ardo 2.7.1 → 2.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -333,8 +333,8 @@ declare function ThemeToggle(): react_jsx_runtime.JSX.Element;
333
333
  declare function Search(): react_jsx_runtime.JSX.Element;
334
334
 
335
335
  interface CodeBlockProps {
336
- /** The code to display */
337
- code: string;
336
+ /** The code to display (as prop or as children string) */
337
+ code?: string;
338
338
  /** Programming language for syntax highlighting */
339
339
  language?: string;
340
340
  /** Optional title shown above the code */
@@ -343,13 +343,24 @@ interface CodeBlockProps {
343
343
  lineNumbers?: boolean;
344
344
  /** Line numbers to highlight */
345
345
  highlightLines?: number[];
346
- /** Optional custom content to render instead of the code */
346
+ /** Code as children supports template literals with auto-outdent */
347
347
  children?: React.ReactNode;
348
+ /** Pre-rendered Shiki HTML (injected by ardo:codeblock-highlight plugin) */
349
+ __html?: string;
348
350
  }
349
351
  /**
350
352
  * Syntax-highlighted code block with copy button.
353
+ *
354
+ * Code can be provided via the `code` prop or as children:
355
+ * ```tsx
356
+ * <CodeBlock language="typescript">{`
357
+ * const x = 42
358
+ * `}</CodeBlock>
359
+ * ```
360
+ * When children is a string, leading/trailing blank lines and common
361
+ * indentation are stripped automatically.
351
362
  */
352
- declare function CodeBlock({ code, language, title, lineNumbers, highlightLines, children, }: CodeBlockProps): react_jsx_runtime.JSX.Element;
363
+ declare function CodeBlock({ code: codeProp, language, title, lineNumbers, highlightLines, children, __html, }: CodeBlockProps): react_jsx_runtime.JSX.Element;
353
364
  interface CodeGroupProps {
354
365
  /** CodeBlock components to display as tabs */
355
366
  children: React.ReactNode;
@@ -359,9 +359,9 @@ var TypeDocGenerator = class {
359
359
  return `${parent}/${basename}`;
360
360
  }
361
361
  if (basename === "index") {
362
- const dir = path.dirname(path.resolve(filePath));
363
- const packageName = this.packageNameCache.get(dir);
364
- if (packageName) return packageName;
362
+ for (const packageName of this.packageNameCache.values()) {
363
+ if (packageName) return packageName;
364
+ }
365
365
  }
366
366
  return basename;
367
367
  }
@@ -1032,4 +1032,4 @@ export {
1032
1032
  TypeDocGenerator,
1033
1033
  generateApiDocs
1034
1034
  };
1035
- //# sourceMappingURL=chunk-U6IRSKHU.js.map
1035
+ //# sourceMappingURL=chunk-CYZLI4AU.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/typedoc/generator.ts"],"sourcesContent":["import {\n Application,\n TSConfigReader,\n TypeDocReader,\n type ProjectReflection,\n ReflectionKind,\n type DeclarationReflection,\n type SignatureReflection,\n type TypeParameterReflection,\n} from \"typedoc\"\nimport path from \"path\"\nimport fs from \"fs/promises\"\nimport { readPackageUp } from \"read-package-up\"\nimport type { TypeDocConfig, GeneratedApiDoc } from \"./types\"\n\nexport class TypeDocGenerator {\n private config: TypeDocConfig\n private app: Application | undefined\n private project: ProjectReflection | undefined\n private basePath: string\n private packageNameCache = new Map<string, string | undefined>()\n\n constructor(config: TypeDocConfig) {\n this.config = {\n out: \"api\",\n excludeExternals: true,\n excludePrivate: true,\n excludeProtected: false,\n excludeInternal: true,\n sort: [\"source-order\"],\n sidebar: {\n title: \"API Reference\",\n position: 100,\n collapsed: false,\n },\n markdown: {\n breadcrumbs: true,\n hierarchy: true,\n sourceLinks: true,\n codeBlocks: true,\n },\n ...config,\n }\n // Use the output directory as the base path for links\n this.basePath = \"/\" + this.config.out!\n }\n\n async generate(outputDir: string): Promise<GeneratedApiDoc[]> {\n // Pre-populate package name cache for all entry points\n await Promise.all(this.config.entryPoints.map((ep) => this.resolvePackageName(ep)))\n\n const typedocOptions: Record<string, unknown> = {\n entryPoints: this.config.entryPoints,\n tsconfig: this.config.tsconfig,\n excludeExternals: this.config.excludeExternals,\n excludePrivate: this.config.excludePrivate,\n excludeProtected: this.config.excludeProtected,\n excludeInternal: this.config.excludeInternal,\n sort: this.config.sort,\n }\n\n // Only pass array/string options when explicitly set to avoid\n // TypeDoc errors like \"option must be set to an array of strings\"\n if (this.config.exclude) typedocOptions.exclude = this.config.exclude\n if (this.config.categoryOrder) typedocOptions.categoryOrder = this.config.categoryOrder\n if (this.config.groupOrder) typedocOptions.groupOrder = this.config.groupOrder\n if (this.config.plugin) typedocOptions.plugin = this.config.plugin\n if (this.config.readme) typedocOptions.readme = this.config.readme\n\n this.app = await Application.bootstrapWithPlugins(typedocOptions, [\n new TSConfigReader(),\n new TypeDocReader(),\n ])\n\n this.project = await this.app.convert()\n\n if (!this.project) {\n throw new Error(\"TypeDoc conversion failed\")\n }\n\n const docs = this.generateMarkdownDocs()\n const apiDir = path.join(outputDir, this.config.out!)\n\n await fs.mkdir(apiDir, { recursive: true })\n\n for (const doc of docs) {\n const filePath = path.join(apiDir, doc.path)\n const dir = path.dirname(filePath)\n await fs.mkdir(dir, { recursive: true })\n\n const frontmatterLines = [\n \"---\",\n `title: ${doc.frontmatter.title}`,\n doc.frontmatter.description ? `description: ${doc.frontmatter.description}` : null,\n doc.frontmatter.sidebar_position !== undefined\n ? `sidebar_position: ${doc.frontmatter.sidebar_position}`\n : null,\n doc.frontmatter.sidebar === false ? `sidebar: false` : null,\n \"---\",\n ].filter((line): line is string => line !== null)\n\n const frontmatter = frontmatterLines.join(\"\\n\") + \"\\n\\n\"\n\n await fs.writeFile(filePath, frontmatter + doc.content)\n }\n\n return docs\n }\n\n private generateMarkdownDocs(): GeneratedApiDoc[] {\n if (!this.project) return []\n\n const docs: GeneratedApiDoc[] = []\n\n // Generate index page\n docs.push(this.generateIndexPage())\n\n const children = this.project.children || []\n\n // Group functions and type aliases by source file\n // React components (PascalCase) get their own pages\n const functionsByFile = new Map<string, DeclarationReflection[]>()\n const typesByFile = new Map<string, DeclarationReflection[]>()\n const componentItems: DeclarationReflection[] = []\n const standaloneItems: DeclarationReflection[] = []\n\n for (const child of children) {\n const sourceFile = child.sources?.[0]?.fileName\n\n if (child.kind === ReflectionKind.Function && sourceFile) {\n // React components are PascalCase and get individual pages\n if (this.isReactComponent(child.name)) {\n componentItems.push(child)\n } else {\n const existing = functionsByFile.get(sourceFile) || []\n existing.push(child)\n functionsByFile.set(sourceFile, existing)\n }\n } else if (child.kind === ReflectionKind.TypeAlias && sourceFile) {\n const existing = typesByFile.get(sourceFile) || []\n existing.push(child)\n typesByFile.set(sourceFile, existing)\n } else {\n standaloneItems.push(child)\n }\n }\n\n // Generate grouped pages for functions (by source file)\n for (const [sourceFile, functions] of functionsByFile) {\n docs.push(this.generateGroupedFunctionsPage(sourceFile, functions))\n }\n\n // Generate grouped pages for types (by source file)\n for (const [sourceFile, types] of typesByFile) {\n docs.push(this.generateGroupedTypesPage(sourceFile, types))\n }\n\n // Generate individual pages for React components\n // Sort alphabetically for consistent prev/next navigation\n const sortedComponents = [...componentItems].sort((a, b) => a.name.localeCompare(b.name))\n for (let i = 0; i < sortedComponents.length; i++) {\n const prev = i > 0 ? sortedComponents[i - 1] : null\n const next = i < sortedComponents.length - 1 ? sortedComponents[i + 1] : null\n docs.push(this.generateComponentPage(sortedComponents[i], prev, next))\n }\n\n // Group standalone items by kind for prev/next navigation within each group\n const itemsByKind = new Map<number, DeclarationReflection[]>()\n for (const child of standaloneItems) {\n const kind = child.kind\n const existing = itemsByKind.get(kind) || []\n existing.push(child)\n itemsByKind.set(kind, existing)\n }\n\n // Generate individual pages for classes, interfaces, enums, etc. with prev/next within group\n for (const [, items] of itemsByKind) {\n const sortedItems = [...items].sort((a, b) => a.name.localeCompare(b.name))\n for (let i = 0; i < sortedItems.length; i++) {\n const prev = i > 0 ? sortedItems[i - 1] : null\n const next = i < sortedItems.length - 1 ? sortedItems[i + 1] : null\n docs.push(...this.generateReflectionDocs(sortedItems[i], \"\", prev, next))\n }\n }\n\n // Generate category index pages for non-empty categories\n docs.push(\n ...this.generateCategoryIndexPages(\n docs,\n componentItems,\n functionsByFile,\n typesByFile,\n standaloneItems\n )\n )\n\n return docs\n }\n\n private generateCategoryIndexPages(\n docs: GeneratedApiDoc[],\n componentItems: DeclarationReflection[],\n functionsByFile: Map<string, DeclarationReflection[]>,\n typesByFile: Map<string, DeclarationReflection[]>,\n standaloneItems: DeclarationReflection[]\n ): GeneratedApiDoc[] {\n const indexPages: GeneratedApiDoc[] = []\n\n // Components index\n if (componentItems.length > 0) {\n const sorted = [...componentItems].sort((a, b) => a.name.localeCompare(b.name))\n const content = [\n `# Components`,\n \"\",\n ...sorted.map((c) => {\n const desc = c.comment?.summary ? ` - ${this.renderCommentShort(c.comment.summary)}` : \"\"\n return `- [${c.name}](${this.buildLink(\"components\", this.getSlug(c.name))})${desc}`\n }),\n \"\",\n ]\n indexPages.push({\n path: \"components/index.md\",\n content: content.join(\"\\n\"),\n frontmatter: { title: \"Components\", sidebar: false },\n })\n }\n\n // Functions index\n if (functionsByFile.size > 0) {\n const sortedModules = [...functionsByFile.entries()].sort((a, b) =>\n this.getModuleNameFromPath(a[0]).localeCompare(this.getModuleNameFromPath(b[0]))\n )\n const content = [\n `# Functions`,\n \"\",\n ...sortedModules.map(([sourceFile, functions]) => {\n const moduleName = this.getModuleNameFromPath(sourceFile)\n const slug = this.getSlug(moduleName)\n const funcNames = functions\n .map((f) => f.name)\n .sort()\n .join(\", \")\n return `- [${moduleName}](${this.buildLink(\"functions\", slug)}) - ${funcNames}`\n }),\n \"\",\n ]\n indexPages.push({\n path: \"functions/index.md\",\n content: content.join(\"\\n\"),\n frontmatter: { title: \"Functions\", sidebar: false },\n })\n }\n\n // Group standalone items by kind for category indexes\n const interfaces = standaloneItems.filter((c) => c.kind === ReflectionKind.Interface)\n const classes = standaloneItems.filter((c) => c.kind === ReflectionKind.Class)\n\n // Interfaces index\n if (interfaces.length > 0) {\n const sorted = [...interfaces].sort((a, b) => a.name.localeCompare(b.name))\n const content = [\n `# Interfaces`,\n \"\",\n ...sorted.map((item) => {\n const desc = item.comment?.summary\n ? ` - ${this.renderCommentShort(item.comment.summary)}`\n : \"\"\n return `- [${item.name}](${this.buildLink(\"interfaces\", this.getSlug(item.name))})${desc}`\n }),\n \"\",\n ]\n indexPages.push({\n path: \"interfaces/index.md\",\n content: content.join(\"\\n\"),\n frontmatter: { title: \"Interfaces\", sidebar: false },\n })\n }\n\n // Types index\n if (typesByFile.size > 0) {\n const sortedModules = [...typesByFile.entries()].sort((a, b) =>\n this.getModuleNameFromPath(a[0]).localeCompare(this.getModuleNameFromPath(b[0]))\n )\n const content = [\n `# Types`,\n \"\",\n ...sortedModules.map(([sourceFile, types]) => {\n const moduleName = this.getModuleNameFromPath(sourceFile)\n const slug = this.getSlug(moduleName)\n const typeNames = types\n .map((t) => t.name)\n .sort()\n .join(\", \")\n return `- [${moduleName}](${this.buildLink(\"types\", slug)}) - ${typeNames}`\n }),\n \"\",\n ]\n indexPages.push({\n path: \"types/index.md\",\n content: content.join(\"\\n\"),\n frontmatter: { title: \"Types\", sidebar: false },\n })\n }\n\n // Classes index\n if (classes.length > 0) {\n const sorted = [...classes].sort((a, b) => a.name.localeCompare(b.name))\n const content = [\n `# Classes`,\n \"\",\n ...sorted.map((item) => {\n const desc = item.comment?.summary\n ? ` - ${this.renderCommentShort(item.comment.summary)}`\n : \"\"\n return `- [${item.name}](${this.buildLink(\"classes\", this.getSlug(item.name))})${desc}`\n }),\n \"\",\n ]\n indexPages.push({\n path: \"classes/index.md\",\n content: content.join(\"\\n\"),\n frontmatter: { title: \"Classes\", sidebar: false },\n })\n }\n\n return indexPages\n }\n\n private generateGroupedFunctionsPage(\n sourceFile: string,\n functions: DeclarationReflection[]\n ): GeneratedApiDoc {\n // Extract module name from source file path (e.g., \"src/utils/string.ts\" -> \"string\")\n const moduleName = this.getModuleNameFromPath(sourceFile)\n const slug = this.getSlug(moduleName)\n const content: string[] = []\n\n content.push(`# ${moduleName} Functions`)\n content.push(\"\")\n content.push(`Functions exported from \\`${sourceFile}\\``)\n content.push(\"\")\n\n // Sort functions alphabetically\n const sortedFunctions = [...functions].sort((a, b) => a.name.localeCompare(b.name))\n\n for (const func of sortedFunctions) {\n content.push(`## ${func.name}`)\n content.push(\"\")\n\n // Description\n if (func.comment?.summary) {\n content.push(this.renderComment(func.comment.summary))\n content.push(\"\")\n }\n\n // Signature\n if (func.signatures) {\n for (const sig of func.signatures) {\n content.push(this.renderSignature(sig))\n content.push(\"\")\n }\n }\n\n // Examples\n if (func.comment?.blockTags) {\n const examples = func.comment.blockTags.filter((t) => t.tag === \"@example\")\n if (examples.length > 0) {\n content.push(\"### Example\")\n content.push(\"\")\n for (const example of examples) {\n content.push(this.renderComment(example.content))\n content.push(\"\")\n }\n }\n }\n\n // Source link\n if (this.config.markdown?.sourceLinks && func.sources?.[0]) {\n const source = func.sources[0]\n const sourceUrl = this.getSourceUrl(source.fileName, source.line)\n if (sourceUrl) {\n content.push(`[Source](${sourceUrl})`)\n content.push(\"\")\n }\n }\n\n content.push(\"---\")\n content.push(\"\")\n }\n\n return {\n path: `functions/${slug}.md`,\n content: content.join(\"\\n\"),\n frontmatter: {\n title: `${moduleName} Functions`,\n description: `Functions from ${sourceFile}`,\n },\n }\n }\n\n private generateGroupedTypesPage(\n sourceFile: string,\n types: DeclarationReflection[]\n ): GeneratedApiDoc {\n const moduleName = this.getModuleNameFromPath(sourceFile)\n const slug = this.getSlug(moduleName)\n const content: string[] = []\n\n content.push(`# ${moduleName} Types`)\n content.push(\"\")\n content.push(`Type definitions from \\`${sourceFile}\\``)\n content.push(\"\")\n\n // Sort types alphabetically\n const sortedTypes = [...types].sort((a, b) => a.name.localeCompare(b.name))\n\n for (const typeAlias of sortedTypes) {\n content.push(`## ${typeAlias.name}`)\n content.push(\"\")\n\n // Description\n if (typeAlias.comment?.summary) {\n content.push(this.renderComment(typeAlias.comment.summary))\n content.push(\"\")\n }\n\n // Type definition\n if (typeAlias.type) {\n content.push(\"```typescript\")\n content.push(`type ${typeAlias.name} = ${typeAlias.type.toString()}`)\n content.push(\"```\")\n content.push(\"\")\n }\n\n // Source link\n if (this.config.markdown?.sourceLinks && typeAlias.sources?.[0]) {\n const source = typeAlias.sources[0]\n const sourceUrl = this.getSourceUrl(source.fileName, source.line)\n if (sourceUrl) {\n content.push(`[Source](${sourceUrl})`)\n content.push(\"\")\n }\n }\n\n content.push(\"---\")\n content.push(\"\")\n }\n\n return {\n path: `types/${slug}.md`,\n content: content.join(\"\\n\"),\n frontmatter: {\n title: `${moduleName} Types`,\n description: `Type definitions from ${sourceFile}`,\n },\n }\n }\n\n private async resolvePackageName(filePath: string): Promise<string | undefined> {\n const dir = path.dirname(path.resolve(filePath))\n if (this.packageNameCache.has(dir)) {\n return this.packageNameCache.get(dir)\n }\n\n const result = await readPackageUp({ cwd: dir })\n const name = result?.packageJson.name\n const resolved = name ? name.replace(/^@[^/]+\\//, \"\") : undefined\n this.packageNameCache.set(dir, resolved)\n return resolved\n }\n\n private getModuleNameFromPath(filePath: string): string {\n // Include parent directory to avoid naming conflicts\n // \"src/utils/string.ts\" -> \"utils/string\"\n // \"src/ui/Sidebar.tsx\" -> \"ui/Sidebar\"\n // \"runtime/sidebar.ts\" -> \"runtime/sidebar\"\n const parts = filePath.split(\"/\")\n const basename = (parts.pop() || filePath).replace(/\\.(ts|tsx|js|jsx)$/, \"\")\n\n // Get parent directory if available\n const parent = parts.pop()\n if (parent && parent !== \"src\") {\n return `${parent}/${basename}`\n }\n if (basename === \"index\") {\n // Find the first cached package name. We cannot use path.resolve() here\n // because TypeDoc reports sourceFile paths relative to the project root,\n // while entry points were resolved relative to a different CWD (e.g. docs/).\n for (const packageName of this.packageNameCache.values()) {\n if (packageName) return packageName\n }\n }\n return basename\n }\n\n private generateIndexPage(): GeneratedApiDoc {\n const content = [\n `# ${this.config.sidebar?.title || \"API Reference\"}`,\n \"\",\n this.project?.comment?.summary\n ? this.renderComment(this.project.comment.summary)\n : \"Auto-generated API documentation.\",\n \"\",\n ]\n\n const children = this.project?.children || []\n\n // Group functions and types by source file for linking\n // Separate React components from regular functions\n const functionsByFile = new Map<string, DeclarationReflection[]>()\n const typesByFile = new Map<string, DeclarationReflection[]>()\n const componentItems: DeclarationReflection[] = []\n const standaloneItems: DeclarationReflection[] = []\n\n for (const child of children) {\n const sourceFile = child.sources?.[0]?.fileName\n\n if (child.kind === ReflectionKind.Function && sourceFile) {\n if (this.isReactComponent(child.name)) {\n componentItems.push(child)\n } else {\n const existing = functionsByFile.get(sourceFile) || []\n existing.push(child)\n functionsByFile.set(sourceFile, existing)\n }\n } else if (child.kind === ReflectionKind.TypeAlias && sourceFile) {\n const existing = typesByFile.get(sourceFile) || []\n existing.push(child)\n typesByFile.set(sourceFile, existing)\n } else {\n standaloneItems.push(child)\n }\n }\n\n // Render components\n if (componentItems.length > 0) {\n content.push(\"## Components\")\n content.push(\"\")\n\n const sortedComponents = [...componentItems].sort((a, b) => a.name.localeCompare(b.name))\n\n for (const component of sortedComponents) {\n const description = component.comment?.summary\n ? this.renderCommentShort(component.comment.summary)\n : \"\"\n const descSuffix = description ? ` - ${description}` : \"\"\n content.push(\n `- [${component.name}](${this.buildLink(\"components\", this.getSlug(component.name))})${descSuffix}`\n )\n }\n\n content.push(\"\")\n }\n\n // Render grouped function modules\n if (functionsByFile.size > 0) {\n content.push(\"## Functions\")\n content.push(\"\")\n\n // Sort modules alphabetically\n const sortedModules = [...functionsByFile.entries()].sort((a, b) =>\n this.getModuleNameFromPath(a[0]).localeCompare(this.getModuleNameFromPath(b[0]))\n )\n\n for (const [sourceFile, functions] of sortedModules) {\n const moduleName = this.getModuleNameFromPath(sourceFile)\n const slug = this.getSlug(moduleName)\n const funcNames = functions\n .map((f) => f.name)\n .sort()\n .join(\", \")\n content.push(`- [${moduleName}](${this.buildLink(\"functions\", slug)}) - ${funcNames}`)\n }\n\n content.push(\"\")\n }\n\n // Render grouped type modules\n if (typesByFile.size > 0) {\n content.push(\"## Type Aliases\")\n content.push(\"\")\n\n const sortedModules = [...typesByFile.entries()].sort((a, b) =>\n this.getModuleNameFromPath(a[0]).localeCompare(this.getModuleNameFromPath(b[0]))\n )\n\n for (const [sourceFile, types] of sortedModules) {\n const moduleName = this.getModuleNameFromPath(sourceFile)\n const slug = this.getSlug(moduleName)\n const typeNames = types\n .map((t) => t.name)\n .sort()\n .join(\", \")\n content.push(`- [${moduleName}](${this.buildLink(\"types\", slug)}) - ${typeNames}`)\n }\n\n content.push(\"\")\n }\n\n // Group remaining items by kind\n const groups: Record<string, DeclarationReflection[]> = {}\n\n for (const child of standaloneItems) {\n const kindName = this.getKindGroupName(child.kind, child.name)\n if (!groups[kindName]) {\n groups[kindName] = []\n }\n groups[kindName].push(child)\n }\n\n // Sort each group alphabetically\n for (const group of Object.values(groups)) {\n group.sort((a, b) => a.name.localeCompare(b.name))\n }\n\n // Define the order of groups (excluding Functions and Types which are handled above)\n const groupOrder = [\"Interfaces\", \"Classes\", \"Variables\", \"Enums\", \"Other\"]\n\n // Render each group\n for (const groupName of groupOrder) {\n const group = groups[groupName]\n if (!group || group.length === 0) continue\n\n content.push(`## ${groupName}`)\n content.push(\"\")\n\n for (const child of group) {\n const description = child.comment?.summary\n ? this.renderCommentShort(child.comment.summary)\n : \"\"\n const descSuffix = description ? ` - ${description}` : \"\"\n const groupUrlPrefix = this.getGroupUrlPrefix(child.kind)\n content.push(\n `- [${child.name}](${this.buildLink(groupUrlPrefix, this.getSlug(child.name))})${descSuffix}`\n )\n }\n\n content.push(\"\")\n }\n\n return {\n path: \"index.md\",\n content: content.join(\"\\n\"),\n frontmatter: {\n title: this.config.sidebar?.title || \"API Reference\",\n description: \"Auto-generated API documentation\",\n sidebar_position: 0,\n },\n }\n }\n\n private getKindGroupName(kind: ReflectionKind, name: string): string {\n // Group hooks and components separately from regular functions\n if (kind === ReflectionKind.Function) {\n // React hooks start with \"use\"\n if (name.startsWith(\"use\")) {\n return \"React Hooks\"\n }\n // React components are PascalCase and typically don't start with lowercase\n if (name[0] === name[0].toUpperCase() && !name.includes(\"_\")) {\n return \"React Components\"\n }\n return \"Functions\"\n }\n\n switch (kind) {\n case ReflectionKind.Interface:\n return \"Interfaces\"\n case ReflectionKind.TypeAlias:\n return \"Types\"\n case ReflectionKind.Class:\n return \"Classes\"\n case ReflectionKind.Variable:\n return \"Variables\"\n case ReflectionKind.Enum:\n return \"Enums\"\n default:\n return \"Other\"\n }\n }\n\n private generateReflectionDocs(\n reflection: DeclarationReflection,\n parentPath: string,\n prev: DeclarationReflection | null = null,\n next: DeclarationReflection | null = null\n ): GeneratedApiDoc[] {\n const docs: GeneratedApiDoc[] = []\n const slug = this.getSlug(reflection.name)\n // Use group prefix (e.g., \"interfaces\", \"classes\") when at top level\n const groupPrefix = parentPath ? \"\" : this.getGroupUrlPrefix(reflection.kind)\n const currentPath = parentPath\n ? `${parentPath}/${slug}`\n : groupPrefix\n ? `${groupPrefix}/${slug}`\n : slug\n\n // Generate main page for this reflection\n docs.push(this.generateReflectionPage(reflection, currentPath, prev, next))\n\n // Generate pages for child classes, interfaces, etc.\n // Functions are grouped by source file, not individual pages\n const children = reflection.children || []\n const hasOwnPage = [\n ReflectionKind.Class,\n ReflectionKind.Interface,\n ReflectionKind.Enum,\n ReflectionKind.Namespace,\n ReflectionKind.Module,\n ]\n\n for (const child of children) {\n if (hasOwnPage.includes(child.kind)) {\n docs.push(...this.generateReflectionDocs(child, currentPath))\n }\n }\n\n return docs\n }\n\n private generateReflectionPage(\n reflection: DeclarationReflection,\n pagePath: string,\n prev: DeclarationReflection | null = null,\n next: DeclarationReflection | null = null\n ): GeneratedApiDoc {\n const kind = this.getKindName(reflection.kind)\n const content: string[] = []\n\n // Breadcrumbs\n if (this.config.markdown?.breadcrumbs) {\n content.push(this.generateBreadcrumbs(pagePath))\n content.push(\"\")\n }\n\n // Title\n content.push(`# ${kind}: ${reflection.name}`)\n content.push(\"\")\n\n // Description\n if (reflection.comment?.summary) {\n content.push(this.renderComment(reflection.comment.summary))\n content.push(\"\")\n }\n\n // Type parameters\n if (reflection.typeParameters && reflection.typeParameters.length > 0) {\n content.push(\"## Type Parameters\")\n content.push(\"\")\n content.push(this.renderTypeParameters(reflection.typeParameters))\n content.push(\"\")\n }\n\n // Hierarchy\n if (this.config.markdown?.hierarchy) {\n const hierarchy = this.renderHierarchy(reflection)\n if (hierarchy) {\n content.push(\"## Hierarchy\")\n content.push(\"\")\n content.push(hierarchy)\n content.push(\"\")\n }\n }\n\n // Signature (for functions)\n if (reflection.signatures) {\n content.push(\"## Signature\")\n content.push(\"\")\n for (const sig of reflection.signatures) {\n content.push(this.renderSignature(sig))\n content.push(\"\")\n }\n }\n\n // Properties\n const properties = (reflection.children || []).filter((c) => c.kind === ReflectionKind.Property)\n if (properties.length > 0) {\n content.push(\"## Properties\")\n content.push(\"\")\n for (const prop of properties) {\n content.push(this.renderProperty(prop))\n content.push(\"\")\n }\n }\n\n // Methods\n const methods = (reflection.children || []).filter((c) => c.kind === ReflectionKind.Method)\n if (methods.length > 0) {\n content.push(\"## Methods\")\n content.push(\"\")\n for (const method of methods) {\n content.push(this.renderMethod(method))\n content.push(\"\")\n }\n }\n\n // Enum members\n const enumMembers = (reflection.children || []).filter(\n (c) => c.kind === ReflectionKind.EnumMember\n )\n if (enumMembers.length > 0) {\n content.push(\"## Members\")\n content.push(\"\")\n content.push(\"| Member | Value | Description |\")\n content.push(\"|--------|-------|-------------|\")\n for (const member of enumMembers) {\n const value = member.defaultValue || \"\"\n const desc = member.comment?.summary ? this.renderCommentShort(member.comment.summary) : \"\"\n content.push(`| \\`${member.name}\\` | \\`${value}\\` | ${desc} |`)\n }\n content.push(\"\")\n }\n\n // Type alias definition\n if (reflection.kind === ReflectionKind.TypeAlias && reflection.type) {\n content.push(\"## Type\")\n content.push(\"\")\n content.push(\"```typescript\")\n content.push(`type ${reflection.name} = ${reflection.type.toString()}`)\n content.push(\"```\")\n content.push(\"\")\n }\n\n // Source link\n if (this.config.markdown?.sourceLinks && reflection.sources?.[0]) {\n const source = reflection.sources[0]\n const sourceUrl = this.getSourceUrl(source.fileName, source.line)\n content.push(\"## Source\")\n content.push(\"\")\n if (sourceUrl) {\n content.push(`[${source.fileName}:${source.line}](${sourceUrl})`)\n } else {\n content.push(`${source.fileName}:${source.line}`)\n }\n content.push(\"\")\n }\n\n // Tags (deprecated, example, etc.)\n if (reflection.comment?.blockTags) {\n const examples = reflection.comment.blockTags.filter((t) => t.tag === \"@example\")\n if (examples.length > 0) {\n content.push(\"## Examples\")\n content.push(\"\")\n for (const example of examples) {\n content.push(this.renderComment(example.content))\n content.push(\"\")\n }\n }\n\n const deprecated = reflection.comment.blockTags.find((t) => t.tag === \"@deprecated\")\n if (deprecated) {\n content.push(\":::warning Deprecated\")\n content.push(this.renderComment(deprecated.content))\n content.push(\":::\")\n content.push(\"\")\n }\n\n const see = reflection.comment.blockTags.filter((t) => t.tag === \"@see\")\n if (see.length > 0) {\n content.push(\"## See Also\")\n content.push(\"\")\n for (const s of see) {\n content.push(`- ${this.renderComment(s.content)}`)\n }\n content.push(\"\")\n }\n }\n\n // Prev/Next navigation within group\n if (prev || next) {\n content.push(\"---\")\n content.push(\"\")\n const groupPrefix = this.getGroupUrlPrefix(reflection.kind)\n const prevLink = prev\n ? `[← ${prev.name}](${this.buildLink(groupPrefix, this.getSlug(prev.name))})`\n : \"\"\n const nextLink = next\n ? `[${next.name} →](${this.buildLink(groupPrefix, this.getSlug(next.name))})`\n : \"\"\n if (prev && next) {\n content.push(`${prevLink} | ${nextLink}`)\n } else {\n content.push(prevLink || nextLink)\n }\n content.push(\"\")\n }\n\n return {\n path: `${pagePath}.md`,\n content: content.join(\"\\n\"),\n frontmatter: {\n title: reflection.name,\n description: reflection.comment?.summary\n ? this.renderCommentShort(reflection.comment.summary)\n : `${kind} ${reflection.name}`,\n },\n }\n }\n\n private renderSignature(sig: SignatureReflection): string {\n const lines: string[] = []\n\n if (this.config.markdown?.codeBlocks) {\n lines.push(\"```typescript\")\n }\n\n const typeParams = sig.typeParameters\n ? `<${sig.typeParameters.map((tp) => tp.name).join(\", \")}>`\n : \"\"\n\n const params = (sig.parameters || [])\n .map((p) => {\n const optional = p.flags.isOptional ? \"?\" : \"\"\n const type = p.type ? `: ${p.type.toString()}` : \"\"\n return `${p.name}${optional}${type}`\n })\n .join(\", \")\n\n const returnType = sig.type ? `: ${sig.type.toString()}` : \"\"\n\n lines.push(`function ${sig.name}${typeParams}(${params})${returnType}`)\n\n if (this.config.markdown?.codeBlocks) {\n lines.push(\"```\")\n }\n\n // Parameters table\n if (sig.parameters && sig.parameters.length > 0) {\n lines.push(\"\")\n lines.push(\"### Parameters\")\n lines.push(\"\")\n lines.push(\"| Name | Type | Description |\")\n lines.push(\"|------|------|-------------|\")\n\n for (const param of sig.parameters) {\n const type = param.type ? `\\`${param.type.toString()}\\`` : \"-\"\n const desc = param.comment?.summary ? this.renderCommentShort(param.comment.summary) : \"-\"\n const optional = param.flags.isOptional ? \" (optional)\" : \"\"\n lines.push(`| ${param.name}${optional} | ${type} | ${desc} |`)\n }\n }\n\n // Return value\n if (sig.type && sig.type.toString() !== \"void\") {\n lines.push(\"\")\n lines.push(\"### Returns\")\n lines.push(\"\")\n lines.push(`\\`${sig.type.toString()}\\``)\n\n if (sig.comment?.blockTags) {\n const returns = sig.comment.blockTags.find((t) => t.tag === \"@returns\")\n if (returns) {\n lines.push(\"\")\n lines.push(this.renderComment(returns.content))\n }\n }\n }\n\n return lines.join(\"\\n\")\n }\n\n private renderProperty(prop: DeclarationReflection): string {\n const lines: string[] = []\n\n const flags: string[] = []\n if (prop.flags.isOptional) flags.push(\"optional\")\n if (prop.flags.isReadonly) flags.push(\"readonly\")\n if (prop.flags.isStatic) flags.push(\"static\")\n\n lines.push(`### ${prop.name}`)\n if (flags.length > 0) {\n lines.push(`*${flags.join(\", \")}*`)\n }\n lines.push(\"\")\n\n if (prop.type) {\n lines.push(\"```typescript\")\n lines.push(`${prop.name}: ${prop.type.toString()}`)\n lines.push(\"```\")\n lines.push(\"\")\n }\n\n if (prop.comment?.summary) {\n lines.push(this.renderComment(prop.comment.summary))\n }\n\n if (prop.defaultValue) {\n lines.push(\"\")\n lines.push(`**Default:** \\`${prop.defaultValue}\\``)\n }\n\n return lines.join(\"\\n\")\n }\n\n private renderMethod(method: DeclarationReflection): string {\n const lines: string[] = []\n\n lines.push(`### ${method.name}()`)\n lines.push(\"\")\n\n if (method.signatures) {\n for (const sig of method.signatures) {\n if (sig.comment?.summary) {\n lines.push(this.renderComment(sig.comment.summary))\n lines.push(\"\")\n }\n\n lines.push(this.renderSignature(sig))\n lines.push(\"\")\n }\n }\n\n return lines.join(\"\\n\")\n }\n\n private renderTypeParameters(typeParams: TypeParameterReflection[]): string {\n const lines: string[] = []\n lines.push(\"| Name | Constraint | Default | Description |\")\n lines.push(\"|------|------------|---------|-------------|\")\n\n for (const tp of typeParams) {\n const constraint = tp.type ? `\\`${tp.type.toString()}\\`` : \"-\"\n const defaultVal = tp.default ? `\\`${tp.default.toString()}\\`` : \"-\"\n const desc = tp.comment?.summary ? this.renderCommentShort(tp.comment.summary) : \"-\"\n lines.push(`| ${tp.name} | ${constraint} | ${defaultVal} | ${desc} |`)\n }\n\n return lines.join(\"\\n\")\n }\n\n private renderHierarchy(reflection: DeclarationReflection): string | null {\n const lines: string[] = []\n\n if (reflection.extendedTypes && reflection.extendedTypes.length > 0) {\n lines.push(\"**Extends:**\")\n for (const t of reflection.extendedTypes) {\n lines.push(`- \\`${t.toString()}\\``)\n }\n }\n\n if (reflection.implementedTypes && reflection.implementedTypes.length > 0) {\n lines.push(\"**Implements:**\")\n for (const t of reflection.implementedTypes) {\n lines.push(`- \\`${t.toString()}\\``)\n }\n }\n\n if (reflection.extendedBy && reflection.extendedBy.length > 0) {\n lines.push(\"**Extended by:**\")\n for (const t of reflection.extendedBy) {\n lines.push(`- \\`${t.toString()}\\``)\n }\n }\n\n if (reflection.implementedBy && reflection.implementedBy.length > 0) {\n lines.push(\"**Implemented by:**\")\n for (const t of reflection.implementedBy) {\n lines.push(`- \\`${t.toString()}\\``)\n }\n }\n\n return lines.length > 0 ? lines.join(\"\\n\") : null\n }\n\n private renderComment(parts: { kind: string; text: string }[]): string {\n return parts.map((p) => p.text).join(\"\")\n }\n\n private renderCommentShort(parts: { kind: string; text: string }[]): string {\n const text = this.renderComment(parts)\n const firstSentence = text.split(/[.!?]\\s/)[0]\n return firstSentence.length < text.length ? firstSentence + \".\" : text\n }\n\n private generateBreadcrumbs(pagePath: string): string {\n const parts = pagePath.split(\"/\")\n const breadcrumbs: string[] = [`[API](${this.basePath})`]\n\n let currentPath = \"\"\n for (let i = 0; i < parts.length - 1; i++) {\n currentPath += (currentPath ? \"/\" : \"\") + parts[i]\n breadcrumbs.push(`[${parts[i]}](${this.basePath}/${currentPath})`)\n }\n\n breadcrumbs.push(parts[parts.length - 1])\n\n return breadcrumbs.join(\" / \")\n }\n\n private getKindName(kind: ReflectionKind): string {\n const kindNames: Partial<Record<ReflectionKind, string>> = {\n [ReflectionKind.Class]: \"Class\",\n [ReflectionKind.Interface]: \"Interface\",\n [ReflectionKind.Enum]: \"Enum\",\n [ReflectionKind.TypeAlias]: \"Type\",\n [ReflectionKind.Function]: \"Function\",\n [ReflectionKind.Variable]: \"Variable\",\n [ReflectionKind.Namespace]: \"Namespace\",\n [ReflectionKind.Module]: \"Module\",\n [ReflectionKind.Property]: \"Property\",\n [ReflectionKind.Method]: \"Method\",\n }\n return kindNames[kind] || \"Unknown\"\n }\n\n private getGroupUrlPrefix(kind: ReflectionKind): string {\n const prefixes: Partial<Record<ReflectionKind, string>> = {\n [ReflectionKind.Class]: \"classes\",\n [ReflectionKind.Interface]: \"interfaces\",\n [ReflectionKind.Enum]: \"enums\",\n [ReflectionKind.Variable]: \"variables\",\n [ReflectionKind.Namespace]: \"namespaces\",\n [ReflectionKind.Module]: \"modules\",\n }\n return prefixes[kind] || \"other\"\n }\n\n private getSlug(name: string): string {\n return name\n .toLowerCase()\n .replace(/[^a-z0-9]+/g, \"-\")\n .replace(/^-|-$/g, \"\")\n }\n\n /**\n * Build a route-compatible link path for a category/slug pair.\n * React Router maps \"category/index.md\" to the \"/category\" route,\n * so links must not include a trailing \"/index\".\n */\n private buildLink(category: string, slug: string): string {\n if (slug === \"index\") {\n return `${this.basePath}/${category}`\n }\n return `${this.basePath}/${category}/${slug}`\n }\n\n private getSourceUrl(fileName: string, line: number): string | null {\n if (!this.config.markdown?.sourceBaseUrl) return null\n const baseUrl = this.config.markdown.sourceBaseUrl.replace(/\\/$/, \"\")\n return `${baseUrl}/${fileName}#L${line}`\n }\n\n /**\n * Check if a function name looks like a React component (PascalCase)\n */\n private isReactComponent(name: string): boolean {\n // React components start with uppercase and don't contain underscores\n // Also check for common component patterns\n if (name[0] !== name[0].toUpperCase()) return false\n if (name.includes(\"_\")) return false\n // Exclude common non-component patterns\n if (name.startsWith(\"use\")) return false // hooks\n if (name.endsWith(\"Props\") || name.endsWith(\"Options\") || name.endsWith(\"Config\")) return false\n return true\n }\n\n /**\n * Generate a page for a React component\n */\n private generateComponentPage(\n component: DeclarationReflection,\n prev: DeclarationReflection | null,\n next: DeclarationReflection | null\n ): GeneratedApiDoc {\n const slug = this.getSlug(component.name)\n const groupPrefix = \"components\"\n const content: string[] = []\n\n content.push(`# ${component.name}`)\n content.push(\"\")\n\n // Description\n if (component.comment?.summary) {\n content.push(this.renderComment(component.comment.summary))\n content.push(\"\")\n }\n\n // Signature\n if (component.signatures) {\n content.push(\"## Usage\")\n content.push(\"\")\n for (const sig of component.signatures) {\n content.push(this.renderComponentSignature(sig, component.name))\n content.push(\"\")\n }\n }\n\n // Examples\n if (component.comment?.blockTags) {\n const examples = component.comment.blockTags.filter((t) => t.tag === \"@example\")\n if (examples.length > 0) {\n content.push(\"## Example\")\n content.push(\"\")\n for (const example of examples) {\n content.push(this.renderComment(example.content))\n content.push(\"\")\n }\n }\n }\n\n // Source link\n if (this.config.markdown?.sourceLinks && component.sources?.[0]) {\n const source = component.sources[0]\n const sourceUrl = this.getSourceUrl(source.fileName, source.line)\n if (sourceUrl) {\n content.push(`[Source](${sourceUrl})`)\n content.push(\"\")\n }\n }\n\n // Prev/Next navigation\n if (prev || next) {\n content.push(\"---\")\n content.push(\"\")\n const prevLink = prev\n ? `[← ${prev.name}](${this.buildLink(groupPrefix, this.getSlug(prev.name))})`\n : \"\"\n const nextLink = next\n ? `[${next.name} →](${this.buildLink(groupPrefix, this.getSlug(next.name))})`\n : \"\"\n if (prev && next) {\n content.push(`${prevLink} | ${nextLink}`)\n } else {\n content.push(prevLink || nextLink)\n }\n content.push(\"\")\n }\n\n return {\n path: `${groupPrefix}/${slug}.md`,\n content: content.join(\"\\n\"),\n frontmatter: {\n title: component.name,\n description: component.comment?.summary\n ? this.renderCommentShort(component.comment.summary)\n : `${component.name} component`,\n },\n }\n }\n\n /**\n * Get the name of a TypeDoc type (handles reference types, etc.)\n */\n private getTypeName(paramType: unknown): string | null {\n if (!paramType || typeof paramType !== \"object\") return null\n\n // Direct name property\n if (\"name\" in paramType && typeof (paramType as { name: unknown }).name === \"string\") {\n return (paramType as { name: string }).name\n }\n\n // Reference type with target\n if (\"type\" in paramType && (paramType as { type: string }).type === \"reference\") {\n const refType = paramType as { name?: string; qualifiedName?: string }\n return refType.name || refType.qualifiedName || null\n }\n\n return null\n }\n\n /**\n * Get props from a component's parameter type\n */\n private getPropsFromType(\n paramType: unknown\n ): Array<{ name: string; type: string; optional: boolean; description: string }> {\n const props: Array<{ name: string; type: string; optional: boolean; description: string }> = []\n\n // Check if it's a reflection type with inline declaration\n if (paramType && typeof paramType === \"object\" && \"declaration\" in paramType) {\n const declaration = (paramType as { declaration: DeclarationReflection }).declaration\n const children = declaration.children || []\n for (const child of children) {\n props.push({\n name: child.name,\n type: child.type ? child.type.toString() : \"unknown\",\n optional: child.flags.isOptional,\n description: child.comment?.summary ? this.renderCommentShort(child.comment.summary) : \"\",\n })\n }\n }\n // Check if it's a reference type - look up the interface in the project\n else {\n const typeName = this.getTypeName(paramType)\n if (typeName) {\n // Find the interface/type alias in the project\n let propsInterface = this.project?.getChildByName(typeName)\n\n // If not found directly, search all children\n if (!propsInterface && this.project?.children) {\n for (const child of this.project.children) {\n if (child.name === typeName) {\n propsInterface = child\n break\n }\n }\n }\n\n if (propsInterface && \"children\" in propsInterface) {\n const children = (propsInterface as DeclarationReflection).children || []\n for (const child of children) {\n props.push({\n name: child.name,\n type: child.type ? child.type.toString() : \"unknown\",\n optional: child.flags.isOptional,\n description: child.comment?.summary\n ? this.renderCommentShort(child.comment.summary)\n : \"\",\n })\n }\n }\n }\n }\n\n return props\n }\n\n /**\n * Render a component signature in a more readable format\n */\n private renderComponentSignature(sig: SignatureReflection, componentName: string): string {\n const lines: string[] = []\n\n // Get props from the first parameter\n const propsParam = sig.parameters?.[0]\n const props = propsParam ? this.getPropsFromType(propsParam.type) : []\n\n // Get the props interface name for linking\n const propsTypeName = propsParam?.type ? this.getTypeName(propsParam.type) : null\n\n // Check if component has children prop\n const hasChildren = props.some((p) => p.name === \"children\")\n // Filter out children from props display (shown in JSX structure instead)\n const displayProps = props.filter((p) => p.name !== \"children\")\n\n lines.push(\"```tsx\")\n lines.push(`<${componentName}`)\n\n if (displayProps.length > 0) {\n for (const prop of displayProps) {\n const optMark = prop.optional ? \"?\" : \"\"\n lines.push(` ${prop.name}${optMark}={${prop.type}}`)\n }\n } else if (!hasChildren) {\n lines.push(` {...props}`)\n }\n\n if (hasChildren) {\n lines.push(`>`)\n lines.push(` {children}`)\n lines.push(`</${componentName}>`)\n } else {\n lines.push(`/>`)\n }\n lines.push(\"```\")\n\n // Props table with link to props interface\n if (props.length > 0) {\n lines.push(\"\")\n if (propsTypeName) {\n lines.push(`## [Props](${this.basePath}/interfaces/${this.getSlug(propsTypeName)})`)\n } else {\n lines.push(\"## Props\")\n }\n lines.push(\"\")\n lines.push(\"| Prop | Type | Required | Description |\")\n lines.push(\"|------|------|----------|-------------|\")\n\n for (const prop of props) {\n const type = `\\`${prop.type}\\``\n const required = prop.optional ? \"No\" : \"Yes\"\n const desc = prop.description || \"-\"\n lines.push(`| ${prop.name} | ${type} | ${required} | ${desc} |`)\n }\n }\n\n // Skip return value for components - it's always Element/JSX.Element\n\n return lines.join(\"\\n\")\n }\n}\n\nexport async function generateApiDocs(\n config: TypeDocConfig,\n outputDir: string\n): Promise<Generated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,UAAU;AAAA,MACvB;AACA,YAAM,KAAK,EAAE;AACb,YAAM,KAAK,0CAA0C;AACrD,YAAM,KAAK,0CAA0C;AAErD,iBAAW,QAAQ,OAAO;AACxB,cAAM,OAAO,KAAK,KAAK,IAAI;AAC3B,cAAM,WAAW,KAAK,WAAW,OAAO;AACxC,cAAM,OAAO,KAAK,eAAe;AACjC,cAAM,KAAK,KAAK,KAAK,IAAI,MAAM,IAAI,MAAM,QAAQ,MAAM,IAAI,IAAI;AAAA,MACjE;AAAA,IACF;AAIA,WAAO,MAAM,KAAK,IAAI;AAAA,EACxB;AACF;AAEA,eAAsB,gBACpB,QACA,WAC4B;AAC5B,QAAM,YAAY,IAAI,iBAAiB,MAAM;AAC7C,SAAO,UAAU,SAAS,SAAS;AACrC;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Content
3
- } from "./chunk-6MXVILOZ.js";
3
+ } from "./chunk-TUXQC2BT.js";
4
4
  import {
5
5
  ChevronDownIcon,
6
6
  GithubIcon,
@@ -841,4 +841,4 @@ export {
841
841
  Steps,
842
842
  FileTree
843
843
  };
844
- //# sourceMappingURL=chunk-2JWOR7PG.js.map
844
+ //# sourceMappingURL=chunk-D3I3T743.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  generateApiDocs
3
- } from "./chunk-U6IRSKHU.js";
3
+ } from "./chunk-CYZLI4AU.js";
4
4
 
5
5
  // src/typedoc/vite-plugin.ts
6
6
  import path from "path";
@@ -271,4 +271,4 @@ export {
271
271
  ApiKindBadge,
272
272
  ApiHierarchy
273
273
  };
274
- //# sourceMappingURL=chunk-EA24YW22.js.map
274
+ //# sourceMappingURL=chunk-KOYIKUSW.js.map
@@ -16,14 +16,29 @@ import {
16
16
  useThemeConfig
17
17
  } from "./chunk-QELSOHIY.js";
18
18
 
19
+ // src/ui/BareContent.tsx
20
+ import { createContext, useContext } from "react";
21
+ import { jsx } from "react/jsx-runtime";
22
+ var BareContentContext = createContext(false);
23
+ function BareContent({ children }) {
24
+ return /* @__PURE__ */ jsx(BareContentContext, { value: true, children });
25
+ }
26
+ function useBareContent() {
27
+ return useContext(BareContentContext);
28
+ }
29
+
19
30
  // src/ui/Content.tsx
20
31
  import { Link, useLocation } from "react-router";
21
- import { jsx, jsxs } from "react/jsx-runtime";
32
+ import { jsx as jsx2, jsxs } from "react/jsx-runtime";
22
33
  function Content({ children }) {
34
+ const isBare = useBareContent();
23
35
  const pageData = usePageData();
24
36
  const themeConfig = useThemeConfig();
25
37
  const sidebar = useSidebar();
26
38
  const location = useLocation();
39
+ if (isBare) {
40
+ return /* @__PURE__ */ jsx2("div", { className: "ardo-content-body ardo-content", children });
41
+ }
27
42
  const { prev, next } = getPrevNextLinks(sidebar, location.pathname);
28
43
  const showEditLink = pageData?.frontmatter.editLink !== false && themeConfig.editLink?.pattern;
29
44
  const showLastUpdated = pageData?.frontmatter.lastUpdated !== false && themeConfig.lastUpdated?.enabled && pageData?.lastUpdated;
@@ -38,13 +53,13 @@ function Content({ children }) {
38
53
  ) : null;
39
54
  return /* @__PURE__ */ jsxs("article", { className: "ardo-content-container", children: [
40
55
  pageData?.frontmatter.title && /* @__PURE__ */ jsxs("header", { className: "ardo-content-header", children: [
41
- /* @__PURE__ */ jsx("h1", { className: "ardo-content-title", children: pageData.frontmatter.title }),
42
- pageData.frontmatter.description && /* @__PURE__ */ jsx("p", { className: "ardo-content-description", children: pageData.frontmatter.description })
56
+ /* @__PURE__ */ jsx2("h1", { className: "ardo-content-title", children: pageData.frontmatter.title }),
57
+ pageData.frontmatter.description && /* @__PURE__ */ jsx2("p", { className: "ardo-content-description", children: pageData.frontmatter.description })
43
58
  ] }),
44
- /* @__PURE__ */ jsx("div", { className: "ardo-content-body ardo-content", children }),
59
+ /* @__PURE__ */ jsx2("div", { className: "ardo-content-body ardo-content", children }),
45
60
  /* @__PURE__ */ jsxs("footer", { className: "ardo-content-footer", children: [
46
61
  (showEditLink || showLastUpdated) && /* @__PURE__ */ jsxs("div", { className: "ardo-content-meta", children: [
47
- showEditLink && /* @__PURE__ */ jsx(
62
+ showEditLink && /* @__PURE__ */ jsx2(
48
63
  "a",
49
64
  {
50
65
  href: editLink,
@@ -62,20 +77,20 @@ function Content({ children }) {
62
77
  ] }),
63
78
  (prev || next) && /* @__PURE__ */ jsxs("nav", { className: "ardo-prev-next", "aria-label": "Page navigation", children: [
64
79
  prev ? /* @__PURE__ */ jsxs(Link, { to: prev.link, className: "ardo-prev-link", children: [
65
- /* @__PURE__ */ jsx("span", { className: "ardo-prev-next-label", children: "Previous" }),
66
- /* @__PURE__ */ jsx("span", { className: "ardo-prev-next-title", children: prev.text })
67
- ] }) : /* @__PURE__ */ jsx("div", {}),
80
+ /* @__PURE__ */ jsx2("span", { className: "ardo-prev-next-label", children: "Previous" }),
81
+ /* @__PURE__ */ jsx2("span", { className: "ardo-prev-next-title", children: prev.text })
82
+ ] }) : /* @__PURE__ */ jsx2("div", {}),
68
83
  next ? /* @__PURE__ */ jsxs(Link, { to: next.link, className: "ardo-next-link", children: [
69
- /* @__PURE__ */ jsx("span", { className: "ardo-prev-next-label", children: "Next" }),
70
- /* @__PURE__ */ jsx("span", { className: "ardo-prev-next-title", children: next.text })
71
- ] }) : /* @__PURE__ */ jsx("div", {})
84
+ /* @__PURE__ */ jsx2("span", { className: "ardo-prev-next-label", children: "Next" }),
85
+ /* @__PURE__ */ jsx2("span", { className: "ardo-prev-next-title", children: next.text })
86
+ ] }) : /* @__PURE__ */ jsx2("div", {})
72
87
  ] })
73
88
  ] })
74
89
  ] });
75
90
  }
76
91
 
77
92
  // src/ui/components/Icon.tsx
78
- import { jsx as jsx2 } from "react/jsx-runtime";
93
+ import { jsx as jsx3 } from "react/jsx-runtime";
79
94
  var iconRegistry = /* @__PURE__ */ new Map();
80
95
  function registerIcons(icons2) {
81
96
  for (const [name, icon] of Object.entries(icons2)) {
@@ -91,12 +106,12 @@ function Icon({ name, ...props }) {
91
106
  console.warn(`[Ardo] Icon "${name}" not found. Did you register it with registerIcons()?`);
92
107
  return null;
93
108
  }
94
- return /* @__PURE__ */ jsx2(IconComp, { ...props });
109
+ return /* @__PURE__ */ jsx3(IconComp, { ...props });
95
110
  }
96
111
 
97
112
  // src/ui/components/CopyButton.tsx
98
113
  import { useState } from "react";
99
- import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
114
+ import { jsx as jsx4, jsxs as jsxs2 } from "react/jsx-runtime";
100
115
  function CopyButton({ code }) {
101
116
  const [copied, setCopied] = useState(false);
102
117
  const handleCopy = async () => {
@@ -115,8 +130,8 @@ function CopyButton({ code }) {
115
130
  onClick: handleCopy,
116
131
  "aria-label": copied ? "Copied!" : "Copy code",
117
132
  children: [
118
- copied ? /* @__PURE__ */ jsx3(CheckIcon, { size: 16 }) : /* @__PURE__ */ jsx3(CopyIcon, { size: 16 }),
119
- /* @__PURE__ */ jsx3("span", { className: "ardo-copy-text", children: copied ? "Copied!" : "Copy" })
133
+ copied ? /* @__PURE__ */ jsx4(CheckIcon, { size: 16 }) : /* @__PURE__ */ jsx4(CopyIcon, { size: 16 }),
134
+ /* @__PURE__ */ jsx4("span", { className: "ardo-copy-text", children: copied ? "Copied!" : "Copy" })
120
135
  ]
121
136
  }
122
137
  );
@@ -124,31 +139,53 @@ function CopyButton({ code }) {
124
139
 
125
140
  // src/ui/components/CodeBlock.tsx
126
141
  import { useState as useState2, Children, isValidElement } from "react";
127
- import { jsx as jsx4, jsxs as jsxs3 } from "react/jsx-runtime";
142
+ import { Fragment, jsx as jsx5, jsxs as jsxs3 } from "react/jsx-runtime";
143
+ function outdent(text) {
144
+ const trimmed = text.replace(/^\n+/, "").replace(/\n\s*$/, "");
145
+ const lines = trimmed.split("\n");
146
+ const indent = lines.reduce((min, line) => {
147
+ if (line.trim().length === 0) return min;
148
+ const match = line.match(/^(\s*)/);
149
+ return match ? Math.min(min, match[1].length) : min;
150
+ }, Infinity);
151
+ if (indent === 0 || indent === Infinity) return trimmed;
152
+ return lines.map((line) => line.slice(indent)).join("\n");
153
+ }
128
154
  function CodeBlock({
129
- code,
155
+ code: codeProp,
130
156
  language = "text",
131
157
  title,
132
158
  lineNumbers = false,
133
159
  highlightLines = [],
134
- children
160
+ children,
161
+ __html
135
162
  }) {
163
+ const code = codeProp ?? (typeof children === "string" ? outdent(children) : "");
164
+ const hasCustomChildren = children != null && typeof children !== "string";
136
165
  const lines = code.split("\n");
166
+ let content;
167
+ if (__html) {
168
+ content = /* @__PURE__ */ jsx5("div", { dangerouslySetInnerHTML: { __html } });
169
+ } else if (hasCustomChildren) {
170
+ content = /* @__PURE__ */ jsx5(Fragment, { children });
171
+ } else {
172
+ content = /* @__PURE__ */ jsx5("pre", { className: `language-${language}`, children: /* @__PURE__ */ jsx5("code", { children: lines.map((line, index) => {
173
+ const lineNum = index + 1;
174
+ const isHighlighted = highlightLines.includes(lineNum);
175
+ const classes = ["ardo-code-line"];
176
+ if (isHighlighted) classes.push("highlighted");
177
+ return /* @__PURE__ */ jsxs3("span", { className: classes.join(" "), children: [
178
+ lineNumbers && /* @__PURE__ */ jsx5("span", { className: "ardo-line-number", children: lineNum }),
179
+ /* @__PURE__ */ jsx5("span", { className: "ardo-line-content", children: line }),
180
+ index < lines.length - 1 && "\n"
181
+ ] }, index);
182
+ }) }) });
183
+ }
137
184
  return /* @__PURE__ */ jsxs3("div", { className: "ardo-code-block", "data-lang": language, children: [
138
- title && /* @__PURE__ */ jsx4("div", { className: "ardo-code-title", children: title }),
185
+ title && /* @__PURE__ */ jsx5("div", { className: "ardo-code-title", children: title }),
139
186
  /* @__PURE__ */ jsxs3("div", { className: "ardo-code-wrapper", children: [
140
- children || /* @__PURE__ */ jsx4("pre", { className: `language-${language}`, children: /* @__PURE__ */ jsx4("code", { children: lines.map((line, index) => {
141
- const lineNum = index + 1;
142
- const isHighlighted = highlightLines.includes(lineNum);
143
- const classes = ["ardo-code-line"];
144
- if (isHighlighted) classes.push("highlighted");
145
- return /* @__PURE__ */ jsxs3("span", { className: classes.join(" "), children: [
146
- lineNumbers && /* @__PURE__ */ jsx4("span", { className: "ardo-line-number", children: lineNum }),
147
- /* @__PURE__ */ jsx4("span", { className: "ardo-line-content", children: line }),
148
- index < lines.length - 1 && "\n"
149
- ] }, index);
150
- }) }) }),
151
- /* @__PURE__ */ jsx4(CopyButton, { code })
187
+ content,
188
+ /* @__PURE__ */ jsx5(CopyButton, { code })
152
189
  ] })
153
190
  ] });
154
191
  }
@@ -162,7 +199,7 @@ function CodeGroup({ children, labels: labelsStr }) {
162
199
  return props["data-label"] || props.title || props.language || `Tab ${index + 1}`;
163
200
  });
164
201
  return /* @__PURE__ */ jsxs3("div", { className: "ardo-code-group", children: [
165
- /* @__PURE__ */ jsx4("div", { className: "ardo-code-group-tabs", children: tabs.map((tab, index) => /* @__PURE__ */ jsx4(
202
+ /* @__PURE__ */ jsx5("div", { className: "ardo-code-group-tabs", children: tabs.map((tab, index) => /* @__PURE__ */ jsx5(
166
203
  "button",
167
204
  {
168
205
  className: ["ardo-code-group-tab", index === activeTab && "active"].filter(Boolean).join(" "),
@@ -171,7 +208,7 @@ function CodeGroup({ children, labels: labelsStr }) {
171
208
  },
172
209
  index
173
210
  )) }),
174
- /* @__PURE__ */ jsx4("div", { className: "ardo-code-group-panels", children: childArray.map((child, index) => /* @__PURE__ */ jsx4(
211
+ /* @__PURE__ */ jsx5("div", { className: "ardo-code-group-panels", children: childArray.map((child, index) => /* @__PURE__ */ jsx5(
175
212
  "div",
176
213
  {
177
214
  className: ["ardo-code-group-panel", index === activeTab && "active"].filter(Boolean).join(" "),
@@ -184,7 +221,7 @@ function CodeGroup({ children, labels: labelsStr }) {
184
221
  }
185
222
 
186
223
  // src/ui/components/Container.tsx
187
- import { jsx as jsx5, jsxs as jsxs4 } from "react/jsx-runtime";
224
+ import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
188
225
  var defaultTitles = {
189
226
  tip: "TIP",
190
227
  warning: "WARNING",
@@ -193,44 +230,44 @@ var defaultTitles = {
193
230
  note: "NOTE"
194
231
  };
195
232
  var icons = {
196
- tip: /* @__PURE__ */ jsx5(LightbulbIcon, { size: 18 }),
197
- warning: /* @__PURE__ */ jsx5(AlertTriangleIcon, { size: 18 }),
198
- danger: /* @__PURE__ */ jsx5(XCircleIcon, { size: 18 }),
199
- info: /* @__PURE__ */ jsx5(InfoIcon, { size: 18 }),
200
- note: /* @__PURE__ */ jsx5(FileTextIcon, { size: 18 })
233
+ tip: /* @__PURE__ */ jsx6(LightbulbIcon, { size: 18 }),
234
+ warning: /* @__PURE__ */ jsx6(AlertTriangleIcon, { size: 18 }),
235
+ danger: /* @__PURE__ */ jsx6(XCircleIcon, { size: 18 }),
236
+ info: /* @__PURE__ */ jsx6(InfoIcon, { size: 18 }),
237
+ note: /* @__PURE__ */ jsx6(FileTextIcon, { size: 18 })
201
238
  };
202
239
  function Container({ type, title, children }) {
203
240
  const displayTitle = title || defaultTitles[type];
204
241
  return /* @__PURE__ */ jsxs4("div", { className: `ardo-container ardo-container-${type}`, children: [
205
242
  /* @__PURE__ */ jsxs4("p", { className: "ardo-container-title", children: [
206
- /* @__PURE__ */ jsx5("span", { className: "ardo-container-icon", children: icons[type] }),
243
+ /* @__PURE__ */ jsx6("span", { className: "ardo-container-icon", children: icons[type] }),
207
244
  displayTitle
208
245
  ] }),
209
- /* @__PURE__ */ jsx5("div", { className: "ardo-container-content", children })
246
+ /* @__PURE__ */ jsx6("div", { className: "ardo-container-content", children })
210
247
  ] });
211
248
  }
212
249
  function Tip({ title, children }) {
213
- return /* @__PURE__ */ jsx5(Container, { type: "tip", title, children });
250
+ return /* @__PURE__ */ jsx6(Container, { type: "tip", title, children });
214
251
  }
215
252
  function Warning({ title, children }) {
216
- return /* @__PURE__ */ jsx5(Container, { type: "warning", title, children });
253
+ return /* @__PURE__ */ jsx6(Container, { type: "warning", title, children });
217
254
  }
218
255
  function Danger({ title, children }) {
219
- return /* @__PURE__ */ jsx5(Container, { type: "danger", title, children });
256
+ return /* @__PURE__ */ jsx6(Container, { type: "danger", title, children });
220
257
  }
221
258
  function Info({ title, children }) {
222
- return /* @__PURE__ */ jsx5(Container, { type: "info", title, children });
259
+ return /* @__PURE__ */ jsx6(Container, { type: "info", title, children });
223
260
  }
224
261
  function Note({ title, children }) {
225
- return /* @__PURE__ */ jsx5(Container, { type: "note", title, children });
262
+ return /* @__PURE__ */ jsx6(Container, { type: "note", title, children });
226
263
  }
227
264
 
228
265
  // src/ui/components/Tabs.tsx
229
- import { useState as useState3, createContext, useContext } from "react";
230
- import { jsx as jsx6 } from "react/jsx-runtime";
231
- var TabsContext = createContext(null);
266
+ import { useState as useState3, createContext as createContext2, useContext as useContext2 } from "react";
267
+ import { jsx as jsx7 } from "react/jsx-runtime";
268
+ var TabsContext = createContext2(null);
232
269
  function useTabsContext() {
233
- const context = useContext(TabsContext);
270
+ const context = useContext2(TabsContext);
234
271
  if (!context) {
235
272
  throw new Error("Tab components must be used within a Tabs component");
236
273
  }
@@ -238,15 +275,15 @@ function useTabsContext() {
238
275
  }
239
276
  function Tabs({ defaultValue, children }) {
240
277
  const [activeTab, setActiveTab] = useState3(defaultValue || "");
241
- return /* @__PURE__ */ jsx6(TabsContext.Provider, { value: { activeTab, setActiveTab }, children: /* @__PURE__ */ jsx6("div", { className: "ardo-tabs", children }) });
278
+ return /* @__PURE__ */ jsx7(TabsContext.Provider, { value: { activeTab, setActiveTab }, children: /* @__PURE__ */ jsx7("div", { className: "ardo-tabs", children }) });
242
279
  }
243
280
  function TabList({ children }) {
244
- return /* @__PURE__ */ jsx6("div", { className: "ardo-tab-list", role: "tablist", children });
281
+ return /* @__PURE__ */ jsx7("div", { className: "ardo-tab-list", role: "tablist", children });
245
282
  }
246
283
  function Tab({ value, children }) {
247
284
  const { activeTab, setActiveTab } = useTabsContext();
248
285
  const isActive = activeTab === value;
249
- return /* @__PURE__ */ jsx6(
286
+ return /* @__PURE__ */ jsx7(
250
287
  "button",
251
288
  {
252
289
  role: "tab",
@@ -263,13 +300,14 @@ function TabPanel({ value, children }) {
263
300
  if (!isActive) {
264
301
  return null;
265
302
  }
266
- return /* @__PURE__ */ jsx6("div", { role: "tabpanel", className: "ardo-tab-panel", children });
303
+ return /* @__PURE__ */ jsx7("div", { role: "tabpanel", className: "ardo-tab-panel", children });
267
304
  }
268
305
  function TabPanels({ children }) {
269
- return /* @__PURE__ */ jsx6("div", { className: "ardo-tab-panels", children });
306
+ return /* @__PURE__ */ jsx7("div", { className: "ardo-tab-panels", children });
270
307
  }
271
308
 
272
309
  export {
310
+ BareContent,
273
311
  Content,
274
312
  registerIcons,
275
313
  getRegisteredIconNames,
@@ -289,4 +327,4 @@ export {
289
327
  TabPanel,
290
328
  TabPanels
291
329
  };
292
- //# sourceMappingURL=chunk-6MXVILOZ.js.map
330
+ //# sourceMappingURL=chunk-TUXQC2BT.js.map