@clarify-labs/renderer 0.10.3 → 0.11.1

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.
Files changed (83) hide show
  1. package/output/{ClarifyShell-UsefuuLS.cjs → ClarifyShell-C2XnkFQ6.cjs} +119 -100
  2. package/output/ClarifyShell-C2XnkFQ6.cjs.map +1 -0
  3. package/output/{ClarifyShell-Cq5Af46F.js → ClarifyShell-CwRtof1h.js} +119 -100
  4. package/output/ClarifyShell-CwRtof1h.js.map +1 -0
  5. package/output/{MermaidViewer-Db7qsyVk.cjs → MermaidViewer-CTvMCE19.cjs} +2 -2
  6. package/output/{MermaidViewer-Db7qsyVk.cjs.map → MermaidViewer-CTvMCE19.cjs.map} +1 -1
  7. package/output/{MermaidViewer-Bc9H25yK.js → MermaidViewer-CwkiQ2gO.js} +2 -2
  8. package/output/{MermaidViewer-Bc9H25yK.js.map → MermaidViewer-CwkiQ2gO.js.map} +1 -1
  9. package/output/{OpenApiOperation-BZWeCbvy.js → OpenApiOperation-CFo6_otd.js} +1964 -292
  10. package/output/OpenApiOperation-CFo6_otd.js.map +1 -0
  11. package/output/{OpenApiOperation-DbZjxIuj.cjs → OpenApiOperation-D1WNrj5X.cjs} +1967 -289
  12. package/output/OpenApiOperation-D1WNrj5X.cjs.map +1 -0
  13. package/output/{PageActions-BQeEmXbT.js → PageActions-3eo05fb_.js} +60 -19
  14. package/output/PageActions-3eo05fb_.js.map +1 -0
  15. package/output/{PageActions-Dg1l9KB1.cjs → PageActions-Lp_NeIKr.cjs} +59 -18
  16. package/output/PageActions-Lp_NeIKr.cjs.map +1 -0
  17. package/output/{SearchDialog-B67VA0Ut.js → SearchDialog-BvCBIFqs.js} +3 -3
  18. package/output/{SearchDialog-B67VA0Ut.js.map → SearchDialog-BvCBIFqs.js.map} +1 -1
  19. package/output/{SearchDialog-DjKvqN7p.cjs → SearchDialog-CM9DrE2Y.cjs} +3 -3
  20. package/output/{SearchDialog-DjKvqN7p.cjs.map → SearchDialog-CM9DrE2Y.cjs.map} +1 -1
  21. package/output/app/PageFooter.d.ts +1 -1
  22. package/output/client.cjs +3 -3
  23. package/output/client.js +3 -3
  24. package/output/components/Tooltip.d.ts +1 -0
  25. package/output/core/i18n.d.ts +1 -1
  26. package/output/core/types.d.ts +37 -19
  27. package/output/{i18n-Bqth9d6Q.js → i18n-BxXpRSFX.js} +106 -2
  28. package/output/i18n-BxXpRSFX.js.map +1 -0
  29. package/output/{i18n-C-fReCj-.cjs → i18n-DsjZ51U1.cjs} +106 -2
  30. package/output/i18n-DsjZ51U1.cjs.map +1 -0
  31. package/output/index.cjs +26 -5
  32. package/output/index.cjs.map +1 -1
  33. package/output/index.d.ts +3 -3
  34. package/output/index.js +26 -6
  35. package/output/index.js.map +1 -1
  36. package/output/mdx/components.d.ts +2 -1
  37. package/output/openapi/components/EndpointMethodBadge.d.ts +6 -0
  38. package/output/openapi/components/EndpointSections.d.ts +2 -2
  39. package/output/openapi/components/ExamplePanels.d.ts +2 -2
  40. package/output/openapi/components/InlineListbox.d.ts +14 -0
  41. package/output/openapi/components/OpenApiAuthPanel.d.ts +12 -0
  42. package/output/openapi/components/OpenApiOperation.d.ts +1 -9
  43. package/output/openapi/components/OpenApiOperation.state.d.ts +4 -2
  44. package/output/openapi/components/OpenApiRequest.d.ts +18 -0
  45. package/output/openapi/components/OpenApiRequestBodyEditor.d.ts +14 -0
  46. package/output/openapi/components/OpenApiRequestFields.d.ts +25 -0
  47. package/output/openapi/components/OpenApiResponseViewer.d.ts +14 -0
  48. package/output/openapi/components/SendRequestButton.d.ts +9 -0
  49. package/output/openapi/components/helpers.d.ts +6 -1
  50. package/output/openapi/components/useOpenApiRequestState.d.ts +48 -0
  51. package/output/openapi/entry.d.ts +2 -0
  52. package/output/openapi/index.d.ts +2 -2
  53. package/output/openapi/lib/api-exchange-code.d.ts +8 -0
  54. package/output/openapi/lib/api-exchange.d.ts +30 -0
  55. package/output/openapi/lib/api-request.d.ts +25 -0
  56. package/output/openapi/lib/helpers.d.ts +8 -0
  57. package/output/openapi/lib/request-code.d.ts +2 -2
  58. package/output/openapi/lib/request-parameters.d.ts +5 -0
  59. package/output/openapi/store.d.ts +10 -0
  60. package/output/openapi/types.d.ts +6 -0
  61. package/output/preview.cjs +46 -40
  62. package/output/preview.cjs.map +1 -1
  63. package/output/preview.js +46 -40
  64. package/output/preview.js.map +1 -1
  65. package/output/{render-Dc9wxg_r.cjs → render-CKG4X-me.cjs} +2 -2
  66. package/output/{render-Dc9wxg_r.cjs.map → render-CKG4X-me.cjs.map} +1 -1
  67. package/output/{render-aS-w4fK4.js → render-vlp3hwW3.js} +2 -2
  68. package/output/{render-aS-w4fK4.js.map → render-vlp3hwW3.js.map} +1 -1
  69. package/output/renderer.css +630 -152
  70. package/output/server.cjs +2 -2
  71. package/output/server.js +2 -2
  72. package/output/theme/ThemeEditor.d.ts +8 -4
  73. package/output/theme/variables.d.ts +8 -4
  74. package/package.json +2 -1
  75. package/output/ClarifyShell-Cq5Af46F.js.map +0 -1
  76. package/output/ClarifyShell-UsefuuLS.cjs.map +0 -1
  77. package/output/OpenApiOperation-BZWeCbvy.js.map +0 -1
  78. package/output/OpenApiOperation-DbZjxIuj.cjs.map +0 -1
  79. package/output/PageActions-BQeEmXbT.js.map +0 -1
  80. package/output/PageActions-Dg1l9KB1.cjs.map +0 -1
  81. package/output/core/index.d.ts +0 -3
  82. package/output/i18n-Bqth9d6Q.js.map +0 -1
  83. package/output/i18n-C-fReCj-.cjs.map +0 -1
@@ -1,6 +1,6 @@
1
1
  const require_rolldown_runtime = require("./rolldown-runtime-DakpK96I.cjs");
2
- const require_i18n = require("./i18n-C-fReCj-.cjs");
3
- const require_PageActions = require("./PageActions-Dg1l9KB1.cjs");
2
+ const require_i18n = require("./i18n-DsjZ51U1.cjs");
3
+ const require_PageActions = require("./PageActions-Lp_NeIKr.cjs");
4
4
  let clsx = require("clsx");
5
5
  clsx = require_rolldown_runtime.__toESM(clsx, 1);
6
6
  let react = require("react");
@@ -124,26 +124,42 @@ function safeDecodeURIComponent(value) {
124
124
  var clarify_default = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='279px'%20height='200px'%20viewBox='0%200%20279%20200'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3ctitle%3eclarify%3c/title%3e%3cg%20id='页面-1'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='clarify'%20transform='translate(-0,%200.0054)'%3e%3cpath%20d='M44.867217,0.0054376148%20C130.715579,1.00591567%20200,70.9091172%20200,156.994562%20L199.986321,155.127494%20C199.384888,180.009127%20179.026368,199.994562%20154,199.994562%20L46,199.994562%20C20.5949015,199.994562%200,179.399661%200,153.994562%20L0,45.9945624%20C0,21.0975659%2019.7793434,0.820282524%2044.4815926,0.0191499894%20Z'%20fill='%2300D492'%3e%3c/path%3e%3cpath%20d='M123.867217,0.0054376148%20C209.715579,1.00591567%20279,70.9091172%20279,156.994562%20L278.986321,155.127494%20C278.384888,180.009127%20258.026368,199.994562%20233,199.994562%20L125,199.994562%20C99.5949015,199.994562%2079,179.399661%2079,153.994562%20L79,45.9945624%20C79,21.0975659%2098.7793434,0.820282524%20123.481593,0.0191499894%20Z'%20id='clarify-right'%20fill-opacity='0.6'%20fill='%2300F6C9'%20transform='translate(179,%20100)%20rotate(-90)%20translate(-179,%20-100)'%3e%3c/path%3e%3cpath%20d='M199.979267,154.416906%20L199.984438,155.157125%20L199.962366,155.872459%20C198.977251,180.406837%20178.776104,199.994562%20154,199.994562%20L124.372438,199.994125%20L124.249053,199.994081%20C99.6939678,199.603921%2079.8122712,179.973634%2079.01915,155.518407%20L79.0054376,155.132783%20C79.5830823,105.566626%20103.129768,61.5221348%20139.498462,33.1463428%20C175.69419,61.3871018%20199.186123,105.143863%20199.979267,154.416906%20Z'%20id='形状结合'%20fill='%2300F692'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e";
125
125
  //#endregion
126
126
  //#region source/app/BuiltWithClarify.tsx
127
+ var CLARIFY_TRACKING_URL = "https://clarify.pub/api/track";
127
128
  function BuiltWithClarify() {
128
129
  const t = require_i18n.useBuiltInText();
129
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("a", {
130
- href: "https://clarify.pub",
131
- target: "_blank",
132
- rel: "noreferrer",
133
- "aria-label": t("builtWith.label"),
134
- className: "clarify-built-with inline-flex items-center gap-1.5 rounded-full px-2 py-1 font-medium no-underline transition",
135
- children: [
136
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t("builtWith.prefix") }),
137
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("img", {
138
- src: clarify_default,
139
- alt: "",
140
- className: "clarify-built-with-logo h-3.5 w-auto flex-none object-contain"
141
- }),
142
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
143
- className: "clarify-built-with-brand font-semibold",
144
- children: "Clarify"
145
- })
146
- ]
130
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
131
+ className: "clarify-built-with inline-flex items-center gap-1.5",
132
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("iframe", {
133
+ tabIndex: -1,
134
+ "aria-hidden": "true",
135
+ title: t("builtWith.label"),
136
+ src: CLARIFY_TRACKING_URL,
137
+ style: {
138
+ position: "absolute",
139
+ width: 0,
140
+ height: 0,
141
+ border: 0,
142
+ overflow: "hidden"
143
+ }
144
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("a", {
145
+ href: "https://clarify.pub",
146
+ target: "_blank",
147
+ rel: "noreferrer",
148
+ "aria-label": t("builtWith.label"),
149
+ className: "clarify-built-with inline-flex items-center gap-1.5 rounded-full px-2 py-1 font-medium no-underline transition",
150
+ children: [
151
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t("builtWith.prefix") }),
152
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("img", {
153
+ src: clarify_default,
154
+ alt: "",
155
+ className: "clarify-built-with-logo h-3.5 w-auto flex-none object-contain"
156
+ }),
157
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
158
+ className: "clarify-built-with-brand font-semibold",
159
+ children: "Clarify"
160
+ })
161
+ ]
162
+ })]
147
163
  });
148
164
  }
149
165
  //#endregion
@@ -361,7 +377,7 @@ function PageBanner(props) {
361
377
  const { currentLocale, onDismiss } = props;
362
378
  const config = require_i18n.useConfig();
363
379
  const banner = config.banner;
364
- const content = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.i18n?.defaultLocale) : "";
380
+ const content = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.locales?.default) : "";
365
381
  const storageKey = (0, react.useMemo)(() => {
366
382
  if (!banner || !content) return "";
367
383
  return bannerStorageKey(config, content);
@@ -381,7 +397,7 @@ function PageBanner(props) {
381
397
  if (!content) return null;
382
398
  if (dismissed) return null;
383
399
  const link = banner.link;
384
- const linkLabel = link ? require_PageActions.resolveLocalizedText(link.label, currentLocale, config.i18n?.defaultLocale) : "";
400
+ const linkLabel = link ? require_PageActions.resolveLocalizedText(link.label, currentLocale, config.locales?.default) : "";
385
401
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
386
402
  className: "clarify-banner relative flex h-12 items-center border-b border-(--clarify-ui-accent-border) bg-(--clarify-ui-accent-background) px-4 text-sm text-(--clarify-ui-text) dark:border-white/10",
387
403
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
@@ -414,17 +430,17 @@ function PageBanner(props) {
414
430
  //#endregion
415
431
  //#region source/app/PageFooter.tsx
416
432
  function localeForPath(config, pathname) {
417
- const i18n = config.i18n;
418
- if (!i18n) return void 0;
433
+ const locales = config.locales;
434
+ if (!locales) return void 0;
419
435
  const firstSegment = pathname.split("/").filter(Boolean)[0];
420
- return i18n.locales.find((locale) => locale.code === firstSegment)?.code ?? i18n.defaultLocale;
436
+ return locales.locales.find((locale) => locale.code === firstSegment)?.code ?? locales.default;
421
437
  }
422
438
  function FooterLink(arg0) {
423
439
  const { link, locale, config } = arg0;
424
440
  const external = link.external ?? require_PageActions.isExternalHref(link.href);
425
441
  const href = external ? link.href : require_PageActions.localizeHref(link.href, config, locale);
426
442
  const className = "clarify-footer-link no-underline transition";
427
- const label = require_PageActions.resolveLocalizedText(link.label, locale, config.i18n?.defaultLocale);
443
+ const label = require_PageActions.resolveLocalizedText(link.label, locale, config.locales?.default);
428
444
  if (external) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
429
445
  href,
430
446
  target: "_blank",
@@ -454,25 +470,22 @@ function PageFooter() {
454
470
  const footer = config.footer;
455
471
  const links = footer?.links ?? [];
456
472
  const socials = Object.entries(footer?.socials ?? {});
457
- const copyright = footer?.copyright ? require_PageActions.resolveLocalizedText(footer.copyright, locale, config.i18n?.defaultLocale) : void 0;
458
- if (!Boolean(copyright || links.length > 0 || socials.length > 0)) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("footer", {
459
- "aria-hidden": "true",
460
- className: "clarify-page-footer mt-16 w-full border-t border-(--clarify-theme-tokens-colors-border) pt-8 lg:mt-24"
461
- });
473
+ const copyright = footer?.copyright ? require_PageActions.resolveLocalizedText(footer.copyright, locale, config.locales?.default) : void 0;
474
+ if (!Boolean(copyright || links.length > 0 || socials.length > 0)) return null;
462
475
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("footer", {
463
- className: "clarify-page-footer mt-16 flex w-full flex-col gap-4 border-t border-(--clarify-theme-tokens-colors-border) py-8 lg:mt-24",
476
+ className: "clarify-page-footer w-full",
464
477
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
465
- className: (0, clsx.default)("clarify-footer-content flex flex-col items-end gap-3 text-right", "sm:items-start sm:text-left"),
478
+ className: (0, clsx.default)("clarify-footer-content flex flex-col items-start gap-2.5 text-left"),
466
479
  children: [copyright ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
467
480
  className: "clarify-footer-copyright m-0",
468
481
  children: copyright
469
482
  }) : null, links.length > 0 || socials.length > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
470
- className: "clarify-footer-links flex flex-wrap justify-end gap-x-4 gap-y-2 sm:justify-start",
483
+ className: "clarify-footer-links flex flex-wrap justify-start gap-x-4 gap-y-2",
471
484
  children: [links.map((link) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FooterLink, {
472
485
  link,
473
486
  locale,
474
487
  config
475
- }, `${link.href}-${require_PageActions.resolveLocalizedText(link.label, locale, config.i18n?.defaultLocale)}`)), socials.map(([name, href]) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SocialLink, {
488
+ }, `${link.href}-${require_PageActions.resolveLocalizedText(link.label, locale, config.locales?.default)}`)), socials.map(([name, href]) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SocialLink, {
476
489
  name,
477
490
  href
478
491
  }, name))]
@@ -495,40 +508,42 @@ function PageNavigation(arg0) {
495
508
  const previous = pageRoutes[currentIndex - 1];
496
509
  const next = pageRoutes[currentIndex + 1];
497
510
  if (!previous && !next) return null;
511
+ const hasBothDirections = Boolean(previous && next);
498
512
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("nav", {
499
- className: "clarify-page-navigation mt-6 grid gap-3 @3xl:grid-cols-2",
513
+ className: (0, clsx.default)("clarify-page-navigation mt-12 grid border-t border-(--clarify-theme-tokens-colors-border)", hasBothDirections && "@3xl:grid-cols-2"),
500
514
  "aria-label": t("navigation.previousNext"),
501
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
515
+ children: [previous ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
502
516
  direction: "previous",
503
- route: previous
504
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
517
+ route: previous,
518
+ separated: hasBothDirections
519
+ }) : null, next ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
505
520
  direction: "next",
506
- route: next
507
- })]
521
+ route: next,
522
+ separated: hasBothDirections
523
+ }) : null]
508
524
  });
509
525
  }
510
526
  function PageNavigationLink(arg0) {
511
- const { direction, route } = arg0;
527
+ const { direction, route, separated } = arg0;
512
528
  const t = require_i18n.useBuiltInText();
513
- if (!route) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { className: "hidden @3xl:block" });
514
529
  const isNext = direction === "next";
515
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_router_dom.Link, {
530
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_router_dom.Link, {
516
531
  to: require_PageActions.normalizeRoutePath(route.path),
517
- className: (0, clsx.default)("group flex min-w-0 items-center gap-3 rounded-lg border border-(--clarify-theme-tokens-colors-border) px-4 py-3 no-underline transition hover:border-(--clarify-theme-tokens-colors-primary) hover:bg-(--clarify-ui-hover-background)", isNext && "@3xl:justify-end @3xl:text-right"),
518
- children: [
519
- !isNext ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronLeft, { className: "h-3.5 w-3.5 shrink-0 text-(--clarify-theme-tokens-colors-muted) transition group-hover:text-(--clarify-theme-tokens-colors-primary)" }) : null,
520
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
521
- className: "min-w-0 flex-1",
522
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
523
- className: "clarify-page-navigation-label block font-medium uppercase tracking-wide text-(--clarify-theme-tokens-colors-muted)",
524
- children: isNext ? t("navigation.next") : t("navigation.previous")
525
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
526
- className: "clarify-page-navigation-title mt-0.5 block truncate font-semibold text-(--clarify-theme-tokens-colors-foreground)",
527
- children: route.title
528
- })]
529
- }),
530
- isNext ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronRight, { className: "h-3.5 w-3.5 shrink-0 text-(--clarify-theme-tokens-colors-muted) transition group-hover:text-(--clarify-theme-tokens-colors-primary)" }) : null
531
- ]
532
+ className: (0, clsx.default)("group flex min-w-0 py-5 no-underline outline-none focus-visible:bg-(--clarify-ui-hover-background)", !isNext && "@3xl:pr-8", isNext && "@3xl:justify-end @3xl:pl-8 @3xl:text-right", isNext && separated && "border-t border-(--clarify-theme-tokens-colors-border) @3xl:border-t-0 @3xl:border-l"),
533
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
534
+ className: (0, clsx.default)("min-w-0", isNext && "ml-auto"),
535
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
536
+ className: (0, clsx.default)("clarify-page-navigation-label flex items-center gap-1.5 text-xs/5 font-medium text-(--clarify-theme-tokens-colors-muted)", isNext && "justify-end"),
537
+ children: [
538
+ !isNext ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronLeft, { className: "size-3.5 transition-transform group-hover:-translate-x-0.5" }) : null,
539
+ isNext ? t("navigation.next") : t("navigation.previous"),
540
+ isNext ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronRight, { className: "size-3.5 transition-transform group-hover:translate-x-0.5" }) : null
541
+ ]
542
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
543
+ className: "clarify-page-navigation-title mt-1 block truncate text-base/6 font-semibold text-(--clarify-theme-tokens-colors-foreground) transition-colors group-hover:text-(--clarify-theme-tokens-colors-primary)",
544
+ children: route.title
545
+ })]
546
+ })
532
547
  });
533
548
  }
534
549
  //#endregion
@@ -771,19 +786,19 @@ function scrollToHash(hash) {
771
786
  });
772
787
  }
773
788
  function explicitLocaleForPath(config, pathname) {
774
- const i18n = config.i18n;
775
- if (!i18n) return void 0;
789
+ const locales = config.locales;
790
+ if (!locales) return void 0;
776
791
  const firstSegment = pathname.split("/").filter(Boolean)[0];
777
- return i18n.locales.find((locale) => locale.code === firstSegment)?.code;
792
+ return locales.locales.find((locale) => locale.code === firstSegment)?.code;
778
793
  }
779
794
  function fallbackLocale(config) {
780
- return config.i18n?.defaultLocale;
795
+ return config.locales?.default;
781
796
  }
782
797
  function storedLocaleForConfig(config) {
783
- return require_PageActions.getStoredLocalePreference(config.i18n?.locales.map((locale) => locale.code));
798
+ return require_PageActions.getStoredLocalePreference(config.locales?.locales.map((locale) => locale.code));
784
799
  }
785
800
  function isDefaultLocale(config, locale) {
786
- return Boolean(locale && config.i18n?.defaultLocale === locale);
801
+ return Boolean(locale && config.locales?.default === locale);
787
802
  }
788
803
  function hasPath(nodes, pathname, locale) {
789
804
  return nodes.some((node) => require_PageActions.isSameRoutePath(node.path, pathname, locale) || hasPath(node.children ?? [], pathname, locale));
@@ -833,7 +848,7 @@ function useRouteState(config, routes, navigation, pathname) {
833
848
  explicitLocale,
834
849
  storedLocale,
835
850
  currentLocale,
836
- currentLocaleConfig: config.i18n?.locales.find((locale) => locale.code === currentLocale),
851
+ currentLocaleConfig: config.locales?.locales.find((locale) => locale.code === currentLocale),
837
852
  notFoundRoute: currentRoute ? void 0 : notFoundRouteForPath(routes, pathname, currentLocale),
838
853
  currentNavigation: navigationForLocale(navigation, currentLocale, pathname),
839
854
  sections: sectionsForRoute(currentRoute)
@@ -857,7 +872,7 @@ function useStoredBannerDismissed(storageKey) {
857
872
  }
858
873
  function useBannerState(config, currentLocale) {
859
874
  const banner = config.banner;
860
- const bannerContent = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.i18n?.defaultLocale) : "";
875
+ const bannerContent = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.locales?.default) : "";
861
876
  const bannerStorageKey = banner && bannerContent ? `clarify:banner:dismissed:${config.title}:${bannerContent}` : void 0;
862
877
  const storedBannerDismissed = useStoredBannerDismissed(banner?.dismissible ? bannerStorageKey : void 0);
863
878
  const [dismissedBannerKey, setDismissedBannerKey] = (0, react.useState)();
@@ -1090,17 +1105,19 @@ function AppShell(arg0) {
1090
1105
  });
1091
1106
  }
1092
1107
  function renderFooter() {
1093
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
1094
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, { name: "page.footer.before" }),
1095
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, {
1096
- name: "page.footer.replace",
1097
- default: DefaultFooterComponent
1098
- }),
1099
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1100
- className: "flex justify-end",
1108
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1109
+ className: "clarify-page-footer-region mt-8 grid gap-5 border-t border-(--clarify-theme-tokens-colors-border) pt-6 sm:grid-cols-[minmax(0,1fr)_auto] sm:items-end",
1110
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1111
+ className: "clarify-page-footer-slot min-w-0",
1112
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, { name: "page.footer.before" }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, {
1113
+ name: "page.footer.replace",
1114
+ default: DefaultFooterComponent
1115
+ })]
1116
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1117
+ className: "clarify-page-attribution flex justify-end sm:self-end",
1101
1118
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BuiltWithClarify, {})
1102
- })
1103
- ] });
1119
+ })]
1120
+ });
1104
1121
  }
1105
1122
  function renderContent() {
1106
1123
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
@@ -1843,8 +1860,7 @@ function createRandomTheme() {
1843
1860
  colors: createRandomThemeColors(selection),
1844
1861
  radius: { ...selection.radius }
1845
1862
  },
1846
- layout: { maxWidth: selection.maxWidth },
1847
- editor: false
1863
+ layout: { maxWidth: selection.maxWidth }
1848
1864
  };
1849
1865
  }
1850
1866
  //#endregion
@@ -1855,42 +1871,47 @@ var themePresets = {
1855
1871
  preset: "default",
1856
1872
  tokens: {
1857
1873
  colors: {
1858
- primary: "#047857",
1859
- accent: "#0D9488",
1874
+ primary: {
1875
+ light: "#047857",
1876
+ dark: "#34d399"
1877
+ },
1878
+ accent: {
1879
+ light: "#0f766e",
1880
+ dark: "#5eead4"
1881
+ },
1860
1882
  background: {
1861
- light: "#ffffff",
1862
- dark: "#09090b"
1883
+ light: "#f8fafc",
1884
+ dark: "#0a0a0b"
1863
1885
  },
1864
1886
  foreground: {
1865
- light: "#111827",
1866
- dark: "#ffffff"
1887
+ light: "#172033",
1888
+ dark: "#f4f4f5"
1867
1889
  },
1868
1890
  surface: {
1869
1891
  light: "#ffffff",
1870
1892
  dark: "#18181b"
1871
1893
  },
1872
1894
  muted: {
1873
- light: "#64748b",
1895
+ light: "#667085",
1874
1896
  dark: "#a1a1aa"
1875
1897
  },
1876
1898
  border: {
1877
- light: "rgb(15 23 42 / 0.12)",
1878
- dark: "rgb(255 255 255 / 0.1)"
1899
+ light: "rgb(15 23 42 / 0.11)",
1900
+ dark: "rgb(255 255 255 / 0.11)"
1879
1901
  },
1880
1902
  codeBackground: {
1881
- light: "#f6fbf8",
1882
- dark: "#18181b"
1903
+ light: "#f1f5f3",
1904
+ dark: "#171719"
1883
1905
  }
1884
1906
  },
1885
1907
  radius: {
1886
1908
  sm: "6px",
1887
- md: "10px",
1888
- lg: "14px",
1889
- xl: "18px"
1909
+ md: "8px",
1910
+ lg: "12px",
1911
+ xl: "16px"
1890
1912
  }
1891
1913
  },
1892
- layout: { maxWidth: "82rem" },
1893
- editor: false
1914
+ layout: { maxWidth: "82rem" }
1894
1915
  },
1895
1916
  base: {
1896
1917
  preset: "base",
@@ -1930,8 +1951,7 @@ var themePresets = {
1930
1951
  xl: "16px"
1931
1952
  }
1932
1953
  },
1933
- layout: { maxWidth: "80rem" },
1934
- editor: false
1954
+ layout: { maxWidth: "80rem" }
1935
1955
  }
1936
1956
  };
1937
1957
  function cloneThemeColorValue(value) {
@@ -1953,8 +1973,7 @@ function cloneTheme(theme) {
1953
1973
  },
1954
1974
  radius: { ...theme.tokens.radius }
1955
1975
  },
1956
- layout: { ...theme.layout },
1957
- editor: theme.editor
1976
+ layout: { ...theme.layout }
1958
1977
  };
1959
1978
  }
1960
1979
  function isModeColorValue(value) {
@@ -2556,4 +2575,4 @@ Object.defineProperty(exports, "useSlot", {
2556
2575
  }
2557
2576
  });
2558
2577
 
2559
- //# sourceMappingURL=ClarifyShell-UsefuuLS.cjs.map
2578
+ //# sourceMappingURL=ClarifyShell-C2XnkFQ6.cjs.map