@agentage/components 0.0.0-stage → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/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 +24 -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 +51 -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 @@
|
|
|
1
|
+
{"version":3,"file":"content-block.d.ts","sourceRoot":"","sources":["../../src/components/content-block.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAM/B,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,iBAAkB,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IACzF,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,oDAAoD;IACpD,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,+EAA+E;IAC/E,MAAM,CAAC,EAAE,kBAAkB,CAAC;IAC5B,yDAAyD;IACzD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,oDAAoD;IACpD,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAmBD,kGAAkG;AAClG,eAAO,MAAM,YAAY,uFAkDxB,CAAC;AAGF,qDAAqD;AACrD,eAAO,MAAM,UAAU,GAAI,UAAU;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,KAAG,KAAK,CAAC,GAAG,CAAC,OAYjE,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface DiffHunk {
|
|
3
|
+
/** `@@ -18,7 +18,9 @@ context`; its start numbers drive the line numbers. */
|
|
4
|
+
header: string;
|
|
5
|
+
/** Lines with a leading `+`, `-` or space. */
|
|
6
|
+
lines: string[];
|
|
7
|
+
}
|
|
8
|
+
export interface DiffFile {
|
|
9
|
+
path: string;
|
|
10
|
+
hunks: DiffHunk[];
|
|
11
|
+
}
|
|
12
|
+
export declare const diffStats: (files: DiffFile[]) => {
|
|
13
|
+
add: number;
|
|
14
|
+
del: number;
|
|
15
|
+
};
|
|
16
|
+
export declare const diffText: (files: DiffFile[]) => string;
|
|
17
|
+
export declare const DiffStat: ({ add, del }: {
|
|
18
|
+
add: number;
|
|
19
|
+
del: number;
|
|
20
|
+
}) => React.JSX.Element;
|
|
21
|
+
/** One file of a diff: a mono path header with +n -n that collapses its hunks. */
|
|
22
|
+
export declare const DiffFileView: ({ file, defaultOpen, }: {
|
|
23
|
+
file: DiffFile;
|
|
24
|
+
defaultOpen?: boolean;
|
|
25
|
+
}) => React.JSX.Element;
|
|
26
|
+
//# sourceMappingURL=content-block.diff.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content-block.diff.d.ts","sourceRoot":"","sources":["../../src/components/content-block.diff.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,MAAM,WAAW,QAAQ;IACvB,6EAA6E;IAC7E,MAAM,EAAE,MAAM,CAAC;IACf,8CAA8C;IAC9C,KAAK,EAAE,MAAM,EAAE,CAAC;CACjB;AAED,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,QAAQ,EAAE,CAAC;CACnB;AAED,eAAO,MAAM,SAAS,GAAI,OAAO,QAAQ,EAAE;;;CAM1C,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,OAAO,QAAQ,EAAE,KAAG,MAS9B,CAAC;AAEhB,eAAO,MAAM,QAAQ,GAAI,cAAc;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,sBAIlE,CAAC;AAiEF,kFAAkF;AAClF,eAAO,MAAM,YAAY,GAAI,wBAG1B;IACD,IAAI,EAAE,QAAQ,CAAC;IACf,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,sBAgCA,CAAC"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { Disclosure as t } from "./disclosure.js";
|
|
4
|
+
import { GroupHeader as n } from "./group-header.js";
|
|
5
|
+
import * as r from "react";
|
|
6
|
+
import { Fragment as i, jsx as a, jsxs as o } from "react/jsx-runtime";
|
|
7
|
+
// src/components/content-block.diff.tsx
|
|
8
|
+
var s = (e) => {
|
|
9
|
+
let t = e.flatMap((e) => e.hunks.flatMap((e) => e.lines));
|
|
10
|
+
return {
|
|
11
|
+
add: t.filter((e) => e.startsWith("+")).length,
|
|
12
|
+
del: t.filter((e) => e.startsWith("-")).length
|
|
13
|
+
};
|
|
14
|
+
}, c = (e) => e.map((e) => [
|
|
15
|
+
`--- a/${e.path}`,
|
|
16
|
+
`+++ b/${e.path}`,
|
|
17
|
+
...e.hunks.flatMap((e) => [e.header, ...e.lines])
|
|
18
|
+
].join("\n")).join("\n"), l = ({ add: e, del: t }) => /* @__PURE__ */ o("span", {
|
|
19
|
+
className: "font-mono tabular-nums",
|
|
20
|
+
"data-slot": "diff-stat",
|
|
21
|
+
children: [
|
|
22
|
+
/* @__PURE__ */ o("span", {
|
|
23
|
+
className: "text-success",
|
|
24
|
+
children: ["+", e]
|
|
25
|
+
}),
|
|
26
|
+
" ",
|
|
27
|
+
/* @__PURE__ */ o("span", {
|
|
28
|
+
className: "text-destructive",
|
|
29
|
+
children: ["-", t]
|
|
30
|
+
})
|
|
31
|
+
]
|
|
32
|
+
}), u = (e) => {
|
|
33
|
+
let t = /@@ -(\d+)(?:,\d+)? \+(\d+)/.exec(e);
|
|
34
|
+
return t ? [Number(t[1]), Number(t[2])] : [1, 1];
|
|
35
|
+
}, d = "grid grid-cols-[36px_36px_16px_minmax(0,1fr)] font-mono text-xs leading-[1.7]", f = "select-none pr-2 text-right text-muted-foreground", p = ({ hunk: t }) => {
|
|
36
|
+
let [n, r] = u(t.header);
|
|
37
|
+
return /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ o("div", {
|
|
38
|
+
className: e(d, "bg-muted/40 text-muted-foreground"),
|
|
39
|
+
"data-slot": "diff-hunk",
|
|
40
|
+
children: [/* @__PURE__ */ a("span", { className: "col-span-3" }), /* @__PURE__ */ a("span", {
|
|
41
|
+
className: "truncate",
|
|
42
|
+
children: t.header
|
|
43
|
+
})]
|
|
44
|
+
}), t.lines.map((t, i) => {
|
|
45
|
+
if (t.startsWith("\\")) return /* @__PURE__ */ o("div", {
|
|
46
|
+
className: e(d, "text-muted-foreground"),
|
|
47
|
+
"data-kind": "meta",
|
|
48
|
+
children: [/* @__PURE__ */ a("span", { className: "col-span-3" }), /* @__PURE__ */ a("span", {
|
|
49
|
+
className: "whitespace-pre italic",
|
|
50
|
+
children: t
|
|
51
|
+
})]
|
|
52
|
+
}, i);
|
|
53
|
+
let s = t[0] === "+" || t[0] === "-" ? t[0] : " ", c = s === "+" ? "" : String(n++), l = s === "-" ? "" : String(r++);
|
|
54
|
+
return /* @__PURE__ */ o("div", {
|
|
55
|
+
className: e(d, s === "+" && "bg-success/12", s === "-" && "bg-destructive/12"),
|
|
56
|
+
"data-kind": s === "+" ? "add" : s === "-" ? "del" : "context",
|
|
57
|
+
children: [
|
|
58
|
+
/* @__PURE__ */ a("span", {
|
|
59
|
+
className: e(f, s !== " " && "text-foreground/70"),
|
|
60
|
+
children: c
|
|
61
|
+
}),
|
|
62
|
+
/* @__PURE__ */ a("span", {
|
|
63
|
+
className: e(f, s !== " " && "text-foreground/70"),
|
|
64
|
+
children: l
|
|
65
|
+
}),
|
|
66
|
+
/* @__PURE__ */ a("span", {
|
|
67
|
+
className: e("select-none font-semibold", s === "+" && "text-success", s === "-" && "text-destructive"),
|
|
68
|
+
"aria-hidden": "true",
|
|
69
|
+
children: s
|
|
70
|
+
}),
|
|
71
|
+
/* @__PURE__ */ o("span", {
|
|
72
|
+
className: "whitespace-pre",
|
|
73
|
+
children: [s !== " " && /* @__PURE__ */ a("span", {
|
|
74
|
+
className: "sr-only select-none",
|
|
75
|
+
children: s === "+" ? "added " : "removed "
|
|
76
|
+
}), t.slice(1)]
|
|
77
|
+
})
|
|
78
|
+
]
|
|
79
|
+
}, i);
|
|
80
|
+
})] });
|
|
81
|
+
}, m = ({ file: e, defaultOpen: i = !0 }) => {
|
|
82
|
+
let [c, u] = r.useState(i), d = r.useId();
|
|
83
|
+
return /* @__PURE__ */ o("div", {
|
|
84
|
+
className: "border-b border-border last:border-b-0",
|
|
85
|
+
"data-slot": "diff-file",
|
|
86
|
+
children: [/* @__PURE__ */ a(n, {
|
|
87
|
+
label: /* @__PURE__ */ a("span", {
|
|
88
|
+
className: "font-mono text-xs font-normal text-muted-foreground",
|
|
89
|
+
children: e.path
|
|
90
|
+
}),
|
|
91
|
+
summary: /* @__PURE__ */ a(l, { ...s([e]) }),
|
|
92
|
+
open: c,
|
|
93
|
+
onOpenChange: u,
|
|
94
|
+
controls: d,
|
|
95
|
+
className: "border-b-0 bg-transparent pr-0",
|
|
96
|
+
"data-slot": "diff-file-toggle"
|
|
97
|
+
}), /* @__PURE__ */ a(t, {
|
|
98
|
+
id: d,
|
|
99
|
+
open: c,
|
|
100
|
+
children: /* @__PURE__ */ a("div", {
|
|
101
|
+
tabIndex: 0,
|
|
102
|
+
role: "region",
|
|
103
|
+
"aria-label": `Changes in ${e.path}`,
|
|
104
|
+
className: "overflow-x-auto border-t border-border py-1 focus-ring",
|
|
105
|
+
children: e.hunks.map((e, t) => /* @__PURE__ */ a(p, { hunk: e }, t))
|
|
106
|
+
})
|
|
107
|
+
})]
|
|
108
|
+
});
|
|
109
|
+
};
|
|
110
|
+
export { m as DiffFileView, l as DiffStat, s as diffStats, c as diffText };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { CopyButton as t } from "./copy-button.js";
|
|
4
|
+
import { Disclosure as n } from "./disclosure.js";
|
|
5
|
+
import { GroupHeader as r } from "./group-header.js";
|
|
6
|
+
import * as i from "react";
|
|
7
|
+
import { Fragment as a, jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
8
|
+
// src/components/content-block.tsx
|
|
9
|
+
var c = () => /* @__PURE__ */ o("svg", {
|
|
10
|
+
viewBox: "0 0 24 24",
|
|
11
|
+
className: "size-3.5 fill-none stroke-current stroke-2",
|
|
12
|
+
"aria-hidden": "true",
|
|
13
|
+
children: /* @__PURE__ */ o("path", {
|
|
14
|
+
d: "M15 3h6v6M10 14 21 3M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",
|
|
15
|
+
strokeLinecap: "round",
|
|
16
|
+
strokeLinejoin: "round"
|
|
17
|
+
})
|
|
18
|
+
}), l = "grid size-6 shrink-0 place-items-center rounded-lg text-muted-foreground transition-colors duration-fast hover:bg-accent hover:text-foreground focus-ring", u = i.forwardRef(({ title: u, icon: d, summary: f, source: p, copyText: m, defaultOpen: h = !0, className: g, children: _, ...v }, y) => {
|
|
19
|
+
let [b, x] = i.useState(h), S = i.useId(), C = (p || m !== void 0) && /* @__PURE__ */ s(a, { children: [p && /* @__PURE__ */ o("a", {
|
|
20
|
+
href: p.href,
|
|
21
|
+
"aria-label": `Open ${p.label}`,
|
|
22
|
+
title: p.label,
|
|
23
|
+
className: l,
|
|
24
|
+
children: /* @__PURE__ */ o(c, {})
|
|
25
|
+
}), m !== void 0 && /* @__PURE__ */ o(t, {
|
|
26
|
+
text: m,
|
|
27
|
+
iconOnly: !0,
|
|
28
|
+
variant: "ghost",
|
|
29
|
+
size: "sm",
|
|
30
|
+
label: "Copy block"
|
|
31
|
+
})] });
|
|
32
|
+
return /* @__PURE__ */ s("section", {
|
|
33
|
+
ref: y,
|
|
34
|
+
"aria-labelledby": `${S}-body-toggle`,
|
|
35
|
+
className: e("min-w-0 overflow-hidden rounded-lg border border-border bg-card", g),
|
|
36
|
+
"data-slot": "content-block",
|
|
37
|
+
"data-state": b ? "open" : "closed",
|
|
38
|
+
...v,
|
|
39
|
+
children: [/* @__PURE__ */ o(r, {
|
|
40
|
+
label: u,
|
|
41
|
+
icon: d,
|
|
42
|
+
summary: f,
|
|
43
|
+
open: b,
|
|
44
|
+
onOpenChange: x,
|
|
45
|
+
controls: `${S}-body`,
|
|
46
|
+
actions: C,
|
|
47
|
+
className: e("pr-1", !b && "border-b-0"),
|
|
48
|
+
"data-slot": "content-block-head"
|
|
49
|
+
}), /* @__PURE__ */ o(n, {
|
|
50
|
+
id: `${S}-body`,
|
|
51
|
+
open: b,
|
|
52
|
+
children: _
|
|
53
|
+
})]
|
|
54
|
+
});
|
|
55
|
+
});
|
|
56
|
+
u.displayName = "ContentBlock";
|
|
57
|
+
var d = ({ text: e }) => /* @__PURE__ */ o(a, { children: e.split(/(`[^`]+`)/g).map((e, t) => e.startsWith("`") && e.endsWith("`") && e.length > 2 ? /* @__PURE__ */ o("code", {
|
|
58
|
+
className: "rounded border border-border bg-card px-1 py-px font-mono text-xs",
|
|
59
|
+
children: e.slice(1, -1)
|
|
60
|
+
}, t) : /* @__PURE__ */ o(i.Fragment, { children: e }, t)) });
|
|
61
|
+
export { u as ContentBlock, d as InlineText };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export type BlockStepState = 'done' | 'active' | 'pending' | 'failed' | 'skipped';
|
|
3
|
+
export interface BlockStep {
|
|
4
|
+
title: string;
|
|
5
|
+
detail?: React.ReactNode;
|
|
6
|
+
state?: BlockStepState;
|
|
7
|
+
}
|
|
8
|
+
/** Numbered steps: a 22 px number disc (or the state glyph), a bold title and a muted detail. */
|
|
9
|
+
export declare const StepsView: ({ steps }: {
|
|
10
|
+
steps: BlockStep[];
|
|
11
|
+
}) => React.JSX.Element;
|
|
12
|
+
//# sourceMappingURL=content-block.parts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content-block.parts.d.ts","sourceRoot":"","sources":["../../src/components/content-block.parts.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAAC;AAElF,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACzB,KAAK,CAAC,EAAE,cAAc,CAAC;CACxB;AAQD,iGAAiG;AACjG,eAAO,MAAM,SAAS,GAAI,WAAW;IAAE,KAAK,EAAE,SAAS,EAAE,CAAA;CAAE,sBAkC1D,CAAC"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { StatusGlyph as t } from "./status-glyph.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
6
|
+
// src/components/content-block.parts.tsx
|
|
7
|
+
var i = {
|
|
8
|
+
done: /* @__PURE__ */ n(t, {
|
|
9
|
+
shape: "check",
|
|
10
|
+
tone: "success",
|
|
11
|
+
size: "md",
|
|
12
|
+
label: "Done"
|
|
13
|
+
}),
|
|
14
|
+
failed: /* @__PURE__ */ n(t, {
|
|
15
|
+
shape: "cross",
|
|
16
|
+
tone: "destructive",
|
|
17
|
+
size: "md",
|
|
18
|
+
label: "Failed"
|
|
19
|
+
}),
|
|
20
|
+
skipped: /* @__PURE__ */ n(t, {
|
|
21
|
+
shape: "dashed",
|
|
22
|
+
tone: "muted",
|
|
23
|
+
size: "md",
|
|
24
|
+
label: "Skipped"
|
|
25
|
+
})
|
|
26
|
+
}, a = ({ steps: t }) => /* @__PURE__ */ n("ol", {
|
|
27
|
+
className: "m-0 flex list-none flex-col p-0 px-3",
|
|
28
|
+
"data-slot": "steps-view",
|
|
29
|
+
children: t.map((t, a) => {
|
|
30
|
+
let o = t.state ?? "pending";
|
|
31
|
+
return /* @__PURE__ */ r("li", {
|
|
32
|
+
className: "grid grid-cols-[22px_minmax(0,1fr)] gap-x-2.5 gap-y-0.5 border-b border-border py-2 last:border-b-0",
|
|
33
|
+
"data-state": o,
|
|
34
|
+
"aria-current": o === "active" ? "step" : void 0,
|
|
35
|
+
children: [
|
|
36
|
+
/* @__PURE__ */ n("span", {
|
|
37
|
+
className: e("row-span-2 grid size-[22px] place-items-center rounded-full border border-border bg-background text-xs font-semibold text-muted-foreground", o === "active" && "border-primary text-primary-emphasis", (o === "done" || o === "failed" || o === "skipped") && "border-transparent bg-transparent"),
|
|
38
|
+
children: o in i ? i[o] : a + 1
|
|
39
|
+
}),
|
|
40
|
+
/* @__PURE__ */ n("b", {
|
|
41
|
+
className: e("text-ui font-semibold", o === "skipped" && "text-muted-foreground line-through"),
|
|
42
|
+
children: t.title
|
|
43
|
+
}),
|
|
44
|
+
t.detail && /* @__PURE__ */ n("span", {
|
|
45
|
+
className: "text-ui text-muted-foreground",
|
|
46
|
+
children: t.detail
|
|
47
|
+
})
|
|
48
|
+
]
|
|
49
|
+
}, a);
|
|
50
|
+
})
|
|
51
|
+
});
|
|
52
|
+
export { a as StepsView };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { CheckStatus } from './check-list.js';
|
|
2
|
+
import { ContentBlockSource } from './content-block.js';
|
|
3
|
+
import { DiffFile } from './content-block.diff.js';
|
|
4
|
+
import { BlockStep } from './content-block.parts.js';
|
|
5
|
+
import { LogLine } from './log-view.js';
|
|
6
|
+
import * as React from 'react';
|
|
7
|
+
export type { DiffFile, DiffHunk } from './content-block.diff.js';
|
|
8
|
+
export type { BlockStep, BlockStepState } from './content-block.parts.js';
|
|
9
|
+
interface BlockBase {
|
|
10
|
+
/** Stable key when blocks change. */
|
|
11
|
+
id?: string;
|
|
12
|
+
title?: string;
|
|
13
|
+
source?: ContentBlockSource;
|
|
14
|
+
/** Adds the header copy button; `true` copies the block as text. */
|
|
15
|
+
copy?: boolean;
|
|
16
|
+
defaultOpen?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export type ContentBlockData = BlockBase & ({
|
|
19
|
+
type: 'text';
|
|
20
|
+
text: string;
|
|
21
|
+
} | {
|
|
22
|
+
type: 'facts';
|
|
23
|
+
rows: {
|
|
24
|
+
label: string;
|
|
25
|
+
value: React.ReactNode;
|
|
26
|
+
mono?: boolean;
|
|
27
|
+
href?: string;
|
|
28
|
+
}[];
|
|
29
|
+
} | {
|
|
30
|
+
type: 'steps';
|
|
31
|
+
steps: BlockStep[];
|
|
32
|
+
} | {
|
|
33
|
+
type: 'checks';
|
|
34
|
+
rows: {
|
|
35
|
+
label: string;
|
|
36
|
+
status?: CheckStatus;
|
|
37
|
+
value?: string;
|
|
38
|
+
detail?: React.ReactNode;
|
|
39
|
+
}[];
|
|
40
|
+
} | {
|
|
41
|
+
type: 'diff';
|
|
42
|
+
files: DiffFile[];
|
|
43
|
+
} | {
|
|
44
|
+
type: 'log';
|
|
45
|
+
lines: (string | LogLine)[];
|
|
46
|
+
tail?: number;
|
|
47
|
+
} | {
|
|
48
|
+
type: 'callout';
|
|
49
|
+
question: React.ReactNode;
|
|
50
|
+
actions?: React.ReactNode;
|
|
51
|
+
icon?: React.ReactNode;
|
|
52
|
+
});
|
|
53
|
+
export interface ContentBlocksProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
54
|
+
blocks: ContentBlockData[];
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Typed detail body, richer than markdown: text, facts, steps, checks, diff, log and a callout.
|
|
58
|
+
* Each framed block has a header with an icon, title, summary, collapse, link and copy.
|
|
59
|
+
*/
|
|
60
|
+
export declare const ContentBlocks: React.ForwardRefExoticComponent<ContentBlocksProps & React.RefAttributes<HTMLDivElement>>;
|
|
61
|
+
//# sourceMappingURL=content-blocks.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content-blocks.d.ts","sourceRoot":"","sources":["../../src/components/content-blocks.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAwB,KAAK,WAAW,EAAE,MAAM,cAAc,CAAC;AAEtE,OAAO,EAA4B,KAAK,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AACpF,OAAO,EAAgB,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,EAAa,KAAK,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClE,OAAO,EAAW,KAAK,OAAO,EAAE,MAAM,YAAY,CAAC;AAInD,YAAY,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC/D,YAAY,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAgBvE,UAAU,SAAS;IACjB,qCAAqC;IACrC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,kBAAkB,CAAC;IAC5B,oEAAoE;IACpE,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,MAAM,MAAM,gBAAgB,GAAG,SAAS,GACtC,CACI;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAC9B;IACE,IAAI,EAAE,OAAO,CAAC;IACd,IAAI,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;QAAC,IAAI,CAAC,EAAE,OAAO,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CAClF,GACD;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,SAAS,EAAE,CAAA;CAAE,GACrC;IACE,IAAI,EAAE,QAAQ,CAAC;IACf,IAAI,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,WAAW,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;KAAE,EAAE,CAAC;CAC3F,GACD;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,QAAQ,EAAE,CAAA;CAAE,GACnC;IAAE,IAAI,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,CAAC,MAAM,GAAG,OAAO,CAAC,EAAE,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,GAC3D;IACE,IAAI,EAAE,SAAS,CAAC;IAChB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACxB,CACJ,CAAC;AAoGJ,MAAM,WAAW,kBAAmB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC9E,MAAM,EAAE,gBAAgB,EAAE,CAAC;CAC5B;AAED;;;GAGG;AACH,eAAO,MAAM,aAAa,2FAazB,CAAC"}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { Alert as t } from "./alert.js";
|
|
4
|
+
import { CheckItem as n, CheckList as r } from "./check-list.js";
|
|
5
|
+
import { DescriptionDetail as i, DescriptionList as a, DescriptionTerm as o } from "./description-list.js";
|
|
6
|
+
import { ContentBlock as s, InlineText as c } from "./content-block.js";
|
|
7
|
+
import { DiffFileView as l } from "./content-block.diff.js";
|
|
8
|
+
import { StepsView as u } from "./content-block.parts.js";
|
|
9
|
+
import { LogView as d } from "./log-view.js";
|
|
10
|
+
import { toLogLine as f } from "./log-view.model.js";
|
|
11
|
+
import { ICON as p, TITLE as m, asText as h, summaryOf as g } from "./content-blocks.meta.js";
|
|
12
|
+
import * as _ from "react";
|
|
13
|
+
import { jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
14
|
+
// src/components/content-blocks.tsx
|
|
15
|
+
var b = (e) => {
|
|
16
|
+
let [t, n] = _.useState(!0);
|
|
17
|
+
return /* @__PURE__ */ v(d, {
|
|
18
|
+
...e,
|
|
19
|
+
follow: t,
|
|
20
|
+
onFollowChange: n,
|
|
21
|
+
showTime: !1,
|
|
22
|
+
className: "py-1"
|
|
23
|
+
});
|
|
24
|
+
}, x = (e) => {
|
|
25
|
+
let t = /* @__PURE__ */ new Map();
|
|
26
|
+
return e.map((e) => {
|
|
27
|
+
let n = t.get(e) ?? 0;
|
|
28
|
+
return t.set(e, n + 1), n ? `${e}#${String(n)}` : e;
|
|
29
|
+
});
|
|
30
|
+
}, S = ({ block: e }) => {
|
|
31
|
+
switch (e.type) {
|
|
32
|
+
case "text": return /* @__PURE__ */ v("p", {
|
|
33
|
+
className: "m-0 px-3 py-2.5 text-ui leading-relaxed",
|
|
34
|
+
children: /* @__PURE__ */ v(c, { text: e.text })
|
|
35
|
+
});
|
|
36
|
+
case "facts": {
|
|
37
|
+
let t = x(e.rows.map((e) => e.label));
|
|
38
|
+
return /* @__PURE__ */ v(a, {
|
|
39
|
+
labelWidth: "md",
|
|
40
|
+
className: "px-3.5 py-3",
|
|
41
|
+
children: e.rows.map((e, n) => /* @__PURE__ */ y(_.Fragment, { children: [/* @__PURE__ */ v(o, { children: e.label }), /* @__PURE__ */ v(i, {
|
|
42
|
+
mono: e.mono,
|
|
43
|
+
href: e.href,
|
|
44
|
+
children: typeof e.value == "string" ? /* @__PURE__ */ v(c, { text: e.value }) : e.value
|
|
45
|
+
})] }, t[n]))
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
case "steps": return /* @__PURE__ */ v(u, { steps: e.steps });
|
|
49
|
+
case "checks": {
|
|
50
|
+
let t = x(e.rows.map((e) => e.label));
|
|
51
|
+
return /* @__PURE__ */ v(r, {
|
|
52
|
+
variant: "plain",
|
|
53
|
+
children: e.rows.map((e, r) => /* @__PURE__ */ v(n, {
|
|
54
|
+
label: e.label,
|
|
55
|
+
status: e.status,
|
|
56
|
+
value: e.value,
|
|
57
|
+
children: e.detail
|
|
58
|
+
}, t[r]))
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
case "diff": {
|
|
62
|
+
let t = x(e.files.map((e) => e.path));
|
|
63
|
+
return /* @__PURE__ */ v("div", { children: e.files.map((e, n) => /* @__PURE__ */ v(l, { file: e }, t[n])) });
|
|
64
|
+
}
|
|
65
|
+
case "log": return /* @__PURE__ */ v(b, {
|
|
66
|
+
lines: e.lines.map(f),
|
|
67
|
+
"aria-label": e.title ?? "Log lines",
|
|
68
|
+
style: { height: Math.min(e.lines.length, e.tail ?? 8) * 24 + 8 }
|
|
69
|
+
});
|
|
70
|
+
default: return null;
|
|
71
|
+
}
|
|
72
|
+
}, C = ({ block: e }) => e.type === "callout" ? /* @__PURE__ */ v(t, {
|
|
73
|
+
variant: "primary",
|
|
74
|
+
icon: e.icon,
|
|
75
|
+
title: e.title,
|
|
76
|
+
actions: e.actions,
|
|
77
|
+
role: "note",
|
|
78
|
+
children: e.question
|
|
79
|
+
}) : e.type === "text" && !e.title ? /* @__PURE__ */ v("p", {
|
|
80
|
+
className: "m-0 text-ui leading-relaxed",
|
|
81
|
+
children: /* @__PURE__ */ v(c, { text: e.text })
|
|
82
|
+
}) : /* @__PURE__ */ v(s, {
|
|
83
|
+
title: e.title ?? m[e.type],
|
|
84
|
+
icon: p[e.type],
|
|
85
|
+
summary: g(e),
|
|
86
|
+
source: e.source,
|
|
87
|
+
copyText: e.copy ? h(e) : void 0,
|
|
88
|
+
defaultOpen: e.defaultOpen,
|
|
89
|
+
"data-block": e.type,
|
|
90
|
+
children: /* @__PURE__ */ v(S, { block: e })
|
|
91
|
+
}), w = _.forwardRef(({ blocks: t, className: n, ...r }, i) => /* @__PURE__ */ v("div", {
|
|
92
|
+
ref: i,
|
|
93
|
+
className: e("flex min-w-0 flex-col gap-3.5", n),
|
|
94
|
+
"data-slot": "content-blocks",
|
|
95
|
+
...r,
|
|
96
|
+
children: t.map((e, t) => /* @__PURE__ */ v(C, { block: e }, e.id ?? `${e.type}-${String(t)}`))
|
|
97
|
+
}));
|
|
98
|
+
w.displayName = "ContentBlocks";
|
|
99
|
+
export { w as ContentBlocks };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ContentBlockData } from './content-blocks.js';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export declare const ICON: {
|
|
4
|
+
text: React.JSX.Element;
|
|
5
|
+
facts: React.JSX.Element;
|
|
6
|
+
steps: React.JSX.Element;
|
|
7
|
+
checks: React.JSX.Element;
|
|
8
|
+
diff: React.JSX.Element;
|
|
9
|
+
log: React.JSX.Element;
|
|
10
|
+
};
|
|
11
|
+
export declare const TITLE: {
|
|
12
|
+
text: string;
|
|
13
|
+
facts: string;
|
|
14
|
+
steps: string;
|
|
15
|
+
checks: string;
|
|
16
|
+
diff: string;
|
|
17
|
+
log: string;
|
|
18
|
+
};
|
|
19
|
+
export declare const asText: (b: ContentBlockData) => string;
|
|
20
|
+
export declare const summaryOf: (b: ContentBlockData) => React.ReactNode;
|
|
21
|
+
//# sourceMappingURL=content-blocks.meta.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content-blocks.meta.d.ts","sourceRoot":"","sources":["../../src/components/content-blocks.meta.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAczD,eAAO,MAAM,IAAI;;;;;;;CAOhB,CAAC;AAEF,eAAO,MAAM,KAAK;;;;;;;CAOjB,CAAC;AAEF,eAAO,MAAM,MAAM,GAAI,GAAG,gBAAgB,KAAG,MAqB5C,CAAC;AAEF,eAAO,MAAM,SAAS,GAAI,GAAG,gBAAgB,KAAG,KAAK,CAAC,SAiBrD,CAAC"}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { checkSummary as e } from "./status-glyph.status.js";
|
|
3
|
+
import { DiffStat as t, diffStats as n, diffText as r } from "./content-block.diff.js";
|
|
4
|
+
import { toLogLine as i } from "./log-view.model.js";
|
|
5
|
+
import "react";
|
|
6
|
+
import { Fragment as a, jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
7
|
+
// src/components/content-blocks.meta.tsx
|
|
8
|
+
var c = ({ d: e }) => /* @__PURE__ */ o("svg", {
|
|
9
|
+
viewBox: "0 0 24 24",
|
|
10
|
+
className: "fill-none stroke-current stroke-2",
|
|
11
|
+
strokeLinecap: "round",
|
|
12
|
+
strokeLinejoin: "round",
|
|
13
|
+
"aria-hidden": "true",
|
|
14
|
+
children: /* @__PURE__ */ o("path", { d: e })
|
|
15
|
+
}), l = {
|
|
16
|
+
text: /* @__PURE__ */ o(c, { d: "M4 6h16M4 12h16M4 18h10" }),
|
|
17
|
+
facts: /* @__PURE__ */ o(c, { d: "M8 6h12M8 12h12M8 18h12M4 6h.01M4 12h.01M4 18h.01" }),
|
|
18
|
+
steps: /* @__PURE__ */ o(c, { d: "M10 6h10M10 12h10M10 18h10M4 4v4M3 18h2.5L3 21h3" }),
|
|
19
|
+
checks: /* @__PURE__ */ o(c, { d: "M9 11l3 3 8-8M20 12v6a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h9" }),
|
|
20
|
+
diff: /* @__PURE__ */ o(c, { d: "M12 3v14M5 10h14M5 21h14" }),
|
|
21
|
+
log: /* @__PURE__ */ o(c, { d: "M4 17l6-6-6-6M12 19h8" })
|
|
22
|
+
}, u = {
|
|
23
|
+
text: "Note",
|
|
24
|
+
facts: "Details",
|
|
25
|
+
steps: "Steps",
|
|
26
|
+
checks: "Checks",
|
|
27
|
+
diff: "Changes",
|
|
28
|
+
log: "Log"
|
|
29
|
+
}, d = (e) => {
|
|
30
|
+
switch (e.type) {
|
|
31
|
+
case "text": return e.text;
|
|
32
|
+
case "facts": return e.rows.map((e) => `${e.label}: ${typeof e.value == "string" ? e.value : ""}`).join("\n");
|
|
33
|
+
case "steps": return e.steps.map((e, t) => `${String(t + 1)}. ${e.title}`).join("\n");
|
|
34
|
+
case "checks": return e.rows.map((e) => `${e.status ?? "ok"} ${e.label}${e.value ? ` (${e.value})` : ""}`).join("\n");
|
|
35
|
+
case "diff": return r(e.files);
|
|
36
|
+
case "log": return e.lines.map((e, t) => i(e, t).message).join("\n");
|
|
37
|
+
default: return "";
|
|
38
|
+
}
|
|
39
|
+
}, f = (r) => {
|
|
40
|
+
if (r.type === "checks") return e(r.rows.map((e) => e.status ?? "ok"));
|
|
41
|
+
if (r.type === "diff") {
|
|
42
|
+
let e = `${String(r.files.length)} ${r.files.length === 1 ? "file" : "files"}`;
|
|
43
|
+
return /* @__PURE__ */ s(a, { children: [
|
|
44
|
+
/* @__PURE__ */ o(t, { ...n(r.files) }),
|
|
45
|
+
" in ",
|
|
46
|
+
e
|
|
47
|
+
] });
|
|
48
|
+
}
|
|
49
|
+
if (r.type === "log") return `${String(r.lines.length)} lines`;
|
|
50
|
+
if (r.type === "steps") {
|
|
51
|
+
let e = r.steps.filter((e) => e.state === "done").length;
|
|
52
|
+
return `${String(e)} of ${String(r.steps.length)} done`;
|
|
53
|
+
}
|
|
54
|
+
if (r.type === "facts") return `${String(r.rows.length)} items`;
|
|
55
|
+
};
|
|
56
|
+
export { l as ICON, u as TITLE, d as asText, f as summaryOf };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** Buttons and toolbar controls: md 28 px, px 10, gap 6, 13 px, 16 px icons; sm 24 px, 12 px. */
|
|
2
|
+
export declare const controlVariants: (props?: ({
|
|
3
|
+
size?: "sm" | "md" | null | undefined;
|
|
4
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
5
|
+
/** Form fields (Input, Select, DatePicker triggers): md 30 px, sm 26 px at 12 px. */
|
|
6
|
+
export declare const fieldVariants: (props?: ({
|
|
7
|
+
size?: "sm" | "md" | null | undefined;
|
|
8
|
+
error?: boolean | null | undefined;
|
|
9
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
10
|
+
//# sourceMappingURL=control.variants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"control.variants.d.ts","sourceRoot":"","sources":["../../src/components/control.variants.ts"],"names":[],"mappings":"AAEA,iGAAiG;AACjG,eAAO,MAAM,eAAe;;8EAW3B,CAAC;AAEF,qFAAqF;AACrF,eAAO,MAAM,aAAa;;;8EAYzB,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { cva as e } from "class-variance-authority";
|
|
2
|
+
// src/components/control.variants.ts
|
|
3
|
+
var t = e("inline-flex shrink-0 items-center justify-center whitespace-nowrap rounded-lg [&_svg]:shrink-0", {
|
|
4
|
+
variants: { size: {
|
|
5
|
+
md: "h-7 gap-1.5 px-2.5 text-ui [&_svg:not([class*=\"size-\"])]:size-4",
|
|
6
|
+
sm: "h-6 gap-1 px-2 text-xs [&_svg:not([class*=\"size-\"])]:size-3.5"
|
|
7
|
+
} },
|
|
8
|
+
defaultVariants: { size: "md" }
|
|
9
|
+
}), n = e("w-full rounded-md border border-border bg-muted/30 transition-colors duration-fast focus-ring placeholder:text-muted-foreground/60 disabled:cursor-not-allowed disabled:opacity-50", {
|
|
10
|
+
variants: {
|
|
11
|
+
size: {
|
|
12
|
+
md: "h-[30px] px-2.5 text-ui",
|
|
13
|
+
sm: "h-[26px] px-2 text-xs"
|
|
14
|
+
},
|
|
15
|
+
error: {
|
|
16
|
+
true: "border-destructive",
|
|
17
|
+
false: ""
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
defaultVariants: {
|
|
21
|
+
size: "md",
|
|
22
|
+
error: !1
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
export { t as controlVariants, n as fieldVariants };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import { buttonVariants } from './button.variants.js';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
export interface CopyButtonProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'children'>, VariantProps<typeof buttonVariants> {
|
|
5
|
+
text: string;
|
|
6
|
+
label?: string;
|
|
7
|
+
successLabel?: string;
|
|
8
|
+
/** Shown briefly when both the async and legacy copy paths fail. */
|
|
9
|
+
errorLabel?: string;
|
|
10
|
+
duration?: number;
|
|
11
|
+
/** The 24 px square small control with a 14 px glyph, for rows too; `size` is ignored. */
|
|
12
|
+
iconOnly?: boolean;
|
|
13
|
+
}
|
|
14
|
+
export declare const CopyButton: React.ForwardRefExoticComponent<CopyButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
15
|
+
//# sourceMappingURL=copy-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"copy-button.d.ts","sourceRoot":"","sources":["../../src/components/copy-button.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAG7D,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAoDnD,MAAM,WAAW,eACf,SACE,IAAI,CAAC,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,UAAU,CAAC,EAC/D,YAAY,CAAC,OAAO,cAAc,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,oEAAoE;IACpE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,0FAA0F;IAC1F,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,UAAU,2FAgFtB,CAAC"}
|