@kanzo-tech/ui 0.0.1-alpha
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 +60 -0
- package/dist/analytics.d.ts +36 -0
- package/dist/analytics.d.ts.map +1 -0
- package/dist/analytics.js +155 -0
- package/dist/analytics.js.map +1 -0
- package/dist/charts/arrow.d.ts +37 -0
- package/dist/charts/arrow.d.ts.map +1 -0
- package/dist/charts/arrow.js +29 -0
- package/dist/charts/arrow.js.map +1 -0
- package/dist/charts/chart-axes.d.ts +59 -0
- package/dist/charts/chart-axes.d.ts.map +1 -0
- package/dist/charts/chart-axes.js +39 -0
- package/dist/charts/chart-axes.js.map +1 -0
- package/dist/charts/chart-config.d.ts +52 -0
- package/dist/charts/chart-config.d.ts.map +1 -0
- package/dist/charts/chart-config.js +43 -0
- package/dist/charts/chart-config.js.map +1 -0
- package/dist/charts/chart-inputs.d.ts +174 -0
- package/dist/charts/chart-inputs.d.ts.map +1 -0
- package/dist/charts/chart-inputs.js +382 -0
- package/dist/charts/chart-inputs.js.map +1 -0
- package/dist/charts/chart-interactors.d.ts +75 -0
- package/dist/charts/chart-interactors.d.ts.map +1 -0
- package/dist/charts/chart-interactors.js +35 -0
- package/dist/charts/chart-interactors.js.map +1 -0
- package/dist/charts/chart-legend.d.ts +38 -0
- package/dist/charts/chart-legend.d.ts.map +1 -0
- package/dist/charts/chart-legend.js +49 -0
- package/dist/charts/chart-legend.js.map +1 -0
- package/dist/charts/chart-marks.d.ts +124 -0
- package/dist/charts/chart-marks.d.ts.map +1 -0
- package/dist/charts/chart-marks.js +109 -0
- package/dist/charts/chart-marks.js.map +1 -0
- package/dist/charts/chart-root.d.ts +90 -0
- package/dist/charts/chart-root.d.ts.map +1 -0
- package/dist/charts/chart-root.js +162 -0
- package/dist/charts/chart-root.js.map +1 -0
- package/dist/charts/chart-spec.d.ts +126 -0
- package/dist/charts/chart-spec.d.ts.map +1 -0
- package/dist/charts/chart-spec.js +133 -0
- package/dist/charts/chart-spec.js.map +1 -0
- package/dist/charts/chart-stat.d.ts +23 -0
- package/dist/charts/chart-stat.d.ts.map +1 -0
- package/dist/charts/chart-stat.js +24 -0
- package/dist/charts/chart-stat.js.map +1 -0
- package/dist/charts/id-set-client.d.ts +42 -0
- package/dist/charts/id-set-client.d.ts.map +1 -0
- package/dist/charts/id-set-client.js +43 -0
- package/dist/charts/id-set-client.js.map +1 -0
- package/dist/charts/mosaic-provider.d.ts +70 -0
- package/dist/charts/mosaic-provider.d.ts.map +1 -0
- package/dist/charts/mosaic-provider.js +53 -0
- package/dist/charts/mosaic-provider.js.map +1 -0
- package/dist/charts/query-client.d.ts +22 -0
- package/dist/charts/query-client.d.ts.map +1 -0
- package/dist/charts/query-client.js +26 -0
- package/dist/charts/query-client.js.map +1 -0
- package/dist/charts/tokenized-plot.d.ts +26 -0
- package/dist/charts/tokenized-plot.d.ts.map +1 -0
- package/dist/charts/tokenized-plot.js +41 -0
- package/dist/charts/tokenized-plot.js.map +1 -0
- package/dist/charts/use-chart-query.d.ts +30 -0
- package/dist/charts/use-chart-query.d.ts.map +1 -0
- package/dist/charts/use-chart-query.js +19 -0
- package/dist/charts/use-chart-query.js.map +1 -0
- package/dist/composites/CodeEditor.d.ts +64 -0
- package/dist/composites/CodeEditor.d.ts.map +1 -0
- package/dist/composites/CodeEditor.js +521 -0
- package/dist/composites/CodeEditor.js.map +1 -0
- package/dist/composites/MadeWith.d.ts +39 -0
- package/dist/composites/MadeWith.d.ts.map +1 -0
- package/dist/composites/MadeWith.js +30 -0
- package/dist/composites/MadeWith.js.map +1 -0
- package/dist/composites/Preferences.d.ts +155 -0
- package/dist/composites/Preferences.d.ts.map +1 -0
- package/dist/composites/Preferences.js +501 -0
- package/dist/composites/Preferences.js.map +1 -0
- package/dist/composites/Questionnaire.d.ts +215 -0
- package/dist/composites/Questionnaire.d.ts.map +1 -0
- package/dist/composites/Questionnaire.js +422 -0
- package/dist/composites/Questionnaire.js.map +1 -0
- package/dist/composites/SidebarIdentity.d.ts +63 -0
- package/dist/composites/SidebarIdentity.d.ts.map +1 -0
- package/dist/composites/SidebarIdentity.js +103 -0
- package/dist/composites/SidebarIdentity.js.map +1 -0
- package/dist/composites/code-editor-search.d.ts +40 -0
- package/dist/composites/code-editor-search.d.ts.map +1 -0
- package/dist/composites/code-editor-search.js +212 -0
- package/dist/composites/code-editor-search.js.map +1 -0
- package/dist/composites/sidebar.d.ts +129 -0
- package/dist/composites/sidebar.d.ts.map +1 -0
- package/dist/composites/sidebar.js +671 -0
- package/dist/composites/sidebar.js.map +1 -0
- package/dist/composites/theme-notice.d.ts +54 -0
- package/dist/composites/theme-notice.d.ts.map +1 -0
- package/dist/composites/theme-notice.js +19 -0
- package/dist/composites/theme-notice.js.map +1 -0
- package/dist/editor.d.ts +3 -0
- package/dist/editor.d.ts.map +1 -0
- package/dist/editor.js +6 -0
- package/dist/editor.js.map +1 -0
- package/dist/guard-corpus.d.ts +63 -0
- package/dist/guard-corpus.d.ts.map +1 -0
- package/dist/index.d.ts +112 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +696 -0
- package/dist/index.js.map +1 -0
- package/dist/layouts/section.d.ts +166 -0
- package/dist/layouts/section.d.ts.map +1 -0
- package/dist/layouts/section.js +153 -0
- package/dist/layouts/section.js.map +1 -0
- package/dist/layouts/shell.d.ts +128 -0
- package/dist/layouts/shell.d.ts.map +1 -0
- package/dist/layouts/shell.js +107 -0
- package/dist/layouts/shell.js.map +1 -0
- package/dist/lib/cn.d.ts +4 -0
- package/dist/lib/cn.d.ts.map +1 -0
- package/dist/lib/cn.js +9 -0
- package/dist/lib/cn.js.map +1 -0
- package/dist/lib/is-active-path.d.ts +13 -0
- package/dist/lib/is-active-path.d.ts.map +1 -0
- package/dist/lib/is-active-path.js +7 -0
- package/dist/lib/is-active-path.js.map +1 -0
- package/dist/lib/theme-tick.d.ts +37 -0
- package/dist/lib/theme-tick.d.ts.map +1 -0
- package/dist/lib/theme-tick.js +30 -0
- package/dist/lib/theme-tick.js.map +1 -0
- package/dist/lib/token-color.d.ts +74 -0
- package/dist/lib/token-color.d.ts.map +1 -0
- package/dist/lib/token-color.js +35 -0
- package/dist/lib/token-color.js.map +1 -0
- package/dist/lib/use-is-mobile.d.ts +2 -0
- package/dist/lib/use-is-mobile.d.ts.map +1 -0
- package/dist/lib/use-is-mobile.js +17 -0
- package/dist/lib/use-is-mobile.js.map +1 -0
- package/dist/shark-parity.divergences.d.ts +104 -0
- package/dist/shark-parity.divergences.d.ts.map +1 -0
- package/dist/simples/FacetFilter.d.ts +57 -0
- package/dist/simples/FacetFilter.d.ts.map +1 -0
- package/dist/simples/FacetFilter.js +167 -0
- package/dist/simples/FacetFilter.js.map +1 -0
- package/dist/simples/FieldArray.d.ts +42 -0
- package/dist/simples/FieldArray.d.ts.map +1 -0
- package/dist/simples/FieldArray.js +76 -0
- package/dist/simples/FieldArray.js.map +1 -0
- package/dist/simples/Link.d.ts +38 -0
- package/dist/simples/Link.d.ts.map +1 -0
- package/dist/simples/Link.js +24 -0
- package/dist/simples/Link.js.map +1 -0
- package/dist/simples/accordion.d.ts +8 -0
- package/dist/simples/accordion.d.ts.map +1 -0
- package/dist/simples/accordion.js +78 -0
- package/dist/simples/accordion.js.map +1 -0
- package/dist/simples/action-bar.d.ts +101 -0
- package/dist/simples/action-bar.d.ts.map +1 -0
- package/dist/simples/action-bar.js +195 -0
- package/dist/simples/action-bar.js.map +1 -0
- package/dist/simples/alert-dialog.d.ts +24 -0
- package/dist/simples/alert-dialog.d.ts.map +1 -0
- package/dist/simples/alert-dialog.js +43 -0
- package/dist/simples/alert-dialog.js.map +1 -0
- package/dist/simples/alert.d.ts +36 -0
- package/dist/simples/alert.d.ts.map +1 -0
- package/dist/simples/alert.js +123 -0
- package/dist/simples/alert.js.map +1 -0
- package/dist/simples/avatar.d.ts +37 -0
- package/dist/simples/avatar.d.ts.map +1 -0
- package/dist/simples/avatar.js +133 -0
- package/dist/simples/avatar.js.map +1 -0
- package/dist/simples/badge.d.ts +66 -0
- package/dist/simples/badge.d.ts.map +1 -0
- package/dist/simples/badge.js +138 -0
- package/dist/simples/badge.js.map +1 -0
- package/dist/simples/breadcrumb.d.ts +19 -0
- package/dist/simples/breadcrumb.d.ts.map +1 -0
- package/dist/simples/breadcrumb.js +107 -0
- package/dist/simples/breadcrumb.js.map +1 -0
- package/dist/simples/button-group.d.ts +19 -0
- package/dist/simples/button-group.d.ts.map +1 -0
- package/dist/simples/button-group.js +69 -0
- package/dist/simples/button-group.js.map +1 -0
- package/dist/simples/button.d.ts +148 -0
- package/dist/simples/button.d.ts.map +1 -0
- package/dist/simples/button.js +157 -0
- package/dist/simples/button.js.map +1 -0
- package/dist/simples/calendar.d.ts +45 -0
- package/dist/simples/calendar.d.ts.map +1 -0
- package/dist/simples/calendar.js +342 -0
- package/dist/simples/calendar.js.map +1 -0
- package/dist/simples/card.d.ts +43 -0
- package/dist/simples/card.d.ts.map +1 -0
- package/dist/simples/card.js +151 -0
- package/dist/simples/card.js.map +1 -0
- package/dist/simples/checkbox.d.ts +25 -0
- package/dist/simples/checkbox.d.ts.map +1 -0
- package/dist/simples/checkbox.js +103 -0
- package/dist/simples/checkbox.js.map +1 -0
- package/dist/simples/client-only.d.ts +3 -0
- package/dist/simples/client-only.d.ts.map +1 -0
- package/dist/simples/client-only.js +7 -0
- package/dist/simples/client-only.js.map +1 -0
- package/dist/simples/clipboard.d.ts +11 -0
- package/dist/simples/clipboard.d.ts.map +1 -0
- package/dist/simples/clipboard.js +99 -0
- package/dist/simples/clipboard.js.map +1 -0
- package/dist/simples/collapsible.d.ts +8 -0
- package/dist/simples/collapsible.d.ts.map +1 -0
- package/dist/simples/collapsible.js +79 -0
- package/dist/simples/collapsible.js.map +1 -0
- package/dist/simples/color-picker.d.ts +62 -0
- package/dist/simples/color-picker.d.ts.map +1 -0
- package/dist/simples/color-picker.js +391 -0
- package/dist/simples/color-picker.js.map +1 -0
- package/dist/simples/combobox.d.ts +66 -0
- package/dist/simples/combobox.d.ts.map +1 -0
- package/dist/simples/combobox.js +230 -0
- package/dist/simples/combobox.js.map +1 -0
- package/dist/simples/command.d.ts +45 -0
- package/dist/simples/command.d.ts.map +1 -0
- package/dist/simples/command.js +180 -0
- package/dist/simples/command.js.map +1 -0
- package/dist/simples/data-list.d.ts +25 -0
- package/dist/simples/data-list.d.ts.map +1 -0
- package/dist/simples/data-list.js +62 -0
- package/dist/simples/data-list.js.map +1 -0
- package/dist/simples/date-picker.d.ts +16 -0
- package/dist/simples/date-picker.d.ts.map +1 -0
- package/dist/simples/date-picker.js +117 -0
- package/dist/simples/date-picker.js.map +1 -0
- package/dist/simples/diagnostic.d.ts +138 -0
- package/dist/simples/diagnostic.d.ts.map +1 -0
- package/dist/simples/diagnostic.js +288 -0
- package/dist/simples/diagnostic.js.map +1 -0
- package/dist/simples/dialog.d.ts +100 -0
- package/dist/simples/dialog.d.ts.map +1 -0
- package/dist/simples/dialog.js +267 -0
- package/dist/simples/dialog.js.map +1 -0
- package/dist/simples/download-trigger.d.ts +3 -0
- package/dist/simples/download-trigger.d.ts.map +1 -0
- package/dist/simples/download-trigger.js +7 -0
- package/dist/simples/download-trigger.js.map +1 -0
- package/dist/simples/editable.d.ts +23 -0
- package/dist/simples/editable.d.ts.map +1 -0
- package/dist/simples/editable.js +70 -0
- package/dist/simples/editable.js.map +1 -0
- package/dist/simples/field.d.ts +58 -0
- package/dist/simples/field.d.ts.map +1 -0
- package/dist/simples/field.js +285 -0
- package/dist/simples/field.js.map +1 -0
- package/dist/simples/file-upload.d.ts +19 -0
- package/dist/simples/file-upload.d.ts.map +1 -0
- package/dist/simples/file-upload.js +192 -0
- package/dist/simples/file-upload.js.map +1 -0
- package/dist/simples/float.d.ts +45 -0
- package/dist/simples/float.d.ts.map +1 -0
- package/dist/simples/float.js +40 -0
- package/dist/simples/float.js.map +1 -0
- package/dist/simples/floating-panel.d.ts +25 -0
- package/dist/simples/floating-panel.d.ts.map +1 -0
- package/dist/simples/floating-panel.js +95 -0
- package/dist/simples/floating-panel.js.map +1 -0
- package/dist/simples/highlight.d.ts +6 -0
- package/dist/simples/highlight.d.ts.map +1 -0
- package/dist/simples/highlight.js +24 -0
- package/dist/simples/highlight.js.map +1 -0
- package/dist/simples/hover-card.d.ts +11 -0
- package/dist/simples/hover-card.d.ts.map +1 -0
- package/dist/simples/hover-card.js +83 -0
- package/dist/simples/hover-card.js.map +1 -0
- package/dist/simples/image-cropper.d.ts +17 -0
- package/dist/simples/image-cropper.d.ts.map +1 -0
- package/dist/simples/image-cropper.js +139 -0
- package/dist/simples/image-cropper.js.map +1 -0
- package/dist/simples/input-group.d.ts +116 -0
- package/dist/simples/input-group.d.ts.map +1 -0
- package/dist/simples/input-group.js +245 -0
- package/dist/simples/input-group.js.map +1 -0
- package/dist/simples/input.d.ts +26 -0
- package/dist/simples/input.d.ts.map +1 -0
- package/dist/simples/input.js +60 -0
- package/dist/simples/input.js.map +1 -0
- package/dist/simples/item.d.ts +72 -0
- package/dist/simples/item.d.ts.map +1 -0
- package/dist/simples/item.js +180 -0
- package/dist/simples/item.js.map +1 -0
- package/dist/simples/json-tree-view.d.ts +7 -0
- package/dist/simples/json-tree-view.d.ts.map +1 -0
- package/dist/simples/json-tree-view.js +71 -0
- package/dist/simples/json-tree-view.js.map +1 -0
- package/dist/simples/kbd.d.ts +25 -0
- package/dist/simples/kbd.d.ts.map +1 -0
- package/dist/simples/kbd.js +50 -0
- package/dist/simples/kbd.js.map +1 -0
- package/dist/simples/listbox.d.ts +46 -0
- package/dist/simples/listbox.d.ts.map +1 -0
- package/dist/simples/listbox.js +218 -0
- package/dist/simples/listbox.js.map +1 -0
- package/dist/simples/menu.d.ts +60 -0
- package/dist/simples/menu.d.ts.map +1 -0
- package/dist/simples/menu.js +294 -0
- package/dist/simples/menu.js.map +1 -0
- package/dist/simples/native-select.d.ts +36 -0
- package/dist/simples/native-select.d.ts.map +1 -0
- package/dist/simples/native-select.js +77 -0
- package/dist/simples/native-select.js.map +1 -0
- package/dist/simples/number-input.d.ts +35 -0
- package/dist/simples/number-input.d.ts.map +1 -0
- package/dist/simples/number-input.js +142 -0
- package/dist/simples/number-input.js.map +1 -0
- package/dist/simples/pagination.d.ts +11 -0
- package/dist/simples/pagination.d.ts.map +1 -0
- package/dist/simples/pagination.js +78 -0
- package/dist/simples/pagination.js.map +1 -0
- package/dist/simples/password-input.d.ts +23 -0
- package/dist/simples/password-input.d.ts.map +1 -0
- package/dist/simples/password-input.js +90 -0
- package/dist/simples/password-input.js.map +1 -0
- package/dist/simples/pin-input.d.ts +30 -0
- package/dist/simples/pin-input.d.ts.map +1 -0
- package/dist/simples/pin-input.js +71 -0
- package/dist/simples/pin-input.js.map +1 -0
- package/dist/simples/popover.d.ts +42 -0
- package/dist/simples/popover.d.ts.map +1 -0
- package/dist/simples/popover.js +188 -0
- package/dist/simples/popover.js.map +1 -0
- package/dist/simples/progress.d.ts +23 -0
- package/dist/simples/progress.d.ts.map +1 -0
- package/dist/simples/progress.js +82 -0
- package/dist/simples/progress.js.map +1 -0
- package/dist/simples/prose.d.ts +17 -0
- package/dist/simples/prose.d.ts.map +1 -0
- package/dist/simples/prose.js +18 -0
- package/dist/simples/prose.js.map +1 -0
- package/dist/simples/radio-group.d.ts +23 -0
- package/dist/simples/radio-group.d.ts.map +1 -0
- package/dist/simples/radio-group.js +149 -0
- package/dist/simples/radio-group.js.map +1 -0
- package/dist/simples/rating.d.ts +10 -0
- package/dist/simples/rating.d.ts.map +1 -0
- package/dist/simples/rating.js +81 -0
- package/dist/simples/rating.js.map +1 -0
- package/dist/simples/resizable.d.ts +16 -0
- package/dist/simples/resizable.d.ts.map +1 -0
- package/dist/simples/resizable.js +57 -0
- package/dist/simples/resizable.js.map +1 -0
- package/dist/simples/scroll-area.d.ts +23 -0
- package/dist/simples/scroll-area.d.ts.map +1 -0
- package/dist/simples/scroll-area.js +88 -0
- package/dist/simples/scroll-area.js.map +1 -0
- package/dist/simples/segment-group.d.ts +27 -0
- package/dist/simples/segment-group.d.ts.map +1 -0
- package/dist/simples/segment-group.js +129 -0
- package/dist/simples/segment-group.js.map +1 -0
- package/dist/simples/select.d.ts +34 -0
- package/dist/simples/select.d.ts.map +1 -0
- package/dist/simples/select.js +258 -0
- package/dist/simples/select.js.map +1 -0
- package/dist/simples/separator.d.ts +12 -0
- package/dist/simples/separator.d.ts.map +1 -0
- package/dist/simples/separator.js +27 -0
- package/dist/simples/separator.js.map +1 -0
- package/dist/simples/sheet.d.ts +94 -0
- package/dist/simples/sheet.d.ts.map +1 -0
- package/dist/simples/sheet.js +172 -0
- package/dist/simples/sheet.js.map +1 -0
- package/dist/simples/show.d.ts +10 -0
- package/dist/simples/show.d.ts.map +1 -0
- package/dist/simples/show.js +9 -0
- package/dist/simples/show.js.map +1 -0
- package/dist/simples/skeleton.d.ts +3 -0
- package/dist/simples/skeleton.d.ts.map +1 -0
- package/dist/simples/skeleton.js +23 -0
- package/dist/simples/skeleton.js.map +1 -0
- package/dist/simples/skip-nav.d.ts +54 -0
- package/dist/simples/skip-nav.d.ts.map +1 -0
- package/dist/simples/skip-nav.js +42 -0
- package/dist/simples/skip-nav.js.map +1 -0
- package/dist/simples/slider.d.ts +29 -0
- package/dist/simples/slider.d.ts.map +1 -0
- package/dist/simples/slider.js +189 -0
- package/dist/simples/slider.js.map +1 -0
- package/dist/simples/spinner.d.ts +2 -0
- package/dist/simples/spinner.d.ts.map +1 -0
- package/dist/simples/spinner.js +20 -0
- package/dist/simples/spinner.js.map +1 -0
- package/dist/simples/stat-tile.d.ts +31 -0
- package/dist/simples/stat-tile.d.ts.map +1 -0
- package/dist/simples/stat-tile.js +64 -0
- package/dist/simples/stat-tile.js.map +1 -0
- package/dist/simples/status.d.ts +48 -0
- package/dist/simples/status.d.ts.map +1 -0
- package/dist/simples/status.js +57 -0
- package/dist/simples/status.js.map +1 -0
- package/dist/simples/steps.d.ts +20 -0
- package/dist/simples/steps.d.ts.map +1 -0
- package/dist/simples/steps.js +171 -0
- package/dist/simples/steps.js.map +1 -0
- package/dist/simples/suggestions.d.ts +43 -0
- package/dist/simples/suggestions.d.ts.map +1 -0
- package/dist/simples/suggestions.js +38 -0
- package/dist/simples/suggestions.js.map +1 -0
- package/dist/simples/swatch.d.ts +73 -0
- package/dist/simples/swatch.d.ts.map +1 -0
- package/dist/simples/swatch.js +35 -0
- package/dist/simples/swatch.js.map +1 -0
- package/dist/simples/switch.d.ts +5 -0
- package/dist/simples/switch.d.ts.map +1 -0
- package/dist/simples/switch.js +71 -0
- package/dist/simples/switch.js.map +1 -0
- package/dist/simples/table.d.ts +55 -0
- package/dist/simples/table.d.ts.map +1 -0
- package/dist/simples/table.js +166 -0
- package/dist/simples/table.js.map +1 -0
- package/dist/simples/tabs.d.ts +55 -0
- package/dist/simples/tabs.d.ts.map +1 -0
- package/dist/simples/tabs.js +133 -0
- package/dist/simples/tabs.js.map +1 -0
- package/dist/simples/tags-input.d.ts +64 -0
- package/dist/simples/tags-input.d.ts.map +1 -0
- package/dist/simples/tags-input.js +228 -0
- package/dist/simples/tags-input.js.map +1 -0
- package/dist/simples/textarea.d.ts +6 -0
- package/dist/simples/textarea.d.ts.map +1 -0
- package/dist/simples/textarea.js +34 -0
- package/dist/simples/textarea.js.map +1 -0
- package/dist/simples/toast.d.ts +20 -0
- package/dist/simples/toast.d.ts.map +1 -0
- package/dist/simples/toast.js +127 -0
- package/dist/simples/toast.js.map +1 -0
- package/dist/simples/toggle-group.d.ts +20 -0
- package/dist/simples/toggle-group.d.ts.map +1 -0
- package/dist/simples/toggle-group.js +82 -0
- package/dist/simples/toggle-group.js.map +1 -0
- package/dist/simples/toggle.d.ts +35 -0
- package/dist/simples/toggle.d.ts.map +1 -0
- package/dist/simples/toggle.js +57 -0
- package/dist/simples/toggle.js.map +1 -0
- package/dist/simples/tooltip.d.ts +8 -0
- package/dist/simples/tooltip.d.ts.map +1 -0
- package/dist/simples/tooltip.js +80 -0
- package/dist/simples/tooltip.js.map +1 -0
- package/dist/simples/tour.d.ts +81 -0
- package/dist/simples/tour.d.ts.map +1 -0
- package/dist/simples/tour.js +253 -0
- package/dist/simples/tour.js.map +1 -0
- package/dist/simples/tree-view.d.ts +64 -0
- package/dist/simples/tree-view.d.ts.map +1 -0
- package/dist/simples/tree-view.js +300 -0
- package/dist/simples/tree-view.js.map +1 -0
- package/dist/styles.css +2 -0
- package/dist/table/data-table-content.d.ts +18 -0
- package/dist/table/data-table-content.d.ts.map +1 -0
- package/dist/table/data-table-content.js +53 -0
- package/dist/table/data-table-content.js.map +1 -0
- package/dist/table/data-table-pagination.d.ts +8 -0
- package/dist/table/data-table-pagination.d.ts.map +1 -0
- package/dist/table/data-table-pagination.js +65 -0
- package/dist/table/data-table-pagination.js.map +1 -0
- package/dist/table/data-table-root.d.ts +10 -0
- package/dist/table/data-table-root.d.ts.map +1 -0
- package/dist/table/data-table-root.js +21 -0
- package/dist/table/data-table-root.js.map +1 -0
- package/dist/table/data-table-toolbar.d.ts +44 -0
- package/dist/table/data-table-toolbar.d.ts.map +1 -0
- package/dist/table/data-table-toolbar.js +87 -0
- package/dist/table/data-table-toolbar.js.map +1 -0
- package/dist/table/select-column.d.ts +16 -0
- package/dist/table/select-column.d.ts.map +1 -0
- package/dist/table/select-column.js +39 -0
- package/dist/table/select-column.js.map +1 -0
- package/dist/table/sortableHeader.d.ts +25 -0
- package/dist/table/sortableHeader.d.ts.map +1 -0
- package/dist/table/sortableHeader.js +43 -0
- package/dist/table/sortableHeader.js.map +1 -0
- package/dist/table/use-data-table.d.ts +40 -0
- package/dist/table/use-data-table.d.ts.map +1 -0
- package/dist/table/use-data-table.js +65 -0
- package/dist/table/use-data-table.js.map +1 -0
- package/dist/table.d.ts +15 -0
- package/dist/table.d.ts.map +1 -0
- package/dist/table.js +22 -0
- package/dist/table.js.map +1 -0
- package/dist/theme/KanzoTheme.d.ts +74 -0
- package/dist/theme/KanzoTheme.d.ts.map +1 -0
- package/dist/theme/KanzoTheme.js +61 -0
- package/dist/theme/KanzoTheme.js.map +1 -0
- package/dist/theme/KanzoThemeProvider.d.ts +144 -0
- package/dist/theme/KanzoThemeProvider.d.ts.map +1 -0
- package/dist/theme/KanzoThemeProvider.js +271 -0
- package/dist/theme/KanzoThemeProvider.js.map +1 -0
- package/dist/theme/theme-context.d.ts +146 -0
- package/dist/theme/theme-context.d.ts.map +1 -0
- package/dist/theme/theme-context.js +18 -0
- package/dist/theme/theme-context.js.map +1 -0
- package/dist/theme/theme-script.d.ts +17 -0
- package/dist/theme/theme-script.d.ts.map +1 -0
- package/dist/theme/theme-script.js +16 -0
- package/dist/theme/theme-script.js.map +1 -0
- package/package.json +201 -0
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as u, jsx as a } from "react/jsx-runtime";
|
|
3
|
+
import { useFieldContext as j } from "@ark-ui/react/field";
|
|
4
|
+
import { useSliderContext as C, Slider as r } from "@ark-ui/react/slider";
|
|
5
|
+
import M from "react";
|
|
6
|
+
import { cn as e } from "../lib/cn.js";
|
|
7
|
+
import { FieldLabel as v } from "./field.js";
|
|
8
|
+
const $ = C, D = (l) => {
|
|
9
|
+
const {
|
|
10
|
+
value: i,
|
|
11
|
+
defaultValue: n,
|
|
12
|
+
min: d = 0,
|
|
13
|
+
max: s = 100,
|
|
14
|
+
markerInterval: m = 1,
|
|
15
|
+
showMarkers: f = !1,
|
|
16
|
+
markerLabels: c = [],
|
|
17
|
+
disabled: b,
|
|
18
|
+
invalid: h,
|
|
19
|
+
readOnly: p,
|
|
20
|
+
tabIndex: x,
|
|
21
|
+
className: y,
|
|
22
|
+
children: w,
|
|
23
|
+
slot: k,
|
|
24
|
+
...N
|
|
25
|
+
} = l, t = j(), S = b ?? (t == null ? void 0 : t.disabled), g = h ?? (t == null ? void 0 : t.invalid), A = p ?? (t == null ? void 0 : t.readOnly), _ = M.useMemo(() => Array.isArray(i) ? i : Array.isArray(n) ? n : [d, s], [i, n, d, s]);
|
|
26
|
+
return /* @__PURE__ */ u(
|
|
27
|
+
r.Root,
|
|
28
|
+
{
|
|
29
|
+
className: e(
|
|
30
|
+
"flex flex-col gap-3",
|
|
31
|
+
"data-[orientation=horizontal]:w-full",
|
|
32
|
+
"data-[orientation=vertical]:h-full",
|
|
33
|
+
y
|
|
34
|
+
),
|
|
35
|
+
defaultValue: n,
|
|
36
|
+
disabled: S,
|
|
37
|
+
invalid: g,
|
|
38
|
+
max: s,
|
|
39
|
+
min: d,
|
|
40
|
+
readOnly: A,
|
|
41
|
+
value: i,
|
|
42
|
+
...N,
|
|
43
|
+
"data-slot": k ?? "slider",
|
|
44
|
+
children: [
|
|
45
|
+
w,
|
|
46
|
+
/* @__PURE__ */ u(
|
|
47
|
+
r.Control,
|
|
48
|
+
{
|
|
49
|
+
className: e(
|
|
50
|
+
"relative",
|
|
51
|
+
"w-full",
|
|
52
|
+
"flex items-center",
|
|
53
|
+
"touch-none select-none",
|
|
54
|
+
"data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-40 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col",
|
|
55
|
+
"data-disabled:pointer-events-none data-disabled:opacity-64"
|
|
56
|
+
),
|
|
57
|
+
"data-slot": "slider-control",
|
|
58
|
+
children: [
|
|
59
|
+
/* @__PURE__ */ a(
|
|
60
|
+
r.Track,
|
|
61
|
+
{
|
|
62
|
+
className: e(
|
|
63
|
+
"grow",
|
|
64
|
+
// The unfilled track is a LEVEL on a backdrop the slider does not own, not a
|
|
65
|
+
// control fill: `--field` recedes to the page in dark, and a track that is the page
|
|
66
|
+
// is a track nobody can see. a4 measures ΔE 5.11 light / 7.73 dark from every surface
|
|
67
|
+
// the theme publishes, against `--field`'s 2.40 / 0.00-on-the-page.
|
|
68
|
+
"bg-foreground/14",
|
|
69
|
+
"rounded-full",
|
|
70
|
+
"select-none overflow-hidden",
|
|
71
|
+
"data-[orientation=horizontal]:h-2 data-[orientation=horizontal]:w-full",
|
|
72
|
+
"data-[orientation=vertical]:h-full data-[orientation=vertical]:w-2",
|
|
73
|
+
"data-invalid:bg-destructive/7"
|
|
74
|
+
),
|
|
75
|
+
"data-slot": "slider-track",
|
|
76
|
+
children: /* @__PURE__ */ a(
|
|
77
|
+
r.Range,
|
|
78
|
+
{
|
|
79
|
+
className: e(
|
|
80
|
+
"absolute",
|
|
81
|
+
"bg-primary",
|
|
82
|
+
"select-none",
|
|
83
|
+
"data-[orientation=horizontal]:h-full",
|
|
84
|
+
"data-[orientation=vertical]:w-full data-[orientation=vertical]:not-[[class^='h-']]:not-[[class*='_h-']]:self-stretch",
|
|
85
|
+
"data-invalid:bg-destructive",
|
|
86
|
+
"dark:data-invalid:bg-destructive-foreground"
|
|
87
|
+
),
|
|
88
|
+
"data-slot": "slider-range"
|
|
89
|
+
}
|
|
90
|
+
)
|
|
91
|
+
}
|
|
92
|
+
),
|
|
93
|
+
Array.from({ length: _.length }, (z, o) => {
|
|
94
|
+
const I = `slider-thumb-${o}`;
|
|
95
|
+
return /* @__PURE__ */ a(
|
|
96
|
+
r.Thumb,
|
|
97
|
+
{
|
|
98
|
+
"aria-invalid": g || void 0,
|
|
99
|
+
className: e(
|
|
100
|
+
"relative",
|
|
101
|
+
"shrink-0",
|
|
102
|
+
"size-4.5",
|
|
103
|
+
"bg-white",
|
|
104
|
+
"rounded-full border border-input shadow-xs/5",
|
|
105
|
+
"cursor-grab select-none",
|
|
106
|
+
"transition-[color,box-shadow,transform]",
|
|
107
|
+
"focus-visible:border-primary focus-visible:outline-hidden focus-visible:ring-[3px] focus-visible:ring-ring",
|
|
108
|
+
"origin-left data-dragging:scale-110 data-dragging:cursor-grabbing data-dragging:border-primary data-dragging:ring-[3px] data-dragging:ring-ring",
|
|
109
|
+
"aria-invalid:border-destructive aria-invalid:ring-[3px] aria-invalid:ring-destructive/24",
|
|
110
|
+
"aria-invalid:focus-visible:border-destructive aria-invalid:focus-visible:ring-destructive/48",
|
|
111
|
+
"aria-invalid:data-dragging:border-destructive aria-invalid:data-dragging:ring-destructive/48",
|
|
112
|
+
"pointer-coarse:after:absolute pointer-coarse:after:h-full pointer-coarse:after:min-h-11",
|
|
113
|
+
"motion-reduce:transition-none!"
|
|
114
|
+
),
|
|
115
|
+
"data-slot": "slider-thumb",
|
|
116
|
+
index: o,
|
|
117
|
+
tabIndex: x ?? void 0,
|
|
118
|
+
children: /* @__PURE__ */ a(r.HiddenInput, {})
|
|
119
|
+
},
|
|
120
|
+
I
|
|
121
|
+
);
|
|
122
|
+
})
|
|
123
|
+
]
|
|
124
|
+
}
|
|
125
|
+
),
|
|
126
|
+
f && /* @__PURE__ */ a(
|
|
127
|
+
r.MarkerGroup,
|
|
128
|
+
{
|
|
129
|
+
className: e(
|
|
130
|
+
"w-full",
|
|
131
|
+
"flex items-center justify-between gap-1",
|
|
132
|
+
"mt-3 px-2.5",
|
|
133
|
+
"font-medium text-muted-foreground text-xs",
|
|
134
|
+
"data-[orientation=vertical]:hidden",
|
|
135
|
+
"pointer-events-none"
|
|
136
|
+
),
|
|
137
|
+
children: Array.from({ length: s + 1 }, (z, o) => /* @__PURE__ */ u(
|
|
138
|
+
r.Marker,
|
|
139
|
+
{
|
|
140
|
+
className: e(
|
|
141
|
+
"group/marker",
|
|
142
|
+
"flex w-0 flex-col items-center justify-center gap-2",
|
|
143
|
+
"data-[state=at-value]:text-foreground data-[state=under-value]:text-foreground"
|
|
144
|
+
),
|
|
145
|
+
"data-interval": o % m === 0 ? void 0 : "",
|
|
146
|
+
"data-slot": "slider-marker",
|
|
147
|
+
value: o,
|
|
148
|
+
children: [
|
|
149
|
+
/* @__PURE__ */ a(
|
|
150
|
+
"span",
|
|
151
|
+
{
|
|
152
|
+
className: e(
|
|
153
|
+
"h-1 w-px",
|
|
154
|
+
"bg-muted-foreground/70 group-data-[state=at-value]/marker:bg-foreground group-data-[state=under-value]/marker:bg-foreground",
|
|
155
|
+
"group-data-interval/marker:h-0.5"
|
|
156
|
+
)
|
|
157
|
+
}
|
|
158
|
+
),
|
|
159
|
+
/* @__PURE__ */ a("span", { className: e("group-data-interval/marker:opacity-0"), children: (c == null ? void 0 : c[o]) ?? o })
|
|
160
|
+
]
|
|
161
|
+
},
|
|
162
|
+
String(o)
|
|
163
|
+
))
|
|
164
|
+
}
|
|
165
|
+
)
|
|
166
|
+
]
|
|
167
|
+
}
|
|
168
|
+
);
|
|
169
|
+
}, G = (l) => {
|
|
170
|
+
const { children: i, ...n } = l;
|
|
171
|
+
return /* @__PURE__ */ a(v, { ...n, children: /* @__PURE__ */ a(r.Label, { "data-slot": "slider-label", children: i }) });
|
|
172
|
+
}, H = (l) => {
|
|
173
|
+
const { className: i, slot: n, ...d } = l;
|
|
174
|
+
return /* @__PURE__ */ a(v, { asChild: !0, children: /* @__PURE__ */ a(
|
|
175
|
+
r.ValueText,
|
|
176
|
+
{
|
|
177
|
+
className: e("ms-auto tabular-nums", i),
|
|
178
|
+
...d,
|
|
179
|
+
"data-slot": n ?? "progress-value"
|
|
180
|
+
}
|
|
181
|
+
) });
|
|
182
|
+
};
|
|
183
|
+
export {
|
|
184
|
+
D as Slider,
|
|
185
|
+
G as SliderLabel,
|
|
186
|
+
H as SliderValue,
|
|
187
|
+
$ as useSlider
|
|
188
|
+
};
|
|
189
|
+
//# sourceMappingURL=slider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slider.js","sources":["../../src/simples/slider.tsx"],"sourcesContent":["\"use client\";\n\nimport { type UseFieldContext, useFieldContext } from \"@ark-ui/react/field\";\nimport { Slider as ArkSlider, useSliderContext } from \"@ark-ui/react/slider\";\nimport React from \"react\";\nimport { cn } from \"../lib/cn\";\nimport { FieldLabel } from \"./field\";\n\nexport const useSlider = useSliderContext;\n\ninterface SliderProps extends React.ComponentProps<typeof ArkSlider.Root> {\n /**\n * The interval between markers.\n *\n * @default 1\n */\n markerInterval?: number;\n /**\n * The labels to show on the markers.\n *\n * @default []\n */\n markerLabels?: string[];\n /**\n * Whether to show markers.\n *\n * @default false\n */\n showMarkers?: boolean;\n}\n\n// Divergence from Shark, declared: Ark 5.37.2's `useSlider` reads NO ambient context at all —\n// not Field, not even Fieldset (RadioGroup at least gets the Fieldset bridge) — so a\n// `<Field invalid>` ancestor never reached this control and the flag had to be stated twice.\n// Shark neither bridges it nor styles an invalid slider at all: its own TanStack example wraps\n// `<Field invalid>` around a slider that stays visually pristine. We bridge the state flags and\n// give the control an invalid look consistent with `input.tsx` / `checkbox.tsx`.\n//\n// Two sub-divergences worth knowing:\n// - `required` is bridged for RadioGroup but not here: the slider machine has no `required`\n// prop (only `disabled`, `readOnly`, `invalid`), and a slider always has a value anyway.\n// - zag puts `data-invalid` on root/label/control/track/range but NOT on the thumb, which is\n// the element carrying `role=\"slider\"`. So an invalid slider announced nothing. We set\n// `aria-invalid` on the thumb ourselves and hang the thumb's invalid styling off it, the\n// same way `input.tsx` styles `aria-invalid`.\nexport const Slider = (props: SliderProps) => {\n const {\n value,\n defaultValue,\n min = 0,\n max = 100,\n markerInterval = 1,\n showMarkers = false,\n markerLabels = [],\n disabled,\n invalid,\n readOnly,\n tabIndex,\n className,\n children,\n slot,\n ...rest\n } = props;\n\n const field: UseFieldContext | undefined = useFieldContext();\n\n const isDisabled = disabled ?? field?.disabled;\n const isInvalid = invalid ?? field?.invalid;\n const isReadOnly = readOnly ?? field?.readOnly;\n\n const _values = React.useMemo(() => {\n if (Array.isArray(value)) {\n return value;\n }\n if (Array.isArray(defaultValue)) {\n return defaultValue;\n }\n return [min, max];\n }, [value, defaultValue, min, max]);\n\n return (\n <ArkSlider.Root\n className={cn(\n \"flex flex-col gap-3\",\n \"data-[orientation=horizontal]:w-full\",\n \"data-[orientation=vertical]:h-full\",\n className\n )}\n defaultValue={defaultValue}\n disabled={isDisabled}\n invalid={isInvalid}\n max={max}\n min={min}\n readOnly={isReadOnly}\n value={value}\n {...rest}\n data-slot={slot ?? \"slider\"}\n >\n {children}\n\n <ArkSlider.Control\n className={cn(\n \"relative\",\n \"w-full\",\n \"flex items-center\",\n \"touch-none select-none\",\n \"data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-40 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col\",\n \"data-disabled:pointer-events-none data-disabled:opacity-64\"\n )}\n data-slot=\"slider-control\"\n >\n <ArkSlider.Track\n className={cn(\n \"grow\",\n // The unfilled track is a LEVEL on a backdrop the slider does not own, not a\n // control fill: `--field` recedes to the page in dark, and a track that is the page\n // is a track nobody can see. a4 measures ΔE 5.11 light / 7.73 dark from every surface\n // the theme publishes, against `--field`'s 2.40 / 0.00-on-the-page.\n \"bg-foreground/14\",\n \"rounded-full\",\n \"select-none overflow-hidden\",\n \"data-[orientation=horizontal]:h-2 data-[orientation=horizontal]:w-full\",\n \"data-[orientation=vertical]:h-full data-[orientation=vertical]:w-2\",\n \"data-invalid:bg-destructive/7\"\n )}\n data-slot=\"slider-track\"\n >\n <ArkSlider.Range\n className={cn(\n \"absolute\",\n \"bg-primary\",\n \"select-none\",\n \"data-[orientation=horizontal]:h-full\",\n \"data-[orientation=vertical]:w-full data-[orientation=vertical]:not-[[class^='h-']]:not-[[class*='_h-']]:self-stretch\",\n \"data-invalid:bg-destructive\",\n \"dark:data-invalid:bg-destructive-foreground\"\n )}\n data-slot=\"slider-range\"\n />\n </ArkSlider.Track>\n\n {Array.from({ length: _values.length }, (_, index) => {\n const key = `slider-thumb-${index}`;\n\n return (\n <ArkSlider.Thumb\n aria-invalid={isInvalid || undefined}\n className={cn(\n \"relative\",\n \"shrink-0\",\n \"size-4.5\",\n \"bg-white\",\n \"rounded-full border border-input shadow-xs/5\",\n \"cursor-grab select-none\",\n \"transition-[color,box-shadow,transform]\",\n \"focus-visible:border-primary focus-visible:outline-hidden focus-visible:ring-[3px] focus-visible:ring-ring\",\n \"origin-left data-dragging:scale-110 data-dragging:cursor-grabbing data-dragging:border-primary data-dragging:ring-[3px] data-dragging:ring-ring\",\n \"aria-invalid:border-destructive aria-invalid:ring-[3px] aria-invalid:ring-destructive/24\",\n \"aria-invalid:focus-visible:border-destructive aria-invalid:focus-visible:ring-destructive/48\",\n \"aria-invalid:data-dragging:border-destructive aria-invalid:data-dragging:ring-destructive/48\",\n \"pointer-coarse:after:absolute pointer-coarse:after:h-full pointer-coarse:after:min-h-11\",\n \"motion-reduce:transition-none!\"\n )}\n data-slot=\"slider-thumb\"\n index={index}\n key={key}\n tabIndex={tabIndex ?? undefined}\n >\n <ArkSlider.HiddenInput />\n </ArkSlider.Thumb>\n );\n })}\n </ArkSlider.Control>\n\n {showMarkers && (\n <ArkSlider.MarkerGroup\n className={cn(\n \"w-full\",\n \"flex items-center justify-between gap-1\",\n \"mt-3 px-2.5\",\n \"font-medium text-muted-foreground text-xs\",\n \"data-[orientation=vertical]:hidden\",\n \"pointer-events-none\"\n )}\n >\n {Array.from({ length: max + 1 }, (_, index) => (\n <ArkSlider.Marker\n className={cn(\n \"group/marker\",\n \"flex w-0 flex-col items-center justify-center gap-2\",\n \"data-[state=at-value]:text-foreground data-[state=under-value]:text-foreground\"\n )}\n data-interval={index % markerInterval === 0 ? undefined : \"\"}\n data-slot=\"slider-marker\"\n key={String(index)}\n value={index}\n >\n <span\n className={cn(\n \"h-1 w-px\",\n \"bg-muted-foreground/70 group-data-[state=at-value]/marker:bg-foreground group-data-[state=under-value]/marker:bg-foreground\",\n \"group-data-interval/marker:h-0.5\"\n )}\n />\n\n <span className={cn(\"group-data-interval/marker:opacity-0\")}>\n {markerLabels?.[index] ?? index}\n </span>\n </ArkSlider.Marker>\n ))}\n </ArkSlider.MarkerGroup>\n )}\n </ArkSlider.Root>\n );\n};\n\nexport const SliderLabel = (props: React.ComponentProps<typeof FieldLabel>) => {\n const { children, ...rest } = props;\n\n return (\n <FieldLabel {...rest}>\n <ArkSlider.Label data-slot=\"slider-label\">{children}</ArkSlider.Label>\n </FieldLabel>\n );\n};\n\nexport const SliderValue = (\n props: React.ComponentProps<typeof ArkSlider.ValueText>\n) => {\n const { className, slot, ...rest } = props;\n\n return (\n <FieldLabel asChild>\n <ArkSlider.ValueText\n className={cn(\"ms-auto tabular-nums\", className)}\n {...rest}\n data-slot={slot ?? \"progress-value\"}\n />\n </FieldLabel>\n );\n};\n"],"names":[],"mappings":";;;;;;;AAQO;AAsCL;AAAM;AACJ;AACA;AACM;AACA;AACW;AACH;AACC;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACG;AAmBL;AACE;AAAW;AAAV;AACY;AACT;AACA;AACA;AACA;AAAA;AAEF;AACU;AACD;AACT;AACA;AACU;AACV;AACI;AACe;AAElB;AAAA;AAED;AAAW;AAAV;AACY;AACT;AACA;AACA;AACA;AACA;AACA;AAAA;AAEQ;AAEV;AAAA;AAAW;AAAV;AACY;AACT;AAAA;AAAA;AAAA;AAAA;AAKA;AACA;AACA;AACA;AACA;AACA;AAAA;AAEQ;AAEV;AAAW;AAAV;AACY;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AAAA;AAEQ;AAAA;AAAA;AACZ;AAAA;AAIA;AAEA;AACE;AAAW;AAAV;AAC4B;AAChB;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAAA;AAEQ;AACV;AAEsB;AAEC;AAAA;AAHlB;AAAA;AAMV;AAAA;AAAA;AAAA;AAID;AAAW;AAAV;AACY;AACT;AACA;AACA;AACA;AACA;AACA;AAAA;AAIA;AAAW;AAAV;AACY;AACT;AACA;AACA;AAAA;AAEwD;AAChD;AAEH;AAEP;AAAA;AAAC;AAAA;AACY;AACT;AACA;AACA;AAAA;AACF;AAAA;AAKF;AAAA;AAAA;AAbiB;AAepB;AAAA;AAAA;AACH;AAAA;AAIR;AAGE;AAEA;AAKF;AAKE;AAEA;AAEI;AAAW;AAAV;AACgD;AAC3C;AACe;AAAA;AAI3B;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spinner.d.ts","sourceRoot":"","sources":["../../src/simples/spinner.tsx"],"names":[],"mappings":"AAGA,eAAO,MAAM,OAAO,GAAI,OAAO,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,gCAYzD,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { Loader2Icon as i } from "lucide-react";
|
|
3
|
+
import { cn as n } from "../lib/cn.js";
|
|
4
|
+
const c = (a) => {
|
|
5
|
+
const { "aria-label": r, className: o, slot: s, ...e } = a;
|
|
6
|
+
return /* @__PURE__ */ t(
|
|
7
|
+
i,
|
|
8
|
+
{
|
|
9
|
+
"aria-label": r ?? "Loading",
|
|
10
|
+
className: n("size-4 animate-spin", o),
|
|
11
|
+
role: "status",
|
|
12
|
+
...e,
|
|
13
|
+
"data-slot": s ?? "spinner"
|
|
14
|
+
}
|
|
15
|
+
);
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
c as Spinner
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=spinner.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spinner.js","sources":["../../src/simples/spinner.tsx"],"sourcesContent":["import { Loader2Icon } from \"lucide-react\";\nimport { cn } from \"../lib/cn\";\n\nexport const Spinner = (props: React.ComponentProps<\"svg\">) => {\n const { \"aria-label\": ariaLabel, className, slot, ...rest } = props;\n\n return (\n <Loader2Icon\n aria-label={ariaLabel ?? \"Loading\"}\n className={cn(\"size-4 animate-spin\", className)}\n role=\"status\"\n {...rest}\n data-slot={slot ?? \"spinner\"}\n />\n );\n};\n"],"names":["Spinner","props","ariaLabel","className","slot","rest","jsx","Loader2Icon","cn"],"mappings":";;;AAGO,MAAMA,IAAU,CAACC,MAAuC;AAC7D,QAAM,EAAE,cAAcC,GAAW,WAAAC,GAAW,MAAAC,GAAM,GAAGC,MAASJ;AAE9D,SACE,gBAAAK;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,cAAYL,KAAa;AAAA,MACzB,WAAWM,EAAG,uBAAuBL,CAAS;AAAA,MAC9C,MAAK;AAAA,MACJ,GAAGE;AAAA,MACJ,aAAWD,KAAQ;AAAA,IAAA;AAAA,EAAA;AAGzB;"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export interface StatTileDelta {
|
|
2
|
+
/** Signed change; its magnitude is shown, its sign + `goodWhenUp` pick the colour. */
|
|
3
|
+
value: number;
|
|
4
|
+
/** The comparison period, e.g. "vs last month". */
|
|
5
|
+
label?: string;
|
|
6
|
+
/**
|
|
7
|
+
* Unit for the magnitude — `"%"`, `"pp"`, `"ms"`, `"°C"`. Sits against the number, before the
|
|
8
|
+
* label, because "+8.2 vs last week" is a different claim from "+8.2% vs last week".
|
|
9
|
+
*/
|
|
10
|
+
unit?: string;
|
|
11
|
+
/** Whether an increase is good (green) or bad (red). Default `true`. */
|
|
12
|
+
goodWhenUp?: boolean;
|
|
13
|
+
}
|
|
14
|
+
export interface StatTileProps {
|
|
15
|
+
/** Sentence case, no trailing colon. */
|
|
16
|
+
label: string;
|
|
17
|
+
value: string | number;
|
|
18
|
+
/** Optional prefix for a numeric value, e.g. "$". */
|
|
19
|
+
prefix?: string;
|
|
20
|
+
delta?: StatTileDelta;
|
|
21
|
+
/** Optional ~12-point trend, drawn as a sparkline. */
|
|
22
|
+
trend?: readonly number[];
|
|
23
|
+
className?: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* A headline figure with its label, an optional signed delta and a trend sparkline — the form for
|
|
27
|
+
* when a single number, not a plot, is the answer (dataviz). The value uses proportional figures;
|
|
28
|
+
* the delta is a reserved status colour paired with a direction icon, never colour alone.
|
|
29
|
+
*/
|
|
30
|
+
export declare function StatTile({ label, value, prefix, delta, trend, className }: StatTileProps): import("react").JSX.Element;
|
|
31
|
+
//# sourceMappingURL=stat-tile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stat-tile.d.ts","sourceRoot":"","sources":["../../src/simples/stat-tile.tsx"],"names":[],"mappings":"AAWA,MAAM,WAAW,aAAa;IAC5B,sFAAsF;IACtF,KAAK,EAAE,MAAM,CAAC;IACd,mDAAmD;IACnD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,wEAAwE;IACxE,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,aAAa;IAC5B,wCAAwC;IACxC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC;IACvB,qDAAqD;IACrD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,sDAAsD;IACtD,KAAK,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AA8BD;;;;GAIG;AACH,wBAAgB,QAAQ,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,EAAE,aAAa,+BA4CxF"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { jsxs as c, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { TrendingUpIcon as p, TrendingDownIcon as w } from "lucide-react";
|
|
3
|
+
import { cn as x } from "../lib/cn.js";
|
|
4
|
+
function f(t) {
|
|
5
|
+
return new Intl.NumberFormat("en-US", {
|
|
6
|
+
notation: Math.abs(t) >= 1e4 ? "compact" : "standard",
|
|
7
|
+
maximumFractionDigits: 1
|
|
8
|
+
}).format(t);
|
|
9
|
+
}
|
|
10
|
+
function N({ points: t }) {
|
|
11
|
+
const e = Math.min(...t), i = Math.max(...t) - e || 1, l = t.length > 1 ? 72 / (t.length - 1) : 72, o = t.map((d, u) => [u * l, 22 - (d - e) / i * 22]), m = o.map(([d, u], g) => `${g ? "L" : "M"}${d.toFixed(1)},${u.toFixed(1)}`).join(" "), a = o[o.length - 1] ?? [0, 0];
|
|
12
|
+
return /* @__PURE__ */ c("svg", { "aria-hidden": !0, className: "overflow-visible", height: 22, viewBox: "0 0 72 22", width: 72, children: [
|
|
13
|
+
/* @__PURE__ */ n(
|
|
14
|
+
"path",
|
|
15
|
+
{
|
|
16
|
+
className: "text-muted-foreground",
|
|
17
|
+
d: m,
|
|
18
|
+
fill: "none",
|
|
19
|
+
stroke: "currentColor",
|
|
20
|
+
strokeLinecap: "round",
|
|
21
|
+
strokeLinejoin: "round",
|
|
22
|
+
strokeWidth: 1.5
|
|
23
|
+
}
|
|
24
|
+
),
|
|
25
|
+
/* @__PURE__ */ n("circle", { className: "fill-primary", cx: a[0], cy: a[1], r: 2.5 })
|
|
26
|
+
] });
|
|
27
|
+
}
|
|
28
|
+
function k({ label: t, value: s, prefix: h, delta: e, trend: r, className: i }) {
|
|
29
|
+
const l = typeof s == "number" ? `${h ?? ""}${f(s)}` : s, o = e ? e.value >= 0 : !1, m = e ? o === (e.goodWhenUp ?? !0) : !1, a = o ? p : w;
|
|
30
|
+
return /* @__PURE__ */ c(
|
|
31
|
+
"div",
|
|
32
|
+
{
|
|
33
|
+
className: x("flex flex-col gap-1 rounded-xl border bg-card p-4 shadow-xs/5", i),
|
|
34
|
+
"data-slot": "stat-tile",
|
|
35
|
+
children: [
|
|
36
|
+
/* @__PURE__ */ n("span", { className: "text-muted-foreground text-sm", children: t }),
|
|
37
|
+
/* @__PURE__ */ c("div", { className: "flex items-end justify-between gap-3", children: [
|
|
38
|
+
/* @__PURE__ */ n("span", { className: "font-semibold text-2xl leading-none tracking-tight text-foreground", children: l }),
|
|
39
|
+
r && r.length > 1 && /* @__PURE__ */ n(N, { points: r })
|
|
40
|
+
] }),
|
|
41
|
+
e && /* @__PURE__ */ c(
|
|
42
|
+
"span",
|
|
43
|
+
{
|
|
44
|
+
className: x(
|
|
45
|
+
"flex items-center gap-1 text-xs font-medium",
|
|
46
|
+
m ? "text-success" : "text-destructive-foreground"
|
|
47
|
+
),
|
|
48
|
+
children: [
|
|
49
|
+
/* @__PURE__ */ n(a, { className: "size-3.5" }),
|
|
50
|
+
e.value > 0 ? "+" : "",
|
|
51
|
+
f(e.value),
|
|
52
|
+
e.unit,
|
|
53
|
+
e.label && /* @__PURE__ */ n("span", { className: "text-muted-foreground font-normal", children: e.label })
|
|
54
|
+
]
|
|
55
|
+
}
|
|
56
|
+
)
|
|
57
|
+
]
|
|
58
|
+
}
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
export {
|
|
62
|
+
k as StatTile
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=stat-tile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stat-tile.js","sources":["../../src/simples/stat-tile.tsx"],"sourcesContent":["import { TrendingDownIcon, TrendingUpIcon } from \"lucide-react\";\nimport { cn } from \"../lib/cn.js\";\n\n/** Auto-compact per the dataviz stat-tile contract: 1,284 · 12.9K · $4.2M. */\nfunction compact(v: number): string {\n return new Intl.NumberFormat(\"en-US\", {\n notation: Math.abs(v) >= 10000 ? \"compact\" : \"standard\",\n maximumFractionDigits: 1,\n }).format(v);\n}\n\nexport interface StatTileDelta {\n /** Signed change; its magnitude is shown, its sign + `goodWhenUp` pick the colour. */\n value: number;\n /** The comparison period, e.g. \"vs last month\". */\n label?: string;\n /**\n * Unit for the magnitude — `\"%\"`, `\"pp\"`, `\"ms\"`, `\"°C\"`. Sits against the number, before the\n * label, because \"+8.2 vs last week\" is a different claim from \"+8.2% vs last week\".\n */\n unit?: string;\n /** Whether an increase is good (green) or bad (red). Default `true`. */\n goodWhenUp?: boolean;\n}\n\nexport interface StatTileProps {\n /** Sentence case, no trailing colon. */\n label: string;\n value: string | number;\n /** Optional prefix for a numeric value, e.g. \"$\". */\n prefix?: string;\n delta?: StatTileDelta;\n /** Optional ~12-point trend, drawn as a sparkline. */\n trend?: readonly number[];\n className?: string;\n}\n\nfunction Sparkline({ points }: { points: readonly number[] }) {\n const w = 72;\n const h = 22;\n const min = Math.min(...points);\n const max = Math.max(...points);\n const range = max - min || 1;\n const step = points.length > 1 ? w / (points.length - 1) : w;\n const coords = points.map((p, i) => [i * step, h - ((p - min) / range) * h] as const);\n const d = coords.map(([x, y], i) => `${i ? \"L\" : \"M\"}${x.toFixed(1)},${y.toFixed(1)}`).join(\" \");\n const last = coords[coords.length - 1] ?? [0, 0];\n return (\n <svg aria-hidden className=\"overflow-visible\" height={h} viewBox={`0 0 ${w} ${h}`} width={w}>\n {/* A 1.5px trend line is a graphical object carrying information, so it owes 3:1. Diluted it\n measured 2.91:1 on the light page (3.33–3.35 in dark); step 11 solid is 9.19 and 8.52. */}\n <path\n className=\"text-muted-foreground\"\n d={d}\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth={1.5}\n />\n <circle className=\"fill-primary\" cx={last[0]} cy={last[1]} r={2.5} />\n </svg>\n );\n}\n\n/**\n * A headline figure with its label, an optional signed delta and a trend sparkline — the form for\n * when a single number, not a plot, is the answer (dataviz). The value uses proportional figures;\n * the delta is a reserved status colour paired with a direction icon, never colour alone.\n */\nexport function StatTile({ label, value, prefix, delta, trend, className }: StatTileProps) {\n const shown = typeof value === \"number\" ? `${prefix ?? \"\"}${compact(value)}` : value;\n const up = delta ? delta.value >= 0 : false;\n const good = delta ? up === (delta.goodWhenUp ?? true) : false;\n const DeltaIcon = up ? TrendingUpIcon : TrendingDownIcon;\n\n return (\n <div\n // **`Card`'s surface, at `Card`'s radius.** This read `rounded-lg` with no shadow — one step\n // below every panel in the library (`Card`, `Alert`, `Popover` and `HoverCard` are all\n // `rounded-xl`; `Dialog` and `Sheet` are `rounded-2xl`) and missing the lift they all carry.\n // Nothing argued for the difference; it is a component Shark has no file for, so the only\n // thing holding its appearance to the house was somebody remembering, and\n // `shark-parity.test.ts` compares names and never a class string.\n //\n // Still its own element rather than a composed `Card`: `Card` is an `<article>` on a 24px\n // `--space` with `gap-4`, and a tile is a 16px box with `gap-1`. Composing it would mean\n // overriding both, which is a heavier lie than sharing the three surface utilities.\n className={cn(\"flex flex-col gap-1 rounded-xl border bg-card p-4 shadow-xs/5\", className)}\n data-slot=\"stat-tile\"\n >\n <span className=\"text-muted-foreground text-sm\">{label}</span>\n <div className=\"flex items-end justify-between gap-3\">\n <span className=\"font-semibold text-2xl leading-none tracking-tight text-foreground\">\n {shown}\n </span>\n {trend && trend.length > 1 && <Sparkline points={trend} />}\n </div>\n {delta && (\n <span\n className={cn(\n \"flex items-center gap-1 text-xs font-medium\",\n good ? \"text-success\" : \"text-destructive-foreground\",\n )}\n >\n <DeltaIcon className=\"size-3.5\" />\n {delta.value > 0 ? \"+\" : \"\"}\n {compact(delta.value)}\n {delta.unit}\n {delta.label && <span className=\"text-muted-foreground font-normal\">{delta.label}</span>}\n </span>\n )}\n </div>\n );\n}\n"],"names":["compact","v","Sparkline","points","min","range","step","coords","p","i","d","x","y","last","jsxs","jsx","StatTile","label","value","prefix","delta","trend","className","shown","up","good","DeltaIcon","TrendingUpIcon","TrendingDownIcon","cn"],"mappings":";;;AAIA,SAASA,EAAQC,GAAmB;AAClC,SAAO,IAAI,KAAK,aAAa,SAAS;AAAA,IACpC,UAAU,KAAK,IAAIA,CAAC,KAAK,MAAQ,YAAY;AAAA,IAC7C,uBAAuB;AAAA,EAAA,CACxB,EAAE,OAAOA,CAAC;AACb;AA4BA,SAASC,EAAU,EAAE,QAAAC,KAAyC;AAG5D,QAAMC,IAAM,KAAK,IAAI,GAAGD,CAAM,GAExBE,IADM,KAAK,IAAI,GAAGF,CAAM,IACVC,KAAO,GACrBE,IAAOH,EAAO,SAAS,IAAI,MAAKA,EAAO,SAAS,KAAK,IACrDI,IAASJ,EAAO,IAAI,CAACK,GAAGC,MAAM,CAACA,IAAIH,GAAM,MAAME,IAAIJ,KAAOC,IAAS,EAAC,CAAU,GAC9EK,IAAIH,EAAO,IAAI,CAAC,CAACI,GAAGC,CAAC,GAAGH,MAAM,GAAGA,IAAI,MAAM,GAAG,GAAGE,EAAE,QAAQ,CAAC,CAAC,IAAIC,EAAE,QAAQ,CAAC,CAAC,EAAE,EAAE,KAAK,GAAG,GACzFC,IAAON,EAAOA,EAAO,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC;AAC/C,SACE,gBAAAO,EAAC,OAAA,EAAI,eAAW,IAAC,WAAU,oBAAmB,QAAQ,IAAG,SAAS,aAAiB,OAAO,IAGxF,UAAA;AAAA,IAAA,gBAAAC;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAU;AAAA,QACV,GAAAL;AAAA,QACA,MAAK;AAAA,QACL,QAAO;AAAA,QACP,eAAc;AAAA,QACd,gBAAe;AAAA,QACf,aAAa;AAAA,MAAA;AAAA,IAAA;AAAA,IAEf,gBAAAK,EAAC,UAAA,EAAO,WAAU,gBAAe,IAAIF,EAAK,CAAC,GAAG,IAAIA,EAAK,CAAC,GAAG,GAAG,IAAA,CAAK;AAAA,EAAA,GACrE;AAEJ;AAOO,SAASG,EAAS,EAAE,OAAAC,GAAO,OAAAC,GAAO,QAAAC,GAAQ,OAAAC,GAAO,OAAAC,GAAO,WAAAC,KAA4B;AACzF,QAAMC,IAAQ,OAAOL,KAAU,WAAW,GAAGC,KAAU,EAAE,GAAGnB,EAAQkB,CAAK,CAAC,KAAKA,GACzEM,IAAKJ,IAAQA,EAAM,SAAS,IAAI,IAChCK,IAAOL,IAAQI,OAAQJ,EAAM,cAAc,MAAQ,IACnDM,IAAYF,IAAKG,IAAiBC;AAExC,SACE,gBAAAd;AAAA,IAAC;AAAA,IAAA;AAAA,MAWC,WAAWe,EAAG,iEAAiEP,CAAS;AAAA,MACxF,aAAU;AAAA,MAEV,UAAA;AAAA,QAAA,gBAAAP,EAAC,QAAA,EAAK,WAAU,iCAAiC,UAAAE,GAAM;AAAA,QACvD,gBAAAH,EAAC,OAAA,EAAI,WAAU,wCACb,UAAA;AAAA,UAAA,gBAAAC,EAAC,QAAA,EAAK,WAAU,sEACb,UAAAQ,GACH;AAAA,UACCF,KAASA,EAAM,SAAS,KAAK,gBAAAN,EAACb,GAAA,EAAU,QAAQmB,EAAA,CAAO;AAAA,QAAA,GAC1D;AAAA,QACCD,KACC,gBAAAN;AAAA,UAAC;AAAA,UAAA;AAAA,YACC,WAAWe;AAAA,cACT;AAAA,cACAJ,IAAO,iBAAiB;AAAA,YAAA;AAAA,YAG1B,UAAA;AAAA,cAAA,gBAAAV,EAACW,GAAA,EAAU,WAAU,WAAA,CAAW;AAAA,cAC/BN,EAAM,QAAQ,IAAI,MAAM;AAAA,cACxBpB,EAAQoB,EAAM,KAAK;AAAA,cACnBA,EAAM;AAAA,cACNA,EAAM,SAAS,gBAAAL,EAAC,UAAK,WAAU,qCAAqC,YAAM,MAAA,CAAM;AAAA,YAAA;AAAA,UAAA;AAAA,QAAA;AAAA,MACnF;AAAA,IAAA;AAAA,EAAA;AAIR;"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { ark } from '@ark-ui/react/factory';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
import { VariantProps } from 'tailwind-variants';
|
|
4
|
+
export declare const statusVariants: import('tailwind-variants').TVReturnType<{
|
|
5
|
+
variant: {
|
|
6
|
+
default: string;
|
|
7
|
+
success: string;
|
|
8
|
+
info: string;
|
|
9
|
+
warning: string;
|
|
10
|
+
destructive: string;
|
|
11
|
+
};
|
|
12
|
+
size: {
|
|
13
|
+
sm: string;
|
|
14
|
+
md: string;
|
|
15
|
+
lg: string;
|
|
16
|
+
};
|
|
17
|
+
}, undefined, string[], {
|
|
18
|
+
variant: {
|
|
19
|
+
default: string;
|
|
20
|
+
success: string;
|
|
21
|
+
info: string;
|
|
22
|
+
warning: string;
|
|
23
|
+
destructive: string;
|
|
24
|
+
};
|
|
25
|
+
size: {
|
|
26
|
+
sm: string;
|
|
27
|
+
md: string;
|
|
28
|
+
lg: string;
|
|
29
|
+
};
|
|
30
|
+
}, undefined, import('tailwind-variants').TVReturnType<{
|
|
31
|
+
variant: {
|
|
32
|
+
default: string;
|
|
33
|
+
success: string;
|
|
34
|
+
info: string;
|
|
35
|
+
warning: string;
|
|
36
|
+
destructive: string;
|
|
37
|
+
};
|
|
38
|
+
size: {
|
|
39
|
+
sm: string;
|
|
40
|
+
md: string;
|
|
41
|
+
lg: string;
|
|
42
|
+
};
|
|
43
|
+
}, undefined, string[], unknown, unknown, undefined>>;
|
|
44
|
+
interface StatusProps extends React.ComponentProps<typeof ark.span>, VariantProps<typeof statusVariants> {
|
|
45
|
+
}
|
|
46
|
+
export declare const Status: (props: StatusProps) => React.JSX.Element;
|
|
47
|
+
export {};
|
|
48
|
+
//# sourceMappingURL=status.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../../src/simples/status.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAC5C,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAG1D,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qDAmCzB,CAAC;AAEH,UAAU,WACR,SAAQ,KAAK,CAAC,cAAc,CAAC,OAAO,GAAG,CAAC,IAAI,CAAC,EAC3C,YAAY,CAAC,OAAO,cAAc,CAAC;CAAG;AAE1C,eAAO,MAAM,MAAM,GAAI,OAAO,WAAW,sBAYxC,CAAC"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { ark as o } from "@ark-ui/react/factory";
|
|
3
|
+
import { tv as c } from "tailwind-variants";
|
|
4
|
+
import { cn as g } from "../lib/cn.js";
|
|
5
|
+
const u = c({
|
|
6
|
+
base: [
|
|
7
|
+
"shrink-0 rounded-full",
|
|
8
|
+
"flex items-center justify-center",
|
|
9
|
+
"font-medium text-[10px]",
|
|
10
|
+
"ring-2 ring-background"
|
|
11
|
+
],
|
|
12
|
+
variants: {
|
|
13
|
+
variant: {
|
|
14
|
+
default: "bg-foreground text-background",
|
|
15
|
+
// `text-*-content`, not `text-white`. The literal was the one sanctioned exception to
|
|
16
|
+
// token-backed utilities, and it was failing AA on every variant — warning at 2.13, success
|
|
17
|
+
// at 2.47 — because with no token there was nothing to measure. The ink is now declared per
|
|
18
|
+
// family by measurement: the fills that hold white keep it, the two that cannot take
|
|
19
|
+
// near-black instead.
|
|
20
|
+
success: "bg-success text-success-content",
|
|
21
|
+
info: "bg-info text-info-content",
|
|
22
|
+
warning: "bg-warning text-warning-content",
|
|
23
|
+
// No `dark:bg-destructive-foreground`, though Shark ships one. It moved the fill and left the
|
|
24
|
+
// ink, so a glyph inside the dot measured 2.35:1 in dark — the `text-white` defect these
|
|
25
|
+
// `-content` tokens exist to kill, reappearing through a `dark:` override. Without it every
|
|
26
|
+
// variant clears AA in both modes; the tightest are this one in light (4.57) and info in dark
|
|
27
|
+
// (4.58). Five variants, one rule, nothing to remember.
|
|
28
|
+
destructive: "bg-destructive text-destructive-content"
|
|
29
|
+
},
|
|
30
|
+
size: {
|
|
31
|
+
sm: "size-2 [&_svg:not([class*='size-'])]:size-1.5 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
32
|
+
md: "size-2.5 [&_svg:not([class*='size-'])]:size-2 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
33
|
+
lg: "size-3 [&_svg:not([class*='size-'])]:size-2.5 [&_svg]:pointer-events-none [&_svg]:shrink-0"
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
defaultVariants: {
|
|
37
|
+
variant: "default",
|
|
38
|
+
size: "md"
|
|
39
|
+
}
|
|
40
|
+
}), l = (s) => {
|
|
41
|
+
const { variant: e, size: t, className: n, slot: i, ...r } = s;
|
|
42
|
+
return /* @__PURE__ */ a(
|
|
43
|
+
o.span,
|
|
44
|
+
{
|
|
45
|
+
"aria-hidden": "true",
|
|
46
|
+
className: g(u({ variant: e, size: t }), n),
|
|
47
|
+
"data-size": t,
|
|
48
|
+
...r,
|
|
49
|
+
"data-slot": i ?? "status-indicator"
|
|
50
|
+
}
|
|
51
|
+
);
|
|
52
|
+
};
|
|
53
|
+
export {
|
|
54
|
+
l as Status,
|
|
55
|
+
u as statusVariants
|
|
56
|
+
};
|
|
57
|
+
//# sourceMappingURL=status.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status.js","sources":["../../src/simples/status.tsx"],"sourcesContent":["import { ark } from \"@ark-ui/react/factory\";\nimport type React from \"react\";\nimport { tv, type VariantProps } from \"tailwind-variants\";\nimport { cn } from \"../lib/cn\";\n\nexport const statusVariants = tv({\n base: [\n \"shrink-0 rounded-full\",\n \"flex items-center justify-center\",\n \"font-medium text-[10px]\",\n \"ring-2 ring-background\",\n ],\n variants: {\n variant: {\n default: \"bg-foreground text-background\",\n // `text-*-content`, not `text-white`. The literal was the one sanctioned exception to\n // token-backed utilities, and it was failing AA on every variant — warning at 2.13, success\n // at 2.47 — because with no token there was nothing to measure. The ink is now declared per\n // family by measurement: the fills that hold white keep it, the two that cannot take\n // near-black instead.\n success: \"bg-success text-success-content\",\n info: \"bg-info text-info-content\",\n warning: \"bg-warning text-warning-content\",\n // No `dark:bg-destructive-foreground`, though Shark ships one. It moved the fill and left the\n // ink, so a glyph inside the dot measured 2.35:1 in dark — the `text-white` defect these\n // `-content` tokens exist to kill, reappearing through a `dark:` override. Without it every\n // variant clears AA in both modes; the tightest are this one in light (4.57) and info in dark\n // (4.58). Five variants, one rule, nothing to remember.\n destructive: \"bg-destructive text-destructive-content\",\n },\n size: {\n sm: \"size-2 [&_svg:not([class*='size-'])]:size-1.5 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n md: \"size-2.5 [&_svg:not([class*='size-'])]:size-2 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n lg: \"size-3 [&_svg:not([class*='size-'])]:size-2.5 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n size: \"md\",\n },\n});\n\ninterface StatusProps\n extends React.ComponentProps<typeof ark.span>,\n VariantProps<typeof statusVariants> {}\n\nexport const Status = (props: StatusProps) => {\n const { variant, size, className, slot, ...rest } = props;\n\n return (\n <ark.span\n aria-hidden=\"true\"\n className={cn(statusVariants({ variant, size }), className)}\n data-size={size}\n {...rest}\n data-slot={slot ?? \"status-indicator\"}\n />\n );\n};\n"],"names":["statusVariants","tv","Status","props","variant","size","className","slot","rest","jsx","ark","cn"],"mappings":";;;;AAKO,MAAMA,IAAiBC,EAAG;AAAA,EAC/B,MAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EAAA;AAAA,EAEF,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MAMT,SAAS;AAAA,MACT,MAAM;AAAA,MACN,SAAS;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MAMT,aAAa;AAAA,IAAA;AAAA,IAEf,MAAM;AAAA,MACJ,IAAI;AAAA,MACJ,IAAI;AAAA,MACJ,IAAI;AAAA,IAAA;AAAA,EACN;AAAA,EAEF,iBAAiB;AAAA,IACf,SAAS;AAAA,IACT,MAAM;AAAA,EAAA;AAEV,CAAC,GAMYC,IAAS,CAACC,MAAuB;AAC5C,QAAM,EAAE,SAAAC,GAAS,MAAAC,GAAM,WAAAC,GAAW,MAAAC,GAAM,GAAGC,MAASL;AAEpD,SACE,gBAAAM;AAAA,IAACC,EAAI;AAAA,IAAJ;AAAA,MACC,eAAY;AAAA,MACZ,WAAWC,EAAGX,EAAe,EAAE,SAAAI,GAAS,MAAAC,EAAA,CAAM,GAAGC,CAAS;AAAA,MAC1D,aAAWD;AAAA,MACV,GAAGG;AAAA,MACJ,aAAWD,KAAQ;AAAA,IAAA;AAAA,EAAA;AAGzB;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ark } from '@ark-ui/react/factory';
|
|
2
|
+
import { Steps as ArkSteps } from '@ark-ui/react/steps';
|
|
3
|
+
import { default as React } from 'react';
|
|
4
|
+
export declare const useSteps: () => import('@ark-ui/react').UseStepsContext;
|
|
5
|
+
export declare const Steps: (props: React.ComponentProps<typeof ArkSteps.Root>) => React.JSX.Element;
|
|
6
|
+
export declare const StepsList: (props: React.ComponentProps<typeof ArkSteps.List>) => React.JSX.Element;
|
|
7
|
+
export declare const StepsItem: (props: React.ComponentProps<typeof ArkSteps.Item>) => React.JSX.Element;
|
|
8
|
+
interface StepsTriggerProps extends React.ComponentProps<typeof ArkSteps.Trigger> {
|
|
9
|
+
}
|
|
10
|
+
export declare const StepsTrigger: (props: StepsTriggerProps) => React.JSX.Element;
|
|
11
|
+
export declare const StepsIndicator: (props: React.ComponentProps<typeof ArkSteps.Indicator>) => React.JSX.Element;
|
|
12
|
+
export declare const StepsSeparator: (props: React.ComponentProps<typeof ArkSteps.Separator>) => React.JSX.Element;
|
|
13
|
+
export declare const StepsTitle: (props: React.ComponentProps<typeof ark.span>) => React.JSX.Element;
|
|
14
|
+
export declare const StepsDescription: (props: React.ComponentProps<typeof ark.span>) => React.JSX.Element;
|
|
15
|
+
export declare const StepsContent: (props: React.ComponentProps<typeof ArkSteps.Content>) => React.JSX.Element;
|
|
16
|
+
export declare const StepsCompletedContent: (props: React.ComponentProps<typeof ArkSteps.CompletedContent>) => React.JSX.Element;
|
|
17
|
+
export declare const StepsPrevious: ({ slot, ...rest }: React.ComponentProps<typeof ArkSteps.PrevTrigger>) => React.JSX.Element;
|
|
18
|
+
export declare const StepsNext: ({ slot, ...rest }: React.ComponentProps<typeof ArkSteps.NextTrigger>) => React.JSX.Element;
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=steps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"steps.d.ts","sourceRoot":"","sources":["../../src/simples/steps.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAC5C,OAAO,EAAE,KAAK,IAAI,QAAQ,EAAmB,MAAM,qBAAqB,CAAC;AAEzE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,eAAO,MAAM,QAAQ,+CAAkB,CAAC;AAExC,eAAO,MAAM,KAAK,GAAI,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,IAAI,CAAC,sBActE,CAAC;AAEF,eAAO,MAAM,SAAS,GACpB,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,IAAI,CAAC,sBAiBlD,CAAC;AAEF,eAAO,MAAM,SAAS,GACpB,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,IAAI,CAAC,sBAkBlD,CAAC;AAEF,UAAU,iBACR,SAAQ,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,OAAO,CAAC;CAAG;AAE1D,eAAO,MAAM,YAAY,GAAI,OAAO,iBAAiB,sBAepD,CAAC;AAEF,eAAO,MAAM,cAAc,GACzB,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,SAAS,CAAC,sBA2BvD,CAAC;AAEF,eAAO,MAAM,cAAc,GACzB,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,SAAS,CAAC,sBAqBvD,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,GAAG,CAAC,IAAI,CAAC,sBAUtE,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAC3B,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,GAAG,CAAC,IAAI,CAAC,sBAW7C,CAAC;AAEF,eAAO,MAAM,YAAY,GACvB,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,OAAO,CAAC,sBAWrD,CAAC;AAEF,eAAO,MAAM,qBAAqB,GAChC,OAAO,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,gBAAgB,CAAC,sBAW9D,CAAC;AAEF,eAAO,MAAM,aAAa,GACxB,mBAAmB,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,WAAW,CAAC,sBACM,CAAC;AAE7E,eAAO,MAAM,SAAS,GACpB,mBAAmB,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,WAAW,CAAC,sBACE,CAAC"}
|