@remix-run/ui 0.2.0 → 0.4.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 +50 -164
- package/dist/accordion/index.d.ts +46 -0
- package/dist/accordion/index.js +142 -0
- package/dist/accordion/index.js.map +1 -0
- package/dist/accordion/primitives.d.ts +104 -0
- package/dist/accordion/primitives.js +312 -0
- package/dist/accordion/primitives.js.map +1 -0
- package/dist/{components/anchor/anchor.d.ts → anchor/index.d.ts} +8 -1
- package/dist/{components/anchor/anchor.js → anchor/index.js} +31 -12
- package/dist/anchor/index.js.map +1 -0
- package/dist/animation/demos/aspect-ratio.d.ts +2 -0
- package/dist/animation/demos/aspect-ratio.js +69 -0
- package/dist/animation/demos/aspect-ratio.js.map +1 -0
- package/dist/animation/demos/bouncy-switch.d.ts +2 -0
- package/dist/animation/demos/bouncy-switch.js +36 -0
- package/dist/animation/demos/bouncy-switch.js.map +1 -0
- package/dist/animation/demos/color-interpolation.d.ts +1 -0
- package/dist/animation/demos/color-interpolation.js +53 -0
- package/dist/animation/demos/color-interpolation.js.map +1 -0
- package/dist/animation/demos/cube.d.ts +2 -0
- package/dist/animation/demos/cube.js +86 -0
- package/dist/animation/demos/cube.js.map +1 -0
- package/dist/animation/demos/default-animate.d.ts +2 -0
- package/dist/animation/demos/default-animate.js +89 -0
- package/dist/animation/demos/default-animate.js.map +1 -0
- package/dist/animation/demos/drag-release.d.ts +24 -0
- package/dist/animation/demos/drag-release.js +96 -0
- package/dist/animation/demos/drag-release.js.map +1 -0
- package/dist/animation/demos/enter.d.ts +1 -0
- package/dist/animation/demos/enter.js +19 -0
- package/dist/animation/demos/enter.js.map +1 -0
- package/dist/animation/demos/exit.d.ts +2 -0
- package/dist/animation/demos/exit.js +58 -0
- package/dist/animation/demos/exit.js.map +1 -0
- package/dist/animation/demos/flip-toggle.d.ts +2 -0
- package/dist/animation/demos/flip-toggle.js +37 -0
- package/dist/animation/demos/flip-toggle.js.map +1 -0
- package/dist/animation/demos/hold-to-confirm.d.ts +13 -0
- package/dist/animation/demos/hold-to-confirm.js +211 -0
- package/dist/animation/demos/hold-to-confirm.js.map +1 -0
- package/dist/animation/demos/html-content.d.ts +2 -0
- package/dist/animation/demos/html-content.js +30 -0
- package/dist/animation/demos/html-content.js.map +1 -0
- package/dist/animation/demos/interruptible-keyframes.d.ts +1 -0
- package/dist/animation/demos/interruptible-keyframes.js +48 -0
- package/dist/animation/demos/interruptible-keyframes.js.map +1 -0
- package/dist/animation/demos/keyframes.d.ts +1 -0
- package/dist/animation/demos/keyframes.js +24 -0
- package/dist/animation/demos/keyframes.js.map +1 -0
- package/dist/animation/demos/material-ripple.d.ts +2 -0
- package/dist/animation/demos/material-ripple.js +127 -0
- package/dist/animation/demos/material-ripple.js.map +1 -0
- package/dist/animation/demos/mixin-presence-list.d.ts +2 -0
- package/dist/animation/demos/mixin-presence-list.js +88 -0
- package/dist/animation/demos/mixin-presence-list.js.map +1 -0
- package/dist/animation/demos/mixin-reclaim.d.ts +2 -0
- package/dist/animation/demos/mixin-reclaim.js +90 -0
- package/dist/animation/demos/mixin-reclaim.js.map +1 -0
- package/dist/animation/demos/multi-state-badge.d.ts +2 -0
- package/dist/animation/demos/multi-state-badge.js +231 -0
- package/dist/animation/demos/multi-state-badge.js.map +1 -0
- package/dist/animation/demos/press.d.ts +2 -0
- package/dist/animation/demos/press.js +63 -0
- package/dist/animation/demos/press.js.map +1 -0
- package/dist/animation/demos/reordering.d.ts +2 -0
- package/dist/animation/demos/reordering.js +53 -0
- package/dist/animation/demos/reordering.js.map +1 -0
- package/dist/animation/demos/rolling-square.d.ts +2 -0
- package/dist/animation/demos/rolling-square.js +42 -0
- package/dist/animation/demos/rolling-square.js.map +1 -0
- package/dist/animation/demos/rotate.d.ts +1 -0
- package/dist/animation/demos/rotate.js +18 -0
- package/dist/animation/demos/rotate.js.map +1 -0
- package/dist/animation/demos/shared-layout.d.ts +2 -0
- package/dist/animation/demos/shared-layout.js +114 -0
- package/dist/animation/demos/shared-layout.js.map +1 -0
- package/dist/animation/demos/transition-options.d.ts +1 -0
- package/dist/animation/demos/transition-options.js +21 -0
- package/dist/animation/demos/transition-options.js.map +1 -0
- package/dist/animation/spring.d.ts +22 -0
- package/dist/animation/spring.js +22 -0
- package/dist/animation/spring.js.map +1 -1
- package/dist/{components/breadcrumbs/breadcrumbs.js → breadcrumbs/index.js} +19 -19
- package/dist/breadcrumbs/index.js.map +1 -0
- package/dist/button/index.d.ts +15 -0
- package/dist/button/index.js +128 -0
- package/dist/button/index.js.map +1 -0
- package/dist/checkbox/index.d.ts +14 -0
- package/dist/checkbox/index.js +125 -0
- package/dist/checkbox/index.js.map +1 -0
- package/dist/combobox/index.d.ts +21 -0
- package/dist/combobox/index.js +58 -0
- package/dist/combobox/index.js.map +1 -0
- package/dist/{components/combobox/combobox.d.ts → combobox/primitives.d.ts} +3 -7
- package/dist/{components/combobox/combobox.js → combobox/primitives.js} +8 -61
- package/dist/combobox/primitives.js.map +1 -0
- package/dist/input/index.d.ts +13 -0
- package/dist/input/index.js +121 -0
- package/dist/input/index.js.map +1 -0
- package/dist/listbox/flash-attribute.js.map +1 -0
- package/dist/{components/listbox/listbox.d.ts → listbox/index.d.ts} +2 -6
- package/dist/{components/listbox/listbox.js → listbox/index.js} +4 -82
- package/dist/listbox/index.js.map +1 -0
- package/dist/menu/hover-aim.js.map +1 -0
- package/dist/menu/index.d.ts +42 -0
- package/dist/menu/index.js +250 -0
- package/dist/menu/index.js.map +1 -0
- package/dist/{components/menu/menu.d.ts → menu/primitives.d.ts} +6 -32
- package/dist/{components/menu/menu.js → menu/primitives.js} +117 -279
- package/dist/menu/primitives.js.map +1 -0
- package/dist/{components/popover/popover.d.ts → popover/index.d.ts} +3 -5
- package/dist/{components/popover/popover.js → popover/index.js} +15 -51
- package/dist/popover/index.js.map +1 -0
- package/dist/{interactions/outside-click/outside-click-mixin.js → popover/outside-click.js} +1 -1
- package/dist/popover/outside-click.js.map +1 -0
- package/dist/popover/scroll-lock.d.ts +1 -0
- package/dist/{utils → popover}/scroll-lock.js +0 -18
- package/dist/popover/scroll-lock.js.map +1 -0
- package/dist/radio/index.d.ts +12 -0
- package/dist/radio/index.js +77 -0
- package/dist/radio/index.js.map +1 -0
- package/dist/runtime/client-entries.d.ts +1 -2
- package/dist/runtime/client-entries.js.map +1 -1
- package/dist/runtime/component.d.ts +2 -2
- package/dist/runtime/component.js +1 -1
- package/dist/runtime/component.js.map +1 -1
- package/dist/runtime/diff-dom.js +194 -21
- package/dist/runtime/diff-dom.js.map +1 -1
- package/dist/runtime/frame.d.ts +7 -0
- package/dist/runtime/frame.js +176 -41
- package/dist/runtime/frame.js.map +1 -1
- package/dist/runtime/jsx.d.ts +2 -3
- package/dist/runtime/jsx.js.map +1 -1
- package/dist/runtime/reconcile.js +11 -5
- package/dist/runtime/reconcile.js.map +1 -1
- package/dist/runtime/vdom.js +3 -0
- package/dist/runtime/vdom.js.map +1 -1
- package/dist/select/index.d.ts +19 -0
- package/dist/select/index.js +95 -0
- package/dist/select/index.js.map +1 -0
- package/dist/select/keydown.js.map +1 -0
- package/dist/{components/select/select.d.ts → select/primitives.d.ts} +4 -6
- package/dist/{components/select/select.js → select/primitives.js} +12 -64
- package/dist/select/primitives.js.map +1 -0
- package/dist/server/stream.js +5 -4
- package/dist/server/stream.js.map +1 -1
- package/dist/shared/focus-styles.d.ts +1 -0
- package/dist/shared/focus-styles.js +2 -0
- package/dist/shared/focus-styles.js.map +1 -0
- package/dist/shared/icons.d.ts +9 -0
- package/dist/shared/icons.js +42 -0
- package/dist/shared/icons.js.map +1 -0
- package/dist/shared/listbox-popover-styles.d.ts +6 -0
- package/dist/shared/listbox-popover-styles.js +137 -0
- package/dist/shared/listbox-popover-styles.js.map +1 -0
- package/dist/shared/style-values.d.ts +78 -0
- package/dist/{theme/presets/rmx-01/index.js → shared/style-values.js} +3 -34
- package/dist/shared/style-values.js.map +1 -0
- package/dist/{interactions/typeahead/typeahead-mixin.js → shared/typeahead.js} +1 -1
- package/dist/shared/typeahead.js.map +1 -0
- package/dist/shared/wait-for-css-transition.js.map +1 -0
- package/dist/shared/wait.js.map +1 -0
- package/dist/style/style.js +27 -10
- package/dist/style/style.js.map +1 -1
- package/dist/tabs/index.d.ts +32 -0
- package/dist/tabs/index.js +157 -0
- package/dist/tabs/index.js.map +1 -0
- package/dist/tabs/primitives.d.ts +57 -0
- package/dist/tabs/primitives.js +238 -0
- package/dist/tabs/primitives.js.map +1 -0
- package/dist/toggle/index.d.ts +9 -0
- package/dist/toggle/index.js +108 -0
- package/dist/toggle/index.js.map +1 -0
- package/dist/toggle/primitives.d.ts +29 -0
- package/dist/toggle/primitives.js +127 -0
- package/dist/toggle/primitives.js.map +1 -0
- package/package.json +74 -45
- package/src/{components/accordion → accordion}/README.md +50 -14
- package/src/accordion/index.tsx +285 -0
- package/src/accordion/primitives.tsx +512 -0
- package/src/{components/anchor → anchor}/README.md +48 -5
- package/src/{components/anchor/anchor.ts → anchor/index.ts} +53 -12
- package/src/animation/demos/aspect-ratio.tsx +120 -0
- package/src/animation/demos/bouncy-switch.tsx +47 -0
- package/src/animation/demos/color-interpolation.tsx +73 -0
- package/src/animation/demos/cube.tsx +116 -0
- package/src/animation/demos/default-animate.tsx +129 -0
- package/src/animation/demos/drag-release.ts +118 -0
- package/src/animation/demos/enter.tsx +22 -0
- package/src/animation/demos/exit.tsx +79 -0
- package/src/animation/demos/flip-toggle.tsx +46 -0
- package/src/animation/demos/hold-to-confirm.tsx +317 -0
- package/src/animation/demos/html-content.tsx +41 -0
- package/src/animation/demos/interruptible-keyframes.tsx +62 -0
- package/src/animation/demos/keyframes.tsx +29 -0
- package/src/animation/demos/material-ripple.tsx +158 -0
- package/src/animation/demos/mixin-presence-list.tsx +121 -0
- package/src/animation/demos/mixin-reclaim.tsx +125 -0
- package/src/animation/demos/multi-state-badge.tsx +426 -0
- package/src/animation/demos/press.tsx +67 -0
- package/src/animation/demos/reordering.tsx +68 -0
- package/src/animation/demos/rolling-square.tsx +57 -0
- package/src/animation/demos/rotate.tsx +21 -0
- package/src/animation/demos/shared-layout.tsx +211 -0
- package/src/animation/demos/transition-options.tsx +24 -0
- package/src/animation/spring.ts +22 -0
- package/src/{components/breadcrumbs → breadcrumbs}/README.md +4 -4
- package/src/{components/breadcrumbs/breadcrumbs.tsx → breadcrumbs/index.tsx} +18 -18
- package/src/button/README.md +44 -0
- package/src/button/index.ts +168 -0
- package/src/checkbox/README.md +59 -0
- package/src/checkbox/index.ts +162 -0
- package/src/{components/combobox → combobox}/README.md +58 -9
- package/src/combobox/index.tsx +112 -0
- package/src/{components/combobox/combobox.tsx → combobox/primitives.tsx} +5 -91
- package/src/input/README.md +52 -0
- package/src/input/index.ts +147 -0
- package/src/{components/listbox → listbox}/README.md +9 -41
- package/src/{components/listbox/listbox.ts → listbox/index.ts} +2 -87
- package/src/menu/README.md +161 -0
- package/src/menu/index.tsx +354 -0
- package/src/{components/menu/menu.tsx → menu/primitives.tsx} +117 -359
- package/src/{components/popover → popover}/README.md +20 -39
- package/src/{components/popover/popover.ts → popover/index.ts} +16 -61
- package/src/{utils → popover}/scroll-lock.ts +0 -28
- package/src/radio/README.md +53 -0
- package/src/radio/index.ts +100 -0
- package/src/runtime/client-entries.ts +1 -5
- package/src/runtime/component.ts +3 -3
- package/src/runtime/demos/readme.demo.tsx +704 -0
- package/src/runtime/diff-dom.ts +270 -20
- package/src/runtime/frame.ts +218 -41
- package/src/runtime/jsx.ts +6 -10
- package/src/runtime/reconcile.ts +11 -5
- package/src/runtime/vdom.ts +3 -0
- package/src/{components/select → select}/README.md +29 -19
- package/src/select/index.tsx +159 -0
- package/src/{components/select/select.tsx → select/primitives.tsx} +11 -99
- package/src/server/stream.ts +10 -5
- package/src/shared/focus-styles.ts +2 -0
- package/src/shared/icons.tsx +62 -0
- package/src/shared/listbox-popover-styles.ts +146 -0
- package/src/shared/style-values.ts +165 -0
- package/src/style/style.ts +29 -10
- package/src/tabs/README.md +141 -0
- package/src/tabs/index.tsx +244 -0
- package/src/tabs/primitives.ts +365 -0
- package/src/toggle/README.md +56 -0
- package/src/toggle/index.tsx +134 -0
- package/src/toggle/primitives.ts +192 -0
- package/dist/components/accordion/accordion.d.ts +0 -92
- package/dist/components/accordion/accordion.js +0 -335
- package/dist/components/accordion/accordion.js.map +0 -1
- package/dist/components/accordion/demos/card.demo.d.ts +0 -6
- package/dist/components/accordion/demos/card.demo.js +0 -58
- package/dist/components/accordion/demos/card.demo.js.map +0 -1
- package/dist/components/accordion/demos/multiple.demo.d.ts +0 -6
- package/dist/components/accordion/demos/multiple.demo.js +0 -19
- package/dist/components/accordion/demos/multiple.demo.js.map +0 -1
- package/dist/components/accordion/demos/overview.demo.d.ts +0 -6
- package/dist/components/accordion/demos/overview.demo.js +0 -19
- package/dist/components/accordion/demos/overview.demo.js.map +0 -1
- package/dist/components/anchor/anchor.js.map +0 -1
- package/dist/components/breadcrumbs/breadcrumbs.js.map +0 -1
- package/dist/components/breadcrumbs/demos/basic.demo.d.ts +0 -5
- package/dist/components/breadcrumbs/demos/basic.demo.js +0 -14
- package/dist/components/breadcrumbs/demos/basic.demo.js.map +0 -1
- package/dist/components/breadcrumbs/demos/separator.demo.d.ts +0 -5
- package/dist/components/breadcrumbs/demos/separator.demo.js +0 -14
- package/dist/components/breadcrumbs/demos/separator.demo.js.map +0 -1
- package/dist/components/button/button.d.ts +0 -105
- package/dist/components/button/button.js +0 -207
- package/dist/components/button/button.js.map +0 -1
- package/dist/components/button/demos/aliases.demo.d.ts +0 -6
- package/dist/components/button/demos/aliases.demo.js +0 -18
- package/dist/components/button/demos/aliases.demo.js.map +0 -1
- package/dist/components/button/demos/basic.demo.d.ts +0 -6
- package/dist/components/button/demos/basic.demo.js +0 -19
- package/dist/components/button/demos/basic.demo.js.map +0 -1
- package/dist/components/button/demos/states.demo.d.ts +0 -6
- package/dist/components/button/demos/states.demo.js +0 -29
- package/dist/components/button/demos/states.demo.js.map +0 -1
- package/dist/components/combobox/combobox.js.map +0 -1
- package/dist/components/combobox/demos/overview.demo.d.ts +0 -6
- package/dist/components/combobox/demos/overview.demo.js +0 -153
- package/dist/components/combobox/demos/overview.demo.js.map +0 -1
- package/dist/components/glyph/glyph.d.ts +0 -14
- package/dist/components/glyph/glyph.js +0 -65
- package/dist/components/glyph/glyph.js.map +0 -1
- package/dist/components/listbox/demos/overview.demo.d.ts +0 -6
- package/dist/components/listbox/demos/overview.demo.js +0 -64
- package/dist/components/listbox/demos/overview.demo.js.map +0 -1
- package/dist/components/listbox/listbox.js.map +0 -1
- package/dist/components/menu/demos/bubbling.demo.d.ts +0 -5
- package/dist/components/menu/demos/bubbling.demo.js +0 -15
- package/dist/components/menu/demos/bubbling.demo.js.map +0 -1
- package/dist/components/menu/demos/overview.demo.d.ts +0 -6
- package/dist/components/menu/demos/overview.demo.js +0 -32
- package/dist/components/menu/demos/overview.demo.js.map +0 -1
- package/dist/components/menu/hover-aim.js.map +0 -1
- package/dist/components/menu/menu.js.map +0 -1
- package/dist/components/popover/demos/overview.demo.d.ts +0 -6
- package/dist/components/popover/demos/overview.demo.js +0 -64
- package/dist/components/popover/demos/overview.demo.js.map +0 -1
- package/dist/components/popover/popover.js.map +0 -1
- package/dist/components/select/demos/deconstructed.demo.d.ts +0 -6
- package/dist/components/select/demos/deconstructed.demo.js +0 -53
- package/dist/components/select/demos/deconstructed.demo.js.map +0 -1
- package/dist/components/select/demos/overview.demo.d.ts +0 -5
- package/dist/components/select/demos/overview.demo.js +0 -27
- package/dist/components/select/demos/overview.demo.js.map +0 -1
- package/dist/components/select/select.js.map +0 -1
- package/dist/components/separator/separator.d.ts +0 -2
- package/dist/components/separator/separator.js +0 -15
- package/dist/components/separator/separator.js.map +0 -1
- package/dist/components/tabs/tabs.d.ts +0 -78
- package/dist/components/tabs/tabs.js +0 -339
- package/dist/components/tabs/tabs.js.map +0 -1
- package/dist/interactions/keydown/keydown.js.map +0 -1
- package/dist/interactions/outside-click/outside-click-mixin.js.map +0 -1
- package/dist/interactions/typeahead/typeahead-mixin.js.map +0 -1
- package/dist/theme/contract.d.ts +0 -61
- package/dist/theme/contract.js +0 -131
- package/dist/theme/contract.js.map +0 -1
- package/dist/theme/glyph-contract.d.ts +0 -11
- package/dist/theme/glyph-contract.js +0 -34
- package/dist/theme/glyph-contract.js.map +0 -1
- package/dist/theme/presets/rmx-01/glyphs.d.ts +0 -2
- package/dist/theme/presets/rmx-01/glyphs.js +0 -252
- package/dist/theme/presets/rmx-01/glyphs.js.map +0 -1
- package/dist/theme/presets/rmx-01/index.d.ts +0 -4
- package/dist/theme/presets/rmx-01/index.js.map +0 -1
- package/dist/theme/runtime.d.ts +0 -2
- package/dist/theme/runtime.js +0 -84
- package/dist/theme/runtime.js.map +0 -1
- package/dist/theme/theme.d.ts +0 -6
- package/dist/theme/theme.js +0 -5
- package/dist/theme/theme.js.map +0 -1
- package/dist/utils/flash-attribute.js.map +0 -1
- package/dist/utils/scroll-lock.d.ts +0 -3
- package/dist/utils/scroll-lock.js.map +0 -1
- package/dist/utils/wait-for-css-transition.js.map +0 -1
- package/dist/utils/wait.js.map +0 -1
- package/src/components/accordion/accordion.tsx +0 -565
- package/src/components/accordion/demos/card.demo.tsx +0 -113
- package/src/components/accordion/demos/multiple.demo.tsx +0 -56
- package/src/components/accordion/demos/overview.demo.tsx +0 -56
- package/src/components/breadcrumbs/demos/basic.demo.tsx +0 -17
- package/src/components/breadcrumbs/demos/separator.demo.tsx +0 -18
- package/src/components/button/README.md +0 -44
- package/src/components/button/button.tsx +0 -286
- package/src/components/button/demos/aliases.demo.tsx +0 -27
- package/src/components/button/demos/basic.demo.tsx +0 -30
- package/src/components/button/demos/states.demo.tsx +0 -52
- package/src/components/combobox/demos/overview.demo.tsx +0 -199
- package/src/components/glyph/README.md +0 -72
- package/src/components/glyph/glyph.tsx +0 -110
- package/src/components/listbox/demos/overview.demo.tsx +0 -101
- package/src/components/menu/README.md +0 -96
- package/src/components/menu/demos/bubbling.demo.tsx +0 -34
- package/src/components/menu/demos/overview.demo.tsx +0 -76
- package/src/components/popover/demos/overview.demo.tsx +0 -143
- package/src/components/select/demos/deconstructed.demo.tsx +0 -95
- package/src/components/select/demos/overview.demo.tsx +0 -51
- package/src/components/separator/separator.ts +0 -19
- package/src/components/tabs/README.md +0 -105
- package/src/components/tabs/tabs.tsx +0 -504
- package/src/theme/README.md +0 -103
- package/src/theme/contract.ts +0 -215
- package/src/theme/glyph-contract.ts +0 -59
- package/src/theme/presets/rmx-01/glyphs.tsx +0 -308
- package/src/theme/presets/rmx-01/index.ts +0 -123
- package/src/theme/runtime.ts +0 -119
- package/src/theme/theme.ts +0 -15
- package/src/utils/scroll-lock/README.md +0 -33
- /package/dist/{components/breadcrumbs/breadcrumbs.d.ts → breadcrumbs/index.d.ts} +0 -0
- /package/dist/{utils → listbox}/flash-attribute.d.ts +0 -0
- /package/dist/{utils → listbox}/flash-attribute.js +0 -0
- /package/dist/{components/menu → menu}/hover-aim.d.ts +0 -0
- /package/dist/{components/menu → menu}/hover-aim.js +0 -0
- /package/dist/{interactions/outside-click/outside-click-mixin.d.ts → popover/outside-click.d.ts} +0 -0
- /package/dist/{interactions/keydown → select}/keydown.d.ts +0 -0
- /package/dist/{interactions/keydown → select}/keydown.js +0 -0
- /package/dist/{interactions/typeahead/typeahead-mixin.d.ts → shared/typeahead.d.ts} +0 -0
- /package/dist/{utils → shared}/wait-for-css-transition.d.ts +0 -0
- /package/dist/{utils → shared}/wait-for-css-transition.js +0 -0
- /package/dist/{utils → shared}/wait.d.ts +0 -0
- /package/dist/{utils → shared}/wait.js +0 -0
- /package/src/{utils → listbox}/flash-attribute.ts +0 -0
- /package/src/{components/menu → menu}/hover-aim.ts +0 -0
- /package/src/{interactions/outside-click/outside-click-mixin.ts → popover/outside-click.ts} +0 -0
- /package/src/{interactions/keydown → select}/keydown.ts +0 -0
- /package/src/{interactions/typeahead/typeahead-mixin.ts → shared/typeahead.ts} +0 -0
- /package/src/{utils → shared}/wait-for-css-transition.ts +0 -0
- /package/src/{utils → shared}/wait.ts +0 -0
package/src/theme/contract.ts
DELETED
|
@@ -1,215 +0,0 @@
|
|
|
1
|
-
import type { css, Handle, MixinDescriptor, RemixElement } from '@remix-run/ui'
|
|
2
|
-
|
|
3
|
-
export interface ThemeVariableTree {
|
|
4
|
-
[key: string]: string | ThemeVariableTree
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
type ThemeVariableGroup<key extends string> = Readonly<Record<key, string>>
|
|
8
|
-
type ThemeActionVariableGroup = ThemeVariableGroup<
|
|
9
|
-
'background' | 'backgroundHover' | 'backgroundActive' | 'foreground' | 'border'
|
|
10
|
-
>
|
|
11
|
-
|
|
12
|
-
type ThemeVariableNames = {
|
|
13
|
-
readonly space: ThemeVariableGroup<'none' | 'px' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl'>
|
|
14
|
-
readonly radius: ThemeVariableGroup<'none' | 'sm' | 'md' | 'lg' | 'xl' | 'full'>
|
|
15
|
-
readonly fontFamily: ThemeVariableGroup<'sans' | 'mono'>
|
|
16
|
-
readonly fontSize: ThemeVariableGroup<'xxxs' | 'xxs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl'>
|
|
17
|
-
readonly lineHeight: ThemeVariableGroup<'tight' | 'normal' | 'relaxed'>
|
|
18
|
-
readonly letterSpacing: ThemeVariableGroup<'tight' | 'normal' | 'meta' | 'wide'>
|
|
19
|
-
readonly fontWeight: ThemeVariableGroup<'normal' | 'medium' | 'semibold' | 'bold'>
|
|
20
|
-
readonly control: {
|
|
21
|
-
readonly height: ThemeVariableGroup<'sm' | 'md' | 'lg'>
|
|
22
|
-
}
|
|
23
|
-
readonly surface: ThemeVariableGroup<'lvl0' | 'lvl1' | 'lvl2' | 'lvl3' | 'lvl4'>
|
|
24
|
-
readonly shadow: ThemeVariableGroup<'xs' | 'sm' | 'md' | 'lg' | 'xl'>
|
|
25
|
-
readonly colors: {
|
|
26
|
-
readonly text: ThemeVariableGroup<'primary' | 'secondary' | 'muted' | 'link'>
|
|
27
|
-
readonly border: ThemeVariableGroup<'subtle' | 'default' | 'strong'>
|
|
28
|
-
readonly focus: ThemeVariableGroup<'ring'>
|
|
29
|
-
readonly overlay: ThemeVariableGroup<'scrim'>
|
|
30
|
-
readonly action: {
|
|
31
|
-
readonly primary: ThemeActionVariableGroup
|
|
32
|
-
readonly secondary: ThemeActionVariableGroup
|
|
33
|
-
readonly danger: ThemeActionVariableGroup
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
const themeVariableNamesSource: ThemeVariableNames = {
|
|
39
|
-
space: {
|
|
40
|
-
none: '--rmx-space-none',
|
|
41
|
-
px: '--rmx-space-px',
|
|
42
|
-
xs: '--rmx-space-xs',
|
|
43
|
-
sm: '--rmx-space-sm',
|
|
44
|
-
md: '--rmx-space-md',
|
|
45
|
-
lg: '--rmx-space-lg',
|
|
46
|
-
xl: '--rmx-space-xl',
|
|
47
|
-
xxl: '--rmx-space-xxl',
|
|
48
|
-
},
|
|
49
|
-
radius: {
|
|
50
|
-
none: '--rmx-radius-none',
|
|
51
|
-
sm: '--rmx-radius-sm',
|
|
52
|
-
md: '--rmx-radius-md',
|
|
53
|
-
lg: '--rmx-radius-lg',
|
|
54
|
-
xl: '--rmx-radius-xl',
|
|
55
|
-
full: '--rmx-radius-full',
|
|
56
|
-
},
|
|
57
|
-
fontFamily: {
|
|
58
|
-
sans: '--rmx-font-family-sans',
|
|
59
|
-
mono: '--rmx-font-family-mono',
|
|
60
|
-
},
|
|
61
|
-
fontSize: {
|
|
62
|
-
xxxs: '--rmx-font-size-xxxs',
|
|
63
|
-
xxs: '--rmx-font-size-xxs',
|
|
64
|
-
xs: '--rmx-font-size-xs',
|
|
65
|
-
sm: '--rmx-font-size-sm',
|
|
66
|
-
md: '--rmx-font-size-md',
|
|
67
|
-
lg: '--rmx-font-size-lg',
|
|
68
|
-
xl: '--rmx-font-size-xl',
|
|
69
|
-
xxl: '--rmx-font-size-xxl',
|
|
70
|
-
},
|
|
71
|
-
lineHeight: {
|
|
72
|
-
tight: '--rmx-line-height-tight',
|
|
73
|
-
normal: '--rmx-line-height-normal',
|
|
74
|
-
relaxed: '--rmx-line-height-relaxed',
|
|
75
|
-
},
|
|
76
|
-
letterSpacing: {
|
|
77
|
-
tight: '--rmx-letter-spacing-tight',
|
|
78
|
-
normal: '--rmx-letter-spacing-normal',
|
|
79
|
-
meta: '--rmx-letter-spacing-meta',
|
|
80
|
-
wide: '--rmx-letter-spacing-wide',
|
|
81
|
-
},
|
|
82
|
-
fontWeight: {
|
|
83
|
-
normal: '--rmx-font-weight-normal',
|
|
84
|
-
medium: '--rmx-font-weight-medium',
|
|
85
|
-
semibold: '--rmx-font-weight-semibold',
|
|
86
|
-
bold: '--rmx-font-weight-bold',
|
|
87
|
-
},
|
|
88
|
-
control: {
|
|
89
|
-
height: {
|
|
90
|
-
sm: '--rmx-control-height-sm',
|
|
91
|
-
md: '--rmx-control-height-md',
|
|
92
|
-
lg: '--rmx-control-height-lg',
|
|
93
|
-
},
|
|
94
|
-
},
|
|
95
|
-
surface: {
|
|
96
|
-
lvl0: '--rmx-surface-lvl0',
|
|
97
|
-
lvl1: '--rmx-surface-lvl1',
|
|
98
|
-
lvl2: '--rmx-surface-lvl2',
|
|
99
|
-
lvl3: '--rmx-surface-lvl3',
|
|
100
|
-
lvl4: '--rmx-surface-lvl4',
|
|
101
|
-
},
|
|
102
|
-
shadow: {
|
|
103
|
-
xs: '--rmx-shadow-xs',
|
|
104
|
-
sm: '--rmx-shadow-sm',
|
|
105
|
-
md: '--rmx-shadow-md',
|
|
106
|
-
lg: '--rmx-shadow-lg',
|
|
107
|
-
xl: '--rmx-shadow-xl',
|
|
108
|
-
},
|
|
109
|
-
colors: {
|
|
110
|
-
text: {
|
|
111
|
-
primary: '--rmx-color-text-primary',
|
|
112
|
-
secondary: '--rmx-color-text-secondary',
|
|
113
|
-
muted: '--rmx-color-text-muted',
|
|
114
|
-
link: '--rmx-color-text-link',
|
|
115
|
-
},
|
|
116
|
-
border: {
|
|
117
|
-
subtle: '--rmx-color-border-subtle',
|
|
118
|
-
default: '--rmx-color-border-default',
|
|
119
|
-
strong: '--rmx-color-border-strong',
|
|
120
|
-
},
|
|
121
|
-
focus: {
|
|
122
|
-
ring: '--rmx-color-focus-ring',
|
|
123
|
-
},
|
|
124
|
-
overlay: {
|
|
125
|
-
scrim: '--rmx-color-overlay-scrim',
|
|
126
|
-
},
|
|
127
|
-
action: {
|
|
128
|
-
primary: {
|
|
129
|
-
background: '--rmx-color-action-primary-background',
|
|
130
|
-
backgroundHover: '--rmx-color-action-primary-background-hover',
|
|
131
|
-
backgroundActive: '--rmx-color-action-primary-background-active',
|
|
132
|
-
foreground: '--rmx-color-action-primary-foreground',
|
|
133
|
-
border: '--rmx-color-action-primary-border',
|
|
134
|
-
},
|
|
135
|
-
secondary: {
|
|
136
|
-
background: '--rmx-color-action-secondary-background',
|
|
137
|
-
backgroundHover: '--rmx-color-action-secondary-background-hover',
|
|
138
|
-
backgroundActive: '--rmx-color-action-secondary-background-active',
|
|
139
|
-
foreground: '--rmx-color-action-secondary-foreground',
|
|
140
|
-
border: '--rmx-color-action-secondary-border',
|
|
141
|
-
},
|
|
142
|
-
danger: {
|
|
143
|
-
background: '--rmx-color-action-danger-background',
|
|
144
|
-
backgroundHover: '--rmx-color-action-danger-background-hover',
|
|
145
|
-
backgroundActive: '--rmx-color-action-danger-background-active',
|
|
146
|
-
foreground: '--rmx-color-action-danger-foreground',
|
|
147
|
-
border: '--rmx-color-action-danger-border',
|
|
148
|
-
},
|
|
149
|
-
},
|
|
150
|
-
},
|
|
151
|
-
} satisfies ThemeVariableTree
|
|
152
|
-
|
|
153
|
-
export const themeVariableNames: ThemeVariableNames = themeVariableNamesSource
|
|
154
|
-
|
|
155
|
-
type MapLeaves<source, leaf> = source extends string
|
|
156
|
-
? leaf
|
|
157
|
-
: {
|
|
158
|
-
[key in keyof source]: MapLeaves<source[key], leaf>
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
export type ThemeValue = string | number
|
|
162
|
-
export type ThemeContract = MapLeaves<ThemeVariableNames, string>
|
|
163
|
-
export type ThemeValues = MapLeaves<typeof themeVariableNames, ThemeValue>
|
|
164
|
-
export type ThemeVars = Readonly<Record<string, string>>
|
|
165
|
-
export type CreateThemeOptions = {
|
|
166
|
-
selector?: string
|
|
167
|
-
reset?: boolean
|
|
168
|
-
}
|
|
169
|
-
export type ThemeStyleProps = {
|
|
170
|
-
nonce?: string
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
type ThemeRenderer = (handle: Handle<ThemeStyleProps>) => () => RemixElement
|
|
174
|
-
|
|
175
|
-
export type ThemeComponent = ThemeRenderer & {
|
|
176
|
-
Style: ThemeRenderer
|
|
177
|
-
cssText: string
|
|
178
|
-
selector: string
|
|
179
|
-
values: ThemeValues
|
|
180
|
-
vars: ThemeVars
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
export const theme: ThemeContract = createThemeContract(themeVariableNames)
|
|
184
|
-
|
|
185
|
-
export type ThemeUtility = ReturnType<typeof css>
|
|
186
|
-
|
|
187
|
-
type ThemeMixLeaf = MixinDescriptor<any, any, any>
|
|
188
|
-
type PreviousThemeMixDepth = [0, 0, 1, 2, 3, 4]
|
|
189
|
-
type NestedThemeMix<value, depth extends number = 4> = depth extends 0
|
|
190
|
-
? value | ReadonlyArray<value>
|
|
191
|
-
: value | ReadonlyArray<NestedThemeMix<value, PreviousThemeMixDepth[depth]>>
|
|
192
|
-
|
|
193
|
-
export type ThemeMix = NestedThemeMix<ThemeMixLeaf>
|
|
194
|
-
|
|
195
|
-
function createThemeContract<tree extends ThemeVariableTree>(tree: tree): MapLeaves<tree, string> {
|
|
196
|
-
return mapTreeLeaves(tree, (variableName) => `var(${variableName})`) as MapLeaves<tree, string>
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
function mapTreeLeaves(
|
|
200
|
-
tree: ThemeVariableTree,
|
|
201
|
-
mapLeaf: (value: string) => string,
|
|
202
|
-
): ThemeVariableTree {
|
|
203
|
-
let output: ThemeVariableTree = {}
|
|
204
|
-
|
|
205
|
-
for (let [key, value] of Object.entries(tree)) {
|
|
206
|
-
if (typeof value === 'string') {
|
|
207
|
-
output[key] = mapLeaf(value)
|
|
208
|
-
continue
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
output[key] = mapTreeLeaves(value, mapLeaf)
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
return output
|
|
215
|
-
}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
import type { RemixElement } from '@remix-run/ui'
|
|
2
|
-
|
|
3
|
-
export const glyphNames = [
|
|
4
|
-
'add',
|
|
5
|
-
'alert',
|
|
6
|
-
'check',
|
|
7
|
-
'chevronDown',
|
|
8
|
-
'chevronVertical',
|
|
9
|
-
'chevronUp',
|
|
10
|
-
'chevronRight',
|
|
11
|
-
'close',
|
|
12
|
-
'copy',
|
|
13
|
-
'edit',
|
|
14
|
-
'expand',
|
|
15
|
-
'info',
|
|
16
|
-
'menu',
|
|
17
|
-
'open',
|
|
18
|
-
'search',
|
|
19
|
-
'spinner',
|
|
20
|
-
'trash',
|
|
21
|
-
] as const
|
|
22
|
-
|
|
23
|
-
export type GlyphName = (typeof glyphNames)[number]
|
|
24
|
-
|
|
25
|
-
export type GlyphSymbol = RemixElement
|
|
26
|
-
|
|
27
|
-
export type GlyphValues = {
|
|
28
|
-
readonly [key in GlyphName]: GlyphSymbol
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export type GlyphContract = Readonly<Record<GlyphName, { id: string }>>
|
|
32
|
-
|
|
33
|
-
const DEFAULT_GLYPH_ID_PREFIX = 'rmx-glyph'
|
|
34
|
-
|
|
35
|
-
export const glyphContract: GlyphContract = Object.freeze(
|
|
36
|
-
createGlyphContract(DEFAULT_GLYPH_ID_PREFIX),
|
|
37
|
-
)
|
|
38
|
-
|
|
39
|
-
function createGlyphIds(idPrefix: string): Record<GlyphName, string> {
|
|
40
|
-
return Object.fromEntries(glyphNames.map((name) => [name, `${idPrefix}-${name}`])) as Record<
|
|
41
|
-
GlyphName,
|
|
42
|
-
string
|
|
43
|
-
>
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
function createGlyphContract(idPrefix: string): GlyphContract {
|
|
47
|
-
let ids = createGlyphIds(idPrefix)
|
|
48
|
-
|
|
49
|
-
return Object.freeze(
|
|
50
|
-
Object.fromEntries(
|
|
51
|
-
glyphNames.map((name) => [
|
|
52
|
-
name,
|
|
53
|
-
{
|
|
54
|
-
id: ids[name],
|
|
55
|
-
},
|
|
56
|
-
]),
|
|
57
|
-
) as GlyphContract,
|
|
58
|
-
)
|
|
59
|
-
}
|
|
@@ -1,308 +0,0 @@
|
|
|
1
|
-
import { createElement } from '@remix-run/ui'
|
|
2
|
-
import type { RemixNode } from '@remix-run/ui'
|
|
3
|
-
|
|
4
|
-
import type { GlyphValues } from '../../glyph-contract.ts'
|
|
5
|
-
|
|
6
|
-
const defaultViewBox = '0 0 16 16'
|
|
7
|
-
|
|
8
|
-
function symbol(...content: RemixNode[]) {
|
|
9
|
-
return createElement('symbol', { viewBox: defaultViewBox }, ...content)
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export const glyphValues: GlyphValues = {
|
|
13
|
-
add: symbol(
|
|
14
|
-
createElement('path', {
|
|
15
|
-
d: 'M8 3.25v9.5M3.25 8h9.5',
|
|
16
|
-
fill: 'none',
|
|
17
|
-
stroke: 'currentColor',
|
|
18
|
-
strokeLinecap: 'round',
|
|
19
|
-
strokeLinejoin: 'round',
|
|
20
|
-
strokeWidth: '1.5',
|
|
21
|
-
}),
|
|
22
|
-
),
|
|
23
|
-
alert: symbol(
|
|
24
|
-
createElement('path', {
|
|
25
|
-
d: 'M8 2.5 13.75 12.5H2.25Z',
|
|
26
|
-
fill: 'none',
|
|
27
|
-
stroke: 'currentColor',
|
|
28
|
-
strokeLinejoin: 'round',
|
|
29
|
-
strokeWidth: '1.5',
|
|
30
|
-
}),
|
|
31
|
-
createElement('path', {
|
|
32
|
-
d: 'M8 5.75v3.5',
|
|
33
|
-
fill: 'none',
|
|
34
|
-
stroke: 'currentColor',
|
|
35
|
-
strokeLinecap: 'round',
|
|
36
|
-
strokeWidth: '1.5',
|
|
37
|
-
}),
|
|
38
|
-
createElement('circle', {
|
|
39
|
-
cx: '8',
|
|
40
|
-
cy: '11.25',
|
|
41
|
-
fill: 'currentColor',
|
|
42
|
-
r: '0.75',
|
|
43
|
-
}),
|
|
44
|
-
),
|
|
45
|
-
check: symbol(
|
|
46
|
-
createElement('path', {
|
|
47
|
-
d: 'm3.5 8.25 2.75 2.75L12.5 4.75',
|
|
48
|
-
fill: 'none',
|
|
49
|
-
stroke: 'currentColor',
|
|
50
|
-
strokeLinecap: 'round',
|
|
51
|
-
strokeLinejoin: 'round',
|
|
52
|
-
strokeWidth: '1.5',
|
|
53
|
-
}),
|
|
54
|
-
),
|
|
55
|
-
chevronDown: symbol(
|
|
56
|
-
createElement('path', {
|
|
57
|
-
d: 'm3.75 6.25 4.25 4 4.25-4',
|
|
58
|
-
fill: 'none',
|
|
59
|
-
stroke: 'currentColor',
|
|
60
|
-
strokeLinecap: 'round',
|
|
61
|
-
strokeLinejoin: 'round',
|
|
62
|
-
strokeWidth: '1.5',
|
|
63
|
-
}),
|
|
64
|
-
),
|
|
65
|
-
chevronVertical: symbol(
|
|
66
|
-
createElement('path', {
|
|
67
|
-
d: 'm3.75 6.5 4.25-4 4.25 4',
|
|
68
|
-
fill: 'none',
|
|
69
|
-
stroke: 'currentColor',
|
|
70
|
-
strokeLinecap: 'round',
|
|
71
|
-
strokeLinejoin: 'round',
|
|
72
|
-
strokeWidth: '1.5',
|
|
73
|
-
}),
|
|
74
|
-
createElement('path', {
|
|
75
|
-
d: 'm3.75 9.5 4.25 4 4.25-4',
|
|
76
|
-
fill: 'none',
|
|
77
|
-
stroke: 'currentColor',
|
|
78
|
-
strokeLinecap: 'round',
|
|
79
|
-
strokeLinejoin: 'round',
|
|
80
|
-
strokeWidth: '1.5',
|
|
81
|
-
}),
|
|
82
|
-
),
|
|
83
|
-
chevronUp: symbol(
|
|
84
|
-
createElement('path', {
|
|
85
|
-
d: 'm3.75 9.75 4.25-4 4.25 4',
|
|
86
|
-
fill: 'none',
|
|
87
|
-
stroke: 'currentColor',
|
|
88
|
-
strokeLinecap: 'round',
|
|
89
|
-
strokeLinejoin: 'round',
|
|
90
|
-
strokeWidth: '1.5',
|
|
91
|
-
}),
|
|
92
|
-
),
|
|
93
|
-
chevronRight: symbol(
|
|
94
|
-
createElement('path', {
|
|
95
|
-
d: 'm6 4 4 4-4 4',
|
|
96
|
-
fill: 'none',
|
|
97
|
-
stroke: 'currentColor',
|
|
98
|
-
strokeLinecap: 'round',
|
|
99
|
-
strokeLinejoin: 'round',
|
|
100
|
-
strokeWidth: '1.5',
|
|
101
|
-
}),
|
|
102
|
-
),
|
|
103
|
-
close: symbol(
|
|
104
|
-
createElement('path', {
|
|
105
|
-
d: 'm4.5 4.5 7 7m0-7-7 7',
|
|
106
|
-
fill: 'none',
|
|
107
|
-
stroke: 'currentColor',
|
|
108
|
-
strokeLinecap: 'round',
|
|
109
|
-
strokeWidth: '1.5',
|
|
110
|
-
}),
|
|
111
|
-
),
|
|
112
|
-
copy: symbol(
|
|
113
|
-
createElement('rect', {
|
|
114
|
-
x: '5.25',
|
|
115
|
-
y: '3.25',
|
|
116
|
-
width: '7.5',
|
|
117
|
-
height: '7.5',
|
|
118
|
-
rx: '1.5',
|
|
119
|
-
fill: 'none',
|
|
120
|
-
stroke: 'currentColor',
|
|
121
|
-
strokeWidth: '1.5',
|
|
122
|
-
}),
|
|
123
|
-
createElement('path', {
|
|
124
|
-
d: 'M10.75 12.75h-5.5a2 2 0 0 1-2-2v-5.5',
|
|
125
|
-
fill: 'none',
|
|
126
|
-
stroke: 'currentColor',
|
|
127
|
-
strokeLinecap: 'round',
|
|
128
|
-
strokeLinejoin: 'round',
|
|
129
|
-
strokeWidth: '1.5',
|
|
130
|
-
}),
|
|
131
|
-
),
|
|
132
|
-
edit: symbol(
|
|
133
|
-
createElement('path', {
|
|
134
|
-
d: 'm10.75 3.75 1.5 1.5',
|
|
135
|
-
fill: 'none',
|
|
136
|
-
stroke: 'currentColor',
|
|
137
|
-
strokeLinecap: 'round',
|
|
138
|
-
strokeLinejoin: 'round',
|
|
139
|
-
strokeWidth: '1.5',
|
|
140
|
-
}),
|
|
141
|
-
createElement('path', {
|
|
142
|
-
d: 'm4 12 2.5-.5 5.75-5.75a1.06 1.06 0 0 0 0-1.5l-.5-.5a1.06 1.06 0 0 0-1.5 0L4.5 9.5 4 12Z',
|
|
143
|
-
fill: 'none',
|
|
144
|
-
stroke: 'currentColor',
|
|
145
|
-
strokeLinejoin: 'round',
|
|
146
|
-
strokeWidth: '1.5',
|
|
147
|
-
}),
|
|
148
|
-
),
|
|
149
|
-
expand: symbol(
|
|
150
|
-
createElement('path', {
|
|
151
|
-
d: 'M9.25 3.5h3.25v3.25',
|
|
152
|
-
fill: 'none',
|
|
153
|
-
stroke: 'currentColor',
|
|
154
|
-
strokeLinecap: 'round',
|
|
155
|
-
strokeLinejoin: 'round',
|
|
156
|
-
strokeWidth: '1.5',
|
|
157
|
-
}),
|
|
158
|
-
createElement('path', {
|
|
159
|
-
d: 'm12.5 3.5-5.5 5.5',
|
|
160
|
-
fill: 'none',
|
|
161
|
-
stroke: 'currentColor',
|
|
162
|
-
strokeLinecap: 'round',
|
|
163
|
-
strokeLinejoin: 'round',
|
|
164
|
-
strokeWidth: '1.5',
|
|
165
|
-
}),
|
|
166
|
-
createElement('path', {
|
|
167
|
-
d: 'M6.75 12.5H3.5V9.25',
|
|
168
|
-
fill: 'none',
|
|
169
|
-
stroke: 'currentColor',
|
|
170
|
-
strokeLinecap: 'round',
|
|
171
|
-
strokeLinejoin: 'round',
|
|
172
|
-
strokeWidth: '1.5',
|
|
173
|
-
}),
|
|
174
|
-
createElement('path', {
|
|
175
|
-
d: 'm3.5 12.5 5.5-5.5',
|
|
176
|
-
fill: 'none',
|
|
177
|
-
stroke: 'currentColor',
|
|
178
|
-
strokeLinecap: 'round',
|
|
179
|
-
strokeLinejoin: 'round',
|
|
180
|
-
strokeWidth: '1.5',
|
|
181
|
-
}),
|
|
182
|
-
),
|
|
183
|
-
info: symbol(
|
|
184
|
-
createElement('circle', {
|
|
185
|
-
cx: '8',
|
|
186
|
-
cy: '8',
|
|
187
|
-
fill: 'none',
|
|
188
|
-
r: '5.75',
|
|
189
|
-
stroke: 'currentColor',
|
|
190
|
-
strokeWidth: '1.5',
|
|
191
|
-
}),
|
|
192
|
-
createElement('path', {
|
|
193
|
-
d: 'M8 7.25v3',
|
|
194
|
-
fill: 'none',
|
|
195
|
-
stroke: 'currentColor',
|
|
196
|
-
strokeLinecap: 'round',
|
|
197
|
-
strokeWidth: '1.5',
|
|
198
|
-
}),
|
|
199
|
-
createElement('circle', {
|
|
200
|
-
cx: '8',
|
|
201
|
-
cy: '5',
|
|
202
|
-
fill: 'currentColor',
|
|
203
|
-
r: '0.75',
|
|
204
|
-
}),
|
|
205
|
-
),
|
|
206
|
-
menu: symbol(
|
|
207
|
-
createElement('path', {
|
|
208
|
-
d: 'M3 4.75h10M3 8h10M3 11.25h10',
|
|
209
|
-
fill: 'none',
|
|
210
|
-
stroke: 'currentColor',
|
|
211
|
-
strokeLinecap: 'round',
|
|
212
|
-
strokeWidth: '1.5',
|
|
213
|
-
}),
|
|
214
|
-
),
|
|
215
|
-
open: symbol(
|
|
216
|
-
createElement('path', {
|
|
217
|
-
d: 'M6.25 4H4.5A1.5 1.5 0 0 0 3 5.5v6A1.5 1.5 0 0 0 4.5 13h6A1.5 1.5 0 0 0 12 11.5V9.75',
|
|
218
|
-
fill: 'none',
|
|
219
|
-
stroke: 'currentColor',
|
|
220
|
-
strokeLinecap: 'round',
|
|
221
|
-
strokeLinejoin: 'round',
|
|
222
|
-
strokeWidth: '1.5',
|
|
223
|
-
}),
|
|
224
|
-
createElement('path', {
|
|
225
|
-
d: 'M8 3h5v5',
|
|
226
|
-
fill: 'none',
|
|
227
|
-
stroke: 'currentColor',
|
|
228
|
-
strokeLinecap: 'round',
|
|
229
|
-
strokeLinejoin: 'round',
|
|
230
|
-
strokeWidth: '1.5',
|
|
231
|
-
}),
|
|
232
|
-
createElement('path', {
|
|
233
|
-
d: 'm13 3-6.25 6.25',
|
|
234
|
-
fill: 'none',
|
|
235
|
-
stroke: 'currentColor',
|
|
236
|
-
strokeLinecap: 'round',
|
|
237
|
-
strokeLinejoin: 'round',
|
|
238
|
-
strokeWidth: '1.5',
|
|
239
|
-
}),
|
|
240
|
-
),
|
|
241
|
-
search: symbol(
|
|
242
|
-
createElement('circle', {
|
|
243
|
-
cx: '7',
|
|
244
|
-
cy: '7',
|
|
245
|
-
fill: 'none',
|
|
246
|
-
r: '4.25',
|
|
247
|
-
stroke: 'currentColor',
|
|
248
|
-
strokeWidth: '1.5',
|
|
249
|
-
}),
|
|
250
|
-
createElement('path', {
|
|
251
|
-
d: 'm10.25 10.25 3 3',
|
|
252
|
-
fill: 'none',
|
|
253
|
-
stroke: 'currentColor',
|
|
254
|
-
strokeLinecap: 'round',
|
|
255
|
-
strokeWidth: '1.5',
|
|
256
|
-
}),
|
|
257
|
-
),
|
|
258
|
-
spinner: symbol(
|
|
259
|
-
createElement('circle', {
|
|
260
|
-
cx: '8',
|
|
261
|
-
cy: '8',
|
|
262
|
-
fill: 'none',
|
|
263
|
-
opacity: '0.24',
|
|
264
|
-
r: '5.25',
|
|
265
|
-
stroke: 'currentColor',
|
|
266
|
-
strokeWidth: '1.5',
|
|
267
|
-
}),
|
|
268
|
-
createElement('path', {
|
|
269
|
-
d: 'M8 2.75a5.25 5.25 0 0 1 5.25 5.25',
|
|
270
|
-
fill: 'none',
|
|
271
|
-
stroke: 'currentColor',
|
|
272
|
-
strokeLinecap: 'round',
|
|
273
|
-
strokeWidth: '1.5',
|
|
274
|
-
}),
|
|
275
|
-
),
|
|
276
|
-
trash: symbol(
|
|
277
|
-
createElement('path', {
|
|
278
|
-
d: 'M3.75 4.75h8.5',
|
|
279
|
-
fill: 'none',
|
|
280
|
-
stroke: 'currentColor',
|
|
281
|
-
strokeLinecap: 'round',
|
|
282
|
-
strokeWidth: '1.5',
|
|
283
|
-
}),
|
|
284
|
-
createElement('path', {
|
|
285
|
-
d: 'M6.25 4.75V4a1 1 0 0 1 1-1h1.5a1 1 0 0 1 1 1v.75',
|
|
286
|
-
fill: 'none',
|
|
287
|
-
stroke: 'currentColor',
|
|
288
|
-
strokeLinecap: 'round',
|
|
289
|
-
strokeLinejoin: 'round',
|
|
290
|
-
strokeWidth: '1.5',
|
|
291
|
-
}),
|
|
292
|
-
createElement('path', {
|
|
293
|
-
d: 'm5 6.25.45 5.1A1.5 1.5 0 0 0 6.94 12.75h2.12a1.5 1.5 0 0 0 1.49-1.4L11 6.25',
|
|
294
|
-
fill: 'none',
|
|
295
|
-
stroke: 'currentColor',
|
|
296
|
-
strokeLinecap: 'round',
|
|
297
|
-
strokeLinejoin: 'round',
|
|
298
|
-
strokeWidth: '1.5',
|
|
299
|
-
}),
|
|
300
|
-
createElement('path', {
|
|
301
|
-
d: 'M7 7.25v3.5M9 7.25v3.5',
|
|
302
|
-
fill: 'none',
|
|
303
|
-
stroke: 'currentColor',
|
|
304
|
-
strokeLinecap: 'round',
|
|
305
|
-
strokeWidth: '1.5',
|
|
306
|
-
}),
|
|
307
|
-
),
|
|
308
|
-
}
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
import { createGlyphSheet } from '../../../components/glyph/glyph.tsx'
|
|
2
|
-
import { createTheme } from '../../runtime.ts'
|
|
3
|
-
import type { GlyphSheetComponent } from '../../../components/glyph/glyph.tsx'
|
|
4
|
-
import type { ThemeComponent } from '../../contract.ts'
|
|
5
|
-
|
|
6
|
-
import { glyphValues } from './glyphs.tsx'
|
|
7
|
-
|
|
8
|
-
export const RMX_01: ThemeComponent = createTheme({
|
|
9
|
-
space: {
|
|
10
|
-
none: '0px',
|
|
11
|
-
px: '1px',
|
|
12
|
-
xs: '4px',
|
|
13
|
-
sm: '8px',
|
|
14
|
-
md: '12px',
|
|
15
|
-
lg: '16px',
|
|
16
|
-
xl: '24px',
|
|
17
|
-
xxl: '32px',
|
|
18
|
-
},
|
|
19
|
-
radius: {
|
|
20
|
-
none: '0px',
|
|
21
|
-
sm: '4px',
|
|
22
|
-
md: '8px',
|
|
23
|
-
lg: '12px',
|
|
24
|
-
xl: '16px',
|
|
25
|
-
full: '9999px',
|
|
26
|
-
},
|
|
27
|
-
fontSize: {
|
|
28
|
-
xxxs: '10px',
|
|
29
|
-
xxs: '11px',
|
|
30
|
-
xs: '12px',
|
|
31
|
-
sm: '13px',
|
|
32
|
-
md: '14px',
|
|
33
|
-
lg: '16px',
|
|
34
|
-
xl: '20px',
|
|
35
|
-
xxl: '28px',
|
|
36
|
-
},
|
|
37
|
-
fontFamily: {
|
|
38
|
-
sans: '"Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',
|
|
39
|
-
mono: 'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',
|
|
40
|
-
},
|
|
41
|
-
lineHeight: {
|
|
42
|
-
tight: '1.25',
|
|
43
|
-
normal: '1.45',
|
|
44
|
-
relaxed: '1.65',
|
|
45
|
-
},
|
|
46
|
-
letterSpacing: {
|
|
47
|
-
tight: '-0.03em',
|
|
48
|
-
normal: '0',
|
|
49
|
-
meta: '0.06em',
|
|
50
|
-
wide: '0.08em',
|
|
51
|
-
},
|
|
52
|
-
fontWeight: {
|
|
53
|
-
normal: '400',
|
|
54
|
-
medium: '500',
|
|
55
|
-
semibold: '600',
|
|
56
|
-
bold: '700',
|
|
57
|
-
},
|
|
58
|
-
control: {
|
|
59
|
-
height: {
|
|
60
|
-
sm: '28px',
|
|
61
|
-
md: '32px',
|
|
62
|
-
lg: '36px',
|
|
63
|
-
},
|
|
64
|
-
},
|
|
65
|
-
surface: {
|
|
66
|
-
lvl0: '#ffffff',
|
|
67
|
-
lvl1: '#f8f8f8',
|
|
68
|
-
lvl2: '#f5f5f5',
|
|
69
|
-
lvl3: '#f3f3f3',
|
|
70
|
-
lvl4: '#efefef',
|
|
71
|
-
},
|
|
72
|
-
shadow: {
|
|
73
|
-
xs: '0 1px 1px rgb(0 0 0 / 0.05)',
|
|
74
|
-
sm: '0 1px 2px rgb(0 0 0 / 0.07)',
|
|
75
|
-
md: '0 6px 18px rgb(0 0 0 / 0.08)',
|
|
76
|
-
lg: '0 16px 34px rgb(0 0 0 / 0.10)',
|
|
77
|
-
xl: '0 24px 52px rgb(0 0 0 / 0.14)',
|
|
78
|
-
},
|
|
79
|
-
colors: {
|
|
80
|
-
text: {
|
|
81
|
-
primary: '#151515',
|
|
82
|
-
secondary: '#4f4f4f',
|
|
83
|
-
muted: '#6d6d6d',
|
|
84
|
-
link: '#1A72FF',
|
|
85
|
-
},
|
|
86
|
-
border: {
|
|
87
|
-
subtle: '#e7e7e7',
|
|
88
|
-
default: '#d1d1d1',
|
|
89
|
-
strong: '#b0b0b0',
|
|
90
|
-
},
|
|
91
|
-
focus: {
|
|
92
|
-
ring: '#1A72FF',
|
|
93
|
-
},
|
|
94
|
-
overlay: {
|
|
95
|
-
scrim: 'rgb(0 0 0 / 0.28)',
|
|
96
|
-
},
|
|
97
|
-
action: {
|
|
98
|
-
primary: {
|
|
99
|
-
background: '#1A72FF',
|
|
100
|
-
backgroundHover: '#1463e0',
|
|
101
|
-
backgroundActive: '#0f55c9',
|
|
102
|
-
foreground: 'rgb(255 255 255 / 0.92)',
|
|
103
|
-
border: '#1A72FF',
|
|
104
|
-
},
|
|
105
|
-
secondary: {
|
|
106
|
-
background: '#ffffff',
|
|
107
|
-
backgroundHover: '#fbfbfb',
|
|
108
|
-
backgroundActive: '#f3f3f3',
|
|
109
|
-
foreground: '#202020',
|
|
110
|
-
border: '#d1d1d1',
|
|
111
|
-
},
|
|
112
|
-
danger: {
|
|
113
|
-
background: '#FF3000',
|
|
114
|
-
backgroundHover: '#e12b00',
|
|
115
|
-
backgroundActive: '#c52600',
|
|
116
|
-
foreground: 'rgb(255 255 255 / 0.92)',
|
|
117
|
-
border: '#FF3000',
|
|
118
|
-
},
|
|
119
|
-
},
|
|
120
|
-
},
|
|
121
|
-
})
|
|
122
|
-
|
|
123
|
-
export const RMX_01_GLYPHS: GlyphSheetComponent = createGlyphSheet(glyphValues)
|