@hjmds/react 1.41.1 → 1.41.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/choice-row.d.ts +14 -5
- package/dist/choice-row.d.ts.map +1 -1
- package/dist/choice-row.js +6 -5
- package/dist/choice-row.js.map +1 -1
- package/dist/evidence.d.ts +1 -1
- package/dist/evidence.js +1 -1
- package/dist/evidence.js.map +1 -1
- package/package.json +2 -2
package/dist/choice-row.d.ts
CHANGED
|
@@ -1,22 +1,31 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
2
|
import { type ChoiceRowItem } from "@hjmds/design-contracts/choice-row";
|
|
3
|
+
import type { ListRowDensity } from "@hjmds/design-contracts/recipes";
|
|
3
4
|
export type { ChoiceRowItem } from "@hjmds/design-contracts/choice-row";
|
|
4
|
-
|
|
5
|
+
/** A synchronous save closes the sheet at once. Only an async save can fail inside the sheet, so only it needs
|
|
6
|
+
* `errorLabel`; a rejected promise keeps the sheet open with that message (2026-10-23 product adoption). */
|
|
7
|
+
export type ChoiceRowSave<Value extends string = string> = Readonly<{
|
|
8
|
+
onValueChange: (value: Value) => void;
|
|
9
|
+
errorLabel?: never;
|
|
10
|
+
}> | Readonly<{
|
|
11
|
+
onValueChange: (value: Value) => Promise<void>;
|
|
12
|
+
errorLabel: string;
|
|
13
|
+
}>;
|
|
14
|
+
export type ChoiceRowProps<Value extends string = string> = ChoiceRowSave<Value> & Readonly<{
|
|
5
15
|
title: string;
|
|
6
16
|
items: readonly ChoiceRowItem<Value>[];
|
|
7
17
|
/** The product-confirmed value; update it only after the save succeeds. */
|
|
8
18
|
value: Value | null;
|
|
9
|
-
/** A returned promise keeps the sheet open and busy; rejection keeps it open with `errorLabel`. */
|
|
10
|
-
onValueChange: (value: Value) => void | Promise<void>;
|
|
11
19
|
closeLabel: string;
|
|
12
|
-
errorLabel: string;
|
|
13
20
|
sheetTitle?: string;
|
|
14
21
|
sheetDescription?: string;
|
|
15
22
|
placeholder?: string;
|
|
16
23
|
leading?: ReactNode;
|
|
17
24
|
trailing?: ReactNode;
|
|
25
|
+
/** ListRow density, so the row matches the surrounding settings rows. */
|
|
26
|
+
density?: ListRowDensity;
|
|
18
27
|
disabled?: boolean;
|
|
19
28
|
loading?: boolean;
|
|
20
29
|
}>;
|
|
21
|
-
export declare function ChoiceRow<Value extends string = string>(
|
|
30
|
+
export declare function ChoiceRow<Value extends string = string>(props: ChoiceRowProps<Value>): import("react").JSX.Element;
|
|
22
31
|
//# sourceMappingURL=choice-row.d.ts.map
|
package/dist/choice-row.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"choice-row.d.ts","sourceRoot":"","sources":["../src/choice-row.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAoB,KAAK,aAAa,EAAE,MAAM,oCAAoC,CAAC;
|
|
1
|
+
{"version":3,"file":"choice-row.d.ts","sourceRoot":"","sources":["../src/choice-row.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAoB,KAAK,aAAa,EAAE,MAAM,oCAAoC,CAAC;AAC1F,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAKtE,YAAY,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACxE;4GAC4G;AAC5G,MAAM,MAAM,aAAa,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IACnD,QAAQ,CAAC;IAAE,aAAa,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IAAC,UAAU,CAAC,EAAE,KAAK,CAAA;CAAE,CAAC,GACvE,QAAQ,CAAC;IAAE,aAAa,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AACrF,MAAM,MAAM,cAAc,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IAAI,aAAa,CAAC,KAAK,CAAC,GAAG,QAAQ,CAAC;IAC1F,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,SAAS,aAAa,CAAC,KAAK,CAAC,EAAE,CAAC;IACvC,2EAA2E;IAC3E,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,yEAAyE;IACzE,OAAO,CAAC,EAAE,cAAc,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CAAC,CAAC;AAEH,wBAAgB,SAAS,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,EAAE,KAAK,EAAE,cAAc,CAAC,KAAK,CAAC,+BA2BpF"}
|
package/dist/choice-row.js
CHANGED
|
@@ -4,9 +4,10 @@ import { resolveChoiceRow } from "@hjmds/design-contracts/choice-row";
|
|
|
4
4
|
import { ListRow } from "./display.js";
|
|
5
5
|
import { Sheet } from "./overlays.js";
|
|
6
6
|
import { RadioGroup } from "./selection.js";
|
|
7
|
-
export function ChoiceRow(
|
|
7
|
+
export function ChoiceRow(props) {
|
|
8
|
+
const { title, items, value, closeLabel, errorLabel, sheetTitle, sheetDescription, placeholder, leading, trailing, density, disabled = false, loading = false } = props;
|
|
8
9
|
const { valueLabel } = resolveChoiceRow({ title, items, value, ...(placeholder === undefined ? {} : { placeholder }) });
|
|
9
|
-
if (!closeLabel.trim() || !errorLabel.trim())
|
|
10
|
+
if (!closeLabel.trim() || (errorLabel !== undefined && !errorLabel.trim()))
|
|
10
11
|
throw new TypeError("ChoiceRow text must not be empty");
|
|
11
12
|
const [open, setOpen] = useState(false);
|
|
12
13
|
const [pending, setPending] = useState(false);
|
|
@@ -17,7 +18,7 @@ export function ChoiceRow({ title, items, value, onValueChange, closeLabel, erro
|
|
|
17
18
|
if (next === value || pending)
|
|
18
19
|
return;
|
|
19
20
|
setFailed(false);
|
|
20
|
-
const result = onValueChange(next);
|
|
21
|
+
const result = props.onValueChange(next);
|
|
21
22
|
if (!result) {
|
|
22
23
|
setOpen(false);
|
|
23
24
|
return;
|
|
@@ -25,7 +26,7 @@ export function ChoiceRow({ title, items, value, onValueChange, closeLabel, erro
|
|
|
25
26
|
setPending(true);
|
|
26
27
|
result.then(() => { setPending(false); setOpen(false); }, () => { setPending(false); setFailed(true); });
|
|
27
28
|
};
|
|
28
|
-
return _jsxs(_Fragment, { children: [_jsx(ListRow, { title: title, description: valueLabel, ...(leading === undefined ? {} : { leading }), ...(trailing === undefined ? {} : { trailing }), disabled: disabled, loading: loading, "aria-haspopup": "dialog", "aria-expanded": open, onClick: () => { setFailed(false); setOpen(true); } }), _jsx(Sheet, { open: open, onOpenChange: (next) => { if (!pending)
|
|
29
|
-
setOpen(next); }, title: sheetTitle ?? title, closeLabel: closeLabel, busy: pending, ...(sheetDescription === undefined ? {} : { description: sheetDescription }), children: _jsx(RadioGroup, { accessibilityLabel: sheetTitle ?? title, orientation: "vertical", value: value, items: items, disabled: pending, ...(failed ? { error: errorLabel } : {}), onValueChange: choose }) })] });
|
|
29
|
+
return _jsxs(_Fragment, { children: [_jsx(ListRow, { title: title, description: valueLabel, ...(leading === undefined ? {} : { leading }), ...(trailing === undefined ? {} : { trailing }), ...(density === undefined ? {} : { density }), disabled: disabled, loading: loading, "aria-haspopup": "dialog", "aria-expanded": open, onClick: () => { setFailed(false); setOpen(true); } }), _jsx(Sheet, { open: open, onOpenChange: (next) => { if (!pending)
|
|
30
|
+
setOpen(next); }, title: sheetTitle ?? title, closeLabel: closeLabel, busy: pending, ...(sheetDescription === undefined ? {} : { description: sheetDescription }), children: _jsx(RadioGroup, { accessibilityLabel: sheetTitle ?? title, orientation: "vertical", value: value, items: items, disabled: pending, ...(failed && errorLabel !== undefined ? { error: errorLabel } : {}), onValueChange: choose }) })] });
|
|
30
31
|
}
|
|
31
32
|
//# sourceMappingURL=choice-row.js.map
|
package/dist/choice-row.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"choice-row.js","sourceRoot":"","sources":["../src/choice-row.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAkB,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAsB,MAAM,oCAAoC,CAAC;
|
|
1
|
+
{"version":3,"file":"choice-row.js","sourceRoot":"","sources":["../src/choice-row.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAkB,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAsB,MAAM,oCAAoC,CAAC;AAE1F,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAyB5C,MAAM,UAAU,SAAS,CAAgC,KAA4B;IACnF,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,UAAU,EAAE,UAAU,EAAE,gBAAgB,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,GAAG,KAAK,EAAE,OAAO,GAAG,KAAK,EAAE,GAAG,KAAK,CAAC;IACxK,MAAM,EAAE,UAAU,EAAE,GAAG,gBAAgB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,CAAC,WAAW,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,CAAC,EAAE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EAAE,CAAC,KAAM,CAAC,QAAQ,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,CAAC,KAAM,CAAC,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO,mBACtN,QAAQ,mBAAgB,IAAI,EAC1C,OAAO,EAAE,GAAG,EAAE,GAAG,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,GAAI,EACzD,KAAC,KAAK,IAAC,IAAI,EAAE,IAAI,EAAE,YAAY,EAAE,CAAC,IAAI,EAAE,EAAE,GAAG,IAAI,CAAC,OAAO;oBAAE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,UAAU,IAAI,KAAK,EAAE,UAAU,EAAE,UAAU,EAAE,IAAI,EAAE,OAAO,KACxI,CAAC,gBAAgB,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,gBAAgB,EAAE,CAAC,YAC7E,KAAC,UAAU,IAAC,kBAAkB,EAAE,UAAU,IAAI,KAAK,EAAE,WAAW,EAAC,UAAU,EAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,OAAO,KACnH,CAAC,MAAM,IAAI,UAAU,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,UAAU,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,aAAa,EAAE,MAAM,GAAI,GAC5F,IACP,CAAC;AACN,CAAC","sourcesContent":["import { useState, type ReactNode } from \"react\";\nimport { resolveChoiceRow, type ChoiceRowItem } from \"@hjmds/design-contracts/choice-row\";\nimport type { ListRowDensity } from \"@hjmds/design-contracts/recipes\";\nimport { ListRow } from \"./display.js\";\nimport { Sheet } from \"./overlays.js\";\nimport { RadioGroup } from \"./selection.js\";\n\nexport type { ChoiceRowItem } from \"@hjmds/design-contracts/choice-row\";\n/** A synchronous save closes the sheet at once. Only an async save can fail inside the sheet, so only it needs\n * `errorLabel`; a rejected promise keeps the sheet open with that message (2026-10-23 product adoption). */\nexport type ChoiceRowSave<Value extends string = string> =\n | Readonly<{ onValueChange: (value: Value) => void; errorLabel?: never }>\n | Readonly<{ onValueChange: (value: Value) => Promise<void>; errorLabel: string }>;\nexport type ChoiceRowProps<Value extends string = string> = ChoiceRowSave<Value> & Readonly<{\n title: string;\n items: readonly ChoiceRowItem<Value>[];\n /** The product-confirmed value; update it only after the save succeeds. */\n value: Value | null;\n closeLabel: string;\n sheetTitle?: string;\n sheetDescription?: string;\n placeholder?: string;\n leading?: ReactNode;\n trailing?: ReactNode;\n /** ListRow density, so the row matches the surrounding settings rows. */\n density?: ListRowDensity;\n disabled?: boolean;\n loading?: boolean;\n}>;\n\nexport function ChoiceRow<Value extends string = string>(props: ChoiceRowProps<Value>) {\n const { title, items, value, closeLabel, errorLabel, sheetTitle, sheetDescription, placeholder, leading, trailing, density, disabled = false, loading = false } = props;\n const { valueLabel } = resolveChoiceRow({ title, items, value, ...(placeholder === undefined ? {} : { placeholder }) });\n if (!closeLabel.trim() || (errorLabel !== undefined && !errorLabel.trim())) throw new TypeError(\"ChoiceRow text must not be empty\");\n const [open, setOpen] = useState(false);\n const [pending, setPending] = useState(false);\n const [failed, setFailed] = useState(false);\n const choose = (raw: string) => {\n // RadioGroup only offers the values passed in `items`, so the string is one of `Value`.\n const next = raw as Value;\n if (next === value || pending) return;\n setFailed(false);\n const result: void | Promise<void> = props.onValueChange(next);\n if (!result) { setOpen(false); return; }\n setPending(true);\n result.then(() => { setPending(false); setOpen(false); }, () => { setPending(false); setFailed(true); });\n };\n return <>\n <ListRow title={title} description={valueLabel} {...(leading === undefined ? {} : { leading })} {...(trailing === undefined ? {} : { trailing })} {...(density === undefined ? {} : { density })} disabled={disabled} loading={loading}\n aria-haspopup=\"dialog\" aria-expanded={open}\n onClick={() => { setFailed(false); setOpen(true); }} />\n <Sheet open={open} onOpenChange={(next) => { if (!pending) setOpen(next); }} title={sheetTitle ?? title} closeLabel={closeLabel} busy={pending}\n {...(sheetDescription === undefined ? {} : { description: sheetDescription })}>\n <RadioGroup accessibilityLabel={sheetTitle ?? title} orientation=\"vertical\" value={value} items={items} disabled={pending}\n {...(failed && errorLabel !== undefined ? { error: errorLabel } : {})} onValueChange={choose} />\n </Sheet>\n </>;\n}\n"]}
|
package/dist/evidence.d.ts
CHANGED
|
@@ -34,7 +34,7 @@ export type ReactRendererEvidenceManifest = Readonly<{
|
|
|
34
34
|
export declare const reactRendererEvidence: {
|
|
35
35
|
readonly schemaVersion: 2;
|
|
36
36
|
readonly packageName: "@hjmds/react";
|
|
37
|
-
readonly packageVersion: "1.41.
|
|
37
|
+
readonly packageVersion: "1.41.2";
|
|
38
38
|
readonly surface: "web";
|
|
39
39
|
readonly components: Readonly<{
|
|
40
40
|
/** Canonical component id from the design-contracts catalog. */
|
package/dist/evidence.js
CHANGED
|
@@ -135,7 +135,7 @@ const activeWebEntries = componentCatalog.filter((entry) => {
|
|
|
135
135
|
export const reactRendererEvidence = {
|
|
136
136
|
schemaVersion: reactRendererEvidenceSchemaVersion,
|
|
137
137
|
packageName: "@hjmds/react",
|
|
138
|
-
packageVersion: "1.41.
|
|
138
|
+
packageVersion: "1.41.2",
|
|
139
139
|
surface: "web",
|
|
140
140
|
components: activeWebEntries.map(derivedClaim),
|
|
141
141
|
};
|
package/dist/evidence.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"evidence.js","sourceRoot":"","sources":["../src/evidence.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAC/E,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,yBAAyB,EAA8B,MAAM,i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C;IACjD,WAAW,EAAE,cAAc;IAC3B,cAAc,EAAE,QAAQ;IACxB,OAAO,EAAE,KAAK;IACd,UAAU,EAAE,gBAAgB,CAAC,GAAG,CAAC,YAAY,CAAC;CACE,CAAC","sourcesContent":["import type { ShowcaseScenarioId } from \"@hjmds/design-contracts/showcase\";\nimport { getRequiredShowcaseEvidence } from \"@hjmds/design-contracts/showcase\";\nimport { componentCatalog, componentIdOf, getComponentSurfaceStatus, type ComponentCatalogEntry } from \"@hjmds/design-contracts/catalog\";\nimport { publicExportEntries } from \"./public-exports.generated.js\";\n\nexport const reactRendererEvidenceSchemaVersion = 2 as const;\n\nexport type ReactRendererEvidenceScenario = Exclude<ShowcaseScenarioId, \"contract\" | \"native-actions\">;\n\nexport type ReactRendererEvidenceComponent = Readonly<{\n /** Canonical component id from the design-contracts catalog. */\n componentId: string;\n /** Public symbols that implement this contract on the declared subpath. */\n exportNames: readonly string[];\n /** Granular @hjmds/react export used by consumers. */\n subpath: `./${string}`;\n /** Scenarios supported by automated first-party renderer evidence. */\n scenarios: readonly ReactRendererEvidenceScenario[];\n /** Repository-local executable proof for every claimed scenario. */\n proofs: readonly Readonly<{\n scenarios: readonly ReactRendererEvidenceScenario[];\n file: `test/${string}.test.tsx`;\n caseId: string;\n }>[];\n}>;\n\nexport type ReactRendererEvidenceManifest = Readonly<{\n schemaVersion: typeof reactRendererEvidenceSchemaVersion;\n packageName: \"@hjmds/react\";\n packageVersion: string;\n surface: \"web\";\n components: readonly ReactRendererEvidenceComponent[];\n}>;\n\nconst defaultProofFile = \"test/default-render.ssr.test.tsx\" as const;\nconst matrixProofFile = \"test/scenario-matrix.browser.test.tsx\" as const;\nconst stableCoreProofFile = \"test/stable-core.browser.test.tsx\" as const;\n\ntype ProofFile = `test/${string}.test.tsx`;\n\n/**\n * Scenarios a component does not pass yet. Each entry is promotion debt that\n * the generated evidence projection reports; remove it when the component is\n * fixed and the matrix case passes. Stable surfaces cannot carry a gap\n * (scripts/check-workspace-sync.mjs).\n */\nconst webScenarioGaps: Readonly<Record<string, readonly ReactRendererEvidenceScenario[]>> = {};\n\n/**\n * Proofs that live outside the shared default/matrix files: keyboard behavior in a dedicated browser test,\n * long copy proven inside a portal by the component's own test, or a whole matrix run in a component file.\n * Everything else about a claim derives from the catalog row (2026-10-18 registration input).\n */\ntype ClaimExtras = Readonly<{\n /** Extra proofs; their scenarios are removed from the shared matrix proof. */\n proofs?: readonly Readonly<{ scenarios: readonly ReactRendererEvidenceScenario[]; file: ProofFile }>[];\n /** Hooks or helpers published beside the component symbols on the same subpath. */\n exportNames?: readonly string[];\n}>;\n\nconst keyboard = (file: ProofFile = stableCoreProofFile): ClaimExtras => ({ proofs: [{ scenarios: [\"keyboard\"], file }] });\nconst keyboardAndLongCopy = (file: ProofFile): ClaimExtras => ({ proofs: [{ scenarios: [\"keyboard\", \"long-copy\"], file }] });\n\nconst claimExtras: Readonly<Record<string, ClaimExtras>> = {\n \"time-picker\": keyboard(\"test/time-picker.browser.test.tsx\"),\n \"design-system-provider\": { exportNames: [\"useHjmTheme\"] },\n layout: keyboard(),\n link: keyboard(),\n field: keyboard(),\n \"search-field\": keyboard(),\n \"password-field\": keyboard(),\n \"otp-field\": keyboard(),\n \"number-field\": keyboard(),\n slider: keyboard(),\n form: keyboard(\"test/form.keyboard.browser.test.tsx\"),\n \"date-picker\": keyboard(),\n calendar: keyboard(\"test/calendar.browser.test.tsx\"),\n \"file-picker\": keyboard(\"test/file-picker.keyboard.browser.test.tsx\"),\n checkbox: keyboard(),\n \"checkbox-group\": keyboard(),\n \"radio-group\": keyboard(),\n switch: keyboard(),\n \"segmented-control\": keyboard(),\n chip: keyboard(),\n tabs: keyboard(\"test/tabs.keyboard.browser.test.tsx\"),\n breadcrumb: keyboard(\"test/page-navigation.browser.test.tsx\"),\n pagination: keyboard(\"test/pagination.keyboard.browser.test.tsx\"),\n popover: keyboardAndLongCopy(\"test/popover.browser.test.tsx\"),\n \"side-panel\": keyboardAndLongCopy(\"test/side-panel.browser.test.tsx\"),\n splitter: keyboard(\"test/splitter.browser.test.tsx\"),\n tour: keyboardAndLongCopy(\"test/tour.browser.test.tsx\"),\n tree: keyboard(\"test/tree.browser.test.tsx\"),\n \"transfer-list\": keyboard(\"test/transfer-list.browser.test.tsx\"),\n mentions: keyboard(\"test/mentions.browser.test.tsx\"),\n \"command-palette\": keyboardAndLongCopy(\"test/command-palette.browser.test.tsx\"),\n agreement: keyboard(\"test/agreement.keyboard.browser.test.tsx\"),\n \"toggle-group\": keyboard(),\n \"tags-input\": keyboard(),\n \"skip-nav\": keyboardAndLongCopy(\"test/skip-nav.browser.test.tsx\"),\n sidebar: keyboard(\"test/sidebar.browser.test.tsx\"),\n \"date-range-picker\": keyboard(\"test/date-range.keyboard.browser.test.tsx\"),\n \"auth-provider-button\": keyboard(),\n \"data-table\": keyboard(\"test/data-table.keyboard.browser.test.tsx\"),\n collapsible: keyboard(\"test/collapsible.keyboard.browser.test.tsx\"),\n \"context-menu\": keyboardAndLongCopy(\"test/context-menu.interactions.browser.test.tsx\"),\n menubar: keyboard(\"test/menubar.keyboard.browser.test.tsx\"),\n anchor: keyboard(\"test/anchor.browser.test.tsx\"),\n \"bottom-navigation\": keyboard(\"test/bottom-navigation.keyboard.browser.test.tsx\"),\n \"load-more\": keyboard(\"test/load-more.interactions.browser.test.tsx\"),\n carousel: keyboard(\"test/carousel.browser.test.tsx\"),\n \"floating-action-button\": keyboard(),\n accordion: keyboard(\"test/accordion.keyboard.browser.test.tsx\"),\n \"upload-item\": keyboard(\"test/upload-item.browser.test.tsx\"),\n // ThinkingOrb runs its whole environment matrix in its own file (canvas timing), not in scenario-matrix.\n \"thinking-orb\": { proofs: [{ scenarios: [\"dark\", \"large-text\", \"rtl\", \"reduced-motion\", \"accessibility\"], file: \"test/thinking-orb.browser.test.tsx\" }] },\n \"color-picker\": keyboard(\"test/web-additions.browser.test.tsx\"),\n // SSR proves semantics but cannot catch the close-only row seen in BurnTok.\n // Keep real geometry evidence attached without promoting catalog maturity.\n toast: {\n exportNames: [\"useToast\"],\n proofs: [\n { scenarios: [\"keyboard\"], file: stableCoreProofFile },\n { scenarios: [\"dark\", \"long-copy\", \"large-text\", \"rtl\"], file: \"test/toast-layout.browser.test.tsx\" },\n ],\n },\n select: keyboard(),\n combobox: keyboard(),\n dialog: keyboard(\"test/advanced.browser.test.tsx\"),\n \"alert-dialog\": keyboardAndLongCopy(\"test/alert-dialog.keyboard.browser.test.tsx\"),\n sheet: keyboardAndLongCopy(\"test/sheet-layout.browser.test.tsx\"),\n tooltip: keyboard(\"test/tooltip.browser.test.tsx\"),\n menu: keyboardAndLongCopy(\"test/menu.keyboard.browser.test.tsx\"),\n};\n\nconst exportEntries: Readonly<Record<string, readonly `./${string}`[] | undefined>> = publicExportEntries;\n\n/**\n * One claim per active Web row of the catalog. The subpath is the symbol's canonical granular entry, the export\n * names are the row's own symbol plus the companions published on that entry, and the scenarios are the row's\n * required Web evidence minus recorded gaps. Keyboard is never implied: it comes only from a dedicated proof.\n */\nfunction derivedClaim(entry: ComponentCatalogEntry): ReactRendererEvidenceComponent {\n const componentId = componentIdOf(entry);\n const extras = claimExtras[componentId] ?? {};\n const symbols = entry.name === \"DesignSystemProvider\" ? [\"HjmProvider\"] : [entry.name, ...(entry.companions ?? [])];\n // A row whose own name is not a symbol (Chart) claims through its first published companion.\n const subpath = symbols.map((symbol) => exportEntries[symbol]?.[0]).find((entry) => entry !== undefined);\n if (!subpath) throw new Error(`${entry.name} has no granular @hjmds/react export to claim evidence on`);\n const exportNames = [\n ...symbols.filter((symbol) => exportEntries[symbol]?.includes(subpath)),\n ...(extras.exportNames ?? []),\n ];\n const required = getRequiredShowcaseEvidence(entry).find((evidence) => evidence.surface === \"web\")?.scenarios ?? [];\n const gaps = webScenarioGaps[componentId] ?? [];\n const extraProofs = extras.proofs ?? [];\n const proven = new Set(extraProofs.flatMap((proof) => proof.scenarios));\n const matrix = required.filter((scenario): scenario is ReactRendererEvidenceScenario =>\n scenario !== \"default\" && scenario !== \"keyboard\" && scenario !== \"native-actions\" && scenario !== \"contract\"\n && !gaps.includes(scenario as ReactRendererEvidenceScenario) && !proven.has(scenario as ReactRendererEvidenceScenario));\n const proofs = [\n { scenarios: [\"default\" as const], file: defaultProofFile, caseId: componentId },\n ...(matrix.length === 0 ? [] : [{ scenarios: matrix, file: matrixProofFile, caseId: componentId }]),\n ...extraProofs.map((proof) => ({ ...proof, caseId: componentId })),\n ];\n return {\n componentId,\n exportNames,\n subpath,\n scenarios: proofs.flatMap((proof) => proof.scenarios),\n proofs,\n };\n}\n\nconst activeWebEntries: readonly ComponentCatalogEntry[] = componentCatalog.filter((entry) => {\n const status = getComponentSurfaceStatus(entry, \"web\");\n return status === \"stable\" || status === \"beta\";\n});\n\n/**\n * First-party Web renderer claims. Scenario axes remain fail-closed: the\n * default scenario is an SSR render, the environment and accessibility\n * scenarios are computed-style assertions in scenario-matrix.browser.\n * Keyboard and cross-platform parity remain fail-closed until dedicated\n * interaction or paired-renderer proofs are mapped one-to-one.\n */\nexport const reactRendererEvidence = {\n schemaVersion: reactRendererEvidenceSchemaVersion,\n packageName: \"@hjmds/react\",\n packageVersion: \"1.41.1\",\n surface: \"web\",\n components: activeWebEntries.map(derivedClaim),\n} as const satisfies ReactRendererEvidenceManifest;\n"]}
|
|
1
|
+
{"version":3,"file":"evidence.js","sourceRoot":"","sources":["../src/evidence.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAC/E,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,yBAAyB,EAA8B,MAAM,iCAAiC,CAAC;AACzI,OAAO,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AAEpE,MAAM,CAAC,MAAM,kCAAkC,GAAG,CAAU,CAAC;AA6B7D,MAAM,gBAAgB,GAAG,kCAA2C,CAAC;AACrE,MAAM,eAAe,GAAG,uCAAgD,CAAC;AACzE,MAAM,mBAAmB,GAAG,mCAA4C,CAA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AAC,MAAM,CAAC,GAAG,CAAC,QAAyC,CAAC,CAAC,CAAC;IAC1H,MAAM,MAAM,GAAG;QACb,EAAE,SAAS,EAAE,CAAC,SAAkB,CAAC,EAAE,IAAI,EAAE,gBAAgB,EAAE,MAAM,EAAE,WAAW,EAAE;QAChF,GAAG,CAAC,MAAM,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,eAAe,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC,CAAC;QACnG,GAAG,WAAW,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,GAAG,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC,CAAC;KACnE,CAAC;IACF,OAAO;QACL,WAAW;QACX,WAAW;QACX,OAAO;QACP,SAAS,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,SAAS,CAAC;QACrD,MAAM;KACP,CAAC;AACJ,CAAC;AAED,MAAM,gBAAgB,GAAqC,gBAAgB,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE;IAC3F,MAAM,MAAM,GAAG,yBAAyB,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;IACvD,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,KAAK,MAAM,CAAC;AAClD,CAAC,CAAC,CAAC;AAEH;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,aAAa,EAAE,kCAAkC;IACjD,WAAW,EAAE,cAAc;IAC3B,cAAc,EAAE,QAAQ;IACxB,OAAO,EAAE,KAAK;IACd,UAAU,EAAE,gBAAgB,CAAC,GAAG,CAAC,YAAY,CAAC;CACE,CAAC","sourcesContent":["import type { ShowcaseScenarioId } from \"@hjmds/design-contracts/showcase\";\nimport { getRequiredShowcaseEvidence } from \"@hjmds/design-contracts/showcase\";\nimport { componentCatalog, componentIdOf, getComponentSurfaceStatus, type ComponentCatalogEntry } from \"@hjmds/design-contracts/catalog\";\nimport { publicExportEntries } from \"./public-exports.generated.js\";\n\nexport const reactRendererEvidenceSchemaVersion = 2 as const;\n\nexport type ReactRendererEvidenceScenario = Exclude<ShowcaseScenarioId, \"contract\" | \"native-actions\">;\n\nexport type ReactRendererEvidenceComponent = Readonly<{\n /** Canonical component id from the design-contracts catalog. */\n componentId: string;\n /** Public symbols that implement this contract on the declared subpath. */\n exportNames: readonly string[];\n /** Granular @hjmds/react export used by consumers. */\n subpath: `./${string}`;\n /** Scenarios supported by automated first-party renderer evidence. */\n scenarios: readonly ReactRendererEvidenceScenario[];\n /** Repository-local executable proof for every claimed scenario. */\n proofs: readonly Readonly<{\n scenarios: readonly ReactRendererEvidenceScenario[];\n file: `test/${string}.test.tsx`;\n caseId: string;\n }>[];\n}>;\n\nexport type ReactRendererEvidenceManifest = Readonly<{\n schemaVersion: typeof reactRendererEvidenceSchemaVersion;\n packageName: \"@hjmds/react\";\n packageVersion: string;\n surface: \"web\";\n components: readonly ReactRendererEvidenceComponent[];\n}>;\n\nconst defaultProofFile = \"test/default-render.ssr.test.tsx\" as const;\nconst matrixProofFile = \"test/scenario-matrix.browser.test.tsx\" as const;\nconst stableCoreProofFile = \"test/stable-core.browser.test.tsx\" as const;\n\ntype ProofFile = `test/${string}.test.tsx`;\n\n/**\n * Scenarios a component does not pass yet. Each entry is promotion debt that\n * the generated evidence projection reports; remove it when the component is\n * fixed and the matrix case passes. Stable surfaces cannot carry a gap\n * (scripts/check-workspace-sync.mjs).\n */\nconst webScenarioGaps: Readonly<Record<string, readonly ReactRendererEvidenceScenario[]>> = {};\n\n/**\n * Proofs that live outside the shared default/matrix files: keyboard behavior in a dedicated browser test,\n * long copy proven inside a portal by the component's own test, or a whole matrix run in a component file.\n * Everything else about a claim derives from the catalog row (2026-10-18 registration input).\n */\ntype ClaimExtras = Readonly<{\n /** Extra proofs; their scenarios are removed from the shared matrix proof. */\n proofs?: readonly Readonly<{ scenarios: readonly ReactRendererEvidenceScenario[]; file: ProofFile }>[];\n /** Hooks or helpers published beside the component symbols on the same subpath. */\n exportNames?: readonly string[];\n}>;\n\nconst keyboard = (file: ProofFile = stableCoreProofFile): ClaimExtras => ({ proofs: [{ scenarios: [\"keyboard\"], file }] });\nconst keyboardAndLongCopy = (file: ProofFile): ClaimExtras => ({ proofs: [{ scenarios: [\"keyboard\", \"long-copy\"], file }] });\n\nconst claimExtras: Readonly<Record<string, ClaimExtras>> = {\n \"time-picker\": keyboard(\"test/time-picker.browser.test.tsx\"),\n \"design-system-provider\": { exportNames: [\"useHjmTheme\"] },\n layout: keyboard(),\n link: keyboard(),\n field: keyboard(),\n \"search-field\": keyboard(),\n \"password-field\": keyboard(),\n \"otp-field\": keyboard(),\n \"number-field\": keyboard(),\n slider: keyboard(),\n form: keyboard(\"test/form.keyboard.browser.test.tsx\"),\n \"date-picker\": keyboard(),\n calendar: keyboard(\"test/calendar.browser.test.tsx\"),\n \"file-picker\": keyboard(\"test/file-picker.keyboard.browser.test.tsx\"),\n checkbox: keyboard(),\n \"checkbox-group\": keyboard(),\n \"radio-group\": keyboard(),\n switch: keyboard(),\n \"segmented-control\": keyboard(),\n chip: keyboard(),\n tabs: keyboard(\"test/tabs.keyboard.browser.test.tsx\"),\n breadcrumb: keyboard(\"test/page-navigation.browser.test.tsx\"),\n pagination: keyboard(\"test/pagination.keyboard.browser.test.tsx\"),\n popover: keyboardAndLongCopy(\"test/popover.browser.test.tsx\"),\n \"side-panel\": keyboardAndLongCopy(\"test/side-panel.browser.test.tsx\"),\n splitter: keyboard(\"test/splitter.browser.test.tsx\"),\n tour: keyboardAndLongCopy(\"test/tour.browser.test.tsx\"),\n tree: keyboard(\"test/tree.browser.test.tsx\"),\n \"transfer-list\": keyboard(\"test/transfer-list.browser.test.tsx\"),\n mentions: keyboard(\"test/mentions.browser.test.tsx\"),\n \"command-palette\": keyboardAndLongCopy(\"test/command-palette.browser.test.tsx\"),\n agreement: keyboard(\"test/agreement.keyboard.browser.test.tsx\"),\n \"toggle-group\": keyboard(),\n \"tags-input\": keyboard(),\n \"skip-nav\": keyboardAndLongCopy(\"test/skip-nav.browser.test.tsx\"),\n sidebar: keyboard(\"test/sidebar.browser.test.tsx\"),\n \"date-range-picker\": keyboard(\"test/date-range.keyboard.browser.test.tsx\"),\n \"auth-provider-button\": keyboard(),\n \"data-table\": keyboard(\"test/data-table.keyboard.browser.test.tsx\"),\n collapsible: keyboard(\"test/collapsible.keyboard.browser.test.tsx\"),\n \"context-menu\": keyboardAndLongCopy(\"test/context-menu.interactions.browser.test.tsx\"),\n menubar: keyboard(\"test/menubar.keyboard.browser.test.tsx\"),\n anchor: keyboard(\"test/anchor.browser.test.tsx\"),\n \"bottom-navigation\": keyboard(\"test/bottom-navigation.keyboard.browser.test.tsx\"),\n \"load-more\": keyboard(\"test/load-more.interactions.browser.test.tsx\"),\n carousel: keyboard(\"test/carousel.browser.test.tsx\"),\n \"floating-action-button\": keyboard(),\n accordion: keyboard(\"test/accordion.keyboard.browser.test.tsx\"),\n \"upload-item\": keyboard(\"test/upload-item.browser.test.tsx\"),\n // ThinkingOrb runs its whole environment matrix in its own file (canvas timing), not in scenario-matrix.\n \"thinking-orb\": { proofs: [{ scenarios: [\"dark\", \"large-text\", \"rtl\", \"reduced-motion\", \"accessibility\"], file: \"test/thinking-orb.browser.test.tsx\" }] },\n \"color-picker\": keyboard(\"test/web-additions.browser.test.tsx\"),\n // SSR proves semantics but cannot catch the close-only row seen in BurnTok.\n // Keep real geometry evidence attached without promoting catalog maturity.\n toast: {\n exportNames: [\"useToast\"],\n proofs: [\n { scenarios: [\"keyboard\"], file: stableCoreProofFile },\n { scenarios: [\"dark\", \"long-copy\", \"large-text\", \"rtl\"], file: \"test/toast-layout.browser.test.tsx\" },\n ],\n },\n select: keyboard(),\n combobox: keyboard(),\n dialog: keyboard(\"test/advanced.browser.test.tsx\"),\n \"alert-dialog\": keyboardAndLongCopy(\"test/alert-dialog.keyboard.browser.test.tsx\"),\n sheet: keyboardAndLongCopy(\"test/sheet-layout.browser.test.tsx\"),\n tooltip: keyboard(\"test/tooltip.browser.test.tsx\"),\n menu: keyboardAndLongCopy(\"test/menu.keyboard.browser.test.tsx\"),\n};\n\nconst exportEntries: Readonly<Record<string, readonly `./${string}`[] | undefined>> = publicExportEntries;\n\n/**\n * One claim per active Web row of the catalog. The subpath is the symbol's canonical granular entry, the export\n * names are the row's own symbol plus the companions published on that entry, and the scenarios are the row's\n * required Web evidence minus recorded gaps. Keyboard is never implied: it comes only from a dedicated proof.\n */\nfunction derivedClaim(entry: ComponentCatalogEntry): ReactRendererEvidenceComponent {\n const componentId = componentIdOf(entry);\n const extras = claimExtras[componentId] ?? {};\n const symbols = entry.name === \"DesignSystemProvider\" ? [\"HjmProvider\"] : [entry.name, ...(entry.companions ?? [])];\n // A row whose own name is not a symbol (Chart) claims through its first published companion.\n const subpath = symbols.map((symbol) => exportEntries[symbol]?.[0]).find((entry) => entry !== undefined);\n if (!subpath) throw new Error(`${entry.name} has no granular @hjmds/react export to claim evidence on`);\n const exportNames = [\n ...symbols.filter((symbol) => exportEntries[symbol]?.includes(subpath)),\n ...(extras.exportNames ?? []),\n ];\n const required = getRequiredShowcaseEvidence(entry).find((evidence) => evidence.surface === \"web\")?.scenarios ?? [];\n const gaps = webScenarioGaps[componentId] ?? [];\n const extraProofs = extras.proofs ?? [];\n const proven = new Set(extraProofs.flatMap((proof) => proof.scenarios));\n const matrix = required.filter((scenario): scenario is ReactRendererEvidenceScenario =>\n scenario !== \"default\" && scenario !== \"keyboard\" && scenario !== \"native-actions\" && scenario !== \"contract\"\n && !gaps.includes(scenario as ReactRendererEvidenceScenario) && !proven.has(scenario as ReactRendererEvidenceScenario));\n const proofs = [\n { scenarios: [\"default\" as const], file: defaultProofFile, caseId: componentId },\n ...(matrix.length === 0 ? [] : [{ scenarios: matrix, file: matrixProofFile, caseId: componentId }]),\n ...extraProofs.map((proof) => ({ ...proof, caseId: componentId })),\n ];\n return {\n componentId,\n exportNames,\n subpath,\n scenarios: proofs.flatMap((proof) => proof.scenarios),\n proofs,\n };\n}\n\nconst activeWebEntries: readonly ComponentCatalogEntry[] = componentCatalog.filter((entry) => {\n const status = getComponentSurfaceStatus(entry, \"web\");\n return status === \"stable\" || status === \"beta\";\n});\n\n/**\n * First-party Web renderer claims. Scenario axes remain fail-closed: the\n * default scenario is an SSR render, the environment and accessibility\n * scenarios are computed-style assertions in scenario-matrix.browser.\n * Keyboard and cross-platform parity remain fail-closed until dedicated\n * interaction or paired-renderer proofs are mapped one-to-one.\n */\nexport const reactRendererEvidence = {\n schemaVersion: reactRendererEvidenceSchemaVersion,\n packageName: \"@hjmds/react\",\n packageVersion: \"1.41.2\",\n surface: \"web\",\n components: activeWebEntries.map(derivedClaim),\n} as const satisfies ReactRendererEvidenceManifest;\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hjmds/react",
|
|
3
|
-
"version": "1.41.
|
|
3
|
+
"version": "1.41.2",
|
|
4
4
|
"description": "Accessible React 19 renderers for HJM design contracts.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"publishConfig": {
|
|
@@ -656,7 +656,7 @@
|
|
|
656
656
|
"@blobatar/react": "2.7.0",
|
|
657
657
|
"lucide-react": "1.59.0",
|
|
658
658
|
"vite": "8.3.4",
|
|
659
|
-
"@hjmds/design-contracts": "1.41.
|
|
659
|
+
"@hjmds/design-contracts": "1.41.2"
|
|
660
660
|
},
|
|
661
661
|
"peerDependenciesMeta": {
|
|
662
662
|
"@number-flow/react": {
|