import { ChevronRight, FileText } from "lucide-react"; import type { MouseEvent } from "react"; import type { OutlineItem } from "@/shared/editor/model/outline"; export type OutlinePresentationMode = "button" | "link"; export type OutlinePresentationVariant = "card" | "rail"; export interface OutlinePresentationProps { items: OutlineItem[]; activeId?: string | null; title?: string; mode: OutlinePresentationMode; variant?: OutlinePresentationVariant; onItemMouseDown?: (item: OutlineItem, event: MouseEvent) => void; } export function OutlinePresentation({ items, activeId, title = "On this page", mode, variant = "card", onItemMouseDown, }: OutlinePresentationProps) { if (items.length === 0) return null; const className = ["tiptap-outline", variant === "rail" ? "tiptap-outline--rail" : ""].filter(Boolean).join(" "); return ( ); } function outlineItemStyle(level: number) { return { // Keep the CSS padding (0.5rem) as the base so the chevron always has // breathing room from the highlight's left edge, even for top-level headings. paddingInlineStart: `calc(0.5rem + ${Math.max(0, level - 1) * 0.875}rem)`, }; } export type { OutlineItem } from "@/shared/editor/model/outline";