@zyncat/ui 0.13.1 → 0.17.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/README.md +46 -157
- package/dist/alert.css +27 -34
- package/dist/alert.js +26 -17
- package/dist/alert.js.map +1 -1
- package/dist/avatar-group.js +2 -2
- package/dist/avatar-group.js.map +1 -1
- package/dist/avatar.css +53 -51
- package/dist/avatar.js +29 -7
- package/dist/avatar.js.map +1 -1
- package/dist/badge.css +31 -37
- package/dist/badge.js +1 -1
- package/dist/bloom-HV23M4AW.js +81 -0
- package/dist/bloom-HV23M4AW.js.map +1 -0
- package/dist/button.css +99 -118
- package/dist/button.js +3 -1
- package/dist/checkbox.css +28 -33
- package/dist/checkbox.js +2 -2
- package/dist/chunk-2YGHPQ66.js +16 -0
- package/dist/chunk-2YGHPQ66.js.map +1 -0
- package/dist/chunk-3MLUH2QL.js +53 -0
- package/dist/chunk-3MLUH2QL.js.map +1 -0
- package/dist/{chunk-RJFGWJ4W.js → chunk-3XRVPCIM.js} +6 -6
- package/dist/chunk-3XRVPCIM.js.map +1 -0
- package/dist/{chunk-FONOS5RN.js → chunk-4PQDVK23.js} +11 -10
- package/dist/chunk-4PQDVK23.js.map +1 -0
- package/dist/{chunk-45R4Z5XN.js → chunk-5VC3TUZ2.js} +4 -4
- package/dist/{chunk-45R4Z5XN.js.map → chunk-5VC3TUZ2.js.map} +1 -1
- package/dist/{chunk-A5WTZACK.js → chunk-5W5TKANX.js} +3 -3
- package/dist/{chunk-A5WTZACK.js.map → chunk-5W5TKANX.js.map} +1 -1
- package/dist/{chunk-227ZW4V7.js → chunk-6IXLW7QA.js} +11 -11
- package/dist/chunk-6IXLW7QA.js.map +1 -0
- package/dist/chunk-7NHY2CRA.js +132 -0
- package/dist/chunk-7NHY2CRA.js.map +1 -0
- package/dist/{chunk-EF6RPXU7.js → chunk-7VTWJL72.js} +43 -35
- package/dist/chunk-7VTWJL72.js.map +1 -0
- package/dist/chunk-7ZSIUUC3.js +50 -0
- package/dist/chunk-7ZSIUUC3.js.map +1 -0
- package/dist/{chunk-TYHR4VNM.js → chunk-AREEMG47.js} +10 -8
- package/dist/chunk-AREEMG47.js.map +1 -0
- package/dist/{chunk-DDRSMHN4.js → chunk-DH7DT6EO.js} +3 -3
- package/dist/{chunk-DDRSMHN4.js.map → chunk-DH7DT6EO.js.map} +1 -1
- package/dist/chunk-EOWWVFBF.js +14 -0
- package/dist/chunk-EOWWVFBF.js.map +1 -0
- package/dist/{chunk-5PZ43DCG.js → chunk-FLDIRXFU.js} +12 -13
- package/dist/chunk-FLDIRXFU.js.map +1 -0
- package/dist/{chunk-I45AU6KH.js → chunk-GGDAMIBH.js} +13 -7
- package/dist/chunk-GGDAMIBH.js.map +1 -0
- package/dist/{chunk-M43IOM5C.js → chunk-GWCBTD63.js} +3 -3
- package/dist/{chunk-M43IOM5C.js.map → chunk-GWCBTD63.js.map} +1 -1
- package/dist/chunk-GZ6UMHCK.js +103 -0
- package/dist/chunk-GZ6UMHCK.js.map +1 -0
- package/dist/chunk-H3X2263Y.js +17 -0
- package/dist/chunk-H3X2263Y.js.map +1 -0
- package/dist/{chunk-IJS7TPGV.js → chunk-HWDIVGME.js} +14 -7
- package/dist/chunk-HWDIVGME.js.map +1 -0
- package/dist/chunk-KSAJ6DED.js +16 -0
- package/dist/chunk-KSAJ6DED.js.map +1 -0
- package/dist/chunk-LH2UIEKN.js +42 -0
- package/dist/chunk-LH2UIEKN.js.map +1 -0
- package/dist/{chunk-JY6A2ZJZ.js → chunk-LNAV5E7S.js} +2 -2
- package/dist/{chunk-JY6A2ZJZ.js.map → chunk-LNAV5E7S.js.map} +1 -1
- package/dist/{chunk-CF4QHO4N.js → chunk-M2A6PZ7J.js} +10 -10
- package/dist/{chunk-CF4QHO4N.js.map → chunk-M2A6PZ7J.js.map} +1 -1
- package/dist/chunk-NYQQH4R5.js +40 -0
- package/dist/chunk-NYQQH4R5.js.map +1 -0
- package/dist/{chunk-TVYH4AN7.js → chunk-ODRO3KS6.js} +13 -13
- package/dist/chunk-ODRO3KS6.js.map +1 -0
- package/dist/chunk-PU3QWBEL.js +39 -0
- package/dist/chunk-PU3QWBEL.js.map +1 -0
- package/dist/{chunk-4BSHB7R3.js → chunk-QDAN43B6.js} +9 -9
- package/dist/chunk-QDAN43B6.js.map +1 -0
- package/dist/{chunk-XNIYSAMJ.js → chunk-RW2A4M2Q.js} +14 -9
- package/dist/chunk-RW2A4M2Q.js.map +1 -0
- package/dist/{chunk-TUTXXC3W.js → chunk-RY35IU3G.js} +3 -3
- package/dist/{chunk-TUTXXC3W.js.map → chunk-RY35IU3G.js.map} +1 -1
- package/dist/{chunk-EAI4POPB.js → chunk-TBLPZQSI.js} +56 -50
- package/dist/chunk-TBLPZQSI.js.map +1 -0
- package/dist/{chunk-AADAJL7D.js → chunk-UKPX3RIP.js} +8 -9
- package/dist/chunk-UKPX3RIP.js.map +1 -0
- package/dist/chunk-VDOBLABP.js +38 -0
- package/dist/chunk-VDOBLABP.js.map +1 -0
- package/dist/chunk-VNVVG47J.js +12 -0
- package/dist/chunk-VNVVG47J.js.map +1 -0
- package/dist/{chunk-4C5RZXBT.js → chunk-VZXML7EH.js} +8 -8
- package/dist/chunk-VZXML7EH.js.map +1 -0
- package/dist/{chunk-43M6GQ4Q.js → chunk-WC45VSST.js} +51 -32
- package/dist/chunk-WC45VSST.js.map +1 -0
- package/dist/{chunk-3MPF7FZV.js → chunk-WCWV5IX6.js} +3 -3
- package/dist/{chunk-3MPF7FZV.js.map → chunk-WCWV5IX6.js.map} +1 -1
- package/dist/chunk-WQKWPI6V.js +196 -0
- package/dist/chunk-WQKWPI6V.js.map +1 -0
- package/dist/{chunk-VAXCXZ53.js → chunk-WZUTBJC4.js} +5 -4
- package/dist/chunk-WZUTBJC4.js.map +1 -0
- package/dist/chunk-ZHMOH62S.js +101 -0
- package/dist/chunk-ZHMOH62S.js.map +1 -0
- package/dist/cli.js +356 -28
- package/dist/collapse.css +21 -33
- package/dist/collapse.js +1 -1
- package/dist/confetti.css +20 -13
- package/dist/confetti.js +7 -6
- package/dist/confetti.js.map +1 -1
- package/dist/count-badge.js +2 -2
- package/dist/date-field.js +22 -19
- package/dist/date-field.js.map +1 -1
- package/dist/date-picker.css +287 -185
- package/dist/date-range-field.js +75 -59
- package/dist/date-range-field.js.map +1 -1
- package/dist/datetime-field.js +26 -23
- package/dist/datetime-field.js.map +1 -1
- package/dist/dialog.css +35 -44
- package/dist/dialog.js +23 -22
- package/dist/dialog.js.map +1 -1
- package/dist/digit-strip.css +17 -17
- package/dist/dropdown.css +37 -28
- package/dist/dropdown.js +77 -40
- package/dist/dropdown.js.map +1 -1
- package/dist/emoji-picker.js +44 -45
- package/dist/emoji-picker.js.map +1 -1
- package/dist/facebook-feed.css +146 -149
- package/dist/facebook-feed.js +106 -102
- package/dist/facebook-feed.js.map +1 -1
- package/dist/flow-field.css +9 -5
- package/dist/flow-field.js +8 -7
- package/dist/flow-field.js.map +1 -1
- package/dist/glide.js +4 -3
- package/dist/icon.css +8 -11
- package/dist/input.css +81 -86
- package/dist/instagram-feed.css +66 -67
- package/dist/instagram-feed.js +61 -44
- package/dist/instagram-feed.js.map +1 -1
- package/dist/lens.css +42 -39
- package/dist/lens.js +17 -16
- package/dist/lens.js.map +1 -1
- package/dist/mcp.js +4 -3
- package/dist/menu-surface.css +55 -35
- package/dist/modal.css +3 -5
- package/dist/modal.js +12 -11
- package/dist/modal.js.map +1 -1
- package/dist/morphing-text.css +27 -17
- package/dist/morphing-text.js +14 -13
- package/dist/morphing-text.js.map +1 -1
- package/dist/motion-devtools.css +118 -69
- package/dist/motion-devtools.js +230 -65
- package/dist/motion-devtools.js.map +1 -1
- package/dist/motion-tokens.js +1 -1
- package/dist/multi-select.js +21 -16
- package/dist/multi-select.js.map +1 -1
- package/dist/number-field.js +15 -15
- package/dist/number-field.js.map +1 -1
- package/dist/odometer.css +23 -17
- package/dist/odometer.js +12 -11
- package/dist/odometer.js.map +1 -1
- package/dist/otp-field.js +3 -3
- package/dist/otp-field.js.map +1 -1
- package/dist/overlay.css +5 -10
- package/dist/pagination.css +11 -16
- package/dist/pagination.js +13 -10
- package/dist/pagination.js.map +1 -1
- package/dist/paint-CJQCM6ZO.js +260 -0
- package/dist/paint-CJQCM6ZO.js.map +1 -0
- package/dist/popover.css +14 -16
- package/dist/popover.js +10 -9
- package/dist/radio-group.css +65 -76
- package/dist/radio-group.js +30 -29
- package/dist/radio-group.js.map +1 -1
- package/dist/select.css +67 -76
- package/dist/select.js +19 -14
- package/dist/select.js.map +1 -1
- package/dist/sheet.css +13 -15
- package/dist/sheet.js +11 -10
- package/dist/spinner.css +115 -0
- package/dist/spinner.js +4 -0
- package/dist/spinner.js.map +1 -0
- package/dist/status-badge.js +9 -9
- package/dist/status-badge.js.map +1 -1
- package/dist/styles.css +35 -35
- package/dist/support-rail.css +110 -256
- package/dist/support-rail.js +116 -123
- package/dist/support-rail.js.map +1 -1
- package/dist/table.css +77 -85
- package/dist/table.js +44 -41
- package/dist/table.js.map +1 -1
- package/dist/tabs.css +81 -93
- package/dist/tabs.js +23 -20
- package/dist/tabs.js.map +1 -1
- package/dist/tag.css +49 -54
- package/dist/tag.js +13 -12
- package/dist/tag.js.map +1 -1
- package/dist/text-field.js +5 -5
- package/dist/textarea.css +47 -50
- package/dist/textarea.js +16 -16
- package/dist/textarea.js.map +1 -1
- package/dist/theme-grid.js +11 -0
- package/dist/theme-grid.js.map +1 -0
- package/dist/theme-switcher.css +107 -0
- package/dist/theme-switcher.js +70 -0
- package/dist/theme-switcher.js.map +1 -0
- package/dist/theme-transition-LLC644ZR.js +346 -0
- package/dist/theme-transition-LLC644ZR.js.map +1 -0
- package/dist/theme-transition.css +48 -0
- package/dist/theme.js +74 -27
- package/dist/theme.js.map +1 -1
- package/dist/tide-DJZMDAFT.js +57 -0
- package/dist/tide-DJZMDAFT.js.map +1 -0
- package/dist/tiktok.css +114 -119
- package/dist/tiktok.js +53 -52
- package/dist/tiktok.js.map +1 -1
- package/dist/time-field.js +26 -20
- package/dist/time-field.js.map +1 -1
- package/dist/toast-store.js +2 -1
- package/dist/toast.css +51 -79
- package/dist/toast.js +34 -26
- package/dist/toast.js.map +1 -1
- package/dist/toggle-tag.js +23 -14
- package/dist/toggle-tag.js.map +1 -1
- package/dist/toggle.css +27 -32
- package/dist/toggle.js +7 -7
- package/dist/toggle.js.map +1 -1
- package/dist/tooltip.css +17 -24
- package/dist/tooltip.js +117 -95
- package/dist/tooltip.js.map +1 -1
- package/dist/trigger.css +4 -4
- package/dist/types/components/composites/alert/Alert.d.ts +1 -2
- package/dist/types/components/composites/date-picker/TimeField.d.ts +1 -2
- package/dist/types/components/composites/date-picker/field-shell.d.ts +1 -1
- package/dist/types/components/composites/date-picker/month-jump.d.ts +11 -0
- package/dist/types/components/composites/date-picker/time-core.d.ts +1 -2
- package/dist/types/components/composites/dropdown/Dropdown.d.ts +9 -1
- package/dist/types/components/composites/dropdown/types.d.ts +14 -0
- package/dist/types/components/composites/emoji-picker/EmojiPickerPanel.d.ts +1 -1
- package/dist/types/components/composites/emoji-picker/data.d.ts +2 -5
- package/dist/types/components/composites/emoji-picker/react/useEmojiPicker.d.ts +0 -11
- package/dist/types/components/composites/emoji-picker/types.d.ts +3 -8
- package/dist/types/components/composites/select/MultiSelect.d.ts +6 -1
- package/dist/types/components/composites/select/Select.d.ts +6 -1
- package/dist/types/components/composites/select/core/index.d.ts +1 -1
- package/dist/types/components/composites/select/core/menu.d.ts +3 -3
- package/dist/types/components/composites/select/core/panel.d.ts +3 -3
- package/dist/types/components/composites/tabs/Tabs.d.ts +7 -10
- package/dist/types/components/composites/theme-switcher/ThemeGrid.d.ts +20 -0
- package/dist/types/components/composites/theme-switcher/ThemeSwitcher.d.ts +24 -0
- package/dist/types/components/composites/toast/Toast.d.ts +1 -1
- package/dist/types/components/composites/tooltip/Tooltip.d.ts +9 -1
- package/dist/types/components/composites/tooltip/tooltip-store.d.ts +5 -6
- package/dist/types/components/compound/support-rail/SupportRail.d.ts +10 -8
- package/dist/types/components/dev/MotionDevtools.d.ts +12 -5
- package/dist/types/components/expressive/theme-transition/bloom.d.ts +2 -0
- package/dist/types/components/expressive/theme-transition/paint.d.ts +2 -0
- package/dist/types/components/expressive/theme-transition/scene.d.ts +24 -0
- package/dist/types/components/expressive/theme-transition/theme-transition.d.ts +19 -0
- package/dist/types/components/expressive/theme-transition/tide.d.ts +2 -0
- package/dist/types/components/internal/hooks/use-host-election.d.ts +8 -0
- package/dist/types/components/internal/icon/Icon.d.ts +2 -3
- package/dist/types/components/internal/menu/highlight.d.ts +7 -0
- package/dist/types/components/internal/utils/activation.d.ts +0 -4
- package/dist/types/components/primitives/avatar/Avatar.d.ts +1 -1
- package/dist/types/components/primitives/button/Button.d.ts +10 -13
- package/dist/types/components/primitives/button/button-style.d.ts +15 -0
- package/dist/types/components/primitives/input/TextField.d.ts +1 -2
- package/dist/types/components/primitives/spinner/Spinner.d.ts +27 -0
- package/dist/types/components/primitives/textarea/Textarea.d.ts +0 -1
- package/dist/types/engine/animate.d.ts +1 -0
- package/dist/types/shared-slot.d.ts +1 -0
- package/dist/types/tokens/component-styles.generated.d.ts +80 -155
- package/dist/types/tokens/motion-defaults.generated.d.ts +34 -0
- package/dist/types/tokens/motion-scale.d.ts +2 -2
- package/dist/types/tokens/motion-tokens.d.ts +7 -0
- package/dist/types/tokens/theme-store.d.ts +47 -0
- package/dist/types/tokens/theme-sync.d.ts +9 -0
- package/dist/types/tokens/theme-tokens.generated.d.ts +693 -1117
- package/dist/types/tokens/theme.d.ts +28 -5
- package/dist/typing-lines.css +18 -11
- package/dist/typing-lines.js +9 -8
- package/dist/typing-lines.js.map +1 -1
- package/dist/weight-field.css +32 -18
- package/dist/weight-field.js +4 -4
- package/dist/weight-field.js.map +1 -1
- package/dist/youtube.css +91 -97
- package/dist/youtube.js +87 -86
- package/dist/youtube.js.map +1 -1
- package/package.json +27 -31
- package/skills/zyncat-ui/SKILL.md +5 -3
- package/skills/zyncat-ui/references/components.md +7 -4
- package/skills/zyncat-ui/references/theming.md +105 -34
- package/src/components/composites/alert/Alert.tsx +15 -12
- package/src/components/composites/alert/alert.css +27 -34
- package/src/components/composites/date-picker/DateField.tsx +1 -1
- package/src/components/composites/date-picker/DateRangeField.tsx +1 -1
- package/src/components/composites/date-picker/DateTimeField.tsx +4 -4
- package/src/components/composites/date-picker/TimeField.tsx +8 -5
- package/src/components/composites/date-picker/calendar-panel.tsx +33 -22
- package/src/components/composites/date-picker/date-picker.css +287 -185
- package/src/components/composites/date-picker/field-shell.tsx +7 -7
- package/src/components/composites/date-picker/month-jump.tsx +192 -0
- package/src/components/composites/date-picker/range-panel.tsx +51 -36
- package/src/components/composites/date-picker/time-core.tsx +4 -6
- package/src/components/composites/date-picker/use-day-focus.ts +1 -1
- package/src/components/composites/dialog/Dialog.tsx +11 -11
- package/src/components/composites/dialog/dialog.css +35 -44
- package/src/components/composites/dropdown/Dropdown.tsx +15 -2
- package/src/components/composites/dropdown/Dropdown.usage.md +7 -4
- package/src/components/composites/dropdown/dropdown.css +37 -28
- package/src/components/composites/dropdown/menu-panel.tsx +56 -27
- package/src/components/composites/dropdown/types.ts +28 -6
- package/src/components/composites/emoji-picker/EmojiPickerPanel.tsx +5 -4
- package/src/components/composites/emoji-picker/EmojiPickerPanel.usage.md +4 -4
- package/src/components/composites/emoji-picker/data.ts +2 -5
- package/src/components/composites/emoji-picker/dom.ts +6 -6
- package/src/components/composites/emoji-picker/react/category-bar.tsx +6 -6
- package/src/components/composites/emoji-picker/react/useEmojiPicker.ts +0 -11
- package/src/components/composites/emoji-picker/scaffold.ts +7 -7
- package/src/components/composites/emoji-picker/search.ts +0 -7
- package/src/components/composites/emoji-picker/styles.css +35 -35
- package/src/components/composites/emoji-picker/types.ts +3 -8
- package/src/components/composites/modal/Modal.tsx +2 -2
- package/src/components/composites/modal/modal.css +3 -5
- package/src/components/composites/pagination/Pagination.tsx +7 -7
- package/src/components/composites/pagination/pagination.css +11 -16
- package/src/components/composites/popover/Popover.tsx +2 -2
- package/src/components/composites/popover/popover.css +14 -16
- package/src/components/composites/select/MultiSelect.tsx +11 -2
- package/src/components/composites/select/MultiSelect.usage.md +2 -1
- package/src/components/composites/select/Select.tsx +10 -1
- package/src/components/composites/select/Select.usage.md +2 -1
- package/src/components/composites/select/core/index.ts +1 -1
- package/src/components/composites/select/core/menu.tsx +19 -4
- package/src/components/composites/select/core/panel.tsx +19 -15
- package/src/components/composites/select/core/trigger.tsx +5 -5
- package/src/components/composites/select/select.css +67 -76
- package/src/components/composites/sheet/Sheet.tsx +2 -2
- package/src/components/composites/sheet/sheet.css +13 -15
- package/src/components/composites/sheet/use-sheet-drag.ts +1 -1
- package/src/components/composites/table/Table.tsx +35 -35
- package/src/components/composites/table/table.css +77 -85
- package/src/components/composites/tabs/Tabs.tsx +20 -21
- package/src/components/composites/tabs/Tabs.usage.md +3 -2
- package/src/components/composites/tabs/tabs.css +81 -93
- package/src/components/composites/theme-switcher/ThemeGrid.tsx +133 -0
- package/src/components/composites/theme-switcher/ThemeGrid.usage.md +20 -0
- package/src/components/composites/theme-switcher/ThemeSwitcher.tsx +75 -0
- package/src/components/composites/theme-switcher/ThemeSwitcher.usage.md +21 -0
- package/src/components/composites/theme-switcher/theme-switcher.css +107 -0
- package/src/components/composites/toast/Toast.tsx +24 -18
- package/src/components/composites/toast/toast-store.ts +8 -6
- package/src/components/composites/toast/toast.css +51 -79
- package/src/components/composites/tooltip/Tooltip.tsx +40 -19
- package/src/components/composites/tooltip/Tooltip.usage.md +9 -1
- package/src/components/composites/tooltip/tooltip-host.tsx +55 -23
- package/src/components/composites/tooltip/tooltip-store.ts +36 -53
- package/src/components/composites/tooltip/tooltip.css +17 -24
- package/src/components/compound/support-rail/SupportRail.tsx +132 -144
- package/src/components/compound/support-rail/SupportRail.usage.md +7 -6
- package/src/components/compound/support-rail/support-rail.css +110 -256
- package/src/components/dev/MotionDevtools.tsx +272 -51
- package/src/components/dev/MotionDevtools.usage.md +12 -4
- package/src/components/dev/motion-devtools.css +118 -69
- package/src/components/dev/slowmo-engine.ts +16 -15
- package/src/components/expressive/confetti/Confetti.tsx +4 -4
- package/src/components/expressive/confetti/confetti.css +20 -13
- package/src/components/expressive/facebook-feed/chrome.tsx +2 -2
- package/src/components/expressive/facebook-feed/facebook-feed.css +146 -149
- package/src/components/expressive/facebook-feed/post.tsx +39 -39
- package/src/components/expressive/facebook-feed/reel.tsx +41 -37
- package/src/components/expressive/facebook-feed/story.tsx +27 -27
- package/src/components/expressive/flow-field/FlowField.tsx +5 -5
- package/src/components/expressive/flow-field/flow-field.css +9 -5
- package/src/components/expressive/instagram-feed/InstagramFeed.tsx +52 -44
- package/src/components/expressive/instagram-feed/instagram-feed.css +66 -67
- package/src/components/expressive/lens/Lens.tsx +14 -14
- package/src/components/expressive/lens/lens.css +42 -39
- package/src/components/expressive/morphing-text/MorphingText.tsx +12 -13
- package/src/components/expressive/morphing-text/morphing-text.css +27 -17
- package/src/components/expressive/odometer/Odometer.tsx +9 -9
- package/src/components/expressive/odometer/odometer.css +23 -17
- package/src/components/expressive/theme-transition/bloom.ts +88 -0
- package/src/components/expressive/theme-transition/paint.ts +296 -0
- package/src/components/expressive/theme-transition/scene.ts +38 -0
- package/src/components/expressive/theme-transition/theme-transition.css +48 -0
- package/src/components/expressive/theme-transition/theme-transition.ts +423 -0
- package/src/components/expressive/theme-transition/tide.ts +65 -0
- package/src/components/expressive/tiktok/TikTok.tsx +54 -54
- package/src/components/expressive/tiktok/tiktok.css +114 -119
- package/src/components/expressive/typing-lines/TypingLines.tsx +0 -0
- package/src/components/expressive/typing-lines/typing-lines.css +18 -11
- package/src/components/expressive/weight-field/WeightField.tsx +4 -4
- package/src/components/expressive/weight-field/weight-field.css +32 -18
- package/src/components/expressive/youtube/YouTube.tsx +4 -4
- package/src/components/expressive/youtube/glyphs.tsx +16 -16
- package/src/components/expressive/youtube/media.tsx +3 -3
- package/src/components/expressive/youtube/post.tsx +28 -28
- package/src/components/expressive/youtube/short.tsx +25 -25
- package/src/components/expressive/youtube/video.tsx +13 -13
- package/src/components/expressive/youtube/youtube.css +91 -97
- package/src/components/internal/glass/glass.css +20 -23
- package/src/components/internal/glass/glint.ts +3 -3
- package/src/components/internal/hooks/use-host-election.ts +46 -0
- package/src/components/internal/icon/Icon.tsx +3 -5
- package/src/components/internal/icon/IconSlot.tsx +1 -1
- package/src/components/internal/icon/icon.css +8 -11
- package/src/components/internal/menu/highlight.ts +12 -0
- package/src/components/internal/menu/menu-row.tsx +5 -5
- package/src/components/internal/menu/menu-surface.css +55 -35
- package/src/components/internal/overlay/layer.tsx +2 -1
- package/src/components/internal/overlay/modal.tsx +5 -4
- package/src/components/internal/overlay/overlay.css +5 -10
- package/src/components/internal/overlay/trigger.css +4 -4
- package/src/components/internal/utils/activation.ts +0 -4
- package/src/components/primitives/avatar/Avatar.tsx +24 -8
- package/src/components/primitives/avatar/AvatarGroup.tsx +4 -4
- package/src/components/primitives/avatar/avatar.css +53 -51
- package/src/components/primitives/badge/Badge.tsx +9 -9
- package/src/components/primitives/badge/StatusBadge.tsx +7 -7
- package/src/components/primitives/badge/badge.css +31 -37
- package/src/components/primitives/badge/digit-strip.css +17 -17
- package/src/components/primitives/badge/digit-strip.tsx +4 -4
- package/src/components/primitives/button/Button.tsx +14 -28
- package/src/components/primitives/button/button-style.ts +28 -0
- package/src/components/primitives/button/button.css +99 -118
- package/src/components/primitives/checkbox/Checkbox.tsx +10 -4
- package/src/components/primitives/checkbox/check-glyph.tsx +5 -5
- package/src/components/primitives/checkbox/checkbox.css +28 -33
- package/src/components/primitives/collapse/Collapse.tsx +2 -2
- package/src/components/primitives/collapse/collapse.css +21 -33
- package/src/components/primitives/collapse/collapse.typecheck.tsx +1 -1
- package/src/components/primitives/input/NumberField.tsx +11 -11
- package/src/components/primitives/input/OtpField.tsx +3 -3
- package/src/components/primitives/input/TextField.tsx +9 -10
- package/src/components/primitives/input/field-chrome.tsx +6 -6
- package/src/components/primitives/input/input.css +81 -86
- package/src/components/primitives/radio-group/RadioGroup.tsx +23 -23
- package/src/components/primitives/radio-group/radio-group.css +65 -76
- package/src/components/primitives/spinner/Spinner.tsx +70 -0
- package/src/components/primitives/spinner/Spinner.usage.md +19 -0
- package/src/components/primitives/spinner/spinner.css +115 -0
- package/src/components/primitives/tag/Tag.tsx +5 -5
- package/src/components/primitives/tag/ToggleTag.tsx +11 -6
- package/src/components/primitives/tag/tag.css +49 -54
- package/src/components/primitives/textarea/Textarea.tsx +13 -14
- package/src/components/primitives/textarea/textarea.css +47 -50
- package/src/components/primitives/toggle/Toggle.tsx +7 -7
- package/src/components/primitives/toggle/toggle.css +27 -32
- package/src/engine/animate.ts +12 -3
- package/src/engine/flip.ts +2 -1
- package/src/mcp/server.ts +5 -2
- package/src/motion/flip.ts +7 -8
- package/src/motion/glide.tsx +41 -26
- package/src/shared-slot.ts +10 -0
- package/src/styles.css +8 -16
- package/src/tokens/base.css +15 -0
- package/src/tokens/color.css +22 -63
- package/src/tokens/component-styles.generated.ts +81 -155
- package/src/tokens/dark.css +58 -0
- package/src/tokens/decisions.css +23 -0
- package/src/tokens/elevation.css +65 -23
- package/src/tokens/fonts.css +0 -2
- package/src/tokens/glass.css +17 -10
- package/src/tokens/motion-defaults.generated.ts +21 -0
- package/src/tokens/motion-scale.ts +2 -2
- package/src/tokens/motion-tokens.ts +65 -40
- package/src/tokens/motion-tokens.usage.md +5 -2
- package/src/tokens/motion.css +18 -28
- package/src/tokens/radius.css +12 -10
- package/src/tokens/reset.css +36 -0
- package/src/tokens/semantic.css +51 -39
- package/src/tokens/spacing.css +6 -7
- package/src/tokens/theme-store.ts +187 -0
- package/src/tokens/theme-sync.tsx +62 -0
- package/src/tokens/theme-tokens.generated.ts +708 -1121
- package/src/tokens/theme.tsx +116 -38
- package/src/tokens/theme.usage.md +26 -19
- package/src/tokens/typography.css +18 -20
- package/tailwind.css +187 -0
- package/dist/chunk-227ZW4V7.js.map +0 -1
- package/dist/chunk-43M6GQ4Q.js.map +0 -1
- package/dist/chunk-4BSHB7R3.js.map +0 -1
- package/dist/chunk-4C5RZXBT.js.map +0 -1
- package/dist/chunk-5PZ43DCG.js.map +0 -1
- package/dist/chunk-7IZJERGA.js +0 -80
- package/dist/chunk-7IZJERGA.js.map +0 -1
- package/dist/chunk-AADAJL7D.js.map +0 -1
- package/dist/chunk-CNWTIMIP.js +0 -39
- package/dist/chunk-CNWTIMIP.js.map +0 -1
- package/dist/chunk-EAI4POPB.js.map +0 -1
- package/dist/chunk-EF6RPXU7.js.map +0 -1
- package/dist/chunk-FONOS5RN.js.map +0 -1
- package/dist/chunk-FQEHSKEI.js +0 -38
- package/dist/chunk-FQEHSKEI.js.map +0 -1
- package/dist/chunk-HY5MPISE.js +0 -52
- package/dist/chunk-HY5MPISE.js.map +0 -1
- package/dist/chunk-I45AU6KH.js.map +0 -1
- package/dist/chunk-IJS7TPGV.js.map +0 -1
- package/dist/chunk-OWNMRMPN.js +0 -14
- package/dist/chunk-OWNMRMPN.js.map +0 -1
- package/dist/chunk-RJFGWJ4W.js.map +0 -1
- package/dist/chunk-TCUCYFT7.js +0 -25
- package/dist/chunk-TCUCYFT7.js.map +0 -1
- package/dist/chunk-TVYH4AN7.js.map +0 -1
- package/dist/chunk-TYHR4VNM.js.map +0 -1
- package/dist/chunk-VAXCXZ53.js.map +0 -1
- package/dist/chunk-XNIYSAMJ.js.map +0 -1
- package/dist/chunk-Y2YA7QRF.js +0 -17
- package/dist/chunk-Y2YA7QRF.js.map +0 -1
- package/src/tokens/avatar.css +0 -24
- package/src/tokens/icons.css +0 -11
- package/src/tokens/layers.css +0 -11
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
@layer zyncat.tokens, zyncat.components;
|
|
1
|
+
@layer zyncat.reset, zyncat.tokens, zyncat.components;
|
|
2
2
|
|
|
3
3
|
@layer zyncat.components {
|
|
4
|
-
|
|
5
|
-
surface tokens so the <Button>/<Checkbox>/<Collapse> it dogfoods render natively.
|
|
6
|
-
|
|
7
|
-
Collapsed it's a small pill (gauge + current factor); opening morphs it into the full panel.
|
|
8
|
-
The width eases (CSS transition) in step with the <Collapse>-driven body height, so it grows
|
|
9
|
-
as one piece and never teleports. Everything that would change size on open lives INSIDE the
|
|
10
|
-
Collapse, so nothing clips while the pill is still narrow.
|
|
11
|
-
|
|
12
|
-
The one non-negotiable trick: it RESETS --duration-* to their canonical values on its own
|
|
13
|
-
root. The engine scales those tokens globally to slow the app; without this local reset the
|
|
14
|
-
panel's own controls - and this very expand/collapse - would slow down with everything else.
|
|
15
|
-
A motion debugger must stay crisp while the app runs in slow-mo. Token fallbacks keep it
|
|
16
|
-
legible if dropped in without the base layer. */
|
|
17
|
-
|
|
18
|
-
.mdt {
|
|
4
|
+
.zc-mdt {
|
|
19
5
|
/* immune to the global slow-mo the engine applies to --duration-* */
|
|
20
6
|
--duration-fast: 140ms;
|
|
21
7
|
--duration-base: 200ms;
|
|
@@ -27,38 +13,35 @@
|
|
|
27
13
|
|
|
28
14
|
--mdt-offset: 16px;
|
|
29
15
|
--mdt-surface: color-mix(in oklab, var(--bg-surface, #fff) 88%, transparent);
|
|
16
|
+
--_mdt-body-max: calc(100dvh - var(--mdt-offset) * 2 - 3.25rem);
|
|
30
17
|
|
|
31
18
|
position: fixed;
|
|
32
|
-
z-index:
|
|
19
|
+
z-index: var(--layer-infinity, 2147483647);
|
|
33
20
|
display: flex;
|
|
34
21
|
color: var(--text-body, oklch(0.35 0.01 264));
|
|
35
|
-
font-family: var(--font-
|
|
22
|
+
font-family: var(--font-body, ui-sans-serif, system-ui, sans-serif);
|
|
36
23
|
-webkit-font-smoothing: antialiased;
|
|
37
24
|
}
|
|
38
25
|
|
|
39
|
-
.mdt--top-left {
|
|
26
|
+
.zc-mdt--top-left {
|
|
40
27
|
top: var(--mdt-offset);
|
|
41
28
|
left: var(--mdt-offset);
|
|
42
29
|
}
|
|
43
|
-
.mdt--top-right {
|
|
30
|
+
.zc-mdt--top-right {
|
|
44
31
|
top: var(--mdt-offset);
|
|
45
32
|
right: var(--mdt-offset);
|
|
46
33
|
}
|
|
47
|
-
.mdt--bottom-left {
|
|
34
|
+
.zc-mdt--bottom-left {
|
|
48
35
|
bottom: var(--mdt-offset);
|
|
49
36
|
left: var(--mdt-offset);
|
|
50
37
|
}
|
|
51
|
-
.mdt--bottom-right {
|
|
38
|
+
.zc-mdt--bottom-right {
|
|
52
39
|
bottom: var(--mdt-offset);
|
|
53
40
|
right: var(--mdt-offset);
|
|
54
41
|
}
|
|
55
42
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
.mdt__panel {
|
|
43
|
+
.zc-mdt__panel {
|
|
59
44
|
box-sizing: border-box;
|
|
60
|
-
/* Compact pill when collapsed; eases to the full panel width in step with the <Collapse>
|
|
61
|
-
body height below, so the whole thing morphs open and never teleports. */
|
|
62
45
|
width: 128px;
|
|
63
46
|
padding: 5px;
|
|
64
47
|
border: 1px solid var(--border-subtle, oklch(0.92 0.004 264));
|
|
@@ -72,7 +55,7 @@
|
|
|
72
55
|
width var(--duration-slow) var(--ease-entrance, ease),
|
|
73
56
|
box-shadow var(--duration-slow) var(--ease-entrance, ease);
|
|
74
57
|
}
|
|
75
|
-
.mdt__panel.is-open {
|
|
58
|
+
.zc-mdt__panel.zc-is-open {
|
|
76
59
|
width: 232px;
|
|
77
60
|
box-shadow: var(--shadow-xl, 0 24px 48px oklch(0 0 0 / 0.16));
|
|
78
61
|
}
|
|
@@ -84,9 +67,7 @@
|
|
|
84
67
|
}
|
|
85
68
|
}
|
|
86
69
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
.mdt__head {
|
|
70
|
+
.zc-mdt__head {
|
|
90
71
|
appearance: none;
|
|
91
72
|
width: 100%;
|
|
92
73
|
display: flex;
|
|
@@ -102,29 +83,39 @@
|
|
|
102
83
|
cursor: pointer;
|
|
103
84
|
transition: background var(--duration-fast) var(--ease-standard, ease);
|
|
104
85
|
}
|
|
105
|
-
.mdt__head:hover {
|
|
86
|
+
.zc-mdt__head:hover {
|
|
106
87
|
background: var(--neutral-wash, oklch(0.5 0.01 264 / 0.07));
|
|
107
88
|
}
|
|
108
|
-
.mdt__head:focus-visible {
|
|
109
|
-
outline:
|
|
110
|
-
|
|
89
|
+
.zc-mdt__head:focus-visible {
|
|
90
|
+
outline: var(--ring-accent, 3px solid oklch(0.7 0.12 185 / 0.35));
|
|
91
|
+
}
|
|
92
|
+
.zc-mdt--draggable .zc-mdt__head {
|
|
93
|
+
cursor: grab;
|
|
94
|
+
touch-action: none;
|
|
95
|
+
}
|
|
96
|
+
.zc-mdt[data-dragging] {
|
|
97
|
+
user-select: none;
|
|
98
|
+
}
|
|
99
|
+
.zc-mdt[data-dragging] .zc-mdt__head {
|
|
100
|
+
cursor: grabbing;
|
|
101
|
+
background: var(--neutral-wash, oklch(0.5 0.01 264 / 0.07));
|
|
111
102
|
}
|
|
112
103
|
|
|
113
|
-
.mdt__glyph {
|
|
104
|
+
.zc-mdt__glyph {
|
|
114
105
|
color: var(--text-subtle, oklch(0.6 0.01 264));
|
|
115
106
|
flex: none;
|
|
116
107
|
display: block;
|
|
117
108
|
}
|
|
118
|
-
.mdt--active .mdt__glyph {
|
|
109
|
+
.zc-mdt--active .zc-mdt__glyph {
|
|
119
110
|
color: var(--accent, oklch(0.62 0.12 185));
|
|
120
111
|
}
|
|
121
|
-
.mdt--paused .mdt__glyph {
|
|
112
|
+
.zc-mdt--paused .zc-mdt__glyph {
|
|
122
113
|
color: var(--warning, oklch(0.72 0.13 75));
|
|
123
114
|
}
|
|
124
|
-
.mdt__spacer {
|
|
115
|
+
.zc-mdt__spacer {
|
|
125
116
|
flex: 1;
|
|
126
117
|
}
|
|
127
|
-
.mdt__badge {
|
|
118
|
+
.zc-mdt__badge {
|
|
128
119
|
font-size: 0.75rem;
|
|
129
120
|
font-weight: 650;
|
|
130
121
|
font-variant-numeric: tabular-nums;
|
|
@@ -135,64 +126,64 @@
|
|
|
135
126
|
background: var(--neutral-wash, oklch(0.5 0.01 264 / 0.08));
|
|
136
127
|
white-space: nowrap;
|
|
137
128
|
}
|
|
138
|
-
.mdt--active .mdt__badge {
|
|
129
|
+
.zc-mdt--active .zc-mdt__badge {
|
|
139
130
|
color: var(--text-on-accent, #fff);
|
|
140
131
|
background: var(--accent, oklch(0.62 0.12 185));
|
|
141
132
|
}
|
|
142
|
-
.mdt--paused .mdt__badge {
|
|
133
|
+
.zc-mdt--paused .zc-mdt__badge {
|
|
143
134
|
color: var(--text-on-accent, #fff);
|
|
144
135
|
background: var(--warning, oklch(0.72 0.13 75));
|
|
145
136
|
}
|
|
146
|
-
.mdt__chevron {
|
|
137
|
+
.zc-mdt__chevron {
|
|
147
138
|
color: var(--text-subtle, oklch(0.6 0.01 264));
|
|
148
139
|
flex: none;
|
|
149
140
|
transition: transform var(--duration-base) var(--ease-standard, ease);
|
|
150
141
|
}
|
|
151
|
-
.mdt__chevron--open {
|
|
142
|
+
.zc-mdt__chevron--open {
|
|
152
143
|
transform: rotate(180deg);
|
|
153
144
|
}
|
|
154
145
|
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
.mdt__body {
|
|
146
|
+
.zc-mdt__body {
|
|
158
147
|
box-sizing: border-box;
|
|
159
|
-
/* Hold a stable layout width so controls don't reflow as the card animates open; the
|
|
160
|
-
collapsed pill is narrower, so this overflows and is clipped by <Collapse>'s overflow. */
|
|
161
148
|
width: 100%;
|
|
162
|
-
min-width: 208px;
|
|
149
|
+
min-width: 208px; /* wider than the collapsed pill on purpose: the controls never reflow while it opens */
|
|
150
|
+
max-height: var(--_mdt-body-max);
|
|
151
|
+
overflow-y: auto;
|
|
152
|
+
scrollbar-width: thin;
|
|
153
|
+
scroll-padding-block: var(--ring-gutter, 3px);
|
|
163
154
|
display: flex;
|
|
164
155
|
flex-direction: column;
|
|
165
156
|
gap: 0.8125rem;
|
|
166
157
|
padding: 0.625rem 0.375rem 0.375rem;
|
|
167
158
|
}
|
|
168
159
|
|
|
169
|
-
.mdt__title {
|
|
160
|
+
.zc-mdt__title {
|
|
170
161
|
font-size: 0.6875rem;
|
|
171
162
|
font-weight: 650;
|
|
172
163
|
letter-spacing: 0.06em;
|
|
173
164
|
text-transform: uppercase;
|
|
174
165
|
color: var(--text-subtle, oklch(0.6 0.01 264));
|
|
175
166
|
}
|
|
176
|
-
.mdt__readout {
|
|
167
|
+
.zc-mdt__readout {
|
|
177
168
|
display: flex;
|
|
178
169
|
align-items: baseline;
|
|
179
170
|
gap: 0.375rem;
|
|
180
171
|
margin-top: -0.375rem;
|
|
181
172
|
}
|
|
182
|
-
.mdt__value {
|
|
173
|
+
.zc-mdt__value {
|
|
183
174
|
font-size: 1.5rem;
|
|
184
175
|
font-weight: 700;
|
|
185
176
|
font-variant-numeric: tabular-nums;
|
|
186
177
|
line-height: 1;
|
|
187
178
|
color: var(--text-strong, oklch(0.25 0.01 264));
|
|
188
179
|
}
|
|
189
|
-
.mdt__unit {
|
|
180
|
+
.zc-mdt__unit {
|
|
190
181
|
font-size: 0.75rem;
|
|
191
182
|
color: var(--text-muted, oklch(0.55 0.01 264));
|
|
192
183
|
font-weight: 500;
|
|
193
184
|
}
|
|
194
185
|
|
|
195
|
-
.mdt__slider {
|
|
186
|
+
.zc-mdt__slider {
|
|
196
187
|
-webkit-appearance: none;
|
|
197
188
|
appearance: none;
|
|
198
189
|
width: 100%;
|
|
@@ -207,7 +198,7 @@
|
|
|
207
198
|
cursor: pointer;
|
|
208
199
|
margin: 0;
|
|
209
200
|
}
|
|
210
|
-
.mdt__slider::-webkit-slider-thumb {
|
|
201
|
+
.zc-mdt__slider::-webkit-slider-thumb {
|
|
211
202
|
-webkit-appearance: none;
|
|
212
203
|
appearance: none;
|
|
213
204
|
width: 16px;
|
|
@@ -217,7 +208,7 @@
|
|
|
217
208
|
border: 2px solid var(--accent, oklch(0.62 0.12 185));
|
|
218
209
|
box-shadow: var(--shadow-sm, 0 1px 2px oklch(0 0 0 / 0.15));
|
|
219
210
|
}
|
|
220
|
-
.mdt__slider::-moz-range-thumb {
|
|
211
|
+
.zc-mdt__slider::-moz-range-thumb {
|
|
221
212
|
width: 16px;
|
|
222
213
|
height: 16px;
|
|
223
214
|
border-radius: 50%;
|
|
@@ -225,45 +216,103 @@
|
|
|
225
216
|
border: 2px solid var(--accent, oklch(0.62 0.12 185));
|
|
226
217
|
box-shadow: var(--shadow-sm, 0 1px 2px oklch(0 0 0 / 0.15));
|
|
227
218
|
}
|
|
228
|
-
.mdt__slider:focus-visible {
|
|
219
|
+
.zc-mdt__slider:focus-visible {
|
|
229
220
|
outline: none;
|
|
230
221
|
}
|
|
231
|
-
.mdt__slider:focus-visible::-webkit-slider-thumb {
|
|
232
|
-
|
|
222
|
+
.zc-mdt__slider:focus-visible::-webkit-slider-thumb {
|
|
223
|
+
outline: var(--ring-accent, 3px solid oklch(0.7 0.12 185 / 0.35));
|
|
233
224
|
}
|
|
234
|
-
.mdt__slider:focus-visible::-moz-range-thumb {
|
|
235
|
-
|
|
225
|
+
.zc-mdt__slider:focus-visible::-moz-range-thumb {
|
|
226
|
+
outline: var(--ring-accent, 3px solid oklch(0.7 0.12 185 / 0.35));
|
|
236
227
|
}
|
|
237
228
|
|
|
238
|
-
|
|
239
|
-
.mdt__chips {
|
|
229
|
+
.zc-mdt__chips {
|
|
240
230
|
display: grid;
|
|
241
231
|
grid-template-columns: repeat(5, 1fr);
|
|
242
232
|
gap: 0.25rem;
|
|
243
233
|
}
|
|
244
|
-
.mdt__chips .btn {
|
|
234
|
+
.zc-mdt__chips .zc-btn {
|
|
245
235
|
padding-inline: 0;
|
|
246
236
|
min-width: 0;
|
|
247
237
|
}
|
|
248
|
-
.mdt__row {
|
|
238
|
+
.zc-mdt__row {
|
|
249
239
|
display: flex;
|
|
250
240
|
gap: 0.375rem;
|
|
251
241
|
}
|
|
252
|
-
.mdt__row .btn {
|
|
242
|
+
.zc-mdt__row .zc-btn {
|
|
253
243
|
flex: 1;
|
|
254
244
|
}
|
|
255
245
|
|
|
256
|
-
.mdt__opt {
|
|
246
|
+
.zc-mdt__opt {
|
|
257
247
|
border-top: 1px solid var(--border-subtle, oklch(0.92 0.004 264));
|
|
258
248
|
padding-top: 0.75rem;
|
|
259
249
|
display: flex;
|
|
260
250
|
flex-direction: column;
|
|
261
251
|
gap: 0.5rem;
|
|
262
252
|
}
|
|
263
|
-
.mdt__hint {
|
|
253
|
+
.zc-mdt__hint {
|
|
264
254
|
font-size: 0.6875rem;
|
|
265
255
|
line-height: 1.45;
|
|
266
256
|
color: var(--text-subtle, oklch(0.6 0.01 264));
|
|
257
|
+
margin: 0.5rem 0 0;
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
.zc-mdt__more {
|
|
261
|
+
appearance: none;
|
|
262
|
+
display: flex;
|
|
263
|
+
align-items: center;
|
|
264
|
+
justify-content: space-between;
|
|
265
|
+
width: 100%;
|
|
266
|
+
padding: 0.125rem 0;
|
|
267
|
+
border: 0;
|
|
268
|
+
border-radius: var(--radius-sm, 0.25rem);
|
|
269
|
+
background: transparent;
|
|
270
|
+
color: var(--text-subtle, oklch(0.6 0.01 264));
|
|
271
|
+
font: inherit;
|
|
272
|
+
font-size: 0.6875rem;
|
|
273
|
+
font-weight: 650;
|
|
274
|
+
letter-spacing: 0.06em;
|
|
275
|
+
text-transform: uppercase;
|
|
276
|
+
cursor: pointer;
|
|
277
|
+
}
|
|
278
|
+
.zc-mdt__more:hover {
|
|
279
|
+
color: var(--text-body, oklch(0.35 0.01 264));
|
|
280
|
+
}
|
|
281
|
+
.zc-mdt__more:focus-visible {
|
|
282
|
+
outline: var(--ring-accent, 3px solid oklch(0.7 0.12 185 / 0.35));
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
.zc-mdt__keys {
|
|
286
|
+
display: flex;
|
|
287
|
+
flex-direction: column;
|
|
288
|
+
gap: 0.3125rem;
|
|
289
|
+
margin: 0.125rem 0 0;
|
|
290
|
+
}
|
|
291
|
+
.zc-mdt__keyrow {
|
|
292
|
+
display: flex;
|
|
293
|
+
align-items: center;
|
|
294
|
+
justify-content: space-between;
|
|
295
|
+
gap: 0.5rem;
|
|
296
|
+
}
|
|
297
|
+
.zc-mdt__keyrow dt {
|
|
298
|
+
font-size: 0.6875rem;
|
|
299
|
+
color: var(--text-muted, oklch(0.55 0.01 264));
|
|
300
|
+
}
|
|
301
|
+
.zc-mdt__keyrow dd {
|
|
302
|
+
display: flex;
|
|
303
|
+
gap: 0.1875rem;
|
|
267
304
|
margin: 0;
|
|
268
305
|
}
|
|
306
|
+
.zc-mdt__key {
|
|
307
|
+
min-width: 1.125rem;
|
|
308
|
+
padding: 0.0625rem 0.25rem;
|
|
309
|
+
border: 1px solid var(--border-subtle, oklch(0.92 0.004 264));
|
|
310
|
+
border-radius: var(--radius-sm, 0.25rem);
|
|
311
|
+
background: var(--bg-muted, oklch(0.97 0.004 264));
|
|
312
|
+
color: var(--text-subtle, oklch(0.6 0.01 264));
|
|
313
|
+
font-family: var(--font-code, ui-monospace, SFMono-Regular, Menlo, monospace);
|
|
314
|
+
font-size: 0.625rem;
|
|
315
|
+
line-height: 1.4;
|
|
316
|
+
text-align: center;
|
|
317
|
+
}
|
|
269
318
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { clock } from '../../engine';
|
|
2
|
+
import { motionDefaults } from '../../tokens/motion-defaults.generated';
|
|
2
3
|
|
|
3
4
|
export interface SlowmoState {
|
|
4
5
|
/** 1 = real time. >1 = that many times slower (4 = quarter speed). */
|
|
@@ -13,15 +14,9 @@ export interface SlowmoOptions {
|
|
|
13
14
|
scaleTimers: boolean;
|
|
14
15
|
}
|
|
15
16
|
|
|
16
|
-
const CANONICAL: Record<string, number> =
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
'--duration-slow': 300,
|
|
20
|
-
'--duration-slower': 450,
|
|
21
|
-
'--duration-slowest': 900,
|
|
22
|
-
'--duration-spin': 600,
|
|
23
|
-
'--duration-pulse': 1600,
|
|
24
|
-
};
|
|
17
|
+
const CANONICAL: Record<string, number> = Object.fromEntries(
|
|
18
|
+
Object.entries(motionDefaults.duration).map(([step, ms]) => [`--duration-${step}`, ms]),
|
|
19
|
+
);
|
|
25
20
|
const DURATION_TOKENS = Object.keys(CANONICAL);
|
|
26
21
|
const COLLAPSED_MS = 4;
|
|
27
22
|
const FROZEN_MS = 600_000;
|
|
@@ -36,6 +31,7 @@ const listeners = new Set<(s: SlowmoState) => void>();
|
|
|
36
31
|
|
|
37
32
|
let active = false;
|
|
38
33
|
let baseMs: Record<string, number> = {};
|
|
34
|
+
let overrideSheet: HTMLStyleElement | null = null;
|
|
39
35
|
|
|
40
36
|
type SetTimer = (handler: TimerHandler, timeout?: number, ...args: unknown[]) => number;
|
|
41
37
|
let origSetTimeout: SetTimer | null = null;
|
|
@@ -53,16 +49,21 @@ function readBaseMs(token: string): number {
|
|
|
53
49
|
}
|
|
54
50
|
|
|
55
51
|
function applyCssTokens() {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
52
|
+
if (!overrideSheet) {
|
|
53
|
+
overrideSheet = document.createElement('style');
|
|
54
|
+
overrideSheet.dataset.zyncatSlowmo = '';
|
|
55
|
+
document.head.append(overrideSheet);
|
|
60
56
|
}
|
|
57
|
+
const declarations = DURATION_TOKENS.map((token) => {
|
|
58
|
+
const ms = state.paused ? FROZEN_MS : baseMs[token] * state.factor;
|
|
59
|
+
return `${token}: ${ms}ms !important;`;
|
|
60
|
+
});
|
|
61
|
+
overrideSheet.textContent = `:root, [data-theme], [data-polarity] { ${declarations.join(' ')} }`;
|
|
61
62
|
}
|
|
62
63
|
|
|
63
64
|
function clearCssTokens() {
|
|
64
|
-
|
|
65
|
-
|
|
65
|
+
overrideSheet?.remove();
|
|
66
|
+
overrideSheet = null;
|
|
66
67
|
}
|
|
67
68
|
|
|
68
69
|
function scaleDelay(delay?: number): number | undefined {
|
|
@@ -25,8 +25,8 @@ const PIXEL_RATIO_CAP = 2;
|
|
|
25
25
|
const PAPER_SLOTS = 5;
|
|
26
26
|
const DEFAULT_WEIGHT = 1;
|
|
27
27
|
const PAPER_KEYS = Array.from({ length: PAPER_SLOTS }, (_, i) => `--confetti-paper-${i + 1}`);
|
|
28
|
-
const REVERSE_KEYS = Array.from({ length: PAPER_SLOTS }, (_, i) => `--
|
|
29
|
-
const SHEEN_KEYS = Array.from({ length: PAPER_SLOTS }, (_, i) => `--
|
|
28
|
+
const REVERSE_KEYS = Array.from({ length: PAPER_SLOTS }, (_, i) => `--_confetti-reverse-${i + 1}`);
|
|
29
|
+
const SHEEN_KEYS = Array.from({ length: PAPER_SLOTS }, (_, i) => `--_confetti-sheen-${i + 1}`);
|
|
30
30
|
const WEIGHTS_KEY = '--confetti-weights';
|
|
31
31
|
|
|
32
32
|
const SCALE_REFERENCE = 700;
|
|
@@ -142,7 +142,7 @@ const CORNER_JITTER = 14;
|
|
|
142
142
|
const CORNER_LAUNCH = 14;
|
|
143
143
|
const CORNER_LAUNCH_JITTER = 12;
|
|
144
144
|
|
|
145
|
-
const VIEWPORT_CLASS = 'confetti--viewport';
|
|
145
|
+
const VIEWPORT_CLASS = 'zc-confetti--viewport';
|
|
146
146
|
|
|
147
147
|
export type ConfettiEmitter = 'sides' | 'top' | 'corners';
|
|
148
148
|
export type ConfettiField = 'container' | 'viewport';
|
|
@@ -714,7 +714,7 @@ export function Confetti({
|
|
|
714
714
|
const canvas = (
|
|
715
715
|
<canvas
|
|
716
716
|
ref={canvasRef}
|
|
717
|
-
className={cx('confetti', field === 'viewport' && VIEWPORT_CLASS, className)}
|
|
717
|
+
className={cx('zc-confetti', field === 'viewport' && VIEWPORT_CLASS, className)}
|
|
718
718
|
style={style}
|
|
719
719
|
aria-hidden="true"
|
|
720
720
|
{...htmlProps}
|
|
@@ -1,31 +1,38 @@
|
|
|
1
|
-
@layer zyncat.tokens, zyncat.components;
|
|
1
|
+
@layer zyncat.reset, zyncat.tokens, zyncat.components;
|
|
2
2
|
|
|
3
3
|
@layer zyncat.components {
|
|
4
|
-
.confetti {
|
|
4
|
+
.zc-confetti {
|
|
5
|
+
/* The five papers a burst draws from. */
|
|
5
6
|
--confetti-paper-1: oklch(0.53 0.2 288);
|
|
6
7
|
--confetti-paper-2: var(--accent);
|
|
7
8
|
--confetti-paper-3: oklch(0.78 0.115 62);
|
|
8
9
|
--confetti-paper-4: oklch(0.67 0.18 12);
|
|
9
10
|
--confetti-paper-5: var(--text-strong);
|
|
11
|
+
/* How often each paper appears, in slot order. */
|
|
10
12
|
--confetti-weights: 1 1 1 1 0.45;
|
|
11
13
|
|
|
14
|
+
/* What the reverse side of a piece darkens toward. */
|
|
12
15
|
--confetti-ink: var(--text-strong);
|
|
16
|
+
/* What the glossy face of a piece brightens toward. */
|
|
13
17
|
--confetti-light: var(--bg-surface);
|
|
18
|
+
/* How far the reverse side leans toward the ink. */
|
|
14
19
|
--confetti-shade: 42%;
|
|
20
|
+
/* How far the glossy face leans toward the light. */
|
|
15
21
|
--confetti-gloss: 66%;
|
|
22
|
+
/* The z-index of a viewport-field burst. */
|
|
16
23
|
--confetti-layer: var(--layer-toast);
|
|
17
24
|
|
|
18
|
-
--
|
|
19
|
-
--
|
|
20
|
-
--
|
|
21
|
-
--
|
|
22
|
-
--
|
|
25
|
+
--_confetti-reverse-1: color-mix(in oklab, var(--confetti-ink) var(--confetti-shade), var(--confetti-paper-1));
|
|
26
|
+
--_confetti-reverse-2: color-mix(in oklab, var(--confetti-ink) var(--confetti-shade), var(--confetti-paper-2));
|
|
27
|
+
--_confetti-reverse-3: color-mix(in oklab, var(--confetti-ink) var(--confetti-shade), var(--confetti-paper-3));
|
|
28
|
+
--_confetti-reverse-4: color-mix(in oklab, var(--confetti-ink) var(--confetti-shade), var(--confetti-paper-4));
|
|
29
|
+
--_confetti-reverse-5: color-mix(in oklab, var(--confetti-ink) var(--confetti-shade), var(--confetti-paper-5));
|
|
23
30
|
|
|
24
|
-
--
|
|
25
|
-
--
|
|
26
|
-
--
|
|
27
|
-
--
|
|
28
|
-
--
|
|
31
|
+
--_confetti-sheen-1: color-mix(in oklab, var(--confetti-light) var(--confetti-gloss), var(--confetti-paper-1));
|
|
32
|
+
--_confetti-sheen-2: color-mix(in oklab, var(--confetti-light) var(--confetti-gloss), var(--confetti-paper-2));
|
|
33
|
+
--_confetti-sheen-3: color-mix(in oklab, var(--confetti-light) var(--confetti-gloss), var(--confetti-paper-3));
|
|
34
|
+
--_confetti-sheen-4: color-mix(in oklab, var(--confetti-light) var(--confetti-gloss), var(--confetti-paper-4));
|
|
35
|
+
--_confetti-sheen-5: color-mix(in oklab, var(--confetti-light) var(--confetti-gloss), var(--confetti-paper-5));
|
|
29
36
|
|
|
30
37
|
position: absolute;
|
|
31
38
|
inset: 0;
|
|
@@ -38,7 +45,7 @@
|
|
|
38
45
|
background: none;
|
|
39
46
|
}
|
|
40
47
|
|
|
41
|
-
.confetti--viewport {
|
|
48
|
+
.zc-confetti--viewport {
|
|
42
49
|
position: fixed;
|
|
43
50
|
z-index: var(--confetti-layer);
|
|
44
51
|
}
|
|
@@ -95,12 +95,12 @@ export function MediaSurface({ media, type, frontClassName, backClassName, front
|
|
|
95
95
|
{backClassName ? (
|
|
96
96
|
<div className={backClassName} style={style} aria-hidden="true">
|
|
97
97
|
{echo}
|
|
98
|
-
{filled ? null : <span className="facebook-feed-media__fill" />}
|
|
98
|
+
{filled ? null : <span className="zc-facebook-feed-media__fill" />}
|
|
99
99
|
</div>
|
|
100
100
|
) : null}
|
|
101
101
|
<div className={frontClassName} style={style} data-ratio={frontRatio}>
|
|
102
102
|
{node}
|
|
103
|
-
{filled ? null : <span className="facebook-feed-media__fill" />}
|
|
103
|
+
{filled ? null : <span className="zc-facebook-feed-media__fill" />}
|
|
104
104
|
</div>
|
|
105
105
|
</>
|
|
106
106
|
);
|