@zyncat/ui 0.19.0 → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/alert.css +1 -2
- package/dist/alert.js +6 -6
- package/dist/avatar.css +1 -1
- package/dist/badge.css +21 -12
- package/dist/badge.js +100 -2
- package/dist/badge.js.map +1 -1
- package/dist/{bloom-HV23M4AW.js → bloom-5MZXLNKG.js} +23 -5
- package/dist/bloom-5MZXLNKG.js.map +1 -0
- package/dist/button.css +1 -2
- package/dist/button.js +2 -2
- package/dist/checkbox.css +1 -1
- package/dist/{chunk-JINATP4N.js → chunk-2W7FOMWE.js} +7 -8
- package/dist/chunk-2W7FOMWE.js.map +1 -0
- package/dist/{chunk-LNAV5E7S.js → chunk-3HE7N3UK.js} +7 -3
- package/dist/chunk-3HE7N3UK.js.map +1 -0
- package/dist/{chunk-UKPX3RIP.js → chunk-47OMFFIB.js} +3 -3
- package/dist/{chunk-UKPX3RIP.js.map → chunk-47OMFFIB.js.map} +1 -1
- package/dist/chunk-4M5FMCFJ.js +16 -0
- package/dist/chunk-4M5FMCFJ.js.map +1 -0
- package/dist/chunk-6BY5G7BI.js +122 -0
- package/dist/chunk-6BY5G7BI.js.map +1 -0
- package/dist/{chunk-RLNCRDAL.js → chunk-AOEO2LCZ.js} +4 -4
- package/dist/{chunk-RLNCRDAL.js.map → chunk-AOEO2LCZ.js.map} +1 -1
- package/dist/{chunk-BRKGYLEQ.js → chunk-AQMR7ZYO.js} +8 -3
- package/dist/chunk-AQMR7ZYO.js.map +1 -0
- package/dist/{chunk-N43NDSME.js → chunk-AXZBD7LY.js} +6 -3
- package/dist/chunk-AXZBD7LY.js.map +1 -0
- package/dist/{chunk-V6QAAOA5.js → chunk-BWGK3OD6.js} +9 -6
- package/dist/chunk-BWGK3OD6.js.map +1 -0
- package/dist/{chunk-VQFILXQN.js → chunk-CYZKPUCG.js} +70 -8
- package/dist/chunk-CYZKPUCG.js.map +1 -0
- package/dist/{chunk-AIAPXRCI.js → chunk-DEZIQTBW.js} +176 -103
- package/dist/chunk-DEZIQTBW.js.map +1 -0
- package/dist/{tide-DJZMDAFT.js → chunk-DVLKB3CZ.js} +15 -12
- package/dist/chunk-DVLKB3CZ.js.map +1 -0
- package/dist/{chunk-F64Z42PJ.js → chunk-GM7IPTTT.js} +5 -6
- package/dist/chunk-GM7IPTTT.js.map +1 -0
- package/dist/chunk-ITW5UCVU.js +24 -0
- package/dist/chunk-ITW5UCVU.js.map +1 -0
- package/dist/{chunk-TDHLZY6I.js → chunk-JQZ3FTHP.js} +77 -18
- package/dist/chunk-JQZ3FTHP.js.map +1 -0
- package/dist/{chunk-PXQBJMPJ.js → chunk-LC6NQQER.js} +3 -3
- package/dist/{chunk-PXQBJMPJ.js.map → chunk-LC6NQQER.js.map} +1 -1
- package/dist/{chunk-M2KGLH2G.js → chunk-LV442ZOR.js} +10 -10
- package/dist/{chunk-M2KGLH2G.js.map → chunk-LV442ZOR.js.map} +1 -1
- package/dist/{chunk-F2TB3TT6.js → chunk-PNFFK5HY.js} +4 -4
- package/dist/{chunk-F2TB3TT6.js.map → chunk-PNFFK5HY.js.map} +1 -1
- package/dist/{chunk-2YGHPQ66.js → chunk-Q5N24VII.js} +2 -2
- package/dist/{chunk-2YGHPQ66.js.map → chunk-Q5N24VII.js.map} +1 -1
- package/dist/{chunk-XKDR22VE.js → chunk-SPFHWHJ6.js} +8 -4
- package/dist/chunk-SPFHWHJ6.js.map +1 -0
- package/dist/{chunk-TRPAKUIB.js → chunk-TBIY5YR5.js} +8 -8
- package/dist/{chunk-TRPAKUIB.js.map → chunk-TBIY5YR5.js.map} +1 -1
- package/dist/chunk-TXJQUN7C.js +108 -0
- package/dist/chunk-TXJQUN7C.js.map +1 -0
- package/dist/{chunk-VZXML7EH.js → chunk-V4ZN5RD4.js} +12 -3
- package/dist/chunk-V4ZN5RD4.js.map +1 -0
- package/dist/{chunk-VJXP256V.js → chunk-ZSP4ZTII.js} +7 -7
- package/dist/{chunk-VJXP256V.js.map → chunk-ZSP4ZTII.js.map} +1 -1
- package/dist/collapse.css +1 -1
- package/dist/confetti.css +1 -1
- package/dist/confetti.js +1 -1
- package/dist/crossfade-XFZLFLT7.js +91 -0
- package/dist/crossfade-XFZLFLT7.js.map +1 -0
- package/dist/date-field.js +20 -18
- package/dist/date-field.js.map +1 -1
- package/dist/date-picker.css +7 -8
- package/dist/date-range-field.js +22 -20
- package/dist/date-range-field.js.map +1 -1
- package/dist/datetime-field.js +21 -19
- package/dist/datetime-field.js.map +1 -1
- package/dist/dialog.css +1 -2
- package/dist/dialog.js +9 -9
- package/dist/digit-strip.css +1 -1
- package/dist/dropdown.css +13 -10
- package/dist/dropdown.js +37 -20
- package/dist/dropdown.js.map +1 -1
- package/dist/emoji-picker.js +14 -14
- package/dist/facebook-feed.css +1 -1
- package/dist/flow-field.css +1 -1
- package/dist/flow-field.js +1 -1
- package/dist/glide.js +2 -2
- package/dist/icon.css +1 -1
- package/dist/input.css +1 -4
- package/dist/instagram-feed.css +1 -1
- package/dist/instagram-feed.js +2 -2
- package/dist/lens.css +1 -1
- package/dist/lens.js +1 -1
- package/dist/menu-surface.css +82 -8
- package/dist/modal.css +1 -1
- package/dist/modal.js +8 -8
- package/dist/morphing-text.css +1 -1
- package/dist/morphing-text.js +1 -1
- package/dist/motion-devtools.css +1 -1
- package/dist/motion-devtools.js +3 -3
- package/dist/motion.js +9 -0
- package/dist/motion.js.map +1 -0
- package/dist/multi-select.js +34 -16
- package/dist/multi-select.js.map +1 -1
- package/dist/number-field.js +2 -2
- package/dist/odometer.css +17 -11
- package/dist/odometer.js +105 -72
- package/dist/odometer.js.map +1 -1
- package/dist/otp-field.js +17 -9
- package/dist/otp-field.js.map +1 -1
- package/dist/overlay.css +1 -1
- package/dist/pagination.css +1 -1
- package/dist/pagination.js +4 -4
- package/dist/{paint-CJQCM6ZO.js → paint-NLTI6TEF.js} +5 -3
- package/dist/paint-NLTI6TEF.js.map +1 -0
- package/dist/popover.css +1 -1
- package/dist/popover.js +9 -9
- package/dist/radio-group.css +11 -5
- package/dist/radio-group.js +5 -5
- package/dist/select.css +34 -8
- package/dist/select.js +25 -12
- package/dist/select.js.map +1 -1
- package/dist/sheet.css +1 -1
- package/dist/sheet.js +9 -9
- package/dist/spinner.css +1 -1
- package/dist/styles.css +1 -1
- package/dist/support-rail.css +7 -2
- package/dist/support-rail.js +11 -11
- package/dist/table.css +10 -5
- package/dist/table.js +7 -7
- package/dist/tabs.css +32 -7
- package/dist/tabs.js +55 -44
- package/dist/tabs.js.map +1 -1
- package/dist/tag.css +1 -1
- package/dist/tag.js +4 -4
- package/dist/textarea.css +14 -2
- package/dist/textarea.js +36 -23
- package/dist/textarea.js.map +1 -1
- package/dist/theme-grid.js +5 -5
- package/dist/theme-switcher.css +1 -2
- package/dist/theme-switcher.js +14 -14
- package/dist/{theme-transition-VGLPZDJI.js → theme-transition-FDF2REFD.js} +27 -7
- package/dist/theme-transition-FDF2REFD.js.map +1 -0
- package/dist/theme-transition.css +50 -1
- package/dist/theme.js +2 -2
- package/dist/theme.js.map +1 -1
- package/dist/tide-AGGMQEJV.js +4 -0
- package/dist/tide-AGGMQEJV.js.map +1 -0
- package/dist/tiktok.css +1 -1
- package/dist/tiktok.js +2 -2
- package/dist/time-field.js +5 -3
- package/dist/time-field.js.map +1 -1
- package/dist/toast.css +1 -1
- package/dist/toast.js +7 -7
- package/dist/toggle-tag.js +2 -2
- package/dist/toggle.css +1 -1
- package/dist/toggle.js +4 -15
- package/dist/toggle.js.map +1 -1
- package/dist/tooltip.css +1 -1
- package/dist/tooltip.js +6 -7
- package/dist/tooltip.js.map +1 -1
- package/dist/trigger.css +1 -2
- package/dist/types/components/composites/date-picker/DateField.d.ts +1 -1
- package/dist/types/components/composites/date-picker/DateRangeField.d.ts +1 -1
- package/dist/types/components/composites/date-picker/DateTimeField.d.ts +1 -1
- package/dist/types/components/composites/date-picker/TimeField.d.ts +1 -1
- package/dist/types/components/composites/date-picker/field-shell.d.ts +5 -1
- package/dist/types/components/composites/dropdown/Dropdown.d.ts +13 -2
- package/dist/types/components/composites/dropdown/types.d.ts +5 -2
- package/dist/types/components/composites/select/MultiSelect.d.ts +23 -3
- package/dist/types/components/composites/select/Select.d.ts +20 -4
- package/dist/types/components/composites/select/core/index.d.ts +2 -1
- package/dist/types/components/composites/select/core/menu.d.ts +8 -5
- package/dist/types/components/composites/select/core/panel.d.ts +6 -4
- package/dist/types/components/composites/select/core/trigger.d.ts +7 -2
- package/dist/types/components/composites/select/core/types.d.ts +9 -0
- package/dist/types/components/composites/select/core/use-listbox.d.ts +5 -3
- package/dist/types/components/composites/tabs/Tabs.d.ts +6 -1
- package/dist/types/components/expressive/odometer/Odometer.d.ts +1 -1
- package/dist/types/components/expressive/odometer/roll.d.ts +20 -0
- package/dist/types/components/expressive/theme-transition/scene.d.ts +3 -0
- package/dist/types/components/internal/menu/highlight.d.ts +9 -1
- package/dist/types/components/internal/menu/menu-row.d.ts +4 -0
- package/dist/types/components/internal/menu/use-anchor-width.d.ts +2 -0
- package/dist/types/components/internal/overlay/layer.d.ts +5 -8
- package/dist/types/components/internal/overlay/track-anchor.d.ts +5 -0
- package/dist/types/components/internal/utils/activation.d.ts +1 -0
- package/dist/types/components/primitives/badge/Badge.d.ts +17 -8
- package/dist/types/components/primitives/badge/morph-label.d.ts +3 -0
- package/dist/types/components/primitives/badge/use-glint-on-change.d.ts +2 -0
- package/dist/types/components/primitives/input/OtpField.d.ts +2 -2
- package/dist/types/components/primitives/textarea/Textarea.d.ts +2 -2
- package/dist/types/components/primitives/textarea/char-meter.d.ts +6 -0
- package/dist/types/components/primitives/toggle/switch-glyph.d.ts +6 -0
- package/dist/types/motion/crossfade.d.ts +3 -0
- package/dist/types/motion/element.d.ts +6 -3
- package/dist/types/motion/flip.d.ts +8 -2
- package/dist/types/motion/motion.d.ts +7 -0
- package/dist/types/theme-scope.d.ts +5 -0
- package/dist/types/tokens/component-styles.generated.d.ts +0 -2
- package/dist/types/tokens/theme-tokens.generated.d.ts +38 -32
- package/dist/typing-lines.css +1 -1
- package/dist/typing-lines.js +1 -1
- package/dist/weight-field.css +1 -1
- package/dist/youtube.css +1 -1
- package/dist/youtube.js +2 -2
- package/package.json +6 -11
- package/skills/zyncat-ui/SKILL.md +2 -2
- package/skills/zyncat-ui/references/components.md +3 -4
- package/skills/zyncat-ui/references/theming.md +3 -3
- package/src/components/composites/alert/alert.css +1 -2
- package/src/components/composites/date-picker/DateField.tsx +2 -0
- package/src/components/composites/date-picker/DateRangeField.tsx +2 -0
- package/src/components/composites/date-picker/DateTimeField.tsx +2 -0
- package/src/components/composites/date-picker/TimeField.tsx +2 -0
- package/src/components/composites/date-picker/date-picker.css +7 -8
- package/src/components/composites/date-picker/field-shell.tsx +14 -1
- package/src/components/composites/dialog/dialog.css +1 -2
- package/src/components/composites/dropdown/Dropdown.tsx +20 -3
- package/src/components/composites/dropdown/Dropdown.usage.md +2 -0
- package/src/components/composites/dropdown/dropdown.css +13 -10
- package/src/components/composites/dropdown/menu-panel.tsx +28 -13
- package/src/components/composites/dropdown/types.ts +5 -2
- package/src/components/composites/emoji-picker/styles.css +1 -1
- package/src/components/composites/modal/modal.css +1 -1
- package/src/components/composites/pagination/pagination.css +1 -1
- package/src/components/composites/popover/popover.css +1 -1
- package/src/components/composites/select/MultiSelect.tsx +56 -5
- package/src/components/composites/select/MultiSelect.usage.md +10 -0
- package/src/components/composites/select/Select.tsx +32 -2
- package/src/components/composites/select/Select.usage.md +13 -1
- package/src/components/composites/select/core/index.ts +2 -1
- package/src/components/composites/select/core/menu.tsx +28 -15
- package/src/components/composites/select/core/panel.tsx +57 -52
- package/src/components/composites/select/core/trigger.tsx +44 -11
- package/src/components/composites/select/core/types.ts +10 -0
- package/src/components/composites/select/core/use-listbox.ts +77 -31
- package/src/components/composites/select/select.css +34 -8
- package/src/components/composites/sheet/sheet.css +1 -1
- package/src/components/composites/table/table.css +10 -5
- package/src/components/composites/tabs/Tabs.tsx +13 -1
- package/src/components/composites/tabs/tabs.css +32 -7
- package/src/components/composites/theme-switcher/theme-switcher.css +1 -2
- package/src/components/composites/toast/toast.css +1 -1
- package/src/components/composites/tooltip/tooltip-host.tsx +1 -1
- package/src/components/composites/tooltip/tooltip.css +1 -1
- package/src/components/compound/support-rail/support-rail.css +7 -2
- package/src/components/dev/motion-devtools.css +1 -1
- package/src/components/expressive/confetti/confetti.css +1 -1
- package/src/components/expressive/facebook-feed/facebook-feed.css +1 -1
- package/src/components/expressive/flow-field/flow-field.css +1 -1
- package/src/components/expressive/instagram-feed/instagram-feed.css +1 -1
- package/src/components/expressive/lens/lens.css +1 -1
- package/src/components/expressive/morphing-text/morphing-text.css +1 -1
- package/src/components/expressive/odometer/Odometer.tsx +45 -92
- package/src/components/expressive/odometer/Odometer.usage.md +2 -2
- package/src/components/expressive/odometer/odometer.css +17 -11
- package/src/components/expressive/odometer/roll.ts +94 -0
- package/src/components/expressive/theme-transition/bloom.ts +22 -2
- package/src/components/expressive/theme-transition/paint.ts +2 -0
- package/src/components/expressive/theme-transition/scene.ts +3 -0
- package/src/components/expressive/theme-transition/theme-transition.css +50 -1
- package/src/components/expressive/theme-transition/theme-transition.ts +21 -1
- package/src/components/expressive/theme-transition/tide.ts +15 -10
- package/src/components/expressive/tiktok/tiktok.css +1 -1
- package/src/components/expressive/typing-lines/typing-lines.css +1 -1
- package/src/components/expressive/weight-field/weight-field.css +1 -1
- package/src/components/expressive/youtube/youtube.css +1 -1
- package/src/components/internal/glass/glass.css +1 -1
- package/src/components/internal/icon/icon.css +1 -1
- package/src/components/internal/menu/highlight.ts +20 -2
- package/src/components/internal/menu/menu-row.tsx +36 -8
- package/src/components/internal/menu/menu-surface.css +82 -8
- package/src/components/internal/menu/use-anchor-width.ts +26 -0
- package/src/components/internal/overlay/layer.tsx +11 -23
- package/src/components/internal/overlay/overlay.css +1 -1
- package/src/components/internal/overlay/position.ts +17 -6
- package/src/components/internal/overlay/track-anchor.ts +69 -0
- package/src/components/internal/overlay/trigger.css +1 -2
- package/src/components/internal/utils/activation.ts +5 -0
- package/src/components/primitives/avatar/avatar.css +1 -1
- package/src/components/primitives/badge/Badge.tsx +38 -15
- package/src/components/primitives/badge/Badge.usage.md +12 -5
- package/src/components/primitives/badge/badge.css +21 -12
- package/src/components/primitives/badge/digit-strip.css +1 -1
- package/src/components/primitives/badge/morph-label.tsx +71 -0
- package/src/components/primitives/badge/use-glint-on-change.ts +16 -0
- package/src/components/primitives/button/button.css +1 -2
- package/src/components/primitives/checkbox/checkbox.css +1 -1
- package/src/components/primitives/collapse/collapse.css +1 -1
- package/src/components/primitives/input/OtpField.tsx +17 -9
- package/src/components/primitives/input/input.css +1 -4
- package/src/components/primitives/radio-group/radio-group.css +11 -5
- package/src/components/primitives/spinner/spinner.css +1 -1
- package/src/components/primitives/tag/tag.css +1 -1
- package/src/components/primitives/textarea/Textarea.tsx +20 -24
- package/src/components/primitives/textarea/char-meter.tsx +34 -0
- package/src/components/primitives/textarea/textarea.css +14 -2
- package/src/components/primitives/toggle/Toggle.tsx +3 -12
- package/src/components/primitives/toggle/switch-glyph.tsx +25 -0
- package/src/components/primitives/toggle/toggle.css +1 -1
- package/src/engine/flip.ts +5 -1
- package/src/motion/crossfade.ts +97 -0
- package/src/motion/element.tsx +10 -7
- package/src/motion/flip.ts +62 -23
- package/src/motion/glide.tsx +5 -0
- package/src/motion/motion.ts +7 -0
- package/src/motion/motion.usage.md +34 -0
- package/src/motion/presence.tsx +4 -0
- package/src/motion/use-motion.ts +8 -3
- package/src/styles.css +1 -1
- package/src/theme-scope.ts +19 -0
- package/src/tokens/base.css +62 -13
- package/src/tokens/color.css +18 -16
- package/src/tokens/component-styles.generated.ts +0 -2
- package/src/tokens/dark.css +4 -1
- package/src/tokens/decisions.css +6 -4
- package/src/tokens/elevation.css +1 -1
- package/src/tokens/glass.css +1 -1
- package/src/tokens/motion.css +4 -4
- package/src/tokens/radius.css +1 -1
- package/src/tokens/reset.css +17 -45
- package/src/tokens/semantic.css +13 -7
- package/src/tokens/spacing.css +4 -4
- package/src/tokens/theme-tokens.generated.ts +38 -32
- package/src/tokens/typography.css +1 -1
- package/tailwind.css +3 -1
- package/dist/bloom-HV23M4AW.js.map +0 -1
- package/dist/chunk-2DNKZ57E.js +0 -72
- package/dist/chunk-2DNKZ57E.js.map +0 -1
- package/dist/chunk-AIAPXRCI.js.map +0 -1
- package/dist/chunk-BRKGYLEQ.js.map +0 -1
- package/dist/chunk-F64Z42PJ.js.map +0 -1
- package/dist/chunk-JINATP4N.js.map +0 -1
- package/dist/chunk-LNAV5E7S.js.map +0 -1
- package/dist/chunk-N43NDSME.js.map +0 -1
- package/dist/chunk-RJENXXTI.js +0 -93
- package/dist/chunk-RJENXXTI.js.map +0 -1
- package/dist/chunk-RW2A4M2Q.js +0 -57
- package/dist/chunk-RW2A4M2Q.js.map +0 -1
- package/dist/chunk-TDHLZY6I.js.map +0 -1
- package/dist/chunk-V6QAAOA5.js.map +0 -1
- package/dist/chunk-VDOBLABP.js +0 -38
- package/dist/chunk-VDOBLABP.js.map +0 -1
- package/dist/chunk-VQFILXQN.js.map +0 -1
- package/dist/chunk-VZXML7EH.js.map +0 -1
- package/dist/chunk-XKDR22VE.js.map +0 -1
- package/dist/count-badge.js +0 -13
- package/dist/count-badge.js.map +0 -1
- package/dist/paint-CJQCM6ZO.js.map +0 -1
- package/dist/status-badge.js +0 -72
- package/dist/status-badge.js.map +0 -1
- package/dist/theme-transition-VGLPZDJI.js.map +0 -1
- package/dist/tide-DJZMDAFT.js.map +0 -1
- package/dist/types/components/primitives/badge/CountBadge.d.ts +0 -8
- package/dist/types/components/primitives/badge/StatusBadge.d.ts +0 -15
- package/src/components/primitives/badge/CountBadge.tsx +0 -20
- package/src/components/primitives/badge/CountBadge.usage.md +0 -13
- package/src/components/primitives/badge/StatusBadge.tsx +0 -113
- package/src/components/primitives/badge/StatusBadge.usage.md +0 -14
package/dist/select.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@layer zyncat.reset, zyncat.tokens, zyncat.components;
|
|
1
|
+
@layer zyncat.reset, zyncat.tokens, zyncat.base, zyncat.components;
|
|
2
2
|
|
|
3
3
|
@layer zyncat.components {
|
|
4
4
|
.zc-select {
|
|
@@ -8,6 +8,10 @@
|
|
|
8
8
|
font-family: var(--font-body);
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
+
.zc-select[data-custom-trigger='true'] {
|
|
12
|
+
width: auto;
|
|
13
|
+
}
|
|
14
|
+
|
|
11
15
|
.zc-select__trigger {
|
|
12
16
|
appearance: none;
|
|
13
17
|
margin: 0;
|
|
@@ -33,7 +37,6 @@
|
|
|
33
37
|
border-color var(--duration-base) var(--ease-standard),
|
|
34
38
|
box-shadow var(--duration-base) var(--ease-standard),
|
|
35
39
|
outline-color var(--duration-base) var(--ease-standard);
|
|
36
|
-
outline: var(--ring-rest);
|
|
37
40
|
}
|
|
38
41
|
.zc-select__trigger:hover {
|
|
39
42
|
border-color: var(--border-strong);
|
|
@@ -47,7 +50,6 @@
|
|
|
47
50
|
.zc-select[data-open='true'] .zc-select__trigger {
|
|
48
51
|
border-color: var(--accent);
|
|
49
52
|
background: var(--bg-surface);
|
|
50
|
-
outline: var(--ring-accent);
|
|
51
53
|
}
|
|
52
54
|
|
|
53
55
|
.zc-select[data-size='sm'] .zc-select__trigger {
|
|
@@ -65,11 +67,13 @@
|
|
|
65
67
|
.zc-select[data-invalid='true'] .zc-select__trigger {
|
|
66
68
|
border-color: var(--danger);
|
|
67
69
|
}
|
|
68
|
-
.zc-select[data-invalid='true'] .zc-select__trigger:focus-visible
|
|
69
|
-
.zc-select[data-invalid='true'][data-open='true'] .zc-select__trigger {
|
|
70
|
+
.zc-select[data-invalid='true'] .zc-select__trigger:focus-visible {
|
|
70
71
|
border-color: var(--danger);
|
|
71
72
|
outline: var(--ring-danger);
|
|
72
73
|
}
|
|
74
|
+
.zc-select[data-invalid='true'][data-open='true'] .zc-select__trigger {
|
|
75
|
+
border-color: var(--danger);
|
|
76
|
+
}
|
|
73
77
|
|
|
74
78
|
.zc-select[data-disabled='true'] .zc-select__trigger {
|
|
75
79
|
cursor: not-allowed;
|
|
@@ -159,9 +163,25 @@
|
|
|
159
163
|
color: var(--text-disabled);
|
|
160
164
|
}
|
|
161
165
|
|
|
166
|
+
.zc-select__menu[data-size='sm'] .zc-select__search {
|
|
167
|
+
padding: var(--space-1) var(--space-2);
|
|
168
|
+
gap: var(--space-1);
|
|
169
|
+
}
|
|
170
|
+
.zc-select__menu[data-size='sm'] .zc-select__search-input {
|
|
171
|
+
font-size: var(--size-caption);
|
|
172
|
+
line-height: var(--leading-caption);
|
|
173
|
+
}
|
|
174
|
+
.zc-select__menu[data-size='lg'] .zc-select__search {
|
|
175
|
+
padding: var(--space-3);
|
|
176
|
+
}
|
|
177
|
+
|
|
162
178
|
.zc-select__list {
|
|
163
179
|
position: relative;
|
|
164
180
|
scroll-behavior: smooth;
|
|
181
|
+
scroll-padding-block: var(--space-1);
|
|
182
|
+
}
|
|
183
|
+
.zc-select__list[data-grouped='true'] {
|
|
184
|
+
scroll-padding-top: calc(var(--menu-group-label-height) + var(--space-1));
|
|
165
185
|
}
|
|
166
186
|
|
|
167
187
|
.zc-select__group-label {
|
|
@@ -233,19 +253,25 @@
|
|
|
233
253
|
.zc-select__menu[data-multiple='true'] .zc-select__option-check {
|
|
234
254
|
opacity: 1;
|
|
235
255
|
}
|
|
236
|
-
.zc-select__menu[data-multiple='true'] .zc-select__option .zc-cbx {
|
|
256
|
+
.zc-select__menu[data-multiple='true'] .zc-select__option :is(.zc-cbx, .zc-sw) {
|
|
237
257
|
padding: 0;
|
|
238
258
|
gap: 0;
|
|
239
259
|
pointer-events: none;
|
|
240
260
|
}
|
|
241
|
-
.zc-select__menu[data-multiple='true'] .zc-select__option .zc-cbx__box {
|
|
261
|
+
.zc-select__menu[data-multiple='true'] .zc-select__option :is(.zc-cbx__box, .zc-sw__track) {
|
|
242
262
|
margin-top: 0;
|
|
243
263
|
}
|
|
244
264
|
|
|
245
|
-
/*
|
|
265
|
+
/* The glyph is pointer-events: none, so its own :active never fires; the row dips it */
|
|
246
266
|
.zc-select__menu[data-multiple='true'] .zc-select__option:active:not([data-disabled='true']) .zc-cbx__box {
|
|
247
267
|
transform: scale(0.86);
|
|
248
268
|
}
|
|
269
|
+
.zc-select__menu[data-multiple='true'] .zc-select__option:active:not([data-disabled='true']) .zc-sw__track {
|
|
270
|
+
transform: scale(0.96);
|
|
271
|
+
}
|
|
272
|
+
.zc-select__menu[data-multiple='true'] .zc-select__option:active:not([data-disabled='true']) .zc-sw__thumb {
|
|
273
|
+
--sw-sx: 1.16;
|
|
274
|
+
}
|
|
249
275
|
.zc-select__empty {
|
|
250
276
|
padding: var(--space-4) var(--space-3);
|
|
251
277
|
text-align: center;
|
package/dist/select.js
CHANGED
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
'use client';import { useListbox, SelectTrigger, ListboxPanel } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
import './chunk-
|
|
1
|
+
'use client';import { useListbox, SelectTrigger, ListboxPanel } from './chunk-DEZIQTBW.js';
|
|
2
|
+
import './chunk-TXJQUN7C.js';
|
|
3
|
+
import './chunk-CYZKPUCG.js';
|
|
4
4
|
import './chunk-TP2AC5MQ.js';
|
|
5
|
-
import './chunk-
|
|
6
|
-
import './chunk-
|
|
7
|
-
import './chunk-
|
|
5
|
+
import './chunk-JQZ3FTHP.js';
|
|
6
|
+
import './chunk-4M5FMCFJ.js';
|
|
7
|
+
import './chunk-3HE7N3UK.js';
|
|
8
|
+
import './chunk-AQMR7ZYO.js';
|
|
9
|
+
import './chunk-AXZBD7LY.js';
|
|
8
10
|
import './chunk-C3D32LE3.js';
|
|
9
|
-
import './chunk-
|
|
10
|
-
import './chunk-
|
|
11
|
-
import './chunk-
|
|
11
|
+
import './chunk-6BY5G7BI.js';
|
|
12
|
+
import './chunk-BWGK3OD6.js';
|
|
13
|
+
import './chunk-SPFHWHJ6.js';
|
|
12
14
|
import './chunk-VNVVG47J.js';
|
|
13
|
-
import { useControllable } from './chunk-MMRIQNEN.js';
|
|
14
15
|
import './chunk-WCWV5IX6.js';
|
|
15
|
-
import './chunk-TBLPZQSI.js';
|
|
16
16
|
import './chunk-6H3IJ752.js';
|
|
17
|
-
import './chunk-
|
|
17
|
+
import './chunk-TBLPZQSI.js';
|
|
18
|
+
import { useControllable } from './chunk-MMRIQNEN.js';
|
|
18
19
|
import './chunk-DMX2F6B4.js';
|
|
19
20
|
import { cx } from './chunk-QGNC7LH5.js';
|
|
20
21
|
import './select.css';
|
|
@@ -27,6 +28,7 @@ function Select({
|
|
|
27
28
|
onChange,
|
|
28
29
|
placeholder = "Select an option",
|
|
29
30
|
size = "md",
|
|
31
|
+
menuSize = size,
|
|
30
32
|
disabled = false,
|
|
31
33
|
invalid = false,
|
|
32
34
|
loading = false,
|
|
@@ -34,13 +36,17 @@ function Select({
|
|
|
34
36
|
searchPlaceholder = "Filter options",
|
|
35
37
|
highlight = "neutral",
|
|
36
38
|
rail = false,
|
|
39
|
+
weight = "medium",
|
|
40
|
+
width = "trigger",
|
|
37
41
|
leadingIcon = null,
|
|
38
42
|
id,
|
|
39
43
|
ariaLabel,
|
|
40
44
|
htmlProps,
|
|
45
|
+
menuProps,
|
|
41
46
|
activateOn = "pointerdown",
|
|
42
47
|
animation,
|
|
43
48
|
triggerProps,
|
|
49
|
+
trigger,
|
|
44
50
|
showCheck = true
|
|
45
51
|
}) {
|
|
46
52
|
const [value, setValue] = useControllable(controlledValue, defaultValue, onChange);
|
|
@@ -57,12 +63,14 @@ function Select({
|
|
|
57
63
|
});
|
|
58
64
|
const selected = lb.flat.find((o) => o.value === value) || null;
|
|
59
65
|
const isPlaceholder = !loading && !selected;
|
|
66
|
+
const customTrigger = typeof trigger === "function" ? trigger({ open: lb.open, selected }) : trigger;
|
|
60
67
|
return /* @__PURE__ */ jsxs(
|
|
61
68
|
"div",
|
|
62
69
|
{
|
|
63
70
|
...htmlProps,
|
|
64
71
|
className: cx("zc-select", htmlProps?.className),
|
|
65
72
|
"data-size": size,
|
|
73
|
+
"data-custom-trigger": customTrigger ? "true" : void 0,
|
|
66
74
|
"data-open": lb.open ? "true" : void 0,
|
|
67
75
|
"data-disabled": disabled ? "true" : void 0,
|
|
68
76
|
"data-invalid": invalid ? "true" : void 0,
|
|
@@ -72,6 +80,7 @@ function Select({
|
|
|
72
80
|
SelectTrigger,
|
|
73
81
|
{
|
|
74
82
|
lb,
|
|
83
|
+
node: customTrigger,
|
|
75
84
|
disabled,
|
|
76
85
|
invalid,
|
|
77
86
|
ariaLabel,
|
|
@@ -92,8 +101,12 @@ function Select({
|
|
|
92
101
|
ariaLabel,
|
|
93
102
|
highlight,
|
|
94
103
|
rail,
|
|
104
|
+
size: menuSize,
|
|
105
|
+
weight,
|
|
106
|
+
width,
|
|
95
107
|
activateOn,
|
|
96
108
|
animation,
|
|
109
|
+
menuProps,
|
|
97
110
|
...!showCheck && { check: () => null }
|
|
98
111
|
}
|
|
99
112
|
)
|
package/dist/select.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/composites/select/Select.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/components/composites/select/Select.tsx"],"names":[],"mappings":"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","file":"select.js","sourcesContent":["'use client';\n\nimport './select.css';\n\nimport type { HTMLAttributes, ReactNode } from 'react';\n\nimport type { DataAttributes } from '../../../dom-props';\nimport type { DisableableAnimation } from '../../../motion/timing';\nimport { useControllable } from '../../internal/hooks/use-controllable';\nimport type { MenuSize, MenuWeight, MenuWidth } from '../../internal/menu/highlight';\nimport type { ActivateOn } from '../../internal/utils/activation';\nimport { cx } from '../../internal/utils/cx';\nimport {\n ListboxPanel,\n SelectTrigger,\n useListbox,\n type CustomTrigger,\n type SelectGroup,\n type SelectMenuHtmlProps,\n type SelectOption,\n type SelectTriggerHtmlProps,\n} from './core';\n\nexport type { SelectOption, SelectGroup } from './core';\n\nexport interface SelectProps {\n /** The choices - a flat `SelectOption[]`, or `SelectGroup[]` to render labeled sections. @default [] */\n options: SelectOption[] | SelectGroup[];\n /** Controlled value - matches an option's `value`, or `null` for none. Omit for uncontrolled (use `defaultValue`). */\n value?: string | null;\n /** Initial value when uncontrolled. @default null */\n defaultValue?: string | null;\n /** Fires on commit - gets the new `value` and its full `SelectOption`. Committing closes the menu. */\n onChange?: (value: string, option: SelectOption) => void;\n /** Trigger text when nothing is selected. @default 'Select an option' */\n placeholder?: string;\n /** Trigger height, type and padding. The menu follows it unless `menuSize` overrides. @default 'md' */\n size?: 'sm' | 'md' | 'lg';\n /** Menu density on its own - row type, row padding and the filter field. A row carrying a\n * description sits one step taller than a plain one at every step. @default the `size` value */\n menuSize?: MenuSize;\n /** Weight of every option label in the menu. @default 'medium' */\n weight?: MenuWeight;\n /** Menu width. `trigger` is never narrower than the trigger, `auto` fits the options, and\n * `sm` | `md` | `lg` are fixed steps with long labels ellipsizing. @default 'trigger' */\n width?: MenuWidth;\n /** Disabled - trigger is inert and the menu cannot open. @default false */\n disabled?: boolean;\n /** Danger ring + border. @default false */\n invalid?: boolean;\n /** Skeleton rows in the menu; trigger reads \"Loading...\". @default false */\n loading?: boolean;\n /** Type-to-filter field pinned above the list. @default false */\n searchable?: boolean;\n /** Placeholder for the `searchable` filter input. @default 'Filter options' */\n searchPlaceholder?: string;\n /** Hue of the highlight that travels between options: the neutral wash, or the accent wash with\n * accent ink on the active option. @default 'neutral' */\n highlight?: 'neutral' | 'accent';\n /** Short accent bar on the leading edge of the highlight, marking the active option. @default false */\n rail?: boolean;\n /** Your own icon node pinned before the trigger label; else the selected option's icon. */\n leadingIcon?: ReactNode;\n /** Base id for the trigger/menu/list ids and a11y wiring; auto-generated if omitted. */\n id?: string;\n /** Accessible name for the trigger and listbox - supply when there is no visible label. */\n ariaLabel?: string;\n /** Standard <div> attributes (className, style, data-*, ...) forwarded to the select root. */\n htmlProps?: HTMLAttributes<HTMLDivElement> & DataAttributes;\n /** Standard attributes (className, style, data-*, ...) forwarded to the menu panel, which portals\n * to <body> and inherits nothing from the root. */\n menuProps?: SelectMenuHtmlProps;\n /** Whether the trigger and the options fire on `pointerdown` (snappier) or wait for `click`.\n * @default 'pointerdown' */\n activateOn?: ActivateOn;\n /** Menu open/close timing - motion tokens only, or `null` to disable. @default duration 'base' + ease 'entrance'/'exit' */\n animation?: DisableableAnimation;\n /** Standard <button> attributes (className, style, aria-*, data-*, ...) merged onto the trigger.\n * `onClick` and `onKeyDown` run before the built-in open/close and arrow-key handling, which\n * cannot be replaced - the trigger is the combobox. Ignored when `trigger` replaces it. */\n triggerProps?: SelectTriggerHtmlProps;\n /** Your own element in place of the built-in trigger. It is cloned with the combobox wiring - role,\n * aria, open/close, arrow keys, and the anchor the menu measures - so it must render one focusable\n * element that forwards its props and ref. Pass a function to read `{ open, selected }`. */\n trigger?: CustomTrigger<SelectOption | null>;\n /** Show check icon on selected value */\n showCheck?: boolean;\n}\n\nexport function Select({\n options = [],\n value: controlledValue,\n defaultValue = null,\n onChange,\n placeholder = 'Select an option',\n size = 'md',\n menuSize = size,\n disabled = false,\n invalid = false,\n loading = false,\n searchable = false,\n searchPlaceholder = 'Filter options',\n highlight = 'neutral',\n rail = false,\n weight = 'medium',\n width = 'trigger',\n leadingIcon = null,\n id,\n ariaLabel,\n htmlProps,\n menuProps,\n activateOn = 'pointerdown',\n animation,\n triggerProps,\n trigger,\n showCheck = true,\n}: SelectProps) {\n const [value, setValue] = useControllable<string | null, SelectOption>(controlledValue, defaultValue, onChange);\n\n const lb = useListbox({\n options,\n disabled,\n loading,\n searchable,\n id,\n idPrefix: 'select-',\n isSelected: (v) => v === value && value != null,\n onCommit: (opt) => setValue(opt.value, opt),\n closeOnCommit: true,\n });\n\n const selected = lb.flat.find((o) => o.value === value) || null;\n const isPlaceholder = !loading && !selected;\n const customTrigger = typeof trigger === 'function' ? trigger({ open: lb.open, selected }) : trigger;\n\n return (\n <div\n {...htmlProps}\n className={cx('zc-select', htmlProps?.className)}\n data-size={size}\n data-custom-trigger={customTrigger ? 'true' : undefined}\n data-open={lb.open ? 'true' : undefined}\n data-disabled={disabled ? 'true' : undefined}\n data-invalid={invalid ? 'true' : undefined}\n data-loading={loading ? 'true' : undefined}\n >\n <SelectTrigger\n lb={lb}\n node={customTrigger}\n disabled={disabled}\n invalid={invalid}\n ariaLabel={ariaLabel}\n leading={leadingIcon || (selected && selected.icon) || null}\n text={loading ? 'Loading...' : isPlaceholder ? placeholder : selected.label}\n isPlaceholder={isPlaceholder}\n activateOn={activateOn}\n {...triggerProps}\n />\n <ListboxPanel\n lb={lb}\n loading={loading}\n searchable={searchable}\n searchPlaceholder={searchPlaceholder}\n ariaLabel={ariaLabel}\n highlight={highlight}\n rail={rail}\n size={menuSize}\n weight={weight}\n width={width}\n activateOn={activateOn}\n animation={animation}\n menuProps={menuProps}\n {...(!showCheck && { check: () => null })}\n />\n </div>\n );\n}\n"]}
|
package/dist/sheet.css
CHANGED
package/dist/sheet.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
'use client';export { Sheet } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
import './chunk-
|
|
4
|
-
import './chunk-
|
|
5
|
-
import './chunk-
|
|
1
|
+
'use client';export { Sheet } from './chunk-ZSP4ZTII.js';
|
|
2
|
+
import './chunk-GM7IPTTT.js';
|
|
3
|
+
import './chunk-JQZ3FTHP.js';
|
|
4
|
+
import './chunk-4M5FMCFJ.js';
|
|
5
|
+
import './chunk-3HE7N3UK.js';
|
|
6
|
+
import './chunk-AXZBD7LY.js';
|
|
6
7
|
import './chunk-C3D32LE3.js';
|
|
7
|
-
import './chunk-
|
|
8
|
-
import './chunk-
|
|
9
|
-
import './chunk-XKDR22VE.js';
|
|
8
|
+
import './chunk-BWGK3OD6.js';
|
|
9
|
+
import './chunk-SPFHWHJ6.js';
|
|
10
10
|
import './chunk-VNVVG47J.js';
|
|
11
|
-
import './chunk-MMRIQNEN.js';
|
|
12
11
|
import './chunk-6H3IJ752.js';
|
|
12
|
+
import './chunk-MMRIQNEN.js';
|
|
13
13
|
import './chunk-DMX2F6B4.js';
|
|
14
14
|
import './chunk-QGNC7LH5.js';
|
|
15
15
|
//# sourceMappingURL=sheet.js.map
|
package/dist/spinner.css
CHANGED
package/dist/styles.css
CHANGED
package/dist/support-rail.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@layer zyncat.reset, zyncat.tokens, zyncat.components;
|
|
1
|
+
@layer zyncat.reset, zyncat.tokens, zyncat.base, zyncat.components;
|
|
2
2
|
|
|
3
3
|
@layer zyncat.components {
|
|
4
4
|
.zc-support-rail {
|
|
@@ -60,6 +60,8 @@
|
|
|
60
60
|
box-shadow: var(--shadow-md);
|
|
61
61
|
pointer-events: auto;
|
|
62
62
|
translate: 0 -50%;
|
|
63
|
+
outline: var(--ring-rest);
|
|
64
|
+
transition: outline-color var(--duration-fast) var(--ease-standard);
|
|
63
65
|
}
|
|
64
66
|
|
|
65
67
|
.zc-support-rail[data-side='right'] .zc-support-rail__shell {
|
|
@@ -167,6 +169,8 @@
|
|
|
167
169
|
margin-inline: calc(var(--ring-gutter) * -1);
|
|
168
170
|
padding: var(--ring-gutter);
|
|
169
171
|
scroll-padding: var(--ring-gutter);
|
|
172
|
+
outline: var(--ring-rest);
|
|
173
|
+
transition: outline-color var(--duration-fast) var(--ease-standard);
|
|
170
174
|
}
|
|
171
175
|
.zc-support-rail__scroll:focus-visible {
|
|
172
176
|
outline: var(--focus-ring);
|
|
@@ -196,7 +200,8 @@
|
|
|
196
200
|
cursor: pointer;
|
|
197
201
|
transition:
|
|
198
202
|
background-color var(--duration-base) var(--ease-standard),
|
|
199
|
-
padding var(--duration-slow) var(--ease-standard)
|
|
203
|
+
padding var(--duration-slow) var(--ease-standard),
|
|
204
|
+
outline-color var(--duration-fast) var(--ease-standard);
|
|
200
205
|
}
|
|
201
206
|
.zc-support-rail__row:hover {
|
|
202
207
|
background: var(--neutral-wash);
|
package/dist/support-rail.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
'use client';import { useReturnFocus } from './chunk-
|
|
2
|
-
import
|
|
3
|
-
import './chunk-
|
|
1
|
+
'use client';import { useOverlayEntry, useOutsidePress, useReturnFocus } from './chunk-JQZ3FTHP.js';
|
|
2
|
+
import './chunk-4M5FMCFJ.js';
|
|
3
|
+
import './chunk-3HE7N3UK.js';
|
|
4
|
+
import { Presence } from './chunk-AXZBD7LY.js';
|
|
4
5
|
import { resolveMotionTiming } from './chunk-C3D32LE3.js';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { animate } from './chunk-XKDR22VE.js';
|
|
6
|
+
import { Motion } from './chunk-6BY5G7BI.js';
|
|
7
|
+
import { usePresence } from './chunk-BWGK3OD6.js';
|
|
8
|
+
import { animate } from './chunk-SPFHWHJ6.js';
|
|
9
9
|
import './chunk-VNVVG47J.js';
|
|
10
|
-
import {
|
|
11
|
-
import { Icon } from './chunk-TBLPZQSI.js';
|
|
12
|
-
import { Button } from './chunk-RLNCRDAL.js';
|
|
13
|
-
import { buttonClass } from './chunk-KSAJ6DED.js';
|
|
10
|
+
import { Button } from './chunk-AOEO2LCZ.js';
|
|
14
11
|
import './chunk-NYQQH4R5.js';
|
|
12
|
+
import { buttonClass } from './chunk-KSAJ6DED.js';
|
|
15
13
|
import { UIMotion } from './chunk-6H3IJ752.js';
|
|
14
|
+
import { Icon } from './chunk-TBLPZQSI.js';
|
|
15
|
+
import { useControllable } from './chunk-MMRIQNEN.js';
|
|
16
16
|
import './chunk-DMX2F6B4.js';
|
|
17
17
|
import { cx } from './chunk-QGNC7LH5.js';
|
|
18
18
|
import './support-rail.css';
|
package/dist/table.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@layer zyncat.reset, zyncat.tokens, zyncat.components;
|
|
1
|
+
@layer zyncat.reset, zyncat.tokens, zyncat.base, zyncat.components;
|
|
2
2
|
|
|
3
3
|
@layer zyncat.components {
|
|
4
4
|
.zc-tbl,
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
}
|
|
8
8
|
|
|
9
9
|
.zc-tbl {
|
|
10
|
+
--_tbl-row-hover: color-mix(in oklab, var(--bg-subtle) 55%, var(--bg-surface));
|
|
10
11
|
--tbl-pad-y: var(--space-3);
|
|
11
12
|
--tbl-head-py: var(--space-3);
|
|
12
13
|
--tbl-head-h: calc(var(--leading-caption) + 2 * var(--tbl-head-py));
|
|
@@ -96,17 +97,21 @@
|
|
|
96
97
|
padding-inline-end: var(--space-4);
|
|
97
98
|
}
|
|
98
99
|
|
|
100
|
+
[data-polarity='dark'] .zc-tbl {
|
|
101
|
+
--_tbl-row-hover: var(--bg-subtle);
|
|
102
|
+
}
|
|
103
|
+
|
|
99
104
|
.zc-tbl__row {
|
|
100
105
|
--row-bg: var(--bg-surface);
|
|
101
106
|
}
|
|
102
107
|
.zc-tbl__row:hover {
|
|
103
|
-
--row-bg: var(--
|
|
108
|
+
--row-bg: var(--_tbl-row-hover);
|
|
104
109
|
}
|
|
105
110
|
.zc-tbl__row[data-selected] {
|
|
106
111
|
--row-bg: color-mix(in oklab, var(--accent) 5%, var(--bg-surface));
|
|
107
112
|
}
|
|
108
113
|
.zc-tbl__row[data-selected]:hover {
|
|
109
|
-
--row-bg: color-mix(in oklab, var(--accent) 5%, var(--
|
|
114
|
+
--row-bg: color-mix(in oklab, var(--accent) 5%, var(--_tbl-row-hover));
|
|
110
115
|
}
|
|
111
116
|
.zc-tbl--clickable tbody .zc-tbl__row {
|
|
112
117
|
cursor: pointer;
|
|
@@ -150,7 +155,7 @@
|
|
|
150
155
|
font-weight: inherit;
|
|
151
156
|
color: inherit;
|
|
152
157
|
white-space: nowrap;
|
|
153
|
-
transition: var(--transition-
|
|
158
|
+
transition: var(--transition-control);
|
|
154
159
|
}
|
|
155
160
|
.zc-tbl__table th.zc-tbl__cell--sortable:first-child .zc-tbl__sort {
|
|
156
161
|
padding-inline-start: var(--space-3);
|
|
@@ -159,7 +164,7 @@
|
|
|
159
164
|
padding-inline-end: var(--space-3);
|
|
160
165
|
}
|
|
161
166
|
.zc-tbl__cell--end .zc-tbl__sort {
|
|
162
|
-
|
|
167
|
+
flex-direction: row-reverse;
|
|
163
168
|
}
|
|
164
169
|
.zc-tbl__cell--center .zc-tbl__sort {
|
|
165
170
|
justify-content: center;
|
package/dist/table.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
'use client';import { useScrollEdges } from './chunk-BIDVNLJO.js';
|
|
2
|
-
import { activationProps } from './chunk-
|
|
3
|
-
import { Motion } from './chunk-
|
|
4
|
-
import './chunk-
|
|
5
|
-
import './chunk-
|
|
2
|
+
import { activationProps } from './chunk-3HE7N3UK.js';
|
|
3
|
+
import { Motion } from './chunk-6BY5G7BI.js';
|
|
4
|
+
import './chunk-BWGK3OD6.js';
|
|
5
|
+
import './chunk-SPFHWHJ6.js';
|
|
6
6
|
import './chunk-VNVVG47J.js';
|
|
7
|
-
import { Icon } from './chunk-TBLPZQSI.js';
|
|
8
7
|
import { DigitStrip } from './chunk-H3X2263Y.js';
|
|
9
|
-
import { Button } from './chunk-
|
|
10
|
-
import './chunk-KSAJ6DED.js';
|
|
8
|
+
import { Button } from './chunk-AOEO2LCZ.js';
|
|
11
9
|
import './chunk-NYQQH4R5.js';
|
|
10
|
+
import './chunk-KSAJ6DED.js';
|
|
12
11
|
import { UIMotion } from './chunk-6H3IJ752.js';
|
|
13
12
|
import { Checkbox } from './chunk-GGDAMIBH.js';
|
|
14
13
|
import './chunk-3XRVPCIM.js';
|
|
14
|
+
import { Icon } from './chunk-TBLPZQSI.js';
|
|
15
15
|
import { cx } from './chunk-QGNC7LH5.js';
|
|
16
16
|
import './table.css';
|
|
17
17
|
import { useState, useRef, useMemo } from 'react';
|
package/dist/tabs.css
CHANGED
|
@@ -1,12 +1,25 @@
|
|
|
1
|
-
@layer zyncat.reset, zyncat.tokens, zyncat.components;
|
|
1
|
+
@layer zyncat.reset, zyncat.tokens, zyncat.base, zyncat.components;
|
|
2
2
|
|
|
3
3
|
@layer zyncat.components {
|
|
4
4
|
.zc-tabs {
|
|
5
5
|
/* 2px, not --border-emphasis: 1.5px renders as sub-pixel fuzz on 1x screens. */
|
|
6
6
|
--tabs-ink-h: 2px;
|
|
7
7
|
--tabs-pill-radius: var(--radius-md);
|
|
8
|
+
--_tabs-tab-h: var(--control-height-sm);
|
|
9
|
+
--_tabs-tab-pad: var(--space-2);
|
|
10
|
+
--_tabs-tab-type: var(--type-caption);
|
|
8
11
|
position: relative;
|
|
9
12
|
}
|
|
13
|
+
.zc-tabs[data-size='md'] {
|
|
14
|
+
--_tabs-tab-h: var(--control-height);
|
|
15
|
+
--_tabs-tab-pad: var(--space-3);
|
|
16
|
+
--_tabs-tab-type: var(--type-label);
|
|
17
|
+
}
|
|
18
|
+
.zc-tabs[data-size='lg'] {
|
|
19
|
+
--_tabs-tab-h: var(--control-height-lg);
|
|
20
|
+
--_tabs-tab-pad: var(--space-4);
|
|
21
|
+
--_tabs-tab-type: var(--type-label);
|
|
22
|
+
}
|
|
10
23
|
.zc-tabs::after {
|
|
11
24
|
content: '';
|
|
12
25
|
position: absolute;
|
|
@@ -60,7 +73,6 @@
|
|
|
60
73
|
cursor: pointer;
|
|
61
74
|
-webkit-tap-highlight-color: transparent;
|
|
62
75
|
border-radius: var(--radius-md);
|
|
63
|
-
outline: var(--ring-rest);
|
|
64
76
|
transition: var(--transition-control);
|
|
65
77
|
}
|
|
66
78
|
.zc-tab:focus-visible {
|
|
@@ -72,10 +84,11 @@
|
|
|
72
84
|
display: flex;
|
|
73
85
|
align-items: center;
|
|
74
86
|
gap: var(--space-2);
|
|
75
|
-
height: var(--
|
|
76
|
-
padding-inline: var(--
|
|
87
|
+
height: var(--_tabs-tab-h);
|
|
88
|
+
padding-inline: var(--_tabs-tab-pad);
|
|
77
89
|
border-radius: var(--radius-md);
|
|
78
|
-
font: var(--type
|
|
90
|
+
font: var(--_tabs-tab-type);
|
|
91
|
+
font-weight: var(--weight-medium);
|
|
79
92
|
line-height: 1;
|
|
80
93
|
white-space: nowrap;
|
|
81
94
|
color: var(--text-subtle);
|
|
@@ -153,7 +166,7 @@
|
|
|
153
166
|
max-width: 100%;
|
|
154
167
|
padding: var(--space-1);
|
|
155
168
|
border-radius: calc(var(--tabs-pill-radius) + var(--space-1));
|
|
156
|
-
background: var(--bg-
|
|
169
|
+
background: var(--bg-muted);
|
|
157
170
|
}
|
|
158
171
|
.zc-tabs--pill::after {
|
|
159
172
|
content: none;
|
|
@@ -183,12 +196,24 @@
|
|
|
183
196
|
.zc-tabs--pill .zc-tabs__ink {
|
|
184
197
|
top: var(--space-1);
|
|
185
198
|
bottom: auto;
|
|
186
|
-
height: var(--
|
|
199
|
+
height: var(--_tabs-tab-h);
|
|
187
200
|
border-radius: var(--tabs-pill-radius);
|
|
188
201
|
background: var(--bg-surface);
|
|
189
202
|
box-shadow: var(--shadow-xs);
|
|
190
203
|
}
|
|
191
204
|
|
|
205
|
+
.zc-tabs--fill,
|
|
206
|
+
.zc-tabs--fill .zc-tabs__list,
|
|
207
|
+
.zc-tabs--fill .zc-tab {
|
|
208
|
+
flex: 1;
|
|
209
|
+
}
|
|
210
|
+
.zc-tabs--fill {
|
|
211
|
+
width: 100%;
|
|
212
|
+
}
|
|
213
|
+
.zc-tabs--fill .zc-tab__pad {
|
|
214
|
+
justify-content: center;
|
|
215
|
+
}
|
|
216
|
+
|
|
192
217
|
.zc-tab-panel {
|
|
193
218
|
outline: none;
|
|
194
219
|
overflow: hidden;
|
package/dist/tabs.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use client';import { useScrollEdges } from './chunk-BIDVNLJO.js';
|
|
2
|
-
import { activationProps } from './chunk-
|
|
3
|
-
import { useGlide, GlidePill } from './chunk-
|
|
2
|
+
import { activationProps } from './chunk-3HE7N3UK.js';
|
|
3
|
+
import { useGlide, GlidePill } from './chunk-AQMR7ZYO.js';
|
|
4
4
|
import { resolveMotionTiming } from './chunk-C3D32LE3.js';
|
|
5
|
-
import { Motion } from './chunk-
|
|
6
|
-
import './chunk-
|
|
7
|
-
import { set, animate } from './chunk-
|
|
5
|
+
import { Motion } from './chunk-6BY5G7BI.js';
|
|
6
|
+
import './chunk-BWGK3OD6.js';
|
|
7
|
+
import { set, animate } from './chunk-SPFHWHJ6.js';
|
|
8
8
|
import './chunk-VNVVG47J.js';
|
|
9
9
|
import { IconSlot } from './chunk-WCWV5IX6.js';
|
|
10
10
|
import { motionFor } from './chunk-6H3IJ752.js';
|
|
@@ -24,6 +24,8 @@ function Tabs({
|
|
|
24
24
|
ariaLabel,
|
|
25
25
|
activateOn = "pointerdown",
|
|
26
26
|
variant = "underline",
|
|
27
|
+
size = "sm",
|
|
28
|
+
fill = false,
|
|
27
29
|
className = "",
|
|
28
30
|
style,
|
|
29
31
|
htmlProps
|
|
@@ -123,48 +125,57 @@ function Tabs({
|
|
|
123
125
|
if (el) el.focus();
|
|
124
126
|
};
|
|
125
127
|
const focusValue = items.some((i) => i.value === value && !i.disabled) ? value : (items.find((i) => !i.disabled) || {}).value;
|
|
126
|
-
return /* @__PURE__ */ jsx(
|
|
128
|
+
return /* @__PURE__ */ jsx(
|
|
127
129
|
"div",
|
|
128
130
|
{
|
|
129
|
-
className: "zc-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
131
|
+
className: cx("zc-tabs", pill && "zc-tabs--pill", fill && "zc-tabs--fill", className),
|
|
132
|
+
style,
|
|
133
|
+
...htmlProps,
|
|
134
|
+
"data-size": size,
|
|
135
|
+
children: /* @__PURE__ */ jsxs(
|
|
136
|
+
"div",
|
|
137
|
+
{
|
|
138
|
+
className: "zc-tabs__list",
|
|
139
|
+
role: "tablist",
|
|
140
|
+
"aria-label": ariaLabel,
|
|
141
|
+
ref: listRef,
|
|
142
|
+
onKeyDown,
|
|
143
|
+
onPointerLeave: pill ? void 0 : glide.leave,
|
|
144
|
+
children: [
|
|
145
|
+
!pill && /* @__PURE__ */ jsx(GlidePill, { className: "zc-tab__hover", glide }),
|
|
146
|
+
items.map((it) => {
|
|
147
|
+
const selected = it.value === value;
|
|
148
|
+
return /* @__PURE__ */ jsx(
|
|
149
|
+
"button",
|
|
150
|
+
{
|
|
151
|
+
type: "button",
|
|
152
|
+
role: "tab",
|
|
153
|
+
id: base + "-tab-" + it.value,
|
|
154
|
+
"aria-selected": selected,
|
|
155
|
+
"aria-controls": name ? name + "-panel-" + it.value : void 0,
|
|
156
|
+
tabIndex: it.value === focusValue ? 0 : -1,
|
|
157
|
+
disabled: it.disabled,
|
|
158
|
+
className: "zc-tab" + (selected ? " zc-is-selected" : ""),
|
|
159
|
+
ref: (el) => {
|
|
160
|
+
tabRefs.current[it.value] = el;
|
|
161
|
+
},
|
|
162
|
+
...activationProps(() => select(it.value), { on: activateOn }),
|
|
163
|
+
onPointerEnter: it.disabled || pill ? void 0 : (e) => glide.enter(e.currentTarget.firstElementChild),
|
|
164
|
+
children: /* @__PURE__ */ jsxs("span", { className: "zc-tab__pad", children: [
|
|
165
|
+
it.icon && /* @__PURE__ */ jsx(IconSlot, { size: "sm", children: it.icon }),
|
|
166
|
+
/* @__PURE__ */ jsx("span", { className: "zc-tab__label", children: it.label }),
|
|
167
|
+
it.count != null && /* @__PURE__ */ jsx("span", { className: "zc-tab__count", children: it.count })
|
|
168
|
+
] })
|
|
169
|
+
},
|
|
170
|
+
it.value
|
|
171
|
+
);
|
|
172
|
+
}),
|
|
173
|
+
/* @__PURE__ */ jsx("span", { className: "zc-tabs__ink", ref: inkRef, "aria-hidden": "true" }, "ink")
|
|
174
|
+
]
|
|
175
|
+
}
|
|
176
|
+
)
|
|
166
177
|
}
|
|
167
|
-
)
|
|
178
|
+
);
|
|
168
179
|
}
|
|
169
180
|
var TABPANEL_TIMING = {
|
|
170
181
|
open: { duration: "base", ease: "entrance" },
|