@openpkg-ts/doc-generator 0.1.1 → 0.1.2

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.
@@ -1,66 +1,813 @@
1
1
  "use client";
2
- import {
3
- CollapsibleMethod,
4
- ExampleBlock,
5
- ExpandableProperty,
6
- MemberRow,
7
- MembersTable,
8
- NestedProperty,
9
- ParamRow,
10
- ParamTable,
11
- Signature,
12
- TypeTable,
13
- cleanCode,
14
- getExampleCode,
15
- getExampleLanguage,
16
- getExampleTitle,
17
- groupMembersByKind
18
- } from "./shared/chunk-e5fkh3kh.js";
19
- import {
20
- buildSignatureString,
21
- formatSchema
22
- } from "./shared/chunk-taeg9090.js";
23
- // src/components/styled/ClassPage.tsx
2
+ // src/components/headless/CollapsibleMethod.tsx
3
+ import { useEffect, useState } from "react";
4
+
5
+ // src/core/query.ts
6
+ function formatSchema(schema) {
7
+ if (!schema)
8
+ return "unknown";
9
+ if (typeof schema === "string")
10
+ return schema;
11
+ if (typeof schema === "object" && schema !== null) {
12
+ if ("$ref" in schema && typeof schema.$ref === "string") {
13
+ return schema.$ref.replace("#/types/", "");
14
+ }
15
+ if ("anyOf" in schema && Array.isArray(schema.anyOf)) {
16
+ return schema.anyOf.map((s) => formatSchema(s)).join(" | ");
17
+ }
18
+ if ("allOf" in schema && Array.isArray(schema.allOf)) {
19
+ return schema.allOf.map((s) => formatSchema(s)).join(" & ");
20
+ }
21
+ if ("type" in schema && schema.type === "array") {
22
+ const items = "items" in schema ? formatSchema(schema.items) : "unknown";
23
+ return `${items}[]`;
24
+ }
25
+ if ("type" in schema && schema.type === "tuple" && "items" in schema) {
26
+ const items = schema.items.map(formatSchema).join(", ");
27
+ return `[${items}]`;
28
+ }
29
+ if ("type" in schema && schema.type === "object") {
30
+ if ("properties" in schema && schema.properties) {
31
+ const props = Object.entries(schema.properties).map(([k, v]) => `${k}: ${formatSchema(v)}`).join("; ");
32
+ return `{ ${props} }`;
33
+ }
34
+ return "object";
35
+ }
36
+ if ("type" in schema && typeof schema.type === "string") {
37
+ return schema.type;
38
+ }
39
+ }
40
+ return "unknown";
41
+ }
42
+ function formatTypeParameters(typeParams) {
43
+ if (!typeParams?.length)
44
+ return "";
45
+ const params = typeParams.map((tp) => {
46
+ let str = tp.name;
47
+ if (tp.constraint)
48
+ str += ` extends ${tp.constraint}`;
49
+ if (tp.default)
50
+ str += ` = ${tp.default}`;
51
+ return str;
52
+ });
53
+ return `<${params.join(", ")}>`;
54
+ }
55
+ function formatParameters(sig) {
56
+ if (!sig?.parameters?.length)
57
+ return "()";
58
+ const params = sig.parameters.map((p) => {
59
+ const optional = p.required === false ? "?" : "";
60
+ const rest = p.rest ? "..." : "";
61
+ const type = formatSchema(p.schema);
62
+ return `${rest}${p.name}${optional}: ${type}`;
63
+ });
64
+ return `(${params.join(", ")})`;
65
+ }
66
+ function formatReturnType(sig) {
67
+ if (!sig?.returns)
68
+ return "void";
69
+ return formatSchema(sig.returns.schema);
70
+ }
71
+ function buildSignatureString(exp, sigIndex = 0) {
72
+ const sig = exp.signatures?.[sigIndex];
73
+ const typeParams = formatTypeParameters(exp.typeParameters || sig?.typeParameters);
74
+ switch (exp.kind) {
75
+ case "function": {
76
+ const params = formatParameters(sig);
77
+ const returnType = formatReturnType(sig);
78
+ return `function ${exp.name}${typeParams}${params}: ${returnType}`;
79
+ }
80
+ case "class": {
81
+ const ext = exp.extends ? ` extends ${exp.extends}` : "";
82
+ const impl = exp.implements?.length ? ` implements ${exp.implements.join(", ")}` : "";
83
+ return `class ${exp.name}${typeParams}${ext}${impl}`;
84
+ }
85
+ case "interface": {
86
+ const ext = exp.extends ? ` extends ${exp.extends}` : "";
87
+ return `interface ${exp.name}${typeParams}${ext}`;
88
+ }
89
+ case "type": {
90
+ const typeValue = typeof exp.type === "string" ? exp.type : formatSchema(exp.schema);
91
+ return `type ${exp.name}${typeParams} = ${typeValue}`;
92
+ }
93
+ case "enum": {
94
+ return `enum ${exp.name}`;
95
+ }
96
+ case "variable": {
97
+ const typeValue = typeof exp.type === "string" ? exp.type : formatSchema(exp.schema);
98
+ return `const ${exp.name}: ${typeValue}`;
99
+ }
100
+ default:
101
+ return exp.name;
102
+ }
103
+ }
104
+
105
+ // src/components/headless/CollapsibleMethod.tsx
24
106
  import { jsxDEV } from "react/jsx-dev-runtime";
25
107
 
108
+ function formatReturnType2(returns) {
109
+ if (!returns)
110
+ return "void";
111
+ return formatSchema(returns.schema);
112
+ }
113
+ function formatParamPreview(params) {
114
+ if (!params || params.length === 0)
115
+ return "";
116
+ if (params.length === 1)
117
+ return params[0].name || "arg";
118
+ return `${params[0].name || "arg"}, ...`;
119
+ }
120
+ function CollapsibleMethod({
121
+ member,
122
+ defaultExpanded = false,
123
+ className,
124
+ renderHeader,
125
+ renderContent
126
+ }) {
127
+ const [expanded, setExpanded] = useState(defaultExpanded);
128
+ const sig = member.signatures?.[0];
129
+ const hasParams = sig?.parameters && sig.parameters.length > 0;
130
+ const visibility = member.visibility ?? "public";
131
+ const flags = member.flags;
132
+ const isStatic = flags?.static;
133
+ const isAsync = flags?.async;
134
+ const returnType = formatReturnType2(sig?.returns);
135
+ const paramPreview = formatParamPreview(sig?.parameters);
136
+ const toggle = () => setExpanded(!expanded);
137
+ useEffect(() => {
138
+ if (typeof window !== "undefined" && window.location.hash === `#${member.name}`) {
139
+ setExpanded(true);
140
+ }
141
+ }, [member.name]);
142
+ const badges = [];
143
+ if (visibility !== "public")
144
+ badges.push(visibility);
145
+ if (isStatic)
146
+ badges.push("static");
147
+ if (isAsync)
148
+ badges.push("async");
149
+ return /* @__PURE__ */ jsxDEV("div", {
150
+ id: member.name,
151
+ className,
152
+ "data-expanded": expanded,
153
+ children: [
154
+ renderHeader ? renderHeader(member, expanded, toggle) : /* @__PURE__ */ jsxDEV("button", {
155
+ type: "button",
156
+ onClick: toggle,
157
+ "data-header": true,
158
+ children: [
159
+ /* @__PURE__ */ jsxDEV("span", {
160
+ "data-name": true,
161
+ children: [
162
+ member.name,
163
+ /* @__PURE__ */ jsxDEV("span", {
164
+ "data-params": true,
165
+ children: [
166
+ "(",
167
+ paramPreview,
168
+ ")"
169
+ ]
170
+ }, undefined, true, undefined, this)
171
+ ]
172
+ }, undefined, true, undefined, this),
173
+ /* @__PURE__ */ jsxDEV("span", {
174
+ "data-return": true,
175
+ children: returnType
176
+ }, undefined, false, undefined, this),
177
+ badges.length > 0 && /* @__PURE__ */ jsxDEV("span", {
178
+ "data-badges": true,
179
+ children: badges.map((badge) => /* @__PURE__ */ jsxDEV("span", {
180
+ "data-badge": badge,
181
+ children: badge
182
+ }, badge, false, undefined, this))
183
+ }, undefined, false, undefined, this)
184
+ ]
185
+ }, undefined, true, undefined, this),
186
+ expanded && (renderContent ? renderContent(member) : /* @__PURE__ */ jsxDEV("div", {
187
+ "data-content": true,
188
+ children: [
189
+ member.description && /* @__PURE__ */ jsxDEV("p", {
190
+ children: member.description
191
+ }, undefined, false, undefined, this),
192
+ hasParams && /* @__PURE__ */ jsxDEV("div", {
193
+ "data-params-section": true,
194
+ children: [
195
+ /* @__PURE__ */ jsxDEV("h4", {
196
+ children: "Parameters"
197
+ }, undefined, false, undefined, this),
198
+ /* @__PURE__ */ jsxDEV("ul", {
199
+ children: sig.parameters.map((param, index) => /* @__PURE__ */ jsxDEV("li", {
200
+ children: [
201
+ /* @__PURE__ */ jsxDEV("code", {
202
+ children: [
203
+ param.name,
204
+ param.required === false && "?",
205
+ ": ",
206
+ formatSchema(param.schema)
207
+ ]
208
+ }, undefined, true, undefined, this),
209
+ param.description && /* @__PURE__ */ jsxDEV("span", {
210
+ children: param.description
211
+ }, undefined, false, undefined, this)
212
+ ]
213
+ }, param.name ?? index, true, undefined, this))
214
+ }, undefined, false, undefined, this)
215
+ ]
216
+ }, undefined, true, undefined, this),
217
+ sig?.returns && returnType !== "void" && /* @__PURE__ */ jsxDEV("div", {
218
+ "data-returns-section": true,
219
+ children: [
220
+ /* @__PURE__ */ jsxDEV("h4", {
221
+ children: "Returns"
222
+ }, undefined, false, undefined, this),
223
+ /* @__PURE__ */ jsxDEV("code", {
224
+ children: returnType
225
+ }, undefined, false, undefined, this),
226
+ sig.returns.description && /* @__PURE__ */ jsxDEV("p", {
227
+ children: sig.returns.description
228
+ }, undefined, false, undefined, this)
229
+ ]
230
+ }, undefined, true, undefined, this)
231
+ ]
232
+ }, undefined, true, undefined, this))
233
+ ]
234
+ }, undefined, true, undefined, this);
235
+ }
236
+ // src/components/headless/ExampleBlock.tsx
237
+ import { useState as useState2 } from "react";
238
+ import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
239
+
240
+ function getExampleCode(example) {
241
+ if (typeof example === "string")
242
+ return example;
243
+ return example.code;
244
+ }
245
+ function getExampleTitle(example) {
246
+ if (typeof example === "string")
247
+ return;
248
+ return example.title;
249
+ }
250
+ function getExampleLanguage(example) {
251
+ if (typeof example === "string")
252
+ return "typescript";
253
+ return example.language ?? "typescript";
254
+ }
255
+ function cleanCode(code) {
256
+ let cleaned = code.trim();
257
+ if (cleaned.startsWith("```")) {
258
+ const lines = cleaned.split(`
259
+ `);
260
+ lines.shift();
261
+ if (lines[lines.length - 1] === "```") {
262
+ lines.pop();
263
+ }
264
+ cleaned = lines.join(`
265
+ `);
266
+ }
267
+ return cleaned;
268
+ }
269
+ function ExampleBlock({
270
+ examples,
271
+ className,
272
+ renderExample
273
+ }) {
274
+ const [activeIndex, setActiveIndex] = useState2(0);
275
+ if (!examples?.length)
276
+ return null;
277
+ const showTabs = examples.length > 1;
278
+ const currentExample = examples[activeIndex];
279
+ const code = cleanCode(getExampleCode(currentExample));
280
+ if (renderExample) {
281
+ return /* @__PURE__ */ jsxDEV2("div", {
282
+ className,
283
+ children: [
284
+ showTabs && /* @__PURE__ */ jsxDEV2("div", {
285
+ "data-tabs": true,
286
+ children: examples.map((example, index) => /* @__PURE__ */ jsxDEV2("button", {
287
+ type: "button",
288
+ onClick: () => setActiveIndex(index),
289
+ "data-active": activeIndex === index,
290
+ children: getExampleTitle(example) ?? `Example ${index + 1}`
291
+ }, index, false, undefined, this))
292
+ }, undefined, false, undefined, this),
293
+ renderExample(currentExample, activeIndex)
294
+ ]
295
+ }, undefined, true, undefined, this);
296
+ }
297
+ return /* @__PURE__ */ jsxDEV2("div", {
298
+ className,
299
+ children: [
300
+ showTabs && /* @__PURE__ */ jsxDEV2("div", {
301
+ "data-tabs": true,
302
+ children: examples.map((example, index) => /* @__PURE__ */ jsxDEV2("button", {
303
+ type: "button",
304
+ onClick: () => setActiveIndex(index),
305
+ "data-active": activeIndex === index,
306
+ children: getExampleTitle(example) ?? `Example ${index + 1}`
307
+ }, index, false, undefined, this))
308
+ }, undefined, false, undefined, this),
309
+ /* @__PURE__ */ jsxDEV2("pre", {
310
+ children: /* @__PURE__ */ jsxDEV2("code", {
311
+ "data-language": getExampleLanguage(currentExample),
312
+ children: code
313
+ }, undefined, false, undefined, this)
314
+ }, undefined, false, undefined, this)
315
+ ]
316
+ }, undefined, true, undefined, this);
317
+ }
318
+ // src/components/headless/ExpandableProperty.tsx
319
+ import { useState as useState3 } from "react";
320
+ import { jsxDEV as jsxDEV3 } from "react/jsx-dev-runtime";
321
+
322
+ function getNestedProperties(schema) {
323
+ if (!schema || typeof schema !== "object")
324
+ return null;
325
+ const s = schema;
326
+ if (s.type === "object" && s.properties && typeof s.properties === "object") {
327
+ return s.properties;
328
+ }
329
+ return null;
330
+ }
331
+ function getRequiredFields(schema) {
332
+ if (!schema || typeof schema !== "object")
333
+ return [];
334
+ const s = schema;
335
+ if (Array.isArray(s.required)) {
336
+ return s.required;
337
+ }
338
+ return [];
339
+ }
340
+ function countProperties(schema) {
341
+ const props = getNestedProperties(schema);
342
+ return props ? Object.keys(props).length : 0;
343
+ }
344
+ function NestedProperty({
345
+ name,
346
+ schema,
347
+ required = false,
348
+ depth = 0
349
+ }) {
350
+ const [expanded, setExpanded] = useState3(false);
351
+ const type = formatSchema(schema);
352
+ const nestedProps = getNestedProperties(schema);
353
+ const nestedCount = countProperties(schema);
354
+ const hasNested = nestedCount > 0;
355
+ const schemaObj = schema;
356
+ const description = schemaObj?.description;
357
+ return /* @__PURE__ */ jsxDEV3("div", {
358
+ "data-property": name,
359
+ "data-depth": depth,
360
+ children: [
361
+ /* @__PURE__ */ jsxDEV3("div", {
362
+ "data-row": true,
363
+ children: [
364
+ /* @__PURE__ */ jsxDEV3("span", {
365
+ "data-name": true,
366
+ children: [
367
+ name,
368
+ !required && "?",
369
+ ":"
370
+ ]
371
+ }, undefined, true, undefined, this),
372
+ /* @__PURE__ */ jsxDEV3("span", {
373
+ "data-type": true,
374
+ children: hasNested ? "object" : type
375
+ }, undefined, false, undefined, this),
376
+ description && /* @__PURE__ */ jsxDEV3("span", {
377
+ "data-description": true,
378
+ children: description
379
+ }, undefined, false, undefined, this),
380
+ hasNested && /* @__PURE__ */ jsxDEV3("button", {
381
+ type: "button",
382
+ onClick: () => setExpanded(!expanded),
383
+ "data-expand": true,
384
+ children: [
385
+ nestedCount,
386
+ " properties"
387
+ ]
388
+ }, undefined, true, undefined, this)
389
+ ]
390
+ }, undefined, true, undefined, this),
391
+ hasNested && expanded && nestedProps && /* @__PURE__ */ jsxDEV3("div", {
392
+ "data-nested": true,
393
+ children: Object.entries(nestedProps).map(([propName, propSchema]) => /* @__PURE__ */ jsxDEV3(NestedProperty, {
394
+ name: propName,
395
+ schema: propSchema,
396
+ required: getRequiredFields(schema).includes(propName),
397
+ depth: depth + 1
398
+ }, propName, false, undefined, this))
399
+ }, undefined, false, undefined, this)
400
+ ]
401
+ }, undefined, true, undefined, this);
402
+ }
403
+ function ExpandableProperty({
404
+ param,
405
+ depth = 0,
406
+ className
407
+ }) {
408
+ const [expanded, setExpanded] = useState3(false);
409
+ const type = formatSchema(param.schema);
410
+ const isOptional = param.required === false;
411
+ const nestedProps = getNestedProperties(param.schema);
412
+ const nestedCount = countProperties(param.schema);
413
+ const hasNested = nestedCount > 0;
414
+ return /* @__PURE__ */ jsxDEV3("div", {
415
+ className,
416
+ "data-param": param.name,
417
+ "data-depth": depth,
418
+ children: [
419
+ /* @__PURE__ */ jsxDEV3("div", {
420
+ "data-row": true,
421
+ children: [
422
+ /* @__PURE__ */ jsxDEV3("span", {
423
+ "data-name": true,
424
+ children: [
425
+ param.name,
426
+ isOptional && "?",
427
+ ":"
428
+ ]
429
+ }, undefined, true, undefined, this),
430
+ /* @__PURE__ */ jsxDEV3("span", {
431
+ "data-type": true,
432
+ children: hasNested ? "object" : type
433
+ }, undefined, false, undefined, this),
434
+ param.description && /* @__PURE__ */ jsxDEV3("span", {
435
+ "data-description": true,
436
+ children: param.description
437
+ }, undefined, false, undefined, this),
438
+ hasNested && /* @__PURE__ */ jsxDEV3("button", {
439
+ type: "button",
440
+ onClick: () => setExpanded(!expanded),
441
+ "data-expand": true,
442
+ children: [
443
+ nestedCount,
444
+ " properties"
445
+ ]
446
+ }, undefined, true, undefined, this)
447
+ ]
448
+ }, undefined, true, undefined, this),
449
+ hasNested && expanded && nestedProps && /* @__PURE__ */ jsxDEV3("div", {
450
+ "data-nested": true,
451
+ children: Object.entries(nestedProps).map(([propName, propSchema]) => /* @__PURE__ */ jsxDEV3(NestedProperty, {
452
+ name: propName,
453
+ schema: propSchema,
454
+ required: getRequiredFields(param.schema).includes(propName),
455
+ depth: depth + 1
456
+ }, propName, false, undefined, this))
457
+ }, undefined, false, undefined, this)
458
+ ]
459
+ }, undefined, true, undefined, this);
460
+ }
461
+ // src/components/headless/MembersTable.tsx
462
+ import { jsxDEV as jsxDEV4 } from "react/jsx-dev-runtime";
463
+
464
+ function groupMembersByKind(members) {
465
+ const groups = {
466
+ constructors: [],
467
+ properties: [],
468
+ methods: [],
469
+ accessors: [],
470
+ other: []
471
+ };
472
+ for (const member of members) {
473
+ const kind = member.kind?.toLowerCase() ?? "other";
474
+ if (kind === "constructor") {
475
+ groups.constructors.push(member);
476
+ } else if (kind === "property" || kind === "field") {
477
+ groups.properties.push(member);
478
+ } else if (kind === "method" || kind === "function") {
479
+ groups.methods.push(member);
480
+ } else if (kind === "getter" || kind === "setter" || kind === "accessor") {
481
+ groups.accessors.push(member);
482
+ } else {
483
+ groups.other.push(member);
484
+ }
485
+ }
486
+ return groups;
487
+ }
488
+ function MemberRow({ member }) {
489
+ const visibility = member.visibility ?? "public";
490
+ const flags = member.flags;
491
+ const isStatic = flags?.static;
492
+ const isAbstract = flags?.abstract;
493
+ const isReadonly = flags?.readonly;
494
+ const type = formatSchema(member.schema);
495
+ const sig = member.signatures?.[0];
496
+ let signature = "";
497
+ if (sig) {
498
+ const params = sig.parameters?.map((p) => {
499
+ const optional = p.required === false ? "?" : "";
500
+ return `${p.name}${optional}: ${formatSchema(p.schema)}`;
501
+ }) ?? [];
502
+ const returnType = formatSchema(sig.returns?.schema) ?? "void";
503
+ signature = `(${params.join(", ")}): ${returnType}`;
504
+ }
505
+ const badges = [];
506
+ if (visibility !== "public")
507
+ badges.push(visibility);
508
+ if (isStatic)
509
+ badges.push("static");
510
+ if (isAbstract)
511
+ badges.push("abstract");
512
+ if (isReadonly)
513
+ badges.push("readonly");
514
+ return /* @__PURE__ */ jsxDEV4("div", {
515
+ "data-member": member.name,
516
+ children: [
517
+ /* @__PURE__ */ jsxDEV4("div", {
518
+ children: [
519
+ /* @__PURE__ */ jsxDEV4("code", {
520
+ children: [
521
+ member.name,
522
+ signature
523
+ ]
524
+ }, undefined, true, undefined, this),
525
+ badges.length > 0 && /* @__PURE__ */ jsxDEV4("span", {
526
+ children: badges.map((badge) => /* @__PURE__ */ jsxDEV4("span", {
527
+ "data-badge": badge,
528
+ children: badge
529
+ }, badge, false, undefined, this))
530
+ }, undefined, false, undefined, this)
531
+ ]
532
+ }, undefined, true, undefined, this),
533
+ !signature && type !== "unknown" && /* @__PURE__ */ jsxDEV4("code", {
534
+ children: type
535
+ }, undefined, false, undefined, this),
536
+ member.description && /* @__PURE__ */ jsxDEV4("p", {
537
+ children: member.description
538
+ }, undefined, false, undefined, this)
539
+ ]
540
+ }, undefined, true, undefined, this);
541
+ }
542
+ function MembersTable({
543
+ members,
544
+ className,
545
+ groupByKind = false,
546
+ renderMember
547
+ }) {
548
+ if (!members?.length)
549
+ return null;
550
+ if (!groupByKind) {
551
+ return /* @__PURE__ */ jsxDEV4("div", {
552
+ className,
553
+ children: members.map((member, index) => renderMember ? renderMember(member, index) : /* @__PURE__ */ jsxDEV4(MemberRow, {
554
+ member
555
+ }, member.name ?? index, false, undefined, this))
556
+ }, undefined, false, undefined, this);
557
+ }
558
+ const groups = groupMembersByKind(members);
559
+ return /* @__PURE__ */ jsxDEV4("div", {
560
+ className,
561
+ children: [
562
+ groups.constructors.length > 0 && /* @__PURE__ */ jsxDEV4("section", {
563
+ "data-group": "constructors",
564
+ children: [
565
+ /* @__PURE__ */ jsxDEV4("h4", {
566
+ children: "Constructor"
567
+ }, undefined, false, undefined, this),
568
+ groups.constructors.map((member, index) => renderMember ? renderMember(member, index) : /* @__PURE__ */ jsxDEV4(MemberRow, {
569
+ member
570
+ }, member.name ?? index, false, undefined, this))
571
+ ]
572
+ }, undefined, true, undefined, this),
573
+ groups.properties.length > 0 && /* @__PURE__ */ jsxDEV4("section", {
574
+ "data-group": "properties",
575
+ children: [
576
+ /* @__PURE__ */ jsxDEV4("h4", {
577
+ children: "Properties"
578
+ }, undefined, false, undefined, this),
579
+ groups.properties.map((member, index) => renderMember ? renderMember(member, index) : /* @__PURE__ */ jsxDEV4(MemberRow, {
580
+ member
581
+ }, member.name ?? index, false, undefined, this))
582
+ ]
583
+ }, undefined, true, undefined, this),
584
+ groups.methods.length > 0 && /* @__PURE__ */ jsxDEV4("section", {
585
+ "data-group": "methods",
586
+ children: [
587
+ /* @__PURE__ */ jsxDEV4("h4", {
588
+ children: "Methods"
589
+ }, undefined, false, undefined, this),
590
+ groups.methods.map((member, index) => renderMember ? renderMember(member, index) : /* @__PURE__ */ jsxDEV4(MemberRow, {
591
+ member
592
+ }, member.name ?? index, false, undefined, this))
593
+ ]
594
+ }, undefined, true, undefined, this),
595
+ groups.accessors.length > 0 && /* @__PURE__ */ jsxDEV4("section", {
596
+ "data-group": "accessors",
597
+ children: [
598
+ /* @__PURE__ */ jsxDEV4("h4", {
599
+ children: "Accessors"
600
+ }, undefined, false, undefined, this),
601
+ groups.accessors.map((member, index) => renderMember ? renderMember(member, index) : /* @__PURE__ */ jsxDEV4(MemberRow, {
602
+ member
603
+ }, member.name ?? index, false, undefined, this))
604
+ ]
605
+ }, undefined, true, undefined, this)
606
+ ]
607
+ }, undefined, true, undefined, this);
608
+ }
609
+ // src/components/headless/ParamTable.tsx
610
+ import { jsxDEV as jsxDEV5 } from "react/jsx-dev-runtime";
611
+
612
+ function isParameter(item) {
613
+ return "required" in item;
614
+ }
615
+ function ParamRow({ item, showRequired = true }) {
616
+ const name = item.name ?? "arg";
617
+ const type = formatSchema(item.schema);
618
+ const description = item.description ?? "";
619
+ const required = isParameter(item) ? item.required : true;
620
+ return /* @__PURE__ */ jsxDEV5("tr", {
621
+ children: [
622
+ /* @__PURE__ */ jsxDEV5("td", {
623
+ children: [
624
+ /* @__PURE__ */ jsxDEV5("code", {
625
+ children: name
626
+ }, undefined, false, undefined, this),
627
+ showRequired && required && /* @__PURE__ */ jsxDEV5("span", {
628
+ children: "*"
629
+ }, undefined, false, undefined, this),
630
+ showRequired && !required && /* @__PURE__ */ jsxDEV5("span", {
631
+ children: "?"
632
+ }, undefined, false, undefined, this)
633
+ ]
634
+ }, undefined, true, undefined, this),
635
+ /* @__PURE__ */ jsxDEV5("td", {
636
+ children: /* @__PURE__ */ jsxDEV5("code", {
637
+ children: type
638
+ }, undefined, false, undefined, this)
639
+ }, undefined, false, undefined, this),
640
+ /* @__PURE__ */ jsxDEV5("td", {
641
+ children: description
642
+ }, undefined, false, undefined, this)
643
+ ]
644
+ }, undefined, true, undefined, this);
645
+ }
646
+ function ParamTable({
647
+ items,
648
+ showRequired = true,
649
+ className,
650
+ renderRow
651
+ }) {
652
+ if (!items?.length)
653
+ return null;
654
+ return /* @__PURE__ */ jsxDEV5("table", {
655
+ className,
656
+ children: [
657
+ /* @__PURE__ */ jsxDEV5("thead", {
658
+ children: /* @__PURE__ */ jsxDEV5("tr", {
659
+ children: [
660
+ /* @__PURE__ */ jsxDEV5("th", {
661
+ children: "Name"
662
+ }, undefined, false, undefined, this),
663
+ /* @__PURE__ */ jsxDEV5("th", {
664
+ children: "Type"
665
+ }, undefined, false, undefined, this),
666
+ /* @__PURE__ */ jsxDEV5("th", {
667
+ children: "Description"
668
+ }, undefined, false, undefined, this)
669
+ ]
670
+ }, undefined, true, undefined, this)
671
+ }, undefined, false, undefined, this),
672
+ /* @__PURE__ */ jsxDEV5("tbody", {
673
+ children: items.map((item, index) => renderRow ? renderRow(item, index) : /* @__PURE__ */ jsxDEV5(ParamRow, {
674
+ item,
675
+ showRequired
676
+ }, item.name ?? index, false, undefined, this))
677
+ }, undefined, false, undefined, this)
678
+ ]
679
+ }, undefined, true, undefined, this);
680
+ }
681
+ // src/components/headless/Signature.tsx
682
+ import { jsxDEV as jsxDEV6 } from "react/jsx-dev-runtime";
683
+
684
+ function Signature({
685
+ export: exp,
686
+ signatureIndex = 0,
687
+ className,
688
+ children
689
+ }) {
690
+ const signature = buildSignatureString(exp, signatureIndex);
691
+ if (children) {
692
+ return children(signature);
693
+ }
694
+ return /* @__PURE__ */ jsxDEV6("code", {
695
+ className,
696
+ children: signature
697
+ }, undefined, false, undefined, this);
698
+ }
699
+ // src/components/headless/TypeTable.tsx
700
+ import { jsxDEV as jsxDEV7 } from "react/jsx-dev-runtime";
701
+
702
+ function isParameter2(item) {
703
+ return "required" in item;
704
+ }
705
+ function TypeTable({
706
+ items,
707
+ showRequired = true,
708
+ className,
709
+ renderRow
710
+ }) {
711
+ if (!items?.length)
712
+ return null;
713
+ return /* @__PURE__ */ jsxDEV7("table", {
714
+ className,
715
+ children: [
716
+ /* @__PURE__ */ jsxDEV7("thead", {
717
+ children: /* @__PURE__ */ jsxDEV7("tr", {
718
+ children: [
719
+ /* @__PURE__ */ jsxDEV7("th", {
720
+ children: "Name"
721
+ }, undefined, false, undefined, this),
722
+ /* @__PURE__ */ jsxDEV7("th", {
723
+ children: "Type"
724
+ }, undefined, false, undefined, this),
725
+ /* @__PURE__ */ jsxDEV7("th", {
726
+ children: "Description"
727
+ }, undefined, false, undefined, this)
728
+ ]
729
+ }, undefined, true, undefined, this)
730
+ }, undefined, false, undefined, this),
731
+ /* @__PURE__ */ jsxDEV7("tbody", {
732
+ children: items.map((item, index) => {
733
+ if (renderRow) {
734
+ return renderRow(item, index);
735
+ }
736
+ const name = item.name ?? `arg${index}`;
737
+ const type = formatSchema(item.schema);
738
+ const description = item.description ?? "";
739
+ const required = isParameter2(item) ? item.required : true;
740
+ return /* @__PURE__ */ jsxDEV7("tr", {
741
+ children: [
742
+ /* @__PURE__ */ jsxDEV7("td", {
743
+ children: [
744
+ /* @__PURE__ */ jsxDEV7("code", {
745
+ children: name
746
+ }, undefined, false, undefined, this),
747
+ showRequired && required && /* @__PURE__ */ jsxDEV7("span", {
748
+ children: "*"
749
+ }, undefined, false, undefined, this),
750
+ showRequired && !required && /* @__PURE__ */ jsxDEV7("span", {
751
+ children: "?"
752
+ }, undefined, false, undefined, this)
753
+ ]
754
+ }, undefined, true, undefined, this),
755
+ /* @__PURE__ */ jsxDEV7("td", {
756
+ children: /* @__PURE__ */ jsxDEV7("code", {
757
+ children: type
758
+ }, undefined, false, undefined, this)
759
+ }, undefined, false, undefined, this),
760
+ /* @__PURE__ */ jsxDEV7("td", {
761
+ children: description
762
+ }, undefined, false, undefined, this)
763
+ ]
764
+ }, name, true, undefined, this);
765
+ })
766
+ }, undefined, false, undefined, this)
767
+ ]
768
+ }, undefined, true, undefined, this);
769
+ }
770
+ // src/components/styled/ClassPage.tsx
771
+ import { jsxDEV as jsxDEV8 } from "react/jsx-dev-runtime";
772
+
26
773
  function PropertyItem({ member }) {
27
774
  const visibility = member.visibility ?? "public";
28
775
  const flags = member.flags;
29
776
  const isStatic = flags?.static;
30
777
  const isReadonly = flags?.readonly;
31
778
  const type = formatSchema(member.schema);
32
- return /* @__PURE__ */ jsxDEV("div", {
779
+ return /* @__PURE__ */ jsxDEV8("div", {
33
780
  className: "py-3 border-b border-border last:border-0",
34
781
  children: [
35
- /* @__PURE__ */ jsxDEV("div", {
782
+ /* @__PURE__ */ jsxDEV8("div", {
36
783
  className: "flex items-baseline gap-2 flex-wrap",
37
784
  children: [
38
- /* @__PURE__ */ jsxDEV("span", {
785
+ /* @__PURE__ */ jsxDEV8("span", {
39
786
  className: "font-semibold text-foreground",
40
787
  children: [
41
788
  member.name,
42
789
  ":"
43
790
  ]
44
791
  }, undefined, true, undefined, this),
45
- /* @__PURE__ */ jsxDEV("span", {
792
+ /* @__PURE__ */ jsxDEV8("span", {
46
793
  className: "text-muted-foreground font-mono text-sm",
47
794
  children: type
48
795
  }, undefined, false, undefined, this),
49
- visibility !== "public" && /* @__PURE__ */ jsxDEV("span", {
796
+ visibility !== "public" && /* @__PURE__ */ jsxDEV8("span", {
50
797
  className: "text-xs px-1.5 py-0.5 rounded bg-muted text-muted-foreground",
51
798
  children: visibility
52
799
  }, undefined, false, undefined, this),
53
- isStatic && /* @__PURE__ */ jsxDEV("span", {
800
+ isStatic && /* @__PURE__ */ jsxDEV8("span", {
54
801
  className: "text-xs px-1.5 py-0.5 rounded bg-blue-500/10 text-blue-600 dark:text-blue-400",
55
802
  children: "static"
56
803
  }, undefined, false, undefined, this),
57
- isReadonly && /* @__PURE__ */ jsxDEV("span", {
804
+ isReadonly && /* @__PURE__ */ jsxDEV8("span", {
58
805
  className: "text-xs px-1.5 py-0.5 rounded bg-purple-500/10 text-purple-600 dark:text-purple-400",
59
806
  children: "readonly"
60
807
  }, undefined, false, undefined, this)
61
808
  ]
62
809
  }, undefined, true, undefined, this),
63
- member.description && /* @__PURE__ */ jsxDEV("p", {
810
+ member.description && /* @__PURE__ */ jsxDEV8("p", {
64
811
  className: "text-sm text-muted-foreground mt-1",
65
812
  children: member.description
66
813
  }, undefined, false, undefined, this)
@@ -75,16 +822,16 @@ function ClassPage({ export: exp, spec, renderExample }) {
75
822
  const constructorSig = constructors[0]?.signatures?.[0];
76
823
  const constructorParams = constructorSig?.parameters ?? [];
77
824
  const exampleCode = hasExamples ? typeof exp.examples[0] === "string" ? exp.examples[0] : exp.examples[0].code : "";
78
- return /* @__PURE__ */ jsxDEV("div", {
825
+ return /* @__PURE__ */ jsxDEV8("div", {
79
826
  className: "space-y-8",
80
827
  children: [
81
- exp.description && /* @__PURE__ */ jsxDEV("p", {
828
+ exp.description && /* @__PURE__ */ jsxDEV8("p", {
82
829
  className: "text-muted-foreground text-lg leading-relaxed",
83
830
  children: exp.description
84
831
  }, undefined, false, undefined, this),
85
- /* @__PURE__ */ jsxDEV("div", {
832
+ /* @__PURE__ */ jsxDEV8("div", {
86
833
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
87
- children: /* @__PURE__ */ jsxDEV("code", {
834
+ children: /* @__PURE__ */ jsxDEV8("code", {
88
835
  className: "font-mono text-sm text-foreground whitespace-pre",
89
836
  children: [
90
837
  "class ",
@@ -94,50 +841,50 @@ function ClassPage({ export: exp, spec, renderExample }) {
94
841
  ]
95
842
  }, undefined, true, undefined, this)
96
843
  }, undefined, false, undefined, this),
97
- /* @__PURE__ */ jsxDEV("div", {
844
+ /* @__PURE__ */ jsxDEV8("div", {
98
845
  className: `grid gap-8 ${hasExamples ? "lg:grid-cols-2" : "grid-cols-1"}`,
99
846
  children: [
100
- /* @__PURE__ */ jsxDEV("div", {
847
+ /* @__PURE__ */ jsxDEV8("div", {
101
848
  className: "space-y-8",
102
849
  children: [
103
- constructorParams.length > 0 && /* @__PURE__ */ jsxDEV("section", {
850
+ constructorParams.length > 0 && /* @__PURE__ */ jsxDEV8("section", {
104
851
  children: [
105
- /* @__PURE__ */ jsxDEV("h3", {
852
+ /* @__PURE__ */ jsxDEV8("h3", {
106
853
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-4",
107
854
  children: "Constructor"
108
855
  }, undefined, false, undefined, this),
109
- /* @__PURE__ */ jsxDEV("div", {
856
+ /* @__PURE__ */ jsxDEV8("div", {
110
857
  className: "ml-2 border-l-2 border-border pl-4",
111
- children: constructorParams.map((param, index) => /* @__PURE__ */ jsxDEV(ExpandableProperty, {
858
+ children: constructorParams.map((param, index) => /* @__PURE__ */ jsxDEV8(ExpandableProperty, {
112
859
  param
113
860
  }, param.name ?? index, false, undefined, this))
114
861
  }, undefined, false, undefined, this)
115
862
  ]
116
863
  }, undefined, true, undefined, this),
117
- methods.length > 0 && /* @__PURE__ */ jsxDEV("section", {
864
+ methods.length > 0 && /* @__PURE__ */ jsxDEV8("section", {
118
865
  children: [
119
- /* @__PURE__ */ jsxDEV("h3", {
866
+ /* @__PURE__ */ jsxDEV8("h3", {
120
867
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-4",
121
868
  children: "Methods"
122
869
  }, undefined, false, undefined, this),
123
- /* @__PURE__ */ jsxDEV("div", {
870
+ /* @__PURE__ */ jsxDEV8("div", {
124
871
  className: "rounded-lg border border-border overflow-hidden",
125
- children: methods.map((member, index) => /* @__PURE__ */ jsxDEV(CollapsibleMethod, {
872
+ children: methods.map((member, index) => /* @__PURE__ */ jsxDEV8(CollapsibleMethod, {
126
873
  member,
127
874
  defaultExpanded: index === 0
128
875
  }, member.name ?? index, false, undefined, this))
129
876
  }, undefined, false, undefined, this)
130
877
  ]
131
878
  }, undefined, true, undefined, this),
132
- properties.length > 0 && /* @__PURE__ */ jsxDEV("section", {
879
+ properties.length > 0 && /* @__PURE__ */ jsxDEV8("section", {
133
880
  children: [
134
- /* @__PURE__ */ jsxDEV("h3", {
881
+ /* @__PURE__ */ jsxDEV8("h3", {
135
882
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-4",
136
883
  children: "Properties"
137
884
  }, undefined, false, undefined, this),
138
- /* @__PURE__ */ jsxDEV("div", {
885
+ /* @__PURE__ */ jsxDEV8("div", {
139
886
  className: "rounded-lg border border-border bg-card px-4",
140
- children: properties.map((member, index) => /* @__PURE__ */ jsxDEV(PropertyItem, {
887
+ children: properties.map((member, index) => /* @__PURE__ */ jsxDEV8(PropertyItem, {
141
888
  member
142
889
  }, member.name ?? index, false, undefined, this))
143
890
  }, undefined, false, undefined, this)
@@ -145,16 +892,16 @@ function ClassPage({ export: exp, spec, renderExample }) {
145
892
  }, undefined, true, undefined, this)
146
893
  ]
147
894
  }, undefined, true, undefined, this),
148
- hasExamples && /* @__PURE__ */ jsxDEV("div", {
895
+ hasExamples && /* @__PURE__ */ jsxDEV8("div", {
149
896
  className: "lg:sticky lg:top-20 lg:self-start",
150
897
  children: [
151
- /* @__PURE__ */ jsxDEV("h3", {
898
+ /* @__PURE__ */ jsxDEV8("h3", {
152
899
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-4",
153
900
  children: "Example"
154
901
  }, undefined, false, undefined, this),
155
- renderExample ? renderExample(exampleCode, `${exp.name.toLowerCase()}.ts`) : /* @__PURE__ */ jsxDEV("pre", {
902
+ renderExample ? renderExample(exampleCode, `${exp.name.toLowerCase()}.ts`) : /* @__PURE__ */ jsxDEV8("pre", {
156
903
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
157
- children: /* @__PURE__ */ jsxDEV("code", {
904
+ children: /* @__PURE__ */ jsxDEV8("code", {
158
905
  className: "font-mono text-sm text-foreground",
159
906
  children: exampleCode
160
907
  }, undefined, false, undefined, this)
@@ -168,36 +915,36 @@ function ClassPage({ export: exp, spec, renderExample }) {
168
915
  }
169
916
 
170
917
  // src/components/styled/EnumPage.tsx
171
- import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
918
+ import { jsxDEV as jsxDEV9 } from "react/jsx-dev-runtime";
172
919
 
173
920
  function EnumPage({ export: exp, spec, renderExample }) {
174
921
  const members = exp.members ?? [];
175
922
  const hasExamples = exp.examples && exp.examples.length > 0;
176
923
  const signature = buildSignatureString(exp);
177
- return /* @__PURE__ */ jsxDEV2("div", {
924
+ return /* @__PURE__ */ jsxDEV9("div", {
178
925
  className: "space-y-6",
179
926
  children: [
180
- exp.description && /* @__PURE__ */ jsxDEV2("p", {
927
+ exp.description && /* @__PURE__ */ jsxDEV9("p", {
181
928
  className: "text-muted-foreground text-base leading-relaxed",
182
929
  children: exp.description
183
930
  }, undefined, false, undefined, this),
184
- /* @__PURE__ */ jsxDEV2("section", {
931
+ /* @__PURE__ */ jsxDEV9("section", {
185
932
  children: [
186
- /* @__PURE__ */ jsxDEV2("h2", {
933
+ /* @__PURE__ */ jsxDEV9("h2", {
187
934
  className: "text-xl font-semibold mb-2",
188
935
  children: "Declaration"
189
936
  }, undefined, false, undefined, this),
190
- /* @__PURE__ */ jsxDEV2("div", {
937
+ /* @__PURE__ */ jsxDEV9("div", {
191
938
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
192
- children: /* @__PURE__ */ jsxDEV2("code", {
939
+ children: /* @__PURE__ */ jsxDEV9("code", {
193
940
  className: "font-mono text-sm text-foreground",
194
941
  children: signature
195
942
  }, undefined, false, undefined, this)
196
943
  }, undefined, false, undefined, this),
197
- exp.deprecated && /* @__PURE__ */ jsxDEV2("div", {
944
+ exp.deprecated && /* @__PURE__ */ jsxDEV9("div", {
198
945
  className: "mt-2 rounded-md bg-yellow-500/10 border border-yellow-500/20 px-3 py-2 text-sm text-yellow-600 dark:text-yellow-400",
199
946
  children: [
200
- /* @__PURE__ */ jsxDEV2("strong", {
947
+ /* @__PURE__ */ jsxDEV9("strong", {
201
948
  children: "Deprecated:"
202
949
  }, undefined, false, undefined, this),
203
950
  " This export is deprecated."
@@ -205,57 +952,57 @@ function EnumPage({ export: exp, spec, renderExample }) {
205
952
  }, undefined, true, undefined, this)
206
953
  ]
207
954
  }, undefined, true, undefined, this),
208
- members.length > 0 && /* @__PURE__ */ jsxDEV2("section", {
955
+ members.length > 0 && /* @__PURE__ */ jsxDEV9("section", {
209
956
  children: [
210
- /* @__PURE__ */ jsxDEV2("h2", {
957
+ /* @__PURE__ */ jsxDEV9("h2", {
211
958
  className: "text-xl font-semibold mb-2",
212
959
  children: "Members"
213
960
  }, undefined, false, undefined, this),
214
- /* @__PURE__ */ jsxDEV2("div", {
961
+ /* @__PURE__ */ jsxDEV9("div", {
215
962
  className: "overflow-x-auto",
216
- children: /* @__PURE__ */ jsxDEV2("table", {
963
+ children: /* @__PURE__ */ jsxDEV9("table", {
217
964
  className: "w-full text-sm border-collapse",
218
965
  children: [
219
- /* @__PURE__ */ jsxDEV2("thead", {
220
- children: /* @__PURE__ */ jsxDEV2("tr", {
966
+ /* @__PURE__ */ jsxDEV9("thead", {
967
+ children: /* @__PURE__ */ jsxDEV9("tr", {
221
968
  className: "border-b border-border",
222
969
  children: [
223
- /* @__PURE__ */ jsxDEV2("th", {
970
+ /* @__PURE__ */ jsxDEV9("th", {
224
971
  className: "text-left py-2 px-3 font-medium text-muted-foreground",
225
972
  children: "Name"
226
973
  }, undefined, false, undefined, this),
227
- /* @__PURE__ */ jsxDEV2("th", {
974
+ /* @__PURE__ */ jsxDEV9("th", {
228
975
  className: "text-left py-2 px-3 font-medium text-muted-foreground",
229
976
  children: "Value"
230
977
  }, undefined, false, undefined, this),
231
- /* @__PURE__ */ jsxDEV2("th", {
978
+ /* @__PURE__ */ jsxDEV9("th", {
232
979
  className: "text-left py-2 px-3 font-medium text-muted-foreground",
233
980
  children: "Description"
234
981
  }, undefined, false, undefined, this)
235
982
  ]
236
983
  }, undefined, true, undefined, this)
237
984
  }, undefined, false, undefined, this),
238
- /* @__PURE__ */ jsxDEV2("tbody", {
985
+ /* @__PURE__ */ jsxDEV9("tbody", {
239
986
  children: members.map((member, index) => {
240
987
  const value = member.schema !== undefined ? typeof member.schema === "object" && member.schema !== null ? member.schema.const ?? member.schema.default ?? "-" : member.schema : "-";
241
- return /* @__PURE__ */ jsxDEV2("tr", {
988
+ return /* @__PURE__ */ jsxDEV9("tr", {
242
989
  className: "border-b border-border last:border-0",
243
990
  children: [
244
- /* @__PURE__ */ jsxDEV2("td", {
991
+ /* @__PURE__ */ jsxDEV9("td", {
245
992
  className: "py-2 px-3 align-top",
246
- children: /* @__PURE__ */ jsxDEV2("code", {
993
+ children: /* @__PURE__ */ jsxDEV9("code", {
247
994
  className: "text-primary font-mono text-xs bg-secondary px-1.5 py-0.5 rounded",
248
995
  children: member.name
249
996
  }, undefined, false, undefined, this)
250
997
  }, undefined, false, undefined, this),
251
- /* @__PURE__ */ jsxDEV2("td", {
998
+ /* @__PURE__ */ jsxDEV9("td", {
252
999
  className: "py-2 px-3 align-top",
253
- children: /* @__PURE__ */ jsxDEV2("code", {
1000
+ children: /* @__PURE__ */ jsxDEV9("code", {
254
1001
  className: "font-mono text-xs text-muted-foreground",
255
1002
  children: String(value)
256
1003
  }, undefined, false, undefined, this)
257
1004
  }, undefined, false, undefined, this),
258
- /* @__PURE__ */ jsxDEV2("td", {
1005
+ /* @__PURE__ */ jsxDEV9("td", {
259
1006
  className: "py-2 px-3 align-top text-muted-foreground",
260
1007
  children: member.description ?? ""
261
1008
  }, undefined, false, undefined, this)
@@ -268,19 +1015,19 @@ function EnumPage({ export: exp, spec, renderExample }) {
268
1015
  }, undefined, false, undefined, this)
269
1016
  ]
270
1017
  }, undefined, true, undefined, this),
271
- hasExamples && /* @__PURE__ */ jsxDEV2("section", {
1018
+ hasExamples && /* @__PURE__ */ jsxDEV9("section", {
272
1019
  children: [
273
- /* @__PURE__ */ jsxDEV2("h2", {
1020
+ /* @__PURE__ */ jsxDEV9("h2", {
274
1021
  className: "text-xl font-semibold mb-2",
275
1022
  children: "Examples"
276
1023
  }, undefined, false, undefined, this),
277
1024
  exp.examples.map((example, index) => {
278
1025
  const code = typeof example === "string" ? example : example.code;
279
- return /* @__PURE__ */ jsxDEV2("div", {
1026
+ return /* @__PURE__ */ jsxDEV9("div", {
280
1027
  className: "mb-4",
281
- children: renderExample ? renderExample(code, `${exp.name.toLowerCase()}-${index}.ts`) : /* @__PURE__ */ jsxDEV2("pre", {
1028
+ children: renderExample ? renderExample(code, `${exp.name.toLowerCase()}-${index}.ts`) : /* @__PURE__ */ jsxDEV9("pre", {
282
1029
  className: "rounded-lg border border-border bg-secondary p-4 overflow-x-auto",
283
- children: /* @__PURE__ */ jsxDEV2("code", {
1030
+ children: /* @__PURE__ */ jsxDEV9("code", {
284
1031
  className: "font-mono text-sm text-foreground",
285
1032
  children: code
286
1033
  }, undefined, false, undefined, this)
@@ -294,7 +1041,7 @@ function EnumPage({ export: exp, spec, renderExample }) {
294
1041
  }
295
1042
 
296
1043
  // src/components/styled/FunctionPage.tsx
297
- import { jsxDEV as jsxDEV3 } from "react/jsx-dev-runtime";
1044
+ import { jsxDEV as jsxDEV10 } from "react/jsx-dev-runtime";
298
1045
 
299
1046
  function FunctionPage({
300
1047
  export: exp,
@@ -305,17 +1052,17 @@ function FunctionPage({
305
1052
  const hasExamples = exp.examples && exp.examples.length > 0;
306
1053
  const hasParams = sig?.parameters && sig.parameters.length > 0;
307
1054
  const exampleCode = hasExamples ? typeof exp.examples[0] === "string" ? exp.examples[0] : exp.examples[0].code : "";
308
- return /* @__PURE__ */ jsxDEV3("div", {
1055
+ return /* @__PURE__ */ jsxDEV10("div", {
309
1056
  className: "space-y-6 not-prose",
310
1057
  children: [
311
- exp.description && /* @__PURE__ */ jsxDEV3("p", {
1058
+ exp.description && /* @__PURE__ */ jsxDEV10("p", {
312
1059
  className: "text-muted-foreground leading-relaxed",
313
1060
  children: exp.description
314
1061
  }, undefined, false, undefined, this),
315
- sig?.returns && /* @__PURE__ */ jsxDEV3("p", {
1062
+ sig?.returns && /* @__PURE__ */ jsxDEV10("p", {
316
1063
  className: "text-muted-foreground text-sm",
317
1064
  children: [
318
- /* @__PURE__ */ jsxDEV3("span", {
1065
+ /* @__PURE__ */ jsxDEV10("span", {
319
1066
  className: "font-medium text-foreground",
320
1067
  children: "Returns:"
321
1068
  }, undefined, false, undefined, this),
@@ -323,7 +1070,7 @@ function FunctionPage({
323
1070
  sig.returns.description || `A ${formatSchema(sig.returns.schema)}`
324
1071
  ]
325
1072
  }, undefined, true, undefined, this),
326
- /* @__PURE__ */ jsxDEV3("div", {
1073
+ /* @__PURE__ */ jsxDEV10("div", {
327
1074
  className: "not-prose",
328
1075
  style: {
329
1076
  display: hasExamples ? "grid" : "block",
@@ -332,37 +1079,37 @@ function FunctionPage({
332
1079
  alignItems: "start"
333
1080
  },
334
1081
  children: [
335
- /* @__PURE__ */ jsxDEV3("div", {
1082
+ /* @__PURE__ */ jsxDEV10("div", {
336
1083
  className: "space-y-6",
337
- children: hasParams && /* @__PURE__ */ jsxDEV3("div", {
1084
+ children: hasParams && /* @__PURE__ */ jsxDEV10("div", {
338
1085
  children: [
339
- /* @__PURE__ */ jsxDEV3("h3", {
1086
+ /* @__PURE__ */ jsxDEV10("h3", {
340
1087
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-4",
341
1088
  children: "Parameters"
342
1089
  }, undefined, false, undefined, this),
343
- /* @__PURE__ */ jsxDEV3("div", {
1090
+ /* @__PURE__ */ jsxDEV10("div", {
344
1091
  className: "space-y-3 rounded-lg border border-border bg-card/50 p-4",
345
- children: sig.parameters.map((param, index) => /* @__PURE__ */ jsxDEV3("div", {
1092
+ children: sig.parameters.map((param, index) => /* @__PURE__ */ jsxDEV10("div", {
346
1093
  className: "border-b border-border last:border-0 pb-3 last:pb-0",
347
1094
  children: [
348
- /* @__PURE__ */ jsxDEV3("div", {
1095
+ /* @__PURE__ */ jsxDEV10("div", {
349
1096
  className: "flex items-baseline gap-2 mb-1",
350
1097
  children: [
351
- /* @__PURE__ */ jsxDEV3("span", {
1098
+ /* @__PURE__ */ jsxDEV10("span", {
352
1099
  className: "font-mono text-sm text-foreground",
353
1100
  children: param.name
354
1101
  }, undefined, false, undefined, this),
355
- param.required !== false && /* @__PURE__ */ jsxDEV3("span", {
1102
+ param.required !== false && /* @__PURE__ */ jsxDEV10("span", {
356
1103
  className: "text-[10px] font-semibold px-1.5 py-0.5 rounded border border-border bg-muted text-muted-foreground uppercase tracking-wide",
357
1104
  children: "Required"
358
1105
  }, undefined, false, undefined, this)
359
1106
  ]
360
1107
  }, undefined, true, undefined, this),
361
- /* @__PURE__ */ jsxDEV3("div", {
1108
+ /* @__PURE__ */ jsxDEV10("div", {
362
1109
  className: "text-sm text-muted-foreground font-mono",
363
1110
  children: formatSchema(param.schema)
364
1111
  }, undefined, false, undefined, this),
365
- param.description && /* @__PURE__ */ jsxDEV3("p", {
1112
+ param.description && /* @__PURE__ */ jsxDEV10("p", {
366
1113
  className: "text-sm text-muted-foreground mt-2",
367
1114
  children: param.description
368
1115
  }, undefined, false, undefined, this)
@@ -372,16 +1119,16 @@ function FunctionPage({
372
1119
  ]
373
1120
  }, undefined, true, undefined, this)
374
1121
  }, undefined, false, undefined, this),
375
- hasExamples && /* @__PURE__ */ jsxDEV3("div", {
1122
+ hasExamples && /* @__PURE__ */ jsxDEV10("div", {
376
1123
  style: { position: "sticky", top: "5rem" },
377
1124
  children: [
378
- /* @__PURE__ */ jsxDEV3("h3", {
1125
+ /* @__PURE__ */ jsxDEV10("h3", {
379
1126
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-4",
380
1127
  children: "Example"
381
1128
  }, undefined, false, undefined, this),
382
- renderExample ? renderExample(exampleCode, `${exp.name.toLowerCase().replace(/[^a-z0-9]/g, "-")}.ts`) : /* @__PURE__ */ jsxDEV3("pre", {
1129
+ renderExample ? renderExample(exampleCode, `${exp.name.toLowerCase().replace(/[^a-z0-9]/g, "-")}.ts`) : /* @__PURE__ */ jsxDEV10("pre", {
383
1130
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
384
- children: /* @__PURE__ */ jsxDEV3("code", {
1131
+ children: /* @__PURE__ */ jsxDEV10("code", {
385
1132
  className: "font-mono text-sm text-foreground",
386
1133
  children: exampleCode
387
1134
  }, undefined, false, undefined, this)
@@ -395,7 +1142,7 @@ function FunctionPage({
395
1142
  }
396
1143
 
397
1144
  // src/components/styled/InterfacePage.tsx
398
- import { jsxDEV as jsxDEV4 } from "react/jsx-dev-runtime";
1145
+ import { jsxDEV as jsxDEV11 } from "react/jsx-dev-runtime";
399
1146
 
400
1147
  function InterfacePage({
401
1148
  export: exp,
@@ -406,30 +1153,30 @@ function InterfacePage({
406
1153
  const methods = exp.members?.filter((m) => m.kind === "method" || m.kind === "function");
407
1154
  const hasExamples = exp.examples && exp.examples.length > 0;
408
1155
  const signature = buildSignatureString(exp);
409
- return /* @__PURE__ */ jsxDEV4("div", {
1156
+ return /* @__PURE__ */ jsxDEV11("div", {
410
1157
  className: "space-y-6",
411
1158
  children: [
412
- exp.description && /* @__PURE__ */ jsxDEV4("p", {
1159
+ exp.description && /* @__PURE__ */ jsxDEV11("p", {
413
1160
  className: "text-muted-foreground text-base leading-relaxed",
414
1161
  children: exp.description
415
1162
  }, undefined, false, undefined, this),
416
- /* @__PURE__ */ jsxDEV4("section", {
1163
+ /* @__PURE__ */ jsxDEV11("section", {
417
1164
  children: [
418
- /* @__PURE__ */ jsxDEV4("h2", {
1165
+ /* @__PURE__ */ jsxDEV11("h2", {
419
1166
  className: "text-xl font-semibold mb-2",
420
1167
  children: "Declaration"
421
1168
  }, undefined, false, undefined, this),
422
- /* @__PURE__ */ jsxDEV4("div", {
1169
+ /* @__PURE__ */ jsxDEV11("div", {
423
1170
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
424
- children: /* @__PURE__ */ jsxDEV4("code", {
1171
+ children: /* @__PURE__ */ jsxDEV11("code", {
425
1172
  className: "font-mono text-sm text-foreground",
426
1173
  children: signature
427
1174
  }, undefined, false, undefined, this)
428
1175
  }, undefined, false, undefined, this),
429
- exp.deprecated && /* @__PURE__ */ jsxDEV4("div", {
1176
+ exp.deprecated && /* @__PURE__ */ jsxDEV11("div", {
430
1177
  className: "mt-2 rounded-md bg-yellow-500/10 border border-yellow-500/20 px-3 py-2 text-sm text-yellow-600 dark:text-yellow-400",
431
1178
  children: [
432
- /* @__PURE__ */ jsxDEV4("strong", {
1179
+ /* @__PURE__ */ jsxDEV11("strong", {
433
1180
  children: "Deprecated:"
434
1181
  }, undefined, false, undefined, this),
435
1182
  " This export is deprecated."
@@ -437,70 +1184,70 @@ function InterfacePage({
437
1184
  }, undefined, true, undefined, this)
438
1185
  ]
439
1186
  }, undefined, true, undefined, this),
440
- exp.extends && /* @__PURE__ */ jsxDEV4("section", {
1187
+ exp.extends && /* @__PURE__ */ jsxDEV11("section", {
441
1188
  children: [
442
- /* @__PURE__ */ jsxDEV4("h2", {
1189
+ /* @__PURE__ */ jsxDEV11("h2", {
443
1190
  className: "text-xl font-semibold mb-2",
444
1191
  children: "Extends"
445
1192
  }, undefined, false, undefined, this),
446
- /* @__PURE__ */ jsxDEV4("div", {
1193
+ /* @__PURE__ */ jsxDEV11("div", {
447
1194
  className: "rounded-lg border border-border bg-card p-4",
448
- children: /* @__PURE__ */ jsxDEV4("code", {
1195
+ children: /* @__PURE__ */ jsxDEV11("code", {
449
1196
  className: "font-mono text-sm text-primary",
450
1197
  children: exp.extends
451
1198
  }, undefined, false, undefined, this)
452
1199
  }, undefined, false, undefined, this)
453
1200
  ]
454
1201
  }, undefined, true, undefined, this),
455
- properties && properties.length > 0 && /* @__PURE__ */ jsxDEV4("section", {
1202
+ properties && properties.length > 0 && /* @__PURE__ */ jsxDEV11("section", {
456
1203
  children: [
457
- /* @__PURE__ */ jsxDEV4("h2", {
1204
+ /* @__PURE__ */ jsxDEV11("h2", {
458
1205
  className: "text-xl font-semibold mb-2",
459
1206
  children: "Properties"
460
1207
  }, undefined, false, undefined, this),
461
- /* @__PURE__ */ jsxDEV4("div", {
1208
+ /* @__PURE__ */ jsxDEV11("div", {
462
1209
  className: "overflow-x-auto",
463
- children: /* @__PURE__ */ jsxDEV4("table", {
1210
+ children: /* @__PURE__ */ jsxDEV11("table", {
464
1211
  className: "w-full text-sm border-collapse",
465
1212
  children: [
466
- /* @__PURE__ */ jsxDEV4("thead", {
467
- children: /* @__PURE__ */ jsxDEV4("tr", {
1213
+ /* @__PURE__ */ jsxDEV11("thead", {
1214
+ children: /* @__PURE__ */ jsxDEV11("tr", {
468
1215
  className: "border-b border-border",
469
1216
  children: [
470
- /* @__PURE__ */ jsxDEV4("th", {
1217
+ /* @__PURE__ */ jsxDEV11("th", {
471
1218
  className: "text-left py-2 px-3 font-medium text-muted-foreground",
472
1219
  children: "Name"
473
1220
  }, undefined, false, undefined, this),
474
- /* @__PURE__ */ jsxDEV4("th", {
1221
+ /* @__PURE__ */ jsxDEV11("th", {
475
1222
  className: "text-left py-2 px-3 font-medium text-muted-foreground",
476
1223
  children: "Type"
477
1224
  }, undefined, false, undefined, this),
478
- /* @__PURE__ */ jsxDEV4("th", {
1225
+ /* @__PURE__ */ jsxDEV11("th", {
479
1226
  className: "text-left py-2 px-3 font-medium text-muted-foreground",
480
1227
  children: "Description"
481
1228
  }, undefined, false, undefined, this)
482
1229
  ]
483
1230
  }, undefined, true, undefined, this)
484
1231
  }, undefined, false, undefined, this),
485
- /* @__PURE__ */ jsxDEV4("tbody", {
486
- children: properties.map((prop, index) => /* @__PURE__ */ jsxDEV4("tr", {
1232
+ /* @__PURE__ */ jsxDEV11("tbody", {
1233
+ children: properties.map((prop, index) => /* @__PURE__ */ jsxDEV11("tr", {
487
1234
  className: "border-b border-border last:border-0",
488
1235
  children: [
489
- /* @__PURE__ */ jsxDEV4("td", {
1236
+ /* @__PURE__ */ jsxDEV11("td", {
490
1237
  className: "py-2 px-3 align-top",
491
- children: /* @__PURE__ */ jsxDEV4("code", {
1238
+ children: /* @__PURE__ */ jsxDEV11("code", {
492
1239
  className: "text-primary font-mono text-xs bg-secondary px-1.5 py-0.5 rounded",
493
1240
  children: prop.name
494
1241
  }, undefined, false, undefined, this)
495
1242
  }, undefined, false, undefined, this),
496
- /* @__PURE__ */ jsxDEV4("td", {
1243
+ /* @__PURE__ */ jsxDEV11("td", {
497
1244
  className: "py-2 px-3 align-top",
498
- children: /* @__PURE__ */ jsxDEV4("code", {
1245
+ children: /* @__PURE__ */ jsxDEV11("code", {
499
1246
  className: "font-mono text-xs text-muted-foreground",
500
1247
  children: formatSchema(prop.schema)
501
1248
  }, undefined, false, undefined, this)
502
1249
  }, undefined, false, undefined, this),
503
- /* @__PURE__ */ jsxDEV4("td", {
1250
+ /* @__PURE__ */ jsxDEV11("td", {
504
1251
  className: "py-2 px-3 align-top text-muted-foreground",
505
1252
  children: prop.description ?? ""
506
1253
  }, undefined, false, undefined, this)
@@ -512,22 +1259,22 @@ function InterfacePage({
512
1259
  }, undefined, false, undefined, this)
513
1260
  ]
514
1261
  }, undefined, true, undefined, this),
515
- methods && methods.length > 0 && /* @__PURE__ */ jsxDEV4("section", {
1262
+ methods && methods.length > 0 && /* @__PURE__ */ jsxDEV11("section", {
516
1263
  children: [
517
- /* @__PURE__ */ jsxDEV4("h2", {
1264
+ /* @__PURE__ */ jsxDEV11("h2", {
518
1265
  className: "text-xl font-semibold mb-2",
519
1266
  children: "Methods"
520
1267
  }, undefined, false, undefined, this),
521
- /* @__PURE__ */ jsxDEV4("div", {
1268
+ /* @__PURE__ */ jsxDEV11("div", {
522
1269
  className: "space-y-4",
523
1270
  children: methods.map((method, index) => {
524
1271
  const sig = method.signatures?.[0];
525
1272
  const params = sig?.parameters ?? [];
526
1273
  const returnType = formatSchema(sig?.returns?.schema);
527
- return /* @__PURE__ */ jsxDEV4("div", {
1274
+ return /* @__PURE__ */ jsxDEV11("div", {
528
1275
  className: "rounded-lg border border-border p-4",
529
1276
  children: [
530
- /* @__PURE__ */ jsxDEV4("code", {
1277
+ /* @__PURE__ */ jsxDEV11("code", {
531
1278
  className: "font-mono text-sm text-primary",
532
1279
  children: [
533
1280
  method.name,
@@ -541,7 +1288,7 @@ function InterfacePage({
541
1288
  returnType
542
1289
  ]
543
1290
  }, undefined, true, undefined, this),
544
- method.description && /* @__PURE__ */ jsxDEV4("p", {
1291
+ method.description && /* @__PURE__ */ jsxDEV11("p", {
545
1292
  className: "text-sm text-muted-foreground mt-2",
546
1293
  children: method.description
547
1294
  }, undefined, false, undefined, this)
@@ -551,25 +1298,25 @@ function InterfacePage({
551
1298
  }, undefined, false, undefined, this)
552
1299
  ]
553
1300
  }, undefined, true, undefined, this),
554
- hasExamples && /* @__PURE__ */ jsxDEV4("section", {
1301
+ hasExamples && /* @__PURE__ */ jsxDEV11("section", {
555
1302
  children: [
556
- /* @__PURE__ */ jsxDEV4("h2", {
1303
+ /* @__PURE__ */ jsxDEV11("h2", {
557
1304
  className: "text-xl font-semibold mb-2",
558
1305
  children: "Examples"
559
1306
  }, undefined, false, undefined, this),
560
1307
  exp.examples.map((example, index) => {
561
1308
  const code = typeof example === "string" ? example : example.code;
562
1309
  const title = typeof example === "string" ? undefined : example.title;
563
- return /* @__PURE__ */ jsxDEV4("div", {
1310
+ return /* @__PURE__ */ jsxDEV11("div", {
564
1311
  className: "mb-4",
565
1312
  children: [
566
- title && /* @__PURE__ */ jsxDEV4("h3", {
1313
+ title && /* @__PURE__ */ jsxDEV11("h3", {
567
1314
  className: "text-sm font-medium mb-2",
568
1315
  children: title
569
1316
  }, undefined, false, undefined, this),
570
- renderExample ? renderExample(code, `${exp.name.toLowerCase()}-${index}.ts`) : /* @__PURE__ */ jsxDEV4("pre", {
1317
+ renderExample ? renderExample(code, `${exp.name.toLowerCase()}-${index}.ts`) : /* @__PURE__ */ jsxDEV11("pre", {
571
1318
  className: "rounded-lg border border-border bg-secondary p-4 overflow-x-auto",
572
- children: /* @__PURE__ */ jsxDEV4("code", {
1319
+ children: /* @__PURE__ */ jsxDEV11("code", {
573
1320
  className: "font-mono text-sm text-foreground",
574
1321
  children: code
575
1322
  }, undefined, false, undefined, this)
@@ -584,7 +1331,7 @@ function InterfacePage({
584
1331
  }
585
1332
 
586
1333
  // src/components/styled/VariablePage.tsx
587
- import { jsxDEV as jsxDEV5 } from "react/jsx-dev-runtime";
1334
+ import { jsxDEV as jsxDEV12 } from "react/jsx-dev-runtime";
588
1335
 
589
1336
  function VariablePage({
590
1337
  export: exp,
@@ -594,16 +1341,16 @@ function VariablePage({
594
1341
  const typeValue = typeof exp.type === "string" ? exp.type : formatSchema(exp.schema);
595
1342
  const hasExamples = exp.examples && exp.examples.length > 0;
596
1343
  const exampleCode = hasExamples ? typeof exp.examples[0] === "string" ? exp.examples[0] : exp.examples[0].code : "";
597
- return /* @__PURE__ */ jsxDEV5("div", {
1344
+ return /* @__PURE__ */ jsxDEV12("div", {
598
1345
  className: "space-y-8",
599
1346
  children: [
600
- exp.description && /* @__PURE__ */ jsxDEV5("p", {
1347
+ exp.description && /* @__PURE__ */ jsxDEV12("p", {
601
1348
  className: "text-muted-foreground text-lg leading-relaxed",
602
1349
  children: exp.description
603
1350
  }, undefined, false, undefined, this),
604
- /* @__PURE__ */ jsxDEV5("div", {
1351
+ /* @__PURE__ */ jsxDEV12("div", {
605
1352
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
606
- children: /* @__PURE__ */ jsxDEV5("code", {
1353
+ children: /* @__PURE__ */ jsxDEV12("code", {
607
1354
  className: "font-mono text-sm text-foreground whitespace-pre",
608
1355
  children: [
609
1356
  "const ",
@@ -613,29 +1360,29 @@ function VariablePage({
613
1360
  ]
614
1361
  }, undefined, true, undefined, this)
615
1362
  }, undefined, false, undefined, this),
616
- exp.deprecated && /* @__PURE__ */ jsxDEV5("div", {
1363
+ exp.deprecated && /* @__PURE__ */ jsxDEV12("div", {
617
1364
  className: "rounded-md bg-yellow-500/10 border border-yellow-500/20 px-3 py-2 text-sm text-yellow-600 dark:text-yellow-400",
618
1365
  children: [
619
- /* @__PURE__ */ jsxDEV5("strong", {
1366
+ /* @__PURE__ */ jsxDEV12("strong", {
620
1367
  children: "Deprecated:"
621
1368
  }, undefined, false, undefined, this),
622
1369
  " This export is deprecated."
623
1370
  ]
624
1371
  }, undefined, true, undefined, this),
625
- /* @__PURE__ */ jsxDEV5("div", {
1372
+ /* @__PURE__ */ jsxDEV12("div", {
626
1373
  className: `grid gap-8 ${hasExamples ? "lg:grid-cols-2" : "grid-cols-1"}`,
627
1374
  children: [
628
- /* @__PURE__ */ jsxDEV5("div", {
1375
+ /* @__PURE__ */ jsxDEV12("div", {
629
1376
  className: "space-y-6",
630
- children: /* @__PURE__ */ jsxDEV5("div", {
1377
+ children: /* @__PURE__ */ jsxDEV12("div", {
631
1378
  children: [
632
- /* @__PURE__ */ jsxDEV5("h3", {
1379
+ /* @__PURE__ */ jsxDEV12("h3", {
633
1380
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-3",
634
1381
  children: "Type"
635
1382
  }, undefined, false, undefined, this),
636
- /* @__PURE__ */ jsxDEV5("div", {
1383
+ /* @__PURE__ */ jsxDEV12("div", {
637
1384
  className: "rounded-lg border border-border bg-card p-4",
638
- children: /* @__PURE__ */ jsxDEV5("code", {
1385
+ children: /* @__PURE__ */ jsxDEV12("code", {
639
1386
  className: "font-mono text-sm text-primary",
640
1387
  children: typeValue
641
1388
  }, undefined, false, undefined, this)
@@ -643,18 +1390,18 @@ function VariablePage({
643
1390
  ]
644
1391
  }, undefined, true, undefined, this)
645
1392
  }, undefined, false, undefined, this),
646
- hasExamples && /* @__PURE__ */ jsxDEV5("div", {
1393
+ hasExamples && /* @__PURE__ */ jsxDEV12("div", {
647
1394
  children: [
648
- /* @__PURE__ */ jsxDEV5("h3", {
1395
+ /* @__PURE__ */ jsxDEV12("h3", {
649
1396
  className: "text-sm font-semibold uppercase tracking-wide text-muted-foreground mb-3",
650
1397
  children: [
651
1398
  exp.name,
652
1399
  " usage"
653
1400
  ]
654
1401
  }, undefined, true, undefined, this),
655
- renderExample ? renderExample(exampleCode, `${exp.name.toLowerCase()}.ts`) : /* @__PURE__ */ jsxDEV5("pre", {
1402
+ renderExample ? renderExample(exampleCode, `${exp.name.toLowerCase()}.ts`) : /* @__PURE__ */ jsxDEV12("pre", {
656
1403
  className: "rounded-lg border border-border bg-muted/30 p-4 overflow-x-auto",
657
- children: /* @__PURE__ */ jsxDEV5("code", {
1404
+ children: /* @__PURE__ */ jsxDEV12("code", {
658
1405
  className: "font-mono text-sm text-foreground",
659
1406
  children: exampleCode
660
1407
  }, undefined, false, undefined, this)
@@ -668,16 +1415,16 @@ function VariablePage({
668
1415
  }
669
1416
 
670
1417
  // src/components/styled/APIPage.tsx
671
- import { jsxDEV as jsxDEV6 } from "react/jsx-dev-runtime";
1418
+ import { jsxDEV as jsxDEV13 } from "react/jsx-dev-runtime";
672
1419
 
673
1420
  function NotFound({ id }) {
674
- return /* @__PURE__ */ jsxDEV6("div", {
1421
+ return /* @__PURE__ */ jsxDEV13("div", {
675
1422
  className: "rounded-lg border border-border bg-card p-6 text-center",
676
- children: /* @__PURE__ */ jsxDEV6("p", {
1423
+ children: /* @__PURE__ */ jsxDEV13("p", {
677
1424
  className: "text-muted-foreground",
678
1425
  children: [
679
1426
  "Export ",
680
- /* @__PURE__ */ jsxDEV6("code", {
1427
+ /* @__PURE__ */ jsxDEV13("code", {
681
1428
  className: "font-mono text-primary",
682
1429
  children: id
683
1430
  }, undefined, false, undefined, this),
@@ -687,17 +1434,17 @@ function NotFound({ id }) {
687
1434
  }, undefined, false, undefined, this);
688
1435
  }
689
1436
  function NoSpec() {
690
- return /* @__PURE__ */ jsxDEV6("div", {
1437
+ return /* @__PURE__ */ jsxDEV13("div", {
691
1438
  className: "rounded-lg border border-red-500/20 bg-red-500/10 p-6 text-center",
692
- children: /* @__PURE__ */ jsxDEV6("p", {
1439
+ children: /* @__PURE__ */ jsxDEV13("p", {
693
1440
  className: "text-red-600 dark:text-red-400",
694
1441
  children: [
695
1442
  "No spec provided. Pass either ",
696
- /* @__PURE__ */ jsxDEV6("code", {
1443
+ /* @__PURE__ */ jsxDEV13("code", {
697
1444
  children: "spec"
698
1445
  }, undefined, false, undefined, this),
699
1446
  " or ",
700
- /* @__PURE__ */ jsxDEV6("code", {
1447
+ /* @__PURE__ */ jsxDEV13("code", {
701
1448
  children: "instance"
702
1449
  }, undefined, false, undefined, this),
703
1450
  " prop."
@@ -708,35 +1455,35 @@ function NoSpec() {
708
1455
  function APIPage({ spec, instance, id, renderExample }) {
709
1456
  const resolvedSpec = spec ?? instance?.spec;
710
1457
  if (!resolvedSpec) {
711
- return /* @__PURE__ */ jsxDEV6(NoSpec, {}, undefined, false, undefined, this);
1458
+ return /* @__PURE__ */ jsxDEV13(NoSpec, {}, undefined, false, undefined, this);
712
1459
  }
713
1460
  const exp = resolvedSpec.exports.find((e) => e.id === id);
714
1461
  if (!exp) {
715
- return /* @__PURE__ */ jsxDEV6(NotFound, {
1462
+ return /* @__PURE__ */ jsxDEV13(NotFound, {
716
1463
  id
717
1464
  }, undefined, false, undefined, this);
718
1465
  }
719
1466
  const pageProps = { export: exp, spec: resolvedSpec, renderExample };
720
1467
  switch (exp.kind) {
721
1468
  case "function":
722
- return /* @__PURE__ */ jsxDEV6(FunctionPage, {
1469
+ return /* @__PURE__ */ jsxDEV13(FunctionPage, {
723
1470
  ...pageProps
724
1471
  }, undefined, false, undefined, this);
725
1472
  case "class":
726
- return /* @__PURE__ */ jsxDEV6(ClassPage, {
1473
+ return /* @__PURE__ */ jsxDEV13(ClassPage, {
727
1474
  ...pageProps
728
1475
  }, undefined, false, undefined, this);
729
1476
  case "interface":
730
1477
  case "type":
731
- return /* @__PURE__ */ jsxDEV6(InterfacePage, {
1478
+ return /* @__PURE__ */ jsxDEV13(InterfacePage, {
732
1479
  ...pageProps
733
1480
  }, undefined, false, undefined, this);
734
1481
  case "enum":
735
- return /* @__PURE__ */ jsxDEV6(EnumPage, {
1482
+ return /* @__PURE__ */ jsxDEV13(EnumPage, {
736
1483
  ...pageProps
737
1484
  }, undefined, false, undefined, this);
738
1485
  default:
739
- return /* @__PURE__ */ jsxDEV6(VariablePage, {
1486
+ return /* @__PURE__ */ jsxDEV13(VariablePage, {
740
1487
  ...pageProps
741
1488
  }, undefined, false, undefined, this);
742
1489
  }