mirror of
https://github.com/soconnor0919/hristudio.git
synced 2026-03-24 03:37:51 -04:00
feat: Introduce dedicated participant, experiment, and trial detail/edit pages, enable MinIO, and refactor dashboard navigation.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import * as LucideIcons from "lucide-react";
|
||||
import { cn } from "~/lib/utils";
|
||||
import { type ReactNode } from "react";
|
||||
import { Badge } from "~/components/ui/badge";
|
||||
import { Button } from "~/components/ui/button";
|
||||
@@ -45,10 +46,15 @@ interface EntityViewSidebarProps {
|
||||
children: ReactNode;
|
||||
}
|
||||
|
||||
|
||||
interface EntityViewProps {
|
||||
children: ReactNode;
|
||||
layout?: "default" | "full-width";
|
||||
}
|
||||
|
||||
// ... existing code ...
|
||||
|
||||
|
||||
export function EntityViewHeader({
|
||||
title,
|
||||
subtitle,
|
||||
@@ -115,8 +121,15 @@ export function EntityViewSidebar({ children }: EntityViewSidebarProps) {
|
||||
return <div className="space-y-6">{children}</div>;
|
||||
}
|
||||
|
||||
export function EntityView({ children }: EntityViewProps) {
|
||||
return <div className="space-y-6">{children}</div>;
|
||||
export function EntityView({ children, layout = "default" }: EntityViewProps) {
|
||||
// Simplification: Always take full width of the parent container provided by DashboardLayout
|
||||
// The DashboardLayout already provides padding (p-4).
|
||||
// We remove 'container mx-auto max-w-5xl' to stop it from shrinking.
|
||||
return (
|
||||
<div className="flex flex-col gap-6 w-full h-full">
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
// Utility component for empty states
|
||||
@@ -158,13 +171,12 @@ interface InfoGridProps {
|
||||
export function InfoGrid({ items, columns = 2 }: InfoGridProps) {
|
||||
return (
|
||||
<div
|
||||
className={`grid gap-4 ${
|
||||
columns === 1
|
||||
? "grid-cols-1"
|
||||
: columns === 2
|
||||
? "md:grid-cols-2"
|
||||
: "md:grid-cols-2 lg:grid-cols-3"
|
||||
}`}
|
||||
className={`grid gap-4 ${columns === 1
|
||||
? "grid-cols-1"
|
||||
: columns === 2
|
||||
? "md:grid-cols-2"
|
||||
: "md:grid-cols-2 lg:grid-cols-3"
|
||||
}`}
|
||||
>
|
||||
{items.map((item, index) => (
|
||||
<div
|
||||
|
||||
Reference in New Issue
Block a user