@krizaka/ui 4.0.0 → 4.2.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 (53) hide show
  1. package/dist/analysis-report.d.ts +44 -2
  2. package/dist/analysis-report.js +34 -13
  3. package/dist/analysis-report.js.map +1 -1
  4. package/dist/{chunk-54WTUZWE.js → chunk-6GTZVF77.js} +1 -1
  5. package/dist/chunk-6GTZVF77.js.map +1 -0
  6. package/dist/filter-bar.d.ts +3 -3
  7. package/dist/media-gallery.d.ts +3 -3
  8. package/dist/media-player.d.ts +3 -3
  9. package/dist/native.d.ts +8 -0
  10. package/dist/native.js +8 -0
  11. package/dist/native.js.map +1 -1
  12. package/dist/nav-bar.d.ts +1 -1
  13. package/dist/nav-bar.js +1 -1
  14. package/dist/{schema-DgjBz7-8.d.ts → schema-CL7t7xqb.d.ts} +1 -1
  15. package/dist/shop.d.ts +2 -2
  16. package/dist/site-cahier.d.ts +52 -39
  17. package/dist/site-cahier.js +18 -2
  18. package/dist/site-cahier.js.map +1 -1
  19. package/dist/site-footer.d.ts +10 -92
  20. package/dist/site-footer.js +19 -3
  21. package/dist/site-footer.js.map +1 -1
  22. package/dist/sites-iJkCPeiH.d.ts +170 -0
  23. package/dist/sites.d.ts +14 -0
  24. package/dist/sites.js.map +1 -1
  25. package/package.json +6 -5
  26. package/registry/account-settings.json +1 -1
  27. package/registry/analysis-report.json +51 -5
  28. package/registry/app-frame.json +1 -1
  29. package/registry/examples/account-settings/patterns.js +1 -1
  30. package/registry/examples/account-settings/patterns.tsx +1 -1
  31. package/registry/examples/analysis-report/authenticity.d.ts +4 -0
  32. package/registry/examples/analysis-report/authenticity.js +50 -0
  33. package/registry/examples/analysis-report/authenticity.tsx +33 -0
  34. package/registry/examples/analysis-report/lease-review.d.ts +4 -0
  35. package/registry/examples/analysis-report/lease-review.js +51 -0
  36. package/registry/examples/analysis-report/lease-review.tsx +33 -0
  37. package/registry/examples/markdown/wide-table.js +1 -1
  38. package/registry/examples/markdown/wide-table.tsx +1 -1
  39. package/registry/examples/site-footer/configured.js +2 -2
  40. package/registry/examples/site-footer/configured.tsx +2 -2
  41. package/registry/examples/site-footer/socials.d.ts +4 -0
  42. package/registry/examples/site-footer/socials.js +25 -0
  43. package/registry/examples/site-footer/socials.tsx +22 -0
  44. package/registry/index.json +13 -10
  45. package/registry/map.json +1 -1
  46. package/registry/markdown.json +1 -1
  47. package/registry/nav-bar.json +1 -1
  48. package/registry/rail-nav.json +1 -1
  49. package/registry/shop.json +1 -1
  50. package/registry/site-footer.json +15 -4
  51. package/registry/sites.json +4 -2
  52. package/dist/chunk-54WTUZWE.js.map +0 -1
  53. package/dist/sites-A5cNWG2Z.d.ts +0 -73
@@ -1,96 +1,8 @@
1
- import { S as SiteStatus, a as SiteId, F as FamilyLabels, O as OrgFacts } from './sites-A5cNWG2Z.js';
1
+ import { S as SiteId, F as FamilyLabels, O as OrgFacts, a as SiteFooterConfig } from './sites-iJkCPeiH.js';
2
+ export { b as FOOTER_LIMITS, c as FooterColumn, d as FooterLegal, e as FooterLink, f as FooterLinkSetting, g as FooterSettings, h as FooterStatus, i as OrgSocialLink, j as footerSettingsProblems, r as resolveFooterSettings } from './sites-iJkCPeiH.js';
2
3
  import * as tailwind_variants from 'tailwind-variants';
3
4
  import * as React from 'react';
4
5
 
5
- /** At most four columns of at most six links: past that a footer is a sitemap, and nobody reads it. */
6
- declare const FOOTER_LIMITS: {
7
- readonly columns: 4;
8
- readonly links: 6;
9
- readonly legalLinks: 4;
10
- };
11
- /** A status said once, on a column's heading (never on each link). */
12
- type FooterStatus = Exclude<SiteStatus, "released">;
13
- /** A link, its words resolved. `external`: it leaves this site (a plain `<a>`, never the router). */
14
- type FooterLink = {
15
- label: string;
16
- href: string;
17
- external?: boolean;
18
- };
19
- /** A column, its words resolved. */
20
- type FooterColumn = {
21
- id: string;
22
- title: string;
23
- status?: FooterStatus;
24
- links: readonly FooterLink[];
25
- };
26
- /** The legal line: who publishes the site, once — `legalName · NEQ … · city`, then the version and the legal links. */
27
- type FooterLegal = {
28
- legalName: string;
29
- /** The Québec enterprise number, shown as the publisher's legal identity (`NEQ 1182652231`). */
30
- neq?: string;
31
- city: string;
32
- showVersion: boolean;
33
- /** Where the version leads (the release's page), when it is a link. */
34
- versionHref?: string;
35
- links: readonly FooterLink[];
36
- };
37
- /** What `SiteFooter` draws from `config`: the columns, then the legal line and the socials. */
38
- type SiteFooterConfig = {
39
- /** The name of the columns' navigation (« Pied de page » / « Footer »). */
40
- label: string;
41
- columns: readonly FooterColumn[];
42
- legal: FooterLegal;
43
- social?: readonly {
44
- id: string;
45
- label: string;
46
- href: string;
47
- }[];
48
- };
49
- /** A stored link: a message key (`labelKey`) or a proper noun the same in every language (`label`: « Verikora », « GitHub »). */
50
- type FooterLinkSetting = ({
51
- labelKey: string;
52
- label?: never;
53
- } | {
54
- label: string;
55
- labelKey?: never;
56
- }) & {
57
- href: string;
58
- external?: boolean;
59
- };
60
- /** The footer as an app stores it in its settings. */
61
- type FooterSettings = {
62
- labelKey: string;
63
- columns: readonly {
64
- id: string;
65
- titleKey: string;
66
- status?: FooterStatus;
67
- links: readonly FooterLinkSetting[];
68
- }[];
69
- legal: {
70
- legalName: string;
71
- neq?: string;
72
- city: string;
73
- showVersion: boolean;
74
- versionHref?: string;
75
- links: readonly FooterLinkSetting[];
76
- };
77
- /** The ids of the org's social links (`@krizaka/org`) to show; their addresses are the org's, never typed here. */
78
- social?: readonly string[];
79
- };
80
- /** A social link of the org (`@krizaka/org` `links.social`). */
81
- type OrgSocialLink = {
82
- id: string;
83
- label: string;
84
- url: string;
85
- };
86
- /** The settings, their words read from the app's messages (`t`) and the socials from the org's list. */
87
- declare function resolveFooterSettings(settings: FooterSettings, t: (key: string) => string, social?: readonly OrgSocialLink[]): SiteFooterConfig;
88
- /**
89
- * What is wrong with a footer's settings — the admin's form refuses to save while the list is not empty: too many
90
- * columns or links, a link twice, an empty column, an `http:` or a development address, a malformed NEQ.
91
- */
92
- declare function footerSettingsProblems(settings: FooterSettings): string[];
93
-
94
6
  /** The app's link component (Next's `Link`, React Router's `Link`…): receives `href`, `className` and the children. */
95
7
  type LinkComponent = React.ElementType<{
96
8
  href: string;
@@ -140,6 +52,8 @@ declare const siteFooter: tailwind_variants.TVReturnType<{
140
52
  stack: string;
141
53
  stackList: string;
142
54
  identity: string;
55
+ socials: string;
56
+ social: string;
143
57
  }, undefined, {
144
58
  variant: {
145
59
  site: {};
@@ -180,6 +94,8 @@ declare const siteFooter: tailwind_variants.TVReturnType<{
180
94
  stack: string;
181
95
  stackList: string;
182
96
  identity: string;
97
+ socials: string;
98
+ social: string;
183
99
  }, tailwind_variants.TVReturnTypeLike<{
184
100
  variant: {
185
101
  site: {};
@@ -220,6 +136,8 @@ declare const siteFooter: tailwind_variants.TVReturnType<{
220
136
  stack: string;
221
137
  stackList: string;
222
138
  identity: string;
139
+ socials: string;
140
+ social: string;
223
141
  }>>;
224
142
  type Tone = "product" | "cahier";
225
143
  type SiteFooterProps = Omit<React.ComponentProps<"footer">, "children"> & {
@@ -299,5 +217,5 @@ type SiteFooterLinkProps = React.ComponentProps<"a"> & {
299
217
  /** A link of the footer. */
300
218
  declare function SiteFooterLink({ active, asChild, className, ...props }: SiteFooterLinkProps): React.JSX.Element;
301
219
 
302
- export { FOOTER_LIMITS, SiteFooter, SiteFooterColumn, SiteFooterLink, footerSettingsProblems, resolveFooterSettings, siteFooter };
303
- export type { FooterColumn, FooterLegal, FooterLink, FooterLinkSetting, FooterSettings, FooterStatus, OrgSocialLink, SiteFooterColumnProps, SiteFooterConfig, SiteFooterLinkProps, SiteFooterProps };
220
+ export { SiteFooter, SiteFooterColumn, SiteFooterConfig, SiteFooterLink, siteFooter };
221
+ export type { SiteFooterColumnProps, SiteFooterLinkProps, SiteFooterProps };
@@ -5,7 +5,7 @@ import {
5
5
  siteById,
6
6
  siteGroups,
7
7
  sites
8
- } from "./chunk-54WTUZWE.js";
8
+ } from "./chunk-6GTZVF77.js";
9
9
  import {
10
10
  ProductLogo
11
11
  } from "./chunk-CDNOT2KR.js";
@@ -70,6 +70,7 @@ function legalProblems(settings) {
70
70
  }
71
71
 
72
72
  // src/site-footer/site-footer.tsx
73
+ import { InstagramIcon, YoutubeIcon } from "@krizaka/icons";
73
74
  import { Slot } from "radix-ui";
74
75
  import * as React from "react";
75
76
  import { tv } from "tailwind-variants";
@@ -115,7 +116,10 @@ var siteFooter = tv({
115
116
  columns: "grid min-w-0 grid-cols-2 gap-x-6 gap-y-6 pb-2 sm:grid-flow-col sm:grid-cols-none sm:auto-cols-[minmax(0,13rem)] sm:gap-x-10",
116
117
  stack: "flex min-w-0 flex-col gap-2",
117
118
  stackList: "flex min-w-0 flex-col gap-1",
118
- identity: "text-fg-secondary"
119
+ identity: "text-fg-secondary",
120
+ // The accounts drawn as their icon (the name stays for screen readers): colour change only on hover, never movement.
121
+ socials: "flex flex-wrap items-center gap-x-3 gap-y-2",
122
+ social: "inline-flex min-h-6 min-w-6 items-center justify-center rounded-md text-fg-secondary no-underline transition-colors hover:text-fg focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring"
119
123
  },
120
124
  variants: {
121
125
  // `site`: the three lines. `docs`: the same on the documentation's width. `app`: line 3 only, inside a signed-in product.
@@ -255,6 +259,7 @@ function SiteFooter({
255
259
  tag
256
260
  ] }),
257
261
  legal && /* @__PURE__ */ jsx("div", { className: s.legal(), children: legal }),
262
+ /* @__PURE__ */ jsx(FooterSocials, { s, links: (org?.links?.social ?? []).map((x) => ({ id: x.id, label: x.label, href: x.url })) }),
258
263
  controls && /* @__PURE__ */ jsx("div", { className: s.controls(), children: controls })
259
264
  ] })
260
265
  ] }) }) });
@@ -288,10 +293,21 @@ function ConfigBottom({
288
293
  /* @__PURE__ */ jsx("span", { className: s.identity(), children: identity }),
289
294
  shown && (legal.showVersion && legal.versionHref ? /* @__PURE__ */ jsx("a", { href: legal.versionHref, className: s.version({ className: "no-underline hover:text-fg focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring" }), children: versionText }) : /* @__PURE__ */ jsx("span", { className: s.version(), children: versionText })),
290
295
  legal.links.length > 0 && /* @__PURE__ */ jsx("div", { className: s.legal(), children: legal.links.map(configured) }),
291
- social && social.length > 0 && /* @__PURE__ */ jsx("div", { className: s.legal(), children: social.map((x) => configured({ label: x.label, href: x.href, external: true })) }),
296
+ /* @__PURE__ */ jsx(FooterSocials, { s, links: social ?? [] }),
292
297
  controls && /* @__PURE__ */ jsx("div", { className: s.controls(), children: controls })
293
298
  ] });
294
299
  }
300
+ var SOCIAL_ICONS = { instagram: InstagramIcon, youtube: YoutubeIcon };
301
+ function FooterSocials({ s, links }) {
302
+ if (links.length === 0) return null;
303
+ return /* @__PURE__ */ jsx("div", { className: s.socials(), children: links.map((x) => {
304
+ const Icon = SOCIAL_ICONS[x.id];
305
+ return /* @__PURE__ */ jsxs("a", { href: x.href, target: "_blank", rel: "noopener noreferrer", className: Icon ? s.social() : s.link(), children: [
306
+ Icon && /* @__PURE__ */ jsx(Icon, { size: 20 }),
307
+ Icon ? /* @__PURE__ */ jsx("span", { className: "sr-only", children: x.label }) : x.label
308
+ ] }, x.id);
309
+ }) });
310
+ }
295
311
  function ConfigColumns({
296
312
  s,
297
313
  config,
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/site-footer/footer-config.ts","../src/site-footer/site-footer.tsx","../src/sites/family-groups.ts"],"sourcesContent":["// The footer as the admin configures it (krizaka-internal#591): the settings an app stores (`@krizaka/settings`, audited)\n// — words as message keys, so FR and EN come from the app's catalogues — and the resolved config `SiteFooter` draws.\n// Pure: no React, no fetch. The structure is the design rule (founder, 2026-11-01): a few short columns, then one legal\n// line that names the company once.\nimport type { SiteStatus } from \"../sites/sites\";\n\n/** At most four columns of at most six links: past that a footer is a sitemap, and nobody reads it. */\nexport const FOOTER_LIMITS = { columns: 4, links: 6, legalLinks: 4 } as const;\n\n/** A status said once, on a column's heading (never on each link). */\nexport type FooterStatus = Exclude<SiteStatus, \"released\">;\n\n/** A link, its words resolved. `external`: it leaves this site (a plain `<a>`, never the router). */\nexport type FooterLink = { label: string; href: string; external?: boolean };\n\n/** A column, its words resolved. */\nexport type FooterColumn = { id: string; title: string; status?: FooterStatus; links: readonly FooterLink[] };\n\n/** The legal line: who publishes the site, once — `legalName · NEQ … · city`, then the version and the legal links. */\nexport type FooterLegal = {\n legalName: string;\n /** The Québec enterprise number, shown as the publisher's legal identity (`NEQ 1182652231`). */\n neq?: string;\n city: string;\n showVersion: boolean;\n /** Where the version leads (the release's page), when it is a link. */\n versionHref?: string;\n links: readonly FooterLink[];\n};\n\n/** What `SiteFooter` draws from `config`: the columns, then the legal line and the socials. */\nexport type SiteFooterConfig = {\n /** The name of the columns' navigation (« Pied de page » / « Footer »). */\n label: string;\n columns: readonly FooterColumn[];\n legal: FooterLegal;\n social?: readonly { id: string; label: string; href: string }[];\n};\n\n/** A stored link: a message key (`labelKey`) or a proper noun the same in every language (`label`: « Verikora », « GitHub »). */\nexport type FooterLinkSetting = ({ labelKey: string; label?: never } | { label: string; labelKey?: never }) & {\n href: string;\n external?: boolean;\n};\n\n/** The footer as an app stores it in its settings. */\nexport type FooterSettings = {\n labelKey: string;\n columns: readonly { id: string; titleKey: string; status?: FooterStatus; links: readonly FooterLinkSetting[] }[];\n legal: { legalName: string; neq?: string; city: string; showVersion: boolean; versionHref?: string; links: readonly FooterLinkSetting[] };\n /** The ids of the org's social links (`@krizaka/org`) to show; their addresses are the org's, never typed here. */\n social?: readonly string[];\n};\n\n/** A social link of the org (`@krizaka/org` `links.social`). */\nexport type OrgSocialLink = { id: string; label: string; url: string };\n\nconst link = (l: FooterLinkSetting, t: (key: string) => string): FooterLink => ({\n label: l.labelKey === undefined ? l.label! : t(l.labelKey),\n href: l.href,\n ...(l.external ? { external: true } : {}),\n});\n\n/** The settings, their words read from the app's messages (`t`) and the socials from the org's list. */\nexport function resolveFooterSettings(\n settings: FooterSettings,\n t: (key: string) => string,\n social: readonly OrgSocialLink[] = [],\n): SiteFooterConfig {\n const shown = (settings.social ?? []).flatMap((id) => social.filter((s) => s.id === id));\n return {\n label: t(settings.labelKey),\n columns: settings.columns.map((c) => ({\n id: c.id,\n title: t(c.titleKey),\n ...(c.status ? { status: c.status } : {}),\n links: c.links.map((l) => link(l, t)),\n })),\n legal: { ...settings.legal, links: settings.legal.links.map((l) => link(l, t)) },\n ...(shown.length > 0 ? { social: shown.map((s) => ({ id: s.id, label: s.label, href: s.url })) } : {}),\n };\n}\n\n/**\n * What is wrong with a footer's settings — the admin's form refuses to save while the list is not empty: too many\n * columns or links, a link twice, an empty column, an `http:` or a development address, a malformed NEQ.\n */\nexport function footerSettingsProblems(settings: FooterSettings): string[] {\n return [...limitProblems(settings), ...linkProblems(settings), ...legalProblems(settings)];\n}\n\nfunction limitProblems(settings: FooterSettings): string[] {\n const problems: string[] = [];\n if (settings.columns.length > FOOTER_LIMITS.columns) problems.push(`at most ${FOOTER_LIMITS.columns} columns`);\n if (settings.legal.links.length > FOOTER_LIMITS.legalLinks) problems.push(`at most ${FOOTER_LIMITS.legalLinks} legal links`);\n for (const c of settings.columns) {\n if (c.links.length === 0) problems.push(`column ${c.id}: no link`);\n if (c.links.length > FOOTER_LIMITS.links) problems.push(`column ${c.id}: at most ${FOOTER_LIMITS.links} links`);\n }\n return problems;\n}\n\nfunction hrefProblems(where: string, l: { href: string; external?: boolean }): string[] {\n const problems: string[] = [];\n if (/^http:/i.test(l.href)) problems.push(`${where}: ${l.href} is not https`);\n if (/^https?:\\/\\/dev\\./i.test(l.href)) problems.push(`${where}: ${l.href} is a development host`);\n if (l.external && !/^[a-z][a-z0-9+.-]*:/i.test(l.href)) problems.push(`${where}: ${l.href} is external but relative`);\n return problems;\n}\n\nfunction linkProblems(settings: FooterSettings): string[] {\n const problems: string[] = [];\n const seen = new Set<string>();\n const all = [...settings.columns.flatMap((c) => c.links.map((l) => ({ where: c.id, l }))), ...settings.legal.links.map((l) => ({ where: \"legal\", l }))];\n for (const { where, l } of all) {\n if (seen.has(l.href)) problems.push(`${where}: ${l.href} is already in the footer`);\n seen.add(l.href);\n problems.push(...hrefProblems(where, l));\n }\n return problems;\n}\n\nfunction legalProblems(settings: FooterSettings): string[] {\n const problems: string[] = [];\n if (settings.legal.neq !== undefined && !/^\\d{10}$/.test(settings.legal.neq)) problems.push(\"legal: the NEQ has ten digits\");\n if (settings.legal.legalName.trim() === \"\") problems.push(\"legal: the legal name is required\");\n return problems;\n}\n","// Client (the mark holds an id). The footer shared by every site and app of the Krizaka family — compact (founder,\n// 2026-10-30, krizaka/krizaka-internal#754: « des footers de 10 lignes »): at most three lines on a desktop —\n// 1. the site's own links, each group inline (`Docs Get started · Components`);\n// 2. the family, grouped inline (Products · Open source · Krizaka), names read from `org.family` of `@krizaka/org`;\n// 3. one line: the mark and the org's signature, the version, the legal links, the host's controls (language, theme).\n// On a phone the family's groups fold (`<details>`), the rest wraps. `variant=\"app\"` keeps line 3 only. Same structure on\n// the Cahier sites and the products (`tone`). No link twice, no site block, no names typed here when `org` is given.\nimport { Slot } from \"radix-ui\";\nimport * as React from \"react\";\nimport { tv } from \"tailwind-variants\";\n\n// ProductLogo, not KrizakaLogo: one import path keeps every mark in one shared chunk (KrizakaLogo alone split it: +871 B gzip on the typical page).\nimport type { LinkComponent } from \"../block-link\";\nimport { ProductLogo } from \"../marks/ProductLogo\";\nimport { columnStatus, familyGroups, orgIdOf } from \"../sites/family-groups\";\nimport { companyLinks, type FamilyLabels, familyLabels, type OrgFacts, siteById, type SiteId, type SiteStatus } from \"../sites/sites\";\nimport type { FooterLink, SiteFooterConfig } from \"./footer-config\";\n\nexport const siteFooter = tv({\n slots: {\n root: \"w-full border-t border-border-subtle bg-surface-0 text-fg\",\n inner:\n \"mx-auto grid w-full max-w-[calc(var(--kz-page-max,72rem)_+_2*var(--kz-page-gutter,clamp(16px,3.2vw,32px)))] grid-cols-[minmax(0,1fr)] gap-3 px-[var(--kz-page-gutter,clamp(16px,3.2vw,32px))] py-6\",\n row: \"flex min-w-0 flex-wrap items-baseline gap-x-6 gap-y-2\",\n family: \"grid min-w-0 grid-cols-[minmax(0,1fr)] gap-1 lg:flex lg:flex-wrap lg:items-baseline lg:gap-x-6 lg:gap-y-2\",\n group:\n \"group/fold min-w-0 lg:[&::details-content]:[content-visibility:visible] lg:[&::details-content]:contents lg:[&>summary]:pointer-events-none lg:inline-flex lg:items-baseline lg:gap-2\",\n summary:\n \"flex min-h-11 cursor-pointer list-none items-center justify-between rounded-md text-xs font-semibold text-fg-secondary [&::-webkit-details-marker]:hidden \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring lg:inline lg:min-h-0 lg:cursor-default\",\n chevron: \"size-4 shrink-0 transition-transform group-open/fold:rotate-180 motion-reduce:transition-none lg:hidden\",\n column: \"inline-flex min-w-0 flex-wrap items-baseline gap-x-2 gap-y-1\",\n title: \"text-xs font-semibold text-fg-secondary\",\n note: \"font-normal\",\n list: \"flex min-w-0 flex-wrap items-baseline gap-x-3 gap-y-1 pb-2 lg:pb-0\",\n link:\n \"inline-flex min-h-6 min-w-0 items-center rounded-md text-sm [overflow-wrap:anywhere] text-fg-secondary no-underline transition-colors hover:text-fg \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring aria-[current=page]:text-fg aria-[current=page]:font-semibold aria-[current=true]:text-fg aria-[current=true]:font-semibold\",\n bottom: \"flex flex-wrap items-center gap-x-4 gap-y-2 text-xs text-fg-secondary\",\n signature:\n \"inline-flex items-center gap-2 rounded-md font-medium text-fg no-underline hover:text-fg-accent focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\",\n version:\n \"rounded-sm border border-border-subtle bg-surface-2 px-2 py-0.5 font-mono text-[11px] text-fg-secondary\",\n legal: \"flex flex-wrap items-center gap-x-4 gap-y-2\",\n controls: \"flex flex-wrap items-center gap-2 sm:ml-auto\",\n // `config`: real columns — two on a phone, side by side from `sm`, each a heading over a stacked list.\n columns: \"grid min-w-0 grid-cols-2 gap-x-6 gap-y-6 pb-2 sm:grid-flow-col sm:grid-cols-none sm:auto-cols-[minmax(0,13rem)] sm:gap-x-10\",\n stack: \"flex min-w-0 flex-col gap-2\",\n stackList: \"flex min-w-0 flex-col gap-1\",\n identity: \"text-fg-secondary\",\n },\n variants: {\n // `site`: the three lines. `docs`: the same on the documentation's width. `app`: line 3 only, inside a signed-in product.\n variant: {\n site: {},\n docs: {\n inner: \"max-w-[calc(var(--kz-page-max-docs,88rem)_+_2*var(--kz-page-gutter,clamp(16px,3.2vw,32px)))]\",\n },\n app: {\n root: \"bg-transparent\",\n inner: \"py-3\",\n },\n },\n // `product`: the products' plain Krizaka UI. `cahier`: the Cahier sites (www, blog, ui., java., ts., lab.) — the\n // headings in the Cahier's hand; the structure is the same.\n tone: {\n product: {},\n cahier: {\n title: \"font-[family-name:var(--kz-font-display,inherit)] italic\",\n summary: \"font-[family-name:var(--kz-font-display,inherit)] italic\",\n },\n },\n },\n defaultVariants: { variant: \"site\", tone: \"product\" },\n});\n\nconst bare = (p: string) => p.replace(/^\\/(en|fr)(?=\\/|$)/, \"\").replace(/\\/+$/, \"\") || \"/\";\n\n/** Is `href` (an absolute family address) the page `path` of the site at `siteUrl`? Locale prefix and trailing slash do not count. */\nfunction isThisPage(href: string, siteUrl: string, path: string): boolean {\n try {\n const target = new URL(href);\n return target.host === new URL(siteUrl).host && bare(target.pathname) === bare(path.split(/[?#]/)[0]!);\n } catch {\n return false;\n }\n}\n\n/** The link to the page you are on: no reload, back to the top (the browser would otherwise keep or restore the scroll). */\nfunction backToTop(event: React.MouseEvent<HTMLAnchorElement>) {\n if (event.metaKey || event.ctrlKey || event.shiftKey || event.button !== 0) return;\n event.preventDefault();\n window.scrollTo({ top: 0, behavior: \"auto\" });\n}\n\ntype Tone = \"product\" | \"cahier\";\nconst ToneContext = React.createContext<Tone>(\"product\");\n\nexport type SiteFooterProps = Omit<React.ComponentProps<\"footer\">, \"children\"> & {\n /** The site this footer belongs to (`@krizaka/ui/sites`): marked in the family, its address for `path`. */\n current: SiteId;\n /**\n * The family's words, passed translated: `familyLabels.fr` from `@krizaka/ui/sites`, or your own of the same shape.\n * @default familyLabels.en\n */\n labels?: FamilyLabels;\n /** The site's own link groups (`SiteFooter.Column`), on the first line. */\n children?: React.ReactNode;\n /** The version the site runs (`1.2.3`, shown `v1.2.3`). */\n version?: string;\n /** The environment, when it is not production (`DEV`). */\n env?: string;\n /**\n * The path of the page being read on this site (`/en/story`, `/blog/…`): the company link that points to this very\n * page says so (`aria-current=\"page\"`) and a click on it scrolls to the top instead of reloading.\n */\n path?: string;\n /**\n * Shows the family on the second line, folded on a phone. The links to the other sites live on krizaka.com only\n * (founder rule, 2026-10-30): every other site and its documentation opts in on purpose, none by default.\n * @default current === \"krizaka\" (and never in `variant=\"app\"`)\n */\n family?: boolean;\n /** Only these products in the Products group (the current site always kept). Omit it to list every product. */\n products?: readonly SiteId[];\n /**\n * The organisation's public facts (`org` of `@krizaka/org`) — pass them on every site. The names and addresses of the\n * family are then `org.family`, the signature is `org.footer.line` (« Une entreprise de Technologies Krizaka · Fait à\n * Montréal », the same everywhere) and, without `legal`, the legal links are `org.footer.legal`.\n */\n org?: OrgFacts;\n /** The legal links, when not the org's (`SiteFooter.Link`s). */\n legal?: React.ReactNode;\n /** The host's controls at the end of the last line: the language switch, the theme toggle. */\n controls?: React.ReactNode;\n /**\n * `site` — every public site. `docs` — the same under documentation, on its width. `app` — inside a signed-in product:\n * the last line only; render it once, in the layout.\n * @default \"site\"\n */\n variant?: \"site\" | \"docs\" | \"app\";\n /** `cahier` on the Cahier sites (www, blog, ui., java., ts., lab.), `product` in the products. @default \"product\" */\n tone?: Tone;\n /**\n * The footer as the admin configured it (`resolveFooterSettings` of the app's settings): its columns, then one legal\n * line — `legalName · NEQ … · city`, the version when `showVersion`, the legal links, the socials. With it the family\n * is not drawn (the columns hold what the site wants) and the org's signature gives way to the legal identity.\n */\n config?: SiteFooterConfig;\n /** The app's router link for the config's internal links (Next's `Link`). @default \"a\" */\n linkAs?: LinkComponent;\n};\n\nconst NO_STATUS = { shared: null, exceptions: new Map<string, Exclude<SiteStatus, \"released\">>() } as const;\n\n/** The footer of a Krizaka site or app: at most three lines — its links, the family, then signature · version · legal. */\nexport function SiteFooter({\n current,\n labels = familyLabels.en,\n children,\n version,\n env,\n path,\n legal: legalProp,\n controls,\n org,\n family: familyProp,\n products,\n variant = \"site\",\n tone = \"product\",\n config,\n linkAs,\n className,\n ...props\n}: SiteFooterProps) {\n const id = React.useId();\n const s = siteFooter({ variant, tone });\n const slim = variant === \"app\";\n const family = !slim && (familyProp ?? (current === \"krizaka\" && !config));\n const site = siteById(current);\n const krizaka = siteById(\"krizaka\");\n const currentId = orgIdOf(current);\n const tag = [env, version && `v${version.replace(/^v/, \"\")}`].filter(Boolean).join(\" · \");\n const own = !slim && React.Children.toArray(children).length > 0;\n const lang = labels.lang ?? \"en\";\n const company = labels.company ?? familyLabels.en.company!;\n const legal =\n legalProp ??\n (org && (\n <>\n {org.footer.legal.map((l) => (\n <SiteFooterLink key={l.id} href={l.url[lang]}>\n {l.label[lang]}\n </SiteFooterLink>\n ))}\n </>\n ));\n const here = (href: string) => path !== undefined && isThisPage(href, site.url, path);\n const productIds = products?.map(orgIdOf);\n // Products · Open source (GitHub closes it) · Krizaka (the company's pages; its home is the signature's link).\n const groups = familyGroups(org);\n const columns = [\n ...groups\n .filter((g) => g.group === \"products\")\n .map((g) => ({ ...g, entries: productIds ? g.entries.filter((e) => productIds.includes(e.id) || e.id === currentId) : g.entries })),\n { group: \"open-source\" as const, entries: groups.filter((g) => g.group === \"open-source\" || g.group === \"github\").flatMap((g) => g.entries) },\n ];\n const companyEntries = companyLinks.map((l) => ({ id: l.id, name: company[l.id], url: l.url[lang] }));\n return (\n <ToneContext.Provider value={tone}>\n <footer className={s.root({ className })} {...props}>\n <div className={s.inner()}>\n {own && <div className={s.row()}>{children}</div>}\n {config && !slim && <ConfigColumns s={s} config={config} id={id} labels={labels} linkAs={linkAs} path={path} />}\n {family && (\n <nav aria-label={labels.family} className={s.family()}>\n {[\n ...columns.map((c) => ({ key: c.group, title: labels.groups[c.group], entries: c.entries, ...columnStatus(c.entries) })),\n { key: \"krizaka\" as const, title: labels.groups.krizaka, entries: companyEntries, ...NO_STATUS },\n ]\n .filter((c) => c.entries.length > 0)\n .map((c) => (\n <details key={c.key} className={s.group()}>\n <summary className={s.summary()}>\n <span>\n <span id={`${id}-${c.key}`}>{c.title}</span>\n {c.shared && (\n <span className={s.note()}>\n <span aria-hidden=\"true\"> · </span>\n {labels.status[c.shared]}\n </span>\n )}\n </span>\n <svg aria-hidden=\"true\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"1.5\" className={s.chevron()}>\n <path d=\"M4 6l4 4 4-4\" strokeLinecap=\"round\" strokeLinejoin=\"round\" />\n </svg>\n </summary>\n <ul aria-labelledby={`${id}-${c.key}`} className={s.list()}>\n {c.entries.map((e) => {\n const isCompany = c.key === \"krizaka\";\n const atHome = isCompany && here(e.url);\n const exception = c.exceptions.get(e.id);\n const isCurrent = !isCompany && e.id === currentId;\n return (\n <li key={e.id}>\n <a\n href={e.url}\n aria-current={atHome ? \"page\" : isCurrent ? \"true\" : undefined}\n onClick={atHome ? backToTop : undefined}\n className={s.link()}\n >\n {e.name}\n {exception && <span className={s.note()}> ({labels.status[exception]})</span>}\n {isCurrent && <span className=\"sr-only\"> ({labels.current})</span>}\n </a>\n </li>\n );\n })}\n </ul>\n </details>\n ))}\n </nav>\n )}\n {config ? (\n <ConfigBottom s={s} config={config} krizaka={krizaka.url} brand={org?.brand.name ?? \"Krizaka\"} tag={tag} env={env} versionLabel={labels.version} linkAs={linkAs} path={path} controls={controls} />\n ) : (\n <div className={s.bottom()}>\n <a href={krizaka.url} className={s.signature()}>\n <ProductLogo id=\"krizaka\" size={18} animated={false} />\n {org ? org.footer.line[lang] : `${labels.signature[site.kind]} · ${labels.place}`}\n </a>\n {tag && (\n <span className={s.version()}>\n <span className=\"sr-only\">{labels.version} </span>\n {tag}\n </span>\n )}\n {legal && <div className={s.legal()}>{legal}</div>}\n {controls && <div className={s.controls()}>{controls}</div>}\n </div>\n )}\n </div>\n </footer>\n </ToneContext.Provider>\n );\n}\n\nconst isCurrent = (l: FooterLink, path?: string) => path !== undefined && !l.external && bare(l.href.split(/[?#]/)[0]!) === bare(path.split(/[?#]/)[0]!);\n\n/** The configured bottom line: the mark beside the legal identity, the version, the legal links and the socials. */\nfunction ConfigBottom({\n s,\n config,\n krizaka,\n brand,\n tag,\n env,\n versionLabel,\n linkAs,\n path,\n controls,\n}: Readonly<{\n s: ReturnType<typeof siteFooter>;\n config: SiteFooterConfig;\n krizaka: string;\n brand: string;\n tag: string;\n env?: string;\n versionLabel: string;\n linkAs?: LinkComponent;\n path?: string;\n controls?: React.ReactNode;\n}>) {\n const { legal, social } = config;\n const configured = (l: FooterLink) => <ConfigLink key={l.href} link={l} linkAs={linkAs} current={isCurrent(l, path)} />;\n const shown = legal.showVersion ? tag : env;\n const identity = [legal.legalName, legal.neq && `NEQ ${legal.neq}`, legal.city].filter(Boolean).join(\" · \");\n const versionText = (\n <>\n <span className=\"sr-only\">{versionLabel} </span>\n {shown}\n </>\n );\n return (\n <div className={s.bottom()}>\n {/* The company named once: its mark (home) beside its legal identity — never a second « by Technologies Krizaka ». */}\n <a href={krizaka} className={s.signature()} aria-label={brand}>\n <ProductLogo id=\"krizaka\" size={18} animated={false} />\n </a>\n <span className={s.identity()}>{identity}</span>\n {shown &&\n (legal.showVersion && legal.versionHref ? (\n <a href={legal.versionHref} className={s.version({ className: \"no-underline hover:text-fg focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\" })}>\n {versionText}\n </a>\n ) : (\n <span className={s.version()}>{versionText}</span>\n ))}\n {legal.links.length > 0 && <div className={s.legal()}>{legal.links.map(configured)}</div>}\n {social && social.length > 0 && <div className={s.legal()}>{social.map((x) => configured({ label: x.label, href: x.href, external: true }))}</div>}\n {controls && <div className={s.controls()}>{controls}</div>}\n </div>\n );\n}\n\n/** The admin-configured columns: a title (and status) over a list of links. */\nfunction ConfigColumns({\n s,\n config,\n id,\n labels,\n linkAs,\n path,\n}: Readonly<{ s: ReturnType<typeof siteFooter>; config: SiteFooterConfig; id: string; labels: FamilyLabels; linkAs?: LinkComponent; path?: string }>) {\n if (config.columns.length === 0) return null;\n return (\n <nav aria-label={config.label} className={s.columns()}>\n {config.columns.map((c) => (\n <div key={c.id} className={s.stack()}>\n <p id={`${id}-c-${c.id}`} className={s.title()}>\n {c.title}\n {c.status && (\n <span className={s.note()}>\n <span aria-hidden=\"true\"> · </span>\n {labels.status[c.status]}\n </span>\n )}\n </p>\n <ul aria-labelledby={`${id}-c-${c.id}`} className={s.stackList()}>\n {c.links.map((l) => (\n <li key={l.href}>\n <ConfigLink link={l} linkAs={linkAs} current={isCurrent(l, path)} />\n </li>\n ))}\n </ul>\n </div>\n ))}\n </nav>\n );\n}\n\n/** A configured link: the router's link inside the site, a plain `<a>` when it leaves it. */\nfunction ConfigLink({ link, linkAs, current }: Readonly<{ link: FooterLink; linkAs?: LinkComponent; current: boolean }>) {\n const s = siteFooter();\n const Comp = (link.external || !linkAs ? \"a\" : linkAs) as React.ElementType;\n return (\n <Comp href={link.href} className={s.link()} aria-current={current ? \"page\" : undefined}>\n {link.label}\n </Comp>\n );\n}\n\nexport type SiteFooterColumnProps = Omit<React.ComponentProps<\"div\">, \"title\"> & {\n /** The group's heading (“Docs”) — passed translated. */\n title: string;\n /** Its links (`SiteFooter.Link`). */\n children: React.ReactNode;\n};\n\n/** One of the site's own link groups, inline on the first line: its heading, then its links. */\nexport function SiteFooterColumn({ title, children, className, ...props }: SiteFooterColumnProps) {\n const id = React.useId();\n const tone = React.useContext(ToneContext);\n // A group with no link is not a group: only a heading over nothing.\n if (React.Children.toArray(children).length === 0) return null;\n const s = siteFooter({ tone });\n return (\n <div className={s.column({ className })} {...props}>\n <p id={id} className={s.title()}>\n {title}\n </p>\n <ul aria-labelledby={id} className={s.list({ className: \"pb-0\" })}>\n {React.Children.toArray(children).map((child, i) => <li key={i}>{child}</li>)}\n </ul>\n </div>\n );\n}\n\nexport type SiteFooterLinkProps = React.ComponentProps<\"a\"> & {\n /** The current page: `aria-current=\"page\"`. */\n active?: boolean;\n /** Renders your router's `<Link>`. */\n asChild?: boolean;\n};\n\n/** A link of the footer. */\nexport function SiteFooterLink({ active, asChild, className, ...props }: SiteFooterLinkProps) {\n const s = siteFooter();\n const Comp = asChild ? Slot.Root : \"a\";\n return <Comp aria-current={active ? \"page\" : undefined} className={s.link({ className })} {...props} />;\n}\n\nSiteFooter.Column = SiteFooterColumn;\nSiteFooter.Link = SiteFooterLink;\n","import { type OrgFacts, type SiteGroup, siteGroups, type SiteId, sites,type SiteStatus } from \"./sites\";\n\n/** The registry's id of Krizaka Lab was `motion`; `@krizaka/org` says `lab`. */\nconst ORG_ID: Partial<Record<SiteId, string>> = { motion: \"lab\" };\n\n/** The family to show, grouped in reading order: `org.family` when the host passes it, this package's registry otherwise. */\nexport function familyGroups(org?: Pick<OrgFacts, \"family\">): { group: SiteGroup; entries: FamilyItem[] }[] {\n const entries = org?.family\n ? org.family.map((e) => ({ id: e.id, name: e.name, url: e.url, group: e.group, status: e.status }))\n : sites.map((s) => ({ id: ORG_ID[s.id] ?? s.id, name: s.name, url: s.url, group: s.group, status: s.status }));\n return siteGroups.map((group) => ({ group, entries: entries.filter((e) => e.group === group) })).filter((g) => g.entries.length > 0);\n}\n\n/** The id `@krizaka/org` gives a site of this registry. */\nexport const orgIdOf = (id: SiteId): string => ORG_ID[id] ?? id;\n\ntype Pending = Exclude<SiteStatus, \"released\">;\ntype FamilyItem = { id: string; name: string; url: string; status: SiteStatus };\n\n/**\n * What a column says about its status, from data: when every entry shares one status other than `released`, it is said once\n * for the column (`shared`); when they differ, the most common one is the column's and only the exceptions wear a badge.\n */\nexport function columnStatus(entries: readonly { id: string; status: SiteStatus }[]): { shared: Pending | null; exceptions: Map<string, Pending> } {\n const counts = new Map<SiteStatus, number>();\n for (const e of entries) counts.set(e.status, (counts.get(e.status) ?? 0) + 1);\n const common = [...counts.entries()].sort((a, b) => b[1] - a[1])[0]?.[0] ?? null;\n const exceptions = new Map<string, Pending>();\n for (const e of entries) if (e.status !== common && e.status !== \"released\") exceptions.set(e.id, e.status);\n return { shared: common === null || common === \"released\" ? null : common, exceptions };\n}\n"],"mappings":";;;;;;;;;;;;;AAOO,IAAM,gBAAgB,EAAE,SAAS,GAAG,OAAO,GAAG,YAAY,EAAE;AAkDnE,IAAM,OAAO,CAAC,GAAsB,OAA4C;AAAA,EAC9E,OAAO,EAAE,aAAa,SAAY,EAAE,QAAS,EAAE,EAAE,QAAQ;AAAA,EACzD,MAAM,EAAE;AAAA,EACR,GAAI,EAAE,WAAW,EAAE,UAAU,KAAK,IAAI,CAAC;AACzC;AAGO,SAAS,sBACd,UACA,GACA,SAAmC,CAAC,GAClB;AAClB,QAAM,SAAS,SAAS,UAAU,CAAC,GAAG,QAAQ,CAAC,OAAO,OAAO,OAAO,CAAC,MAAM,EAAE,OAAO,EAAE,CAAC;AACvF,SAAO;AAAA,IACL,OAAO,EAAE,SAAS,QAAQ;AAAA,IAC1B,SAAS,SAAS,QAAQ,IAAI,CAAC,OAAO;AAAA,MACpC,IAAI,EAAE;AAAA,MACN,OAAO,EAAE,EAAE,QAAQ;AAAA,MACnB,GAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAO,IAAI,CAAC;AAAA,MACvC,OAAO,EAAE,MAAM,IAAI,CAAC,MAAM,KAAK,GAAG,CAAC,CAAC;AAAA,IACtC,EAAE;AAAA,IACF,OAAO,EAAE,GAAG,SAAS,OAAO,OAAO,SAAS,MAAM,MAAM,IAAI,CAAC,MAAM,KAAK,GAAG,CAAC,CAAC,EAAE;AAAA,IAC/E,GAAI,MAAM,SAAS,IAAI,EAAE,QAAQ,MAAM,IAAI,CAAC,OAAO,EAAE,IAAI,EAAE,IAAI,OAAO,E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,WAAW,EAAE,MAAAC,OAAM,QAAQ,QAAQ,GAA6E;AACvH,QAAM,IAAI,WAAW;AACrB,QAAM,OAAQA,MAAK,YAAY,CAAC,SAAS,MAAM;AAC/C,SACE,oBAAC,QAAK,MAAMA,MAAK,MAAM,WAAW,EAAE,KAAK,GAAG,gBAAc,UAAU,SAAS,QAC1E,UAAAA,MAAK,OACR;AAEJ;AAUO,SAAS,iBAAiB,EAAE,OAAO,UAAU,WAAW,GAAG,MAAM,GAA0B;AAChG,QAAM,KAAW,YAAM;AACvB,QAAM,OAAa,iBAAW,WAAW;AAEzC,MAAU,eAAS,QAAQ,QAAQ,EAAE,WAAW,EAAG,QAAO;AAC1D,QAAM,IAAI,WAAW,EAAE,KAAK,CAAC;AAC7B,SACE,qBAAC,SAAI,WAAW,EAAE,OAAO,EAAE,UAAU,CAAC,GAAI,GAAG,OAC3C;AAAA,wBAAC,OAAE,IAAQ,WAAW,EAAE,MAAM,GAC3B,iBACH;AAAA,IACA,oBAAC,QAAG,mBAAiB,IAAI,WAAW,EAAE,KAAK,EAAE,WAAW,OAAO,CAAC,GAC7D,UAAM,eAAS,QAAQ,QAAQ,EAAE,IAAI,CAAC,OAAO,MAAM,oBAAC,QAAY,mBAAJ,CAAU,CAAK,GAC9E;AAAA,KACF;AAEJ;AAUO,SAAS,eAAe,EAAE,QAAQ,SAAS,WAAW,GAAG,MAAM,GAAwB;AAC5F,QAAM,IAAI,WAAW;AACrB,QAAM,OAAO,UAAU,KAAK,OAAO;AACnC,SAAO,oBAAC,QAAK,gBAAc,SAAS,SAAS,QAAW,WAAW,EAAE,KAAK,EAAE,UAAU,CAAC,GAAI,GAAG,OAAO;AACvG;AAEA,WAAW,SAAS;AACpB,WAAW,OAAO;","names":["isCurrent","link"]}
1
+ {"version":3,"sources":["../src/site-footer/footer-config.ts","../src/site-footer/site-footer.tsx","../src/sites/family-groups.ts"],"sourcesContent":["// The footer as the admin configures it (krizaka-internal#591): the settings an app stores (`@krizaka/settings`, audited)\n// — words as message keys, so FR and EN come from the app's catalogues — and the resolved config `SiteFooter` draws.\n// Pure: no React, no fetch. The structure is the design rule (founder, 2026-11-01): a few short columns, then one legal\n// line that names the company once.\nimport type { SiteStatus } from \"../sites/sites\";\n\n/** At most four columns of at most six links: past that a footer is a sitemap, and nobody reads it. */\nexport const FOOTER_LIMITS = { columns: 4, links: 6, legalLinks: 4 } as const;\n\n/** A status said once, on a column's heading (never on each link). */\nexport type FooterStatus = Exclude<SiteStatus, \"released\">;\n\n/** A link, its words resolved. `external`: it leaves this site (a plain `<a>`, never the router). */\nexport type FooterLink = { label: string; href: string; external?: boolean };\n\n/** A column, its words resolved. */\nexport type FooterColumn = { id: string; title: string; status?: FooterStatus; links: readonly FooterLink[] };\n\n/** The legal line: who publishes the site, once — `legalName · NEQ … · city`, then the version and the legal links. */\nexport type FooterLegal = {\n legalName: string;\n /** The Québec enterprise number, shown as the publisher's legal identity (`NEQ 1182652231`). */\n neq?: string;\n city: string;\n showVersion: boolean;\n /** Where the version leads (the release's page), when it is a link. */\n versionHref?: string;\n links: readonly FooterLink[];\n};\n\n/** What `SiteFooter` draws from `config`: the columns, then the legal line and the socials. */\nexport type SiteFooterConfig = {\n /** The name of the columns' navigation (« Pied de page » / « Footer »). */\n label: string;\n columns: readonly FooterColumn[];\n legal: FooterLegal;\n social?: readonly { id: string; label: string; href: string }[];\n};\n\n/** A stored link: a message key (`labelKey`) or a proper noun the same in every language (`label`: « Verikora », « GitHub »). */\nexport type FooterLinkSetting = ({ labelKey: string; label?: never } | { label: string; labelKey?: never }) & {\n href: string;\n external?: boolean;\n};\n\n/** The footer as an app stores it in its settings. */\nexport type FooterSettings = {\n labelKey: string;\n columns: readonly { id: string; titleKey: string; status?: FooterStatus; links: readonly FooterLinkSetting[] }[];\n legal: { legalName: string; neq?: string; city: string; showVersion: boolean; versionHref?: string; links: readonly FooterLinkSetting[] };\n /** The ids of the org's social links (`@krizaka/org`) to show; their addresses are the org's, never typed here. */\n social?: readonly string[];\n};\n\n/** A social link of the org (`@krizaka/org` `links.social`). */\nexport type OrgSocialLink = { id: string; label: string; url: string };\n\nconst link = (l: FooterLinkSetting, t: (key: string) => string): FooterLink => ({\n label: l.labelKey === undefined ? l.label! : t(l.labelKey),\n href: l.href,\n ...(l.external ? { external: true } : {}),\n});\n\n/** The settings, their words read from the app's messages (`t`) and the socials from the org's list. */\nexport function resolveFooterSettings(\n settings: FooterSettings,\n t: (key: string) => string,\n social: readonly OrgSocialLink[] = [],\n): SiteFooterConfig {\n const shown = (settings.social ?? []).flatMap((id) => social.filter((s) => s.id === id));\n return {\n label: t(settings.labelKey),\n columns: settings.columns.map((c) => ({\n id: c.id,\n title: t(c.titleKey),\n ...(c.status ? { status: c.status } : {}),\n links: c.links.map((l) => link(l, t)),\n })),\n legal: { ...settings.legal, links: settings.legal.links.map((l) => link(l, t)) },\n ...(shown.length > 0 ? { social: shown.map((s) => ({ id: s.id, label: s.label, href: s.url })) } : {}),\n };\n}\n\n/**\n * What is wrong with a footer's settings — the admin's form refuses to save while the list is not empty: too many\n * columns or links, a link twice, an empty column, an `http:` or a development address, a malformed NEQ.\n */\nexport function footerSettingsProblems(settings: FooterSettings): string[] {\n return [...limitProblems(settings), ...linkProblems(settings), ...legalProblems(settings)];\n}\n\nfunction limitProblems(settings: FooterSettings): string[] {\n const problems: string[] = [];\n if (settings.columns.length > FOOTER_LIMITS.columns) problems.push(`at most ${FOOTER_LIMITS.columns} columns`);\n if (settings.legal.links.length > FOOTER_LIMITS.legalLinks) problems.push(`at most ${FOOTER_LIMITS.legalLinks} legal links`);\n for (const c of settings.columns) {\n if (c.links.length === 0) problems.push(`column ${c.id}: no link`);\n if (c.links.length > FOOTER_LIMITS.links) problems.push(`column ${c.id}: at most ${FOOTER_LIMITS.links} links`);\n }\n return problems;\n}\n\nfunction hrefProblems(where: string, l: { href: string; external?: boolean }): string[] {\n const problems: string[] = [];\n if (/^http:/i.test(l.href)) problems.push(`${where}: ${l.href} is not https`);\n if (/^https?:\\/\\/dev\\./i.test(l.href)) problems.push(`${where}: ${l.href} is a development host`);\n if (l.external && !/^[a-z][a-z0-9+.-]*:/i.test(l.href)) problems.push(`${where}: ${l.href} is external but relative`);\n return problems;\n}\n\nfunction linkProblems(settings: FooterSettings): string[] {\n const problems: string[] = [];\n const seen = new Set<string>();\n const all = [...settings.columns.flatMap((c) => c.links.map((l) => ({ where: c.id, l }))), ...settings.legal.links.map((l) => ({ where: \"legal\", l }))];\n for (const { where, l } of all) {\n if (seen.has(l.href)) problems.push(`${where}: ${l.href} is already in the footer`);\n seen.add(l.href);\n problems.push(...hrefProblems(where, l));\n }\n return problems;\n}\n\nfunction legalProblems(settings: FooterSettings): string[] {\n const problems: string[] = [];\n if (settings.legal.neq !== undefined && !/^\\d{10}$/.test(settings.legal.neq)) problems.push(\"legal: the NEQ has ten digits\");\n if (settings.legal.legalName.trim() === \"\") problems.push(\"legal: the legal name is required\");\n return problems;\n}\n","// Client (the mark holds an id). The footer shared by every site and app of the Krizaka family — compact (founder,\n// 2026-10-30, krizaka/krizaka-internal#754: « des footers de 10 lignes »): at most three lines on a desktop —\n// 1. the site's own links, each group inline (`Docs Get started · Components`);\n// 2. the family, grouped inline (Products · Open source · Krizaka), names read from `org.family` of `@krizaka/org`;\n// 3. one line: the mark and the org's signature, the version, the legal links, the host's controls (language, theme).\n// On a phone the family's groups fold (`<details>`), the rest wraps. `variant=\"app\"` keeps line 3 only. Same structure on\n// the Cahier sites and the products (`tone`). No link twice, no site block, no names typed here when `org` is given.\nimport { InstagramIcon, YoutubeIcon } from \"@krizaka/icons\";\nimport { Slot } from \"radix-ui\";\nimport * as React from \"react\";\nimport { tv } from \"tailwind-variants\";\n\n// ProductLogo, not KrizakaLogo: one import path keeps every mark in one shared chunk (KrizakaLogo alone split it: +871 B gzip on the typical page).\nimport type { LinkComponent } from \"../block-link\";\nimport { ProductLogo } from \"../marks/ProductLogo\";\nimport { columnStatus, familyGroups, orgIdOf } from \"../sites/family-groups\";\nimport { companyLinks, type FamilyLabels, familyLabels, type OrgFacts, siteById, type SiteId, type SiteStatus } from \"../sites/sites\";\nimport type { FooterLink, SiteFooterConfig } from \"./footer-config\";\n\nexport const siteFooter = tv({\n slots: {\n root: \"w-full border-t border-border-subtle bg-surface-0 text-fg\",\n inner:\n \"mx-auto grid w-full max-w-[calc(var(--kz-page-max,72rem)_+_2*var(--kz-page-gutter,clamp(16px,3.2vw,32px)))] grid-cols-[minmax(0,1fr)] gap-3 px-[var(--kz-page-gutter,clamp(16px,3.2vw,32px))] py-6\",\n row: \"flex min-w-0 flex-wrap items-baseline gap-x-6 gap-y-2\",\n family: \"grid min-w-0 grid-cols-[minmax(0,1fr)] gap-1 lg:flex lg:flex-wrap lg:items-baseline lg:gap-x-6 lg:gap-y-2\",\n group:\n \"group/fold min-w-0 lg:[&::details-content]:[content-visibility:visible] lg:[&::details-content]:contents lg:[&>summary]:pointer-events-none lg:inline-flex lg:items-baseline lg:gap-2\",\n summary:\n \"flex min-h-11 cursor-pointer list-none items-center justify-between rounded-md text-xs font-semibold text-fg-secondary [&::-webkit-details-marker]:hidden \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring lg:inline lg:min-h-0 lg:cursor-default\",\n chevron: \"size-4 shrink-0 transition-transform group-open/fold:rotate-180 motion-reduce:transition-none lg:hidden\",\n column: \"inline-flex min-w-0 flex-wrap items-baseline gap-x-2 gap-y-1\",\n title: \"text-xs font-semibold text-fg-secondary\",\n note: \"font-normal\",\n list: \"flex min-w-0 flex-wrap items-baseline gap-x-3 gap-y-1 pb-2 lg:pb-0\",\n link:\n \"inline-flex min-h-6 min-w-0 items-center rounded-md text-sm [overflow-wrap:anywhere] text-fg-secondary no-underline transition-colors hover:text-fg \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring aria-[current=page]:text-fg aria-[current=page]:font-semibold aria-[current=true]:text-fg aria-[current=true]:font-semibold\",\n bottom: \"flex flex-wrap items-center gap-x-4 gap-y-2 text-xs text-fg-secondary\",\n signature:\n \"inline-flex items-center gap-2 rounded-md font-medium text-fg no-underline hover:text-fg-accent focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\",\n version:\n \"rounded-sm border border-border-subtle bg-surface-2 px-2 py-0.5 font-mono text-[11px] text-fg-secondary\",\n legal: \"flex flex-wrap items-center gap-x-4 gap-y-2\",\n controls: \"flex flex-wrap items-center gap-2 sm:ml-auto\",\n // `config`: real columns — two on a phone, side by side from `sm`, each a heading over a stacked list.\n columns: \"grid min-w-0 grid-cols-2 gap-x-6 gap-y-6 pb-2 sm:grid-flow-col sm:grid-cols-none sm:auto-cols-[minmax(0,13rem)] sm:gap-x-10\",\n stack: \"flex min-w-0 flex-col gap-2\",\n stackList: \"flex min-w-0 flex-col gap-1\",\n identity: \"text-fg-secondary\",\n // The accounts drawn as their icon (the name stays for screen readers): colour change only on hover, never movement.\n socials: \"flex flex-wrap items-center gap-x-3 gap-y-2\",\n social:\n \"inline-flex min-h-6 min-w-6 items-center justify-center rounded-md text-fg-secondary no-underline transition-colors hover:text-fg \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\",\n },\n variants: {\n // `site`: the three lines. `docs`: the same on the documentation's width. `app`: line 3 only, inside a signed-in product.\n variant: {\n site: {},\n docs: {\n inner: \"max-w-[calc(var(--kz-page-max-docs,88rem)_+_2*var(--kz-page-gutter,clamp(16px,3.2vw,32px)))]\",\n },\n app: {\n root: \"bg-transparent\",\n inner: \"py-3\",\n },\n },\n // `product`: the products' plain Krizaka UI. `cahier`: the Cahier sites (www, blog, ui., java., ts., lab.) — the\n // headings in the Cahier's hand; the structure is the same.\n tone: {\n product: {},\n cahier: {\n title: \"font-[family-name:var(--kz-font-display,inherit)] italic\",\n summary: \"font-[family-name:var(--kz-font-display,inherit)] italic\",\n },\n },\n },\n defaultVariants: { variant: \"site\", tone: \"product\" },\n});\n\nconst bare = (p: string) => p.replace(/^\\/(en|fr)(?=\\/|$)/, \"\").replace(/\\/+$/, \"\") || \"/\";\n\n/** Is `href` (an absolute family address) the page `path` of the site at `siteUrl`? Locale prefix and trailing slash do not count. */\nfunction isThisPage(href: string, siteUrl: string, path: string): boolean {\n try {\n const target = new URL(href);\n return target.host === new URL(siteUrl).host && bare(target.pathname) === bare(path.split(/[?#]/)[0]!);\n } catch {\n return false;\n }\n}\n\n/** The link to the page you are on: no reload, back to the top (the browser would otherwise keep or restore the scroll). */\nfunction backToTop(event: React.MouseEvent<HTMLAnchorElement>) {\n if (event.metaKey || event.ctrlKey || event.shiftKey || event.button !== 0) return;\n event.preventDefault();\n window.scrollTo({ top: 0, behavior: \"auto\" });\n}\n\ntype Tone = \"product\" | \"cahier\";\nconst ToneContext = React.createContext<Tone>(\"product\");\n\nexport type SiteFooterProps = Omit<React.ComponentProps<\"footer\">, \"children\"> & {\n /** The site this footer belongs to (`@krizaka/ui/sites`): marked in the family, its address for `path`. */\n current: SiteId;\n /**\n * The family's words, passed translated: `familyLabels.fr` from `@krizaka/ui/sites`, or your own of the same shape.\n * @default familyLabels.en\n */\n labels?: FamilyLabels;\n /** The site's own link groups (`SiteFooter.Column`), on the first line. */\n children?: React.ReactNode;\n /** The version the site runs (`1.2.3`, shown `v1.2.3`). */\n version?: string;\n /** The environment, when it is not production (`DEV`). */\n env?: string;\n /**\n * The path of the page being read on this site (`/en/story`, `/blog/…`): the company link that points to this very\n * page says so (`aria-current=\"page\"`) and a click on it scrolls to the top instead of reloading.\n */\n path?: string;\n /**\n * Shows the family on the second line, folded on a phone. The links to the other sites live on krizaka.com only\n * (founder rule, 2026-10-30): every other site and its documentation opts in on purpose, none by default.\n * @default current === \"krizaka\" (and never in `variant=\"app\"`)\n */\n family?: boolean;\n /** Only these products in the Products group (the current site always kept). Omit it to list every product. */\n products?: readonly SiteId[];\n /**\n * The organisation's public facts (`org` of `@krizaka/org`) — pass them on every site. The names and addresses of the\n * family are then `org.family`, the signature is `org.footer.line` (« Une entreprise de Technologies Krizaka · Fait à\n * Montréal », the same everywhere) and, without `legal`, the legal links are `org.footer.legal`.\n */\n org?: OrgFacts;\n /** The legal links, when not the org's (`SiteFooter.Link`s). */\n legal?: React.ReactNode;\n /** The host's controls at the end of the last line: the language switch, the theme toggle. */\n controls?: React.ReactNode;\n /**\n * `site` — every public site. `docs` — the same under documentation, on its width. `app` — inside a signed-in product:\n * the last line only; render it once, in the layout.\n * @default \"site\"\n */\n variant?: \"site\" | \"docs\" | \"app\";\n /** `cahier` on the Cahier sites (www, blog, ui., java., ts., lab.), `product` in the products. @default \"product\" */\n tone?: Tone;\n /**\n * The footer as the admin configured it (`resolveFooterSettings` of the app's settings): its columns, then one legal\n * line — `legalName · NEQ … · city`, the version when `showVersion`, the legal links, the socials. With it the family\n * is not drawn (the columns hold what the site wants) and the org's signature gives way to the legal identity.\n */\n config?: SiteFooterConfig;\n /** The app's router link for the config's internal links (Next's `Link`). @default \"a\" */\n linkAs?: LinkComponent;\n};\n\nconst NO_STATUS = { shared: null, exceptions: new Map<string, Exclude<SiteStatus, \"released\">>() } as const;\n\n/** The footer of a Krizaka site or app: at most three lines — its links, the family, then signature · version · legal. */\nexport function SiteFooter({\n current,\n labels = familyLabels.en,\n children,\n version,\n env,\n path,\n legal: legalProp,\n controls,\n org,\n family: familyProp,\n products,\n variant = \"site\",\n tone = \"product\",\n config,\n linkAs,\n className,\n ...props\n}: SiteFooterProps) {\n const id = React.useId();\n const s = siteFooter({ variant, tone });\n const slim = variant === \"app\";\n const family = !slim && (familyProp ?? (current === \"krizaka\" && !config));\n const site = siteById(current);\n const krizaka = siteById(\"krizaka\");\n const currentId = orgIdOf(current);\n const tag = [env, version && `v${version.replace(/^v/, \"\")}`].filter(Boolean).join(\" · \");\n const own = !slim && React.Children.toArray(children).length > 0;\n const lang = labels.lang ?? \"en\";\n const company = labels.company ?? familyLabels.en.company!;\n const legal =\n legalProp ??\n (org && (\n <>\n {org.footer.legal.map((l) => (\n <SiteFooterLink key={l.id} href={l.url[lang]}>\n {l.label[lang]}\n </SiteFooterLink>\n ))}\n </>\n ));\n const here = (href: string) => path !== undefined && isThisPage(href, site.url, path);\n const productIds = products?.map(orgIdOf);\n // Products · Open source (GitHub closes it) · Krizaka (the company's pages; its home is the signature's link).\n const groups = familyGroups(org);\n const columns = [\n ...groups\n .filter((g) => g.group === \"products\")\n .map((g) => ({ ...g, entries: productIds ? g.entries.filter((e) => productIds.includes(e.id) || e.id === currentId) : g.entries })),\n { group: \"open-source\" as const, entries: groups.filter((g) => g.group === \"open-source\" || g.group === \"github\").flatMap((g) => g.entries) },\n ];\n const companyEntries = companyLinks.map((l) => ({ id: l.id, name: company[l.id], url: l.url[lang] }));\n return (\n <ToneContext.Provider value={tone}>\n <footer className={s.root({ className })} {...props}>\n <div className={s.inner()}>\n {own && <div className={s.row()}>{children}</div>}\n {config && !slim && <ConfigColumns s={s} config={config} id={id} labels={labels} linkAs={linkAs} path={path} />}\n {family && (\n <nav aria-label={labels.family} className={s.family()}>\n {[\n ...columns.map((c) => ({ key: c.group, title: labels.groups[c.group], entries: c.entries, ...columnStatus(c.entries) })),\n { key: \"krizaka\" as const, title: labels.groups.krizaka, entries: companyEntries, ...NO_STATUS },\n ]\n .filter((c) => c.entries.length > 0)\n .map((c) => (\n <details key={c.key} className={s.group()}>\n <summary className={s.summary()}>\n <span>\n <span id={`${id}-${c.key}`}>{c.title}</span>\n {c.shared && (\n <span className={s.note()}>\n <span aria-hidden=\"true\"> · </span>\n {labels.status[c.shared]}\n </span>\n )}\n </span>\n <svg aria-hidden=\"true\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"1.5\" className={s.chevron()}>\n <path d=\"M4 6l4 4 4-4\" strokeLinecap=\"round\" strokeLinejoin=\"round\" />\n </svg>\n </summary>\n <ul aria-labelledby={`${id}-${c.key}`} className={s.list()}>\n {c.entries.map((e) => {\n const isCompany = c.key === \"krizaka\";\n const atHome = isCompany && here(e.url);\n const exception = c.exceptions.get(e.id);\n const isCurrent = !isCompany && e.id === currentId;\n return (\n <li key={e.id}>\n <a\n href={e.url}\n aria-current={atHome ? \"page\" : isCurrent ? \"true\" : undefined}\n onClick={atHome ? backToTop : undefined}\n className={s.link()}\n >\n {e.name}\n {exception && <span className={s.note()}> ({labels.status[exception]})</span>}\n {isCurrent && <span className=\"sr-only\"> ({labels.current})</span>}\n </a>\n </li>\n );\n })}\n </ul>\n </details>\n ))}\n </nav>\n )}\n {config ? (\n <ConfigBottom s={s} config={config} krizaka={krizaka.url} brand={org?.brand.name ?? \"Krizaka\"} tag={tag} env={env} versionLabel={labels.version} linkAs={linkAs} path={path} controls={controls} />\n ) : (\n <div className={s.bottom()}>\n <a href={krizaka.url} className={s.signature()}>\n <ProductLogo id=\"krizaka\" size={18} animated={false} />\n {org ? org.footer.line[lang] : `${labels.signature[site.kind]} · ${labels.place}`}\n </a>\n {tag && (\n <span className={s.version()}>\n <span className=\"sr-only\">{labels.version} </span>\n {tag}\n </span>\n )}\n {legal && <div className={s.legal()}>{legal}</div>}\n <FooterSocials s={s} links={(org?.links?.social ?? []).map((x) => ({ id: x.id, label: x.label, href: x.url }))} />\n {controls && <div className={s.controls()}>{controls}</div>}\n </div>\n )}\n </div>\n </footer>\n </ToneContext.Provider>\n );\n}\n\nconst isCurrent = (l: FooterLink, path?: string) => path !== undefined && !l.external && bare(l.href.split(/[?#]/)[0]!) === bare(path.split(/[?#]/)[0]!);\n\n/** The configured bottom line: the mark beside the legal identity, the version, the legal links and the socials. */\nfunction ConfigBottom({\n s,\n config,\n krizaka,\n brand,\n tag,\n env,\n versionLabel,\n linkAs,\n path,\n controls,\n}: Readonly<{\n s: ReturnType<typeof siteFooter>;\n config: SiteFooterConfig;\n krizaka: string;\n brand: string;\n tag: string;\n env?: string;\n versionLabel: string;\n linkAs?: LinkComponent;\n path?: string;\n controls?: React.ReactNode;\n}>) {\n const { legal, social } = config;\n const configured = (l: FooterLink) => <ConfigLink key={l.href} link={l} linkAs={linkAs} current={isCurrent(l, path)} />;\n const shown = legal.showVersion ? tag : env;\n const identity = [legal.legalName, legal.neq && `NEQ ${legal.neq}`, legal.city].filter(Boolean).join(\" · \");\n const versionText = (\n <>\n <span className=\"sr-only\">{versionLabel} </span>\n {shown}\n </>\n );\n return (\n <div className={s.bottom()}>\n {/* The company named once: its mark (home) beside its legal identity — never a second « by Technologies Krizaka ». */}\n <a href={krizaka} className={s.signature()} aria-label={brand}>\n <ProductLogo id=\"krizaka\" size={18} animated={false} />\n </a>\n <span className={s.identity()}>{identity}</span>\n {shown &&\n (legal.showVersion && legal.versionHref ? (\n <a href={legal.versionHref} className={s.version({ className: \"no-underline hover:text-fg focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\" })}>\n {versionText}\n </a>\n ) : (\n <span className={s.version()}>{versionText}</span>\n ))}\n {legal.links.length > 0 && <div className={s.legal()}>{legal.links.map(configured)}</div>}\n <FooterSocials s={s} links={social ?? []} />\n {controls && <div className={s.controls()}>{controls}</div>}\n </div>\n );\n}\n\n/** Icons of the accounts a glyph exists for; any other account stays a text link. */\nconst SOCIAL_ICONS: Readonly<Partial<Record<string, typeof InstagramIcon>>> = { instagram: InstagramIcon, youtube: YoutubeIcon };\n\n/** The company's accounts: each is its icon (decorative) in a link named by the account, opening in a new tab. */\nfunction FooterSocials({ s, links }: Readonly<{ s: ReturnType<typeof siteFooter>; links: readonly { id: string; label: string; href: string }[] }>) {\n if (links.length === 0) return null;\n return (\n <div className={s.socials()}>\n {links.map((x) => {\n const Icon = SOCIAL_ICONS[x.id];\n return (\n <a key={x.id} href={x.href} target=\"_blank\" rel=\"noopener noreferrer\" className={Icon ? s.social() : s.link()}>\n {Icon && <Icon size={20} />}\n {Icon ? <span className=\"sr-only\">{x.label}</span> : x.label}\n </a>\n );\n })}\n </div>\n );\n}\n\n/** The admin-configured columns: a title (and status) over a list of links. */\nfunction ConfigColumns({\n s,\n config,\n id,\n labels,\n linkAs,\n path,\n}: Readonly<{ s: ReturnType<typeof siteFooter>; config: SiteFooterConfig; id: string; labels: FamilyLabels; linkAs?: LinkComponent; path?: string }>) {\n if (config.columns.length === 0) return null;\n return (\n <nav aria-label={config.label} className={s.columns()}>\n {config.columns.map((c) => (\n <div key={c.id} className={s.stack()}>\n <p id={`${id}-c-${c.id}`} className={s.title()}>\n {c.title}\n {c.status && (\n <span className={s.note()}>\n <span aria-hidden=\"true\"> · </span>\n {labels.status[c.status]}\n </span>\n )}\n </p>\n <ul aria-labelledby={`${id}-c-${c.id}`} className={s.stackList()}>\n {c.links.map((l) => (\n <li key={l.href}>\n <ConfigLink link={l} linkAs={linkAs} current={isCurrent(l, path)} />\n </li>\n ))}\n </ul>\n </div>\n ))}\n </nav>\n );\n}\n\n/** A configured link: the router's link inside the site, a plain `<a>` when it leaves it. */\nfunction ConfigLink({ link, linkAs, current }: Readonly<{ link: FooterLink; linkAs?: LinkComponent; current: boolean }>) {\n const s = siteFooter();\n const Comp = (link.external || !linkAs ? \"a\" : linkAs) as React.ElementType;\n return (\n <Comp href={link.href} className={s.link()} aria-current={current ? \"page\" : undefined}>\n {link.label}\n </Comp>\n );\n}\n\nexport type SiteFooterColumnProps = Omit<React.ComponentProps<\"div\">, \"title\"> & {\n /** The group's heading (“Docs”) — passed translated. */\n title: string;\n /** Its links (`SiteFooter.Link`). */\n children: React.ReactNode;\n};\n\n/** One of the site's own link groups, inline on the first line: its heading, then its links. */\nexport function SiteFooterColumn({ title, children, className, ...props }: SiteFooterColumnProps) {\n const id = React.useId();\n const tone = React.useContext(ToneContext);\n // A group with no link is not a group: only a heading over nothing.\n if (React.Children.toArray(children).length === 0) return null;\n const s = siteFooter({ tone });\n return (\n <div className={s.column({ className })} {...props}>\n <p id={id} className={s.title()}>\n {title}\n </p>\n <ul aria-labelledby={id} className={s.list({ className: \"pb-0\" })}>\n {React.Children.toArray(children).map((child, i) => <li key={i}>{child}</li>)}\n </ul>\n </div>\n );\n}\n\nexport type SiteFooterLinkProps = React.ComponentProps<\"a\"> & {\n /** The current page: `aria-current=\"page\"`. */\n active?: boolean;\n /** Renders your router's `<Link>`. */\n asChild?: boolean;\n};\n\n/** A link of the footer. */\nexport function SiteFooterLink({ active, asChild, className, ...props }: SiteFooterLinkProps) {\n const s = siteFooter();\n const Comp = asChild ? Slot.Root : \"a\";\n return <Comp aria-current={active ? \"page\" : undefined} className={s.link({ className })} {...props} />;\n}\n\nSiteFooter.Column = SiteFooterColumn;\nSiteFooter.Link = SiteFooterLink;\n","import { type OrgFacts, type SiteGroup, siteGroups, type SiteId, sites,type SiteStatus } from \"./sites\";\n\n/** The registry's id of Krizaka Lab was `motion`; `@krizaka/org` says `lab`. */\nconst ORG_ID: Partial<Record<SiteId, string>> = { motion: \"lab\" };\n\n/** The family to show, grouped in reading order: `org.family` when the host passes it, this package's registry otherwise. */\nexport function familyGroups(org?: Pick<OrgFacts, \"family\">): { group: SiteGroup; entries: FamilyItem[] }[] {\n const entries = org?.family\n ? org.family.map((e) => ({ id: e.id, name: e.name, url: e.url, group: e.group, status: e.status }))\n : sites.map((s) => ({ id: ORG_ID[s.id] ?? s.id, name: s.name, url: s.url, group: s.group, status: s.status }));\n return siteGroups.map((group) => ({ group, entries: entries.filter((e) => e.group === group) })).filter((g) => g.entries.length > 0);\n}\n\n/** The id `@krizaka/org` gives a site of this registry. */\nexport const orgIdOf = (id: SiteId): string => ORG_ID[id] ?? id;\n\ntype Pending = Exclude<SiteStatus, \"released\">;\ntype FamilyItem = { id: string; name: string; url: string; status: SiteStatus };\n\n/**\n * What a column says about its status, from data: when every entry shares one status other than `released`, it is said once\n * for the column (`shared`); when they differ, the most common one is the column's and only the exceptions wear a badge.\n */\nexport function columnStatus(entries: readonly { id: string; status: SiteStatus }[]): { shared: Pending | null; exceptions: Map<string, Pending> } {\n const counts = new Map<SiteStatus, number>();\n for (const e of entries) counts.set(e.status, (counts.get(e.status) ?? 0) + 1);\n const common = [...counts.entries()].sort((a, b) => b[1] - a[1])[0]?.[0] ?? null;\n const exceptions = new Map<string, Pending>();\n for (const e of entries) if (e.status !== common && e.status !== \"released\") exceptions.set(e.id, e.status);\n return { shared: common === null || common === \"released\" ? null : common, exceptions };\n}\n"],"mappings":";;;;;;;;;;;;;AAOO,IAAM,gBAAgB,EAAE,SAAS,GAAG,OAAO,GAAG,YAAY,EAAE;AAkDnE,IAAM,OAAO,CAAC,GAAsB,OAA4C;AAAA,EAC9E,OAAO,EAAE,aAAa,SAAY,EAAE,QAAS,EAAE,EAAE,QAAQ;AAAA,EACzD,MAAM,EAAE;AAAA,EACR,GAAI,EAAE,WAAW,EAAE,UAAU,KAAK,IAAI,CAAC;AACzC;AAGO,SAAS,sBACd,UACA,GACA,SAAmC,CAAC,GAClB;AAClB,QAAM,SAAS,SAAS,UAAU,CAAC,GAAG,QAAQ,CAAC,OAAO,OAAO,OAAO,CAAC,MAAM,EAAE,OAAO,EAAE,CAAC;AACvF,SAAO;AAAA,IACL,OAAO,EAAE,SAAS,QAAQ;AAAA,IAC1B,SAAS,SAAS,QAAQ,IAAI,CAAC,OAAO;AAAA,MACpC,IAAI,EAAE;AAAA,MACN,OAAO,EAAE,EAAE,QAAQ;AAAA,MACnB,GAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAO,IAAI,CAAC;AAAA,MACvC,OAAO,EAAE,MAAM,IAAI,CAAC,MAAM,KAAK,GAAG,CAAC,CAAC;AAAA,IACtC,EAAE;AAAA,IACF,OAAO,EAAE,GAAG,SAAS,OAAO,OAAO,SAAS,MAAM,MAAM,IAAI,CAAC,MAAM,KAAK,GAAG,CAAC,CAAC,EAAE;AAAA,IAC/E,GAAI,MAAM,SAAS,IAAI,EAAE,QAAQ,MAAM,IAAI,CAAC,OAAO,EAAE,IAAI,EAAE,IAAI,OAAO,EAAE,OAAO,MAAM,EAAE,IAAI,EAAE,EAAE,IAAI,CAAC;AAAA,EACtG;AACF;AAMO,SAAS,uBAAuB,UAAoC;AACzE,SAAO,CAAC,GAAG,cAAc,QAAQ,GAAG,GAAG,aAAa,QAAQ,GAAG,GAAG,c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AAK,GAC9E;AAAA,KACF;AAEJ;AAUO,SAAS,eAAe,EAAE,QAAQ,SAAS,WAAW,GAAG,MAAM,GAAwB;AAC5F,QAAM,IAAI,WAAW;AACrB,QAAM,OAAO,UAAU,KAAK,OAAO;AACnC,SAAO,oBAAC,QAAK,gBAAc,SAAS,SAAS,QAAW,WAAW,EAAE,KAAK,EAAE,UAAU,CAAC,GAAI,GAAG,OAAO;AACvG;AAEA,WAAW,SAAS;AACpB,WAAW,OAAO;","names":["isCurrent","link"]}
@@ -0,0 +1,170 @@
1
+ /** At most four columns of at most six links: past that a footer is a sitemap, and nobody reads it. */
2
+ declare const FOOTER_LIMITS: {
3
+ readonly columns: 4;
4
+ readonly links: 6;
5
+ readonly legalLinks: 4;
6
+ };
7
+ /** A status said once, on a column's heading (never on each link). */
8
+ type FooterStatus = Exclude<SiteStatus, "released">;
9
+ /** A link, its words resolved. `external`: it leaves this site (a plain `<a>`, never the router). */
10
+ type FooterLink = {
11
+ label: string;
12
+ href: string;
13
+ external?: boolean;
14
+ };
15
+ /** A column, its words resolved. */
16
+ type FooterColumn = {
17
+ id: string;
18
+ title: string;
19
+ status?: FooterStatus;
20
+ links: readonly FooterLink[];
21
+ };
22
+ /** The legal line: who publishes the site, once — `legalName · NEQ … · city`, then the version and the legal links. */
23
+ type FooterLegal = {
24
+ legalName: string;
25
+ /** The Québec enterprise number, shown as the publisher's legal identity (`NEQ 1182652231`). */
26
+ neq?: string;
27
+ city: string;
28
+ showVersion: boolean;
29
+ /** Where the version leads (the release's page), when it is a link. */
30
+ versionHref?: string;
31
+ links: readonly FooterLink[];
32
+ };
33
+ /** What `SiteFooter` draws from `config`: the columns, then the legal line and the socials. */
34
+ type SiteFooterConfig = {
35
+ /** The name of the columns' navigation (« Pied de page » / « Footer »). */
36
+ label: string;
37
+ columns: readonly FooterColumn[];
38
+ legal: FooterLegal;
39
+ social?: readonly {
40
+ id: string;
41
+ label: string;
42
+ href: string;
43
+ }[];
44
+ };
45
+ /** A stored link: a message key (`labelKey`) or a proper noun the same in every language (`label`: « Verikora », « GitHub »). */
46
+ type FooterLinkSetting = ({
47
+ labelKey: string;
48
+ label?: never;
49
+ } | {
50
+ label: string;
51
+ labelKey?: never;
52
+ }) & {
53
+ href: string;
54
+ external?: boolean;
55
+ };
56
+ /** The footer as an app stores it in its settings. */
57
+ type FooterSettings = {
58
+ labelKey: string;
59
+ columns: readonly {
60
+ id: string;
61
+ titleKey: string;
62
+ status?: FooterStatus;
63
+ links: readonly FooterLinkSetting[];
64
+ }[];
65
+ legal: {
66
+ legalName: string;
67
+ neq?: string;
68
+ city: string;
69
+ showVersion: boolean;
70
+ versionHref?: string;
71
+ links: readonly FooterLinkSetting[];
72
+ };
73
+ /** The ids of the org's social links (`@krizaka/org`) to show; their addresses are the org's, never typed here. */
74
+ social?: readonly string[];
75
+ };
76
+ /** A social link of the org (`@krizaka/org` `links.social`). */
77
+ type OrgSocialLink = {
78
+ id: string;
79
+ label: string;
80
+ url: string;
81
+ };
82
+ /** The settings, their words read from the app's messages (`t`) and the socials from the org's list. */
83
+ declare function resolveFooterSettings(settings: FooterSettings, t: (key: string) => string, social?: readonly OrgSocialLink[]): SiteFooterConfig;
84
+ /**
85
+ * What is wrong with a footer's settings — the admin's form refuses to save while the list is not empty: too many
86
+ * columns or links, a link twice, an empty column, an `http:` or a development address, a malformed NEQ.
87
+ */
88
+ declare function footerSettingsProblems(settings: FooterSettings): string[];
89
+
90
+ /** A site of the family. */
91
+ type SiteId = "krizaka" | "sovkora" | "verikora" | "folioviv" | "ui" | "java" | "ts" | "motion" | "github";
92
+ /** What a site is: the company, a product, or an open-source project. It chooses the footer's signature line. */
93
+ type SiteKind = "company" | "product" | "open-source";
94
+ /**
95
+ * `released`: open to visit. `upcoming`: announced, not released yet (said "Coming soon"). `construction`: under
96
+ * construction — nothing offered (a QA-only app may run; the public page says so). `development`: being built in the
97
+ * open, with a dev site (said "In development"). A site with none yet would use its repository as its address.
98
+ */
99
+ type SiteStatus = "released" | "upcoming" | "construction" | "development";
100
+ /** The groups of the family, in reading order: Krizaka · Products · Open source · GitHub. */
101
+ type SiteGroup = "krizaka" | "products" | "open-source" | "github";
102
+ /** The languages the family's words are written in. */
103
+ type SiteLocale = "en" | "fr";
104
+ /** The company's own pages, the footer's « Krizaka » column (the brand's home is the signature line's link). */
105
+ type CompanyLinkId = "story" | "blog" | "contact";
106
+ /** The words of the family: the switcher, the footer, each site's one line. */
107
+ interface FamilyLabels {
108
+ /** The family's name: the switcher's navigation and its button, the footer's navigation (“Krizaka family”). */
109
+ family: string;
110
+ /** The heading of each group. */
111
+ groups: Record<SiteGroup, string>;
112
+ /** The badge of a site that is not released. */
113
+ status: Record<Exclude<SiteStatus, "released">, string>;
114
+ /** Says which site is the current one (“You are here”). */
115
+ current: string;
116
+ /** One line per site: what it is. */
117
+ descriptions: Record<SiteId, string>;
118
+ /** The footer's signature, by the kind of the current site (“A Krizaka product”). */
119
+ signature: Record<SiteKind, string>;
120
+ /** The footer's place line (“Made in Montréal”). */
121
+ place: string;
122
+ /** The accessible name of the version (“Version”). */
123
+ version: string;
124
+ /** The language of these words: the company links open in it. @default "en" */
125
+ lang?: SiteLocale;
126
+ /** The company's pages in the footer's « Krizaka » column. @default the English words */
127
+ company?: Record<CompanyLinkId, string>;
128
+ }
129
+ /**
130
+ * What the footer and the bar read from `@krizaka/org` (the organisation's public facts, one validated JSON): the brand's
131
+ * name, the footer line and the legal links, each in both languages. Structural: the whole `Org` of `@krizaka/org` fits.
132
+ */
133
+ interface OrgFacts {
134
+ brand: {
135
+ name: string;
136
+ };
137
+ /**
138
+ * The company's own accounts elsewhere (`org.links.social` of `@krizaka/org` ≥ 1.1.0): the footer draws each one as its
139
+ * icon, linked to the address given here — never typed in a site. Optional so an older `org` still fits.
140
+ */
141
+ links?: {
142
+ social: readonly OrgSocialLink[];
143
+ };
144
+ /**
145
+ * Every name of the family (`org.family` of `@krizaka/org`, krizaka/krizaka-internal#754): when given, the footer reads
146
+ * the names and addresses here, never from this package's registry — the company « Krizaka », products by their own
147
+ * name, libraries « Krizaka <X> ».
148
+ */
149
+ family?: readonly OrgFamilyEntry[];
150
+ footer: {
151
+ /** « Une entreprise de Technologies Krizaka · Fait à Montréal ». */
152
+ line: Record<SiteLocale, string>;
153
+ legal: readonly {
154
+ id: string;
155
+ label: Record<SiteLocale, string>;
156
+ url: Record<SiteLocale, string>;
157
+ }[];
158
+ };
159
+ }
160
+ /** One entry of `org.family` (`@krizaka/org`), the part the footer reads. */
161
+ interface OrgFamilyEntry {
162
+ id: string;
163
+ name: string;
164
+ group: SiteGroup;
165
+ status: SiteStatus;
166
+ url: string;
167
+ }
168
+
169
+ export { FOOTER_LIMITS as b, footerSettingsProblems as j, resolveFooterSettings as r };
170
+ export type { FamilyLabels as F, OrgFacts as O, SiteId as S, SiteFooterConfig as a, FooterColumn as c, FooterLegal as d, FooterLink as e, FooterLinkSetting as f, FooterSettings as g, FooterStatus as h, OrgSocialLink as i };
package/dist/sites.d.ts CHANGED
@@ -1,3 +1,10 @@
1
+ /** A social link of the org (`@krizaka/org` `links.social`). */
2
+ type OrgSocialLink = {
3
+ id: string;
4
+ label: string;
5
+ url: string;
6
+ };
7
+
1
8
  /** A site of the family. */
2
9
  type SiteId = "krizaka" | "sovkora" | "verikora" | "folioviv" | "ui" | "java" | "ts" | "motion" | "github";
3
10
  /** What a site is: the company, a product, or an open-source project. It chooses the footer's signature line. */
@@ -79,6 +86,13 @@ interface OrgFacts {
79
86
  brand: {
80
87
  name: string;
81
88
  };
89
+ /**
90
+ * The company's own accounts elsewhere (`org.links.social` of `@krizaka/org` ≥ 1.1.0): the footer draws each one as its
91
+ * icon, linked to the address given here — never typed in a site. Optional so an older `org` still fits.
92
+ */
93
+ links?: {
94
+ social: readonly OrgSocialLink[];
95
+ };
82
96
  /**
83
97
  * Every name of the family (`org.family` of `@krizaka/org`, krizaka/krizaka-internal#754): when given, the footer reads
84
98
  * the names and addresses here, never from this package's registry — the company « Krizaka », products by their own