@proyecto-viviana/ui 0.6.1 → 0.6.3
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/README.md +14 -16
- package/dist/_chunk/LinkButton.js +9 -9
- package/dist/_chunk/LinkButton.js.map +1 -1
- package/dist/_chunk/LinkButton.jsx +9 -9
- package/dist/_chunk/LinkButton.jsx.map +1 -1
- package/dist/_chunk/RangeCalendar.js +7 -7
- package/dist/_chunk/RangeCalendar.js.map +1 -1
- package/dist/_chunk/RangeCalendar.jsx +7 -7
- package/dist/_chunk/RangeCalendar.jsx.map +1 -1
- package/dist/_chunk/Tabs.js +2 -2
- package/dist/_chunk/Tabs.jsx +2 -2
- package/dist/_chunk/breadcrumbs.js +2 -2
- package/dist/_chunk/breadcrumbs.js.map +1 -1
- package/dist/_chunk/breadcrumbs.jsx +2 -2
- package/dist/_chunk/breadcrumbs.jsx.map +1 -1
- package/dist/_chunk/button.js +3 -3
- package/dist/_chunk/button.jsx +3 -3
- package/dist/_chunk/color.js +4 -4
- package/dist/_chunk/color.jsx +4 -4
- package/dist/_chunk/form.js +5 -7
- package/dist/_chunk/form.js.map +1 -1
- package/dist/_chunk/form.jsx +5 -8
- package/dist/_chunk/form.jsx.map +1 -1
- package/dist/_chunk/layout.js +5 -1
- package/dist/_chunk/layout.js.map +1 -1
- package/dist/_chunk/layout.jsx +5 -1
- package/dist/_chunk/layout.jsx.map +1 -1
- package/dist/_chunk/list.js +4 -4
- package/dist/_chunk/list.jsx +4 -4
- package/dist/_chunk/menu.js +1 -1
- package/dist/_chunk/menu.js.map +1 -1
- package/dist/_chunk/menu.jsx +1 -1
- package/dist/_chunk/menu.jsx.map +1 -1
- package/dist/_chunk/numberfield.js +2 -2
- package/dist/_chunk/numberfield.jsx +2 -2
- package/dist/_chunk/s2-action-button-styles.js +8 -8
- package/dist/_chunk/s2-action-button-styles.js.map +1 -1
- package/dist/_chunk/s2-action-button-styles.jsx +8 -8
- package/dist/_chunk/s2-action-button-styles.jsx.map +1 -1
- package/dist/_chunk/s2-menu-styles.js +1 -1
- package/dist/_chunk/s2-menu-styles.jsx +1 -1
- package/dist/_chunk/slider.js +6 -6
- package/dist/_chunk/slider.jsx +6 -6
- package/dist/_chunk/switch.js +2 -2
- package/dist/_chunk/switch.jsx +2 -2
- package/dist/_chunk/table.js +3 -3
- package/dist/_chunk/table.js.map +1 -1
- package/dist/_chunk/table.jsx +3 -3
- package/dist/_chunk/table.jsx.map +1 -1
- package/dist/_chunk/text.js +1 -1
- package/dist/_chunk/text.jsx +1 -1
- package/dist/_chunk/textfield.js +4 -4
- package/dist/_chunk/textfield.jsx +4 -4
- package/dist/_chunk/toast.js +3 -3
- package/dist/_chunk/toast.jsx +3 -3
- package/dist/actiongroup/index.js +2 -2
- package/dist/actiongroup/index.jsx +2 -2
- package/dist/badge/index.js +6 -6
- package/dist/badge/index.jsx +6 -6
- package/dist/breadcrumbs/index.d.ts.map +1 -1
- package/dist/calendar/DateField.d.ts.map +1 -1
- package/dist/calendar/DateField.js +2 -2
- package/dist/calendar/DateField.js.map +1 -1
- package/dist/calendar/DateField.jsx +2 -2
- package/dist/calendar/DateField.jsx.map +1 -1
- package/dist/calendar/DatePicker.d.ts.map +1 -1
- package/dist/calendar/DatePicker.js +2 -2
- package/dist/calendar/DatePicker.js.map +1 -1
- package/dist/calendar/DatePicker.jsx +2 -2
- package/dist/calendar/DatePicker.jsx.map +1 -1
- package/dist/calendar/DateRangePicker.js +2 -2
- package/dist/calendar/DateRangePicker.jsx +2 -2
- package/dist/calendar/RangeCalendar.d.ts.map +1 -1
- package/dist/calendar/TimeField.d.ts.map +1 -1
- package/dist/calendar/TimeField.js +2 -2
- package/dist/calendar/TimeField.js.map +1 -1
- package/dist/calendar/TimeField.jsx +2 -2
- package/dist/calendar/TimeField.jsx.map +1 -1
- package/dist/calendar/index.js +5 -5
- package/dist/calendar/index.js.map +1 -1
- package/dist/calendar/index.jsx +5 -5
- package/dist/calendar/index.jsx.map +1 -1
- package/dist/checkbox/index.js +3 -3
- package/dist/checkbox/index.jsx +3 -3
- package/dist/combobox/index.js +2 -2
- package/dist/combobox/index.jsx +2 -2
- package/dist/dropzone/index.js +1 -1
- package/dist/dropzone/index.jsx +1 -1
- package/dist/font-faces.css +13 -6
- package/dist/form/index.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelChartIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelChartIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelChartIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelCheckIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelCheckIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelCheckIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelChevronDownIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelChevronDownIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelChevronDownIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelChevronRightIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelChevronRightIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelChevronRightIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelClockIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelClockIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelClockIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelCodeIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelCodeIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelCodeIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelCommunityIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelCommunityIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelCommunityIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelCubeIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelCubeIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelCubeIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelFlameIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelFlameIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelFlameIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelHomeIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelHomeIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelHomeIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelLayoutIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelLayoutIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelLayoutIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelMessageIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelMessageIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelMessageIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavCommunityIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavCommunityIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavCommunityIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavExploreIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavExploreIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavExploreIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavLiveIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavLiveIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavLiveIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavPathwaysIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavPathwaysIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavPathwaysIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavPlaygroundIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavPlaygroundIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavPlaygroundIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavProjectsIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavProjectsIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavProjectsIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavReferenceIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavReferenceIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavReferenceIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavSettingsIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavSettingsIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavSettingsIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNavTopicsIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNavTopicsIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNavTopicsIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelNotificationIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelNotificationIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelNotificationIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelPathwaysIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelPathwaysIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelPathwaysIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelPlayIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelPlayIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelPlayIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelSearchIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelSearchIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelSearchIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelSettingsIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelSettingsIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelSettingsIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelSparkleIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelSparkleIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelSparkleIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelTopicsIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelTopicsIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelTopicsIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelUserIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelUserIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelUserIcon.jsx.map +1 -1
- package/dist/icon/pixel-icons/PixelZapIcon.d.ts.map +1 -1
- package/dist/icon/pixel-icons/PixelZapIcon.js.map +1 -1
- package/dist/icon/pixel-icons/PixelZapIcon.jsx.map +1 -1
- package/dist/inlinealert/index.js +6 -6
- package/dist/inlinealert/index.jsx +6 -6
- package/dist/labeledvalue/index.js +1 -1
- package/dist/labeledvalue/index.jsx +1 -1
- package/dist/layout/Flex.d.ts +2 -0
- package/dist/layout/Flex.d.ts.map +1 -1
- package/dist/link/index.d.ts.map +1 -1
- package/dist/link/index.js +1 -4
- package/dist/link/index.js.map +1 -1
- package/dist/link/index.jsx +1 -4
- package/dist/link/index.jsx.map +1 -1
- package/dist/listbox/index.js +3 -3
- package/dist/listbox/index.jsx +4 -4
- package/dist/menu/index.d.ts.map +1 -1
- package/dist/meter/index.d.ts.map +1 -1
- package/dist/meter/index.js +2 -2
- package/dist/meter/index.js.map +1 -1
- package/dist/meter/index.jsx +2 -2
- package/dist/meter/index.jsx.map +1 -1
- package/dist/notificationbadge/index.js +1 -1
- package/dist/notificationbadge/index.jsx +1 -1
- package/dist/picker/index.js +3 -3
- package/dist/picker/index.jsx +3 -3
- package/dist/popover/index.js +1 -1
- package/dist/popover/index.jsx +1 -1
- package/dist/progress/ProgressCircle.js +2 -2
- package/dist/progress/ProgressCircle.js.map +1 -1
- package/dist/progress/ProgressCircle.jsx +2 -2
- package/dist/progress/ProgressCircle.jsx.map +1 -1
- package/dist/progress-bar/index.js +4 -4
- package/dist/progress-bar/index.jsx +4 -4
- package/dist/radio/index.js +2 -2
- package/dist/radio/index.jsx +2 -2
- package/dist/searchfield/index.js +2 -2
- package/dist/searchfield/index.jsx +2 -2
- package/dist/segmentedcontrol/index.js +2 -5
- package/dist/segmentedcontrol/index.js.map +1 -1
- package/dist/segmentedcontrol/index.jsx +2 -5
- package/dist/segmentedcontrol/index.jsx.map +1 -1
- package/dist/select/index.js +3 -3
- package/dist/select/index.jsx +3 -3
- package/dist/selectboxgroup/index.js +1 -1
- package/dist/selectboxgroup/index.jsx +1 -1
- package/dist/statuslight/index.js +1 -1
- package/dist/statuslight/index.jsx +1 -1
- package/dist/steplist/index.js +5 -5
- package/dist/steplist/index.jsx +5 -5
- package/dist/style/glasselated-ramps.d.ts.map +1 -1
- package/dist/style/index.js +18 -9
- package/dist/style/index.js.map +1 -1
- package/dist/style/spectrum-theme.d.ts +7 -7
- package/dist/style/spectrum-theme.d.ts.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/table/index.d.ts.map +1 -1
- package/dist/tag-group/index.js +10 -10
- package/dist/tag-group/index.js.map +1 -1
- package/dist/tag-group/index.jsx +10 -10
- package/dist/tag-group/index.jsx.map +1 -1
- package/dist/toolbar/index.d.ts.map +1 -1
- package/dist/toolbar/index.js.map +1 -1
- package/dist/toolbar/index.jsx.map +1 -1
- package/dist/tree/index.d.ts.map +1 -1
- package/dist/tree/index.js +5 -5
- package/dist/tree/index.js.map +1 -1
- package/dist/tree/index.jsx +5 -5
- package/dist/tree/index.jsx.map +1 -1
- package/dist/viviana-tokens.css +39 -12
- package/package.json +18 -5
- package/src/breadcrumbs/index.tsx +14 -7
- package/src/button/s2-action-button-styles.ts +8 -8
- package/src/button/s2-button-styles.ts +8 -8
- package/src/calendar/DateField.tsx +2 -6
- package/src/calendar/DatePicker.tsx +8 -1
- package/src/calendar/RangeCalendar.tsx +13 -7
- package/src/calendar/TimeField.tsx +2 -6
- package/src/calendar/index.tsx +4 -4
- package/src/font-faces.css +13 -6
- package/src/form/index.tsx +5 -6
- package/src/icon/pixel-icons/PixelChartIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelCheckIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelChevronDownIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelChevronRightIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelClockIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelCodeIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelCommunityIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelCubeIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelFlameIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelHomeIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelLayoutIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelMessageIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavCommunityIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavExploreIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavLiveIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavPathwaysIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavPlaygroundIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavProjectsIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavReferenceIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavSettingsIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNavTopicsIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelNotificationIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelPathwaysIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelPlayIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelSearchIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelSettingsIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelSparkleIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelTopicsIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelUserIcon.tsx +4 -1
- package/src/icon/pixel-icons/PixelZapIcon.tsx +4 -1
- package/src/layout/Flex.tsx +7 -0
- package/src/link/index.tsx +3 -1
- package/src/menu/index.tsx +1 -3
- package/src/meter/index.tsx +1 -3
- package/src/progress/ProgressCircle.tsx +1 -1
- package/src/segmentedcontrol/index.tsx +6 -6
- package/src/style/glasselated-ramps.ts +37 -33
- package/src/style/spectrum-theme.ts +22 -17
- package/src/table/index.tsx +1 -3
- package/src/tag-group/index.tsx +8 -8
- package/src/toolbar/index.tsx +4 -1
- package/src/tree/index.tsx +3 -11
- package/src/viviana-tokens.css +39 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../src/tag-group/index.tsx"],"sourcesContent":["// @ts-nocheck\nimport {\n type JSX,\n children as resolveChildren,\n createContext,\n createUniqueId,\n mergeProps,\n splitProps,\n useContext,\n Show,\n} from \"solid-js\";\nimport { isServer } from \"solid-js/web\";\nimport { getSlottedContextProps, type SpectrumContextValue } from \"../button/spectrum-context\";\nimport {\n TagList as HeadlessTagList,\n Tag as HeadlessTag,\n TagRemoveButton as HeadlessTagRemoveButton,\n type TagListProps as HeadlessTagListProps,\n type TagRenderProps,\n type TagProps as HeadlessTagProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport type { Key, SelectionBehavior, SelectionMode } from \"@proyecto-viviana/solid-stately\";\nimport type { StyleString } from \"../style\";\nimport { baseColor, focusRing, lightDark, style } from \"../style\" with { type: \"macro\" };\nimport {\n control,\n controlFont,\n field,\n fieldInput,\n fieldLabel,\n getAllowedOverrides,\n} from \"../s2-internal/style-utils\" with { type: \"macro\" };\nimport { useProviderProps } from \"../provider\";\nimport { pressScale } from \"../pressScale\";\nimport AlertTriangleIcon from \"../icon/s2wf-icons/AlertTriangleIcon\";\nimport { CrossIcon } from \"../icon/ui-icons/Cross\";\nimport { ActionButton } from \"../button/ActionButton\";\n\nexport type TagGroupSize = \"S\" | \"M\" | \"L\" | \"sm\" | \"md\" | \"lg\";\ntype S2TagGroupSize = \"S\" | \"M\" | \"L\";\nexport type TagGroupVariant = \"default\" | \"outline\" | \"solid\";\nexport type TagGroupLabelPosition = \"top\" | \"side\";\nexport type TagGroupLabelAlign = \"start\" | \"end\";\n\nexport interface TagGroupProps<T extends { id?: Key; key?: Key }> extends Omit<\n HeadlessTagListProps<T>,\n \"class\" | \"style\" | \"children\" | \"label\"\n> {\n /** The label for the tag group. */\n label?: JSX.Element;\n /** Function to render each tag or each tag's content. */\n children: (item: T) => JSX.Element;\n /** S2 tag size. Legacy sm/md/lg aliases map to S/M/L. @default 'M' */\n size?: TagGroupSize;\n /** Legacy visual variant. Prefer `isEmphasized` for S2 parity. */\n variant?: TagGroupVariant;\n /** Whether selected tags use the emphasized accent fill. */\n isEmphasized?: boolean;\n /** Description text shown below the tag list. */\n description?: JSX.Element;\n /** Error message shown when invalid. */\n errorMessage?: JSX.Element;\n /** Whether the group is invalid. */\n isInvalid?: boolean;\n /** Position of the label relative to the tag list. */\n labelPosition?: TagGroupLabelPosition;\n /** Text alignment for side labels. */\n labelAlign?: TagGroupLabelAlign;\n /** Label for the optional group action button. */\n groupActionLabel?: string;\n /** Handler for the optional group action button. */\n onGroupAction?: () => void;\n /** Maximum visible rows. This is approximated with overflow clipping in Solid. */\n maxRows?: number;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n /** Backward-compatible class alias. Prefer UNSAFE_className for S2 parity. */\n class?: string;\n /** Backward-compatible inline style alias. Prefer UNSAFE_style for S2 parity. */\n style?: JSX.CSSProperties;\n /** Handler called when a tag is activated. */\n onAction?: (key: Key) => void;\n}\n\nexport interface TagProps extends Omit<HeadlessTagProps, \"class\" | \"style\" | \"children\"> {\n /** The content of the tag. */\n children?: JSX.Element;\n /** Whether selected tags use the emphasized accent fill. Inherited from TagGroup. */\n isEmphasized?: boolean;\n /** S2 tag size. Inherited from TagGroup. */\n size?: TagGroupSize;\n /** Href retained for API parity; rendered as a tag action in the current Solid primitive. */\n href?: string;\n /** Link target retained for API parity. */\n target?: string;\n /** Link relationship retained for API parity. */\n rel?: string;\n /** Handler called when this tag is activated. */\n onAction?: (key: Key) => void;\n /** Additional CSS class name. Use only as a last resort. */\n class?: string;\n /** Additional inline styles. Use only as a last resort. */\n style?: JSX.CSSProperties;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n}\n\nexport const TagGroupContext = createContext<SpectrumContextValue<TagGroupProps<any>>>(null);\n\ninterface TagGroupContextValue {\n size: S2TagGroupSize;\n isEmphasized: boolean;\n onAction?: (key: Key) => void;\n}\n\ninterface TagGroupStyleProps extends TagRenderProps {\n size?: S2TagGroupSize;\n labelPosition?: TagGroupLabelPosition;\n labelAlign?: TagGroupLabelAlign;\n isEmphasized?: boolean;\n isInvalid?: boolean;\n isLink?: boolean;\n isEmpty?: boolean;\n isDisabled?: boolean;\n allowsRemoving?: boolean;\n}\n\nconst StyledTagGroupContext = createContext<TagGroupContextValue>();\n\nconst tagGroupRoot = style<TagGroupStyleProps>(\n {\n ...field(),\n font: controlFont(),\n color: {\n default: baseColor(\"neutral\"),\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isDisabled: \"GrayText\",\n },\n },\n },\n getAllowedOverrides(),\n);\n\nconst labelWrapper = style<TagGroupStyleProps>({\n gridArea: \"label\",\n display: \"inline\",\n textAlign: {\n labelAlign: {\n start: \"start\",\n end: \"end\",\n },\n },\n paddingBottom: {\n labelPosition: {\n top: \"--field-gap\",\n },\n },\n contain: {\n labelPosition: {\n top: \"inline-size\",\n },\n },\n});\n\nconst labelStyle = style({\n ...fieldLabel(),\n});\n\nconst tagListContainer = style<TagGroupStyleProps>({\n gridArea: \"input\",\n minWidth: \"full\",\n marginStart: {\n default: -4,\n isEmpty: 0,\n },\n marginEnd: {\n default: 4,\n isEmpty: 0,\n },\n position: \"relative\",\n});\n\nconst tagListStyle = style({\n ...fieldInput(),\n display: \"inline\",\n minWidth: \"full\",\n // S2's real `<TagList>` sets a FIXED `font: 'ui'` (14px) on the grid container —\n // NOT the size-conditional `controlFont()`. The tags scale their own font via\n // `control()`; the grid's font is a static default (D1 grid font-size diverges at\n // size S/L when this ramps).\n font: \"ui\",\n outlineStyle: \"none\",\n});\n\nconst tagStyle = style<TagGroupStyleProps>({\n ...focusRing(),\n ...control({ shape: \"default\", icon: true, register: \"chip\" }),\n display: \"inline-flex\",\n maxWidth: \"full\",\n verticalAlign: \"middle\",\n justifyContent: \"center\",\n transition: \"default\",\n /* The muted chip is a WELL, not a gray step. All three of the handoff's unselected\n * chips are drawn `background: var(--surface-well)` inside `--well-border`\n * (TerminalGlassLab.tsx:35-55) — the same matte surface as a terminal well, which is\n * why `control({register:\"chip\"})` above already hands them the well's border. The\n * fill was the last part still coming off the ramp, and `gray-100` is opaque on both\n * columns (#e5eaf1 / #43474d), so the chips read as flat grey plates on a page whose\n * every other surface is glass or well: 10 elements in dark, 10 in light.\n *\n * Hover has no drawn counterpart — the handoff's chips are static — so it takes\n * `surface-hover`, the register's one hover surface, rather than a second ramp step. */\n backgroundColor: {\n default: \"well\",\n isHovered: {\n default: \"surface-hover\",\n },\n isFocusVisible: {\n default: \"surface-hover\",\n },\n isSelected: {\n default: baseColor(\"neutral\"),\n isEmphasized: {\n default: lightDark(\"accent-900\", \"accent-700\"),\n isHovered: lightDark(\"accent-1000\", \"accent-800\"),\n isPressed: lightDark(\"accent-1000\", \"accent-800\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-800\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonFace\",\n isSelected: \"Highlight\",\n },\n },\n /* ...and the well's dither with it. The handoff sets `scan: true` on exactly the three\n * well-filled chips and `scan: false` on the selected one (TerminalGlassLab.tsx:33, :40),\n * so the texture follows the fill: a chip that stops being a well stops being dithered.\n *\n * The gradient is `wellScan()`'s literal, restated rather than spread because that helper\n * emits an unconditional `backgroundImage` and this needs the `isSelected` branch —\n * spreading it and re-declaring the key in the same object is the duplicate-key trap.\n * `wellScan()` remains the source of the value; if it moves, this moves with it. */\n backgroundImage: {\n default: \"[repeating-conic-gradient(var(--well-scan) 0% 25%, transparent 0% 50%)]\",\n isSelected: \"none\",\n forcedColors: \"none\",\n },\n backgroundSize: \"[4px 4px]\",\n color: {\n default: baseColor(\"neutral\"),\n isSelected: {\n default: \"gray-25\",\n isEmphasized: \"white\",\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isSelected: \"HighlightText\",\n isDisabled: \"GrayText\",\n },\n },\n /* The chip's 1px edge arrives with `control({register: \"chip\"})` above, which sets\n * `borderWidth: 1`, `borderStyle: \"solid\"` and a resting `borderColor: \"well-border\"`\n * (s2-internal/style-utils.ts). This slot previously held `borderStyle: \"none\"`, and\n * because a literal key REPLACES the spread's value for that property, it cancelled the\n * register's edge outright — the chip drew no border at all. Only the state colours\n * belong here now; the width and style come from the register.\n *\n * A `default` stop is mandatory, not redundant with the spread: declaring `borderColor`\n * as a literal key discards the register's `well-border` for every state this map does\n * not name, and an unnamed state would fall back to `currentColor` (the tag's text).\n *\n * The stops mirror the `backgroundColor` map above so a selected chip's edge matches its\n * own fill rather than outlining it in the muted well colour.\n *\n * `gray-800` here is deliberate and must not be \"corrected\" to `baseColor(\"neutral\")` for\n * symmetry with the fill above: the theme's `borderColor` map (style/spectrum-theme.ts)\n * exposes `...baseColors` plus `negative`, `disabled` and the three edge tokens, but no\n * `neutral` — that key exists only on the `color`, `backgroundColor` and `fill` maps, so\n * `neutral` throws `Invalid color neutral` at macro build time. This file is `@ts-nocheck`,\n * so that surfaces as a build crash rather than a type error. The substitution is exact,\n * not approximate: `neutral` on `backgroundColor` is `neutral-background-color-default`,\n * which is a token `ref` to `{gray-800}`, and `nextColorStop` recurses through refs — so\n * both spellings resolve to the same stop and both step to gray-900 on hover/press. */\n borderColor: {\n default: \"well-border\",\n isSelected: {\n default: baseColor(\"gray-800\"),\n isEmphasized: {\n default: lightDark(\"accent-900\", \"accent-700\"),\n isHovered: lightDark(\"accent-1000\", \"accent-800\"),\n isPressed: lightDark(\"accent-1000\", \"accent-800\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-800\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonBorder\",\n isSelected: \"Highlight\",\n isDisabled: \"GrayText\",\n },\n },\n paddingEnd: {\n default: \"edge-to-text\",\n allowsRemoving: 0,\n },\n margin: 4,\n cursor: {\n default: \"default\",\n isLink: \"pointer\",\n isDisabled: \"default\",\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\n// S2's TagWrapper CONTENT DIV (a sibling of the ClearButton at the tag-row flex\n// level). It carries NO `order`, so it keeps DOM order (content before the remove\n// button). The `order`/`truncate` belong on the inner Text (`tagTextStyle`), NOT\n// here — putting them on the row-level element sorts the label AFTER the\n// `order: 0` remove button (`× Landscape` instead of `Landscape ×`).\nconst tagContentStyle = style({\n display: \"flex\",\n minWidth: 0,\n alignItems: \"center\",\n gap: \"text-to-visual\",\n forcedColorAdjust: \"none\",\n backgroundColor: \"transparent\",\n});\n\n// S2's `TextContext` styles inside the content div: `{order: 1, truncate: true}`\n// (icon slots take `order: 0`, so the icon precedes the text regardless of DOM\n// order). Scoped to the inner text — see `tagContentStyle`.\nconst tagTextStyle = style({\n order: 1,\n truncate: true,\n});\n\n// Captured so the `outlineColor` static-color branch can reuse the focus ring's own\n// default (mirrors S2 `const focusRingStyles = focusRing()`).\nconst removeButtonFocusRing = focusRing();\n\nconst removeButtonStyle = style<TagGroupStyleProps>({\n ...removeButtonFocusRing,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n // Mirror S2 ClearButton (`visibleClearButton`): fill the tag height and width to\n // the control-size ramp (`controlSize()` = {S: 24, M: 32, L: 40}). The port's\n // local `controlSize` helper has a different meaning, so the ramp is inlined.\n height: \"full\",\n width: {\n size: {\n S: 24,\n M: 32,\n L: 40,\n },\n },\n flexShrink: 0,\n borderRadius: \"full\",\n borderStyle: \"none\",\n backgroundColor: \"transparent\",\n color: \"inherit\",\n boxSizing: \"border-box\",\n padding: 0,\n outlineOffset: -4,\n // Mirror S2 `visibleClearButton`: a static-color (emphasized + selected) tag uses\n // a white focus outline against its accent fill; every other tag uses the default\n // focus-ring colour. `isStaticColor` = `isEmphasized && isSelected` (threaded in\n // by the TagWrapper — here at the render site).\n outlineColor: {\n default: removeButtonFocusRing.outlineColor,\n isStaticColor: \"white\",\n },\n // S2 `visibleClearButton` sets NO cursor — the native `<button>` UA cursor\n // (`default`) stands. Do NOT re-add the arrow→`pointer` override (an invented\n // divergence: D1 pins React's native `default`).\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\nconst helpTextStyle = style<TagGroupStyleProps>({\n gridArea: \"helptext\",\n display: \"flex\",\n margin: 0,\n alignItems: \"baseline\",\n gap: \"text-to-visual\",\n font: controlFont(),\n color: {\n default: \"neutral-subdued\",\n isInvalid: {\n default: \"negative\",\n forcedColors: \"Mark\",\n },\n isDisabled: {\n default: \"disabled\",\n forcedColors: \"GrayText\",\n },\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n contain: \"inline-size\",\n paddingTop: \"--field-gap\",\n});\n\nconst emptyStateStyle = style({\n color: \"neutral-subdued\",\n font: controlFont(),\n});\n\nconst actionRowStyle = style({\n display: \"inline-flex\",\n verticalAlign: \"middle\",\n margin: 4,\n gap: 4,\n});\n\nconst errorIconStyle = style({\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n flexShrink: 0,\n});\n\nfunction normalizeSize(size: TagGroupSize | undefined): S2TagGroupSize {\n switch (size) {\n case \"sm\":\n return \"S\";\n case \"md\":\n return \"M\";\n case \"lg\":\n return \"L\";\n case \"S\":\n case \"M\":\n case \"L\":\n return size;\n default:\n return \"M\";\n }\n}\n\nfunction getItemKey<T extends { id?: Key; key?: Key }>(item: T, getKey?: (item: T) => Key): Key {\n if (getKey) return getKey(item);\n if (item.id !== undefined) return item.id;\n if (item.key !== undefined) return item.key;\n return String(item);\n}\n\nfunction hasKey(keys: Iterable<Key> | \"all\" | undefined, key: Key): boolean {\n if (keys == null) {\n return false;\n }\n\n if (keys === \"all\") {\n return true;\n }\n\n if (\"has\" in keys && typeof keys.has === \"function\") {\n return keys.has(key);\n }\n\n for (const value of keys) {\n if (value === key) {\n return true;\n }\n }\n\n return false;\n}\n\n// Matches a `role=\"row\"` attribute in a serialized SSR node's markup, mirroring the client-side\n// `getAttribute(\"role\") === \"row\"` check below.\nconst SSR_TAG_ROW_PATTERN = /\\srole=\"row\"[\\s>]/;\n// Matches the `solidaria-Tag` token inside a `class=\"...\"` attribute, mirroring the client-side\n// `classList.contains(\"solidaria-Tag\")` check below.\nconst SSR_TAG_CLASS_PATTERN = /\\sclass=\"[^\"]*\\bsolidaria-Tag\\b[^\"]*\"/;\n\nfunction isRenderedTag(value: JSX.Element): boolean {\n if (Array.isArray(value)) {\n return value.length === 1 && isRenderedTag(value[0]);\n }\n\n if (isServer) {\n // During renderToString, resolved children are Solid's server-side SSR node objects\n // (`{ t: string }` holding the serialized HTML), not HTMLElement instances — `HTMLElement`\n // isn't even a global in Node. Duck-type the same \"already a rendered Tag row\" signal the\n // client checks for (a `role=\"row\"` gridcell wrapper carrying the Tag class) by inspecting\n // the markup string directly, so the wrap/no-wrap decision matches what the client will\n // compute once `HTMLElement` is real and hydration can walk a matching tree.\n const markup = (value as { t?: unknown } | null | undefined)?.t;\n if (typeof markup !== \"string\") {\n return false;\n }\n return SSR_TAG_ROW_PATTERN.test(markup) || SSR_TAG_CLASS_PATTERN.test(markup);\n }\n\n if (typeof HTMLElement === \"undefined\" || !(value instanceof HTMLElement)) {\n return false;\n }\n return value.getAttribute(\"role\") === \"row\" || value.classList.contains(\"solidaria-Tag\");\n}\n\nfunction joinIds(...ids: Array<string | undefined | false>) {\n return ids.filter(Boolean).join(\" \") || undefined;\n}\n\nfunction maxRowsStyle(\n maxRows: number | undefined,\n size: S2TagGroupSize,\n): JSX.CSSProperties | undefined {\n if (maxRows == null || maxRows <= 0) {\n return undefined;\n }\n\n const rowHeight = size === \"L\" ? 44 : size === \"S\" ? 30 : 36;\n return {\n \"max-height\": `${rowHeight * maxRows}px`,\n overflow: \"hidden\",\n };\n}\n\nfunction resolveStyleClass<P extends Record<string, unknown>>(\n styleValue: StyleString | ((props: P) => StyleString),\n props: P,\n): string {\n return typeof styleValue === \"function\" ? styleValue(props) : styleValue;\n}\n\n/**\n * An individual Tag for TagGroups.\n */\nexport function Tag(props: TagProps): JSX.Element {\n const ctx = useContext(StyledTagGroupContext);\n const [local, tagProps] = splitProps(props, [\n \"class\",\n \"style\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"children\",\n \"id\",\n \"isDisabled\",\n \"isEmphasized\",\n \"size\",\n \"href\",\n \"target\",\n \"rel\",\n \"onAction\",\n \"textValue\",\n ]);\n\n // Mirror S2 Tag: derive the row's accessible text from string children when no\n // explicit textValue is given. This names the row (and cascades to the remove\n // button's `aria-labelledby` and the gridcell's name-from-contents), matching\n // how S2 auto-derives `node.textValue` from string children.\n const textValue = () =>\n local.textValue ?? (typeof local.children === \"string\" ? local.children : undefined);\n const size = () => normalizeSize(local.size ?? ctx?.size);\n const isEmphasized = () => local.isEmphasized ?? ctx?.isEmphasized ?? false;\n const isLink = () => local.href != null;\n const actionHandler = () => local.onAction ?? ctx?.onAction;\n\n // Mirror S2 Tag: `ref={domRef} style={pressScale(domRef)}` — the layer hint\n // (`will-change: transform`) at rest, plus the press-scale transform on press.\n let tagEl: HTMLDivElement | undefined;\n const rowStyle = (renderProps: TagRenderProps): JSX.CSSProperties =>\n pressScale(() => tagEl, local.UNSAFE_style ?? local.style)(renderProps);\n\n // Mirror S2 ClearButton: `<Button style={pressScale(domRef)}>` — pressScale\n // ALWAYS contributes the `will-change: transform` layer hint. The plain headless\n // remove button carries no press state yet, so only the resting hint is mirrored\n // here; the on-press scale lands with the CP9.44b interaction pass\n // (tech-debt `taggroup-remove-pressscale`).\n const removeButtonRestStyle = pressScale(undefined)({ isPressed: false });\n\n const className = (renderProps: TagRenderProps) =>\n [\n local.UNSAFE_className,\n local.class,\n tagStyle(\n {\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n isLink: isLink(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <HeadlessTag\n {...tagProps}\n id={local.id}\n isDisabled={local.isDisabled}\n textValue={textValue()}\n class={className}\n ref={(el: HTMLDivElement) => (tagEl = el)}\n style={rowStyle}\n data-href={local.href}\n data-target={local.target}\n data-rel={local.rel}\n onAction={() => actionHandler()?.(local.id)}\n >\n {(renderProps) => (\n <>\n <div class={resolveStyleClass(tagContentStyle, {})}>\n <span class={resolveStyleClass(tagTextStyle, {})}>{local.children}</span>\n </div>\n <Show when={renderProps.allowsRemoving}>\n <HeadlessTagRemoveButton\n buttonProps={renderProps.removeButtonProps}\n class={removeButtonStyle({\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n // S2 TagWrapper: `isStaticColor={isEmphasized && isSelected}`.\n isStaticColor: isEmphasized() && renderProps.isSelected,\n })}\n style={removeButtonRestStyle}\n >\n {/* S2 ClearButton renders `<CrossIcon size={props.size}/>` with the RAW\n control size — the ui-icon selects its own variant (S→Size75,\n M→Size100, L→Size200) and CSS width (S=M=8px, L=10px). Passing a\n down-mapped size renders the wrong Cross path variant. No\n `aria-hidden`: S2's ClearButton leaves the bare CrossIcon svg\n exposed (Chromium reports an unnamed `img` under the labelled\n remove button), so mirror that AX shape rather than hiding it. */}\n <CrossIcon size={size()} />\n </HeadlessTagRemoveButton>\n </Show>\n </>\n )}\n </HeadlessTag>\n );\n}\n\n/**\n * A tag group displays a collection of tags that can be selected and/or removed.\n */\nexport function TagGroup<T extends { id?: Key; key?: Key }>(props: TagGroupProps<T>): JSX.Element {\n const providerProps = useProviderProps(props);\n const contextProps = getSlottedContextProps(useContext(TagGroupContext), props.slot);\n const mergedProps = mergeProps(providerProps, contextProps ?? {}, props);\n const [local, listProps] = splitProps(mergedProps, [\n \"label\",\n \"items\",\n \"children\",\n \"getKey\",\n \"onRemove\",\n \"size\",\n \"variant\",\n \"isEmphasized\",\n \"description\",\n \"errorMessage\",\n \"isInvalid\",\n \"labelPosition\",\n \"labelAlign\",\n \"groupActionLabel\",\n \"onGroupAction\",\n \"maxRows\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"class\",\n \"style\",\n \"renderEmptyState\",\n \"selectionMode\",\n \"selectionBehavior\",\n \"selectedKeys\",\n \"defaultSelectedKeys\",\n \"onSelectionChange\",\n \"disabledKeys\",\n \"isDisabled\",\n \"onAction\",\n \"id\",\n \"aria-label\",\n \"aria-labelledby\",\n \"aria-describedby\",\n ]);\n\n const labelId = createUniqueId();\n const descriptionId = createUniqueId();\n const errorId = createUniqueId();\n const size = () => normalizeSize(local.size);\n const labelPosition = () => local.labelPosition ?? \"top\";\n const labelAlign = () => local.labelAlign ?? \"start\";\n const isInvalid = () => local.isInvalid === true;\n const isEmphasized = () => local.isEmphasized ?? local.variant === \"solid\";\n const hasItems = () => local.items.length > 0;\n const keyForItem = (item: T) => getItemKey(item, local.getKey);\n const renderedEmptyState = () => (\n <span class={resolveStyleClass(emptyStateStyle, { size: size() })}>\n {local.renderEmptyState?.() ?? \"No tags\"}\n </span>\n );\n\n const describedBy = () =>\n joinIds(\n local[\"aria-describedby\"],\n local.description && !isInvalid() ? descriptionId : undefined,\n local.errorMessage && isInvalid() ? errorId : undefined,\n );\n\n const rootClass = () =>\n [\n local.UNSAFE_className,\n local.class,\n tagGroupRoot(\n {\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n isDisabled: local.isDisabled,\n isInvalid: isInvalid(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n const renderItem = (item: T) => {\n const resolved = resolveChildren(() => local.children(item));\n const rendered = resolved();\n if (isRenderedTag(rendered)) {\n return rendered;\n }\n\n return (\n <Tag id={keyForItem(item)} isDisabled={hasKey(local.disabledKeys, keyForItem(item))}>\n {rendered}\n </Tag>\n );\n };\n\n const contextValue: TagGroupContextValue = {\n get size() {\n return size();\n },\n get isEmphasized() {\n return isEmphasized();\n },\n get onAction() {\n return local.onAction;\n },\n };\n\n return (\n <StyledTagGroupContext.Provider value={contextValue}>\n <div\n id={local.id}\n class={rootClass()}\n style={local.UNSAFE_style ?? local.style}\n data-invalid={isInvalid() ? \"true\" : undefined}\n data-disabled={local.isDisabled ? \"true\" : undefined}\n >\n <Show when={local.label}>\n <div\n class={labelWrapper({\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n })}\n >\n <span\n id={labelId}\n class={resolveStyleClass(labelStyle, { size: size(), isDisabled: local.isDisabled })}\n >\n {local.label}\n </span>\n </div>\n </Show>\n\n <div\n class={tagListContainer({\n size: size(),\n isEmpty: local.items.length === 0,\n })}\n style={maxRowsStyle(local.maxRows, size())}\n >\n <HeadlessTagList\n {...listProps}\n items={local.items}\n getKey={local.getKey}\n onRemove={local.onRemove}\n selectionMode={local.selectionMode}\n selectionBehavior={local.selectionBehavior}\n selectedKeys={local.selectedKeys}\n defaultSelectedKeys={local.defaultSelectedKeys}\n onSelectionChange={local.onSelectionChange}\n disabledKeys={local.disabledKeys}\n isDisabled={local.isDisabled}\n aria-label={local[\"aria-label\"]}\n aria-labelledby={local.label ? labelId : local[\"aria-labelledby\"]}\n aria-describedby={describedBy()}\n class={(renderProps) =>\n resolveStyleClass(tagListStyle, {\n ...renderProps,\n size: size(),\n isDisabled: local.isDisabled,\n })\n }\n renderEmptyState={renderedEmptyState}\n >\n {renderItem}\n </HeadlessTagList>\n\n <Show when={hasItems() && local.groupActionLabel && local.onGroupAction}>\n <span class={resolveStyleClass(actionRowStyle, { size: size() })}>\n <ActionButton size={size()} isQuiet onPress={local.onGroupAction}>\n {local.groupActionLabel}\n </ActionButton>\n </span>\n </Show>\n </div>\n\n <Show when={local.description && !isInvalid()}>\n <p\n id={descriptionId}\n class={helpTextStyle({\n size: size(),\n isInvalid: false,\n isDisabled: local.isDisabled,\n })}\n >\n {local.description}\n </p>\n </Show>\n\n <Show when={local.errorMessage && isInvalid()}>\n <p\n id={errorId}\n class={helpTextStyle({\n size: size(),\n isInvalid: true,\n isDisabled: local.isDisabled,\n })}\n >\n <AlertTriangleIcon styles={errorIconStyle} size={size()} aria-hidden=\"true\" />\n {local.errorMessage}\n </p>\n </Show>\n </div>\n </StyledTagGroupContext.Provider>\n );\n}\n\nexport type { Key, SelectionBehavior, SelectionMode };\n"],"mappings":";;;;;;;;;;;;;;AAmHA,MAAa,kBAAkB,cAAwD,IAAA;AAoBvF,MAAM,wBAAwB,cAAc;AAE5C,MAAM,eAAA,SAAA,UAAA,OAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgBN,MAAM,eAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;AAqBN,MAAM,aAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIN,MAAM,mBAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;AAcN,MAAM,eAA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AAA,KAAA;IAAA,GAAA,KAAA;GAAA,CAAA;GAAA,OAAA;EAAA;CAAA,CAAA;AAmE7C"}
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../src/tag-group/index.tsx"],"sourcesContent":["// @ts-nocheck\nimport {\n type JSX,\n children as resolveChildren,\n createContext,\n createUniqueId,\n mergeProps,\n splitProps,\n useContext,\n Show,\n} from \"solid-js\";\nimport { isServer } from \"solid-js/web\";\nimport { getSlottedContextProps, type SpectrumContextValue } from \"../button/spectrum-context\";\nimport {\n TagList as HeadlessTagList,\n Tag as HeadlessTag,\n TagRemoveButton as HeadlessTagRemoveButton,\n type TagListProps as HeadlessTagListProps,\n type TagRenderProps,\n type TagProps as HeadlessTagProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport type { Key, SelectionBehavior, SelectionMode } from \"@proyecto-viviana/solid-stately\";\nimport type { StyleString } from \"../style\";\nimport { baseColor, focusRing, lightDark, style } from \"../style\" with { type: \"macro\" };\nimport {\n control,\n controlFont,\n field,\n fieldInput,\n fieldLabel,\n getAllowedOverrides,\n} from \"../s2-internal/style-utils\" with { type: \"macro\" };\nimport { useProviderProps } from \"../provider\";\nimport { pressScale } from \"../pressScale\";\nimport AlertTriangleIcon from \"../icon/s2wf-icons/AlertTriangleIcon\";\nimport { CrossIcon } from \"../icon/ui-icons/Cross\";\nimport { ActionButton } from \"../button/ActionButton\";\n\nexport type TagGroupSize = \"S\" | \"M\" | \"L\" | \"sm\" | \"md\" | \"lg\";\ntype S2TagGroupSize = \"S\" | \"M\" | \"L\";\nexport type TagGroupVariant = \"default\" | \"outline\" | \"solid\";\nexport type TagGroupLabelPosition = \"top\" | \"side\";\nexport type TagGroupLabelAlign = \"start\" | \"end\";\n\nexport interface TagGroupProps<T extends { id?: Key; key?: Key }> extends Omit<\n HeadlessTagListProps<T>,\n \"class\" | \"style\" | \"children\" | \"label\"\n> {\n /** The label for the tag group. */\n label?: JSX.Element;\n /** Function to render each tag or each tag's content. */\n children: (item: T) => JSX.Element;\n /** S2 tag size. Legacy sm/md/lg aliases map to S/M/L. @default 'M' */\n size?: TagGroupSize;\n /** Legacy visual variant. Prefer `isEmphasized` for S2 parity. */\n variant?: TagGroupVariant;\n /** Whether selected tags use the emphasized accent fill. */\n isEmphasized?: boolean;\n /** Description text shown below the tag list. */\n description?: JSX.Element;\n /** Error message shown when invalid. */\n errorMessage?: JSX.Element;\n /** Whether the group is invalid. */\n isInvalid?: boolean;\n /** Position of the label relative to the tag list. */\n labelPosition?: TagGroupLabelPosition;\n /** Text alignment for side labels. */\n labelAlign?: TagGroupLabelAlign;\n /** Label for the optional group action button. */\n groupActionLabel?: string;\n /** Handler for the optional group action button. */\n onGroupAction?: () => void;\n /** Maximum visible rows. This is approximated with overflow clipping in Solid. */\n maxRows?: number;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n /** Backward-compatible class alias. Prefer UNSAFE_className for S2 parity. */\n class?: string;\n /** Backward-compatible inline style alias. Prefer UNSAFE_style for S2 parity. */\n style?: JSX.CSSProperties;\n /** Handler called when a tag is activated. */\n onAction?: (key: Key) => void;\n}\n\nexport interface TagProps extends Omit<HeadlessTagProps, \"class\" | \"style\" | \"children\"> {\n /** The content of the tag. */\n children?: JSX.Element;\n /** Whether selected tags use the emphasized accent fill. Inherited from TagGroup. */\n isEmphasized?: boolean;\n /** S2 tag size. Inherited from TagGroup. */\n size?: TagGroupSize;\n /** Href retained for API parity; rendered as a tag action in the current Solid primitive. */\n href?: string;\n /** Link target retained for API parity. */\n target?: string;\n /** Link relationship retained for API parity. */\n rel?: string;\n /** Handler called when this tag is activated. */\n onAction?: (key: Key) => void;\n /** Additional CSS class name. Use only as a last resort. */\n class?: string;\n /** Additional inline styles. Use only as a last resort. */\n style?: JSX.CSSProperties;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n}\n\nexport const TagGroupContext = createContext<SpectrumContextValue<TagGroupProps<any>>>(null);\n\ninterface TagGroupContextValue {\n size: S2TagGroupSize;\n isEmphasized: boolean;\n onAction?: (key: Key) => void;\n}\n\ninterface TagGroupStyleProps extends TagRenderProps {\n size?: S2TagGroupSize;\n labelPosition?: TagGroupLabelPosition;\n labelAlign?: TagGroupLabelAlign;\n isEmphasized?: boolean;\n isInvalid?: boolean;\n isLink?: boolean;\n isEmpty?: boolean;\n isDisabled?: boolean;\n allowsRemoving?: boolean;\n}\n\nconst StyledTagGroupContext = createContext<TagGroupContextValue>();\n\nconst tagGroupRoot = style<TagGroupStyleProps>(\n {\n ...field(),\n font: controlFont(),\n color: {\n default: baseColor(\"neutral\"),\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isDisabled: \"GrayText\",\n },\n },\n },\n getAllowedOverrides(),\n);\n\nconst labelWrapper = style<TagGroupStyleProps>({\n gridArea: \"label\",\n display: \"inline\",\n textAlign: {\n labelAlign: {\n start: \"start\",\n end: \"end\",\n },\n },\n paddingBottom: {\n labelPosition: {\n top: \"--field-gap\",\n },\n },\n contain: {\n labelPosition: {\n top: \"inline-size\",\n },\n },\n});\n\nconst labelStyle = style({\n ...fieldLabel(),\n});\n\nconst tagListContainer = style<TagGroupStyleProps>({\n gridArea: \"input\",\n minWidth: \"full\",\n marginStart: {\n default: -4,\n isEmpty: 0,\n },\n marginEnd: {\n default: 4,\n isEmpty: 0,\n },\n position: \"relative\",\n});\n\nconst tagListStyle = style({\n ...fieldInput(),\n display: \"inline\",\n minWidth: \"full\",\n // S2's real `<TagList>` sets a FIXED `font: 'ui'` (14px) on the grid container —\n // NOT the size-conditional `controlFont()`. The tags scale their own font via\n // `control()`; the grid's font is a static default (D1 grid font-size diverges at\n // size S/L when this ramps).\n font: \"ui\",\n outlineStyle: \"none\",\n});\n\nconst tagStyle = style<TagGroupStyleProps>({\n ...focusRing(),\n ...control({ shape: \"default\", icon: true, register: \"chip\" }),\n display: \"inline-flex\",\n maxWidth: \"full\",\n verticalAlign: \"middle\",\n justifyContent: \"center\",\n transition: \"default\",\n /* The muted chip is a WELL, not a gray step. All three of the handoff's unselected\n * chips are drawn `background: var(--surface-well)` inside `--well-border`\n * (TerminalGlassLab.tsx:35-55) — the same matte surface as a terminal well, which is\n * why `control({register:\"chip\"})` above already hands them the well's border. The\n * fill was the last part still coming off the ramp, and `gray-100` is opaque on both\n * columns (#e5eaf1 / #43474d), so the chips read as flat grey plates on a page whose\n * every other surface is glass or well: 10 elements in dark, 10 in light.\n *\n * Hover has no drawn counterpart — the handoff's chips are static — so it takes\n * `surface-hover`, the register's one hover surface, rather than a second ramp step. */\n backgroundColor: {\n default: \"well\",\n isHovered: {\n default: \"surface-hover\",\n },\n isFocusVisible: {\n default: \"surface-hover\",\n },\n isSelected: {\n default: baseColor(\"neutral\"),\n isEmphasized: {\n default: \"interactive-fill\",\n isHovered: lightDark(\"accent-1000\", \"accent-600\"),\n isPressed: lightDark(\"accent-1000\", \"accent-600\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-600\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonFace\",\n isSelected: \"Highlight\",\n },\n },\n /* ...and the well's dither with it. The handoff sets `scan: true` on exactly the three\n * well-filled chips and `scan: false` on the selected one (TerminalGlassLab.tsx:33, :40),\n * so the texture follows the fill: a chip that stops being a well stops being dithered.\n *\n * The gradient is `wellScan()`'s literal, restated rather than spread because that helper\n * emits an unconditional `backgroundImage` and this needs the `isSelected` branch —\n * spreading it and re-declaring the key in the same object is the duplicate-key trap.\n * `wellScan()` remains the source of the value; if it moves, this moves with it. */\n backgroundImage: {\n default: \"[repeating-conic-gradient(var(--well-scan) 0% 25%, transparent 0% 50%)]\",\n isSelected: \"none\",\n forcedColors: \"none\",\n },\n backgroundSize: \"[4px 4px]\",\n color: {\n default: baseColor(\"neutral\"),\n isSelected: {\n default: \"gray-25\",\n isEmphasized: \"white\",\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isSelected: \"HighlightText\",\n isDisabled: \"GrayText\",\n },\n },\n /* The chip's 1px edge arrives with `control({register: \"chip\"})` above, which sets\n * `borderWidth: 1`, `borderStyle: \"solid\"` and a resting `borderColor: \"well-border\"`\n * (s2-internal/style-utils.ts). This slot previously held `borderStyle: \"none\"`, and\n * because a literal key REPLACES the spread's value for that property, it cancelled the\n * register's edge outright — the chip drew no border at all. Only the state colours\n * belong here now; the width and style come from the register.\n *\n * A `default` stop is mandatory, not redundant with the spread: declaring `borderColor`\n * as a literal key discards the register's `well-border` for every state this map does\n * not name, and an unnamed state would fall back to `currentColor` (the tag's text).\n *\n * The stops mirror the `backgroundColor` map above so a selected chip's edge matches its\n * own fill rather than outlining it in the muted well colour.\n *\n * `gray-800` here is deliberate and must not be \"corrected\" to `baseColor(\"neutral\")` for\n * symmetry with the fill above: the theme's `borderColor` map (style/spectrum-theme.ts)\n * exposes `...baseColors` plus `negative`, `disabled` and the three edge tokens, but no\n * `neutral` — that key exists only on the `color`, `backgroundColor` and `fill` maps, so\n * `neutral` throws `Invalid color neutral` at macro build time. This file is `@ts-nocheck`,\n * so that surfaces as a build crash rather than a type error. The substitution is exact,\n * not approximate: `neutral` on `backgroundColor` is `neutral-background-color-default`,\n * which is a token `ref` to `{gray-800}`, and `nextColorStop` recurses through refs — so\n * both spellings resolve to the same stop and both step to gray-900 on hover/press. */\n borderColor: {\n default: \"well-border\",\n isSelected: {\n default: baseColor(\"gray-800\"),\n isEmphasized: {\n default: \"interactive-fill\",\n isHovered: lightDark(\"accent-1000\", \"accent-600\"),\n isPressed: lightDark(\"accent-1000\", \"accent-600\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-600\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonBorder\",\n isSelected: \"Highlight\",\n isDisabled: \"GrayText\",\n },\n },\n paddingEnd: {\n default: \"edge-to-text\",\n allowsRemoving: 0,\n },\n margin: 4,\n cursor: {\n default: \"default\",\n isLink: \"pointer\",\n isDisabled: \"default\",\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\n// S2's TagWrapper CONTENT DIV (a sibling of the ClearButton at the tag-row flex\n// level). It carries NO `order`, so it keeps DOM order (content before the remove\n// button). The `order`/`truncate` belong on the inner Text (`tagTextStyle`), NOT\n// here — putting them on the row-level element sorts the label AFTER the\n// `order: 0` remove button (`× Landscape` instead of `Landscape ×`).\nconst tagContentStyle = style({\n display: \"flex\",\n minWidth: 0,\n alignItems: \"center\",\n gap: \"text-to-visual\",\n forcedColorAdjust: \"none\",\n backgroundColor: \"transparent\",\n});\n\n// S2's `TextContext` styles inside the content div: `{order: 1, truncate: true}`\n// (icon slots take `order: 0`, so the icon precedes the text regardless of DOM\n// order). Scoped to the inner text — see `tagContentStyle`.\nconst tagTextStyle = style({\n order: 1,\n truncate: true,\n});\n\n// Captured so the `outlineColor` static-color branch can reuse the focus ring's own\n// default (mirrors S2 `const focusRingStyles = focusRing()`).\nconst removeButtonFocusRing = focusRing();\n\nconst removeButtonStyle = style<TagGroupStyleProps>({\n ...removeButtonFocusRing,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n // Mirror S2 ClearButton (`visibleClearButton`): fill the tag height and width to\n // the control-size ramp (`controlSize()` = {S: 24, M: 32, L: 40}). The port's\n // local `controlSize` helper has a different meaning, so the ramp is inlined.\n height: \"full\",\n width: {\n size: {\n S: 24,\n M: 32,\n L: 40,\n },\n },\n flexShrink: 0,\n borderRadius: \"full\",\n borderStyle: \"none\",\n backgroundColor: \"transparent\",\n color: \"inherit\",\n boxSizing: \"border-box\",\n padding: 0,\n outlineOffset: -4,\n // Mirror S2 `visibleClearButton`: a static-color (emphasized + selected) tag uses\n // a white focus outline against its accent fill; every other tag uses the default\n // focus-ring colour. `isStaticColor` = `isEmphasized && isSelected` (threaded in\n // by the TagWrapper — here at the render site).\n outlineColor: {\n default: removeButtonFocusRing.outlineColor,\n isStaticColor: \"white\",\n },\n // S2 `visibleClearButton` sets NO cursor — the native `<button>` UA cursor\n // (`default`) stands. Do NOT re-add the arrow→`pointer` override (an invented\n // divergence: D1 pins React's native `default`).\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\nconst helpTextStyle = style<TagGroupStyleProps>({\n gridArea: \"helptext\",\n display: \"flex\",\n margin: 0,\n alignItems: \"baseline\",\n gap: \"text-to-visual\",\n font: controlFont(),\n color: {\n default: \"neutral-subdued\",\n isInvalid: {\n default: \"negative\",\n forcedColors: \"Mark\",\n },\n isDisabled: {\n default: \"disabled\",\n forcedColors: \"GrayText\",\n },\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n contain: \"inline-size\",\n paddingTop: \"--field-gap\",\n});\n\nconst emptyStateStyle = style({\n color: \"neutral-subdued\",\n font: controlFont(),\n});\n\nconst actionRowStyle = style({\n display: \"inline-flex\",\n verticalAlign: \"middle\",\n margin: 4,\n gap: 4,\n});\n\nconst errorIconStyle = style({\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n flexShrink: 0,\n});\n\nfunction normalizeSize(size: TagGroupSize | undefined): S2TagGroupSize {\n switch (size) {\n case \"sm\":\n return \"S\";\n case \"md\":\n return \"M\";\n case \"lg\":\n return \"L\";\n case \"S\":\n case \"M\":\n case \"L\":\n return size;\n default:\n return \"M\";\n }\n}\n\nfunction getItemKey<T extends { id?: Key; key?: Key }>(item: T, getKey?: (item: T) => Key): Key {\n if (getKey) return getKey(item);\n if (item.id !== undefined) return item.id;\n if (item.key !== undefined) return item.key;\n return String(item);\n}\n\nfunction hasKey(keys: Iterable<Key> | \"all\" | undefined, key: Key): boolean {\n if (keys == null) {\n return false;\n }\n\n if (keys === \"all\") {\n return true;\n }\n\n if (\"has\" in keys && typeof keys.has === \"function\") {\n return keys.has(key);\n }\n\n for (const value of keys) {\n if (value === key) {\n return true;\n }\n }\n\n return false;\n}\n\n// Matches a `role=\"row\"` attribute in a serialized SSR node's markup, mirroring the client-side\n// `getAttribute(\"role\") === \"row\"` check below.\nconst SSR_TAG_ROW_PATTERN = /\\srole=\"row\"[\\s>]/;\n// Matches the `solidaria-Tag` token inside a `class=\"...\"` attribute, mirroring the client-side\n// `classList.contains(\"solidaria-Tag\")` check below.\nconst SSR_TAG_CLASS_PATTERN = /\\sclass=\"[^\"]*\\bsolidaria-Tag\\b[^\"]*\"/;\n\nfunction isRenderedTag(value: JSX.Element): boolean {\n if (Array.isArray(value)) {\n return value.length === 1 && isRenderedTag(value[0]);\n }\n\n if (isServer) {\n // During renderToString, resolved children are Solid's server-side SSR node objects\n // (`{ t: string }` holding the serialized HTML), not HTMLElement instances — `HTMLElement`\n // isn't even a global in Node. Duck-type the same \"already a rendered Tag row\" signal the\n // client checks for (a `role=\"row\"` gridcell wrapper carrying the Tag class) by inspecting\n // the markup string directly, so the wrap/no-wrap decision matches what the client will\n // compute once `HTMLElement` is real and hydration can walk a matching tree.\n const markup = (value as { t?: unknown } | null | undefined)?.t;\n if (typeof markup !== \"string\") {\n return false;\n }\n return SSR_TAG_ROW_PATTERN.test(markup) || SSR_TAG_CLASS_PATTERN.test(markup);\n }\n\n if (typeof HTMLElement === \"undefined\" || !(value instanceof HTMLElement)) {\n return false;\n }\n return value.getAttribute(\"role\") === \"row\" || value.classList.contains(\"solidaria-Tag\");\n}\n\nfunction joinIds(...ids: Array<string | undefined | false>) {\n return ids.filter(Boolean).join(\" \") || undefined;\n}\n\nfunction maxRowsStyle(\n maxRows: number | undefined,\n size: S2TagGroupSize,\n): JSX.CSSProperties | undefined {\n if (maxRows == null || maxRows <= 0) {\n return undefined;\n }\n\n const rowHeight = size === \"L\" ? 44 : size === \"S\" ? 30 : 36;\n return {\n \"max-height\": `${rowHeight * maxRows}px`,\n overflow: \"hidden\",\n };\n}\n\nfunction resolveStyleClass<P extends Record<string, unknown>>(\n styleValue: StyleString | ((props: P) => StyleString),\n props: P,\n): string {\n return typeof styleValue === \"function\" ? styleValue(props) : styleValue;\n}\n\n/**\n * An individual Tag for TagGroups.\n */\nexport function Tag(props: TagProps): JSX.Element {\n const ctx = useContext(StyledTagGroupContext);\n const [local, tagProps] = splitProps(props, [\n \"class\",\n \"style\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"children\",\n \"id\",\n \"isDisabled\",\n \"isEmphasized\",\n \"size\",\n \"href\",\n \"target\",\n \"rel\",\n \"onAction\",\n \"textValue\",\n ]);\n\n // Mirror S2 Tag: derive the row's accessible text from string children when no\n // explicit textValue is given. This names the row (and cascades to the remove\n // button's `aria-labelledby` and the gridcell's name-from-contents), matching\n // how S2 auto-derives `node.textValue` from string children.\n const textValue = () =>\n local.textValue ?? (typeof local.children === \"string\" ? local.children : undefined);\n const size = () => normalizeSize(local.size ?? ctx?.size);\n const isEmphasized = () => local.isEmphasized ?? ctx?.isEmphasized ?? false;\n const isLink = () => local.href != null;\n const actionHandler = () => local.onAction ?? ctx?.onAction;\n\n // Mirror S2 Tag: `ref={domRef} style={pressScale(domRef)}` — the layer hint\n // (`will-change: transform`) at rest, plus the press-scale transform on press.\n let tagEl: HTMLDivElement | undefined;\n const rowStyle = (renderProps: TagRenderProps): JSX.CSSProperties =>\n pressScale(() => tagEl, local.UNSAFE_style ?? local.style)(renderProps);\n\n // Mirror S2 ClearButton: `<Button style={pressScale(domRef)}>` — pressScale\n // ALWAYS contributes the `will-change: transform` layer hint. The plain headless\n // remove button carries no press state yet, so only the resting hint is mirrored\n // here; the on-press scale lands with the CP9.44b interaction pass\n // (tech-debt `taggroup-remove-pressscale`).\n const removeButtonRestStyle = pressScale(undefined)({ isPressed: false });\n\n const className = (renderProps: TagRenderProps) =>\n [\n local.UNSAFE_className,\n local.class,\n tagStyle(\n {\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n isLink: isLink(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <HeadlessTag\n {...tagProps}\n id={local.id}\n isDisabled={local.isDisabled}\n textValue={textValue()}\n class={className}\n ref={(el: HTMLDivElement) => (tagEl = el)}\n style={rowStyle}\n data-href={local.href}\n data-target={local.target}\n data-rel={local.rel}\n onAction={() => actionHandler()?.(local.id)}\n >\n {(renderProps) => (\n <>\n <div class={resolveStyleClass(tagContentStyle, {})}>\n <span class={resolveStyleClass(tagTextStyle, {})}>{local.children}</span>\n </div>\n <Show when={renderProps.allowsRemoving}>\n <HeadlessTagRemoveButton\n buttonProps={renderProps.removeButtonProps}\n class={removeButtonStyle({\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n // S2 TagWrapper: `isStaticColor={isEmphasized && isSelected}`.\n isStaticColor: isEmphasized() && renderProps.isSelected,\n })}\n style={removeButtonRestStyle}\n >\n {/* S2 ClearButton renders `<CrossIcon size={props.size}/>` with the RAW\n control size — the ui-icon selects its own variant (S→Size75,\n M→Size100, L→Size200) and CSS width (S=M=8px, L=10px). Passing a\n down-mapped size renders the wrong Cross path variant. No\n `aria-hidden`: S2's ClearButton leaves the bare CrossIcon svg\n exposed (Chromium reports an unnamed `img` under the labelled\n remove button), so mirror that AX shape rather than hiding it. */}\n <CrossIcon size={size()} />\n </HeadlessTagRemoveButton>\n </Show>\n </>\n )}\n </HeadlessTag>\n );\n}\n\n/**\n * A tag group displays a collection of tags that can be selected and/or removed.\n */\nexport function TagGroup<T extends { id?: Key; key?: Key }>(props: TagGroupProps<T>): JSX.Element {\n const providerProps = useProviderProps(props);\n const contextProps = getSlottedContextProps(useContext(TagGroupContext), props.slot);\n const mergedProps = mergeProps(providerProps, contextProps ?? {}, props);\n const [local, listProps] = splitProps(mergedProps, [\n \"label\",\n \"items\",\n \"children\",\n \"getKey\",\n \"onRemove\",\n \"size\",\n \"variant\",\n \"isEmphasized\",\n \"description\",\n \"errorMessage\",\n \"isInvalid\",\n \"labelPosition\",\n \"labelAlign\",\n \"groupActionLabel\",\n \"onGroupAction\",\n \"maxRows\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"class\",\n \"style\",\n \"renderEmptyState\",\n \"selectionMode\",\n \"selectionBehavior\",\n \"selectedKeys\",\n \"defaultSelectedKeys\",\n \"onSelectionChange\",\n \"disabledKeys\",\n \"isDisabled\",\n \"onAction\",\n \"id\",\n \"aria-label\",\n \"aria-labelledby\",\n \"aria-describedby\",\n ]);\n\n const labelId = createUniqueId();\n const descriptionId = createUniqueId();\n const errorId = createUniqueId();\n const size = () => normalizeSize(local.size);\n const labelPosition = () => local.labelPosition ?? \"top\";\n const labelAlign = () => local.labelAlign ?? \"start\";\n const isInvalid = () => local.isInvalid === true;\n const isEmphasized = () => local.isEmphasized ?? local.variant === \"solid\";\n const hasItems = () => local.items.length > 0;\n const keyForItem = (item: T) => getItemKey(item, local.getKey);\n const renderedEmptyState = () => (\n <span class={resolveStyleClass(emptyStateStyle, { size: size() })}>\n {local.renderEmptyState?.() ?? \"No tags\"}\n </span>\n );\n\n const describedBy = () =>\n joinIds(\n local[\"aria-describedby\"],\n local.description && !isInvalid() ? descriptionId : undefined,\n local.errorMessage && isInvalid() ? errorId : undefined,\n );\n\n const rootClass = () =>\n [\n local.UNSAFE_className,\n local.class,\n tagGroupRoot(\n {\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n isDisabled: local.isDisabled,\n isInvalid: isInvalid(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n const renderItem = (item: T) => {\n const resolved = resolveChildren(() => local.children(item));\n const rendered = resolved();\n if (isRenderedTag(rendered)) {\n return rendered;\n }\n\n return (\n <Tag id={keyForItem(item)} isDisabled={hasKey(local.disabledKeys, keyForItem(item))}>\n {rendered}\n </Tag>\n );\n };\n\n const contextValue: TagGroupContextValue = {\n get size() {\n return size();\n },\n get isEmphasized() {\n return isEmphasized();\n },\n get onAction() {\n return local.onAction;\n },\n };\n\n return (\n <StyledTagGroupContext.Provider value={contextValue}>\n <div\n id={local.id}\n class={rootClass()}\n style={local.UNSAFE_style ?? local.style}\n data-invalid={isInvalid() ? \"true\" : undefined}\n data-disabled={local.isDisabled ? \"true\" : undefined}\n >\n <Show when={local.label}>\n <div\n class={labelWrapper({\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n })}\n >\n <span\n id={labelId}\n class={resolveStyleClass(labelStyle, { size: size(), isDisabled: local.isDisabled })}\n >\n {local.label}\n </span>\n </div>\n </Show>\n\n <div\n class={tagListContainer({\n size: size(),\n isEmpty: local.items.length === 0,\n })}\n style={maxRowsStyle(local.maxRows, size())}\n >\n <HeadlessTagList\n {...listProps}\n items={local.items}\n getKey={local.getKey}\n onRemove={local.onRemove}\n selectionMode={local.selectionMode}\n selectionBehavior={local.selectionBehavior}\n selectedKeys={local.selectedKeys}\n defaultSelectedKeys={local.defaultSelectedKeys}\n onSelectionChange={local.onSelectionChange}\n disabledKeys={local.disabledKeys}\n isDisabled={local.isDisabled}\n aria-label={local[\"aria-label\"]}\n aria-labelledby={local.label ? labelId : local[\"aria-labelledby\"]}\n aria-describedby={describedBy()}\n class={(renderProps) =>\n resolveStyleClass(tagListStyle, {\n ...renderProps,\n size: size(),\n isDisabled: local.isDisabled,\n })\n }\n renderEmptyState={renderedEmptyState}\n >\n {renderItem}\n </HeadlessTagList>\n\n <Show when={hasItems() && local.groupActionLabel && local.onGroupAction}>\n <span class={resolveStyleClass(actionRowStyle, { size: size() })}>\n <ActionButton size={size()} isQuiet onPress={local.onGroupAction}>\n {local.groupActionLabel}\n </ActionButton>\n </span>\n </Show>\n </div>\n\n <Show when={local.description && !isInvalid()}>\n <p\n id={descriptionId}\n class={helpTextStyle({\n size: size(),\n isInvalid: false,\n isDisabled: local.isDisabled,\n })}\n >\n {local.description}\n </p>\n </Show>\n\n <Show when={local.errorMessage && isInvalid()}>\n <p\n id={errorId}\n class={helpTextStyle({\n size: size(),\n isInvalid: true,\n isDisabled: local.isDisabled,\n })}\n >\n <AlertTriangleIcon styles={errorIconStyle} size={size()} aria-hidden=\"true\" />\n {local.errorMessage}\n </p>\n </Show>\n </div>\n </StyledTagGroupContext.Provider>\n );\n}\n\nexport type { Key, SelectionBehavior, SelectionMode };\n"],"mappings":";;;;;;;;;;;;;;AAmHA,MAAa,kBAAkB,cAAwD,IAAA;AAoBvF,MAAM,wBAAwB,cAAc;AAE5C,MAAM,eAAA,SAAA,UAAA,OAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgBN,MAAM,eAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;AAqBN,MAAM,aAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIN,MAAM,mBAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;AAcN,MAAM,eAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;AAYN,MAAM,WAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkIN,MAAM,kBAAA;AAYN,MAAM,eAAA;AASN,MAAM,oBAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyCN,MAAM,gBAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BN,MAAM,kBAAA,SAAA,UA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M,OAAK,OAC1B,UAAA,IAAc,SAAS,KAAA,GAAA,OACtB,MAAM,aAAa,SAAS,KAAA,GAAA,OAoBlC,iBAAiB;KACtB,MAAM,KAAA;KACN,SAAS,MAAM,MAAM,WAAW;IAClC,CAAA,GAAA,OACO,aAAa,MAAM,SAAS,KAAA,CAAA;IAAA,SAAA,IAAA,KAAA,aAAA,OAAA,MAAA,IAAA,IAAA,IAAA;IAAA,SAAA,IAAA,KAAA,UAAA,OAAA,IAAA,IAAA,IAAA;IAAA,IAAA,IAAA,MAAA,OAAA,MAAA,IAAA,CAAA;IAAA,SAAA,IAAA,KAAA,aAAA,OAAA,gBAAA,IAAA,IAAA,IAAA;IAAA,SAAA,IAAA,KAAA,aAAA,OAAA,iBAAA,IAAA,IAAA,IAAA;IAAA,SAAA,IAAA,KAAA,UAAA,OAAA,IAAA,IAAA,IAAA;IAAA,IAAA,IAAA,MAAA,OAAA,MAAA,IAAA,CAAA;IAAA,OAAA;GAAA,GAAA;IAAA,GAAA,KAAA;IAAA,GAAA,KAAA;IAAA,GAAA,KAAA;IAAA,GAAA,KAAA;IAAA,GAAA,KAAA;IAAA,GAAA,KAAA;IAAA,GAAA,KAAA;GAAA,CAAA;GAAA,OAAA;EAAA;CAAA,CAAA;AAmE7C"}
|
package/dist/tag-group/index.jsx
CHANGED
|
@@ -173,7 +173,7 @@ const labelStyle = function anonymous(props) {
|
|
|
173
173
|
}
|
|
174
174
|
if (props.isStaticColor) rules += " pl151";
|
|
175
175
|
else if (props.isDisabled) rules += " pUvnvv151";
|
|
176
|
-
else rules += "
|
|
176
|
+
else rules += " pWQ7V3d151";
|
|
177
177
|
rules += " plb151";
|
|
178
178
|
rules += " ri151";
|
|
179
179
|
return rules;
|
|
@@ -296,10 +296,10 @@ const tagStyle = function anonymous(props) {
|
|
|
296
296
|
rules += " lb151";
|
|
297
297
|
rules += " _jf151";
|
|
298
298
|
if (props.isDisabled) rules += " ifbAdGe151";
|
|
299
|
-
else if (props.isSelected) if (props.isEmphasized) if (props.isFocusVisible) rules += "
|
|
300
|
-
else if (props.isPressed) rules += "
|
|
301
|
-
else if (props.isHovered) rules += "
|
|
302
|
-
else rules += "
|
|
299
|
+
else if (props.isSelected) if (props.isEmphasized) if (props.isFocusVisible) rules += " iKDgA3151";
|
|
300
|
+
else if (props.isPressed) rules += " iKDgA3151";
|
|
301
|
+
else if (props.isHovered) rules += " iKDgA3151";
|
|
302
|
+
else rules += " inhAeB151";
|
|
303
303
|
else if (props.isPressed) rules += " iMwyHo151";
|
|
304
304
|
else if (props.isFocusVisible) rules += " iMwyHo151";
|
|
305
305
|
else if (props.isHovered) rules += " iMwyHo151";
|
|
@@ -320,10 +320,10 @@ const tagStyle = function anonymous(props) {
|
|
|
320
320
|
rules += " Xb151";
|
|
321
321
|
rules += " _2b151";
|
|
322
322
|
if (props.isDisabled) rules += " gkDWoNd151";
|
|
323
|
-
else if (props.isSelected) if (props.isEmphasized) if (props.isFocusVisible) rules += "
|
|
324
|
-
else if (props.isPressed) rules += "
|
|
325
|
-
else if (props.isHovered) rules += "
|
|
326
|
-
else rules += "
|
|
323
|
+
else if (props.isSelected) if (props.isEmphasized) if (props.isFocusVisible) rules += " gKDgA3151";
|
|
324
|
+
else if (props.isPressed) rules += " gKDgA3151";
|
|
325
|
+
else if (props.isHovered) rules += " gKDgA3151";
|
|
326
|
+
else rules += " gnhAeB151";
|
|
327
327
|
else if (props.isPressed) rules += " gMwyHo151";
|
|
328
328
|
else if (props.isFocusVisible) rules += " gMwyHo151";
|
|
329
329
|
else if (props.isHovered) rules += " gMwyHo151";
|
|
@@ -463,7 +463,7 @@ const helpTextStyle = function anonymous(props) {
|
|
|
463
463
|
} else if (props.isInvalid) {
|
|
464
464
|
rules += " pYjUhNc151";
|
|
465
465
|
rules += " plQBRyrc151";
|
|
466
|
-
} else rules += "
|
|
466
|
+
} else rules += " pWQ7V3d151";
|
|
467
467
|
rules += " -_8sjo0b-t5ZbAob151";
|
|
468
468
|
rules += " _qb151";
|
|
469
469
|
rules += " TgOnRt151";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.jsx","names":[],"sources":["../../src/tag-group/index.tsx"],"sourcesContent":["// @ts-nocheck\nimport {\n type JSX,\n children as resolveChildren,\n createContext,\n createUniqueId,\n mergeProps,\n splitProps,\n useContext,\n Show,\n} from \"solid-js\";\nimport { isServer } from \"solid-js/web\";\nimport { getSlottedContextProps, type SpectrumContextValue } from \"../button/spectrum-context\";\nimport {\n TagList as HeadlessTagList,\n Tag as HeadlessTag,\n TagRemoveButton as HeadlessTagRemoveButton,\n type TagListProps as HeadlessTagListProps,\n type TagRenderProps,\n type TagProps as HeadlessTagProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport type { Key, SelectionBehavior, SelectionMode } from \"@proyecto-viviana/solid-stately\";\nimport type { StyleString } from \"../style\";\nimport { baseColor, focusRing, lightDark, style } from \"../style\" with { type: \"macro\" };\nimport {\n control,\n controlFont,\n field,\n fieldInput,\n fieldLabel,\n getAllowedOverrides,\n} from \"../s2-internal/style-utils\" with { type: \"macro\" };\nimport { useProviderProps } from \"../provider\";\nimport { pressScale } from \"../pressScale\";\nimport AlertTriangleIcon from \"../icon/s2wf-icons/AlertTriangleIcon\";\nimport { CrossIcon } from \"../icon/ui-icons/Cross\";\nimport { ActionButton } from \"../button/ActionButton\";\n\nexport type TagGroupSize = \"S\" | \"M\" | \"L\" | \"sm\" | \"md\" | \"lg\";\ntype S2TagGroupSize = \"S\" | \"M\" | \"L\";\nexport type TagGroupVariant = \"default\" | \"outline\" | \"solid\";\nexport type TagGroupLabelPosition = \"top\" | \"side\";\nexport type TagGroupLabelAlign = \"start\" | \"end\";\n\nexport interface TagGroupProps<T extends { id?: Key; key?: Key }> extends Omit<\n HeadlessTagListProps<T>,\n \"class\" | \"style\" | \"children\" | \"label\"\n> {\n /** The label for the tag group. */\n label?: JSX.Element;\n /** Function to render each tag or each tag's content. */\n children: (item: T) => JSX.Element;\n /** S2 tag size. Legacy sm/md/lg aliases map to S/M/L. @default 'M' */\n size?: TagGroupSize;\n /** Legacy visual variant. Prefer `isEmphasized` for S2 parity. */\n variant?: TagGroupVariant;\n /** Whether selected tags use the emphasized accent fill. */\n isEmphasized?: boolean;\n /** Description text shown below the tag list. */\n description?: JSX.Element;\n /** Error message shown when invalid. */\n errorMessage?: JSX.Element;\n /** Whether the group is invalid. */\n isInvalid?: boolean;\n /** Position of the label relative to the tag list. */\n labelPosition?: TagGroupLabelPosition;\n /** Text alignment for side labels. */\n labelAlign?: TagGroupLabelAlign;\n /** Label for the optional group action button. */\n groupActionLabel?: string;\n /** Handler for the optional group action button. */\n onGroupAction?: () => void;\n /** Maximum visible rows. This is approximated with overflow clipping in Solid. */\n maxRows?: number;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n /** Backward-compatible class alias. Prefer UNSAFE_className for S2 parity. */\n class?: string;\n /** Backward-compatible inline style alias. Prefer UNSAFE_style for S2 parity. */\n style?: JSX.CSSProperties;\n /** Handler called when a tag is activated. */\n onAction?: (key: Key) => void;\n}\n\nexport interface TagProps extends Omit<HeadlessTagProps, \"class\" | \"style\" | \"children\"> {\n /** The content of the tag. */\n children?: JSX.Element;\n /** Whether selected tags use the emphasized accent fill. Inherited from TagGroup. */\n isEmphasized?: boolean;\n /** S2 tag size. Inherited from TagGroup. */\n size?: TagGroupSize;\n /** Href retained for API parity; rendered as a tag action in the current Solid primitive. */\n href?: string;\n /** Link target retained for API parity. */\n target?: string;\n /** Link relationship retained for API parity. */\n rel?: string;\n /** Handler called when this tag is activated. */\n onAction?: (key: Key) => void;\n /** Additional CSS class name. Use only as a last resort. */\n class?: string;\n /** Additional inline styles. Use only as a last resort. */\n style?: JSX.CSSProperties;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n}\n\nexport const TagGroupContext = createContext<SpectrumContextValue<TagGroupProps<any>>>(null);\n\ninterface TagGroupContextValue {\n size: S2TagGroupSize;\n isEmphasized: boolean;\n onAction?: (key: Key) => void;\n}\n\ninterface TagGroupStyleProps extends TagRenderProps {\n size?: S2TagGroupSize;\n labelPosition?: TagGroupLabelPosition;\n labelAlign?: TagGroupLabelAlign;\n isEmphasized?: boolean;\n isInvalid?: boolean;\n isLink?: boolean;\n isEmpty?: boolean;\n isDisabled?: boolean;\n allowsRemoving?: boolean;\n}\n\nconst StyledTagGroupContext = createContext<TagGroupContextValue>();\n\nconst tagGroupRoot = style<TagGroupStyleProps>(\n {\n ...field(),\n font: controlFont(),\n color: {\n default: baseColor(\"neutral\"),\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isDisabled: \"GrayText\",\n },\n },\n },\n getAllowedOverrides(),\n);\n\nconst labelWrapper = style<TagGroupStyleProps>({\n gridArea: \"label\",\n display: \"inline\",\n textAlign: {\n labelAlign: {\n start: \"start\",\n end: \"end\",\n },\n },\n paddingBottom: {\n labelPosition: {\n top: \"--field-gap\",\n },\n },\n contain: {\n labelPosition: {\n top: \"inline-size\",\n },\n },\n});\n\nconst labelStyle = style({\n ...fieldLabel(),\n});\n\nconst tagListContainer = style<TagGroupStyleProps>({\n gridArea: \"input\",\n minWidth: \"full\",\n marginStart: {\n default: -4,\n isEmpty: 0,\n },\n marginEnd: {\n default: 4,\n isEmpty: 0,\n },\n position: \"relative\",\n});\n\nconst tagListStyle = style({\n ...fieldInput(),\n display: \"inline\",\n minWidth: \"full\",\n // S2's real `<TagList>` sets a FIXED `font: 'ui'` (14px) on the grid container —\n // NOT the size-conditional `controlFont()`. The tags scale their own font via\n // `control()`; the grid's font is a static default (D1 grid font-size diverges at\n // size S/L when this ramps).\n font: \"ui\",\n outlineStyle: \"none\",\n});\n\nconst tagStyle = style<TagGroupStyleProps>({\n ...focusRing(),\n ...control({ shape: \"default\", icon: true, register: \"chip\" }),\n display: \"inline-flex\",\n maxWidth: \"full\",\n verticalAlign: \"middle\",\n justifyContent: \"center\",\n transition: \"default\",\n /* The muted chip is a WELL, not a gray step. All three of the handoff's unselected\n * chips are drawn `background: var(--surface-well)` inside `--well-border`\n * (TerminalGlassLab.tsx:35-55) — the same matte surface as a terminal well, which is\n * why `control({register:\"chip\"})` above already hands them the well's border. The\n * fill was the last part still coming off the ramp, and `gray-100` is opaque on both\n * columns (#e5eaf1 / #43474d), so the chips read as flat grey plates on a page whose\n * every other surface is glass or well: 10 elements in dark, 10 in light.\n *\n * Hover has no drawn counterpart — the handoff's chips are static — so it takes\n * `surface-hover`, the register's one hover surface, rather than a second ramp step. */\n backgroundColor: {\n default: \"well\",\n isHovered: {\n default: \"surface-hover\",\n },\n isFocusVisible: {\n default: \"surface-hover\",\n },\n isSelected: {\n default: baseColor(\"neutral\"),\n isEmphasized: {\n default: lightDark(\"accent-900\", \"accent-700\"),\n isHovered: lightDark(\"accent-1000\", \"accent-800\"),\n isPressed: lightDark(\"accent-1000\", \"accent-800\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-800\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonFace\",\n isSelected: \"Highlight\",\n },\n },\n /* ...and the well's dither with it. The handoff sets `scan: true` on exactly the three\n * well-filled chips and `scan: false` on the selected one (TerminalGlassLab.tsx:33, :40),\n * so the texture follows the fill: a chip that stops being a well stops being dithered.\n *\n * The gradient is `wellScan()`'s literal, restated rather than spread because that helper\n * emits an unconditional `backgroundImage` and this needs the `isSelected` branch —\n * spreading it and re-declaring the key in the same object is the duplicate-key trap.\n * `wellScan()` remains the source of the value; if it moves, this moves with it. */\n backgroundImage: {\n default: \"[repeating-conic-gradient(var(--well-scan) 0% 25%, transparent 0% 50%)]\",\n isSelected: \"none\",\n forcedColors: \"none\",\n },\n backgroundSize: \"[4px 4px]\",\n color: {\n default: baseColor(\"neutral\"),\n isSelected: {\n default: \"gray-25\",\n isEmphasized: \"white\",\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isSelected: \"HighlightText\",\n isDisabled: \"GrayText\",\n },\n },\n /* The chip's 1px edge arrives with `control({register: \"chip\"})` above, which sets\n * `borderWidth: 1`, `borderStyle: \"solid\"` and a resting `borderColor: \"well-border\"`\n * (s2-internal/style-utils.ts). This slot previously held `borderStyle: \"none\"`, and\n * because a literal key REPLACES the spread's value for that property, it cancelled the\n * register's edge outright — the chip drew no border at all. Only the state colours\n * belong here now; the width and style come from the register.\n *\n * A `default` stop is mandatory, not redundant with the spread: declaring `borderColor`\n * as a literal key discards the register's `well-border` for every state this map does\n * not name, and an unnamed state would fall back to `currentColor` (the tag's text).\n *\n * The stops mirror the `backgroundColor` map above so a selected chip's edge matches its\n * own fill rather than outlining it in the muted well colour.\n *\n * `gray-800` here is deliberate and must not be \"corrected\" to `baseColor(\"neutral\")` for\n * symmetry with the fill above: the theme's `borderColor` map (style/spectrum-theme.ts)\n * exposes `...baseColors` plus `negative`, `disabled` and the three edge tokens, but no\n * `neutral` — that key exists only on the `color`, `backgroundColor` and `fill` maps, so\n * `neutral` throws `Invalid color neutral` at macro build time. This file is `@ts-nocheck`,\n * so that surfaces as a build crash rather than a type error. The substitution is exact,\n * not approximate: `neutral` on `backgroundColor` is `neutral-background-color-default`,\n * which is a token `ref` to `{gray-800}`, and `nextColorStop` recurses through refs — so\n * both spellings resolve to the same stop and both step to gray-900 on hover/press. */\n borderColor: {\n default: \"well-border\",\n isSelected: {\n default: baseColor(\"gray-800\"),\n isEmphasized: {\n default: lightDark(\"accent-900\", \"accent-700\"),\n isHovered: lightDark(\"accent-1000\", \"accent-800\"),\n isPressed: lightDark(\"accent-1000\", \"accent-800\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-800\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonBorder\",\n isSelected: \"Highlight\",\n isDisabled: \"GrayText\",\n },\n },\n paddingEnd: {\n default: \"edge-to-text\",\n allowsRemoving: 0,\n },\n margin: 4,\n cursor: {\n default: \"default\",\n isLink: \"pointer\",\n isDisabled: \"default\",\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\n// S2's TagWrapper CONTENT DIV (a sibling of the ClearButton at the tag-row flex\n// level). It carries NO `order`, so it keeps DOM order (content before the remove\n// button). The `order`/`truncate` belong on the inner Text (`tagTextStyle`), NOT\n// here — putting them on the row-level element sorts the label AFTER the\n// `order: 0` remove button (`× Landscape` instead of `Landscape ×`).\nconst tagContentStyle = style({\n display: \"flex\",\n minWidth: 0,\n alignItems: \"center\",\n gap: \"text-to-visual\",\n forcedColorAdjust: \"none\",\n backgroundColor: \"transparent\",\n});\n\n// S2's `TextContext` styles inside the content div: `{order: 1, truncate: true}`\n// (icon slots take `order: 0`, so the icon precedes the text regardless of DOM\n// order). Scoped to the inner text — see `tagContentStyle`.\nconst tagTextStyle = style({\n order: 1,\n truncate: true,\n});\n\n// Captured so the `outlineColor` static-color branch can reuse the focus ring's own\n// default (mirrors S2 `const focusRingStyles = focusRing()`).\nconst removeButtonFocusRing = focusRing();\n\nconst removeButtonStyle = style<TagGroupStyleProps>({\n ...removeButtonFocusRing,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n // Mirror S2 ClearButton (`visibleClearButton`): fill the tag height and width to\n // the control-size ramp (`controlSize()` = {S: 24, M: 32, L: 40}). The port's\n // local `controlSize` helper has a different meaning, so the ramp is inlined.\n height: \"full\",\n width: {\n size: {\n S: 24,\n M: 32,\n L: 40,\n },\n },\n flexShrink: 0,\n borderRadius: \"full\",\n borderStyle: \"none\",\n backgroundColor: \"transparent\",\n color: \"inherit\",\n boxSizing: \"border-box\",\n padding: 0,\n outlineOffset: -4,\n // Mirror S2 `visibleClearButton`: a static-color (emphasized + selected) tag uses\n // a white focus outline against its accent fill; every other tag uses the default\n // focus-ring colour. `isStaticColor` = `isEmphasized && isSelected` (threaded in\n // by the TagWrapper — here at the render site).\n outlineColor: {\n default: removeButtonFocusRing.outlineColor,\n isStaticColor: \"white\",\n },\n // S2 `visibleClearButton` sets NO cursor — the native `<button>` UA cursor\n // (`default`) stands. Do NOT re-add the arrow→`pointer` override (an invented\n // divergence: D1 pins React's native `default`).\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\nconst helpTextStyle = style<TagGroupStyleProps>({\n gridArea: \"helptext\",\n display: \"flex\",\n margin: 0,\n alignItems: \"baseline\",\n gap: \"text-to-visual\",\n font: controlFont(),\n color: {\n default: \"neutral-subdued\",\n isInvalid: {\n default: \"negative\",\n forcedColors: \"Mark\",\n },\n isDisabled: {\n default: \"disabled\",\n forcedColors: \"GrayText\",\n },\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n contain: \"inline-size\",\n paddingTop: \"--field-gap\",\n});\n\nconst emptyStateStyle = style({\n color: \"neutral-subdued\",\n font: controlFont(),\n});\n\nconst actionRowStyle = style({\n display: \"inline-flex\",\n verticalAlign: \"middle\",\n margin: 4,\n gap: 4,\n});\n\nconst errorIconStyle = style({\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n flexShrink: 0,\n});\n\nfunction normalizeSize(size: TagGroupSize | undefined): S2TagGroupSize {\n switch (size) {\n case \"sm\":\n return \"S\";\n case \"md\":\n return \"M\";\n case \"lg\":\n return \"L\";\n case \"S\":\n case \"M\":\n case \"L\":\n return size;\n default:\n return \"M\";\n }\n}\n\nfunction getItemKey<T extends { id?: Key; key?: Key }>(item: T, getKey?: (item: T) => Key): Key {\n if (getKey) return getKey(item);\n if (item.id !== undefined) return item.id;\n if (item.key !== undefined) return item.key;\n return String(item);\n}\n\nfunction hasKey(keys: Iterable<Key> | \"all\" | undefined, key: Key): boolean {\n if (keys == null) {\n return false;\n }\n\n if (keys === \"all\") {\n return true;\n }\n\n if (\"has\" in keys && typeof keys.has === \"function\") {\n return keys.has(key);\n }\n\n for (const value of keys) {\n if (value === key) {\n return true;\n }\n }\n\n return false;\n}\n\n// Matches a `role=\"row\"` attribute in a serialized SSR node's markup, mirroring the client-side\n// `getAttribute(\"role\") === \"row\"` check below.\nconst SSR_TAG_ROW_PATTERN = /\\srole=\"row\"[\\s>]/;\n// Matches the `solidaria-Tag` token inside a `class=\"...\"` attribute, mirroring the client-side\n// `classList.contains(\"solidaria-Tag\")` check below.\nconst SSR_TAG_CLASS_PATTERN = /\\sclass=\"[^\"]*\\bsolidaria-Tag\\b[^\"]*\"/;\n\nfunction isRenderedTag(value: JSX.Element): boolean {\n if (Array.isArray(value)) {\n return value.length === 1 && isRenderedTag(value[0]);\n }\n\n if (isServer) {\n // During renderToString, resolved children are Solid's server-side SSR node objects\n // (`{ t: string }` holding the serialized HTML), not HTMLElement instances — `HTMLElement`\n // isn't even a global in Node. Duck-type the same \"already a rendered Tag row\" signal the\n // client checks for (a `role=\"row\"` gridcell wrapper carrying the Tag class) by inspecting\n // the markup string directly, so the wrap/no-wrap decision matches what the client will\n // compute once `HTMLElement` is real and hydration can walk a matching tree.\n const markup = (value as { t?: unknown } | null | undefined)?.t;\n if (typeof markup !== \"string\") {\n return false;\n }\n return SSR_TAG_ROW_PATTERN.test(markup) || SSR_TAG_CLASS_PATTERN.test(markup);\n }\n\n if (typeof HTMLElement === \"undefined\" || !(value instanceof HTMLElement)) {\n return false;\n }\n return value.getAttribute(\"role\") === \"row\" || value.classList.contains(\"solidaria-Tag\");\n}\n\nfunction joinIds(...ids: Array<string | undefined | false>) {\n return ids.filter(Boolean).join(\" \") || undefined;\n}\n\nfunction maxRowsStyle(\n maxRows: number | undefined,\n size: S2TagGroupSize,\n): JSX.CSSProperties | undefined {\n if (maxRows == null || maxRows <= 0) {\n return undefined;\n }\n\n const rowHeight = size === \"L\" ? 44 : size === \"S\" ? 30 : 36;\n return {\n \"max-height\": `${rowHeight * maxRows}px`,\n overflow: \"hidden\",\n };\n}\n\nfunction resolveStyleClass<P extends Record<string, unknown>>(\n styleValue: StyleString | ((props: P) => StyleString),\n props: P,\n): string {\n return typeof styleValue === \"function\" ? styleValue(props) : styleValue;\n}\n\n/**\n * An individual Tag for TagGroups.\n */\nexport function Tag(props: TagProps): JSX.Element {\n const ctx = useContext(StyledTagGroupContext);\n const [local, tagProps] = splitProps(props, [\n \"class\",\n \"style\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"children\",\n \"id\",\n \"isDisabled\",\n \"isEmphasized\",\n \"size\",\n \"href\",\n \"target\",\n \"rel\",\n \"onAction\",\n \"textValue\",\n ]);\n\n // Mirror S2 Tag: derive the row's accessible text from string children when no\n // explicit textValue is given. This names the row (and cascades to the remove\n // button's `aria-labelledby` and the gridcell's name-from-contents), matching\n // how S2 auto-derives `node.textValue` from string children.\n const textValue = () =>\n local.textValue ?? (typeof local.children === \"string\" ? local.children : undefined);\n const size = () => normalizeSize(local.size ?? ctx?.size);\n const isEmphasized = () => local.isEmphasized ?? ctx?.isEmphasized ?? false;\n const isLink = () => local.href != null;\n const actionHandler = () => local.onAction ?? ctx?.onAction;\n\n // Mirror S2 Tag: `ref={domRef} style={pressScale(domRef)}` — the layer hint\n // (`will-change: transform`) at rest, plus the press-scale transform on press.\n let tagEl: HTMLDivElement | undefined;\n const rowStyle = (renderProps: TagRenderProps): JSX.CSSProperties =>\n pressScale(() => tagEl, local.UNSAFE_style ?? local.style)(renderProps);\n\n // Mirror S2 ClearButton: `<Button style={pressScale(domRef)}>` — pressScale\n // ALWAYS contributes the `will-change: transform` layer hint. The plain headless\n // remove button carries no press state yet, so only the resting hint is mirrored\n // here; the on-press scale lands with the CP9.44b interaction pass\n // (tech-debt `taggroup-remove-pressscale`).\n const removeButtonRestStyle = pressScale(undefined)({ isPressed: false });\n\n const className = (renderProps: TagRenderProps) =>\n [\n local.UNSAFE_className,\n local.class,\n tagStyle(\n {\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n isLink: isLink(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <HeadlessTag\n {...tagProps}\n id={local.id}\n isDisabled={local.isDisabled}\n textValue={textValue()}\n class={className}\n ref={(el: HTMLDivElement) => (tagEl = el)}\n style={rowStyle}\n data-href={local.href}\n data-target={local.target}\n data-rel={local.rel}\n onAction={() => actionHandler()?.(local.id)}\n >\n {(renderProps) => (\n <>\n <div class={resolveStyleClass(tagContentStyle, {})}>\n <span class={resolveStyleClass(tagTextStyle, {})}>{local.children}</span>\n </div>\n <Show when={renderProps.allowsRemoving}>\n <HeadlessTagRemoveButton\n buttonProps={renderProps.removeButtonProps}\n class={removeButtonStyle({\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n // S2 TagWrapper: `isStaticColor={isEmphasized && isSelected}`.\n isStaticColor: isEmphasized() && renderProps.isSelected,\n })}\n style={removeButtonRestStyle}\n >\n {/* S2 ClearButton renders `<CrossIcon size={props.size}/>` with the RAW\n control size — the ui-icon selects its own variant (S→Size75,\n M→Size100, L→Size200) and CSS width (S=M=8px, L=10px). Passing a\n down-mapped size renders the wrong Cross path variant. No\n `aria-hidden`: S2's ClearButton leaves the bare CrossIcon svg\n exposed (Chromium reports an unnamed `img` under the labelled\n remove button), so mirror that AX shape rather than hiding it. */}\n <CrossIcon size={size()} />\n </HeadlessTagRemoveButton>\n </Show>\n </>\n )}\n </HeadlessTag>\n );\n}\n\n/**\n * A tag group displays a collection of tags that can be selected and/or removed.\n */\nexport function TagGroup<T extends { id?: Key; key?: Key }>(props: TagGroupProps<T>): JSX.Element {\n const providerProps = useProviderProps(props);\n const contextProps = getSlottedContextProps(useContext(TagGroupContext), props.slot);\n const mergedProps = mergeProps(providerProps, contextProps ?? {}, props);\n const [local, listProps] = splitProps(mergedProps, [\n \"label\",\n \"items\",\n \"children\",\n \"getKey\",\n \"onRemove\",\n \"size\",\n \"variant\",\n \"isEmphasized\",\n \"description\",\n \"errorMessage\",\n \"isInvalid\",\n \"labelPosition\",\n \"labelAlign\",\n \"groupActionLabel\",\n \"onGroupAction\",\n \"maxRows\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"class\",\n \"style\",\n \"renderEmptyState\",\n \"selectionMode\",\n \"selectionBehavior\",\n \"selectedKeys\",\n \"defaultSelectedKeys\",\n \"onSelectionChange\",\n \"disabledKeys\",\n \"isDisabled\",\n \"onAction\",\n \"id\",\n \"aria-label\",\n \"aria-labelledby\",\n \"aria-describedby\",\n ]);\n\n const labelId = createUniqueId();\n const descriptionId = createUniqueId();\n const errorId = createUniqueId();\n const size = () => normalizeSize(local.size);\n const labelPosition = () => local.labelPosition ?? \"top\";\n const labelAlign = () => local.labelAlign ?? \"start\";\n const isInvalid = () => local.isInvalid === true;\n const isEmphasized = () => local.isEmphasized ?? local.variant === \"solid\";\n const hasItems = () => local.items.length > 0;\n const keyForItem = (item: T) => getItemKey(item, local.getKey);\n const renderedEmptyState = () => (\n <span class={resolveStyleClass(emptyStateStyle, { size: size() })}>\n {local.renderEmptyState?.() ?? \"No tags\"}\n </span>\n );\n\n const describedBy = () =>\n joinIds(\n local[\"aria-describedby\"],\n local.description && !isInvalid() ? descriptionId : undefined,\n local.errorMessage && isInvalid() ? errorId : undefined,\n );\n\n const rootClass = () =>\n [\n local.UNSAFE_className,\n local.class,\n tagGroupRoot(\n {\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n isDisabled: local.isDisabled,\n isInvalid: isInvalid(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n const renderItem = (item: T) => {\n const resolved = resolveChildren(() => local.children(item));\n const rendered = resolved();\n if (isRenderedTag(rendered)) {\n return rendered;\n }\n\n return (\n <Tag id={keyForItem(item)} isDisabled={hasKey(local.disabledKeys, keyForItem(item))}>\n {rendered}\n </Tag>\n );\n };\n\n const contextValue: TagGroupContextValue = {\n get size() {\n return size();\n },\n get isEmphasized() {\n return isEmphasized();\n },\n get onAction() {\n return local.onAction;\n },\n };\n\n return (\n <StyledTagGroupContext.Provider value={contextValue}>\n <div\n id={local.id}\n class={rootClass()}\n style={local.UNSAFE_style ?? local.style}\n data-invalid={isInvalid() ? \"true\" : undefined}\n data-disabled={local.isDisabled ? \"true\" : undefined}\n >\n <Show when={local.label}>\n <div\n class={labelWrapper({\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n })}\n >\n <span\n id={labelId}\n class={resolveStyleClass(labelStyle, { size: size(), isDisabled: local.isDisabled })}\n >\n {local.label}\n </span>\n </div>\n </Show>\n\n <div\n class={tagListContainer({\n size: size(),\n isEmpty: local.items.length === 0,\n })}\n style={maxRowsStyle(local.maxRows, size())}\n >\n <HeadlessTagList\n {...listProps}\n items={local.items}\n getKey={local.getKey}\n onRemove={local.onRemove}\n selectionMode={local.selectionMode}\n selectionBehavior={local.selectionBehavior}\n selectedKeys={local.selectedKeys}\n defaultSelectedKeys={local.defaultSelectedKeys}\n onSelectionChange={local.onSelectionChange}\n disabledKeys={local.disabledKeys}\n isDisabled={local.isDisabled}\n aria-label={local[\"aria-label\"]}\n aria-labelledby={local.label ? labelId : local[\"aria-labelledby\"]}\n aria-describedby={describedBy()}\n class={(renderProps) =>\n resolveStyleClass(tagListStyle, {\n ...renderProps,\n size: size(),\n isDisabled: local.isDisabled,\n })\n }\n renderEmptyState={renderedEmptyState}\n >\n {renderItem}\n </HeadlessTagList>\n\n <Show when={hasItems() && local.groupActionLabel && local.onGroupAction}>\n <span class={resolveStyleClass(actionRowStyle, { size: size() })}>\n <ActionButton size={size()} isQuiet onPress={local.onGroupAction}>\n {local.groupActionLabel}\n </ActionButton>\n </span>\n </Show>\n </div>\n\n <Show when={local.description && !isInvalid()}>\n <p\n id={descriptionId}\n class={helpTextStyle({\n size: size(),\n isInvalid: false,\n isDisabled: local.isDisabled,\n })}\n >\n {local.description}\n </p>\n </Show>\n\n <Show when={local.errorMessage && isInvalid()}>\n <p\n id={errorId}\n class={helpTextStyle({\n size: size(),\n isInvalid: true,\n isDisabled: local.isDisabled,\n })}\n >\n <AlertTriangleIcon styles={errorIconStyle} size={size()} aria-hidden=\"true\" />\n {local.errorMessage}\n </p>\n </Show>\n </div>\n </StyledTagGroupContext.Provider>\n );\n}\n\nexport type { Key, SelectionBehavior, SelectionMode };\n"],"mappings":";;;;;;;;;;AAuDA,MAAY,kBAAe,cAAA,IAAA;AAiB3B,MAAM,wBAAsB,cAAmC;AAC/D,MAAE,eAAgB,SAAA,UAAA,OAAA,WAAA;CACd,IAAE,QAAS;CACb,IAAM,kBAAc;CAClB,IAAE,gBAAe;CACnB,IAAA,UAAgB,OAAG,aAAM,EAAA,EAAA,SAAA,+EAAA;CACvB,KAAE,IAAA,KAAW,SAAO;EACtB,IAAA,EAAY,OAAO,KAAA,kBAAa;EAC5B,IAAA,EAAQ,OAAC,KAAW,gBAAa;EAC/B,SAAQ,EAAA;CACZ;CACF,SAAW;CACT,IAAE,MAAQ;MACF,CAAC,iBAAc,SAAI;CAAA;;MAGxB,MAAU,kBAAiB;OACxB,CAAO,eAAc,SAAA;EAAA;CAAA;CAG7B,IAAA,MAAY,UACN,SAAS;MAEX,IAAK,MAAA,kBAAyB,QAC3B,SAAM;MACJ,IAAO,MAAA,kBAAyB,OAChC,SAAM;CAGb,IAAE,MAAQ,kBAAiB,QAC7B,SAAe;MACX,IAAA,MAAe,kBAAgB,OAC7B,SAAQ;CAEd,IAAM,MAAM,kBAAa,QACrB,SAAS;MACJ,IAAA,MAAA,kBAAW,OAChB,SAAW;CAEb,IAAE,MAAA,SAAiB,MAAC;EACtB,SAAe;EACjB,SAAA;;EAEO,SAAM;;CAEb,OAAU,IAAA,MAAA,SAAoB,KAAC;EACvB,SAAA;EACN,SAAc;CACd,OAAS,IAAG,MAAK,SAAQ,MAAI;EAC/B,SAAA;;CAEA,OAAU;EACF,SAAC;EACP,SAAe;CACf;CACA,SAAA;CACA,IAAA,MAAY,SA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A,KAAA,QAAA,YACJ,OAAI,KAAA,IAAA,GAAA;CAER,KAAK,MAAI,SAAU,MACf,IAAI,UAAA,KAAA,OAAA;CAIR,OAAO;AACX;AAGA,MAAM,sBAAU;AAGhB,MAAM,wBAAoB;AAC1B,SAAS,cAAE,OAAA;CACP,IAAI,MAAM,QAAE,KAAA,GACR,OAAI,MAAO,WAAa,KAAC,cAAA,MAAA,EAAA;CAE7B,IAAI,UAAM;wBASH;EACH,IAAI,OAAI,WAAO,UACX,OAAO;EAEX,OAAM,oBAAe,KAAA,MAAA,KAAA,sBAAA,KAAA,MAAA;CACzB;CACA,IAAI,OAAM,gBAAA,eAAA,EAAA,iBAAA,cACN,OAAE;CAEN,OAAO,MAAE,aAAM,MAAY,MAAA,SAAA,MAAA,UAAA,SAAA,eAAA;AAC/B;AACA,SAAS,QAAK,GAAA,KAAA;CACV,OAAO,IAAA,OAAA,OAAA,EAAA,KAAA,GAAA,KAAA,KAAA;AACX;AACA,SAAG,aAAA,SAAA,MAAA;CACH,IAAA,WAAA,QAAA,WAAA,GAAA"}
|
|
1
|
+
{"version":3,"file":"index.jsx","names":[],"sources":["../../src/tag-group/index.tsx"],"sourcesContent":["// @ts-nocheck\nimport {\n type JSX,\n children as resolveChildren,\n createContext,\n createUniqueId,\n mergeProps,\n splitProps,\n useContext,\n Show,\n} from \"solid-js\";\nimport { isServer } from \"solid-js/web\";\nimport { getSlottedContextProps, type SpectrumContextValue } from \"../button/spectrum-context\";\nimport {\n TagList as HeadlessTagList,\n Tag as HeadlessTag,\n TagRemoveButton as HeadlessTagRemoveButton,\n type TagListProps as HeadlessTagListProps,\n type TagRenderProps,\n type TagProps as HeadlessTagProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport type { Key, SelectionBehavior, SelectionMode } from \"@proyecto-viviana/solid-stately\";\nimport type { StyleString } from \"../style\";\nimport { baseColor, focusRing, lightDark, style } from \"../style\" with { type: \"macro\" };\nimport {\n control,\n controlFont,\n field,\n fieldInput,\n fieldLabel,\n getAllowedOverrides,\n} from \"../s2-internal/style-utils\" with { type: \"macro\" };\nimport { useProviderProps } from \"../provider\";\nimport { pressScale } from \"../pressScale\";\nimport AlertTriangleIcon from \"../icon/s2wf-icons/AlertTriangleIcon\";\nimport { CrossIcon } from \"../icon/ui-icons/Cross\";\nimport { ActionButton } from \"../button/ActionButton\";\n\nexport type TagGroupSize = \"S\" | \"M\" | \"L\" | \"sm\" | \"md\" | \"lg\";\ntype S2TagGroupSize = \"S\" | \"M\" | \"L\";\nexport type TagGroupVariant = \"default\" | \"outline\" | \"solid\";\nexport type TagGroupLabelPosition = \"top\" | \"side\";\nexport type TagGroupLabelAlign = \"start\" | \"end\";\n\nexport interface TagGroupProps<T extends { id?: Key; key?: Key }> extends Omit<\n HeadlessTagListProps<T>,\n \"class\" | \"style\" | \"children\" | \"label\"\n> {\n /** The label for the tag group. */\n label?: JSX.Element;\n /** Function to render each tag or each tag's content. */\n children: (item: T) => JSX.Element;\n /** S2 tag size. Legacy sm/md/lg aliases map to S/M/L. @default 'M' */\n size?: TagGroupSize;\n /** Legacy visual variant. Prefer `isEmphasized` for S2 parity. */\n variant?: TagGroupVariant;\n /** Whether selected tags use the emphasized accent fill. */\n isEmphasized?: boolean;\n /** Description text shown below the tag list. */\n description?: JSX.Element;\n /** Error message shown when invalid. */\n errorMessage?: JSX.Element;\n /** Whether the group is invalid. */\n isInvalid?: boolean;\n /** Position of the label relative to the tag list. */\n labelPosition?: TagGroupLabelPosition;\n /** Text alignment for side labels. */\n labelAlign?: TagGroupLabelAlign;\n /** Label for the optional group action button. */\n groupActionLabel?: string;\n /** Handler for the optional group action button. */\n onGroupAction?: () => void;\n /** Maximum visible rows. This is approximated with overflow clipping in Solid. */\n maxRows?: number;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n /** Backward-compatible class alias. Prefer UNSAFE_className for S2 parity. */\n class?: string;\n /** Backward-compatible inline style alias. Prefer UNSAFE_style for S2 parity. */\n style?: JSX.CSSProperties;\n /** Handler called when a tag is activated. */\n onAction?: (key: Key) => void;\n}\n\nexport interface TagProps extends Omit<HeadlessTagProps, \"class\" | \"style\" | \"children\"> {\n /** The content of the tag. */\n children?: JSX.Element;\n /** Whether selected tags use the emphasized accent fill. Inherited from TagGroup. */\n isEmphasized?: boolean;\n /** S2 tag size. Inherited from TagGroup. */\n size?: TagGroupSize;\n /** Href retained for API parity; rendered as a tag action in the current Solid primitive. */\n href?: string;\n /** Link target retained for API parity. */\n target?: string;\n /** Link relationship retained for API parity. */\n rel?: string;\n /** Handler called when this tag is activated. */\n onAction?: (key: Key) => void;\n /** Additional CSS class name. Use only as a last resort. */\n class?: string;\n /** Additional inline styles. Use only as a last resort. */\n style?: JSX.CSSProperties;\n /** Spectrum-defined generated classes. */\n styles?: StyleString;\n /** Additional CSS class name. Use only as a last resort. */\n UNSAFE_className?: string;\n /** Additional inline styles. Use only as a last resort. */\n UNSAFE_style?: JSX.CSSProperties;\n}\n\nexport const TagGroupContext = createContext<SpectrumContextValue<TagGroupProps<any>>>(null);\n\ninterface TagGroupContextValue {\n size: S2TagGroupSize;\n isEmphasized: boolean;\n onAction?: (key: Key) => void;\n}\n\ninterface TagGroupStyleProps extends TagRenderProps {\n size?: S2TagGroupSize;\n labelPosition?: TagGroupLabelPosition;\n labelAlign?: TagGroupLabelAlign;\n isEmphasized?: boolean;\n isInvalid?: boolean;\n isLink?: boolean;\n isEmpty?: boolean;\n isDisabled?: boolean;\n allowsRemoving?: boolean;\n}\n\nconst StyledTagGroupContext = createContext<TagGroupContextValue>();\n\nconst tagGroupRoot = style<TagGroupStyleProps>(\n {\n ...field(),\n font: controlFont(),\n color: {\n default: baseColor(\"neutral\"),\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isDisabled: \"GrayText\",\n },\n },\n },\n getAllowedOverrides(),\n);\n\nconst labelWrapper = style<TagGroupStyleProps>({\n gridArea: \"label\",\n display: \"inline\",\n textAlign: {\n labelAlign: {\n start: \"start\",\n end: \"end\",\n },\n },\n paddingBottom: {\n labelPosition: {\n top: \"--field-gap\",\n },\n },\n contain: {\n labelPosition: {\n top: \"inline-size\",\n },\n },\n});\n\nconst labelStyle = style({\n ...fieldLabel(),\n});\n\nconst tagListContainer = style<TagGroupStyleProps>({\n gridArea: \"input\",\n minWidth: \"full\",\n marginStart: {\n default: -4,\n isEmpty: 0,\n },\n marginEnd: {\n default: 4,\n isEmpty: 0,\n },\n position: \"relative\",\n});\n\nconst tagListStyle = style({\n ...fieldInput(),\n display: \"inline\",\n minWidth: \"full\",\n // S2's real `<TagList>` sets a FIXED `font: 'ui'` (14px) on the grid container —\n // NOT the size-conditional `controlFont()`. The tags scale their own font via\n // `control()`; the grid's font is a static default (D1 grid font-size diverges at\n // size S/L when this ramps).\n font: \"ui\",\n outlineStyle: \"none\",\n});\n\nconst tagStyle = style<TagGroupStyleProps>({\n ...focusRing(),\n ...control({ shape: \"default\", icon: true, register: \"chip\" }),\n display: \"inline-flex\",\n maxWidth: \"full\",\n verticalAlign: \"middle\",\n justifyContent: \"center\",\n transition: \"default\",\n /* The muted chip is a WELL, not a gray step. All three of the handoff's unselected\n * chips are drawn `background: var(--surface-well)` inside `--well-border`\n * (TerminalGlassLab.tsx:35-55) — the same matte surface as a terminal well, which is\n * why `control({register:\"chip\"})` above already hands them the well's border. The\n * fill was the last part still coming off the ramp, and `gray-100` is opaque on both\n * columns (#e5eaf1 / #43474d), so the chips read as flat grey plates on a page whose\n * every other surface is glass or well: 10 elements in dark, 10 in light.\n *\n * Hover has no drawn counterpart — the handoff's chips are static — so it takes\n * `surface-hover`, the register's one hover surface, rather than a second ramp step. */\n backgroundColor: {\n default: \"well\",\n isHovered: {\n default: \"surface-hover\",\n },\n isFocusVisible: {\n default: \"surface-hover\",\n },\n isSelected: {\n default: baseColor(\"neutral\"),\n isEmphasized: {\n default: \"interactive-fill\",\n isHovered: lightDark(\"accent-1000\", \"accent-600\"),\n isPressed: lightDark(\"accent-1000\", \"accent-600\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-600\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonFace\",\n isSelected: \"Highlight\",\n },\n },\n /* ...and the well's dither with it. The handoff sets `scan: true` on exactly the three\n * well-filled chips and `scan: false` on the selected one (TerminalGlassLab.tsx:33, :40),\n * so the texture follows the fill: a chip that stops being a well stops being dithered.\n *\n * The gradient is `wellScan()`'s literal, restated rather than spread because that helper\n * emits an unconditional `backgroundImage` and this needs the `isSelected` branch —\n * spreading it and re-declaring the key in the same object is the duplicate-key trap.\n * `wellScan()` remains the source of the value; if it moves, this moves with it. */\n backgroundImage: {\n default: \"[repeating-conic-gradient(var(--well-scan) 0% 25%, transparent 0% 50%)]\",\n isSelected: \"none\",\n forcedColors: \"none\",\n },\n backgroundSize: \"[4px 4px]\",\n color: {\n default: baseColor(\"neutral\"),\n isSelected: {\n default: \"gray-25\",\n isEmphasized: \"white\",\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonText\",\n isSelected: \"HighlightText\",\n isDisabled: \"GrayText\",\n },\n },\n /* The chip's 1px edge arrives with `control({register: \"chip\"})` above, which sets\n * `borderWidth: 1`, `borderStyle: \"solid\"` and a resting `borderColor: \"well-border\"`\n * (s2-internal/style-utils.ts). This slot previously held `borderStyle: \"none\"`, and\n * because a literal key REPLACES the spread's value for that property, it cancelled the\n * register's edge outright — the chip drew no border at all. Only the state colours\n * belong here now; the width and style come from the register.\n *\n * A `default` stop is mandatory, not redundant with the spread: declaring `borderColor`\n * as a literal key discards the register's `well-border` for every state this map does\n * not name, and an unnamed state would fall back to `currentColor` (the tag's text).\n *\n * The stops mirror the `backgroundColor` map above so a selected chip's edge matches its\n * own fill rather than outlining it in the muted well colour.\n *\n * `gray-800` here is deliberate and must not be \"corrected\" to `baseColor(\"neutral\")` for\n * symmetry with the fill above: the theme's `borderColor` map (style/spectrum-theme.ts)\n * exposes `...baseColors` plus `negative`, `disabled` and the three edge tokens, but no\n * `neutral` — that key exists only on the `color`, `backgroundColor` and `fill` maps, so\n * `neutral` throws `Invalid color neutral` at macro build time. This file is `@ts-nocheck`,\n * so that surfaces as a build crash rather than a type error. The substitution is exact,\n * not approximate: `neutral` on `backgroundColor` is `neutral-background-color-default`,\n * which is a token `ref` to `{gray-800}`, and `nextColorStop` recurses through refs — so\n * both spellings resolve to the same stop and both step to gray-900 on hover/press. */\n borderColor: {\n default: \"well-border\",\n isSelected: {\n default: baseColor(\"gray-800\"),\n isEmphasized: {\n default: \"interactive-fill\",\n isHovered: lightDark(\"accent-1000\", \"accent-600\"),\n isPressed: lightDark(\"accent-1000\", \"accent-600\"),\n isFocusVisible: lightDark(\"accent-1000\", \"accent-600\"),\n },\n },\n isDisabled: \"disabled\",\n forcedColors: {\n default: \"ButtonBorder\",\n isSelected: \"Highlight\",\n isDisabled: \"GrayText\",\n },\n },\n paddingEnd: {\n default: \"edge-to-text\",\n allowsRemoving: 0,\n },\n margin: 4,\n cursor: {\n default: \"default\",\n isLink: \"pointer\",\n isDisabled: \"default\",\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\n// S2's TagWrapper CONTENT DIV (a sibling of the ClearButton at the tag-row flex\n// level). It carries NO `order`, so it keeps DOM order (content before the remove\n// button). The `order`/`truncate` belong on the inner Text (`tagTextStyle`), NOT\n// here — putting them on the row-level element sorts the label AFTER the\n// `order: 0` remove button (`× Landscape` instead of `Landscape ×`).\nconst tagContentStyle = style({\n display: \"flex\",\n minWidth: 0,\n alignItems: \"center\",\n gap: \"text-to-visual\",\n forcedColorAdjust: \"none\",\n backgroundColor: \"transparent\",\n});\n\n// S2's `TextContext` styles inside the content div: `{order: 1, truncate: true}`\n// (icon slots take `order: 0`, so the icon precedes the text regardless of DOM\n// order). Scoped to the inner text — see `tagContentStyle`.\nconst tagTextStyle = style({\n order: 1,\n truncate: true,\n});\n\n// Captured so the `outlineColor` static-color branch can reuse the focus ring's own\n// default (mirrors S2 `const focusRingStyles = focusRing()`).\nconst removeButtonFocusRing = focusRing();\n\nconst removeButtonStyle = style<TagGroupStyleProps>({\n ...removeButtonFocusRing,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n // Mirror S2 ClearButton (`visibleClearButton`): fill the tag height and width to\n // the control-size ramp (`controlSize()` = {S: 24, M: 32, L: 40}). The port's\n // local `controlSize` helper has a different meaning, so the ramp is inlined.\n height: \"full\",\n width: {\n size: {\n S: 24,\n M: 32,\n L: 40,\n },\n },\n flexShrink: 0,\n borderRadius: \"full\",\n borderStyle: \"none\",\n backgroundColor: \"transparent\",\n color: \"inherit\",\n boxSizing: \"border-box\",\n padding: 0,\n outlineOffset: -4,\n // Mirror S2 `visibleClearButton`: a static-color (emphasized + selected) tag uses\n // a white focus outline against its accent fill; every other tag uses the default\n // focus-ring colour. `isStaticColor` = `isEmphasized && isSelected` (threaded in\n // by the TagWrapper — here at the render site).\n outlineColor: {\n default: removeButtonFocusRing.outlineColor,\n isStaticColor: \"white\",\n },\n // S2 `visibleClearButton` sets NO cursor — the native `<button>` UA cursor\n // (`default`) stands. Do NOT re-add the arrow→`pointer` override (an invented\n // divergence: D1 pins React's native `default`).\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n});\n\nconst helpTextStyle = style<TagGroupStyleProps>({\n gridArea: \"helptext\",\n display: \"flex\",\n margin: 0,\n alignItems: \"baseline\",\n gap: \"text-to-visual\",\n font: controlFont(),\n color: {\n default: \"neutral-subdued\",\n isInvalid: {\n default: \"negative\",\n forcedColors: \"Mark\",\n },\n isDisabled: {\n default: \"disabled\",\n forcedColors: \"GrayText\",\n },\n },\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n contain: \"inline-size\",\n paddingTop: \"--field-gap\",\n});\n\nconst emptyStateStyle = style({\n color: \"neutral-subdued\",\n font: controlFont(),\n});\n\nconst actionRowStyle = style({\n display: \"inline-flex\",\n verticalAlign: \"middle\",\n margin: 4,\n gap: 4,\n});\n\nconst errorIconStyle = style({\n \"--iconPrimary\": {\n type: \"fill\",\n value: \"currentColor\",\n },\n flexShrink: 0,\n});\n\nfunction normalizeSize(size: TagGroupSize | undefined): S2TagGroupSize {\n switch (size) {\n case \"sm\":\n return \"S\";\n case \"md\":\n return \"M\";\n case \"lg\":\n return \"L\";\n case \"S\":\n case \"M\":\n case \"L\":\n return size;\n default:\n return \"M\";\n }\n}\n\nfunction getItemKey<T extends { id?: Key; key?: Key }>(item: T, getKey?: (item: T) => Key): Key {\n if (getKey) return getKey(item);\n if (item.id !== undefined) return item.id;\n if (item.key !== undefined) return item.key;\n return String(item);\n}\n\nfunction hasKey(keys: Iterable<Key> | \"all\" | undefined, key: Key): boolean {\n if (keys == null) {\n return false;\n }\n\n if (keys === \"all\") {\n return true;\n }\n\n if (\"has\" in keys && typeof keys.has === \"function\") {\n return keys.has(key);\n }\n\n for (const value of keys) {\n if (value === key) {\n return true;\n }\n }\n\n return false;\n}\n\n// Matches a `role=\"row\"` attribute in a serialized SSR node's markup, mirroring the client-side\n// `getAttribute(\"role\") === \"row\"` check below.\nconst SSR_TAG_ROW_PATTERN = /\\srole=\"row\"[\\s>]/;\n// Matches the `solidaria-Tag` token inside a `class=\"...\"` attribute, mirroring the client-side\n// `classList.contains(\"solidaria-Tag\")` check below.\nconst SSR_TAG_CLASS_PATTERN = /\\sclass=\"[^\"]*\\bsolidaria-Tag\\b[^\"]*\"/;\n\nfunction isRenderedTag(value: JSX.Element): boolean {\n if (Array.isArray(value)) {\n return value.length === 1 && isRenderedTag(value[0]);\n }\n\n if (isServer) {\n // During renderToString, resolved children are Solid's server-side SSR node objects\n // (`{ t: string }` holding the serialized HTML), not HTMLElement instances — `HTMLElement`\n // isn't even a global in Node. Duck-type the same \"already a rendered Tag row\" signal the\n // client checks for (a `role=\"row\"` gridcell wrapper carrying the Tag class) by inspecting\n // the markup string directly, so the wrap/no-wrap decision matches what the client will\n // compute once `HTMLElement` is real and hydration can walk a matching tree.\n const markup = (value as { t?: unknown } | null | undefined)?.t;\n if (typeof markup !== \"string\") {\n return false;\n }\n return SSR_TAG_ROW_PATTERN.test(markup) || SSR_TAG_CLASS_PATTERN.test(markup);\n }\n\n if (typeof HTMLElement === \"undefined\" || !(value instanceof HTMLElement)) {\n return false;\n }\n return value.getAttribute(\"role\") === \"row\" || value.classList.contains(\"solidaria-Tag\");\n}\n\nfunction joinIds(...ids: Array<string | undefined | false>) {\n return ids.filter(Boolean).join(\" \") || undefined;\n}\n\nfunction maxRowsStyle(\n maxRows: number | undefined,\n size: S2TagGroupSize,\n): JSX.CSSProperties | undefined {\n if (maxRows == null || maxRows <= 0) {\n return undefined;\n }\n\n const rowHeight = size === \"L\" ? 44 : size === \"S\" ? 30 : 36;\n return {\n \"max-height\": `${rowHeight * maxRows}px`,\n overflow: \"hidden\",\n };\n}\n\nfunction resolveStyleClass<P extends Record<string, unknown>>(\n styleValue: StyleString | ((props: P) => StyleString),\n props: P,\n): string {\n return typeof styleValue === \"function\" ? styleValue(props) : styleValue;\n}\n\n/**\n * An individual Tag for TagGroups.\n */\nexport function Tag(props: TagProps): JSX.Element {\n const ctx = useContext(StyledTagGroupContext);\n const [local, tagProps] = splitProps(props, [\n \"class\",\n \"style\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"children\",\n \"id\",\n \"isDisabled\",\n \"isEmphasized\",\n \"size\",\n \"href\",\n \"target\",\n \"rel\",\n \"onAction\",\n \"textValue\",\n ]);\n\n // Mirror S2 Tag: derive the row's accessible text from string children when no\n // explicit textValue is given. This names the row (and cascades to the remove\n // button's `aria-labelledby` and the gridcell's name-from-contents), matching\n // how S2 auto-derives `node.textValue` from string children.\n const textValue = () =>\n local.textValue ?? (typeof local.children === \"string\" ? local.children : undefined);\n const size = () => normalizeSize(local.size ?? ctx?.size);\n const isEmphasized = () => local.isEmphasized ?? ctx?.isEmphasized ?? false;\n const isLink = () => local.href != null;\n const actionHandler = () => local.onAction ?? ctx?.onAction;\n\n // Mirror S2 Tag: `ref={domRef} style={pressScale(domRef)}` — the layer hint\n // (`will-change: transform`) at rest, plus the press-scale transform on press.\n let tagEl: HTMLDivElement | undefined;\n const rowStyle = (renderProps: TagRenderProps): JSX.CSSProperties =>\n pressScale(() => tagEl, local.UNSAFE_style ?? local.style)(renderProps);\n\n // Mirror S2 ClearButton: `<Button style={pressScale(domRef)}>` — pressScale\n // ALWAYS contributes the `will-change: transform` layer hint. The plain headless\n // remove button carries no press state yet, so only the resting hint is mirrored\n // here; the on-press scale lands with the CP9.44b interaction pass\n // (tech-debt `taggroup-remove-pressscale`).\n const removeButtonRestStyle = pressScale(undefined)({ isPressed: false });\n\n const className = (renderProps: TagRenderProps) =>\n [\n local.UNSAFE_className,\n local.class,\n tagStyle(\n {\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n isLink: isLink(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <HeadlessTag\n {...tagProps}\n id={local.id}\n isDisabled={local.isDisabled}\n textValue={textValue()}\n class={className}\n ref={(el: HTMLDivElement) => (tagEl = el)}\n style={rowStyle}\n data-href={local.href}\n data-target={local.target}\n data-rel={local.rel}\n onAction={() => actionHandler()?.(local.id)}\n >\n {(renderProps) => (\n <>\n <div class={resolveStyleClass(tagContentStyle, {})}>\n <span class={resolveStyleClass(tagTextStyle, {})}>{local.children}</span>\n </div>\n <Show when={renderProps.allowsRemoving}>\n <HeadlessTagRemoveButton\n buttonProps={renderProps.removeButtonProps}\n class={removeButtonStyle({\n ...renderProps,\n size: size(),\n isEmphasized: isEmphasized(),\n // S2 TagWrapper: `isStaticColor={isEmphasized && isSelected}`.\n isStaticColor: isEmphasized() && renderProps.isSelected,\n })}\n style={removeButtonRestStyle}\n >\n {/* S2 ClearButton renders `<CrossIcon size={props.size}/>` with the RAW\n control size — the ui-icon selects its own variant (S→Size75,\n M→Size100, L→Size200) and CSS width (S=M=8px, L=10px). Passing a\n down-mapped size renders the wrong Cross path variant. No\n `aria-hidden`: S2's ClearButton leaves the bare CrossIcon svg\n exposed (Chromium reports an unnamed `img` under the labelled\n remove button), so mirror that AX shape rather than hiding it. */}\n <CrossIcon size={size()} />\n </HeadlessTagRemoveButton>\n </Show>\n </>\n )}\n </HeadlessTag>\n );\n}\n\n/**\n * A tag group displays a collection of tags that can be selected and/or removed.\n */\nexport function TagGroup<T extends { id?: Key; key?: Key }>(props: TagGroupProps<T>): JSX.Element {\n const providerProps = useProviderProps(props);\n const contextProps = getSlottedContextProps(useContext(TagGroupContext), props.slot);\n const mergedProps = mergeProps(providerProps, contextProps ?? {}, props);\n const [local, listProps] = splitProps(mergedProps, [\n \"label\",\n \"items\",\n \"children\",\n \"getKey\",\n \"onRemove\",\n \"size\",\n \"variant\",\n \"isEmphasized\",\n \"description\",\n \"errorMessage\",\n \"isInvalid\",\n \"labelPosition\",\n \"labelAlign\",\n \"groupActionLabel\",\n \"onGroupAction\",\n \"maxRows\",\n \"styles\",\n \"UNSAFE_className\",\n \"UNSAFE_style\",\n \"class\",\n \"style\",\n \"renderEmptyState\",\n \"selectionMode\",\n \"selectionBehavior\",\n \"selectedKeys\",\n \"defaultSelectedKeys\",\n \"onSelectionChange\",\n \"disabledKeys\",\n \"isDisabled\",\n \"onAction\",\n \"id\",\n \"aria-label\",\n \"aria-labelledby\",\n \"aria-describedby\",\n ]);\n\n const labelId = createUniqueId();\n const descriptionId = createUniqueId();\n const errorId = createUniqueId();\n const size = () => normalizeSize(local.size);\n const labelPosition = () => local.labelPosition ?? \"top\";\n const labelAlign = () => local.labelAlign ?? \"start\";\n const isInvalid = () => local.isInvalid === true;\n const isEmphasized = () => local.isEmphasized ?? local.variant === \"solid\";\n const hasItems = () => local.items.length > 0;\n const keyForItem = (item: T) => getItemKey(item, local.getKey);\n const renderedEmptyState = () => (\n <span class={resolveStyleClass(emptyStateStyle, { size: size() })}>\n {local.renderEmptyState?.() ?? \"No tags\"}\n </span>\n );\n\n const describedBy = () =>\n joinIds(\n local[\"aria-describedby\"],\n local.description && !isInvalid() ? descriptionId : undefined,\n local.errorMessage && isInvalid() ? errorId : undefined,\n );\n\n const rootClass = () =>\n [\n local.UNSAFE_className,\n local.class,\n tagGroupRoot(\n {\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n isDisabled: local.isDisabled,\n isInvalid: isInvalid(),\n },\n local.styles,\n ),\n ]\n .filter(Boolean)\n .join(\" \");\n\n const renderItem = (item: T) => {\n const resolved = resolveChildren(() => local.children(item));\n const rendered = resolved();\n if (isRenderedTag(rendered)) {\n return rendered;\n }\n\n return (\n <Tag id={keyForItem(item)} isDisabled={hasKey(local.disabledKeys, keyForItem(item))}>\n {rendered}\n </Tag>\n );\n };\n\n const contextValue: TagGroupContextValue = {\n get size() {\n return size();\n },\n get isEmphasized() {\n return isEmphasized();\n },\n get onAction() {\n return local.onAction;\n },\n };\n\n return (\n <StyledTagGroupContext.Provider value={contextValue}>\n <div\n id={local.id}\n class={rootClass()}\n style={local.UNSAFE_style ?? local.style}\n data-invalid={isInvalid() ? \"true\" : undefined}\n data-disabled={local.isDisabled ? \"true\" : undefined}\n >\n <Show when={local.label}>\n <div\n class={labelWrapper({\n size: size(),\n labelPosition: labelPosition(),\n labelAlign: labelAlign(),\n })}\n >\n <span\n id={labelId}\n class={resolveStyleClass(labelStyle, { size: size(), isDisabled: local.isDisabled })}\n >\n {local.label}\n </span>\n </div>\n </Show>\n\n <div\n class={tagListContainer({\n size: size(),\n isEmpty: local.items.length === 0,\n })}\n style={maxRowsStyle(local.maxRows, size())}\n >\n <HeadlessTagList\n {...listProps}\n items={local.items}\n getKey={local.getKey}\n onRemove={local.onRemove}\n selectionMode={local.selectionMode}\n selectionBehavior={local.selectionBehavior}\n selectedKeys={local.selectedKeys}\n defaultSelectedKeys={local.defaultSelectedKeys}\n onSelectionChange={local.onSelectionChange}\n disabledKeys={local.disabledKeys}\n isDisabled={local.isDisabled}\n aria-label={local[\"aria-label\"]}\n aria-labelledby={local.label ? labelId : local[\"aria-labelledby\"]}\n aria-describedby={describedBy()}\n class={(renderProps) =>\n resolveStyleClass(tagListStyle, {\n ...renderProps,\n size: size(),\n isDisabled: local.isDisabled,\n })\n }\n renderEmptyState={renderedEmptyState}\n >\n {renderItem}\n </HeadlessTagList>\n\n <Show when={hasItems() && local.groupActionLabel && local.onGroupAction}>\n <span class={resolveStyleClass(actionRowStyle, { size: size() })}>\n <ActionButton size={size()} isQuiet onPress={local.onGroupAction}>\n {local.groupActionLabel}\n </ActionButton>\n </span>\n </Show>\n </div>\n\n <Show when={local.description && !isInvalid()}>\n <p\n id={descriptionId}\n class={helpTextStyle({\n size: size(),\n isInvalid: false,\n isDisabled: local.isDisabled,\n })}\n >\n {local.description}\n </p>\n </Show>\n\n <Show when={local.errorMessage && isInvalid()}>\n <p\n id={errorId}\n class={helpTextStyle({\n size: size(),\n isInvalid: true,\n isDisabled: local.isDisabled,\n })}\n >\n <AlertTriangleIcon styles={errorIconStyle} size={size()} aria-hidden=\"true\" />\n {local.errorMessage}\n </p>\n </Show>\n </div>\n </StyledTagGroupContext.Provider>\n );\n}\n\nexport type { Key, SelectionBehavior, SelectionMode };\n"],"mappings":";;;;;;;;;;AAuDA,MAAY,kBAAe,cAAA,IAAA;AAiB3B,MAAM,wBAAsB,cAAmC;AAC/D,MAAE,eAAgB,SAAA,UAAA,OAAA,WAAA;CACd,IAAE,QAAS;CACb,IAAM,kBAAc;CAClB,IAAE,gBAAe;CACnB,IAAA,UAAgB,OAAG,aAAM,EAAA,EAAA,SAAA,+EAAA;CACvB,KAAE,IAAA,KAAW,SAAO;EACtB,IAAA,EAAY,OAAO,KAAA,kBAAa;EAC5B,IAAA,EAAQ,OAAC,KAAW,gBAAa;EAC/B,SAAQ,EAAA;CACZ;CACF,SAAW;CACT,IAAE,MAAQ;MACF,CAAC,iBA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AA,WAAA,GAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/toolbar/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,GAAG,EAAc,MAAM,UAAU,CAAC;AAChD,OAAO,EAEL,KAAK,YAAY,IAAI,oBAAoB,EACzC,KAAK,kBAAkB,EACxB,MAAM,wCAAwC,CAAC;AAGhD,YAAY,EAAE,kBAAkB,EAAE,CAAC;AACnC,MAAM,MAAM,YAAY,GAAG,oBAAoB,CAAC;AA0BhD;;;;;;;;;;;;GAYG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,YAAY,GAAG,GAAG,CAAC,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/toolbar/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,GAAG,EAAc,MAAM,UAAU,CAAC;AAChD,OAAO,EAEL,KAAK,YAAY,IAAI,oBAAoB,EACzC,KAAK,kBAAkB,EACxB,MAAM,wCAAwC,CAAC;AAGhD,YAAY,EAAE,kBAAkB,EAAE,CAAC;AACnC,MAAM,MAAM,YAAY,GAAG,oBAAoB,CAAC;AA0BhD;;;;;;;;;;;;GAYG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,YAAY,GAAG,GAAG,CAAC,OAAO,CAcxD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../src/toolbar/index.tsx"],"sourcesContent":["import { type JSX, splitProps } from \"solid-js\";\nimport {\n Toolbar as HeadlessToolbar,\n type ToolbarProps as HeadlessToolbarProps,\n type ToolbarRenderProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport { style } from \"../style\" with { type: \"macro\" };\n\nexport type { ToolbarRenderProps };\nexport type ToolbarProps = HeadlessToolbarProps;\n\n// S2 1.5.1 ships Toolbar as a bare unstyled passthrough, but viviana-ui owns\n// its own register: an unstyled toolbar renders as a plain block and its\n// controls stack with no rhythm. Layout only — flex along the toolbar axis\n// with a consistent gap; the controls keep their own paint. `alignSelf: start`\n// stops column-flex parents from stretching the row full-width.\nconst toolbarStyles = style<{ orientation: \"horizontal\" | \"vertical\" }>({\n display: \"flex\",\n alignSelf: \"start\",\n justifySelf: \"start\",\n gap: 8,\n flexDirection: {\n orientation: {\n horizontal: \"row\",\n vertical: \"column\",\n },\n },\n alignItems: {\n orientation: {\n horizontal: \"center\",\n vertical: \"start\",\n },\n },\n});\n\n/**\n * A toolbar is a container for a set of interactive controls, such as buttons,\n * menus, or checkboxes, with arrow key navigation between them.\n *\n * @example\n * ```tsx\n * <Toolbar aria-label=\"Text formatting\">\n * <Button>Bold</Button>\n * <Button>Italic</Button>\n * <Button>Underline</Button>\n * </Toolbar>\n * ```\n */\nexport function Toolbar(props: ToolbarProps): JSX.Element {\n const [local, headlessProps] = splitProps(props, [\"class\"]);\n\n const mergedClass = (rp: ToolbarRenderProps): string => {\n const cls = local.class;\n return [toolbarStyles({ orientation: rp.orientation })
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../src/toolbar/index.tsx"],"sourcesContent":["import { type JSX, splitProps } from \"solid-js\";\nimport {\n Toolbar as HeadlessToolbar,\n type ToolbarProps as HeadlessToolbarProps,\n type ToolbarRenderProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport { style } from \"../style\" with { type: \"macro\" };\n\nexport type { ToolbarRenderProps };\nexport type ToolbarProps = HeadlessToolbarProps;\n\n// S2 1.5.1 ships Toolbar as a bare unstyled passthrough, but viviana-ui owns\n// its own register: an unstyled toolbar renders as a plain block and its\n// controls stack with no rhythm. Layout only — flex along the toolbar axis\n// with a consistent gap; the controls keep their own paint. `alignSelf: start`\n// stops column-flex parents from stretching the row full-width.\nconst toolbarStyles = style<{ orientation: \"horizontal\" | \"vertical\" }>({\n display: \"flex\",\n alignSelf: \"start\",\n justifySelf: \"start\",\n gap: 8,\n flexDirection: {\n orientation: {\n horizontal: \"row\",\n vertical: \"column\",\n },\n },\n alignItems: {\n orientation: {\n horizontal: \"center\",\n vertical: \"start\",\n },\n },\n});\n\n/**\n * A toolbar is a container for a set of interactive controls, such as buttons,\n * menus, or checkboxes, with arrow key navigation between them.\n *\n * @example\n * ```tsx\n * <Toolbar aria-label=\"Text formatting\">\n * <Button>Bold</Button>\n * <Button>Italic</Button>\n * <Button>Underline</Button>\n * </Toolbar>\n * ```\n */\nexport function Toolbar(props: ToolbarProps): JSX.Element {\n const [local, headlessProps] = splitProps(props, [\"class\"]);\n\n const mergedClass = (rp: ToolbarRenderProps): string => {\n const cls = local.class;\n return [\n toolbarStyles({ orientation: rp.orientation }),\n typeof cls === \"function\" ? cls(rp) : cls,\n ]\n .filter(Boolean)\n .join(\" \");\n };\n\n return <HeadlessToolbar {...headlessProps} class={mergedClass} />;\n}\n"],"mappings":";;;;AAgBA,MAAM,gBAAA,SAAA,UAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;AAgCN,SAAgB,QAAQ,OAA0B;CAChD,MAAM,CAAC,OAAO,iBAAiB,WAAW,OAAO,CAAC,OAAA,CAAQ;CAE1D,MAAM,eAAe,OAA+B;EAClD,MAAM,MAAM,MAAM;EAClB,OAAO,CACL,cAAc,EAAE,aAAa,GAAG,YAAY,CAAA,GAC5C,OAAO,QAAQ,aAAa,IAAI,EAAA,IAAM,GAAA,EAErC,OAAO,OAAA,EACP,KAAK,GAAA;CACV;CAEA,OAAA,gBAAQ,WAAA,WAAoB,eAAa,EAAA,SAAS,YAAA,CAAA,CAAA;AACpD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.jsx","names":[],"sources":["../../src/toolbar/index.tsx"],"sourcesContent":["import { type JSX, splitProps } from \"solid-js\";\nimport {\n Toolbar as HeadlessToolbar,\n type ToolbarProps as HeadlessToolbarProps,\n type ToolbarRenderProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport { style } from \"../style\" with { type: \"macro\" };\n\nexport type { ToolbarRenderProps };\nexport type ToolbarProps = HeadlessToolbarProps;\n\n// S2 1.5.1 ships Toolbar as a bare unstyled passthrough, but viviana-ui owns\n// its own register: an unstyled toolbar renders as a plain block and its\n// controls stack with no rhythm. Layout only — flex along the toolbar axis\n// with a consistent gap; the controls keep their own paint. `alignSelf: start`\n// stops column-flex parents from stretching the row full-width.\nconst toolbarStyles = style<{ orientation: \"horizontal\" | \"vertical\" }>({\n display: \"flex\",\n alignSelf: \"start\",\n justifySelf: \"start\",\n gap: 8,\n flexDirection: {\n orientation: {\n horizontal: \"row\",\n vertical: \"column\",\n },\n },\n alignItems: {\n orientation: {\n horizontal: \"center\",\n vertical: \"start\",\n },\n },\n});\n\n/**\n * A toolbar is a container for a set of interactive controls, such as buttons,\n * menus, or checkboxes, with arrow key navigation between them.\n *\n * @example\n * ```tsx\n * <Toolbar aria-label=\"Text formatting\">\n * <Button>Bold</Button>\n * <Button>Italic</Button>\n * <Button>Underline</Button>\n * </Toolbar>\n * ```\n */\nexport function Toolbar(props: ToolbarProps): JSX.Element {\n const [local, headlessProps] = splitProps(props, [\"class\"]);\n\n const mergedClass = (rp: ToolbarRenderProps): string => {\n const cls = local.class;\n return [toolbarStyles({ orientation: rp.orientation })
|
|
1
|
+
{"version":3,"file":"index.jsx","names":[],"sources":["../../src/toolbar/index.tsx"],"sourcesContent":["import { type JSX, splitProps } from \"solid-js\";\nimport {\n Toolbar as HeadlessToolbar,\n type ToolbarProps as HeadlessToolbarProps,\n type ToolbarRenderProps,\n} from \"@proyecto-viviana/solidaria-components\";\nimport { style } from \"../style\" with { type: \"macro\" };\n\nexport type { ToolbarRenderProps };\nexport type ToolbarProps = HeadlessToolbarProps;\n\n// S2 1.5.1 ships Toolbar as a bare unstyled passthrough, but viviana-ui owns\n// its own register: an unstyled toolbar renders as a plain block and its\n// controls stack with no rhythm. Layout only — flex along the toolbar axis\n// with a consistent gap; the controls keep their own paint. `alignSelf: start`\n// stops column-flex parents from stretching the row full-width.\nconst toolbarStyles = style<{ orientation: \"horizontal\" | \"vertical\" }>({\n display: \"flex\",\n alignSelf: \"start\",\n justifySelf: \"start\",\n gap: 8,\n flexDirection: {\n orientation: {\n horizontal: \"row\",\n vertical: \"column\",\n },\n },\n alignItems: {\n orientation: {\n horizontal: \"center\",\n vertical: \"start\",\n },\n },\n});\n\n/**\n * A toolbar is a container for a set of interactive controls, such as buttons,\n * menus, or checkboxes, with arrow key navigation between them.\n *\n * @example\n * ```tsx\n * <Toolbar aria-label=\"Text formatting\">\n * <Button>Bold</Button>\n * <Button>Italic</Button>\n * <Button>Underline</Button>\n * </Toolbar>\n * ```\n */\nexport function Toolbar(props: ToolbarProps): JSX.Element {\n const [local, headlessProps] = splitProps(props, [\"class\"]);\n\n const mergedClass = (rp: ToolbarRenderProps): string => {\n const cls = local.class;\n return [\n toolbarStyles({ orientation: rp.orientation }),\n typeof cls === \"function\" ? cls(rp) : cls,\n ]\n .filter(Boolean)\n .join(\" \");\n };\n\n return <HeadlessToolbar {...headlessProps} class={mergedClass} />;\n}\n"],"mappings":";;;AASA,MAAM,gBAAM,SAAe,UAAA,OAAoB;;CAE5C,SAAS;CACT,SAAQ;CACR,SAAS;CACT,SAAO;CACP,SAAM;CACT,IAAM,MAAA,gBAAwB,YAC5B,SAAe;MACN,IAAG,MAAM,gBAAA,cAClB,SAAc;CAEd,IAAA,MAAA,gBAAe,YACb,SAAa;MACX,IAAA,MAAa,gBAAI,cACjB,SAAW;CAEd,OAAA;AACH;;;;;;;;;;;;;GAaI,SAAE,QAAA,OAAA;CACF,MAAA,CAAO,OAAM,iBAAY,WAAW,OAAA,CAClC,OACF,CAAC;CACD,MAAE,eAAkB,OAAM;EACzB,MAAO,MAAA,MAAA;EACP,OAAA,CACH,cAAA,EACc,aAAa,GAAE,YACtB,CAAA,GAAA,OAAA,QAAA,aAAA,IAAA,EAAA,IAAA,GAED,EAAA,OAAA,OAAe,EAAG,KAAC,GAAA;CACvB;CACA,OAAO,CAAA,cAAA,eAA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E;AAQD,eAAO,MAAM,QAAQ,aAAO,CAAC;AAC7B,eAAO,MAAM,YAAY,iBAAW,CAAC;AACrC,eAAO,MAAM,mBAAmB,wBAAkB,CAAC;AACnD,eAAO,MAAM,oBAAoB,yBAAmB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AACpE,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAE/B,YAAY,EAAE,GAAG,EAAE,YAAY,EAAE,mBAAmB,EAAE,CAAC"}
|
package/dist/tree/index.js
CHANGED
|
@@ -17,7 +17,7 @@ import { className, createComponent, effect, getNextElement, getNextMarker, inse
|
|
|
17
17
|
import { children, createContext, createEffect, createMemo, createSignal, mergeProps as mergeProps$1, onCleanup, splitProps, useContext } from "solid-js";
|
|
18
18
|
import { Collection, Tree as Tree$1, TreeExpandButton as TreeExpandButton$1, TreeItem as TreeItem$1, TreeItemContent as TreeItemContent$1, TreeItemContext, TreeLoadMoreItem as TreeLoadMoreItem$1, TreeSelectionCheckbox as TreeSelectionCheckbox$1, TreeStateContext } from "@proyecto-viviana/solidaria-components";
|
|
19
19
|
//#region src/tree/index.tsx
|
|
20
|
-
var _tmpl$ = /*#__PURE__*/ template(`<div class=" MkDJKOc151 sd151 eb151 _Ca151 pHKLAu151 uk151 ucJ9TBTb151 ud3Euai151 uea151 ugb151 uhd151 uje151 u2NhKxcl151 uic151 -_6BNtrc-b151 vx151 xb151 _xa151 _Fb151 _FnuYUwec151">`), _tmpl$2 = /*#__PURE__*/ template(`<div class=" Mi151 sd151 eb151 _Ca151
|
|
20
|
+
var _tmpl$ = /*#__PURE__*/ template(`<div class=" MkDJKOc151 sd151 eb151 _Ca151 pHKLAu151 uk151 ucJ9TBTb151 ud3Euai151 uea151 ugb151 uhd151 uje151 u2NhKxcl151 uic151 -_6BNtrc-b151 vx151 xb151 _xa151 _Fb151 _FnuYUwec151">`), _tmpl$2 = /*#__PURE__*/ template(`<div class=" Mi151 sd151 eb151 _Ca151 pWQ7V3d151"data-rsp-slot=load-more>`), _tmpl$3 = /*#__PURE__*/ template(`<div hidden inert aria-hidden=true style=display:none>`), _tmpl$4 = /*#__PURE__*/ template(`<div><!$><!/><!$><!/><!$><!/><!$><!/>`), _tmpl$5 = /*#__PURE__*/ template(`<div>`), _tmpl$6 = /*#__PURE__*/ template(`<div aria-hidden=true>`), _tmpl$7 = /*#__PURE__*/ template(`<span class=" z7fSmKc151 y7fSmKc151 B7fSmKc151 A7fSmKc151 _df151 ZatWdwc151"aria-hidden=true>`), _tmpl$8 = /*#__PURE__*/ template(`<span slot=icon class=" z2U5Crc151 y2U5Crc151 B2U5Crc151 AvoofG151 sb151 ZuUmpre151 FuUmpre151 _dc151 Ht151 Hsu151 -_8sjo0b-t5ZbAob151"data-rsp-slot=icon>`), _tmpl$9 = /*#__PURE__*/ template(`<span>`), _tmpl$0 = /*#__PURE__*/ template(`<button>`), _tmpl$1 = /*#__PURE__*/ template(`<span data-rsp-slot=selection-indicator><!$><!/><span>`);
|
|
21
21
|
const TreeViewContext = createContext(null);
|
|
22
22
|
const InternalTreeViewContext = createContext({ selectionStyle: "checkbox" });
|
|
23
23
|
const StaticTreeCollectionContext = createContext(null);
|
|
@@ -164,7 +164,7 @@ const legacyDescription = function anonymous(props) {
|
|
|
164
164
|
if (props.isPressed) rules += " pQKeKoe151";
|
|
165
165
|
else if (props.isFocusVisible) rules += " pQKeKoe151";
|
|
166
166
|
else if (props.isHovered) rules += " pQKeKoe151";
|
|
167
|
-
else rules += "
|
|
167
|
+
else rules += " pWQ7V3d151";
|
|
168
168
|
rules += " Js151";
|
|
169
169
|
return rules;
|
|
170
170
|
};
|
|
@@ -196,7 +196,7 @@ const treeViewItem = function anonymous(props) {
|
|
|
196
196
|
else if (props.isPressed) rules += " pQKeKoe151";
|
|
197
197
|
else if (props.isFocusVisible) rules += " pQKeKoe151";
|
|
198
198
|
else if (props.isHovered) rules += " pQKeKoe151";
|
|
199
|
-
else rules += "
|
|
199
|
+
else rules += " pWQ7V3d151";
|
|
200
200
|
else {
|
|
201
201
|
if (props.isDisabled) rules += " pUvnvv151";
|
|
202
202
|
else if (props.isSelected) if (props.isPressed) rules += " pMwyHo151";
|
|
@@ -206,7 +206,7 @@ const treeViewItem = function anonymous(props) {
|
|
|
206
206
|
else if (props.isPressed) rules += " pQKeKoe151";
|
|
207
207
|
else if (props.isFocusVisible) rules += " pQKeKoe151";
|
|
208
208
|
else if (props.isHovered) rules += " pQKeKoe151";
|
|
209
|
-
else rules += "
|
|
209
|
+
else rules += " pWQ7V3d151";
|
|
210
210
|
rules += " plb151";
|
|
211
211
|
}
|
|
212
212
|
rules += " g9151";
|
|
@@ -446,7 +446,7 @@ const treeDescription = function anonymous(props) {
|
|
|
446
446
|
} else if (props.isPressed) rules += " pQKeKoe151";
|
|
447
447
|
else if (props.isFocusVisible) rules += " pQKeKoe151";
|
|
448
448
|
else if (props.isHovered) rules += " pQKeKoe151";
|
|
449
|
-
else rules += "
|
|
449
|
+
else rules += " pWQ7V3d151";
|
|
450
450
|
rules += " _Nc151";
|
|
451
451
|
rules += " Pc151";
|
|
452
452
|
rules += " _Yb151";
|