@bridgebrew/ui 0.0.0-stage → 0.1.9
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 +39 -2
- package/SOURCE.md +182 -0
- package/dist/build.js +871 -0
- package/dist/theme-css.js +896 -0
- package/dist/themes.js +69 -0
- package/dist/types/build/stylesheet.d.ts +31 -0
- package/dist/types/components/composite/command/command.d.ts +94 -0
- package/dist/types/components/composite/command/index.d.ts +2 -0
- package/dist/types/components/composite/draft-bar/draft-bar.d.ts +12 -0
- package/dist/types/components/composite/draft-bar/index.d.ts +2 -0
- package/dist/types/components/composite/image-field/image-field.d.ts +33 -0
- package/dist/types/components/composite/image-field/index.d.ts +2 -0
- package/dist/types/components/composite/list/index.d.ts +3 -0
- package/dist/types/components/composite/list/list-swipe.d.ts +28 -0
- package/dist/types/components/composite/list/list.d.ts +95 -0
- package/dist/types/components/composite/picker/index.d.ts +2 -0
- package/dist/types/components/composite/picker/picker.d.ts +44 -0
- package/dist/types/components/composite/prompt-field/index.d.ts +2 -0
- package/dist/types/components/composite/prompt-field/prompt-field.d.ts +18 -0
- package/dist/types/components/composite/properties/index.d.ts +2 -0
- package/dist/types/components/composite/properties/properties.d.ts +24 -0
- package/dist/types/components/composite/snooze-menu/index.d.ts +4 -0
- package/dist/types/components/composite/snooze-menu/presets.d.ts +36 -0
- package/dist/types/components/composite/snooze-menu/snooze-menu.d.ts +27 -0
- package/dist/types/components/composite/tag-input/index.d.ts +2 -0
- package/dist/types/components/composite/tag-input/tag-input.d.ts +22 -0
- package/dist/types/components/composite/wizard/index.d.ts +2 -0
- package/dist/types/components/composite/wizard/wizard.d.ts +53 -0
- package/dist/types/components/core/avatar/avatar.d.ts +16 -0
- package/dist/types/components/core/avatar/index.d.ts +2 -0
- package/dist/types/components/core/badge/badge.d.ts +8 -0
- package/dist/types/components/core/badge/index.d.ts +2 -0
- package/dist/types/components/core/breadcrumb/breadcrumb.d.ts +21 -0
- package/dist/types/components/core/breadcrumb/index.d.ts +2 -0
- package/dist/types/components/core/bullets/bullets.d.ts +15 -0
- package/dist/types/components/core/bullets/index.d.ts +2 -0
- package/dist/types/components/core/button/button.d.ts +14 -0
- package/dist/types/components/core/button/index.d.ts +2 -0
- package/dist/types/components/core/card/card.d.ts +16 -0
- package/dist/types/components/core/card/index.d.ts +2 -0
- package/dist/types/components/core/checkbox/checkbox.d.ts +15 -0
- package/dist/types/components/core/checkbox/index.d.ts +2 -0
- package/dist/types/components/core/cluster/cluster.d.ts +5 -0
- package/dist/types/components/core/cluster/index.d.ts +1 -0
- package/dist/types/components/core/code-block/code-block.d.ts +18 -0
- package/dist/types/components/core/code-block/index.d.ts +2 -0
- package/dist/types/components/core/collapsible/collapsible.d.ts +8 -0
- package/dist/types/components/core/collapsible/index.d.ts +1 -0
- package/dist/types/components/core/colour-picker/colour-picker.d.ts +25 -0
- package/dist/types/components/core/colour-picker/index.d.ts +4 -0
- package/dist/types/components/core/combobox/combobox.d.ts +63 -0
- package/dist/types/components/core/combobox/index.d.ts +2 -0
- package/dist/types/components/core/detail/detail.d.ts +12 -0
- package/dist/types/components/core/detail/index.d.ts +1 -0
- package/dist/types/components/core/dialog/dialog.d.ts +43 -0
- package/dist/types/components/core/dialog/drag.d.ts +4 -0
- package/dist/types/components/core/dialog/index.d.ts +2 -0
- package/dist/types/components/core/drop-zone/drop-zone.d.ts +23 -0
- package/dist/types/components/core/drop-zone/index.d.ts +2 -0
- package/dist/types/components/core/dropdown-menu/dropdown-menu.d.ts +78 -0
- package/dist/types/components/core/dropdown-menu/index.d.ts +2 -0
- package/dist/types/components/core/editable-field/editable-field.d.ts +42 -0
- package/dist/types/components/core/editable-field/index.d.ts +2 -0
- package/dist/types/components/core/empty-state/empty-state.d.ts +11 -0
- package/dist/types/components/core/empty-state/index.d.ts +2 -0
- package/dist/types/components/core/field/field.d.ts +31 -0
- package/dist/types/components/core/field/index.d.ts +2 -0
- package/dist/types/components/core/icon/icon-sets.d.ts +38 -0
- package/dist/types/components/core/icon/icon.d.ts +14 -0
- package/dist/types/components/core/icon/index.d.ts +2 -0
- package/dist/types/components/core/input/index.d.ts +4 -0
- package/dist/types/components/core/input/input.d.ts +22 -0
- package/dist/types/components/core/input/textarea.d.ts +8 -0
- package/dist/types/components/core/kbd/index.d.ts +2 -0
- package/dist/types/components/core/kbd/kbd.d.ts +7 -0
- package/dist/types/components/core/label/index.d.ts +2 -0
- package/dist/types/components/core/label/label.d.ts +13 -0
- package/dist/types/components/core/main-content/index.d.ts +2 -0
- package/dist/types/components/core/main-content/main-content.d.ts +18 -0
- package/dist/types/components/core/pane/index.d.ts +1 -0
- package/dist/types/components/core/pane/pane.d.ts +12 -0
- package/dist/types/components/core/pick-menu/index.d.ts +4 -0
- package/dist/types/components/core/pick-menu/pick-menu.d.ts +57 -0
- package/dist/types/components/core/pick-menu/tag-menu.d.ts +19 -0
- package/dist/types/components/core/popover/index.d.ts +2 -0
- package/dist/types/components/core/popover/popover.d.ts +22 -0
- package/dist/types/components/core/progress/index.d.ts +2 -0
- package/dist/types/components/core/progress/progress.d.ts +13 -0
- package/dist/types/components/core/resizable/index.d.ts +2 -0
- package/dist/types/components/core/resizable/resizable.d.ts +15 -0
- package/dist/types/components/core/resizable/use-remembered-layout.d.ts +31 -0
- package/dist/types/components/core/screen-link/index.d.ts +2 -0
- package/dist/types/components/core/screen-link/screen-link.d.ts +52 -0
- package/dist/types/components/core/scroll-area/index.d.ts +2 -0
- package/dist/types/components/core/scroll-area/scroll-area.d.ts +13 -0
- package/dist/types/components/core/scroll-area/steps.d.ts +5 -0
- package/dist/types/components/core/section/index.d.ts +2 -0
- package/dist/types/components/core/section/section.d.ts +16 -0
- package/dist/types/components/core/segment-group/index.d.ts +2 -0
- package/dist/types/components/core/segment-group/segment-group.d.ts +24 -0
- package/dist/types/components/core/select/index.d.ts +2 -0
- package/dist/types/components/core/select/select.d.ts +39 -0
- package/dist/types/components/core/skeleton/index.d.ts +2 -0
- package/dist/types/components/core/skeleton/skeleton.d.ts +13 -0
- package/dist/types/components/core/slider/index.d.ts +2 -0
- package/dist/types/components/core/slider/slider.d.ts +9 -0
- package/dist/types/components/core/sortable/index.d.ts +2 -0
- package/dist/types/components/core/sortable/sortable.d.ts +53 -0
- package/dist/types/components/core/split-view/index.d.ts +2 -0
- package/dist/types/components/core/split-view/split-view.d.ts +28 -0
- package/dist/types/components/core/status-icon/index.d.ts +2 -0
- package/dist/types/components/core/status-icon/status-icon.d.ts +13 -0
- package/dist/types/components/core/table/collapsible-rows.d.ts +7 -0
- package/dist/types/components/core/table/expand-toggle.d.ts +10 -0
- package/dist/types/components/core/table/group-header.d.ts +14 -0
- package/dist/types/components/core/table/index.d.ts +8 -0
- package/dist/types/components/core/table/table.d.ts +31 -0
- package/dist/types/components/core/tabs/index.d.ts +2 -0
- package/dist/types/components/core/tabs/tabs.d.ts +20 -0
- package/dist/types/components/core/tag-pill/index.d.ts +2 -0
- package/dist/types/components/core/tag-pill/tag-pill.d.ts +25 -0
- package/dist/types/components/core/thumbnail/index.d.ts +2 -0
- package/dist/types/components/core/thumbnail/thumbnail.d.ts +23 -0
- package/dist/types/components/core/toast/index.d.ts +2 -0
- package/dist/types/components/core/toast/toast.d.ts +88 -0
- package/dist/types/components/core/toggle/index.d.ts +2 -0
- package/dist/types/components/core/toggle/toggle.d.ts +9 -0
- package/dist/types/components/core/toggle-group/index.d.ts +2 -0
- package/dist/types/components/core/toggle-group/toggle-group.d.ts +21 -0
- package/dist/types/components/core/tooltip/index.d.ts +2 -0
- package/dist/types/components/core/tooltip/tooltip.d.ts +33 -0
- package/dist/types/components/layout/multi-pane/index.d.ts +4 -0
- package/dist/types/components/layout/multi-pane/list-detail.d.ts +17 -0
- package/dist/types/components/layout/multi-pane/multi-pane.d.ts +34 -0
- package/dist/types/components/layout/single-pane/index.d.ts +2 -0
- package/dist/types/components/layout/single-pane/single-pane.d.ts +11 -0
- package/dist/types/components/shell/app-shell/app-shell.d.ts +12 -0
- package/dist/types/components/shell/app-shell/index.d.ts +2 -0
- package/dist/types/components/shell/sidebar/index.d.ts +2 -0
- package/dist/types/components/shell/sidebar/sidebar-group.d.ts +45 -0
- package/dist/types/components/shell/sidebar/sidebar-item.d.ts +19 -0
- package/dist/types/components/shell/sidebar/sidebar-resize-handle.d.ts +17 -0
- package/dist/types/components/shell/sidebar/sidebar-tree.d.ts +42 -0
- package/dist/types/components/shell/sidebar/sidebar.d.ts +27 -0
- package/dist/types/components/template/address-book-template/address-book-template.d.ts +15 -0
- package/dist/types/components/template/address-book-template/index.d.ts +2 -0
- package/dist/types/components/template/mail-template/index.d.ts +2 -0
- package/dist/types/components/template/mail-template/mail-template.d.ts +11 -0
- package/dist/types/components/template/use-narrow.d.ts +3 -0
- package/dist/types/index.d.ts +149 -0
- package/dist/types/kit/check-rendering.d.ts +3 -0
- package/dist/types/kit/kit.d.ts +76 -0
- package/dist/types/lib/clipboard.d.ts +5 -0
- package/dist/types/lib/dates.d.ts +9 -0
- package/dist/types/lib/json.d.ts +26 -0
- package/dist/types/lib/keys.d.ts +15 -0
- package/dist/types/lib/utils.d.ts +2 -0
- package/dist/types/lib/view-scope.d.ts +22 -0
- package/dist/types/profile/profile.d.ts +34 -0
- package/dist/types/theme/appearance.d.ts +31 -0
- package/dist/types/theme/boot.d.ts +3 -0
- package/dist/types/theme/client-appearance-react.d.ts +3 -0
- package/dist/types/theme/client-appearance.d.ts +69 -0
- package/dist/types/theme/generate-tokens.d.ts +45 -0
- package/dist/types/theme/pack-themes-react.d.ts +24 -0
- package/dist/types/theme/palette.d.ts +111 -0
- package/dist/types/theme/semantic-mapping.d.ts +28 -0
- package/dist/types/theme/set-theme.d.ts +30 -0
- package/dist/types/theme/theme-colours.d.ts +14 -0
- package/dist/types/theme/theme-css.d.ts +3 -0
- package/dist/types/theme/themes.d.ts +63 -0
- package/dist/types/theme/wallpaper-sheet.d.ts +16 -0
- package/dist/types/theme/wallpaper-theme-react.d.ts +7 -0
- package/dist/types/theme/wallpaper-theme.d.ts +37 -0
- package/package.json +87 -3
- package/src/build/stylesheet.ts +128 -0
- package/src/components/composite/command/command.meta.yaml +74 -0
- package/src/components/composite/command/command.tsx +939 -0
- package/src/components/composite/command/index.ts +17 -0
- package/src/components/composite/draft-bar/draft-bar.meta.yaml +19 -0
- package/src/components/composite/draft-bar/draft-bar.tsx +57 -0
- package/src/components/composite/draft-bar/index.ts +2 -0
- package/src/components/composite/image-field/image-field.meta.yaml +69 -0
- package/src/components/composite/image-field/image-field.tsx +267 -0
- package/src/components/composite/image-field/index.ts +2 -0
- package/src/components/composite/list/index.ts +18 -0
- package/src/components/composite/list/list-swipe.tsx +163 -0
- package/src/components/composite/list/list.meta.yaml +238 -0
- package/src/components/composite/list/list.tsx +868 -0
- package/src/components/composite/picker/index.ts +2 -0
- package/src/components/composite/picker/picker.meta.yaml +103 -0
- package/src/components/composite/picker/picker.tsx +276 -0
- package/src/components/composite/prompt-field/index.ts +2 -0
- package/src/components/composite/prompt-field/prompt-field.meta.yaml +60 -0
- package/src/components/composite/prompt-field/prompt-field.tsx +81 -0
- package/src/components/composite/properties/index.ts +9 -0
- package/src/components/composite/properties/properties.meta.yaml +56 -0
- package/src/components/composite/properties/properties.tsx +132 -0
- package/src/components/composite/snooze-menu/index.ts +11 -0
- package/src/components/composite/snooze-menu/presets.ts +169 -0
- package/src/components/composite/snooze-menu/snooze-menu.meta.yaml +58 -0
- package/src/components/composite/snooze-menu/snooze-menu.tsx +146 -0
- package/src/components/composite/tag-input/index.ts +2 -0
- package/src/components/composite/tag-input/tag-input.meta.yaml +51 -0
- package/src/components/composite/tag-input/tag-input.tsx +404 -0
- package/src/components/composite/wizard/index.ts +2 -0
- package/src/components/composite/wizard/wizard.meta.yaml +73 -0
- package/src/components/composite/wizard/wizard.tsx +256 -0
- package/src/components/core/avatar/avatar.meta.yaml +71 -0
- package/src/components/core/avatar/avatar.tsx +92 -0
- package/src/components/core/avatar/index.ts +2 -0
- package/src/components/core/badge/badge.meta.yaml +34 -0
- package/src/components/core/badge/badge.tsx +23 -0
- package/src/components/core/badge/index.ts +2 -0
- package/src/components/core/breadcrumb/breadcrumb.meta.yaml +45 -0
- package/src/components/core/breadcrumb/breadcrumb.tsx +110 -0
- package/src/components/core/breadcrumb/index.ts +2 -0
- package/src/components/core/bullets/bullets.meta.yaml +37 -0
- package/src/components/core/bullets/bullets.tsx +60 -0
- package/src/components/core/bullets/index.ts +2 -0
- package/src/components/core/button/button.meta.yaml +91 -0
- package/src/components/core/button/button.tsx +93 -0
- package/src/components/core/button/index.ts +2 -0
- package/src/components/core/card/card.meta.yaml +94 -0
- package/src/components/core/card/card.tsx +54 -0
- package/src/components/core/card/index.ts +2 -0
- package/src/components/core/checkbox/checkbox.meta.yaml +59 -0
- package/src/components/core/checkbox/checkbox.tsx +106 -0
- package/src/components/core/checkbox/index.ts +2 -0
- package/src/components/core/cluster/cluster.meta.yaml +4 -0
- package/src/components/core/cluster/cluster.tsx +17 -0
- package/src/components/core/cluster/index.ts +1 -0
- package/src/components/core/code-block/code-block.meta.yaml +30 -0
- package/src/components/core/code-block/code-block.tsx +93 -0
- package/src/components/core/code-block/index.ts +2 -0
- package/src/components/core/collapsible/collapsible.meta.yaml +34 -0
- package/src/components/core/collapsible/collapsible.tsx +54 -0
- package/src/components/core/collapsible/index.ts +1 -0
- package/src/components/core/colour-picker/colour-picker.meta.yaml +52 -0
- package/src/components/core/colour-picker/colour-picker.tsx +314 -0
- package/src/components/core/colour-picker/index.ts +4 -0
- package/src/components/core/combobox/combobox.meta.yaml +75 -0
- package/src/components/core/combobox/combobox.tsx +288 -0
- package/src/components/core/combobox/index.ts +2 -0
- package/src/components/core/detail/detail.meta.yaml +13 -0
- package/src/components/core/detail/detail.tsx +73 -0
- package/src/components/core/detail/index.ts +1 -0
- package/src/components/core/dialog/dialog.meta.yaml +95 -0
- package/src/components/core/dialog/dialog.tsx +254 -0
- package/src/components/core/dialog/drag.ts +40 -0
- package/src/components/core/dialog/index.ts +25 -0
- package/src/components/core/drop-zone/drop-zone.meta.yaml +55 -0
- package/src/components/core/drop-zone/drop-zone.tsx +146 -0
- package/src/components/core/drop-zone/index.ts +2 -0
- package/src/components/core/dropdown-menu/dropdown-menu.meta.yaml +118 -0
- package/src/components/core/dropdown-menu/dropdown-menu.tsx +407 -0
- package/src/components/core/dropdown-menu/index.ts +32 -0
- package/src/components/core/editable-field/editable-field.meta.yaml +120 -0
- package/src/components/core/editable-field/editable-field.tsx +346 -0
- package/src/components/core/editable-field/index.ts +2 -0
- package/src/components/core/empty-state/empty-state.meta.yaml +21 -0
- package/src/components/core/empty-state/empty-state.tsx +42 -0
- package/src/components/core/empty-state/index.ts +2 -0
- package/src/components/core/field/field.meta.yaml +37 -0
- package/src/components/core/field/field.tsx +100 -0
- package/src/components/core/field/index.ts +9 -0
- package/src/components/core/icon/curated-names.json +107 -0
- package/src/components/core/icon/icon-sets.ts +109 -0
- package/src/components/core/icon/icon.meta.yaml +30 -0
- package/src/components/core/icon/icon.tsx +93 -0
- package/src/components/core/icon/index.ts +2 -0
- package/src/components/core/input/index.ts +4 -0
- package/src/components/core/input/input.meta.yaml +98 -0
- package/src/components/core/input/input.tsx +133 -0
- package/src/components/core/input/textarea.meta.yaml +79 -0
- package/src/components/core/input/textarea.tsx +63 -0
- package/src/components/core/kbd/index.ts +2 -0
- package/src/components/core/kbd/kbd.meta.yaml +12 -0
- package/src/components/core/kbd/kbd.tsx +29 -0
- package/src/components/core/label/index.ts +2 -0
- package/src/components/core/label/label.meta.yaml +55 -0
- package/src/components/core/label/label.tsx +72 -0
- package/src/components/core/main-content/index.ts +2 -0
- package/src/components/core/main-content/main-content.meta.yaml +23 -0
- package/src/components/core/main-content/main-content.tsx +49 -0
- package/src/components/core/pane/index.ts +1 -0
- package/src/components/core/pane/pane.meta.yaml +13 -0
- package/src/components/core/pane/pane.tsx +64 -0
- package/src/components/core/pick-menu/index.ts +4 -0
- package/src/components/core/pick-menu/pick-menu.meta.yaml +36 -0
- package/src/components/core/pick-menu/pick-menu.tsx +348 -0
- package/src/components/core/pick-menu/tag-menu.meta.yaml +7 -0
- package/src/components/core/pick-menu/tag-menu.tsx +79 -0
- package/src/components/core/popover/index.ts +2 -0
- package/src/components/core/popover/popover.meta.yaml +16 -0
- package/src/components/core/popover/popover.tsx +66 -0
- package/src/components/core/progress/index.ts +2 -0
- package/src/components/core/progress/progress.meta.yaml +47 -0
- package/src/components/core/progress/progress.tsx +56 -0
- package/src/components/core/resizable/index.ts +13 -0
- package/src/components/core/resizable/resizable.meta.yaml +110 -0
- package/src/components/core/resizable/resizable.tsx +125 -0
- package/src/components/core/resizable/use-remembered-layout.ts +261 -0
- package/src/components/core/screen-link/index.ts +2 -0
- package/src/components/core/screen-link/screen-link.meta.yaml +34 -0
- package/src/components/core/screen-link/screen-link.tsx +100 -0
- package/src/components/core/scroll-area/index.ts +2 -0
- package/src/components/core/scroll-area/scroll-area.meta.yaml +72 -0
- package/src/components/core/scroll-area/scroll-area.tsx +95 -0
- package/src/components/core/scroll-area/steps.tsx +72 -0
- package/src/components/core/section/index.ts +2 -0
- package/src/components/core/section/section.meta.yaml +72 -0
- package/src/components/core/section/section.tsx +93 -0
- package/src/components/core/segment-group/index.ts +2 -0
- package/src/components/core/segment-group/segment-group.meta.yaml +71 -0
- package/src/components/core/segment-group/segment-group.tsx +166 -0
- package/src/components/core/select/index.ts +20 -0
- package/src/components/core/select/select.meta.yaml +48 -0
- package/src/components/core/select/select.tsx +226 -0
- package/src/components/core/skeleton/index.ts +2 -0
- package/src/components/core/skeleton/skeleton.meta.yaml +50 -0
- package/src/components/core/skeleton/skeleton.tsx +71 -0
- package/src/components/core/slider/index.ts +2 -0
- package/src/components/core/slider/slider.meta.yaml +55 -0
- package/src/components/core/slider/slider.tsx +46 -0
- package/src/components/core/sortable/index.ts +16 -0
- package/src/components/core/sortable/sortable.meta.yaml +125 -0
- package/src/components/core/sortable/sortable.tsx +471 -0
- package/src/components/core/split-view/index.ts +2 -0
- package/src/components/core/split-view/split-view.meta.yaml +85 -0
- package/src/components/core/split-view/split-view.tsx +193 -0
- package/src/components/core/status-icon/index.ts +2 -0
- package/src/components/core/status-icon/status-icon.meta.yaml +64 -0
- package/src/components/core/status-icon/status-icon.tsx +94 -0
- package/src/components/core/table/collapsible-rows.tsx +30 -0
- package/src/components/core/table/expand-toggle.tsx +58 -0
- package/src/components/core/table/group-header.tsx +35 -0
- package/src/components/core/table/index.ts +26 -0
- package/src/components/core/table/table.meta.yaml +67 -0
- package/src/components/core/table/table.tsx +166 -0
- package/src/components/core/tabs/index.ts +2 -0
- package/src/components/core/tabs/tabs.meta.yaml +57 -0
- package/src/components/core/tabs/tabs.tsx +74 -0
- package/src/components/core/tag-pill/index.ts +2 -0
- package/src/components/core/tag-pill/tag-pill.meta.yaml +19 -0
- package/src/components/core/tag-pill/tag-pill.tsx +102 -0
- package/src/components/core/thumbnail/index.ts +2 -0
- package/src/components/core/thumbnail/thumbnail.meta.yaml +59 -0
- package/src/components/core/thumbnail/thumbnail.tsx +162 -0
- package/src/components/core/toast/index.ts +12 -0
- package/src/components/core/toast/toast.meta.yaml +93 -0
- package/src/components/core/toast/toast.tsx +763 -0
- package/src/components/core/toggle/index.ts +2 -0
- package/src/components/core/toggle/toggle.meta.yaml +53 -0
- package/src/components/core/toggle/toggle.tsx +44 -0
- package/src/components/core/toggle-group/index.ts +2 -0
- package/src/components/core/toggle-group/toggle-group.meta.yaml +59 -0
- package/src/components/core/toggle-group/toggle-group.tsx +68 -0
- package/src/components/core/tooltip/index.ts +7 -0
- package/src/components/core/tooltip/tooltip.meta.yaml +93 -0
- package/src/components/core/tooltip/tooltip.tsx +198 -0
- package/src/components/layout/multi-pane/index.ts +4 -0
- package/src/components/layout/multi-pane/list-detail.tsx +45 -0
- package/src/components/layout/multi-pane/multi-pane.meta.yaml +67 -0
- package/src/components/layout/multi-pane/multi-pane.tsx +158 -0
- package/src/components/layout/single-pane/index.ts +2 -0
- package/src/components/layout/single-pane/single-pane.meta.yaml +35 -0
- package/src/components/layout/single-pane/single-pane.tsx +48 -0
- package/src/components/shell/app-shell/app-shell.meta.yaml +65 -0
- package/src/components/shell/app-shell/app-shell.tsx +61 -0
- package/src/components/shell/app-shell/index.ts +2 -0
- package/src/components/shell/sidebar/index.ts +35 -0
- package/src/components/shell/sidebar/sidebar-group.tsx +254 -0
- package/src/components/shell/sidebar/sidebar-item.tsx +88 -0
- package/src/components/shell/sidebar/sidebar-resize-handle.tsx +101 -0
- package/src/components/shell/sidebar/sidebar-tree.tsx +325 -0
- package/src/components/shell/sidebar/sidebar.meta.yaml +126 -0
- package/src/components/shell/sidebar/sidebar.tsx +142 -0
- package/src/components/template/address-book-template/address-book-template.meta.yaml +22 -0
- package/src/components/template/address-book-template/address-book-template.tsx +201 -0
- package/src/components/template/address-book-template/index.ts +2 -0
- package/src/components/template/mail-template/index.ts +2 -0
- package/src/components/template/mail-template/mail-template.meta.yaml +22 -0
- package/src/components/template/mail-template/mail-template.tsx +731 -0
- package/src/components/template/use-narrow.ts +18 -0
- package/src/index.ts +505 -0
- package/src/kit/check-rendering.tsx +130 -0
- package/src/kit/kit.tsx +177 -0
- package/src/lib/clipboard.ts +27 -0
- package/src/lib/dates.ts +13 -0
- package/src/lib/json.ts +59 -0
- package/src/lib/keys.ts +54 -0
- package/src/lib/utils.ts +12 -0
- package/src/lib/view-scope.tsx +60 -0
- package/src/profile/profile.ts +238 -0
- package/src/theme/appearance.ts +198 -0
- package/src/theme/boot.ts +6 -0
- package/src/theme/client-appearance-react.ts +14 -0
- package/src/theme/client-appearance.ts +284 -0
- package/src/theme/generate-tokens.ts +658 -0
- package/src/theme/pack-themes-react.ts +107 -0
- package/src/theme/palette.ts +301 -0
- package/src/theme/semantic-mapping.ts +165 -0
- package/src/theme/set-theme.ts +162 -0
- package/src/theme/theme-colours.ts +60 -0
- package/src/theme/theme-css.ts +15 -0
- package/src/theme/themes.ts +133 -0
- package/src/theme/wallpaper-sheet.ts +58 -0
- package/src/theme/wallpaper-theme-react.ts +60 -0
- package/src/theme/wallpaper-theme.ts +231 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Field as FieldPrimitive } from "@base-ui/react/field";
|
|
3
|
+
/** Set inside a Field: the kit's native controls (Input, Textarea, TagInput) then render through
|
|
4
|
+
* Base UI's Field.Control; FieldError reads `invalid` (Base UI's own error ignores that prop) and
|
|
5
|
+
* `disabled`, TagInput `disabled` for its chips. */
|
|
6
|
+
declare const FieldContext: React.Context<{
|
|
7
|
+
invalid: boolean;
|
|
8
|
+
disabled: boolean;
|
|
9
|
+
} | null>;
|
|
10
|
+
/** Inside a Field, wires a native control element (id, label, description, error, `aria-invalid`,
|
|
11
|
+
* the Field's `disabled`); outside one, returns it unchanged. For custom controls too. */
|
|
12
|
+
declare function useFieldControl(element: React.ReactElement<Record<string, unknown>>): React.JSX.Element;
|
|
13
|
+
interface FieldProps extends React.ComponentProps<typeof FieldPrimitive.Root> {
|
|
14
|
+
}
|
|
15
|
+
declare function Field({ className, invalid, disabled, ...props }: FieldProps): React.JSX.Element;
|
|
16
|
+
/** A form label (not the kit's coloured `Label` chip). */
|
|
17
|
+
interface FieldLabelProps extends React.ComponentProps<typeof FieldPrimitive.Label> {
|
|
18
|
+
}
|
|
19
|
+
declare function FieldLabel({ className, ...props }: FieldLabelProps): React.JSX.Element;
|
|
20
|
+
interface FieldDescriptionProps extends React.ComponentProps<typeof FieldPrimitive.Description> {
|
|
21
|
+
}
|
|
22
|
+
declare function FieldDescription({ className, ...props }: FieldDescriptionProps): React.JSX.Element;
|
|
23
|
+
/** Shown while the field is invalid (`<Field invalid>` with a message, or native validation), or
|
|
24
|
+
* with `match`; never on a disabled Field. */
|
|
25
|
+
interface FieldErrorProps extends React.ComponentProps<typeof FieldPrimitive.Error> {
|
|
26
|
+
}
|
|
27
|
+
declare function FieldError({ className, match, children, ...props }: FieldErrorProps): React.JSX.Element | null;
|
|
28
|
+
/** Fields side by side, sharing the line evenly (a first and a last name in a create dialog). */
|
|
29
|
+
declare function FieldRow({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
30
|
+
export { Field, FieldLabel, FieldDescription, FieldError, FieldRow, useFieldControl, FieldContext };
|
|
31
|
+
export type { FieldProps, FieldLabelProps, FieldDescriptionProps, FieldErrorProps };
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/** One icon as SVG data: its `viewBox`, and paths each with its fill ("currentColor" for the text colour). */
|
|
2
|
+
export interface IconData {
|
|
3
|
+
viewBox: string;
|
|
4
|
+
paths: readonly (readonly [fill: string, d: string])[];
|
|
5
|
+
}
|
|
6
|
+
export interface IconSet {
|
|
7
|
+
/** Lowercase letters, digits and dashes; "lucide" is the kit's own. */
|
|
8
|
+
id: string;
|
|
9
|
+
label: string;
|
|
10
|
+
/** By `Icon` name; a name the set lacks is drawn by Lucide. */
|
|
11
|
+
icons: Readonly<Record<string, IconData>>;
|
|
12
|
+
/** Pixel art: drawn with crisp edges. */
|
|
13
|
+
pixelated?: boolean;
|
|
14
|
+
}
|
|
15
|
+
/** Where the page keeps the chosen set; the boot kernel reads it before the first mount. */
|
|
16
|
+
export declare const ICON_SET_STORAGE_KEY = "bridge.icons";
|
|
17
|
+
export declare const DEFAULT_ICON_SET = "lucide";
|
|
18
|
+
/** The registered sets' ids. */
|
|
19
|
+
export declare const iconSetIds: () => string[];
|
|
20
|
+
/** Calls `listener` each time a set is registered or removed, until the returned function. */
|
|
21
|
+
export declare function onIconSetsChange(listener: () => void): () => void;
|
|
22
|
+
/** Registers a set, until the returned function removes it. Throws on a bad or taken id. */
|
|
23
|
+
export declare function registerIconSet(set: IconSet): () => void;
|
|
24
|
+
/** The chosen set's id (`<html data-icons>`), registered or not yet; "lucide" when none. */
|
|
25
|
+
export declare function getIconSet(): string;
|
|
26
|
+
/** Shows a set without remembering it (the Bridge default, `theme/appearance.ts`). */
|
|
27
|
+
export declare function applyIconSet(id: string): void;
|
|
28
|
+
/** Chooses a set for this browser and remembers it, "lucide" included: it overrides the Bridge default. A storage
|
|
29
|
+
* failure leaves it chosen for this page only. */
|
|
30
|
+
export declare function setIconSet(id: string): void;
|
|
31
|
+
/** The registered sets, outside React (the shell's look resolution: research-035). */
|
|
32
|
+
export declare const getIconSets: () => readonly IconSet[];
|
|
33
|
+
/** Calls `onChange` when a set comes or goes (or the choice changes); returns the unsubscribe. */
|
|
34
|
+
export declare const subscribeIconSets: (onChange: () => void) => () => void;
|
|
35
|
+
/** The registered sets, re-rendering the caller when one comes or goes. */
|
|
36
|
+
export declare function useIconSets(): readonly IconSet[];
|
|
37
|
+
/** The chosen set's id, re-rendering the caller when it changes. */
|
|
38
|
+
export declare function useIconSetId(): string;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type LucideProps } from "lucide-react";
|
|
2
|
+
/** The names `Icon` knows, sorted: every lucide icon (https://lucide.dev/icons), a few names of the kit's own, and
|
|
3
|
+
* `smartphone-off`, drawn by the kit. */
|
|
4
|
+
declare const ICON_NAMES: string[];
|
|
5
|
+
interface IconProps extends Omit<LucideProps, "ref"> {
|
|
6
|
+
/** A lucide name (`ICON_NAMES`); anything else (or nothing) shows the default `file` icon. */
|
|
7
|
+
name?: string | undefined;
|
|
8
|
+
}
|
|
9
|
+
/** A 16px navigation icon, decorative (`aria-hidden`), in the current text colour, from the chosen icon
|
|
10
|
+
* set (./icon-sets.ts). A set chosen but not registered yet (its plugin still loading) shows an empty box of
|
|
11
|
+
* the icon's size, so the page does not flash Lucide first; a name the set lacks is drawn by Lucide. */
|
|
12
|
+
declare function Icon({ name, size, ...props }: IconProps): import("react").JSX.Element;
|
|
13
|
+
export { Icon, ICON_NAMES };
|
|
14
|
+
export type { IconProps };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type VariantProps } from "class-variance-authority";
|
|
3
|
+
declare const inputVariants: (props?: ({
|
|
4
|
+
variant?: "inline" | "inline-description" | "inline-title" | "outline" | null | undefined;
|
|
5
|
+
size?: "default" | "lg" | "sm" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
interface InputProps extends Omit<React.ComponentProps<"input">, "size">, Omit<VariantProps<typeof inputVariants>, "variant"> {
|
|
8
|
+
/** Visual variant. Use the Textarea component for multi-line descriptions. */
|
|
9
|
+
variant?: "inline" | "inline-title" | "outline";
|
|
10
|
+
label?: string;
|
|
11
|
+
/** Icon element rendered inside the input, left-aligned. */
|
|
12
|
+
icon?: React.ReactNode;
|
|
13
|
+
/** Keyboard shortcut hint rendered inside the input, right-aligned (e.g., "⌘K"). */
|
|
14
|
+
shortcut?: string;
|
|
15
|
+
}
|
|
16
|
+
/** The autocomplete value that keeps the browser's autofill out (owner, 17 October 2026): Bridge's fields are rarely
|
|
17
|
+
* the user's own, and Chrome filled a new contact with their name and email. Chrome ignores "off" for addresses and
|
|
18
|
+
* names but fills no field whose autocomplete value it does not know (the Chromium team's advice). */
|
|
19
|
+
declare const noAutofill = "bridge-no-autofill";
|
|
20
|
+
declare function Input({ className, type, variant, size, label, icon, shortcut, id: idProp, ...props }: InputProps): React.JSX.Element;
|
|
21
|
+
export { Input, inputVariants, noAutofill };
|
|
22
|
+
export type { InputProps };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
interface TextareaProps extends Omit<React.ComponentProps<"textarea">, "children"> {
|
|
3
|
+
/** `default`: borderless (inline description); `outline`: bordered like `Input variant="outline"`. */
|
|
4
|
+
variant?: "default" | "outline";
|
|
5
|
+
}
|
|
6
|
+
declare function Textarea({ className, onInput, ref: externalRef, value, variant, ...props }: TextareaProps): React.JSX.Element;
|
|
7
|
+
export { Textarea };
|
|
8
|
+
export type { TextareaProps };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type VariantProps } from "class-variance-authority";
|
|
3
|
+
declare const labelVariants: (props?: ({
|
|
4
|
+
variant?: "bug" | "feature" | "improvement" | null | undefined;
|
|
5
|
+
shape?: "round" | "square" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
type LabelVariant = "bug" | "feature" | "improvement";
|
|
8
|
+
interface LabelProps extends React.ComponentProps<"span">, VariantProps<typeof labelVariants> {
|
|
9
|
+
color?: string;
|
|
10
|
+
}
|
|
11
|
+
declare function Label({ className, variant, shape, color, children, style, ...props }: LabelProps): React.JSX.Element;
|
|
12
|
+
export { Label, labelVariants };
|
|
13
|
+
export type { LabelProps, LabelVariant };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare const widths: {
|
|
3
|
+
/** A column to read: a record, settings, a document. */
|
|
4
|
+
readonly read: "max-w-[800px]";
|
|
5
|
+
/** A wider column: a page of samples, settings with two columns. */
|
|
6
|
+
readonly wide: "max-w-[1120px]";
|
|
7
|
+
/** The whole width: a large table, a dashboard. */
|
|
8
|
+
readonly full: "";
|
|
9
|
+
};
|
|
10
|
+
interface MainContentProps extends React.ComponentProps<"div"> {
|
|
11
|
+
/** `read` (default): a column of 720px at most; `wide`: 1040px; `full`: the whole width. Narrow, all take the width. */
|
|
12
|
+
width?: keyof typeof widths;
|
|
13
|
+
}
|
|
14
|
+
/** The main pane's content: its margins (16px, 40px from 640px of pane), its column centred. Its props go to the
|
|
15
|
+
* column (`aria-label`, `className`). */
|
|
16
|
+
declare function MainContent({ width, className, children, ...props }: MainContentProps): React.JSX.Element;
|
|
17
|
+
export { MainContent };
|
|
18
|
+
export type { MainContentProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Pane, PaneHeader, PaneBody, PaneFooter, PaneNote } from "./pane";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { ScrollArea } from "../scroll-area";
|
|
3
|
+
declare function Pane({ className, ...props }: React.ComponentProps<"section">): React.JSX.Element;
|
|
4
|
+
/** The pane's toolbar: its first control (a search, or the KeyHint around it) grows. */
|
|
5
|
+
declare function PaneHeader({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
6
|
+
/** The pane's scrolling body. */
|
|
7
|
+
declare function PaneBody({ className, ...props }: React.ComponentProps<typeof ScrollArea>): React.JSX.Element;
|
|
8
|
+
/** The pane's footer: a count, its filters, the selection (a `strong` stands out); muted, tabular figures. */
|
|
9
|
+
declare function PaneFooter({ className, ...props }: React.ComponentProps<"footer">): React.JSX.Element;
|
|
10
|
+
/** A list's last line ("Loading…" while its next page waits); a ref on it loads that page once in view. */
|
|
11
|
+
declare function PaneNote({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
|
|
12
|
+
export { Pane, PaneHeader, PaneBody, PaneFooter, PaneNote };
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
interface PickOption {
|
|
3
|
+
key: string;
|
|
4
|
+
label: string;
|
|
5
|
+
/** Before the label (a tag's dot, an avatar). */
|
|
6
|
+
icon?: React.ReactNode;
|
|
7
|
+
/** After the label, quieter (a count, a website). */
|
|
8
|
+
note?: string;
|
|
9
|
+
checked?: boolean;
|
|
10
|
+
/** The "none" choice ("No organization"): first, shown whatever is typed, picked with 0. */
|
|
11
|
+
none?: boolean;
|
|
12
|
+
}
|
|
13
|
+
interface PickMenuProps {
|
|
14
|
+
open: boolean;
|
|
15
|
+
onOpenChange: (open: boolean) => void;
|
|
16
|
+
/** What it opens next to. */
|
|
17
|
+
anchor: Element | null;
|
|
18
|
+
options: readonly PickOption[];
|
|
19
|
+
onPick: (option: PickOption) => void;
|
|
20
|
+
/** Checkboxes, and the menu stays open after a pick. */
|
|
21
|
+
multiple?: boolean;
|
|
22
|
+
/** Offers "Create “text”" for a typed text no option's label is (any case). */
|
|
23
|
+
onCreate?: (text: string) => void;
|
|
24
|
+
placeholder?: string;
|
|
25
|
+
/** The caller searches (a server) as one types: `options` are its answer for the text, not filtered here. */
|
|
26
|
+
onSearch?: (text: string) => void;
|
|
27
|
+
/** Said when no option shows ("No match" by default): a search on its way, or its failure. */
|
|
28
|
+
emptyText?: string;
|
|
29
|
+
/** Under the options, quieter ("Enter toggles · Esc closes"). */
|
|
30
|
+
footer?: React.ReactNode;
|
|
31
|
+
"aria-label"?: string;
|
|
32
|
+
}
|
|
33
|
+
declare function PickMenu({ open, onOpenChange, anchor, options, onPick, multiple, onCreate, placeholder, onSearch, emptyText, footer, "aria-label": ariaLabel, }: PickMenuProps): React.JSX.Element | null;
|
|
34
|
+
interface DataMenuTriggerProps extends React.ComponentProps<"button"> {
|
|
35
|
+
/** Nothing chosen yet ("Set organization"): muted. */
|
|
36
|
+
empty?: boolean;
|
|
37
|
+
/** Height, as Button's and Input's (h-sm, h-md, h-lg). Defaults to `default` (h-md). */
|
|
38
|
+
size?: "sm" | "default" | "lg" | undefined;
|
|
39
|
+
}
|
|
40
|
+
/** A data menu's trigger, as Linear's properties: an icon and a label, no border, a background on hover; an input's height and text, so it lines up with the fields beside. Its icon
|
|
41
|
+
* sits on the value column's edge. */
|
|
42
|
+
declare function DataMenuTrigger({ empty, size, className, type, ...props }: DataMenuTriggerProps): React.JSX.Element;
|
|
43
|
+
interface PickSelectProps {
|
|
44
|
+
value: string;
|
|
45
|
+
options: readonly Omit<PickOption, "checked">[];
|
|
46
|
+
onChange: (key: string) => void;
|
|
47
|
+
/** The pill's and the menu's accessible name. */
|
|
48
|
+
"aria-label": string;
|
|
49
|
+
disabled?: boolean;
|
|
50
|
+
/** Its trigger's height (DataMenuTrigger's `size`). */
|
|
51
|
+
size?: DataMenuTriggerProps["size"];
|
|
52
|
+
className?: string;
|
|
53
|
+
}
|
|
54
|
+
/** Linear's data menu for one value among a few (an email's kind): its trigger, a PickMenu on its checked option. */
|
|
55
|
+
declare function PickSelect({ value, options, onChange, disabled, size, className, ...props }: PickSelectProps): React.JSX.Element;
|
|
56
|
+
export { DataMenuTrigger, PickMenu, PickSelect };
|
|
57
|
+
export type { DataMenuTriggerProps, PickMenuProps, PickOption, PickSelectProps };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
interface TagCount {
|
|
3
|
+
value: string;
|
|
4
|
+
count: number;
|
|
5
|
+
}
|
|
6
|
+
interface TagMenuProps {
|
|
7
|
+
open: boolean;
|
|
8
|
+
onOpenChange: (open: boolean) => void;
|
|
9
|
+
anchor: Element | null;
|
|
10
|
+
/** The record's tags. */
|
|
11
|
+
value: readonly string[];
|
|
12
|
+
/** Adds or removes `tag` (any case). */
|
|
13
|
+
onToggle: (tag: string) => void;
|
|
14
|
+
/** The known tags with their counts, asked each time the menu opens (a failure keeps the last ones). */
|
|
15
|
+
load: () => Promise<TagCount[]>;
|
|
16
|
+
}
|
|
17
|
+
declare function TagMenu({ open, onOpenChange, anchor, value, onToggle, load }: TagMenuProps): React.JSX.Element;
|
|
18
|
+
export { TagMenu };
|
|
19
|
+
export type { TagMenuProps, TagCount };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Popover as PopoverPrimitive } from "@base-ui/react/popover";
|
|
3
|
+
interface PopoverProps extends React.ComponentProps<typeof PopoverPrimitive.Root> {
|
|
4
|
+
}
|
|
5
|
+
declare function Popover(props: PopoverProps): React.JSX.Element;
|
|
6
|
+
interface PopoverTriggerProps extends React.ComponentProps<typeof PopoverPrimitive.Trigger> {
|
|
7
|
+
}
|
|
8
|
+
declare function PopoverTrigger(props: PopoverTriggerProps): React.JSX.Element;
|
|
9
|
+
interface PopoverContentProps extends React.ComponentProps<typeof PopoverPrimitive.Popup> {
|
|
10
|
+
/** Which side of the trigger to open on; it flips when there is no room (lives on Base UI's Positioner). */
|
|
11
|
+
side?: React.ComponentProps<typeof PopoverPrimitive.Positioner>["side"];
|
|
12
|
+
/** Alignment against the trigger (lives on Base UI's Positioner). */
|
|
13
|
+
align?: React.ComponentProps<typeof PopoverPrimitive.Positioner>["align"];
|
|
14
|
+
/** Distance from the trigger in px (lives on Base UI's Positioner). */
|
|
15
|
+
sideOffset?: React.ComponentProps<typeof PopoverPrimitive.Positioner>["sideOffset"];
|
|
16
|
+
/** Minimum distance from the viewport edges in px (lives on Base UI's Positioner). */
|
|
17
|
+
collisionPadding?: React.ComponentProps<typeof PopoverPrimitive.Positioner>["collisionPadding"];
|
|
18
|
+
}
|
|
19
|
+
/** The panel, in a portal: never taller than the room the viewport leaves on its side. */
|
|
20
|
+
declare function PopoverContent({ className, side, align, sideOffset, collisionPadding, ...props }: PopoverContentProps): React.JSX.Element;
|
|
21
|
+
export { Popover, PopoverTrigger, PopoverContent };
|
|
22
|
+
export type { PopoverProps, PopoverTriggerProps, PopoverContentProps };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
interface ProgressProps extends Omit<React.ComponentProps<"div">, "value"> {
|
|
3
|
+
/** How far along, 0 to 1; absent: indeterminate (an animated bar). */
|
|
4
|
+
value?: number;
|
|
5
|
+
/** The bar's accessible name. */
|
|
6
|
+
label?: string;
|
|
7
|
+
size?: "sm" | "md";
|
|
8
|
+
tone?: "default" | "danger";
|
|
9
|
+
}
|
|
10
|
+
/** A horizontal progress bar: determinate from `value` (clamped to 0..1), or indeterminate and animated. */
|
|
11
|
+
declare function Progress({ value, label, size, tone, className, ...props }: ProgressProps): React.JSX.Element;
|
|
12
|
+
export { Progress };
|
|
13
|
+
export type { ProgressProps };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { useGroupRef, usePanelRef, type GroupProps, type PanelImperativeHandle, type PanelProps, type SeparatorProps } from "react-resizable-panels";
|
|
3
|
+
type ResizablePanelGroupProps = GroupProps;
|
|
4
|
+
declare function ResizablePanelGroup({ className, ...props }: ResizablePanelGroupProps): React.JSX.Element;
|
|
5
|
+
type ResizablePanelProps = PanelProps;
|
|
6
|
+
declare function ResizablePanel({ style, ...props }: ResizablePanelProps): React.JSX.Element;
|
|
7
|
+
interface ResizableHandleProps extends Omit<SeparatorProps, "onDoubleClick"> {
|
|
8
|
+
/** Show a visible grip indicator on the handle */
|
|
9
|
+
withHandle?: boolean;
|
|
10
|
+
/** Replaces the library's own double-click (a panel back to its defaultSize), e.g. toggling two widths. */
|
|
11
|
+
onDoubleClick?: () => void;
|
|
12
|
+
}
|
|
13
|
+
declare function ResizableHandle({ className, withHandle, onDoubleClick, ...props }: ResizableHandleProps): React.JSX.Element;
|
|
14
|
+
export { ResizablePanelGroup, ResizablePanel, ResizableHandle, useGroupRef, usePanelRef };
|
|
15
|
+
export type { PanelImperativeHandle, ResizablePanelGroupProps, ResizablePanelProps, ResizableHandleProps, };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { useGroupRef } from "./resizable";
|
|
3
|
+
/** A group's layout: each panel's id to its percentage. */
|
|
4
|
+
export type PaneLayout = Record<string, number>;
|
|
5
|
+
/** A pane's id and starting size (`"280px"`, `"25%"`; none: a share of what the sized panes leave). */
|
|
6
|
+
export interface PaneStart {
|
|
7
|
+
id: string;
|
|
8
|
+
size?: string | undefined;
|
|
9
|
+
}
|
|
10
|
+
/** The starting layout in percentages: px over the group's `length`, %, the rest shared by the unsized panes. The
|
|
11
|
+
* library reads a string given to a panel's `resize` as a percentage, so px are converted here. */
|
|
12
|
+
export declare function startingLayout(panes: PaneStart[], length: number): PaneLayout;
|
|
13
|
+
export interface RememberedLayout {
|
|
14
|
+
/** The sizes kept for this workspace: the group's starting layout; `undefined` without a key or a workspace. */
|
|
15
|
+
defaultLayout: PaneLayout | undefined;
|
|
16
|
+
/** The group's handle, to apply kept sizes after mount. */
|
|
17
|
+
groupRef: ReturnType<typeof useGroupRef>;
|
|
18
|
+
/** The group's element: its size, for the starting layout; its growing brings the kept sizes back. */
|
|
19
|
+
elementRef: React.RefObject<HTMLDivElement | null>;
|
|
20
|
+
/** The library's moves: tells a drag from a box that shrank. */
|
|
21
|
+
onLayoutChange: () => void;
|
|
22
|
+
/** Keeps `layout` after a drag or a key on the edge. */
|
|
23
|
+
onLayoutChanged: (layout: PaneLayout) => void;
|
|
24
|
+
/** The edge's double-click: forgets the workspace's sizes and brings the starting ones back. */
|
|
25
|
+
forget: () => void;
|
|
26
|
+
}
|
|
27
|
+
/** A group's sizes remembered per workspace under `storageKey` (none: nothing is read or kept); `starts` gives its
|
|
28
|
+
* panes' ids and starting sizes, `orientation` which side of its box they share. */
|
|
29
|
+
export declare function useRememberedLayout(storageKey: string | undefined, starts: () => PaneStart[], orientation?: "horizontal" | "vertical",
|
|
30
|
+
/** Whether the layout may be kept now (SplitView: every pane named, a generated id changes at a remount). */
|
|
31
|
+
canKeep?: () => boolean): RememberedLayout;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
/** What a click asks for: here, beside, on a new desk; `undefined`, nothing to follow (⇧, a right click). */
|
|
3
|
+
type Gesture = "here" | "beside" | "desk";
|
|
4
|
+
/** The part of a mouse or keyboard event a gesture is read from (a key's Enter: no `button`, a plain click). */
|
|
5
|
+
interface FollowEvent {
|
|
6
|
+
type?: string;
|
|
7
|
+
button?: number;
|
|
8
|
+
metaKey: boolean;
|
|
9
|
+
ctrlKey: boolean;
|
|
10
|
+
altKey: boolean;
|
|
11
|
+
shiftKey: boolean;
|
|
12
|
+
}
|
|
13
|
+
/** Where a link goes: an item of the screen its window shows (`reuse`: a plain click shows it in another window of
|
|
14
|
+
* that screen when there is one, as `ctx.screen.open`'s hint), or a view of the workspace (a node, a screen there, its
|
|
15
|
+
* item). */
|
|
16
|
+
type FollowTarget = {
|
|
17
|
+
item?: string;
|
|
18
|
+
reuse?: boolean;
|
|
19
|
+
} | {
|
|
20
|
+
node: string;
|
|
21
|
+
screen?: {
|
|
22
|
+
plugin: string;
|
|
23
|
+
id: string;
|
|
24
|
+
};
|
|
25
|
+
item?: string;
|
|
26
|
+
};
|
|
27
|
+
/** What the shell provides around each window (`FollowProvider`): follows a target as the event asks, and gives its
|
|
28
|
+
* URL (`undefined`: none yet, the screen tree loading). */
|
|
29
|
+
interface Follow {
|
|
30
|
+
follow: (target: FollowTarget, event: FollowEvent) => void;
|
|
31
|
+
href: (target: FollowTarget) => string | undefined;
|
|
32
|
+
}
|
|
33
|
+
/** The gesture an event asks for. */
|
|
34
|
+
declare function gestureOf(event: FollowEvent): Gesture | undefined;
|
|
35
|
+
/** The shell's, around a window's view. */
|
|
36
|
+
declare function FollowProvider({ value, children }: {
|
|
37
|
+
value: Follow;
|
|
38
|
+
children: React.ReactNode;
|
|
39
|
+
}): React.JSX.Element;
|
|
40
|
+
/** The shell's `Follow` for the window this renders in; `null` outside a shell (a test, a page of its own). A row or a
|
|
41
|
+
* button calls `follow(target, event)` from its `onClick` (and `onAuxClick`, a middle click), never a screen change of
|
|
42
|
+
* its own that ignores the event. */
|
|
43
|
+
declare function useFollow(): Follow | null;
|
|
44
|
+
interface ScreenLinkProps extends Omit<React.ComponentProps<"a">, "href"> {
|
|
45
|
+
/** Where it goes. */
|
|
46
|
+
to: FollowTarget;
|
|
47
|
+
}
|
|
48
|
+
/** A link to a screen: an anchor with a real `href` (copied, opened in a browser tab from its menu), whose clicks
|
|
49
|
+
* follow Bridge's rule. Outside a shell: an anchor without `href`, its own `onClick` alone. */
|
|
50
|
+
declare function ScreenLink({ to, className, onClick, onAuxClick, ...props }: ScreenLinkProps): React.JSX.Element;
|
|
51
|
+
export { ScreenLink, FollowProvider, useFollow, gestureOf };
|
|
52
|
+
export type { ScreenLinkProps, Follow, FollowEvent, FollowTarget, Gesture };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { ScrollArea as ScrollAreaPrimitive } from "@base-ui/react/scroll-area";
|
|
3
|
+
interface ScrollAreaProps extends React.ComponentProps<typeof ScrollAreaPrimitive.Root> {
|
|
4
|
+
orientation?: "vertical" | "horizontal" | "both";
|
|
5
|
+
viewportClassName?: string;
|
|
6
|
+
viewportRef?: React.Ref<HTMLDivElement>;
|
|
7
|
+
}
|
|
8
|
+
declare function ScrollArea({ className, orientation, viewportClassName, viewportRef, children, ...props }: ScrollAreaProps): React.JSX.Element;
|
|
9
|
+
interface ScrollAreaScrollbarProps extends React.ComponentProps<typeof ScrollAreaPrimitive.Scrollbar> {
|
|
10
|
+
}
|
|
11
|
+
declare function ScrollAreaScrollbar({ className, orientation, ...props }: ScrollAreaScrollbarProps): React.JSX.Element;
|
|
12
|
+
export { ScrollArea, ScrollAreaScrollbar };
|
|
13
|
+
export type { ScrollAreaProps, ScrollAreaScrollbarProps };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type VariantProps } from "class-variance-authority";
|
|
3
|
+
declare const sectionVariants: (props?: ({
|
|
4
|
+
size?: "default" | "lg" | "sm" | null | undefined;
|
|
5
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
6
|
+
interface SectionProps extends Omit<React.ComponentProps<"section">, "title">, VariantProps<typeof sectionVariants> {
|
|
7
|
+
/** The heading: h2 at `lg`, h3 at `default`, h4 at `sm`. Names the section. */
|
|
8
|
+
title: React.ReactNode;
|
|
9
|
+
/** A line under the title. */
|
|
10
|
+
description?: React.ReactNode;
|
|
11
|
+
/** At the header's end (a search field, a button). */
|
|
12
|
+
actions?: React.ReactNode;
|
|
13
|
+
}
|
|
14
|
+
declare function Section({ className, size, title, description, actions, children, ...props }: SectionProps): React.JSX.Element;
|
|
15
|
+
export { Section, sectionVariants };
|
|
16
|
+
export type { SectionProps };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type VariantProps } from "class-variance-authority";
|
|
3
|
+
declare const segmentGroupVariants: (props?: ({
|
|
4
|
+
fullWidth?: boolean | null | undefined;
|
|
5
|
+
size?: "default" | "lg" | "sm" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
/** A segment's padding and text at each size, shared with ToggleGroup's items. */
|
|
8
|
+
declare const segmentItemSizes: {
|
|
9
|
+
readonly sm: "px-1.5 text-xs";
|
|
10
|
+
readonly default: "px-2 text-xs";
|
|
11
|
+
readonly lg: "px-2.5 text-sm";
|
|
12
|
+
};
|
|
13
|
+
interface SegmentGroupItem {
|
|
14
|
+
value: string;
|
|
15
|
+
label: React.ReactNode;
|
|
16
|
+
}
|
|
17
|
+
interface SegmentGroupProps extends React.ComponentProps<"div">, VariantProps<typeof segmentGroupVariants> {
|
|
18
|
+
items: SegmentGroupItem[];
|
|
19
|
+
value: string;
|
|
20
|
+
onValueChange: (value: string) => void;
|
|
21
|
+
}
|
|
22
|
+
declare function SegmentGroup({ className, fullWidth, size, items, value, onValueChange, ...props }: SegmentGroupProps): React.JSX.Element;
|
|
23
|
+
export { SegmentGroup, segmentGroupVariants, segmentItemSizes };
|
|
24
|
+
export type { SegmentGroupProps, SegmentGroupItem };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { Select, SelectTrigger, SelectValue, SelectContent, SelectItem, SelectGroup, SelectLabel, SelectSeparator, } from "./select";
|
|
2
|
+
export type { SelectProps, SelectTriggerProps, SelectValueProps, SelectContentProps, SelectItemProps, SelectGroupProps, SelectLabelProps, SelectSeparatorProps, } from "./select";
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Select as SelectPrimitive } from "@base-ui/react/select";
|
|
3
|
+
declare const Select: typeof SelectPrimitive.Root;
|
|
4
|
+
type SelectProps<Value = unknown, Multiple extends boolean | undefined = false> = SelectPrimitive.Root.Props<Value, Multiple>;
|
|
5
|
+
interface SelectTriggerProps extends React.ComponentProps<typeof SelectPrimitive.Trigger> {
|
|
6
|
+
/** Height, as `Input variant="outline"` (h-sm, h-md, h-lg). Defaults to `default` (h-md), as Button and Input: a form that wants h-lg sets `lg` on each of its controls. */
|
|
7
|
+
size?: "sm" | "default" | "lg";
|
|
8
|
+
}
|
|
9
|
+
declare function SelectTrigger({ className, size, children, ...props }: SelectTriggerProps): React.JSX.Element;
|
|
10
|
+
interface SelectValueProps extends React.ComponentProps<typeof SelectPrimitive.Value> {
|
|
11
|
+
}
|
|
12
|
+
declare function SelectValue({ className, ...props }: SelectValueProps): React.JSX.Element;
|
|
13
|
+
interface SelectContentProps extends React.ComponentProps<typeof SelectPrimitive.Popup> {
|
|
14
|
+
/** Distance from the trigger in px (lives on Base UI's Positioner) */
|
|
15
|
+
sideOffset?: SelectPrimitive.Positioner.Props["sideOffset"];
|
|
16
|
+
/** Alignment against the trigger (lives on Base UI's Positioner) */
|
|
17
|
+
align?: SelectPrimitive.Positioner.Props["align"];
|
|
18
|
+
/** Which side of the trigger to position against (lives on Base UI's Positioner) */
|
|
19
|
+
side?: SelectPrimitive.Positioner.Props["side"];
|
|
20
|
+
/** Offset along the alignment axis (lives on Base UI's Positioner) */
|
|
21
|
+
alignOffset?: SelectPrimitive.Positioner.Props["alignOffset"];
|
|
22
|
+
/** Overlay the selected item on the trigger (macOS style) instead of dropping below it, as DropdownMenu does. */
|
|
23
|
+
alignItemWithTrigger?: SelectPrimitive.Positioner.Props["alignItemWithTrigger"];
|
|
24
|
+
}
|
|
25
|
+
declare function SelectContent({ className, children, sideOffset, align, side, alignOffset, alignItemWithTrigger, ...props }: SelectContentProps): React.JSX.Element;
|
|
26
|
+
interface SelectItemProps extends React.ComponentProps<typeof SelectPrimitive.Item> {
|
|
27
|
+
}
|
|
28
|
+
declare function SelectItem({ className, children, ...props }: SelectItemProps): React.JSX.Element;
|
|
29
|
+
interface SelectGroupProps extends React.ComponentProps<typeof SelectPrimitive.Group> {
|
|
30
|
+
}
|
|
31
|
+
declare function SelectGroup({ className, ...props }: SelectGroupProps): React.JSX.Element;
|
|
32
|
+
interface SelectLabelProps extends React.ComponentProps<typeof SelectPrimitive.GroupLabel> {
|
|
33
|
+
}
|
|
34
|
+
declare function SelectLabel({ className, ...props }: SelectLabelProps): React.JSX.Element;
|
|
35
|
+
interface SelectSeparatorProps extends React.ComponentProps<typeof SelectPrimitive.Separator> {
|
|
36
|
+
}
|
|
37
|
+
declare function SelectSeparator({ className, ...props }: SelectSeparatorProps): React.JSX.Element;
|
|
38
|
+
export { Select, SelectTrigger, SelectValue, SelectContent, SelectItem, SelectGroup, SelectLabel, SelectSeparator, };
|
|
39
|
+
export type { SelectProps, SelectTriggerProps, SelectValueProps, SelectContentProps, SelectItemProps, SelectGroupProps, SelectLabelProps, SelectSeparatorProps, };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
interface SkeletonProps extends React.ComponentProps<"div"> {
|
|
3
|
+
/** Draw a circle instead of the default rounded rectangle (e.g. an avatar's place). */
|
|
4
|
+
round?: boolean;
|
|
5
|
+
}
|
|
6
|
+
/** A pulsing placeholder block. Purely presentational; its size comes from `className`. */
|
|
7
|
+
declare function Skeleton({ className, round, ...props }: SkeletonProps): React.JSX.Element;
|
|
8
|
+
/** A list loading: eight rows (an avatar, a name, a line). */
|
|
9
|
+
declare function ListSkeleton(): React.JSX.Element;
|
|
10
|
+
/** A record page loading: its header (an avatar, a title, a line), then five rows (a label, a value). */
|
|
11
|
+
declare function DetailSkeleton(): React.JSX.Element;
|
|
12
|
+
export { Skeleton, ListSkeleton, DetailSkeleton };
|
|
13
|
+
export type { SkeletonProps };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Slider as SliderPrimitive } from "@base-ui/react/slider";
|
|
3
|
+
interface SliderProps extends Omit<React.ComponentProps<typeof SliderPrimitive.Root<number>>, "render"> {
|
|
4
|
+
}
|
|
5
|
+
/** One value on a range: a 6px track filled in the accent up to a 16px thumb, as wide as its
|
|
6
|
+
* container (min 160px); its label goes to the thumb's input. */
|
|
7
|
+
declare function Slider({ className, "aria-label": label, "aria-labelledby": labelledBy, ...props }: SliderProps): React.JSX.Element;
|
|
8
|
+
export { Slider };
|
|
9
|
+
export type { SliderProps };
|