@ttoss/fsl-ui 0.2.4

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 (174) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +76 -0
  3. package/dist/_virtual/_rolldown/runtime.cjs +30 -0
  4. package/dist/components/Breadcrumbs/Breadcrumbs.cjs +129 -0
  5. package/dist/components/Breadcrumbs/Breadcrumbs.d.cts +61 -0
  6. package/dist/components/Breadcrumbs/Breadcrumbs.d.mts +61 -0
  7. package/dist/components/Breadcrumbs/Breadcrumbs.mjs +126 -0
  8. package/dist/components/Button/Button.cjs +80 -0
  9. package/dist/components/Button/Button.d.cts +68 -0
  10. package/dist/components/Button/Button.d.mts +68 -0
  11. package/dist/components/Button/Button.mjs +79 -0
  12. package/dist/components/Checkbox/Checkbox.cjs +183 -0
  13. package/dist/components/Checkbox/Checkbox.d.cts +45 -0
  14. package/dist/components/Checkbox/Checkbox.d.mts +45 -0
  15. package/dist/components/Checkbox/Checkbox.mjs +182 -0
  16. package/dist/components/CheckboxGroup/CheckboxGroup.cjs +97 -0
  17. package/dist/components/CheckboxGroup/CheckboxGroup.d.cts +56 -0
  18. package/dist/components/CheckboxGroup/CheckboxGroup.d.mts +56 -0
  19. package/dist/components/CheckboxGroup/CheckboxGroup.mjs +96 -0
  20. package/dist/components/FileTrigger/FileTrigger.cjs +51 -0
  21. package/dist/components/FileTrigger/FileTrigger.d.cts +52 -0
  22. package/dist/components/FileTrigger/FileTrigger.d.mts +52 -0
  23. package/dist/components/FileTrigger/FileTrigger.mjs +50 -0
  24. package/dist/components/GridList/GridList.cjs +220 -0
  25. package/dist/components/GridList/GridList.d.cts +72 -0
  26. package/dist/components/GridList/GridList.d.mts +72 -0
  27. package/dist/components/GridList/GridList.mjs +217 -0
  28. package/dist/components/Group/Group.cjs +77 -0
  29. package/dist/components/Group/Group.d.cts +61 -0
  30. package/dist/components/Group/Group.d.mts +61 -0
  31. package/dist/components/Group/Group.mjs +74 -0
  32. package/dist/components/Icon/Icon.cjs +52 -0
  33. package/dist/components/Icon/Icon.mjs +52 -0
  34. package/dist/components/Icon/glyphs.cjs +72 -0
  35. package/dist/components/Icon/glyphs.mjs +63 -0
  36. package/dist/components/Link/Link.cjs +62 -0
  37. package/dist/components/Link/Link.d.cts +38 -0
  38. package/dist/components/Link/Link.d.mts +38 -0
  39. package/dist/components/Link/Link.mjs +61 -0
  40. package/dist/components/ListBox/ListBox.cjs +126 -0
  41. package/dist/components/ListBox/ListBox.d.cts +63 -0
  42. package/dist/components/ListBox/ListBox.d.mts +63 -0
  43. package/dist/components/ListBox/ListBox.mjs +123 -0
  44. package/dist/components/Meter/Meter.cjs +126 -0
  45. package/dist/components/Meter/Meter.d.cts +63 -0
  46. package/dist/components/Meter/Meter.d.mts +63 -0
  47. package/dist/components/Meter/Meter.mjs +125 -0
  48. package/dist/components/NumberField/NumberField.cjs +221 -0
  49. package/dist/components/NumberField/NumberField.d.cts +68 -0
  50. package/dist/components/NumberField/NumberField.d.mts +68 -0
  51. package/dist/components/NumberField/NumberField.mjs +220 -0
  52. package/dist/components/ProgressBar/ProgressBar.cjs +132 -0
  53. package/dist/components/ProgressBar/ProgressBar.d.cts +56 -0
  54. package/dist/components/ProgressBar/ProgressBar.d.mts +56 -0
  55. package/dist/components/ProgressBar/ProgressBar.mjs +129 -0
  56. package/dist/components/RadioGroup/RadioGroup.cjs +218 -0
  57. package/dist/components/RadioGroup/RadioGroup.d.cts +82 -0
  58. package/dist/components/RadioGroup/RadioGroup.d.mts +82 -0
  59. package/dist/components/RadioGroup/RadioGroup.mjs +215 -0
  60. package/dist/components/Select/Select.cjs +253 -0
  61. package/dist/components/Select/Select.d.cts +86 -0
  62. package/dist/components/Select/Select.d.mts +86 -0
  63. package/dist/components/Select/Select.mjs +250 -0
  64. package/dist/components/Separator/Separator.cjs +64 -0
  65. package/dist/components/Separator/Separator.d.cts +44 -0
  66. package/dist/components/Separator/Separator.d.mts +44 -0
  67. package/dist/components/Separator/Separator.mjs +63 -0
  68. package/dist/components/Slider/Slider.cjs +160 -0
  69. package/dist/components/Slider/Slider.d.cts +45 -0
  70. package/dist/components/Slider/Slider.d.mts +45 -0
  71. package/dist/components/Slider/Slider.mjs +159 -0
  72. package/dist/components/Switch/Switch.cjs +176 -0
  73. package/dist/components/Switch/Switch.d.cts +43 -0
  74. package/dist/components/Switch/Switch.d.mts +43 -0
  75. package/dist/components/Switch/Switch.mjs +175 -0
  76. package/dist/components/Tabs/Tabs.cjs +180 -0
  77. package/dist/components/Tabs/Tabs.d.cts +85 -0
  78. package/dist/components/Tabs/Tabs.d.mts +85 -0
  79. package/dist/components/Tabs/Tabs.mjs +173 -0
  80. package/dist/components/Toast/Toast.cjs +218 -0
  81. package/dist/components/Toast/Toast.d.cts +96 -0
  82. package/dist/components/Toast/Toast.d.mts +96 -0
  83. package/dist/components/Toast/Toast.mjs +214 -0
  84. package/dist/components/ToggleButton/ToggleButton.cjs +125 -0
  85. package/dist/components/ToggleButton/ToggleButton.d.cts +43 -0
  86. package/dist/components/ToggleButton/ToggleButton.d.mts +43 -0
  87. package/dist/components/ToggleButton/ToggleButton.mjs +124 -0
  88. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.cjs +48 -0
  89. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.d.cts +41 -0
  90. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.d.mts +41 -0
  91. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.mjs +47 -0
  92. package/dist/components/Toolbar/Toolbar.cjs +67 -0
  93. package/dist/components/Toolbar/Toolbar.d.cts +60 -0
  94. package/dist/components/Toolbar/Toolbar.d.mts +60 -0
  95. package/dist/components/Toolbar/Toolbar.mjs +66 -0
  96. package/dist/composites/Accordion/Accordion.cjs +279 -0
  97. package/dist/composites/Accordion/Accordion.d.cts +176 -0
  98. package/dist/composites/Accordion/Accordion.d.mts +176 -0
  99. package/dist/composites/Accordion/Accordion.mjs +270 -0
  100. package/dist/composites/ConfirmationDialog/ConfirmationDialog.cjs +206 -0
  101. package/dist/composites/ConfirmationDialog/ConfirmationDialog.d.cts +166 -0
  102. package/dist/composites/ConfirmationDialog/ConfirmationDialog.d.mts +166 -0
  103. package/dist/composites/ConfirmationDialog/ConfirmationDialog.mjs +203 -0
  104. package/dist/composites/Dialog/Dialog.cjs +372 -0
  105. package/dist/composites/Dialog/Dialog.d.cts +234 -0
  106. package/dist/composites/Dialog/Dialog.d.mts +234 -0
  107. package/dist/composites/Dialog/Dialog.mjs +360 -0
  108. package/dist/composites/Disclosure/Disclosure.cjs +214 -0
  109. package/dist/composites/Disclosure/Disclosure.d.cts +118 -0
  110. package/dist/composites/Disclosure/Disclosure.d.mts +118 -0
  111. package/dist/composites/Disclosure/Disclosure.mjs +207 -0
  112. package/dist/composites/Form/Form.cjs +161 -0
  113. package/dist/composites/Form/Form.d.cts +176 -0
  114. package/dist/composites/Form/Form.d.mts +176 -0
  115. package/dist/composites/Form/Form.mjs +156 -0
  116. package/dist/composites/Menu/Menu.cjs +190 -0
  117. package/dist/composites/Menu/Menu.d.cts +158 -0
  118. package/dist/composites/Menu/Menu.d.mts +158 -0
  119. package/dist/composites/Menu/Menu.mjs +186 -0
  120. package/dist/composites/Popover/Popover.cjs +80 -0
  121. package/dist/composites/Popover/Popover.d.cts +56 -0
  122. package/dist/composites/Popover/Popover.d.mts +56 -0
  123. package/dist/composites/Popover/Popover.mjs +78 -0
  124. package/dist/composites/SearchField/SearchField.cjs +194 -0
  125. package/dist/composites/SearchField/SearchField.d.cts +81 -0
  126. package/dist/composites/SearchField/SearchField.d.mts +81 -0
  127. package/dist/composites/SearchField/SearchField.mjs +189 -0
  128. package/dist/composites/TagGroup/TagGroup.cjs +212 -0
  129. package/dist/composites/TagGroup/TagGroup.d.cts +84 -0
  130. package/dist/composites/TagGroup/TagGroup.d.mts +84 -0
  131. package/dist/composites/TagGroup/TagGroup.mjs +209 -0
  132. package/dist/composites/TextArea/TextArea.cjs +190 -0
  133. package/dist/composites/TextArea/TextArea.d.cts +95 -0
  134. package/dist/composites/TextArea/TextArea.d.mts +95 -0
  135. package/dist/composites/TextArea/TextArea.mjs +181 -0
  136. package/dist/composites/TextField/TextField.cjs +200 -0
  137. package/dist/composites/TextField/TextField.d.cts +111 -0
  138. package/dist/composites/TextField/TextField.d.mts +111 -0
  139. package/dist/composites/TextField/TextField.mjs +191 -0
  140. package/dist/composites/Tooltip/Tooltip.cjs +79 -0
  141. package/dist/composites/Tooltip/Tooltip.d.cts +53 -0
  142. package/dist/composites/Tooltip/Tooltip.d.mts +53 -0
  143. package/dist/composites/Tooltip/Tooltip.mjs +77 -0
  144. package/dist/composites/Wizard/Wizard.cjs +333 -0
  145. package/dist/composites/Wizard/Wizard.d.cts +206 -0
  146. package/dist/composites/Wizard/Wizard.d.mts +206 -0
  147. package/dist/composites/Wizard/Wizard.mjs +324 -0
  148. package/dist/composites/scope.cjs +124 -0
  149. package/dist/composites/scope.mjs +121 -0
  150. package/dist/index.cjs +186 -0
  151. package/dist/index.d.cts +37 -0
  152. package/dist/index.d.mts +37 -0
  153. package/dist/index.mjs +39 -0
  154. package/dist/semantics/componentMeta.d.cts +37 -0
  155. package/dist/semantics/componentMeta.d.mts +37 -0
  156. package/dist/semantics/index.cjs +16 -0
  157. package/dist/semantics/index.d.cts +4 -0
  158. package/dist/semantics/index.d.mts +4 -0
  159. package/dist/semantics/index.mjs +3 -0
  160. package/dist/semantics/taxonomy.cjs +150 -0
  161. package/dist/semantics/taxonomy.d.cts +153 -0
  162. package/dist/semantics/taxonomy.d.mts +153 -0
  163. package/dist/semantics/taxonomy.mjs +140 -0
  164. package/dist/tokens/escapeHatch.cjs +13 -0
  165. package/dist/tokens/escapeHatch.mjs +13 -0
  166. package/dist/tokens/focusRing.cjs +28 -0
  167. package/dist/tokens/focusRing.mjs +28 -0
  168. package/dist/tokens/keyframes.cjs +76 -0
  169. package/dist/tokens/keyframes.mjs +75 -0
  170. package/dist/tokens/resolveInteractiveStyle.cjs +41 -0
  171. package/dist/tokens/resolveInteractiveStyle.mjs +41 -0
  172. package/llms.txt +142 -0
  173. package/package.json +70 -0
  174. package/src/tokens/CONTRACT.md +505 -0
@@ -0,0 +1,52 @@
1
+ /** Powered by @ttoss/config. https://ttoss.dev/docs/modules/packages/config/ */
2
+ import { ensureIconGlyphs, iconifyName } from "./glyphs.mjs";
3
+ import { vars } from "@ttoss/fsl-theme/vars";
4
+ import { jsx } from "react/jsx-runtime";
5
+ import { Icon } from "@iconify-icon/react";
6
+
7
+ //#region src/components/Icon/Icon.tsx
8
+ /** Formal semantic identity — Icon (Structure entity, static glyph). */
9
+ var iconMeta = {
10
+ displayName: "Icon",
11
+ entity: "Structure",
12
+ structure: "icon"
13
+ };
14
+ /**
15
+ * Renders a semantic glyph via the Iconify provider (ADR-005).
16
+ *
17
+ * Icon is named by intent and inherits its color from context
18
+ * (`currentColor`); only its size is a token. Glyphs are registered offline
19
+ * on first render (`ensureIconGlyphs`), so no network request is made.
20
+ *
21
+ * @example
22
+ * ```tsx
23
+ * <Icon intent="disclosure.expand" />
24
+ * <Icon intent="action.close" size="sm" label={closeLabel} />
25
+ * ```
26
+ */
27
+ var Icon$1 = ({
28
+ intent,
29
+ size = "md",
30
+ label
31
+ }) => {
32
+ ensureIconGlyphs();
33
+ const decorative = label === void 0;
34
+ return /* @__PURE__ */jsx(Icon, {
35
+ "data-scope": "icon",
36
+ "data-part": "icon",
37
+ icon: iconifyName(intent),
38
+ noobserver: true,
39
+ "aria-hidden": decorative ? "true" : void 0,
40
+ "aria-label": label,
41
+ role: decorative ? void 0 : "img",
42
+ style: {
43
+ fontSize: vars.sizing.icon[size],
44
+ lineHeight: 1,
45
+ flexShrink: 0
46
+ }
47
+ });
48
+ };
49
+ Icon$1.displayName = iconMeta.displayName;
50
+
51
+ //#endregion
52
+ export { Icon$1 as Icon };
@@ -0,0 +1,72 @@
1
+ /** Powered by @ttoss/config. https://ttoss.dev/docs/modules/packages/config/ */
2
+ const require_runtime = require('../../_virtual/_rolldown/runtime.cjs');
3
+ let _iconify_icon_react = require("@iconify-icon/react");
4
+ let _iconify_icons_lucide_check_js = require("@iconify/icons-lucide/check.js");
5
+ _iconify_icons_lucide_check_js = require_runtime.__toESM(_iconify_icons_lucide_check_js, 1);
6
+ let _iconify_icons_lucide_chevron_down_js = require("@iconify/icons-lucide/chevron-down.js");
7
+ _iconify_icons_lucide_chevron_down_js = require_runtime.__toESM(_iconify_icons_lucide_chevron_down_js, 1);
8
+ let _iconify_icons_lucide_chevron_right_js = require("@iconify/icons-lucide/chevron-right.js");
9
+ _iconify_icons_lucide_chevron_right_js = require_runtime.__toESM(_iconify_icons_lucide_chevron_right_js, 1);
10
+ let _iconify_icons_lucide_minus_js = require("@iconify/icons-lucide/minus.js");
11
+ _iconify_icons_lucide_minus_js = require_runtime.__toESM(_iconify_icons_lucide_minus_js, 1);
12
+ let _iconify_icons_lucide_plus_js = require("@iconify/icons-lucide/plus.js");
13
+ _iconify_icons_lucide_plus_js = require_runtime.__toESM(_iconify_icons_lucide_plus_js, 1);
14
+ let _iconify_icons_lucide_search_js = require("@iconify/icons-lucide/search.js");
15
+ _iconify_icons_lucide_search_js = require_runtime.__toESM(_iconify_icons_lucide_search_js, 1);
16
+ let _iconify_icons_lucide_x_js = require("@iconify/icons-lucide/x.js");
17
+ _iconify_icons_lucide_x_js = require_runtime.__toESM(_iconify_icons_lucide_x_js, 1);
18
+
19
+ //#region src/components/Icon/glyphs.ts
20
+ /**
21
+ * Default glyph mapping — intent → Lucide (via Iconify).
22
+ *
23
+ * This is the "theme glyph mapping" from icon-system.md, housed internally
24
+ * while `@ttoss/fsl-icon` is not yet its own package. Glyphs come from the
25
+ * official provider (**Iconify**, ADR-005), sourced per-icon from
26
+ * `@iconify/icons-lucide/*` so bundlers keep only the icons actually
27
+ * referenced (tree-shakeable, mirroring `@ttoss/theme`'s `BruttalIcons`).
28
+ * No SVG is hand-authored here; no icon is fetched from the Iconify API at
29
+ * runtime — every glyph is registered offline via `addIcon`, so rendering is
30
+ * SSR-safe and network-free.
31
+ *
32
+ * @see ./intents.ts — the intents these glyphs satisfy
33
+ * @see ../../../CONTRIBUTING.md ADR-005
34
+ */
35
+ /**
36
+ * The default (Lucide) glyph for every intent. `satisfies Record<…>` makes a
37
+ * missing intent a compile error — the completeness rule from icon-system.md.
38
+ */
39
+ var INTENT_GLYPHS = {
40
+ "disclosure.expand": _iconify_icons_lucide_chevron_down_js.default,
41
+ "disclosure.collapse": _iconify_icons_lucide_chevron_right_js.default,
42
+ "selection.checked": _iconify_icons_lucide_check_js.default,
43
+ "selection.indeterminate": _iconify_icons_lucide_minus_js.default,
44
+ "action.close": _iconify_icons_lucide_x_js.default,
45
+ "action.search": _iconify_icons_lucide_search_js.default,
46
+ "action.increment": _iconify_icons_lucide_plus_js.default,
47
+ "action.decrement": _iconify_icons_lucide_minus_js.default
48
+ };
49
+ /**
50
+ * The Iconify registry name for an intent — `fsl-ui:{family}-{intent}`. The
51
+ * `fsl-ui` prefix namespaces our glyphs so `addIcon` never clobbers (or is
52
+ * clobbered by) icons an application registers under bare names.
53
+ */
54
+ var iconifyName = intent => {
55
+ return `fsl-ui:${intent.replace(".", "-")}`;
56
+ };
57
+ var registered = false;
58
+ /**
59
+ * Registers every intent's glyph with Iconify exactly once (idempotent).
60
+ * Mirrors the `ensureKeyframes()` pattern: called from the component render
61
+ * path rather than at module top-level, so `sideEffects: false` bundlers do
62
+ * not drop the registration as dead code.
63
+ */
64
+ var ensureIconGlyphs = () => {
65
+ if (registered) return;
66
+ for (const [intent, glyph] of Object.entries(INTENT_GLYPHS)) (0, _iconify_icon_react.addIcon)(iconifyName(intent), glyph);
67
+ registered = true;
68
+ };
69
+
70
+ //#endregion
71
+ exports.ensureIconGlyphs = ensureIconGlyphs;
72
+ exports.iconifyName = iconifyName;
@@ -0,0 +1,63 @@
1
+ /** Powered by @ttoss/config. https://ttoss.dev/docs/modules/packages/config/ */
2
+ import { addIcon } from "@iconify-icon/react";
3
+ import checkGlyph from "@iconify/icons-lucide/check.js";
4
+ import chevronDownGlyph from "@iconify/icons-lucide/chevron-down.js";
5
+ import chevronRightGlyph from "@iconify/icons-lucide/chevron-right.js";
6
+ import minusGlyph from "@iconify/icons-lucide/minus.js";
7
+ import plusGlyph from "@iconify/icons-lucide/plus.js";
8
+ import searchGlyph from "@iconify/icons-lucide/search.js";
9
+ import xGlyph from "@iconify/icons-lucide/x.js";
10
+
11
+ //#region src/components/Icon/glyphs.ts
12
+ /**
13
+ * Default glyph mapping — intent → Lucide (via Iconify).
14
+ *
15
+ * This is the "theme glyph mapping" from icon-system.md, housed internally
16
+ * while `@ttoss/fsl-icon` is not yet its own package. Glyphs come from the
17
+ * official provider (**Iconify**, ADR-005), sourced per-icon from
18
+ * `@iconify/icons-lucide/*` so bundlers keep only the icons actually
19
+ * referenced (tree-shakeable, mirroring `@ttoss/theme`'s `BruttalIcons`).
20
+ * No SVG is hand-authored here; no icon is fetched from the Iconify API at
21
+ * runtime — every glyph is registered offline via `addIcon`, so rendering is
22
+ * SSR-safe and network-free.
23
+ *
24
+ * @see ./intents.ts — the intents these glyphs satisfy
25
+ * @see ../../../CONTRIBUTING.md ADR-005
26
+ */
27
+ /**
28
+ * The default (Lucide) glyph for every intent. `satisfies Record<…>` makes a
29
+ * missing intent a compile error — the completeness rule from icon-system.md.
30
+ */
31
+ var INTENT_GLYPHS = {
32
+ "disclosure.expand": chevronDownGlyph,
33
+ "disclosure.collapse": chevronRightGlyph,
34
+ "selection.checked": checkGlyph,
35
+ "selection.indeterminate": minusGlyph,
36
+ "action.close": xGlyph,
37
+ "action.search": searchGlyph,
38
+ "action.increment": plusGlyph,
39
+ "action.decrement": minusGlyph
40
+ };
41
+ /**
42
+ * The Iconify registry name for an intent — `fsl-ui:{family}-{intent}`. The
43
+ * `fsl-ui` prefix namespaces our glyphs so `addIcon` never clobbers (or is
44
+ * clobbered by) icons an application registers under bare names.
45
+ */
46
+ var iconifyName = intent => {
47
+ return `fsl-ui:${intent.replace(".", "-")}`;
48
+ };
49
+ var registered = false;
50
+ /**
51
+ * Registers every intent's glyph with Iconify exactly once (idempotent).
52
+ * Mirrors the `ensureKeyframes()` pattern: called from the component render
53
+ * path rather than at module top-level, so `sideEffects: false` bundlers do
54
+ * not drop the registration as dead code.
55
+ */
56
+ var ensureIconGlyphs = () => {
57
+ if (registered) return;
58
+ for (const [intent, glyph] of Object.entries(INTENT_GLYPHS)) addIcon(iconifyName(intent), glyph);
59
+ registered = true;
60
+ };
61
+
62
+ //#endregion
63
+ export { ensureIconGlyphs, iconifyName };
@@ -0,0 +1,62 @@
1
+ /** Powered by @ttoss/config. https://ttoss.dev/docs/modules/packages/config/ */
2
+ const require_focusRing = require('../../tokens/focusRing.cjs');
3
+ const require_resolveInteractiveStyle = require('../../tokens/resolveInteractiveStyle.cjs');
4
+ let _ttoss_fsl_theme_vars = require("@ttoss/fsl-theme/vars");
5
+ let react_aria_components = require("react-aria-components");
6
+ let react_jsx_runtime = require("react/jsx-runtime");
7
+
8
+ //#region src/components/Link/Link.tsx
9
+ /**
10
+ * Formal semantic identity — what this component *is* (Layer 1).
11
+ */
12
+ var linkMeta = {
13
+ displayName: "Link",
14
+ entity: "Navigation",
15
+ structure: "root"
16
+ };
17
+ /**
18
+ * A link component for navigation, styled with navigation tokens.
19
+ */
20
+ var Link = ({
21
+ evaluation = "primary",
22
+ ...props
23
+ }) => {
24
+ const colors = _ttoss_fsl_theme_vars.vars.colors.navigation[evaluation];
25
+ return /* @__PURE__ */(0, react_jsx_runtime.jsx)(react_aria_components.Link, {
26
+ ...props,
27
+ "data-scope": "link",
28
+ "data-part": "root",
29
+ "data-evaluation": evaluation,
30
+ style: ({
31
+ isHovered,
32
+ isPressed,
33
+ isDisabled,
34
+ isFocusVisible
35
+ }) => {
36
+ return {
37
+ boxSizing: "border-box",
38
+ display: "inline-flex",
39
+ alignItems: "center",
40
+ textDecoration: isDisabled ? "none" : "underline",
41
+ textDecorationThickness: isHovered ? "2px" : "1px",
42
+ borderRadius: _ttoss_fsl_theme_vars.vars.radii.control,
43
+ transitionDuration: _ttoss_fsl_theme_vars.vars.motion.feedback.duration,
44
+ transitionTimingFunction: _ttoss_fsl_theme_vars.vars.motion.feedback.easing,
45
+ transitionProperty: "color, text-decoration-thickness",
46
+ cursor: isDisabled ? "not-allowed" : "pointer",
47
+ ..._ttoss_fsl_theme_vars.vars.text.label.md,
48
+ color: require_resolveInteractiveStyle.resolveInteractiveStyle(colors?.text, {
49
+ isHovered,
50
+ isPressed,
51
+ isDisabled
52
+ }),
53
+ outline: require_focusRing.focusRingOutline(isFocusVisible)
54
+ };
55
+ }
56
+ });
57
+ };
58
+ Link.displayName = linkMeta.displayName;
59
+
60
+ //#endregion
61
+ exports.Link = Link;
62
+ exports.linkMeta = linkMeta;
@@ -0,0 +1,38 @@
1
+
2
+ import { EvaluationsFor } from "../../semantics/taxonomy.cjs";
3
+ import { LinkProps } from "react-aria-components";
4
+
5
+ //#region src/components/Link/Link.d.ts
6
+ /**
7
+ * Formal semantic identity — what this component *is* (Layer 1).
8
+ */
9
+ declare const linkMeta: {
10
+ readonly displayName: "Link";
11
+ readonly entity: "Navigation";
12
+ readonly structure: "root";
13
+ };
14
+ /**
15
+ * A navigation link built on React Aria with semantic tokens from CONTRACT.md.
16
+ *
17
+ * Entity = Navigation → colors: `navigation`, radii: `control`,
18
+ * typography: `label.md`, motion: `feedback`.
19
+ */
20
+ interface LinkProps$1 extends LinkProps {
21
+ /**
22
+ * Semantic emphasis.
23
+ * @default 'primary'
24
+ */
25
+ evaluation?: EvaluationsFor<(typeof linkMeta)['entity']>;
26
+ }
27
+ /**
28
+ * A link component for navigation, styled with navigation tokens.
29
+ */
30
+ declare const Link: {
31
+ ({
32
+ evaluation,
33
+ ...props
34
+ }: LinkProps$1): import("react/jsx-runtime").JSX.Element;
35
+ displayName: "Link";
36
+ };
37
+ //#endregion
38
+ export { Link, LinkProps$1 as LinkProps, linkMeta };
@@ -0,0 +1,38 @@
1
+
2
+ import { EvaluationsFor } from "../../semantics/taxonomy.mjs";
3
+ import { LinkProps } from "react-aria-components";
4
+
5
+ //#region src/components/Link/Link.d.ts
6
+ /**
7
+ * Formal semantic identity — what this component *is* (Layer 1).
8
+ */
9
+ declare const linkMeta: {
10
+ readonly displayName: "Link";
11
+ readonly entity: "Navigation";
12
+ readonly structure: "root";
13
+ };
14
+ /**
15
+ * A navigation link built on React Aria with semantic tokens from CONTRACT.md.
16
+ *
17
+ * Entity = Navigation → colors: `navigation`, radii: `control`,
18
+ * typography: `label.md`, motion: `feedback`.
19
+ */
20
+ interface LinkProps$1 extends LinkProps {
21
+ /**
22
+ * Semantic emphasis.
23
+ * @default 'primary'
24
+ */
25
+ evaluation?: EvaluationsFor<(typeof linkMeta)['entity']>;
26
+ }
27
+ /**
28
+ * A link component for navigation, styled with navigation tokens.
29
+ */
30
+ declare const Link$1: {
31
+ ({
32
+ evaluation,
33
+ ...props
34
+ }: LinkProps$1): import("react/jsx-runtime").JSX.Element;
35
+ displayName: "Link";
36
+ };
37
+ //#endregion
38
+ export { Link$1 as Link, LinkProps$1 as LinkProps, linkMeta };
@@ -0,0 +1,61 @@
1
+ /** Powered by @ttoss/config. https://ttoss.dev/docs/modules/packages/config/ */
2
+ import { focusRingOutline } from "../../tokens/focusRing.mjs";
3
+ import { resolveInteractiveStyle } from "../../tokens/resolveInteractiveStyle.mjs";
4
+ import { vars } from "@ttoss/fsl-theme/vars";
5
+ import { Link } from "react-aria-components";
6
+ import { jsx } from "react/jsx-runtime";
7
+
8
+ //#region src/components/Link/Link.tsx
9
+ /**
10
+ * Formal semantic identity — what this component *is* (Layer 1).
11
+ */
12
+ var linkMeta = {
13
+ displayName: "Link",
14
+ entity: "Navigation",
15
+ structure: "root"
16
+ };
17
+ /**
18
+ * A link component for navigation, styled with navigation tokens.
19
+ */
20
+ var Link$1 = ({
21
+ evaluation = "primary",
22
+ ...props
23
+ }) => {
24
+ const colors = vars.colors.navigation[evaluation];
25
+ return /* @__PURE__ */jsx(Link, {
26
+ ...props,
27
+ "data-scope": "link",
28
+ "data-part": "root",
29
+ "data-evaluation": evaluation,
30
+ style: ({
31
+ isHovered,
32
+ isPressed,
33
+ isDisabled,
34
+ isFocusVisible
35
+ }) => {
36
+ return {
37
+ boxSizing: "border-box",
38
+ display: "inline-flex",
39
+ alignItems: "center",
40
+ textDecoration: isDisabled ? "none" : "underline",
41
+ textDecorationThickness: isHovered ? "2px" : "1px",
42
+ borderRadius: vars.radii.control,
43
+ transitionDuration: vars.motion.feedback.duration,
44
+ transitionTimingFunction: vars.motion.feedback.easing,
45
+ transitionProperty: "color, text-decoration-thickness",
46
+ cursor: isDisabled ? "not-allowed" : "pointer",
47
+ ...vars.text.label.md,
48
+ color: resolveInteractiveStyle(colors?.text, {
49
+ isHovered,
50
+ isPressed,
51
+ isDisabled
52
+ }),
53
+ outline: focusRingOutline(isFocusVisible)
54
+ };
55
+ }
56
+ });
57
+ };
58
+ Link$1.displayName = linkMeta.displayName;
59
+
60
+ //#endregion
61
+ export { Link$1 as Link, linkMeta };
@@ -0,0 +1,126 @@
1
+ /** Powered by @ttoss/config. https://ttoss.dev/docs/modules/packages/config/ */
2
+ const require_focusRing = require('../../tokens/focusRing.cjs');
3
+ const require_resolveInteractiveStyle = require('../../tokens/resolveInteractiveStyle.cjs');
4
+ let _ttoss_fsl_theme_vars = require("@ttoss/fsl-theme/vars");
5
+ let react_aria_components = require("react-aria-components");
6
+ let react_jsx_runtime = require("react/jsx-runtime");
7
+
8
+ //#region src/components/ListBox/ListBox.tsx
9
+ /** Formal semantic identity — ListBox root (Collection entity, surface). */
10
+ var listBoxMeta = {
11
+ displayName: "ListBox",
12
+ entity: "Collection",
13
+ structure: "root"
14
+ };
15
+ /** Formal semantic identity — ListBoxItem (Selection entity, one of a set). */
16
+ var listBoxItemMeta = {
17
+ displayName: "ListBoxItem",
18
+ entity: "Selection",
19
+ structure: "item",
20
+ composition: "selection"
21
+ };
22
+ /**
23
+ * A standalone semantic list box built on React Aria's `ListBox` — a
24
+ * selectable list of options.
25
+ *
26
+ * Per ADR-007 the CONTAINER is Entity = Collection (an `informational`
27
+ * surface) and each `ListBoxItem` is Entity = Selection (`input` chrome). Set
28
+ * `selectionMode="single|multiple"`. Use `ListBoxItem` for each option.
29
+ *
30
+ * @example
31
+ * ```tsx
32
+ * <ListBox aria-label="Frameworks" selectionMode="multiple">
33
+ * <ListBoxItem id="react">React</ListBoxItem>
34
+ * <ListBoxItem id="vue">Vue</ListBoxItem>
35
+ * </ListBox>
36
+ * ```
37
+ */
38
+ var ListBox = ({
39
+ children,
40
+ ...props
41
+ }) => {
42
+ const surface = _ttoss_fsl_theme_vars.vars.colors.informational.primary;
43
+ return /* @__PURE__ */(0, react_jsx_runtime.jsx)(react_aria_components.ListBox, {
44
+ ...props,
45
+ "data-scope": "list-box",
46
+ "data-part": "root",
47
+ style: {
48
+ boxSizing: "border-box",
49
+ display: "flex",
50
+ flexDirection: "column",
51
+ gap: _ttoss_fsl_theme_vars.vars.spacing.gap.stack.xs,
52
+ padding: _ttoss_fsl_theme_vars.vars.spacing.inset.surface.sm,
53
+ borderRadius: _ttoss_fsl_theme_vars.vars.radii.surface,
54
+ borderWidth: _ttoss_fsl_theme_vars.vars.border.outline.surface.width,
55
+ borderStyle: _ttoss_fsl_theme_vars.vars.border.outline.surface.style,
56
+ borderColor: surface?.border?.default ?? "transparent",
57
+ backgroundColor: surface?.background?.default
58
+ },
59
+ children
60
+ });
61
+ };
62
+ ListBox.displayName = listBoxMeta.displayName;
63
+ /**
64
+ * A single option inside a `ListBox`. Entity = Selection → reads
65
+ * `vars.colors.input.primary.*` and surfaces the `selected` State (set
66
+ * membership) — the same chrome as `SelectItem`.
67
+ *
68
+ * @example
69
+ * ```tsx
70
+ * <ListBoxItem id="react">React</ListBoxItem>
71
+ * ```
72
+ */
73
+ var ListBoxItem = ({
74
+ children,
75
+ ...props
76
+ }) => {
77
+ const c = _ttoss_fsl_theme_vars.vars.colors.input.primary;
78
+ return /* @__PURE__ */(0, react_jsx_runtime.jsx)(react_aria_components.ListBoxItem, {
79
+ ...props,
80
+ "data-scope": "list-box",
81
+ "data-part": "item",
82
+ style: ({
83
+ isHovered,
84
+ isPressed,
85
+ isDisabled,
86
+ isFocusVisible,
87
+ isSelected
88
+ }) => {
89
+ return {
90
+ boxSizing: "border-box",
91
+ display: "flex",
92
+ alignItems: "center",
93
+ paddingBlock: _ttoss_fsl_theme_vars.vars.spacing.inset.control.md,
94
+ paddingInline: _ttoss_fsl_theme_vars.vars.spacing.inset.control.md,
95
+ borderRadius: _ttoss_fsl_theme_vars.vars.radii.control,
96
+ cursor: isDisabled ? "not-allowed" : "pointer",
97
+ opacity: isDisabled ? _ttoss_fsl_theme_vars.vars.opacity.disabled : void 0,
98
+ ..._ttoss_fsl_theme_vars.vars.text.label.md,
99
+ backgroundColor: require_resolveInteractiveStyle.resolveInteractiveStyle(c?.background, {
100
+ isDisabled,
101
+ isSelected,
102
+ isHovered,
103
+ isPressed
104
+ }),
105
+ color: require_resolveInteractiveStyle.resolveInteractiveStyle(c?.text, {
106
+ isDisabled,
107
+ isSelected,
108
+ isHovered
109
+ }) ?? c?.text?.default,
110
+ outline: require_focusRing.focusRingOutline(isFocusVisible),
111
+ outlineOffset: "2px",
112
+ transitionProperty: "background-color, color",
113
+ transitionDuration: _ttoss_fsl_theme_vars.vars.motion.feedback.duration,
114
+ transitionTimingFunction: _ttoss_fsl_theme_vars.vars.motion.feedback.easing
115
+ };
116
+ },
117
+ children
118
+ });
119
+ };
120
+ ListBoxItem.displayName = listBoxItemMeta.displayName;
121
+
122
+ //#endregion
123
+ exports.ListBox = ListBox;
124
+ exports.ListBoxItem = ListBoxItem;
125
+ exports.listBoxItemMeta = listBoxItemMeta;
126
+ exports.listBoxMeta = listBoxMeta;
@@ -0,0 +1,63 @@
1
+
2
+ import { ListBoxItemProps, ListBoxProps } from "react-aria-components";
3
+
4
+ //#region src/components/ListBox/ListBox.d.ts
5
+ /** Formal semantic identity — ListBox root (Collection entity, surface). */
6
+ declare const listBoxMeta: {
7
+ readonly displayName: "ListBox";
8
+ readonly entity: "Collection";
9
+ readonly structure: "root";
10
+ };
11
+ /** Formal semantic identity — ListBoxItem (Selection entity, one of a set). */
12
+ declare const listBoxItemMeta: {
13
+ readonly displayName: "ListBoxItem";
14
+ readonly entity: "Selection";
15
+ readonly structure: "item";
16
+ readonly composition: "selection";
17
+ };
18
+ /** Props for the ListBox component. */
19
+ type ListBoxProps$1<T extends object = object> = Omit<ListBoxProps<T>, 'style' | 'className'>;
20
+ /**
21
+ * A standalone semantic list box built on React Aria's `ListBox` — a
22
+ * selectable list of options.
23
+ *
24
+ * Per ADR-007 the CONTAINER is Entity = Collection (an `informational`
25
+ * surface) and each `ListBoxItem` is Entity = Selection (`input` chrome). Set
26
+ * `selectionMode="single|multiple"`. Use `ListBoxItem` for each option.
27
+ *
28
+ * @example
29
+ * ```tsx
30
+ * <ListBox aria-label="Frameworks" selectionMode="multiple">
31
+ * <ListBoxItem id="react">React</ListBoxItem>
32
+ * <ListBoxItem id="vue">Vue</ListBoxItem>
33
+ * </ListBox>
34
+ * ```
35
+ */
36
+ declare const ListBox: {
37
+ <T extends object = object>({
38
+ children,
39
+ ...props
40
+ }: ListBoxProps$1<T>): import("react/jsx-runtime").JSX.Element;
41
+ displayName: "ListBox";
42
+ };
43
+ /** Props for the ListBoxItem component. */
44
+ type ListBoxItemProps$1 = Omit<ListBoxItemProps, 'style' | 'className'>;
45
+ /**
46
+ * A single option inside a `ListBox`. Entity = Selection → reads
47
+ * `vars.colors.input.primary.*` and surfaces the `selected` State (set
48
+ * membership) — the same chrome as `SelectItem`.
49
+ *
50
+ * @example
51
+ * ```tsx
52
+ * <ListBoxItem id="react">React</ListBoxItem>
53
+ * ```
54
+ */
55
+ declare const ListBoxItem: {
56
+ ({
57
+ children,
58
+ ...props
59
+ }: ListBoxItemProps$1): import("react/jsx-runtime").JSX.Element;
60
+ displayName: "ListBoxItem";
61
+ };
62
+ //#endregion
63
+ export { ListBox, ListBoxItem, ListBoxItemProps$1 as ListBoxItemProps, ListBoxProps$1 as ListBoxProps, listBoxItemMeta, listBoxMeta };
@@ -0,0 +1,63 @@
1
+
2
+ import { ListBoxItemProps, ListBoxProps } from "react-aria-components";
3
+
4
+ //#region src/components/ListBox/ListBox.d.ts
5
+ /** Formal semantic identity — ListBox root (Collection entity, surface). */
6
+ declare const listBoxMeta: {
7
+ readonly displayName: "ListBox";
8
+ readonly entity: "Collection";
9
+ readonly structure: "root";
10
+ };
11
+ /** Formal semantic identity — ListBoxItem (Selection entity, one of a set). */
12
+ declare const listBoxItemMeta: {
13
+ readonly displayName: "ListBoxItem";
14
+ readonly entity: "Selection";
15
+ readonly structure: "item";
16
+ readonly composition: "selection";
17
+ };
18
+ /** Props for the ListBox component. */
19
+ type ListBoxProps$1<T extends object = object> = Omit<ListBoxProps<T>, 'style' | 'className'>;
20
+ /**
21
+ * A standalone semantic list box built on React Aria's `ListBox` — a
22
+ * selectable list of options.
23
+ *
24
+ * Per ADR-007 the CONTAINER is Entity = Collection (an `informational`
25
+ * surface) and each `ListBoxItem` is Entity = Selection (`input` chrome). Set
26
+ * `selectionMode="single|multiple"`. Use `ListBoxItem` for each option.
27
+ *
28
+ * @example
29
+ * ```tsx
30
+ * <ListBox aria-label="Frameworks" selectionMode="multiple">
31
+ * <ListBoxItem id="react">React</ListBoxItem>
32
+ * <ListBoxItem id="vue">Vue</ListBoxItem>
33
+ * </ListBox>
34
+ * ```
35
+ */
36
+ declare const ListBox$1: {
37
+ <T extends object = object>({
38
+ children,
39
+ ...props
40
+ }: ListBoxProps$1<T>): import("react/jsx-runtime").JSX.Element;
41
+ displayName: "ListBox";
42
+ };
43
+ /** Props for the ListBoxItem component. */
44
+ type ListBoxItemProps$1 = Omit<ListBoxItemProps, 'style' | 'className'>;
45
+ /**
46
+ * A single option inside a `ListBox`. Entity = Selection → reads
47
+ * `vars.colors.input.primary.*` and surfaces the `selected` State (set
48
+ * membership) — the same chrome as `SelectItem`.
49
+ *
50
+ * @example
51
+ * ```tsx
52
+ * <ListBoxItem id="react">React</ListBoxItem>
53
+ * ```
54
+ */
55
+ declare const ListBoxItem$1: {
56
+ ({
57
+ children,
58
+ ...props
59
+ }: ListBoxItemProps$1): import("react/jsx-runtime").JSX.Element;
60
+ displayName: "ListBoxItem";
61
+ };
62
+ //#endregion
63
+ export { ListBox$1 as ListBox, ListBoxItem$1 as ListBoxItem, ListBoxItemProps$1 as ListBoxItemProps, ListBoxProps$1 as ListBoxProps, listBoxItemMeta, listBoxMeta };