@agentage/components 0.0.0-stage → 0.21.1
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/LICENSE +21 -0
- package/README.md +207 -2
- package/dist/components/accordion.context.d.ts +17 -0
- package/dist/components/accordion.context.d.ts.map +1 -0
- package/dist/components/accordion.context.js +14 -0
- package/dist/components/accordion.d.ts +27 -0
- package/dist/components/accordion.d.ts.map +1 -0
- package/dist/components/accordion.js +90 -0
- package/dist/components/accordion.trigger.d.ts +11 -0
- package/dist/components/accordion.trigger.d.ts.map +1 -0
- package/dist/components/accordion.trigger.js +57 -0
- package/dist/components/action-bar.d.ts +29 -0
- package/dist/components/action-bar.d.ts.map +1 -0
- package/dist/components/action-bar.js +119 -0
- package/dist/components/action-bar.parts.d.ts +23 -0
- package/dist/components/action-bar.parts.d.ts.map +1 -0
- package/dist/components/action-bar.parts.js +117 -0
- package/dist/components/alert.d.ts +17 -0
- package/dist/components/alert.d.ts.map +1 -0
- package/dist/components/alert.js +73 -0
- package/dist/components/avatar.d.ts +22 -0
- package/dist/components/avatar.d.ts.map +1 -0
- package/dist/components/avatar.js +82 -0
- package/dist/components/badge.d.ts +20 -0
- package/dist/components/badge.d.ts.map +1 -0
- package/dist/components/badge.js +32 -0
- package/dist/components/breadcrumb.d.ts +12 -0
- package/dist/components/breadcrumb.d.ts.map +1 -0
- package/dist/components/breadcrumb.js +70 -0
- package/dist/components/button.d.ts +17 -0
- package/dist/components/button.d.ts.map +1 -0
- package/dist/components/button.js +43 -0
- package/dist/components/button.variants.d.ts +5 -0
- package/dist/components/button.variants.d.ts.map +1 -0
- package/dist/components/button.variants.js +26 -0
- package/dist/components/card-base.d.ts +10 -0
- package/dist/components/card-base.d.ts.map +1 -0
- package/dist/components/card-base.js +10 -0
- package/dist/components/card-state.d.ts +45 -0
- package/dist/components/card-state.d.ts.map +1 -0
- package/dist/components/card-state.js +137 -0
- package/dist/components/card.d.ts +25 -0
- package/dist/components/card.d.ts.map +1 -0
- package/dist/components/card.js +62 -0
- package/dist/components/card.parts.d.ts +9 -0
- package/dist/components/card.parts.d.ts.map +1 -0
- package/dist/components/card.parts.js +37 -0
- package/dist/components/check-list.d.ts +30 -0
- package/dist/components/check-list.d.ts.map +1 -0
- package/dist/components/check-list.js +88 -0
- package/dist/components/check-list.parts.d.ts +17 -0
- package/dist/components/check-list.parts.d.ts.map +1 -0
- package/dist/components/check-list.parts.js +40 -0
- package/dist/components/checkbox.d.ts +24 -0
- package/dist/components/checkbox.d.ts.map +1 -0
- package/dist/components/checkbox.js +103 -0
- package/dist/components/chip.d.ts +17 -0
- package/dist/components/chip.d.ts.map +1 -0
- package/dist/components/chip.js +93 -0
- package/dist/components/code-block.d.ts +15 -0
- package/dist/components/code-block.d.ts.map +1 -0
- package/dist/components/code-block.js +87 -0
- package/dist/components/collapsible.d.ts +27 -0
- package/dist/components/collapsible.d.ts.map +1 -0
- package/dist/components/collapsible.js +81 -0
- package/dist/components/command.context.d.ts +16 -0
- package/dist/components/command.context.d.ts.map +1 -0
- package/dist/components/command.context.js +13 -0
- package/dist/components/command.d.ts +19 -0
- package/dist/components/command.d.ts.map +1 -0
- package/dist/components/command.js +125 -0
- package/dist/components/command.parts.d.ts +18 -0
- package/dist/components/command.parts.d.ts.map +1 -0
- package/dist/components/command.parts.js +77 -0
- package/dist/components/command.variants.d.ts +6 -0
- package/dist/components/command.variants.d.ts.map +1 -0
- package/dist/components/command.variants.js +23 -0
- package/dist/components/content-block.d.ts +24 -0
- package/dist/components/content-block.d.ts.map +1 -0
- package/dist/components/content-block.diff.d.ts +26 -0
- package/dist/components/content-block.diff.d.ts.map +1 -0
- package/dist/components/content-block.diff.js +110 -0
- package/dist/components/content-block.js +61 -0
- package/dist/components/content-block.parts.d.ts +12 -0
- package/dist/components/content-block.parts.d.ts.map +1 -0
- package/dist/components/content-block.parts.js +52 -0
- package/dist/components/content-blocks.d.ts +61 -0
- package/dist/components/content-blocks.d.ts.map +1 -0
- package/dist/components/content-blocks.js +99 -0
- package/dist/components/content-blocks.meta.d.ts +21 -0
- package/dist/components/content-blocks.meta.d.ts.map +1 -0
- package/dist/components/content-blocks.meta.js +56 -0
- package/dist/components/control.variants.d.ts +10 -0
- package/dist/components/control.variants.d.ts.map +1 -0
- package/dist/components/control.variants.js +25 -0
- package/dist/components/copy-button.d.ts +15 -0
- package/dist/components/copy-button.d.ts.map +1 -0
- package/dist/components/copy-button.js +96 -0
- package/dist/components/count.d.ts +5 -0
- package/dist/components/count.d.ts.map +1 -0
- package/dist/components/count.js +12 -0
- package/dist/components/data-table.body.d.ts +36 -0
- package/dist/components/data-table.body.d.ts.map +1 -0
- package/dist/components/data-table.body.js +112 -0
- package/dist/components/data-table.d.ts +14 -0
- package/dist/components/data-table.d.ts.map +1 -0
- package/dist/components/data-table.group-head.d.ts +17 -0
- package/dist/components/data-table.group-head.d.ts.map +1 -0
- package/dist/components/data-table.group-head.js +40 -0
- package/dist/components/data-table.group.d.ts +27 -0
- package/dist/components/data-table.group.d.ts.map +1 -0
- package/dist/components/data-table.group.js +32 -0
- package/dist/components/data-table.js +115 -0
- package/dist/components/data-table.menu.d.ts +12 -0
- package/dist/components/data-table.menu.d.ts.map +1 -0
- package/dist/components/data-table.menu.js +39 -0
- package/dist/components/data-table.parts.d.ts +28 -0
- package/dist/components/data-table.parts.d.ts.map +1 -0
- package/dist/components/data-table.parts.js +54 -0
- package/dist/components/data-table.selection.d.ts +27 -0
- package/dist/components/data-table.selection.d.ts.map +1 -0
- package/dist/components/data-table.selection.js +42 -0
- package/dist/components/data-table.state.d.ts +8 -0
- package/dist/components/data-table.state.d.ts.map +1 -0
- package/dist/components/data-table.state.js +11 -0
- package/dist/components/data-table.types.d.ts +71 -0
- package/dist/components/data-table.types.d.ts.map +1 -0
- package/dist/components/data-table.types.js +0 -0
- package/dist/components/data-table.variants.d.ts +22 -0
- package/dist/components/data-table.variants.d.ts.map +1 -0
- package/dist/components/data-table.variants.js +91 -0
- package/dist/components/data-tree.d.ts +20 -0
- package/dist/components/data-tree.d.ts.map +1 -0
- package/dist/components/data-tree.js +75 -0
- package/dist/components/data-tree.model.d.ts +35 -0
- package/dist/components/data-tree.model.d.ts.map +1 -0
- package/dist/components/data-tree.model.js +70 -0
- package/dist/components/data-tree.row.d.ts +23 -0
- package/dist/components/data-tree.row.d.ts.map +1 -0
- package/dist/components/data-tree.row.js +109 -0
- package/dist/components/data-view.board-card.d.ts +18 -0
- package/dist/components/data-view.board-card.d.ts.map +1 -0
- package/dist/components/data-view.board-card.js +74 -0
- package/dist/components/data-view.board-head.d.ts +14 -0
- package/dist/components/data-view.board-head.d.ts.map +1 -0
- package/dist/components/data-view.board-head.js +61 -0
- package/dist/components/data-view.board.d.ts +31 -0
- package/dist/components/data-view.board.d.ts.map +1 -0
- package/dist/components/data-view.board.js +120 -0
- package/dist/components/data-view.config.d.ts +70 -0
- package/dist/components/data-view.config.d.ts.map +1 -0
- package/dist/components/data-view.config.js +68 -0
- package/dist/components/data-view.d.ts +10 -0
- package/dist/components/data-view.d.ts.map +1 -0
- package/dist/components/data-view.hooks.d.ts +23 -0
- package/dist/components/data-view.hooks.d.ts.map +1 -0
- package/dist/components/data-view.hooks.js +104 -0
- package/dist/components/data-view.js +117 -0
- package/dist/components/data-view.parts.d.ts +22 -0
- package/dist/components/data-view.parts.d.ts.map +1 -0
- package/dist/components/data-view.parts.js +29 -0
- package/dist/components/data-view.toolbar.d.ts +34 -0
- package/dist/components/data-view.toolbar.d.ts.map +1 -0
- package/dist/components/data-view.toolbar.js +134 -0
- package/dist/components/data-view.types.d.ts +53 -0
- package/dist/components/data-view.types.d.ts.map +1 -0
- package/dist/components/data-view.types.js +0 -0
- package/dist/components/date-picker.d.ts +27 -0
- package/dist/components/date-picker.d.ts.map +1 -0
- package/dist/components/date-picker.js +123 -0
- package/dist/components/date-picker.range.d.ts +18 -0
- package/dist/components/date-picker.range.d.ts.map +1 -0
- package/dist/components/date-picker.range.js +97 -0
- package/dist/components/date-picker.range.parts.d.ts +12 -0
- package/dist/components/date-picker.range.parts.d.ts.map +1 -0
- package/dist/components/date-picker.range.parts.js +80 -0
- package/dist/components/description-list.d.ts +33 -0
- package/dist/components/description-list.d.ts.map +1 -0
- package/dist/components/description-list.js +75 -0
- package/dist/components/description-list.property.d.ts +25 -0
- package/dist/components/description-list.property.d.ts.map +1 -0
- package/dist/components/description-list.property.js +36 -0
- package/dist/components/description-list.variants.d.ts +8 -0
- package/dist/components/description-list.variants.d.ts.map +1 -0
- package/dist/components/description-list.variants.js +74 -0
- package/dist/components/dialog-shell.d.ts +36 -0
- package/dist/components/dialog-shell.d.ts.map +1 -0
- package/dist/components/dialog-shell.js +69 -0
- package/dist/components/dialog.confirm.d.ts +8 -0
- package/dist/components/dialog.confirm.d.ts.map +1 -0
- package/dist/components/dialog.confirm.js +91 -0
- package/dist/components/dialog.d.ts +27 -0
- package/dist/components/dialog.d.ts.map +1 -0
- package/dist/components/dialog.js +53 -0
- package/dist/components/dialog.phrase.d.ts +9 -0
- package/dist/components/dialog.phrase.d.ts.map +1 -0
- package/dist/components/dialog.phrase.js +43 -0
- package/dist/components/dirty-bar.d.ts +30 -0
- package/dist/components/dirty-bar.d.ts.map +1 -0
- package/dist/components/dirty-bar.js +109 -0
- package/dist/components/disclosure.d.ts +24 -0
- package/dist/components/disclosure.d.ts.map +1 -0
- package/dist/components/disclosure.js +34 -0
- package/dist/components/dropdown-menu.d.ts +16 -0
- package/dist/components/dropdown-menu.d.ts.map +1 -0
- package/dist/components/dropdown-menu.items.d.ts +15 -0
- package/dist/components/dropdown-menu.items.d.ts.map +1 -0
- package/dist/components/dropdown-menu.items.js +25 -0
- package/dist/components/dropdown-menu.js +80 -0
- package/dist/components/dropdown-menu.variants.d.ts +2 -0
- package/dist/components/dropdown-menu.variants.d.ts.map +1 -0
- package/dist/components/dropdown-menu.variants.js +1 -0
- package/dist/components/empty-state.d.ts +11 -0
- package/dist/components/empty-state.d.ts.map +1 -0
- package/dist/components/empty-state.js +33 -0
- package/dist/components/entity-card.d.ts +34 -0
- package/dist/components/entity-card.d.ts.map +1 -0
- package/dist/components/entity-card.js +87 -0
- package/dist/components/entity-list.d.ts +30 -0
- package/dist/components/entity-list.d.ts.map +1 -0
- package/dist/components/entity-list.items.d.ts +20 -0
- package/dist/components/entity-list.items.d.ts.map +1 -0
- package/dist/components/entity-list.items.js +59 -0
- package/dist/components/entity-list.js +61 -0
- package/dist/components/entity-list.parts.d.ts +35 -0
- package/dist/components/entity-list.parts.d.ts.map +1 -0
- package/dist/components/entity-list.parts.js +86 -0
- package/dist/components/entity-list.row.d.ts +14 -0
- package/dist/components/entity-list.row.d.ts.map +1 -0
- package/dist/components/entity-list.row.js +58 -0
- package/dist/components/form-field.d.ts +13 -0
- package/dist/components/form-field.d.ts.map +1 -0
- package/dist/components/form-field.js +65 -0
- package/dist/components/form-field.live.d.ts +6 -0
- package/dist/components/form-field.live.d.ts.map +1 -0
- package/dist/components/form-field.live.js +19 -0
- package/dist/components/group-header.d.ts +23 -0
- package/dist/components/group-header.d.ts.map +1 -0
- package/dist/components/group-header.js +81 -0
- package/dist/components/highlight.d.ts +4 -0
- package/dist/components/highlight.d.ts.map +1 -0
- package/dist/components/highlight.js +14 -0
- package/dist/components/icon-button.d.ts +15 -0
- package/dist/components/icon-button.d.ts.map +1 -0
- package/dist/components/icon-button.js +25 -0
- package/dist/components/index.d.ts +155 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +95 -0
- package/dist/components/inline-edit.d.ts +24 -0
- package/dist/components/inline-edit.d.ts.map +1 -0
- package/dist/components/inline-edit.js +68 -0
- package/dist/components/input.d.ts +35 -0
- package/dist/components/input.d.ts.map +1 -0
- package/dist/components/input.js +101 -0
- package/dist/components/kbd.d.ts +5 -0
- package/dist/components/kbd.d.ts.map +1 -0
- package/dist/components/kbd.js +12 -0
- package/dist/components/label.d.ts +5 -0
- package/dist/components/label.d.ts.map +1 -0
- package/dist/components/label.js +16 -0
- package/dist/components/list-toolbar.d.ts +37 -0
- package/dist/components/list-toolbar.d.ts.map +1 -0
- package/dist/components/list-toolbar.filter.d.ts +13 -0
- package/dist/components/list-toolbar.filter.d.ts.map +1 -0
- package/dist/components/list-toolbar.filter.js +65 -0
- package/dist/components/list-toolbar.fit.d.ts +24 -0
- package/dist/components/list-toolbar.fit.d.ts.map +1 -0
- package/dist/components/list-toolbar.fit.js +69 -0
- package/dist/components/list-toolbar.icons.d.ts +10 -0
- package/dist/components/list-toolbar.icons.d.ts.map +1 -0
- package/dist/components/list-toolbar.icons.js +21 -0
- package/dist/components/list-toolbar.js +68 -0
- package/dist/components/list-toolbar.menus.d.ts +26 -0
- package/dist/components/list-toolbar.menus.d.ts.map +1 -0
- package/dist/components/list-toolbar.menus.js +98 -0
- package/dist/components/list-toolbar.parts.d.ts +25 -0
- package/dist/components/list-toolbar.parts.d.ts.map +1 -0
- package/dist/components/list-toolbar.parts.js +72 -0
- package/dist/components/list-toolbar.search.d.ts +8 -0
- package/dist/components/list-toolbar.search.d.ts.map +1 -0
- package/dist/components/list-toolbar.search.js +54 -0
- package/dist/components/list-toolbar.variants.d.ts +11 -0
- package/dist/components/list-toolbar.variants.d.ts.map +1 -0
- package/dist/components/list-toolbar.variants.js +9 -0
- package/dist/components/log-view.d.ts +25 -0
- package/dist/components/log-view.d.ts.map +1 -0
- package/dist/components/log-view.hooks.d.ts +40 -0
- package/dist/components/log-view.hooks.d.ts.map +1 -0
- package/dist/components/log-view.hooks.js +87 -0
- package/dist/components/log-view.js +110 -0
- package/dist/components/log-view.model.d.ts +35 -0
- package/dist/components/log-view.model.d.ts.map +1 -0
- package/dist/components/log-view.model.js +56 -0
- package/dist/components/log-view.row.d.ts +31 -0
- package/dist/components/log-view.row.d.ts.map +1 -0
- package/dist/components/log-view.row.js +127 -0
- package/dist/components/menu.parts.d.ts +26 -0
- package/dist/components/menu.parts.d.ts.map +1 -0
- package/dist/components/menu.parts.js +59 -0
- package/dist/components/menu.selectable.d.ts +24 -0
- package/dist/components/menu.selectable.d.ts.map +1 -0
- package/dist/components/menu.selectable.js +66 -0
- package/dist/components/menu.variants.d.ts +9 -0
- package/dist/components/menu.variants.d.ts.map +1 -0
- package/dist/components/menu.variants.js +16 -0
- package/dist/components/nav-tree.d.ts +22 -0
- package/dist/components/nav-tree.d.ts.map +1 -0
- package/dist/components/nav-tree.js +95 -0
- package/dist/components/nav-tree.variants.d.ts +13 -0
- package/dist/components/nav-tree.variants.d.ts.map +1 -0
- package/dist/components/nav-tree.variants.js +9 -0
- package/dist/components/page-header.d.ts +34 -0
- package/dist/components/page-header.d.ts.map +1 -0
- package/dist/components/page-header.js +115 -0
- package/dist/components/pagination.d.ts +13 -0
- package/dist/components/pagination.d.ts.map +1 -0
- package/dist/components/pagination.js +114 -0
- package/dist/components/popover.d.ts +18 -0
- package/dist/components/popover.d.ts.map +1 -0
- package/dist/components/popover.js +64 -0
- package/dist/components/priority-glyph.d.ts +11 -0
- package/dist/components/priority-glyph.d.ts.map +1 -0
- package/dist/components/priority-glyph.js +75 -0
- package/dist/components/progress.d.ts +30 -0
- package/dist/components/progress.d.ts.map +1 -0
- package/dist/components/progress.js +87 -0
- package/dist/components/progress.meter.d.ts +36 -0
- package/dist/components/progress.meter.d.ts.map +1 -0
- package/dist/components/progress.meter.js +64 -0
- package/dist/components/progress.segments.d.ts +28 -0
- package/dist/components/progress.segments.d.ts.map +1 -0
- package/dist/components/progress.segments.js +59 -0
- package/dist/components/property-date.d.ts +11 -0
- package/dist/components/property-date.d.ts.map +1 -0
- package/dist/components/property-date.format.d.ts +3 -0
- package/dist/components/property-date.format.d.ts.map +1 -0
- package/dist/components/property-date.format.js +7 -0
- package/dist/components/property-date.js +142 -0
- package/dist/components/property-select.d.ts +28 -0
- package/dist/components/property-select.d.ts.map +1 -0
- package/dist/components/property-select.js +68 -0
- package/dist/components/prose.d.ts +6 -0
- package/dist/components/prose.d.ts.map +1 -0
- package/dist/components/prose.js +13 -0
- package/dist/components/radio-group.d.ts +23 -0
- package/dist/components/radio-group.d.ts.map +1 -0
- package/dist/components/radio-group.js +116 -0
- package/dist/components/relative-time.d.ts +12 -0
- package/dist/components/relative-time.d.ts.map +1 -0
- package/dist/components/relative-time.js +30 -0
- package/dist/components/resizable-split-prepaint.d.ts +12 -0
- package/dist/components/resizable-split-prepaint.d.ts.map +1 -0
- package/dist/components/resizable-split-prepaint.js +5 -0
- package/dist/components/resizable-split.context.d.ts +11 -0
- package/dist/components/resizable-split.context.d.ts.map +1 -0
- package/dist/components/resizable-split.context.js +9 -0
- package/dist/components/resizable-split.d.ts +30 -0
- package/dist/components/resizable-split.d.ts.map +1 -0
- package/dist/components/resizable-split.js +85 -0
- package/dist/components/resizable.d.ts +21 -0
- package/dist/components/resizable.d.ts.map +1 -0
- package/dist/components/resizable.js +90 -0
- package/dist/components/resizable.model.d.ts +18 -0
- package/dist/components/resizable.model.d.ts.map +1 -0
- package/dist/components/resizable.model.js +11 -0
- package/dist/components/resizable.parts.d.ts +20 -0
- package/dist/components/resizable.parts.d.ts.map +1 -0
- package/dist/components/resizable.parts.js +36 -0
- package/dist/components/resizable.variants.d.ts +16 -0
- package/dist/components/resizable.variants.d.ts.map +1 -0
- package/dist/components/resizable.variants.js +41 -0
- package/dist/components/row.variants.d.ts +10 -0
- package/dist/components/row.variants.d.ts.map +1 -0
- package/dist/components/row.variants.js +36 -0
- package/dist/components/secret-input.d.ts +20 -0
- package/dist/components/secret-input.d.ts.map +1 -0
- package/dist/components/secret-input.js +94 -0
- package/dist/components/section-index.d.ts +23 -0
- package/dist/components/section-index.d.ts.map +1 -0
- package/dist/components/section-index.js +51 -0
- package/dist/components/section.d.ts +19 -0
- package/dist/components/section.d.ts.map +1 -0
- package/dist/components/section.js +42 -0
- package/dist/components/select.d.ts +28 -0
- package/dist/components/select.d.ts.map +1 -0
- package/dist/components/select.js +120 -0
- package/dist/components/select.keys.d.ts +6 -0
- package/dist/components/select.keys.d.ts.map +1 -0
- package/dist/components/select.keys.js +20 -0
- package/dist/components/select.list.d.ts +26 -0
- package/dist/components/select.list.d.ts.map +1 -0
- package/dist/components/select.list.js +50 -0
- package/dist/components/select.parts.d.ts +53 -0
- package/dist/components/select.parts.d.ts.map +1 -0
- package/dist/components/select.parts.js +95 -0
- package/dist/components/select.variants.d.ts +13 -0
- package/dist/components/select.variants.d.ts.map +1 -0
- package/dist/components/select.variants.js +54 -0
- package/dist/components/sheet.d.ts +27 -0
- package/dist/components/sheet.d.ts.map +1 -0
- package/dist/components/sheet.docked.d.ts +8 -0
- package/dist/components/sheet.docked.d.ts.map +1 -0
- package/dist/components/sheet.docked.js +106 -0
- package/dist/components/sheet.js +61 -0
- package/dist/components/sheet.narrow.d.ts +3 -0
- package/dist/components/sheet.narrow.d.ts.map +1 -0
- package/dist/components/sheet.narrow.js +9 -0
- package/dist/components/sidebar.d.ts +14 -0
- package/dist/components/sidebar.d.ts.map +1 -0
- package/dist/components/sidebar.js +48 -0
- package/dist/components/skeleton.d.ts +10 -0
- package/dist/components/skeleton.d.ts.map +1 -0
- package/dist/components/skeleton.js +21 -0
- package/dist/components/sparkline.d.ts +26 -0
- package/dist/components/sparkline.d.ts.map +1 -0
- package/dist/components/sparkline.js +83 -0
- package/dist/components/spinner.d.ts +10 -0
- package/dist/components/spinner.d.ts.map +1 -0
- package/dist/components/spinner.js +38 -0
- package/dist/components/stat-card.d.ts +9 -0
- package/dist/components/stat-card.d.ts.map +1 -0
- package/dist/components/stat-card.header.d.ts +19 -0
- package/dist/components/stat-card.header.d.ts.map +1 -0
- package/dist/components/stat-card.header.js +43 -0
- package/dist/components/stat-card.js +84 -0
- package/dist/components/stat-card.parts.d.ts +10 -0
- package/dist/components/stat-card.parts.d.ts.map +1 -0
- package/dist/components/stat-card.parts.js +35 -0
- package/dist/components/stat-card.state.d.ts +9 -0
- package/dist/components/stat-card.state.d.ts.map +1 -0
- package/dist/components/stat-card.state.js +51 -0
- package/dist/components/stat-card.types.d.ts +28 -0
- package/dist/components/stat-card.types.d.ts.map +1 -0
- package/dist/components/stat-card.types.js +0 -0
- package/dist/components/status-bar.d.ts +32 -0
- package/dist/components/status-bar.d.ts.map +1 -0
- package/dist/components/status-bar.js +114 -0
- package/dist/components/status-bar.variants.d.ts +12 -0
- package/dist/components/status-bar.variants.d.ts.map +1 -0
- package/dist/components/status-bar.variants.js +63 -0
- package/dist/components/status-glyph.d.ts +15 -0
- package/dist/components/status-glyph.d.ts.map +1 -0
- package/dist/components/status-glyph.js +118 -0
- package/dist/components/status-glyph.status.d.ts +11 -0
- package/dist/components/status-glyph.status.d.ts.map +1 -0
- package/dist/components/status-glyph.status.js +33 -0
- package/dist/components/step-list.d.ts +28 -0
- package/dist/components/step-list.d.ts.map +1 -0
- package/dist/components/step-list.js +70 -0
- package/dist/components/step-list.parts.d.ts +34 -0
- package/dist/components/step-list.parts.d.ts.map +1 -0
- package/dist/components/step-list.parts.js +74 -0
- package/dist/components/switch.d.ts +22 -0
- package/dist/components/switch.d.ts.map +1 -0
- package/dist/components/switch.js +93 -0
- package/dist/components/table.d.ts +19 -0
- package/dist/components/table.d.ts.map +1 -0
- package/dist/components/table.js +73 -0
- package/dist/components/tabs.context.d.ts +19 -0
- package/dist/components/tabs.context.d.ts.map +1 -0
- package/dist/components/tabs.context.js +15 -0
- package/dist/components/tabs.d.ts +23 -0
- package/dist/components/tabs.d.ts.map +1 -0
- package/dist/components/tabs.js +61 -0
- package/dist/components/tabs.trigger.d.ts +12 -0
- package/dist/components/tabs.trigger.d.ts.map +1 -0
- package/dist/components/tabs.trigger.js +69 -0
- package/dist/components/tabs.variants.d.ts +10 -0
- package/dist/components/tabs.variants.d.ts.map +1 -0
- package/dist/components/tabs.variants.js +33 -0
- package/dist/components/toast.d.ts +21 -0
- package/dist/components/toast.d.ts.map +1 -0
- package/dist/components/toast.js +125 -0
- package/dist/components/toggle-group.d.ts +36 -0
- package/dist/components/toggle-group.d.ts.map +1 -0
- package/dist/components/toggle-group.js +68 -0
- package/dist/components/toggle-group.variants.d.ts +13 -0
- package/dist/components/toggle-group.variants.d.ts.map +1 -0
- package/dist/components/toggle-group.variants.js +71 -0
- package/dist/components/tooltip.d.ts +10 -0
- package/dist/components/tooltip.d.ts.map +1 -0
- package/dist/components/tooltip.js +49 -0
- package/dist/components/tree-select.d.ts +26 -0
- package/dist/components/tree-select.d.ts.map +1 -0
- package/dist/components/tree-select.js +102 -0
- package/dist/components/tree-select.model.d.ts +30 -0
- package/dist/components/tree-select.model.d.ts.map +1 -0
- package/dist/components/tree-select.model.js +33 -0
- package/dist/components/tree-select.rows.d.ts +18 -0
- package/dist/components/tree-select.rows.d.ts.map +1 -0
- package/dist/components/tree-select.rows.js +39 -0
- package/dist/components/truncate.d.ts +9 -0
- package/dist/components/truncate.d.ts.map +1 -0
- package/dist/components/truncate.js +31 -0
- package/dist/components/use-split-state.d.ts +17 -0
- package/dist/components/use-split-state.d.ts.map +1 -0
- package/dist/components/use-split-state.js +51 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +96 -0
- package/dist/lib/aria.d.ts +4 -0
- package/dist/lib/aria.d.ts.map +1 -0
- package/dist/lib/aria.js +4 -0
- package/dist/lib/copy-text.d.ts +3 -0
- package/dist/lib/copy-text.d.ts.map +1 -0
- package/dist/lib/copy-text.js +20 -0
- package/dist/lib/cron.d.ts +13 -0
- package/dist/lib/cron.d.ts.map +1 -0
- package/dist/lib/cron.js +131 -0
- package/dist/lib/cron.next.d.ts +9 -0
- package/dist/lib/cron.next.d.ts.map +1 -0
- package/dist/lib/cron.next.js +49 -0
- package/dist/lib/cron.text.d.ts +3 -0
- package/dist/lib/cron.text.d.ts.map +1 -0
- package/dist/lib/cron.text.js +61 -0
- package/dist/lib/drag-reorder.d.ts +33 -0
- package/dist/lib/drag-reorder.d.ts.map +1 -0
- package/dist/lib/drag-reorder.js +61 -0
- package/dist/lib/index.d.ts +2 -0
- package/dist/lib/index.d.ts.map +1 -0
- package/dist/lib/index.js +1 -0
- package/dist/lib/list-controls-storage.d.ts +7 -0
- package/dist/lib/list-controls-storage.d.ts.map +1 -0
- package/dist/lib/list-controls-storage.js +25 -0
- package/dist/lib/list-controls.d.ts +49 -0
- package/dist/lib/list-controls.d.ts.map +1 -0
- package/dist/lib/list-controls.js +44 -0
- package/dist/lib/list-navigation.d.ts +3 -0
- package/dist/lib/list-navigation.d.ts.map +1 -0
- package/dist/lib/list-navigation.js +7 -0
- package/dist/lib/overlay-layer.d.ts +32 -0
- package/dist/lib/overlay-layer.d.ts.map +1 -0
- package/dist/lib/overlay-layer.js +37 -0
- package/dist/lib/panel-sizes.d.ts +18 -0
- package/dist/lib/panel-sizes.d.ts.map +1 -0
- package/dist/lib/panel-sizes.js +25 -0
- package/dist/lib/relative-range.d.ts +23 -0
- package/dist/lib/relative-range.d.ts.map +1 -0
- package/dist/lib/relative-range.js +130 -0
- package/dist/lib/relative-time-format.d.ts +6 -0
- package/dist/lib/relative-time-format.d.ts.map +1 -0
- package/dist/lib/relative-time-format.js +21 -0
- package/dist/lib/split-px.d.ts +23 -0
- package/dist/lib/split-px.d.ts.map +1 -0
- package/dist/lib/split-px.js +30 -0
- package/dist/lib/table-sort.d.ts +11 -0
- package/dist/lib/table-sort.d.ts.map +1 -0
- package/dist/lib/table-sort.js +17 -0
- package/dist/lib/usage-level.d.ts +13 -0
- package/dist/lib/usage-level.d.ts.map +1 -0
- package/dist/lib/usage-level.js +12 -0
- package/dist/lib/use-anchor-position.d.ts +22 -0
- package/dist/lib/use-anchor-position.d.ts.map +1 -0
- package/dist/lib/use-anchor-position.js +41 -0
- package/dist/lib/use-announce.d.ts +6 -0
- package/dist/lib/use-announce.d.ts.map +1 -0
- package/dist/lib/use-announce.js +20 -0
- package/dist/lib/use-cell-stack.d.ts +8 -0
- package/dist/lib/use-cell-stack.d.ts.map +1 -0
- package/dist/lib/use-cell-stack.js +23 -0
- package/dist/lib/use-controlled.d.ts +8 -0
- package/dist/lib/use-controlled.d.ts.map +1 -0
- package/dist/lib/use-controlled.js +22 -0
- package/dist/lib/use-drag-reorder.d.ts +28 -0
- package/dist/lib/use-drag-reorder.d.ts.map +1 -0
- package/dist/lib/use-drag-reorder.js +100 -0
- package/dist/lib/use-flip.d.ts +8 -0
- package/dist/lib/use-flip.d.ts.map +1 -0
- package/dist/lib/use-flip.js +28 -0
- package/dist/lib/use-focus-origin.d.ts +9 -0
- package/dist/lib/use-focus-origin.d.ts.map +1 -0
- package/dist/lib/use-focus-origin.js +15 -0
- package/dist/lib/use-focus-restore.d.ts +7 -0
- package/dist/lib/use-focus-restore.d.ts.map +1 -0
- package/dist/lib/use-focus-restore.js +15 -0
- package/dist/lib/use-focus-trap.d.ts +5 -0
- package/dist/lib/use-focus-trap.d.ts.map +1 -0
- package/dist/lib/use-focus-trap.js +32 -0
- package/dist/lib/use-keep-focus.d.ts +4 -0
- package/dist/lib/use-keep-focus.d.ts.map +1 -0
- package/dist/lib/use-keep-focus.js +20 -0
- package/dist/lib/use-list-controls.d.ts +28 -0
- package/dist/lib/use-list-controls.d.ts.map +1 -0
- package/dist/lib/use-list-controls.js +72 -0
- package/dist/lib/use-mounted.d.ts +3 -0
- package/dist/lib/use-mounted.d.ts.map +1 -0
- package/dist/lib/use-mounted.js +8 -0
- package/dist/lib/use-persisted-state.d.ts +21 -0
- package/dist/lib/use-persisted-state.d.ts.map +1 -0
- package/dist/lib/use-persisted-state.js +52 -0
- package/dist/lib/use-roving-focus.d.ts +14 -0
- package/dist/lib/use-roving-focus.d.ts.map +1 -0
- package/dist/lib/use-roving-focus.js +36 -0
- package/dist/lib/use-scroll-lock.d.ts +6 -0
- package/dist/lib/use-scroll-lock.d.ts.map +1 -0
- package/dist/lib/use-scroll-lock.js +23 -0
- package/dist/lib/use-scroll-spy.d.ts +12 -0
- package/dist/lib/use-scroll-spy.d.ts.map +1 -0
- package/dist/lib/use-scroll-spy.js +34 -0
- package/dist/lib/utils.d.ts +12 -0
- package/dist/lib/utils.d.ts.map +1 -0
- package/dist/lib/utils.js +9 -0
- package/package.json +457 -4
- package/src/styles/base.css +98 -0
- package/src/styles/primitives.css +143 -0
- package/src/styles/theme.css +10 -0
- package/src/styles/tokens.css +344 -0
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { CardFallback, CardState } from './card-state.js';
|
|
2
|
+
import type * as React from 'react';
|
|
3
|
+
/** Whether a rise is good news: drives the trend colour; the arrow always shows the direction. */
|
|
4
|
+
export type StatCardSentiment = 'up-is-good' | 'down-is-good' | 'neutral';
|
|
5
|
+
export interface StatCardTrend {
|
|
6
|
+
/** The change as shown, for example `+12%`. */
|
|
7
|
+
value: string;
|
|
8
|
+
direction: 'up' | 'down';
|
|
9
|
+
/** `up-is-good` (default) draws a rise green; `down-is-good` draws it red; `neutral` muted. */
|
|
10
|
+
sentiment?: StatCardSentiment;
|
|
11
|
+
}
|
|
12
|
+
export interface StatCardProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'title'> {
|
|
13
|
+
title: string;
|
|
14
|
+
value: React.ReactNode;
|
|
15
|
+
/** Change chip at the end of the header. */
|
|
16
|
+
trend?: StatCardTrend;
|
|
17
|
+
/** The one muted line under the value: a description or the earlier figure. */
|
|
18
|
+
hint?: React.ReactNode;
|
|
19
|
+
/** Leading header glyph, for example a StatusGlyph or a 24 px icon tile. */
|
|
20
|
+
icon?: React.ReactNode;
|
|
21
|
+
/** `loading`, `empty` and `error` cover the body at its own height; `stale` badges the card. */
|
|
22
|
+
state?: CardState;
|
|
23
|
+
/** Bodies for those states: loading placeholder, empty line, error with Retry. */
|
|
24
|
+
fallback?: CardFallback;
|
|
25
|
+
/** A bottom row above a 1 px rule; put a `CardMeta` in it for source and last update. */
|
|
26
|
+
footer?: React.ReactNode;
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=stat-card.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stat-card.types.d.ts","sourceRoot":"","sources":["../../src/components/stat-card.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AACpC,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAE5D,kGAAkG;AAClG,MAAM,MAAM,iBAAiB,GAAG,YAAY,GAAG,cAAc,GAAG,SAAS,CAAC;AAE1E,MAAM,WAAW,aAAa;IAC5B,+CAA+C;IAC/C,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,IAAI,GAAG,MAAM,CAAC;IACzB,+FAA+F;IAC/F,SAAS,CAAC,EAAE,iBAAiB,CAAC;CAC/B;AAED,MAAM,WAAW,aAAc,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,OAAO,CAAC;IACxF,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,4CAA4C;IAC5C,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,+EAA+E;IAC/E,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,4EAA4E;IAC5E,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,gGAAgG;IAChG,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,kFAAkF;IAClF,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB,yFAAyF;IACzF,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC1B"}
|
|
File without changes
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export type StatusBarTone = 'success' | 'destructive' | 'warning' | 'info' | 'primary' | 'muted' | 'pending' | 'empty';
|
|
3
|
+
export interface StatusBarCell {
|
|
4
|
+
/** Stable key, for example the date; keeps focus and the tooltip on the same cell as new ones arrive. */
|
|
5
|
+
id?: string;
|
|
6
|
+
tone: StatusBarTone;
|
|
7
|
+
/** Accessible name of the tick, for example `Nov 3, 99.2 percent, degraded`. */
|
|
8
|
+
label: string;
|
|
9
|
+
/** Richer tooltip content; `label` by default. */
|
|
10
|
+
title?: React.ReactNode;
|
|
11
|
+
pulse?: boolean;
|
|
12
|
+
onClick?: () => void;
|
|
13
|
+
}
|
|
14
|
+
export interface StatusBarProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'title'> {
|
|
15
|
+
/** Oldest first: the newest cell sits on the right. */
|
|
16
|
+
cells: StatusBarCell[];
|
|
17
|
+
/** Accessible name of the bar, for example `Last 30 days of API`. */
|
|
18
|
+
label: string;
|
|
19
|
+
/** `md` 7 by 28 px ticks (default); `sm` 6 by 14 px, the compact strip for rows and cards. */
|
|
20
|
+
size?: 'sm' | 'md';
|
|
21
|
+
/** Total ticks; missing ones pad the left as no-data ticks. */
|
|
22
|
+
slots?: number;
|
|
23
|
+
/** Ticks stretch to fill the width. */
|
|
24
|
+
fill?: boolean;
|
|
25
|
+
/** Leading name, for example the service. */
|
|
26
|
+
name?: React.ReactNode;
|
|
27
|
+
/** Trailing summary, for example `99.98 percent`. */
|
|
28
|
+
summary?: React.ReactNode;
|
|
29
|
+
}
|
|
30
|
+
/** A row of status ticks, newest on the right; hover or focus a tick for its tooltip. */
|
|
31
|
+
export declare const StatusBar: React.ForwardRefExoticComponent<StatusBarProps & React.RefAttributes<HTMLDivElement>>;
|
|
32
|
+
//# sourceMappingURL=status-bar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status-bar.d.ts","sourceRoot":"","sources":["../../src/components/status-bar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAO/B,MAAM,MAAM,aAAa,GACvB,SAAS,GAAG,aAAa,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,CAAC;AAE7F,MAAM,WAAW,aAAa;IAC5B,yGAAyG;IACzG,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,aAAa,CAAC;IACpB,gFAAgF;IAChF,KAAK,EAAE,MAAM,CAAC;IACd,kDAAkD;IAClD,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,MAAM,WAAW,cAAe,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzF,uDAAuD;IACvD,KAAK,EAAE,aAAa,EAAE,CAAC;IACvB,qEAAqE;IACrE,KAAK,EAAE,MAAM,CAAC;IACd,8FAA8F;IAC9F,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,CAAC;IACnB,+DAA+D;IAC/D,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,uCAAuC;IACvC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,6CAA6C;IAC7C,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,qDAAqD;IACrD,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AA+BD,yFAAyF;AACzF,eAAO,MAAM,SAAS,uFAiFrB,CAAC"}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { useAnchorPosition as e } from "../lib/use-anchor-position.js";
|
|
3
|
+
import { useRovingFocus as t } from "../lib/use-roving-focus.js";
|
|
4
|
+
import { cn as n } from "../lib/utils.js";
|
|
5
|
+
import { statusBarTickVariants as r, statusBarTrackVariants as i } from "./status-bar.variants.js";
|
|
6
|
+
import * as a from "react";
|
|
7
|
+
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
8
|
+
import { createPortal as c } from "react-dom";
|
|
9
|
+
// src/components/status-bar.tsx
|
|
10
|
+
var l = "pointer-events-none z-[var(--z-overlay,50)] max-w-xs rounded-md bg-foreground px-2 py-1 text-xs text-background shadow-[var(--shadow-popover)]", u = ({ anchor: t, id: n, children: r }) => {
|
|
11
|
+
let i = a.useRef(t), s = a.useRef(null), { top: u, left: d } = e(i, s, !0, { side: "top" });
|
|
12
|
+
return c(/* @__PURE__ */ o("div", {
|
|
13
|
+
ref: s,
|
|
14
|
+
id: n,
|
|
15
|
+
role: "tooltip",
|
|
16
|
+
style: {
|
|
17
|
+
position: "fixed",
|
|
18
|
+
top: u,
|
|
19
|
+
left: d
|
|
20
|
+
},
|
|
21
|
+
className: l,
|
|
22
|
+
children: r
|
|
23
|
+
}), document.body);
|
|
24
|
+
}, d = a.forwardRef(({ cells: e, label: c, size: l = "md", slots: d, fill: f = !1, name: p, summary: m, className: h, ...g }, _) => {
|
|
25
|
+
let v = a.useRef(null), [y, b] = a.useState(null), x = `${a.useId()}-tip`;
|
|
26
|
+
t(v, {
|
|
27
|
+
selector: "[data-tick]",
|
|
28
|
+
orientation: "horizontal",
|
|
29
|
+
loop: !1
|
|
30
|
+
});
|
|
31
|
+
let S = d === void 0 ? e : e.slice(Math.max(0, e.length - d)), C = Math.max(0, (d ?? 0) - S.length), w = (e, t) => e.id ?? `i${String(t)}`, T = y ? S.find((e, t) => w(e, t) === y.key) : void 0, E = () => b(null), D = (e) => ({
|
|
32
|
+
onPointerEnter: (t) => b({
|
|
33
|
+
key: e,
|
|
34
|
+
el: t.currentTarget
|
|
35
|
+
}),
|
|
36
|
+
onFocus: (t) => b({
|
|
37
|
+
key: e,
|
|
38
|
+
el: t.currentTarget
|
|
39
|
+
}),
|
|
40
|
+
onPointerLeave: E,
|
|
41
|
+
onBlur: E,
|
|
42
|
+
onKeyDown: (e) => e.key === "Escape" && E()
|
|
43
|
+
}), O = /* @__PURE__ */ s("div", {
|
|
44
|
+
ref: v,
|
|
45
|
+
role: "group",
|
|
46
|
+
"aria-label": c,
|
|
47
|
+
className: i({
|
|
48
|
+
size: l,
|
|
49
|
+
fill: f
|
|
50
|
+
}),
|
|
51
|
+
"data-slot": "status-bar-track",
|
|
52
|
+
children: [
|
|
53
|
+
Array.from({ length: C }, (e, t) => /* @__PURE__ */ o("span", {
|
|
54
|
+
"aria-hidden": "true",
|
|
55
|
+
className: r({
|
|
56
|
+
tone: "empty",
|
|
57
|
+
size: l,
|
|
58
|
+
fill: f
|
|
59
|
+
})
|
|
60
|
+
}, `pad-${String(t)}`)),
|
|
61
|
+
S.map((e, t) => {
|
|
62
|
+
let n = w(e, t), i = {
|
|
63
|
+
"data-tick": "",
|
|
64
|
+
"data-tone": e.tone,
|
|
65
|
+
"aria-label": e.label,
|
|
66
|
+
"aria-describedby": y?.key === n ? x : void 0,
|
|
67
|
+
...D(n)
|
|
68
|
+
}, a = r({
|
|
69
|
+
tone: e.tone,
|
|
70
|
+
size: l,
|
|
71
|
+
fill: f,
|
|
72
|
+
pulse: e.pulse,
|
|
73
|
+
interactive: !!e.onClick
|
|
74
|
+
});
|
|
75
|
+
return e.onClick ? /* @__PURE__ */ o("button", {
|
|
76
|
+
type: "button",
|
|
77
|
+
className: a,
|
|
78
|
+
onClick: e.onClick,
|
|
79
|
+
...i
|
|
80
|
+
}, n) : /* @__PURE__ */ o("span", {
|
|
81
|
+
role: "img",
|
|
82
|
+
tabIndex: -1,
|
|
83
|
+
className: a,
|
|
84
|
+
...i
|
|
85
|
+
}, n);
|
|
86
|
+
}),
|
|
87
|
+
y && T && /* @__PURE__ */ o(u, {
|
|
88
|
+
anchor: y.el,
|
|
89
|
+
id: x,
|
|
90
|
+
children: T.title ?? T.label
|
|
91
|
+
}, y.key)
|
|
92
|
+
]
|
|
93
|
+
});
|
|
94
|
+
return /* @__PURE__ */ s("div", {
|
|
95
|
+
ref: _,
|
|
96
|
+
className: n("flex min-w-0 items-center gap-3", f && "w-full", h),
|
|
97
|
+
"data-slot": "status-bar",
|
|
98
|
+
"data-size": l,
|
|
99
|
+
...g,
|
|
100
|
+
children: [
|
|
101
|
+
p !== void 0 && /* @__PURE__ */ o("span", {
|
|
102
|
+
className: "min-w-0 shrink-0 truncate text-ui",
|
|
103
|
+
children: p
|
|
104
|
+
}),
|
|
105
|
+
O,
|
|
106
|
+
m !== void 0 && /* @__PURE__ */ o("span", {
|
|
107
|
+
className: "ml-auto shrink-0 text-xs tabular-nums text-muted-foreground",
|
|
108
|
+
children: m
|
|
109
|
+
})
|
|
110
|
+
]
|
|
111
|
+
});
|
|
112
|
+
});
|
|
113
|
+
d.displayName = "StatusBar";
|
|
114
|
+
export { d as StatusBar };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare const statusBarTickVariants: (props?: ({
|
|
2
|
+
tone?: "muted" | "primary" | "success" | "warning" | "destructive" | "info" | "pending" | "empty" | null | undefined;
|
|
3
|
+
size?: "sm" | "md" | null | undefined;
|
|
4
|
+
fill?: boolean | null | undefined;
|
|
5
|
+
pulse?: boolean | null | undefined;
|
|
6
|
+
interactive?: boolean | null | undefined;
|
|
7
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
8
|
+
export declare const statusBarTrackVariants: (props?: ({
|
|
9
|
+
size?: "sm" | "md" | null | undefined;
|
|
10
|
+
fill?: boolean | null | undefined;
|
|
11
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
12
|
+
//# sourceMappingURL=status-bar.variants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status-bar.variants.d.ts","sourceRoot":"","sources":["../../src/components/status-bar.variants.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,qBAAqB;;;;;;8EAoCjC,CAAC;AAEF,eAAO,MAAM,sBAAsB;;;8EAMjC,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { cva as e } from "class-variance-authority";
|
|
2
|
+
var t = e("block shrink-0 self-end p-0 outline-offset-1 cursor-default", {
|
|
3
|
+
variants: {
|
|
4
|
+
tone: {
|
|
5
|
+
success: "h-full bg-success",
|
|
6
|
+
destructive: "h-full bg-destructive",
|
|
7
|
+
warning: "h-1/2 bg-warning",
|
|
8
|
+
info: "h-full bg-info",
|
|
9
|
+
primary: "h-full bg-primary",
|
|
10
|
+
muted: "h-1/4 bg-muted-foreground/45",
|
|
11
|
+
pending: "h-full border-[1.5px] border-muted-foreground bg-transparent",
|
|
12
|
+
empty: "h-full border border-border bg-transparent"
|
|
13
|
+
},
|
|
14
|
+
size: {
|
|
15
|
+
sm: "w-1.5 rounded-[2px]",
|
|
16
|
+
md: "w-[7px] rounded-[2px]"
|
|
17
|
+
},
|
|
18
|
+
fill: {
|
|
19
|
+
true: "w-auto min-w-[3px] flex-1",
|
|
20
|
+
false: ""
|
|
21
|
+
},
|
|
22
|
+
pulse: {
|
|
23
|
+
true: "motion-safe:animate-breathe",
|
|
24
|
+
false: ""
|
|
25
|
+
},
|
|
26
|
+
interactive: {
|
|
27
|
+
true: "cursor-pointer transition-opacity duration-fast hover:opacity-75 focus-ring motion-reduce:transition-none",
|
|
28
|
+
false: "focus-ring"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
compoundVariants: [{
|
|
32
|
+
tone: "destructive",
|
|
33
|
+
size: "sm",
|
|
34
|
+
class: "[mask-image:linear-gradient(to_bottom,#000_0_3px,transparent_3px_6px,#000_6px)]"
|
|
35
|
+
}, {
|
|
36
|
+
tone: "destructive",
|
|
37
|
+
size: "md",
|
|
38
|
+
class: "[mask-image:linear-gradient(to_bottom,#000_0_6px,transparent_6px_10px,#000_10px)]"
|
|
39
|
+
}],
|
|
40
|
+
defaultVariants: {
|
|
41
|
+
tone: "muted",
|
|
42
|
+
size: "md",
|
|
43
|
+
fill: !1,
|
|
44
|
+
pulse: !1,
|
|
45
|
+
interactive: !1
|
|
46
|
+
}
|
|
47
|
+
}), n = e("flex min-w-0 items-end", {
|
|
48
|
+
variants: {
|
|
49
|
+
size: {
|
|
50
|
+
sm: "h-3.5 gap-0.5",
|
|
51
|
+
md: "h-7 gap-px"
|
|
52
|
+
},
|
|
53
|
+
fill: {
|
|
54
|
+
true: "flex-1",
|
|
55
|
+
false: "shrink-0"
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
defaultVariants: {
|
|
59
|
+
size: "md",
|
|
60
|
+
fill: !1
|
|
61
|
+
}
|
|
62
|
+
});
|
|
63
|
+
export { t as statusBarTickVariants, n as statusBarTrackVariants };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export type StatusGlyphShape = 'dot' | 'ring' | 'dashed' | 'disc' | 'half' | 'three-quarters' | 'check' | 'cross' | 'question' | 'alert' | 'slash' | 'clock';
|
|
4
|
+
export declare const statusGlyphVariants: (props?: ({
|
|
5
|
+
tone?: "muted" | "primary" | "success" | "warning" | "destructive" | "info" | null | undefined;
|
|
6
|
+
size?: "sm" | "md" | null | undefined;
|
|
7
|
+
pulse?: boolean | null | undefined;
|
|
8
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
9
|
+
export interface StatusGlyphProps extends Omit<React.SVGAttributes<SVGSVGElement>, 'children'>, VariantProps<typeof statusGlyphVariants> {
|
|
10
|
+
shape: StatusGlyphShape;
|
|
11
|
+
/** Accessible name. Without it the glyph is decorative and hidden from assistive tech. */
|
|
12
|
+
label?: string;
|
|
13
|
+
}
|
|
14
|
+
export declare const StatusGlyph: React.ForwardRefExoticComponent<StatusGlyphProps & React.RefAttributes<SVGSVGElement>>;
|
|
15
|
+
//# sourceMappingURL=status-glyph.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status-glyph.d.ts","sourceRoot":"","sources":["../../src/components/status-glyph.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAGlE,MAAM,MAAM,gBAAgB,GACxB,KAAK,GACL,MAAM,GACN,QAAQ,GACR,MAAM,GACN,MAAM,GACN,gBAAgB,GAChB,OAAO,GACP,OAAO,GACP,UAAU,GACV,OAAO,GACP,OAAO,GACP,OAAO,CAAC;AAEZ,eAAO,MAAM,mBAAmB;;;;8EAoB9B,CAAC;AAkFH,MAAM,WAAW,gBACf,SACE,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,aAAa,CAAC,EAAE,UAAU,CAAC,EACpD,YAAY,CAAC,OAAO,mBAAmB,CAAC;IAC1C,KAAK,EAAE,gBAAgB,CAAC;IACxB,0FAA0F;IAC1F,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,WAAW,wFAiBvB,CAAC"}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import { cn as e } from "../lib/utils.js";
|
|
2
|
+
import * as t from "react";
|
|
3
|
+
import { cva as n } from "class-variance-authority";
|
|
4
|
+
import { Fragment as r, jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
5
|
+
// src/components/status-glyph.tsx
|
|
6
|
+
var o = n("inline-block shrink-0", {
|
|
7
|
+
variants: {
|
|
8
|
+
tone: {
|
|
9
|
+
muted: "text-muted-foreground",
|
|
10
|
+
primary: "text-primary",
|
|
11
|
+
success: "text-success",
|
|
12
|
+
destructive: "text-destructive",
|
|
13
|
+
warning: "text-warning",
|
|
14
|
+
info: "text-info"
|
|
15
|
+
},
|
|
16
|
+
size: {
|
|
17
|
+
sm: "size-3.5",
|
|
18
|
+
md: "size-4"
|
|
19
|
+
},
|
|
20
|
+
pulse: {
|
|
21
|
+
true: "motion-safe:animate-breathe",
|
|
22
|
+
false: ""
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
defaultVariants: {
|
|
26
|
+
tone: "muted",
|
|
27
|
+
size: "sm",
|
|
28
|
+
pulse: !1
|
|
29
|
+
}
|
|
30
|
+
}), s = {
|
|
31
|
+
fill: "none",
|
|
32
|
+
strokeWidth: 1.6,
|
|
33
|
+
strokeLinecap: "round",
|
|
34
|
+
strokeLinejoin: "round",
|
|
35
|
+
className: "stroke-background"
|
|
36
|
+
}, c = ({ dashed: e }) => /* @__PURE__ */ i("circle", {
|
|
37
|
+
cx: "7",
|
|
38
|
+
cy: "7",
|
|
39
|
+
r: "5.25",
|
|
40
|
+
fill: "none",
|
|
41
|
+
stroke: "currentColor",
|
|
42
|
+
strokeWidth: "1.5",
|
|
43
|
+
strokeDasharray: e ? "2.1 1.9" : void 0
|
|
44
|
+
}), l = () => /* @__PURE__ */ i("circle", {
|
|
45
|
+
cx: "7",
|
|
46
|
+
cy: "7",
|
|
47
|
+
r: "6.25",
|
|
48
|
+
fill: "currentColor"
|
|
49
|
+
}), u = {
|
|
50
|
+
...s,
|
|
51
|
+
className: void 0,
|
|
52
|
+
stroke: "currentColor"
|
|
53
|
+
}, d = {
|
|
54
|
+
dot: /* @__PURE__ */ i("circle", {
|
|
55
|
+
cx: "7",
|
|
56
|
+
cy: "7",
|
|
57
|
+
r: "3",
|
|
58
|
+
fill: "currentColor"
|
|
59
|
+
}),
|
|
60
|
+
ring: /* @__PURE__ */ i(c, {}),
|
|
61
|
+
dashed: /* @__PURE__ */ i(c, { dashed: !0 }),
|
|
62
|
+
disc: /* @__PURE__ */ i("circle", {
|
|
63
|
+
cx: "7",
|
|
64
|
+
cy: "7",
|
|
65
|
+
r: "5.25",
|
|
66
|
+
fill: "currentColor"
|
|
67
|
+
}),
|
|
68
|
+
half: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(c, {}), /* @__PURE__ */ i("path", {
|
|
69
|
+
d: "M7 3.5a3.5 3.5 0 0 1 0 7z",
|
|
70
|
+
fill: "currentColor"
|
|
71
|
+
})] }),
|
|
72
|
+
"three-quarters": /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(c, {}), /* @__PURE__ */ i("path", {
|
|
73
|
+
d: "M7 7V3.5a3.5 3.5 0 1 1-3.5 3.5z",
|
|
74
|
+
fill: "currentColor"
|
|
75
|
+
})] }),
|
|
76
|
+
check: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(l, {}), /* @__PURE__ */ i("path", {
|
|
77
|
+
d: "M4.3 7.2l1.9 1.9 3.6-4",
|
|
78
|
+
...s
|
|
79
|
+
})] }),
|
|
80
|
+
cross: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(l, {}), /* @__PURE__ */ i("path", {
|
|
81
|
+
d: "M4.8 4.8l4.4 4.4M9.2 4.8l-4.4 4.4",
|
|
82
|
+
...s
|
|
83
|
+
})] }),
|
|
84
|
+
question: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(l, {}), /* @__PURE__ */ i("path", {
|
|
85
|
+
d: "M5.2 5.4a1.85 1.85 0 1 1 2.6 1.7c-.55.3-.8.65-.8 1.2M7 10.2v.05",
|
|
86
|
+
...s
|
|
87
|
+
})] }),
|
|
88
|
+
alert: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(l, {}), /* @__PURE__ */ i("path", {
|
|
89
|
+
d: "M7 3.8v4M7 10.1v.05",
|
|
90
|
+
...s
|
|
91
|
+
})] }),
|
|
92
|
+
slash: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(c, {}), /* @__PURE__ */ i("path", {
|
|
93
|
+
d: "M3.9 10.1l6.2-6.2",
|
|
94
|
+
...u
|
|
95
|
+
})] }),
|
|
96
|
+
clock: /* @__PURE__ */ a(r, { children: [/* @__PURE__ */ i(c, {}), /* @__PURE__ */ i("path", {
|
|
97
|
+
d: "M7 4.3V7l1.9 1.3",
|
|
98
|
+
...u
|
|
99
|
+
})] })
|
|
100
|
+
}, f = t.forwardRef(({ shape: t, tone: n, size: r, pulse: a, label: s, className: c, ...l }, u) => /* @__PURE__ */ i("svg", {
|
|
101
|
+
ref: u,
|
|
102
|
+
viewBox: "0 0 14 14",
|
|
103
|
+
className: e(o({
|
|
104
|
+
tone: n,
|
|
105
|
+
size: r,
|
|
106
|
+
pulse: a
|
|
107
|
+
}), c),
|
|
108
|
+
"data-slot": "status-glyph",
|
|
109
|
+
"data-shape": t,
|
|
110
|
+
role: s ? "img" : void 0,
|
|
111
|
+
"aria-label": s,
|
|
112
|
+
"aria-hidden": !s || void 0,
|
|
113
|
+
focusable: "false",
|
|
114
|
+
...l,
|
|
115
|
+
children: d[t]
|
|
116
|
+
}));
|
|
117
|
+
f.displayName = "StatusGlyph";
|
|
118
|
+
export { f as StatusGlyph, o as statusGlyphVariants };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { StatusGlyphProps } from './status-glyph.js';
|
|
2
|
+
/** One status vocabulary for status rows (CheckList, StepList). */
|
|
3
|
+
export type RowStatus = 'ok' | 'error' | 'running' | 'pending' | 'skipped';
|
|
4
|
+
/** Accepted spellings from older parts: `fail` / `failed` = error, `done` = ok, `active` = running. */
|
|
5
|
+
export type RowStatusAlias = 'fail' | 'failed' | 'done' | 'active';
|
|
6
|
+
export declare const normalizeRowStatus: (status: RowStatus | RowStatusAlias) => RowStatus;
|
|
7
|
+
/** The glyph of each status: shape and colour both carry it. */
|
|
8
|
+
export declare const ROW_STATUS_GLYPH: Record<RowStatus, Pick<StatusGlyphProps, 'shape' | 'tone' | 'pulse'>>;
|
|
9
|
+
/** "6 of 6 passed", with failed, running and skipped counts when there are any. */
|
|
10
|
+
export declare const checkSummary: (statuses: (RowStatus | RowStatusAlias)[]) => string;
|
|
11
|
+
//# sourceMappingURL=status-glyph.status.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status-glyph.status.d.ts","sourceRoot":"","sources":["../../src/components/status-glyph.status.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvD,mEAAmE;AACnE,MAAM,MAAM,SAAS,GAAG,IAAI,GAAG,OAAO,GAAG,SAAS,GAAG,SAAS,GAAG,SAAS,CAAC;AAE3E,uGAAuG;AACvG,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,QAAQ,CAAC;AASnE,eAAO,MAAM,kBAAkB,GAAI,QAAQ,SAAS,GAAG,cAAc,KAAG,SACG,CAAC;AAE5E,gEAAgE;AAChE,eAAO,MAAM,gBAAgB,EAAE,MAAM,CACnC,SAAS,EACT,IAAI,CAAC,gBAAgB,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAOnD,CAAC;AAEF,mFAAmF;AACnF,eAAO,MAAM,YAAY,GAAI,UAAU,CAAC,SAAS,GAAG,cAAc,CAAC,EAAE,KAAG,MASvE,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
// src/components/status-glyph.status.ts
|
|
2
|
+
var e = {
|
|
3
|
+
fail: "error",
|
|
4
|
+
failed: "error",
|
|
5
|
+
done: "ok",
|
|
6
|
+
active: "running"
|
|
7
|
+
}, t = (t) => t in e ? e[t] : t, n = {
|
|
8
|
+
ok: {
|
|
9
|
+
shape: "check",
|
|
10
|
+
tone: "success"
|
|
11
|
+
},
|
|
12
|
+
error: {
|
|
13
|
+
shape: "cross",
|
|
14
|
+
tone: "destructive"
|
|
15
|
+
},
|
|
16
|
+
running: {
|
|
17
|
+
shape: "disc",
|
|
18
|
+
tone: "primary",
|
|
19
|
+
pulse: !0
|
|
20
|
+
},
|
|
21
|
+
pending: {
|
|
22
|
+
shape: "ring",
|
|
23
|
+
tone: "muted"
|
|
24
|
+
},
|
|
25
|
+
skipped: {
|
|
26
|
+
shape: "dashed",
|
|
27
|
+
tone: "muted"
|
|
28
|
+
}
|
|
29
|
+
}, r = (e) => {
|
|
30
|
+
let n = e.map(t), r = (e) => n.filter((t) => t === e).length, i = n.length - r("skipped"), a = [`${String(r("ok"))} of ${String(i)} passed`];
|
|
31
|
+
return r("error") && a.push(`${String(r("error"))} failed`), r("running") && a.push(`${String(r("running"))} running`), r("skipped") && a.push(`${String(r("skipped"))} skipped`), a.join(", ");
|
|
32
|
+
};
|
|
33
|
+
export { n as ROW_STATUS_GLYPH, r as checkSummary, t as normalizeRowStatus };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { StepStatus } from './step-list.parts.js';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export type { StepStatus } from './step-list.parts.js';
|
|
4
|
+
export interface StepListProps extends React.HTMLAttributes<HTMLOListElement> {
|
|
5
|
+
/** `md` 36 px rows at 13 px (default), `sm` 28 px sub-step rows at 12 px. */
|
|
6
|
+
size?: 'sm' | 'md';
|
|
7
|
+
/** A status glyph per step, joined by a connector line; the step icon moves next to the label. */
|
|
8
|
+
glyphs?: boolean;
|
|
9
|
+
/** Last row, for example the total duration. */
|
|
10
|
+
footer?: React.ReactNode;
|
|
11
|
+
}
|
|
12
|
+
/** Compact step timeline: a bordered `ol` of `Step` rows; Up and Down move between steps. */
|
|
13
|
+
export declare const StepList: React.ForwardRefExoticComponent<StepListProps & React.RefAttributes<HTMLOListElement>>;
|
|
14
|
+
export interface StepProps extends Omit<React.HTMLAttributes<HTMLLIElement>, 'title'> {
|
|
15
|
+
label: React.ReactNode;
|
|
16
|
+
/** Time since the start, shown first in mono, for example `+0:12`. */
|
|
17
|
+
offset?: React.ReactNode;
|
|
18
|
+
icon?: React.ReactNode;
|
|
19
|
+
duration?: React.ReactNode;
|
|
20
|
+
/** Monospace label, for tool and command names. */
|
|
21
|
+
mono?: boolean;
|
|
22
|
+
/** `error` marks the edge, colours the row and adds `errorLabel` as text. */
|
|
23
|
+
status?: StepStatus;
|
|
24
|
+
errorLabel?: string;
|
|
25
|
+
defaultOpen?: boolean;
|
|
26
|
+
}
|
|
27
|
+
export declare const Step: React.ForwardRefExoticComponent<StepProps & React.RefAttributes<HTMLLIElement>>;
|
|
28
|
+
//# sourceMappingURL=step-list.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"step-list.d.ts","sourceRoot":"","sources":["../../src/components/step-list.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAOL,KAAK,UAAU,EAChB,MAAM,mBAAmB,CAAC;AAG3B,YAAY,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEpD,MAAM,WAAW,aAAc,SAAQ,KAAK,CAAC,cAAc,CAAC,gBAAgB,CAAC;IAC3E,6EAA6E;IAC7E,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,CAAC;IACnB,kGAAkG;IAClG,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,gDAAgD;IAChD,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC1B;AAID,6FAA6F;AAC7F,eAAO,MAAM,QAAQ,wFAiCpB,CAAC;AAGF,MAAM,WAAW,SAAU,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,aAAa,CAAC,EAAE,OAAO,CAAC;IACnF,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,sEAAsE;IACtE,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACzB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,mDAAmD;IACnD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,6EAA6E;IAC7E,MAAM,CAAC,EAAE,UAAU,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,eAAO,MAAM,IAAI,iFAqEhB,CAAC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { useRovingFocus as e } from "../lib/use-roving-focus.js";
|
|
3
|
+
import { MUTED_ON_HOVER as t, cn as n } from "../lib/utils.js";
|
|
4
|
+
import { CONNECTOR as r, HEAD as i, HEAD_SIZE as a, StepDetail as o, StepHead as s, StepListContext as c } from "./step-list.parts.js";
|
|
5
|
+
import { normalizeRowStatus as l } from "./status-glyph.status.js";
|
|
6
|
+
import * as u from "react";
|
|
7
|
+
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
8
|
+
// src/components/step-list.tsx
|
|
9
|
+
var p = "[data-slot=\"step-head\"]", m = u.forwardRef(({ size: t = "md", glyphs: r = !1, footer: i, className: a, children: o, ...s }, l) => {
|
|
10
|
+
let m = u.useRef(null);
|
|
11
|
+
return u.useImperativeHandle(l, () => m.current), e(m, {
|
|
12
|
+
selector: p,
|
|
13
|
+
loop: !1
|
|
14
|
+
}), /* @__PURE__ */ d(c.Provider, {
|
|
15
|
+
value: {
|
|
16
|
+
size: t,
|
|
17
|
+
glyphs: r
|
|
18
|
+
},
|
|
19
|
+
children: /* @__PURE__ */ f("ol", {
|
|
20
|
+
ref: m,
|
|
21
|
+
className: n("group/steps m-0 flex list-none flex-col divide-y divide-border rounded-lg border border-border p-0", a),
|
|
22
|
+
"data-slot": "step-list",
|
|
23
|
+
"data-glyphs": r || void 0,
|
|
24
|
+
...s,
|
|
25
|
+
children: [o, i && /* @__PURE__ */ d("li", {
|
|
26
|
+
className: n("flex h-8 items-center justify-between gap-2 px-2.5 text-muted-foreground", t === "md" ? "text-ui" : "text-xs"),
|
|
27
|
+
"data-slot": "step-list-footer",
|
|
28
|
+
children: i
|
|
29
|
+
})]
|
|
30
|
+
})
|
|
31
|
+
});
|
|
32
|
+
});
|
|
33
|
+
m.displayName = "StepList";
|
|
34
|
+
var h = u.forwardRef(({ label: e, offset: p, icon: m, duration: h, mono: g = !0, status: _ = "ok", errorLabel: v = "error", defaultOpen: y = !1, className: b, children: x, ...S }, C) => {
|
|
35
|
+
let { size: w } = u.useContext(c), [T, E] = u.useState(y), D = u.useId(), O = l(_), k = O === "error", A = {
|
|
36
|
+
offset: p,
|
|
37
|
+
icon: m,
|
|
38
|
+
label: e,
|
|
39
|
+
duration: h,
|
|
40
|
+
mono: g,
|
|
41
|
+
status: O,
|
|
42
|
+
errorLabel: v
|
|
43
|
+
}, j = x != null && x !== !1;
|
|
44
|
+
return /* @__PURE__ */ f("li", {
|
|
45
|
+
ref: C,
|
|
46
|
+
className: n(r, k && "[background:linear-gradient(var(--color-destructive),var(--color-destructive))_left/2px_100%_no-repeat]", w === "md" && "group-data-[glyphs]/steps:after:top-[25px]", w === "md" && "group-data-[glyphs]/steps:before:h-[11px]", b),
|
|
47
|
+
"data-slot": "step",
|
|
48
|
+
"data-status": O,
|
|
49
|
+
...S,
|
|
50
|
+
children: [j ? /* @__PURE__ */ d("button", {
|
|
51
|
+
type: "button",
|
|
52
|
+
className: n(i, a[w], "transition-colors hover:bg-accent focus-ring", t),
|
|
53
|
+
"aria-expanded": T,
|
|
54
|
+
"aria-controls": D,
|
|
55
|
+
onClick: () => E(!T),
|
|
56
|
+
"data-slot": "step-head",
|
|
57
|
+
children: /* @__PURE__ */ d(s, { ...A })
|
|
58
|
+
}) : /* @__PURE__ */ d("div", {
|
|
59
|
+
className: n(i, a[w]),
|
|
60
|
+
children: /* @__PURE__ */ d(s, { ...A })
|
|
61
|
+
}), j && /* @__PURE__ */ d(o, {
|
|
62
|
+
id: D,
|
|
63
|
+
open: T,
|
|
64
|
+
error: k,
|
|
65
|
+
children: x
|
|
66
|
+
})]
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
h.displayName = "Step";
|
|
70
|
+
export { h as Step, m as StepList };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { RowStatus, RowStatusAlias } from './status-glyph.status.js';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
/** Status of a Step; the shared row vocabulary plus its aliases. */
|
|
4
|
+
export type StepStatus = RowStatus | RowStatusAlias;
|
|
5
|
+
interface StepListContextValue {
|
|
6
|
+
size: 'sm' | 'md';
|
|
7
|
+
glyphs: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare const StepListContext: React.Context<StepListContextValue>;
|
|
10
|
+
export declare const HEAD = "grid w-full grid-cols-[46px_16px_minmax(0,1fr)_auto] items-center gap-2 px-2.5 text-left";
|
|
11
|
+
export declare const HEAD_SIZE: {
|
|
12
|
+
sm: string;
|
|
13
|
+
md: string;
|
|
14
|
+
};
|
|
15
|
+
export declare const CONNECTOR: string[];
|
|
16
|
+
interface StepHeadProps {
|
|
17
|
+
offset?: React.ReactNode;
|
|
18
|
+
icon?: React.ReactNode;
|
|
19
|
+
label: React.ReactNode;
|
|
20
|
+
duration?: React.ReactNode;
|
|
21
|
+
mono: boolean;
|
|
22
|
+
status: RowStatus;
|
|
23
|
+
errorLabel: string;
|
|
24
|
+
}
|
|
25
|
+
export declare const StepHead: ({ offset, icon, label, duration, mono, status, errorLabel, }: StepHeadProps) => React.JSX.Element;
|
|
26
|
+
export declare const StepDetail: ({ id, open, error, children }: StepDetailProps) => React.JSX.Element;
|
|
27
|
+
interface StepDetailProps {
|
|
28
|
+
id: string;
|
|
29
|
+
open: boolean;
|
|
30
|
+
error: boolean;
|
|
31
|
+
children: React.ReactNode;
|
|
32
|
+
}
|
|
33
|
+
export {};
|
|
34
|
+
//# sourceMappingURL=step-list.parts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"step-list.parts.d.ts","sourceRoot":"","sources":["../../src/components/step-list.parts.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,OAAO,EAAoB,KAAK,SAAS,EAAE,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE9F,oEAAoE;AACpE,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,cAAc,CAAC;AAEpD,UAAU,oBAAoB;IAC5B,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;CACjB;AAED,eAAO,MAAM,eAAe,qCAG1B,CAAC;AAUH,eAAO,MAAM,IAAI,6FAC2E,CAAC;AAC7F,eAAO,MAAM,SAAS;;;CAA2C,CAAC;AAGlE,eAAO,MAAM,SAAS,UAKrB,CAAC;AAEF,UAAU,aAAa;IACrB,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACzB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,SAAS,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,eAAO,MAAM,QAAQ,GAAI,8DAQtB,aAAa,sBAoCf,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,+BAA+B,eAAe,sBAWxE,CAAC;AAEF,UAAU,eAAe;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,OAAO,CAAC;IACd,KAAK,EAAE,OAAO,CAAC;IACf,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B"}
|