@clarify-labs/renderer 0.10.2 → 0.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/output/{ClarifyShell-C6li72Ce.cjs → ClarifyShell-BAjq876Z.cjs} +113 -90
  2. package/output/ClarifyShell-BAjq876Z.cjs.map +1 -0
  3. package/output/{ClarifyShell-1LuBliwt.js → ClarifyShell-GoSXvgMg.js} +114 -91
  4. package/output/ClarifyShell-GoSXvgMg.js.map +1 -0
  5. package/output/{MermaidViewer-B6-BMCJG.cjs → MermaidViewer-BZ8ghcFP.cjs} +2 -2
  6. package/output/{MermaidViewer-B6-BMCJG.cjs.map → MermaidViewer-BZ8ghcFP.cjs.map} +1 -1
  7. package/output/{MermaidViewer-dXsomvM7.js → MermaidViewer-CkIxyqtf.js} +2 -2
  8. package/output/{MermaidViewer-dXsomvM7.js.map → MermaidViewer-CkIxyqtf.js.map} +1 -1
  9. package/output/{OpenApiOperation-DgrqzeiS.js → OpenApiOperation-C2vJztWZ.js} +1983 -365
  10. package/output/OpenApiOperation-C2vJztWZ.js.map +1 -0
  11. package/output/{OpenApiOperation-B52IWlKb.cjs → OpenApiOperation-D-5uE5v7.cjs} +2009 -361
  12. package/output/OpenApiOperation-D-5uE5v7.cjs.map +1 -0
  13. package/output/{PageActions-BjB6PYmL.cjs → PageActions-DJRXlGhz.cjs} +532 -358
  14. package/output/PageActions-DJRXlGhz.cjs.map +1 -0
  15. package/output/{PageActions-D7K9LDGf.js → PageActions-bugd7GZh.js} +535 -361
  16. package/output/PageActions-bugd7GZh.js.map +1 -0
  17. package/output/{SearchDialog-CIPvXMT3.cjs → SearchDialog-8AdCRp6K.cjs} +3 -3
  18. package/output/{SearchDialog-CIPvXMT3.cjs.map → SearchDialog-8AdCRp6K.cjs.map} +1 -1
  19. package/output/{SearchDialog-CxYLjRi5.js → SearchDialog-CBJjDs_9.js} +3 -3
  20. package/output/{SearchDialog-CxYLjRi5.js.map → SearchDialog-CBJjDs_9.js.map} +1 -1
  21. package/output/app/ContentDiagnostic.d.ts +2 -1
  22. package/output/app/PageFooter.d.ts +1 -1
  23. package/output/client.cjs +3 -3
  24. package/output/client.js +3 -3
  25. package/output/components/AccordionGroup.d.ts +7 -0
  26. package/output/components/Collapse.d.ts +2 -0
  27. package/output/components/FileTree.d.ts +10 -0
  28. package/output/components/Image.d.ts +6 -0
  29. package/output/components/Steps.d.ts +12 -0
  30. package/output/components/Tabs.d.ts +12 -5
  31. package/output/components/Tooltip.d.ts +8 -0
  32. package/output/components/index.d.ts +10 -1
  33. package/output/core/i18n.d.ts +1 -1
  34. package/output/core/types.d.ts +37 -19
  35. package/output/{i18n-DnqZHFT7.js → i18n-BPrC45nD.js} +102 -2
  36. package/output/i18n-BPrC45nD.js.map +1 -0
  37. package/output/{i18n-b4iTLeia.cjs → i18n-wXINKKV0.cjs} +102 -2
  38. package/output/i18n-wXINKKV0.cjs.map +1 -0
  39. package/output/index.cjs +38 -8
  40. package/output/index.cjs.map +1 -1
  41. package/output/index.d.ts +8 -7
  42. package/output/index.js +34 -9
  43. package/output/index.js.map +1 -1
  44. package/output/mdx/components.d.ts +11 -1
  45. package/output/mdx/primitives.d.ts +4 -2
  46. package/output/openapi/components/CodeDisplay.d.ts +1 -0
  47. package/output/openapi/components/EndpointMethodBadge.d.ts +6 -0
  48. package/output/openapi/components/EndpointSections.d.ts +2 -2
  49. package/output/openapi/components/ExamplePanels.d.ts +2 -2
  50. package/output/openapi/components/InlineListbox.d.ts +31 -0
  51. package/output/openapi/components/OpenApiAuthPanel.d.ts +12 -0
  52. package/output/openapi/components/OpenApiOperation.d.ts +1 -9
  53. package/output/openapi/components/OpenApiOperation.state.d.ts +4 -2
  54. package/output/openapi/components/OpenApiRequest.d.ts +18 -0
  55. package/output/openapi/components/OpenApiRequestFields.d.ts +25 -0
  56. package/output/openapi/components/OpenApiResponseViewer.d.ts +8 -0
  57. package/output/openapi/components/SendRequestButton.d.ts +9 -0
  58. package/output/openapi/components/helpers.d.ts +6 -1
  59. package/output/openapi/components/useOpenApiRequestState.d.ts +41 -0
  60. package/output/openapi/entry.d.ts +2 -0
  61. package/output/openapi/index.d.ts +2 -2
  62. package/output/openapi/lib/api-exchange-code.d.ts +8 -0
  63. package/output/openapi/lib/api-exchange.d.ts +30 -0
  64. package/output/openapi/lib/api-request.d.ts +24 -0
  65. package/output/openapi/lib/request-code.d.ts +2 -2
  66. package/output/openapi/lib/request-parameters.d.ts +5 -0
  67. package/output/openapi/store.d.ts +10 -0
  68. package/output/openapi/types.d.ts +4 -0
  69. package/output/preview.cjs +37 -27
  70. package/output/preview.cjs.map +1 -1
  71. package/output/preview.js +37 -27
  72. package/output/preview.js.map +1 -1
  73. package/output/{render-Di5B6Zc0.cjs → render-FICIzeXz.cjs} +2 -2
  74. package/output/{render-Di5B6Zc0.cjs.map → render-FICIzeXz.cjs.map} +1 -1
  75. package/output/{render-DKj24Jqw.js → render-XQiw_48i.js} +2 -2
  76. package/output/{render-DKj24Jqw.js.map → render-XQiw_48i.js.map} +1 -1
  77. package/output/renderer.css +1310 -318
  78. package/output/server.cjs +2 -2
  79. package/output/server.js +2 -2
  80. package/output/theme/ThemeEditor.d.ts +8 -4
  81. package/output/theme/variables.d.ts +8 -4
  82. package/package.json +1 -1
  83. package/output/ClarifyShell-1LuBliwt.js.map +0 -1
  84. package/output/ClarifyShell-C6li72Ce.cjs.map +0 -1
  85. package/output/OpenApiOperation-B52IWlKb.cjs.map +0 -1
  86. package/output/OpenApiOperation-DgrqzeiS.js.map +0 -1
  87. package/output/PageActions-BjB6PYmL.cjs.map +0 -1
  88. package/output/PageActions-D7K9LDGf.js.map +0 -1
  89. package/output/i18n-DnqZHFT7.js.map +0 -1
  90. package/output/i18n-b4iTLeia.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-b4iTLeia.cjs");
3
- const require_PageActions = require("./PageActions-BjB6PYmL.cjs");
2
+ const require_i18n = require("./i18n-wXINKKV0.cjs");
3
+ const require_PageActions = require("./PageActions-DJRXlGhz.cjs");
4
4
  let clsx = require("clsx");
5
5
  clsx = require_rolldown_runtime.__toESM(clsx, 1);
6
6
  let react = require("react");
@@ -332,25 +332,36 @@ function PageBannerLink(props) {
332
332
  const { href, label, external: externalProp, config, locale } = props;
333
333
  const external = externalProp ?? require_PageActions.isExternalHref(href);
334
334
  const resolvedHref = external ? href : require_PageActions.localizeHref(href, config, locale);
335
- const className = "clarify-banner-link shrink-0 rounded-full bg-(--clarify-theme-tokens-colors-primary) px-3 py-1 text-xs/5 font-semibold text-white no-underline transition hover:opacity-90";
335
+ const className = "clarify-banner-link inline-flex h-7 shrink-0 items-center gap-1 rounded-(--clarify-theme-tokens-radius-md) px-2 text-xs/5 font-semibold text-(--clarify-ui-accent-text) no-underline transition hover:bg-(--clarify-ui-hover-background) focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-(--clarify-theme-tokens-colors-primary)";
336
+ const children = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
337
+ className: "hidden sm:inline",
338
+ children: label
339
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ArrowRight, {
340
+ className: "size-3.5",
341
+ "aria-hidden": "true"
342
+ })] });
336
343
  if (external) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
337
344
  href: resolvedHref,
338
345
  target: "_blank",
339
346
  rel: "noreferrer",
340
347
  className,
341
- children: label
348
+ "aria-label": label,
349
+ title: label,
350
+ children
342
351
  });
343
352
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_router_dom.Link, {
344
353
  to: resolvedHref,
345
354
  className,
346
- children: label
355
+ "aria-label": label,
356
+ title: label,
357
+ children
347
358
  });
348
359
  }
349
360
  function PageBanner(props) {
350
361
  const { currentLocale, onDismiss } = props;
351
362
  const config = require_i18n.useConfig();
352
363
  const banner = config.banner;
353
- const content = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.i18n?.defaultLocale) : "";
364
+ const content = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.locales?.default) : "";
354
365
  const storageKey = (0, react.useMemo)(() => {
355
366
  if (!banner || !content) return "";
356
367
  return bannerStorageKey(config, content);
@@ -370,13 +381,13 @@ function PageBanner(props) {
370
381
  if (!content) return null;
371
382
  if (dismissed) return null;
372
383
  const link = banner.link;
373
- const linkLabel = link ? require_PageActions.resolveLocalizedText(link.label, currentLocale, config.i18n?.defaultLocale) : "";
384
+ const linkLabel = link ? require_PageActions.resolveLocalizedText(link.label, currentLocale, config.locales?.default) : "";
374
385
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
375
- className: "clarify-banner relative flex min-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",
386
+ 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",
376
387
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
377
- className: "mx-auto flex w-full max-w-(--clarify-theme-layout-max-width) items-center justify-center gap-3 pr-8 sm:pr-0",
388
+ className: "mx-auto flex min-w-0 w-full max-w-(--clarify-theme-layout-max-width) items-center justify-center gap-1 pr-9 sm:gap-2",
378
389
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
379
- className: "clarify-banner-content m-0 text-center font-medium",
390
+ className: "clarify-banner-content m-0 min-w-0 truncate text-left font-medium sm:text-center",
380
391
  children: content
381
392
  }), link ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageBannerLink, {
382
393
  href: link.href,
@@ -387,7 +398,7 @@ function PageBanner(props) {
387
398
  }) : null]
388
399
  }), banner.dismissible ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
389
400
  type: "button",
390
- className: "clarify-banner-dismiss absolute right-3 inline-flex size-8 items-center justify-center rounded-full text-(--clarify-ui-text-soft) transition hover:bg-(--clarify-ui-hover-background) hover:text-(--clarify-ui-text-strong)",
401
+ className: "clarify-banner-dismiss absolute right-2 inline-flex size-8 items-center justify-center rounded-(--clarify-theme-tokens-radius-md) text-(--clarify-ui-text-soft) transition hover:bg-(--clarify-ui-hover-background) hover:text-(--clarify-ui-text-strong) focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-(--clarify-theme-tokens-colors-primary) sm:right-3",
391
402
  "aria-label": "Dismiss announcement",
392
403
  onClick: () => {
393
404
  if (storageKey && typeof window !== "undefined") window.localStorage.setItem(storageKey, "1");
@@ -403,17 +414,17 @@ function PageBanner(props) {
403
414
  //#endregion
404
415
  //#region source/app/PageFooter.tsx
405
416
  function localeForPath(config, pathname) {
406
- const i18n = config.i18n;
407
- if (!i18n) return void 0;
417
+ const locales = config.locales;
418
+ if (!locales) return void 0;
408
419
  const firstSegment = pathname.split("/").filter(Boolean)[0];
409
- return i18n.locales.find((locale) => locale.code === firstSegment)?.code ?? i18n.defaultLocale;
420
+ return locales.locales.find((locale) => locale.code === firstSegment)?.code ?? locales.default;
410
421
  }
411
422
  function FooterLink(arg0) {
412
423
  const { link, locale, config } = arg0;
413
424
  const external = link.external ?? require_PageActions.isExternalHref(link.href);
414
425
  const href = external ? link.href : require_PageActions.localizeHref(link.href, config, locale);
415
426
  const className = "clarify-footer-link no-underline transition";
416
- const label = require_PageActions.resolveLocalizedText(link.label, locale, config.i18n?.defaultLocale);
427
+ const label = require_PageActions.resolveLocalizedText(link.label, locale, config.locales?.default);
417
428
  if (external) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
418
429
  href,
419
430
  target: "_blank",
@@ -443,25 +454,22 @@ function PageFooter() {
443
454
  const footer = config.footer;
444
455
  const links = footer?.links ?? [];
445
456
  const socials = Object.entries(footer?.socials ?? {});
446
- const copyright = footer?.copyright ? require_PageActions.resolveLocalizedText(footer.copyright, locale, config.i18n?.defaultLocale) : void 0;
447
- if (!Boolean(copyright || links.length > 0 || socials.length > 0)) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("footer", {
448
- "aria-hidden": "true",
449
- className: "clarify-page-footer mt-16 w-full border-t border-(--clarify-theme-tokens-colors-border) pt-8 lg:mt-24"
450
- });
457
+ const copyright = footer?.copyright ? require_PageActions.resolveLocalizedText(footer.copyright, locale, config.locales?.default) : void 0;
458
+ if (!Boolean(copyright || links.length > 0 || socials.length > 0)) return null;
451
459
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("footer", {
452
- 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",
460
+ className: "clarify-page-footer w-full",
453
461
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
454
- className: (0, clsx.default)("clarify-footer-content flex flex-col items-end gap-3 text-right", "sm:items-start sm:text-left"),
462
+ className: (0, clsx.default)("clarify-footer-content flex flex-col items-start gap-2.5 text-left"),
455
463
  children: [copyright ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
456
464
  className: "clarify-footer-copyright m-0",
457
465
  children: copyright
458
466
  }) : null, links.length > 0 || socials.length > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
459
- className: "clarify-footer-links flex flex-wrap justify-end gap-x-4 gap-y-2 sm:justify-start",
467
+ className: "clarify-footer-links flex flex-wrap justify-start gap-x-4 gap-y-2",
460
468
  children: [links.map((link) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FooterLink, {
461
469
  link,
462
470
  locale,
463
471
  config
464
- }, `${link.href}-${require_PageActions.resolveLocalizedText(link.label, locale, config.i18n?.defaultLocale)}`)), socials.map(([name, href]) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SocialLink, {
472
+ }, `${link.href}-${require_PageActions.resolveLocalizedText(link.label, locale, config.locales?.default)}`)), socials.map(([name, href]) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SocialLink, {
465
473
  name,
466
474
  href
467
475
  }, name))]
@@ -484,40 +492,42 @@ function PageNavigation(arg0) {
484
492
  const previous = pageRoutes[currentIndex - 1];
485
493
  const next = pageRoutes[currentIndex + 1];
486
494
  if (!previous && !next) return null;
495
+ const hasBothDirections = Boolean(previous && next);
487
496
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("nav", {
488
- className: "clarify-page-navigation mt-6 grid gap-3 @3xl:grid-cols-2",
497
+ className: (0, clsx.default)("clarify-page-navigation mt-12 grid border-t border-(--clarify-theme-tokens-colors-border)", hasBothDirections && "@3xl:grid-cols-2"),
489
498
  "aria-label": t("navigation.previousNext"),
490
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
499
+ children: [previous ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
491
500
  direction: "previous",
492
- route: previous
493
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
501
+ route: previous,
502
+ separated: hasBothDirections
503
+ }) : null, next ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PageNavigationLink, {
494
504
  direction: "next",
495
- route: next
496
- })]
505
+ route: next,
506
+ separated: hasBothDirections
507
+ }) : null]
497
508
  });
498
509
  }
499
510
  function PageNavigationLink(arg0) {
500
- const { direction, route } = arg0;
511
+ const { direction, route, separated } = arg0;
501
512
  const t = require_i18n.useBuiltInText();
502
- if (!route) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { className: "hidden @3xl:block" });
503
513
  const isNext = direction === "next";
504
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_router_dom.Link, {
514
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_router_dom.Link, {
505
515
  to: require_PageActions.normalizeRoutePath(route.path),
506
- 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"),
507
- children: [
508
- !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,
509
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
510
- className: "min-w-0 flex-1",
511
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
512
- className: "clarify-page-navigation-label block font-medium uppercase tracking-wide text-(--clarify-theme-tokens-colors-muted)",
513
- children: isNext ? t("navigation.next") : t("navigation.previous")
514
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
515
- className: "clarify-page-navigation-title mt-0.5 block truncate font-semibold text-(--clarify-theme-tokens-colors-foreground)",
516
- children: route.title
517
- })]
518
- }),
519
- 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
520
- ]
516
+ 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"),
517
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
518
+ className: (0, clsx.default)("min-w-0", isNext && "ml-auto"),
519
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
520
+ 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"),
521
+ children: [
522
+ !isNext ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronLeft, { className: "size-3.5 transition-transform group-hover:-translate-x-0.5" }) : null,
523
+ isNext ? t("navigation.next") : t("navigation.previous"),
524
+ isNext ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.ChevronRight, { className: "size-3.5 transition-transform group-hover:translate-x-0.5" }) : null
525
+ ]
526
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
527
+ 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)",
528
+ children: route.title
529
+ })]
530
+ })
521
531
  });
522
532
  }
523
533
  //#endregion
@@ -662,12 +672,19 @@ function useReleaseHashSyncOnManualScroll(hashScrollSuppressedUntilRef) {
662
672
  function SectionHashSync(arg0) {
663
673
  const { hashScrollSuppressedUntilRef } = arg0;
664
674
  const location = (0, react_router_dom.useLocation)();
675
+ const pathnameRef = (0, react.useRef)(location.pathname);
665
676
  const hashUpdateTimeoutRef = (0, react.useRef)(void 0);
666
677
  const sections = require_PageActions.useSectionStore((state) => state.sections);
667
678
  const visibleSections = require_PageActions.useSectionStore((state) => state.visibleSections);
679
+ (0, react.useEffect)(() => {
680
+ if (pathnameRef.current === location.pathname) return;
681
+ pathnameRef.current = location.pathname;
682
+ hashScrollSuppressedUntilRef.current = Date.now() + 1200;
683
+ }, [hashScrollSuppressedUntilRef, location.pathname]);
668
684
  useReleaseHashSyncOnManualScroll(hashScrollSuppressedUntilRef);
669
685
  (0, react.useEffect)(() => {
670
686
  if (!sections.length || !visibleSections.length) return;
687
+ if (!location.hash && Date.now() < hashScrollSuppressedUntilRef.current) return;
671
688
  const visibleSectionId = visibleSections.find((id) => id !== "_top" && sections.some((section) => section.id === id));
672
689
  const hashSectionId = location.hash ? safeDecodeURIComponent(location.hash.slice(1)) : void 0;
673
690
  if (hashSectionId && Date.now() < hashScrollSuppressedUntilRef.current && !visibleSections.includes(hashSectionId)) return;
@@ -753,19 +770,19 @@ function scrollToHash(hash) {
753
770
  });
754
771
  }
755
772
  function explicitLocaleForPath(config, pathname) {
756
- const i18n = config.i18n;
757
- if (!i18n) return void 0;
773
+ const locales = config.locales;
774
+ if (!locales) return void 0;
758
775
  const firstSegment = pathname.split("/").filter(Boolean)[0];
759
- return i18n.locales.find((locale) => locale.code === firstSegment)?.code;
776
+ return locales.locales.find((locale) => locale.code === firstSegment)?.code;
760
777
  }
761
778
  function fallbackLocale(config) {
762
- return config.i18n?.defaultLocale;
779
+ return config.locales?.default;
763
780
  }
764
781
  function storedLocaleForConfig(config) {
765
- return require_PageActions.getStoredLocalePreference(config.i18n?.locales.map((locale) => locale.code));
782
+ return require_PageActions.getStoredLocalePreference(config.locales?.locales.map((locale) => locale.code));
766
783
  }
767
784
  function isDefaultLocale(config, locale) {
768
- return Boolean(locale && config.i18n?.defaultLocale === locale);
785
+ return Boolean(locale && config.locales?.default === locale);
769
786
  }
770
787
  function hasPath(nodes, pathname, locale) {
771
788
  return nodes.some((node) => require_PageActions.isSameRoutePath(node.path, pathname, locale) || hasPath(node.children ?? [], pathname, locale));
@@ -815,7 +832,7 @@ function useRouteState(config, routes, navigation, pathname) {
815
832
  explicitLocale,
816
833
  storedLocale,
817
834
  currentLocale,
818
- currentLocaleConfig: config.i18n?.locales.find((locale) => locale.code === currentLocale),
835
+ currentLocaleConfig: config.locales?.locales.find((locale) => locale.code === currentLocale),
819
836
  notFoundRoute: currentRoute ? void 0 : notFoundRouteForPath(routes, pathname, currentLocale),
820
837
  currentNavigation: navigationForLocale(navigation, currentLocale, pathname),
821
838
  sections: sectionsForRoute(currentRoute)
@@ -839,7 +856,7 @@ function useStoredBannerDismissed(storageKey) {
839
856
  }
840
857
  function useBannerState(config, currentLocale) {
841
858
  const banner = config.banner;
842
- const bannerContent = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.i18n?.defaultLocale) : "";
859
+ const bannerContent = banner ? require_PageActions.resolveLocalizedText(banner.content, currentLocale, config.locales?.default) : "";
843
860
  const bannerStorageKey = banner && bannerContent ? `clarify:banner:dismissed:${config.title}:${bannerContent}` : void 0;
844
861
  const storedBannerDismissed = useStoredBannerDismissed(banner?.dismissible ? bannerStorageKey : void 0);
845
862
  const [dismissedBannerKey, setDismissedBannerKey] = (0, react.useState)();
@@ -879,9 +896,11 @@ function useAppShellNavigationEffects(arg0) {
879
896
  scrollToHash(location.hash);
880
897
  return;
881
898
  }
899
+ hashScrollSuppressedUntilRef.current = Date.now() + 1200;
882
900
  window.scrollTo({
883
901
  top: 0,
884
- left: 0
902
+ left: 0,
903
+ behavior: "instant"
885
904
  });
886
905
  window.requestAnimationFrame(() => {
887
906
  window.dispatchEvent(new Event("scroll"));
@@ -1070,17 +1089,19 @@ function AppShell(arg0) {
1070
1089
  });
1071
1090
  }
1072
1091
  function renderFooter() {
1073
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
1074
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, { name: "page.footer.before" }),
1075
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, {
1076
- name: "page.footer.replace",
1077
- default: DefaultFooterComponent
1078
- }),
1079
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1080
- className: "flex justify-end",
1092
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1093
+ 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",
1094
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1095
+ className: "clarify-page-footer-slot min-w-0",
1096
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, { name: "page.footer.before" }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RuntimeSlot, {
1097
+ name: "page.footer.replace",
1098
+ default: DefaultFooterComponent
1099
+ })]
1100
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1101
+ className: "clarify-page-attribution flex justify-end sm:self-end",
1081
1102
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BuiltWithClarify, {})
1082
- })
1083
- ] });
1103
+ })]
1104
+ });
1084
1105
  }
1085
1106
  function renderContent() {
1086
1107
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
@@ -1823,8 +1844,7 @@ function createRandomTheme() {
1823
1844
  colors: createRandomThemeColors(selection),
1824
1845
  radius: { ...selection.radius }
1825
1846
  },
1826
- layout: { maxWidth: selection.maxWidth },
1827
- editor: false
1847
+ layout: { maxWidth: selection.maxWidth }
1828
1848
  };
1829
1849
  }
1830
1850
  //#endregion
@@ -1835,42 +1855,47 @@ var themePresets = {
1835
1855
  preset: "default",
1836
1856
  tokens: {
1837
1857
  colors: {
1838
- primary: "#047857",
1839
- accent: "#0D9488",
1858
+ primary: {
1859
+ light: "#047857",
1860
+ dark: "#34d399"
1861
+ },
1862
+ accent: {
1863
+ light: "#0f766e",
1864
+ dark: "#5eead4"
1865
+ },
1840
1866
  background: {
1841
- light: "#ffffff",
1842
- dark: "#09090b"
1867
+ light: "#f8fafc",
1868
+ dark: "#0a0a0b"
1843
1869
  },
1844
1870
  foreground: {
1845
- light: "#111827",
1846
- dark: "#ffffff"
1871
+ light: "#172033",
1872
+ dark: "#f4f4f5"
1847
1873
  },
1848
1874
  surface: {
1849
1875
  light: "#ffffff",
1850
1876
  dark: "#18181b"
1851
1877
  },
1852
1878
  muted: {
1853
- light: "#64748b",
1879
+ light: "#667085",
1854
1880
  dark: "#a1a1aa"
1855
1881
  },
1856
1882
  border: {
1857
- light: "rgb(15 23 42 / 0.12)",
1858
- dark: "rgb(255 255 255 / 0.1)"
1883
+ light: "rgb(15 23 42 / 0.11)",
1884
+ dark: "rgb(255 255 255 / 0.11)"
1859
1885
  },
1860
1886
  codeBackground: {
1861
- light: "#f6fbf8",
1862
- dark: "#18181b"
1887
+ light: "#f1f5f3",
1888
+ dark: "#171719"
1863
1889
  }
1864
1890
  },
1865
1891
  radius: {
1866
1892
  sm: "6px",
1867
- md: "10px",
1868
- lg: "14px",
1869
- xl: "18px"
1893
+ md: "8px",
1894
+ lg: "12px",
1895
+ xl: "16px"
1870
1896
  }
1871
1897
  },
1872
- layout: { maxWidth: "82rem" },
1873
- editor: false
1898
+ layout: { maxWidth: "82rem" }
1874
1899
  },
1875
1900
  base: {
1876
1901
  preset: "base",
@@ -1910,8 +1935,7 @@ var themePresets = {
1910
1935
  xl: "16px"
1911
1936
  }
1912
1937
  },
1913
- layout: { maxWidth: "80rem" },
1914
- editor: false
1938
+ layout: { maxWidth: "80rem" }
1915
1939
  }
1916
1940
  };
1917
1941
  function cloneThemeColorValue(value) {
@@ -1933,8 +1957,7 @@ function cloneTheme(theme) {
1933
1957
  },
1934
1958
  radius: { ...theme.tokens.radius }
1935
1959
  },
1936
- layout: { ...theme.layout },
1937
- editor: theme.editor
1960
+ layout: { ...theme.layout }
1938
1961
  };
1939
1962
  }
1940
1963
  function isModeColorValue(value) {
@@ -2536,4 +2559,4 @@ Object.defineProperty(exports, "useSlot", {
2536
2559
  }
2537
2560
  });
2538
2561
 
2539
- //# sourceMappingURL=ClarifyShell-C6li72Ce.cjs.map
2562
+ //# sourceMappingURL=ClarifyShell-BAjq876Z.cjs.map