"use client"; import type { ReactNode } from "react"; import { useTranslation } from "react-i18next"; import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@kandev/ui/select"; import { Switch } from "@kandev/ui/switch"; import { useResponsiveBreakpoint } from "@/hooks/use-responsive-breakpoint"; import type { ThreadLayout, ThreadView } from "@/lib/state/slices/ui/thread-view-types"; import { SectionLabel } from "./threads-view-editor-actions"; type LayoutProps = { value: ThreadLayout; onChange: (layout: ThreadLayout) => void; mobile?: boolean; }; function ThreadsLayoutSelect({ value, onChange, mobile = false }: LayoutProps) { const { t } = useTranslation("threads"); return ( ); } export function ThreadsViewDisplay({ current, mobile, gridHeightFallback, onUpdate, children, }: { current: Pick; mobile: boolean; gridHeightFallback: boolean; onUpdate: (patch: Partial>) => void; children: ReactNode; }) { const { t } = useTranslation("threads"); const { isMobile, isFinePointer } = useResponsiveBreakpoint(); return (
{t("display")}
onUpdate({ layout })} />

{current.layout === "grid" ? t("layoutGridDescription") : t("layoutColumnsDescription")}

{isMobile && (

{t("phoneLayoutHint")}

)} {gridHeightFallback && current.layout === "grid" && (

{t("gridHeightFallback")}

)}

{t("autoHideComposerDescription")}

{(isMobile || !isFinePointer) && (

{t("touchComposerHint")}

)}
{children}

{t("maxChatsDescription")}

); }