@kjun-ui/react 0.20.0 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -5
- package/dist/index.cjs +11354 -4458
- package/dist/index.js +10951 -4033
- package/dist/styles.css +3948 -738
- package/dist/types/packages/react/src/actions.d.cts +21 -16
- package/dist/types/packages/react/src/actions.d.ts +21 -16
- package/dist/types/packages/react/src/app-navigation.d.cts +14 -5
- package/dist/types/packages/react/src/app-navigation.d.ts +14 -5
- package/dist/types/packages/react/src/avatar-group.d.cts +36 -0
- package/dist/types/packages/react/src/avatar-group.d.ts +36 -0
- package/dist/types/packages/react/src/button.d.cts +14 -6
- package/dist/types/packages/react/src/button.d.ts +14 -6
- package/dist/types/packages/react/src/calendar.d.cts +6 -2
- package/dist/types/packages/react/src/calendar.d.ts +6 -2
- package/dist/types/packages/react/src/card-actions-context.d.cts +2 -0
- package/dist/types/packages/react/src/card-actions-context.d.ts +2 -0
- package/dist/types/packages/react/src/card.d.cts +23 -6
- package/dist/types/packages/react/src/card.d.ts +23 -6
- package/dist/types/packages/react/src/carousel.d.cts +8 -1
- package/dist/types/packages/react/src/carousel.d.ts +8 -1
- package/dist/types/packages/react/src/chip.d.cts +4 -2
- package/dist/types/packages/react/src/chip.d.ts +4 -2
- package/dist/types/packages/react/src/choice-controls.d.cts +99 -0
- package/dist/types/packages/react/src/choice-controls.d.ts +99 -0
- package/dist/types/packages/react/src/collapse.d.cts +4 -1
- package/dist/types/packages/react/src/collapse.d.ts +4 -1
- package/dist/types/packages/react/src/color-picker-parts.d.cts +58 -0
- package/dist/types/packages/react/src/color-picker-parts.d.ts +58 -0
- package/dist/types/packages/react/src/color-picker.d.cts +58 -0
- package/dist/types/packages/react/src/color-picker.d.ts +58 -0
- package/dist/types/packages/react/src/combobox.d.cts +18 -5
- package/dist/types/packages/react/src/combobox.d.ts +18 -5
- package/dist/types/packages/react/src/controls.d.cts +7 -74
- package/dist/types/packages/react/src/controls.d.ts +7 -74
- package/dist/types/packages/react/src/data-state.d.cts +22 -9
- package/dist/types/packages/react/src/data-state.d.ts +22 -9
- package/dist/types/packages/react/src/date-picker.d.cts +8 -2
- package/dist/types/packages/react/src/date-picker.d.ts +8 -2
- package/dist/types/packages/react/src/display.d.cts +40 -11
- package/dist/types/packages/react/src/display.d.ts +40 -11
- package/dist/types/packages/react/src/drawer.d.cts +11 -2
- package/dist/types/packages/react/src/drawer.d.ts +11 -2
- package/dist/types/packages/react/src/dropdown.d.cts +19 -5
- package/dist/types/packages/react/src/dropdown.d.ts +19 -5
- package/dist/types/packages/react/src/event-calendar.d.cts +47 -0
- package/dist/types/packages/react/src/event-calendar.d.ts +47 -0
- package/dist/types/packages/react/src/fab.d.cts +18 -7
- package/dist/types/packages/react/src/fab.d.ts +18 -7
- package/dist/types/packages/react/src/file-upload-row.d.cts +23 -0
- package/dist/types/packages/react/src/file-upload-row.d.ts +23 -0
- package/dist/types/packages/react/src/file-upload.d.cts +38 -0
- package/dist/types/packages/react/src/file-upload.d.ts +38 -0
- package/dist/types/packages/react/src/financial-display.d.cts +32 -11
- package/dist/types/packages/react/src/financial-display.d.ts +32 -11
- package/dist/types/packages/react/src/floating-panel.d.cts +6 -2
- package/dist/types/packages/react/src/floating-panel.d.ts +6 -2
- package/dist/types/packages/react/src/index.d.cts +16 -1
- package/dist/types/packages/react/src/index.d.ts +16 -1
- package/dist/types/packages/react/src/input.d.cts +14 -1
- package/dist/types/packages/react/src/input.d.ts +14 -1
- package/dist/types/packages/react/src/kpi-hero.d.cts +55 -0
- package/dist/types/packages/react/src/kpi-hero.d.ts +55 -0
- package/dist/types/packages/react/src/kpi-row.d.cts +46 -0
- package/dist/types/packages/react/src/kpi-row.d.ts +46 -0
- package/dist/types/packages/react/src/kpi.d.cts +2 -72
- package/dist/types/packages/react/src/kpi.d.ts +2 -72
- package/dist/types/packages/react/src/layout-primitives.d.cts +71 -139
- package/dist/types/packages/react/src/layout-primitives.d.ts +71 -139
- package/dist/types/packages/react/src/list-context.d.cts +9 -0
- package/dist/types/packages/react/src/list-context.d.ts +9 -0
- package/dist/types/packages/react/src/list.d.cts +84 -11
- package/dist/types/packages/react/src/list.d.ts +84 -11
- package/dist/types/packages/react/src/market-model.d.cts +13 -1
- package/dist/types/packages/react/src/market-model.d.ts +13 -1
- package/dist/types/packages/react/src/market-parts.d.cts +9 -0
- package/dist/types/packages/react/src/market-parts.d.ts +9 -0
- package/dist/types/packages/react/src/market-skeleton.d.cts +7 -1
- package/dist/types/packages/react/src/market-skeleton.d.ts +7 -1
- package/dist/types/packages/react/src/media.d.cts +6 -2
- package/dist/types/packages/react/src/media.d.ts +6 -2
- package/dist/types/packages/react/src/modal.d.cts +14 -2
- package/dist/types/packages/react/src/modal.d.ts +14 -2
- package/dist/types/packages/react/src/navigation.d.cts +36 -6
- package/dist/types/packages/react/src/navigation.d.ts +36 -6
- package/dist/types/packages/react/src/number-display.d.cts +10 -5
- package/dist/types/packages/react/src/number-display.d.ts +10 -5
- package/dist/types/packages/react/src/number-input.d.cts +28 -0
- package/dist/types/packages/react/src/number-input.d.ts +28 -0
- package/dist/types/packages/react/src/popover.d.cts +5 -2
- package/dist/types/packages/react/src/popover.d.ts +5 -2
- package/dist/types/packages/react/src/pressable.d.cts +17 -0
- package/dist/types/packages/react/src/pressable.d.ts +17 -0
- package/dist/types/packages/react/src/quantity-stepper.d.cts +3 -1
- package/dist/types/packages/react/src/quantity-stepper.d.ts +3 -1
- package/dist/types/packages/react/src/range-input.d.cts +15 -3
- package/dist/types/packages/react/src/range-input.d.ts +15 -3
- package/dist/types/packages/react/src/reorder-controls.d.cts +43 -0
- package/dist/types/packages/react/src/reorder-controls.d.ts +43 -0
- package/dist/types/packages/react/src/search-input.d.cts +6 -3
- package/dist/types/packages/react/src/search-input.d.ts +6 -3
- package/dist/types/packages/react/src/select-control.d.cts +7 -2
- package/dist/types/packages/react/src/select-control.d.ts +7 -2
- package/dist/types/packages/react/src/side-navigation-layout.d.cts +47 -0
- package/dist/types/packages/react/src/side-navigation-layout.d.ts +47 -0
- package/dist/types/packages/react/src/side-navigation.d.cts +74 -0
- package/dist/types/packages/react/src/side-navigation.d.ts +74 -0
- package/dist/types/packages/react/src/skeletons.d.cts +19 -3
- package/dist/types/packages/react/src/skeletons.d.ts +19 -3
- package/dist/types/packages/react/src/spinner-glyph.d.cts +8 -0
- package/dist/types/packages/react/src/spinner-glyph.d.ts +8 -0
- package/dist/types/packages/react/src/split-pane.d.cts +43 -0
- package/dist/types/packages/react/src/split-pane.d.ts +43 -0
- package/dist/types/packages/react/src/stacked-bar.d.cts +24 -0
- package/dist/types/packages/react/src/stacked-bar.d.ts +24 -0
- package/dist/types/packages/react/src/steps.d.cts +26 -0
- package/dist/types/packages/react/src/steps.d.ts +26 -0
- package/dist/types/packages/react/src/table-cards.d.cts +4 -12
- package/dist/types/packages/react/src/table-cards.d.ts +4 -12
- package/dist/types/packages/react/src/table-grid.d.cts +3 -7
- package/dist/types/packages/react/src/table-grid.d.ts +3 -7
- package/dist/types/packages/react/src/table-groups.d.cts +5 -0
- package/dist/types/packages/react/src/table-groups.d.ts +5 -0
- package/dist/types/packages/react/src/table-list.d.cts +2 -9
- package/dist/types/packages/react/src/table-list.d.ts +2 -9
- package/dist/types/packages/react/src/table-model.d.cts +6 -2
- package/dist/types/packages/react/src/table-model.d.ts +6 -2
- package/dist/types/packages/react/src/tabs.d.cts +3 -1
- package/dist/types/packages/react/src/tabs.d.ts +3 -1
- package/dist/types/packages/react/src/textarea.d.cts +6 -3
- package/dist/types/packages/react/src/textarea.d.ts +6 -3
- package/dist/types/packages/react/src/tiles.d.cts +18 -0
- package/dist/types/packages/react/src/tiles.d.ts +18 -0
- package/dist/types/packages/react/src/time-picker.d.cts +12 -2
- package/dist/types/packages/react/src/time-picker.d.ts +12 -2
- package/dist/types/packages/react/src/time-wheel.d.cts +18 -0
- package/dist/types/packages/react/src/time-wheel.d.ts +18 -0
- package/dist/types/packages/react/src/use-filter-scroll.d.cts +5 -0
- package/dist/types/packages/react/src/use-filter-scroll.d.ts +5 -0
- package/dist/types/packages/react/src/zone-gauge.d.cts +28 -0
- package/dist/types/packages/react/src/zone-gauge.d.ts +28 -0
- package/dist/types/shared/package-runtime/accordion-state.d.cts +2 -0
- package/dist/types/shared/package-runtime/accordion-state.d.ts +2 -0
- package/dist/types/shared/package-runtime/action-size.d.cts +4 -0
- package/dist/types/shared/package-runtime/action-size.d.ts +4 -0
- package/dist/types/shared/package-runtime/alert-action-size.d.cts +1 -0
- package/dist/types/shared/package-runtime/alert-action-size.d.ts +1 -0
- package/dist/types/shared/package-runtime/alert-actions.d.cts +7 -0
- package/dist/types/shared/package-runtime/alert-actions.d.ts +7 -0
- package/dist/types/shared/package-runtime/alert-exit.d.cts +6 -0
- package/dist/types/shared/package-runtime/alert-exit.d.ts +6 -0
- package/dist/types/shared/package-runtime/alert-live.d.cts +2 -0
- package/dist/types/shared/package-runtime/alert-live.d.ts +2 -0
- package/dist/types/shared/package-runtime/avatar-group.d.cts +18 -0
- package/dist/types/shared/package-runtime/avatar-group.d.ts +18 -0
- package/dist/types/shared/package-runtime/badge-tone.d.cts +8 -2
- package/dist/types/shared/package-runtime/badge-tone.d.ts +8 -2
- package/dist/types/shared/package-runtime/bottom-bar.d.cts +15 -0
- package/dist/types/shared/package-runtime/bottom-bar.d.ts +15 -0
- package/dist/types/shared/package-runtime/bottom-navigation.d.cts +30 -0
- package/dist/types/shared/package-runtime/bottom-navigation.d.ts +30 -0
- package/dist/types/shared/package-runtime/calendar.d.cts +21 -7
- package/dist/types/shared/package-runtime/calendar.d.ts +21 -7
- package/dist/types/shared/package-runtime/card-layout.d.cts +42 -0
- package/dist/types/shared/package-runtime/card-layout.d.ts +42 -0
- package/dist/types/shared/package-runtime/carousel-scroll.d.cts +2 -0
- package/dist/types/shared/package-runtime/carousel-scroll.d.ts +2 -0
- package/dist/types/shared/package-runtime/carousel.d.cts +12 -2
- package/dist/types/shared/package-runtime/carousel.d.ts +12 -2
- package/dist/types/shared/package-runtime/chart-skeleton.d.cts +2 -2
- package/dist/types/shared/package-runtime/chart-skeleton.d.ts +2 -2
- package/dist/types/shared/package-runtime/chip-size.d.cts +4 -0
- package/dist/types/shared/package-runtime/chip-size.d.ts +4 -0
- package/dist/types/shared/package-runtime/clipboard.d.cts +6 -0
- package/dist/types/shared/package-runtime/clipboard.d.ts +6 -0
- package/dist/types/shared/package-runtime/color-picker-model.d.cts +51 -0
- package/dist/types/shared/package-runtime/color-picker-model.d.ts +51 -0
- package/dist/types/shared/package-runtime/color-picker.d.cts +92 -0
- package/dist/types/shared/package-runtime/color-picker.d.ts +92 -0
- package/dist/types/shared/package-runtime/color.d.cts +22 -0
- package/dist/types/shared/package-runtime/color.d.ts +22 -0
- package/dist/types/shared/package-runtime/combobox-options.d.cts +13 -0
- package/dist/types/shared/package-runtime/combobox-options.d.ts +13 -0
- package/dist/types/shared/package-runtime/combobox.d.cts +3 -1
- package/dist/types/shared/package-runtime/combobox.d.ts +3 -1
- package/dist/types/shared/package-runtime/copy-button.d.cts +11 -0
- package/dist/types/shared/package-runtime/copy-button.d.ts +11 -0
- package/dist/types/shared/package-runtime/data-cells.d.cts +36 -0
- package/dist/types/shared/package-runtime/data-cells.d.ts +36 -0
- package/dist/types/shared/package-runtime/development.d.cts +4 -0
- package/dist/types/shared/package-runtime/development.d.ts +4 -0
- package/dist/types/shared/package-runtime/distribution.d.cts +168 -0
- package/dist/types/shared/package-runtime/distribution.d.ts +168 -0
- package/dist/types/shared/package-runtime/drawer-geometry.d.cts +7 -0
- package/dist/types/shared/package-runtime/drawer-geometry.d.ts +7 -0
- package/dist/types/shared/package-runtime/empty-geometry.d.cts +19 -0
- package/dist/types/shared/package-runtime/empty-geometry.d.ts +19 -0
- package/dist/types/shared/package-runtime/event-calendar.d.cts +81 -0
- package/dist/types/shared/package-runtime/event-calendar.d.ts +81 -0
- package/dist/types/shared/package-runtime/external-link.d.cts +4 -0
- package/dist/types/shared/package-runtime/external-link.d.ts +4 -0
- package/dist/types/shared/package-runtime/file-upload.d.cts +128 -0
- package/dist/types/shared/package-runtime/file-upload.d.ts +128 -0
- package/dist/types/shared/package-runtime/filter-scroll.d.cts +5 -0
- package/dist/types/shared/package-runtime/filter-scroll.d.ts +5 -0
- package/dist/types/shared/package-runtime/filter-value.d.cts +2 -0
- package/dist/types/shared/package-runtime/filter-value.d.ts +2 -0
- package/dist/types/shared/package-runtime/input-field.d.cts +23 -0
- package/dist/types/shared/package-runtime/input-field.d.ts +23 -0
- package/dist/types/shared/package-runtime/input-variant.d.cts +7 -0
- package/dist/types/shared/package-runtime/input-variant.d.ts +7 -0
- package/dist/types/shared/package-runtime/kpi.d.cts +102 -0
- package/dist/types/shared/package-runtime/kpi.d.ts +102 -0
- package/dist/types/shared/package-runtime/layer-state.d.cts +2 -1
- package/dist/types/shared/package-runtime/layer-state.d.ts +2 -1
- package/dist/types/shared/package-runtime/layout-primitives.d.cts +115 -6
- package/dist/types/shared/package-runtime/layout-primitives.d.ts +115 -6
- package/dist/types/shared/package-runtime/list-leading.d.cts +38 -0
- package/dist/types/shared/package-runtime/list-leading.d.ts +38 -0
- package/dist/types/shared/package-runtime/list-row.d.cts +152 -4
- package/dist/types/shared/package-runtime/list-row.d.ts +152 -4
- package/dist/types/shared/package-runtime/market-layout.d.cts +6 -2
- package/dist/types/shared/package-runtime/market-layout.d.ts +6 -2
- package/dist/types/shared/package-runtime/market-query.d.cts +21 -0
- package/dist/types/shared/package-runtime/market-query.d.ts +21 -0
- package/dist/types/shared/package-runtime/market-table.d.cts +32 -0
- package/dist/types/shared/package-runtime/market-table.d.ts +32 -0
- package/dist/types/shared/package-runtime/menu-button.d.cts +4 -0
- package/dist/types/shared/package-runtime/menu-button.d.ts +4 -0
- package/dist/types/shared/package-runtime/messages/ko.d.cts +101 -1
- package/dist/types/shared/package-runtime/messages/ko.d.ts +101 -1
- package/dist/types/shared/package-runtime/messages-context.d.cts +93 -1
- package/dist/types/shared/package-runtime/messages-context.d.ts +93 -1
- package/dist/types/shared/package-runtime/minimum-loading.d.cts +3 -0
- package/dist/types/shared/package-runtime/minimum-loading.d.ts +3 -0
- package/dist/types/shared/package-runtime/modal-geometry.d.cts +15 -0
- package/dist/types/shared/package-runtime/modal-geometry.d.ts +15 -0
- package/dist/types/shared/package-runtime/navigation.d.cts +9 -2
- package/dist/types/shared/package-runtime/navigation.d.ts +9 -2
- package/dist/types/shared/package-runtime/nested-controls.d.cts +7 -0
- package/dist/types/shared/package-runtime/nested-controls.d.ts +7 -0
- package/dist/types/shared/package-runtime/number-input.d.cts +63 -0
- package/dist/types/shared/package-runtime/number-input.d.ts +63 -0
- package/dist/types/shared/package-runtime/number-sign.d.cts +9 -0
- package/dist/types/shared/package-runtime/number-sign.d.ts +9 -0
- package/dist/types/shared/package-runtime/options.d.cts +25 -5
- package/dist/types/shared/package-runtime/options.d.ts +25 -5
- package/dist/types/shared/package-runtime/pagination.d.cts +12 -0
- package/dist/types/shared/package-runtime/pagination.d.ts +12 -0
- package/dist/types/shared/package-runtime/popover-scroll.d.cts +3 -0
- package/dist/types/shared/package-runtime/popover-scroll.d.ts +3 -0
- package/dist/types/shared/package-runtime/press-repeat.d.cts +13 -0
- package/dist/types/shared/package-runtime/press-repeat.d.ts +13 -0
- package/dist/types/shared/package-runtime/progress-circle.d.cts +5 -0
- package/dist/types/shared/package-runtime/progress-circle.d.ts +5 -0
- package/dist/types/shared/package-runtime/progress-marker.d.cts +7 -0
- package/dist/types/shared/package-runtime/progress-marker.d.ts +7 -0
- package/dist/types/shared/package-runtime/radio-keyboard.d.cts +2 -0
- package/dist/types/shared/package-runtime/radio-keyboard.d.ts +2 -0
- package/dist/types/shared/package-runtime/reorder-session.d.cts +62 -0
- package/dist/types/shared/package-runtime/reorder-session.d.ts +62 -0
- package/dist/types/shared/package-runtime/reorder.d.cts +81 -0
- package/dist/types/shared/package-runtime/reorder.d.ts +81 -0
- package/dist/types/shared/package-runtime/select-trigger.d.cts +23 -0
- package/dist/types/shared/package-runtime/select-trigger.d.ts +23 -0
- package/dist/types/shared/package-runtime/sheet-drag.d.cts +24 -0
- package/dist/types/shared/package-runtime/sheet-drag.d.ts +24 -0
- package/dist/types/shared/package-runtime/side-navigation-keys.d.cts +23 -0
- package/dist/types/shared/package-runtime/side-navigation-keys.d.ts +23 -0
- package/dist/types/shared/package-runtime/side-navigation-scroll.d.cts +7 -0
- package/dist/types/shared/package-runtime/side-navigation-scroll.d.ts +7 -0
- package/dist/types/shared/package-runtime/side-navigation.d.cts +277 -0
- package/dist/types/shared/package-runtime/side-navigation.d.ts +277 -0
- package/dist/types/shared/package-runtime/signed-number.d.cts +33 -0
- package/dist/types/shared/package-runtime/signed-number.d.ts +33 -0
- package/dist/types/shared/package-runtime/skeleton-text.d.cts +18 -0
- package/dist/types/shared/package-runtime/skeleton-text.d.ts +18 -0
- package/dist/types/shared/package-runtime/slider-view.d.cts +17 -2
- package/dist/types/shared/package-runtime/slider-view.d.ts +17 -2
- package/dist/types/shared/package-runtime/sparkline.d.cts +8 -4
- package/dist/types/shared/package-runtime/sparkline.d.ts +8 -4
- package/dist/types/shared/package-runtime/spinner-geometry.d.cts +14 -0
- package/dist/types/shared/package-runtime/spinner-geometry.d.ts +14 -0
- package/dist/types/shared/package-runtime/split-pane.d.cts +85 -0
- package/dist/types/shared/package-runtime/split-pane.d.ts +85 -0
- package/dist/types/shared/package-runtime/steps.d.cts +37 -0
- package/dist/types/shared/package-runtime/steps.d.ts +37 -0
- package/dist/types/shared/package-runtime/tab-keyboard.d.cts +6 -0
- package/dist/types/shared/package-runtime/tab-keyboard.d.ts +6 -0
- package/dist/types/shared/package-runtime/table-columns.d.cts +36 -0
- package/dist/types/shared/package-runtime/table-columns.d.ts +36 -0
- package/dist/types/shared/package-runtime/table-model.d.cts +23 -3
- package/dist/types/shared/package-runtime/table-model.d.ts +23 -3
- package/dist/types/shared/package-runtime/table-presentation.d.cts +33 -4
- package/dist/types/shared/package-runtime/table-presentation.d.ts +33 -4
- package/dist/types/shared/package-runtime/table.d.cts +44 -2
- package/dist/types/shared/package-runtime/table.d.ts +44 -2
- package/dist/types/shared/package-runtime/textarea.d.cts +6 -4
- package/dist/types/shared/package-runtime/textarea.d.ts +6 -4
- package/dist/types/shared/package-runtime/tiles-children.d.cts +7 -0
- package/dist/types/shared/package-runtime/tiles-children.d.ts +7 -0
- package/dist/types/shared/package-runtime/tiles.d.cts +18 -0
- package/dist/types/shared/package-runtime/tiles.d.ts +18 -0
- package/dist/types/shared/package-runtime/time-segments.d.cts +24 -0
- package/dist/types/shared/package-runtime/time-segments.d.ts +24 -0
- package/dist/types/shared/package-runtime/time-wheel.d.cts +54 -0
- package/dist/types/shared/package-runtime/time-wheel.d.ts +54 -0
- package/dist/types/shared/package-runtime/trailing-overflow.d.cts +1 -0
- package/dist/types/shared/package-runtime/trailing-overflow.d.ts +1 -0
- package/dist/types/shared/package-runtime/use-color-picker.d.cts +54 -0
- package/dist/types/shared/package-runtime/use-color-picker.d.ts +54 -0
- package/dist/types/shared/package-runtime/use-copy-feedback.d.cts +10 -0
- package/dist/types/shared/package-runtime/use-copy-feedback.d.ts +10 -0
- package/dist/types/shared/package-runtime/use-layer.d.cts +4 -2
- package/dist/types/shared/package-runtime/use-layer.d.ts +4 -2
- package/dist/types/shared/package-runtime/use-open-state.d.cts +5 -0
- package/dist/types/shared/package-runtime/use-open-state.d.ts +5 -0
- package/dist/types/shared/package-runtime/use-pending-action.d.cts +6 -0
- package/dist/types/shared/package-runtime/use-pending-action.d.ts +6 -0
- package/dist/types/shared/package-runtime/use-side-navigation-state.d.cts +25 -0
- package/dist/types/shared/package-runtime/use-side-navigation-state.d.ts +25 -0
- package/dist/types/shared/package-runtime/use-slide.d.cts +3 -0
- package/dist/types/shared/package-runtime/use-slide.d.ts +3 -0
- package/package.json +3 -3
- package/dist/types/packages/react/src/compound-control.d.cts +0 -1
- package/dist/types/packages/react/src/compound-control.d.ts +0 -1
- package/dist/types/shared/package-runtime/center-option.d.cts +0 -1
- package/dist/types/shared/package-runtime/center-option.d.ts +0 -1
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
export type SplitDirection = "horizontal" | "vertical";
|
|
2
|
+
export type SplitMin = readonly [
|
|
3
|
+
number,
|
|
4
|
+
number
|
|
5
|
+
];
|
|
6
|
+
export type SplitMax = readonly [
|
|
7
|
+
number | null,
|
|
8
|
+
number | null
|
|
9
|
+
];
|
|
10
|
+
export interface SplitLimits {
|
|
11
|
+
low: number;
|
|
12
|
+
high: number;
|
|
13
|
+
}
|
|
14
|
+
export type SplitKeyAction = "decrease" | "increase" | "min" | "max" | "reset";
|
|
15
|
+
export type SplitUnit = "ratio" | "px";
|
|
16
|
+
/** Pixels one arrow key press moves the handle. */
|
|
17
|
+
export declare const SPLIT_KEY_STEP: number;
|
|
18
|
+
/** Two presses on the handle this close in time, and this close in place, are a double press that restores the default size. */
|
|
19
|
+
export declare const SPLIT_DOUBLE_PRESS_MS = 300;
|
|
20
|
+
export declare const SPLIT_PRESS_SLOP = 10;
|
|
21
|
+
/**
|
|
22
|
+
* The first pane's allowed pixels. Minimums beat maximums, and when the container is narrower than both minimums the
|
|
23
|
+
* first pane keeps its minimum (or all the room, if even that does not fit), so panes never overlap or go negative.
|
|
24
|
+
*/
|
|
25
|
+
export declare function splitLimits(total: number, handle: number, min?: SplitMin, max?: SplitMax): SplitLimits;
|
|
26
|
+
export declare function splitClamp(px: number, limits: SplitLimits): number;
|
|
27
|
+
export declare function splitFromRatio(ratio: number, total: number, handle: number): number;
|
|
28
|
+
/** Four decimals: enough for a pixel on any screen, and stable to store. */
|
|
29
|
+
export declare function splitToRatio(px: number, total: number, handle: number): number;
|
|
30
|
+
/** The wanted ratio as the first pane's pixels inside the limits. */
|
|
31
|
+
export declare function splitResolve(ratio: number, total: number, handle: number, min?: SplitMin, max?: SplitMax): number;
|
|
32
|
+
/** A whole percent for aria-valuenow, aria-valuemin and aria-valuemax. */
|
|
33
|
+
export declare function splitPercent(px: number, total: number, handle: number): number;
|
|
34
|
+
/**
|
|
35
|
+
* The first pane's pixels during a drag: where it started plus how far the pointer has moved. scale is layout pixels
|
|
36
|
+
* per viewport pixel (1 unless an ancestor is transformed), and right to left the pane grows as the pointer moves left.
|
|
37
|
+
*/
|
|
38
|
+
export declare function splitDrag(startPx: number, startPointer: number, pointer: number, scale: number, rtl: boolean | undefined): number;
|
|
39
|
+
/** A usable share: a missing or non-finite size falls back, and the rest is kept inside 0–1. */
|
|
40
|
+
export declare function splitShare(size: number | undefined, fallback?: number): number;
|
|
41
|
+
/** Browser shortcuts (Alt+Left, Ctrl+Home) keep their meaning on a focused handle. */
|
|
42
|
+
export declare function splitKeyHeld(event: {
|
|
43
|
+
altKey?: boolean;
|
|
44
|
+
ctrlKey?: boolean;
|
|
45
|
+
metaKey?: boolean;
|
|
46
|
+
}): boolean;
|
|
47
|
+
/** rtl is read by truth: Native Web has no reading direction to report and passes undefined. */
|
|
48
|
+
export declare function splitKeyAction(key: string, direction: SplitDirection, rtl: boolean | undefined): SplitKeyAction | null;
|
|
49
|
+
/** The first pane's pixels after a key action; resetPx is the default size in pixels. */
|
|
50
|
+
export declare function splitKeyTarget(action: SplitKeyAction, px: number, limits: SplitLimits, resetPx: number): number;
|
|
51
|
+
/**
|
|
52
|
+
* The wanted size in its unit. A ratio falls back to the default share (or one half); pixels fall back to the default
|
|
53
|
+
* pixels, or to null when there is none, which means half the room once the split is measured.
|
|
54
|
+
*/
|
|
55
|
+
export declare function splitWanted(size: number | undefined, fallback: number | undefined, unit: SplitUnit): number | null;
|
|
56
|
+
/** The first pane's pixels for a wanted size, before the limits. */
|
|
57
|
+
export declare function splitWantedPx(value: number | null, unit: SplitUnit, total: number, handle: number): number;
|
|
58
|
+
/** The size reported to the app: a ratio with four decimals, or whole pixels. */
|
|
59
|
+
export declare function splitReport(px: number, unit: SplitUnit, total: number, handle: number): number;
|
|
60
|
+
/** A collapsed first pane's pixels: collapsedSize, never past the room. */
|
|
61
|
+
export declare function splitFoldedPx(collapsedSize: number | undefined, total: number, handle: number): number;
|
|
62
|
+
/**
|
|
63
|
+
* While dragging a collapsible pane: the pointer collapses it once it passes the midpoint between the collapsed size
|
|
64
|
+
* and the pane's smallest open size, and opens it again on the way back.
|
|
65
|
+
*/
|
|
66
|
+
export declare function splitCollapseAt(px: number, low: number, folded: number): boolean;
|
|
67
|
+
/**
|
|
68
|
+
* What a key does to a collapsible pane, as in the window-splitter pattern: Enter toggles it, Home collapses it, and
|
|
69
|
+
* from collapsed an increase restores the size it had while End opens it to the largest size. move says whether the
|
|
70
|
+
* key then moves the handle as on a pane that does not collapse.
|
|
71
|
+
*/
|
|
72
|
+
export declare function splitKeyCollapse(action: SplitKeyAction, collapsible: boolean, collapsed: boolean): {
|
|
73
|
+
collapse: boolean | null;
|
|
74
|
+
move: boolean;
|
|
75
|
+
};
|
|
76
|
+
/** A second press within the double-press time and slop of the first. */
|
|
77
|
+
export declare function splitDoublePress(previous: {
|
|
78
|
+
at: number;
|
|
79
|
+
x: number;
|
|
80
|
+
y: number;
|
|
81
|
+
} | null, now: {
|
|
82
|
+
at: number;
|
|
83
|
+
x: number;
|
|
84
|
+
y: number;
|
|
85
|
+
}): boolean;
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
export type SplitDirection = "horizontal" | "vertical";
|
|
2
|
+
export type SplitMin = readonly [
|
|
3
|
+
number,
|
|
4
|
+
number
|
|
5
|
+
];
|
|
6
|
+
export type SplitMax = readonly [
|
|
7
|
+
number | null,
|
|
8
|
+
number | null
|
|
9
|
+
];
|
|
10
|
+
export interface SplitLimits {
|
|
11
|
+
low: number;
|
|
12
|
+
high: number;
|
|
13
|
+
}
|
|
14
|
+
export type SplitKeyAction = "decrease" | "increase" | "min" | "max" | "reset";
|
|
15
|
+
export type SplitUnit = "ratio" | "px";
|
|
16
|
+
/** Pixels one arrow key press moves the handle. */
|
|
17
|
+
export declare const SPLIT_KEY_STEP: number;
|
|
18
|
+
/** Two presses on the handle this close in time, and this close in place, are a double press that restores the default size. */
|
|
19
|
+
export declare const SPLIT_DOUBLE_PRESS_MS = 300;
|
|
20
|
+
export declare const SPLIT_PRESS_SLOP = 10;
|
|
21
|
+
/**
|
|
22
|
+
* The first pane's allowed pixels. Minimums beat maximums, and when the container is narrower than both minimums the
|
|
23
|
+
* first pane keeps its minimum (or all the room, if even that does not fit), so panes never overlap or go negative.
|
|
24
|
+
*/
|
|
25
|
+
export declare function splitLimits(total: number, handle: number, min?: SplitMin, max?: SplitMax): SplitLimits;
|
|
26
|
+
export declare function splitClamp(px: number, limits: SplitLimits): number;
|
|
27
|
+
export declare function splitFromRatio(ratio: number, total: number, handle: number): number;
|
|
28
|
+
/** Four decimals: enough for a pixel on any screen, and stable to store. */
|
|
29
|
+
export declare function splitToRatio(px: number, total: number, handle: number): number;
|
|
30
|
+
/** The wanted ratio as the first pane's pixels inside the limits. */
|
|
31
|
+
export declare function splitResolve(ratio: number, total: number, handle: number, min?: SplitMin, max?: SplitMax): number;
|
|
32
|
+
/** A whole percent for aria-valuenow, aria-valuemin and aria-valuemax. */
|
|
33
|
+
export declare function splitPercent(px: number, total: number, handle: number): number;
|
|
34
|
+
/**
|
|
35
|
+
* The first pane's pixels during a drag: where it started plus how far the pointer has moved. scale is layout pixels
|
|
36
|
+
* per viewport pixel (1 unless an ancestor is transformed), and right to left the pane grows as the pointer moves left.
|
|
37
|
+
*/
|
|
38
|
+
export declare function splitDrag(startPx: number, startPointer: number, pointer: number, scale: number, rtl: boolean | undefined): number;
|
|
39
|
+
/** A usable share: a missing or non-finite size falls back, and the rest is kept inside 0–1. */
|
|
40
|
+
export declare function splitShare(size: number | undefined, fallback?: number): number;
|
|
41
|
+
/** Browser shortcuts (Alt+Left, Ctrl+Home) keep their meaning on a focused handle. */
|
|
42
|
+
export declare function splitKeyHeld(event: {
|
|
43
|
+
altKey?: boolean;
|
|
44
|
+
ctrlKey?: boolean;
|
|
45
|
+
metaKey?: boolean;
|
|
46
|
+
}): boolean;
|
|
47
|
+
/** rtl is read by truth: Native Web has no reading direction to report and passes undefined. */
|
|
48
|
+
export declare function splitKeyAction(key: string, direction: SplitDirection, rtl: boolean | undefined): SplitKeyAction | null;
|
|
49
|
+
/** The first pane's pixels after a key action; resetPx is the default size in pixels. */
|
|
50
|
+
export declare function splitKeyTarget(action: SplitKeyAction, px: number, limits: SplitLimits, resetPx: number): number;
|
|
51
|
+
/**
|
|
52
|
+
* The wanted size in its unit. A ratio falls back to the default share (or one half); pixels fall back to the default
|
|
53
|
+
* pixels, or to null when there is none, which means half the room once the split is measured.
|
|
54
|
+
*/
|
|
55
|
+
export declare function splitWanted(size: number | undefined, fallback: number | undefined, unit: SplitUnit): number | null;
|
|
56
|
+
/** The first pane's pixels for a wanted size, before the limits. */
|
|
57
|
+
export declare function splitWantedPx(value: number | null, unit: SplitUnit, total: number, handle: number): number;
|
|
58
|
+
/** The size reported to the app: a ratio with four decimals, or whole pixels. */
|
|
59
|
+
export declare function splitReport(px: number, unit: SplitUnit, total: number, handle: number): number;
|
|
60
|
+
/** A collapsed first pane's pixels: collapsedSize, never past the room. */
|
|
61
|
+
export declare function splitFoldedPx(collapsedSize: number | undefined, total: number, handle: number): number;
|
|
62
|
+
/**
|
|
63
|
+
* While dragging a collapsible pane: the pointer collapses it once it passes the midpoint between the collapsed size
|
|
64
|
+
* and the pane's smallest open size, and opens it again on the way back.
|
|
65
|
+
*/
|
|
66
|
+
export declare function splitCollapseAt(px: number, low: number, folded: number): boolean;
|
|
67
|
+
/**
|
|
68
|
+
* What a key does to a collapsible pane, as in the window-splitter pattern: Enter toggles it, Home collapses it, and
|
|
69
|
+
* from collapsed an increase restores the size it had while End opens it to the largest size. move says whether the
|
|
70
|
+
* key then moves the handle as on a pane that does not collapse.
|
|
71
|
+
*/
|
|
72
|
+
export declare function splitKeyCollapse(action: SplitKeyAction, collapsible: boolean, collapsed: boolean): {
|
|
73
|
+
collapse: boolean | null;
|
|
74
|
+
move: boolean;
|
|
75
|
+
};
|
|
76
|
+
/** A second press within the double-press time and slop of the first. */
|
|
77
|
+
export declare function splitDoublePress(previous: {
|
|
78
|
+
at: number;
|
|
79
|
+
x: number;
|
|
80
|
+
y: number;
|
|
81
|
+
} | null, now: {
|
|
82
|
+
at: number;
|
|
83
|
+
x: number;
|
|
84
|
+
y: number;
|
|
85
|
+
}): boolean;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { KjunMessages } from "./messages/index.cjs";
|
|
2
|
+
export type KjunStepStatus = "complete" | "current" | "error" | "upcoming";
|
|
3
|
+
export type KjunStepsCurrentStatus = "active" | "error";
|
|
4
|
+
export type KjunStepsLayout = "auto" | "full" | "compact";
|
|
5
|
+
/** Which steps onStepSelect makes buttons: completed ones (default), or every step but the current one (a wizard that may skip ahead). */
|
|
6
|
+
export type KjunStepsSelectable = "complete" | "all";
|
|
7
|
+
export interface KjunStepItem {
|
|
8
|
+
key?: string | number;
|
|
9
|
+
label: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
meta?: string;
|
|
12
|
+
}
|
|
13
|
+
/** Narrowest column a step gets in the wide layout; mirrors `extensions.steps.minColumn`. */
|
|
14
|
+
export declare const STEPS_MIN_COLUMN = 80;
|
|
15
|
+
/** More steps than this always fold to compact. */
|
|
16
|
+
export declare const STEPS_AUTO_MAX = 10;
|
|
17
|
+
/** `current` counts finished steps: floored and kept within 0..count (count means all complete). */
|
|
18
|
+
export declare function clampCurrent(current: number, count: number): number;
|
|
19
|
+
export declare function stepStatus(index: number, current: number, currentStatus: KjunStepsCurrentStatus): KjunStepStatus;
|
|
20
|
+
export declare function stepsRootStatus(current: number, count: number, currentStatus: KjunStepsCurrentStatus): "current" | "error" | "complete";
|
|
21
|
+
export declare function stepsLayout(width: number, count: number): "full" | "compact";
|
|
22
|
+
/** A step is a button when someone listens and it is not the step the user is on. */
|
|
23
|
+
export declare function stepSelectable(status: KjunStepStatus, selectable?: KjunStepsSelectable): boolean;
|
|
24
|
+
type StepMessages = Pick<KjunMessages, "stepComplete" | "stepCurrent" | "stepError" | "stepUpcoming" | "stepPosition" | "stepCount">;
|
|
25
|
+
/** Vertical rows show meta and description under the label; the horizontal row shows the label alone. */
|
|
26
|
+
export declare function stepDetail(item: KjunStepItem, vertical: boolean): string;
|
|
27
|
+
/** One phrase names the step for a screen reader: a button carries it as its name, static copy as hidden text. */
|
|
28
|
+
export declare function stepSpoken(m: StepMessages, index: number, item: KjunStepItem, status: KjunStepStatus, detail: string): string;
|
|
29
|
+
/** The compact heading row: the current step (the last one once every step is complete), the step after it, and "n / N"
|
|
30
|
+
* split so the position can be drawn bold (lead is "" when a locale's count does not start with it). */
|
|
31
|
+
export declare function stepsHead<T extends KjunStepItem>(m: StepMessages, items: readonly T[], at: number): {
|
|
32
|
+
item: T | undefined;
|
|
33
|
+
next: T | undefined;
|
|
34
|
+
lead: string;
|
|
35
|
+
rest: string;
|
|
36
|
+
};
|
|
37
|
+
export {};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { KjunMessages } from "./messages/index.js";
|
|
2
|
+
export type KjunStepStatus = "complete" | "current" | "error" | "upcoming";
|
|
3
|
+
export type KjunStepsCurrentStatus = "active" | "error";
|
|
4
|
+
export type KjunStepsLayout = "auto" | "full" | "compact";
|
|
5
|
+
/** Which steps onStepSelect makes buttons: completed ones (default), or every step but the current one (a wizard that may skip ahead). */
|
|
6
|
+
export type KjunStepsSelectable = "complete" | "all";
|
|
7
|
+
export interface KjunStepItem {
|
|
8
|
+
key?: string | number;
|
|
9
|
+
label: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
meta?: string;
|
|
12
|
+
}
|
|
13
|
+
/** Narrowest column a step gets in the wide layout; mirrors `extensions.steps.minColumn`. */
|
|
14
|
+
export declare const STEPS_MIN_COLUMN = 80;
|
|
15
|
+
/** More steps than this always fold to compact. */
|
|
16
|
+
export declare const STEPS_AUTO_MAX = 10;
|
|
17
|
+
/** `current` counts finished steps: floored and kept within 0..count (count means all complete). */
|
|
18
|
+
export declare function clampCurrent(current: number, count: number): number;
|
|
19
|
+
export declare function stepStatus(index: number, current: number, currentStatus: KjunStepsCurrentStatus): KjunStepStatus;
|
|
20
|
+
export declare function stepsRootStatus(current: number, count: number, currentStatus: KjunStepsCurrentStatus): "current" | "error" | "complete";
|
|
21
|
+
export declare function stepsLayout(width: number, count: number): "full" | "compact";
|
|
22
|
+
/** A step is a button when someone listens and it is not the step the user is on. */
|
|
23
|
+
export declare function stepSelectable(status: KjunStepStatus, selectable?: KjunStepsSelectable): boolean;
|
|
24
|
+
type StepMessages = Pick<KjunMessages, "stepComplete" | "stepCurrent" | "stepError" | "stepUpcoming" | "stepPosition" | "stepCount">;
|
|
25
|
+
/** Vertical rows show meta and description under the label; the horizontal row shows the label alone. */
|
|
26
|
+
export declare function stepDetail(item: KjunStepItem, vertical: boolean): string;
|
|
27
|
+
/** One phrase names the step for a screen reader: a button carries it as its name, static copy as hidden text. */
|
|
28
|
+
export declare function stepSpoken(m: StepMessages, index: number, item: KjunStepItem, status: KjunStepStatus, detail: string): string;
|
|
29
|
+
/** The compact heading row: the current step (the last one once every step is complete), the step after it, and "n / N"
|
|
30
|
+
* split so the position can be drawn bold (lead is "" when a locale's count does not start with it). */
|
|
31
|
+
export declare function stepsHead<T extends KjunStepItem>(m: StepMessages, items: readonly T[], at: number): {
|
|
32
|
+
item: T | undefined;
|
|
33
|
+
next: T | undefined;
|
|
34
|
+
lead: string;
|
|
35
|
+
rest: string;
|
|
36
|
+
};
|
|
37
|
+
export {};
|
|
@@ -1,2 +1,8 @@
|
|
|
1
1
|
export declare function manageTabList(list: HTMLElement, select: (name: string) => void, keyboard?: boolean): () => void;
|
|
2
2
|
export declare function panelNeedsFocus(panel: HTMLElement): boolean;
|
|
3
|
+
/**
|
|
4
|
+
* Scrolls the tab track just enough to show a tab clear of the edge fade (pad pixels). Only the track moves: unlike
|
|
5
|
+
* scrollIntoView this never scrolls the page, so a selected tab revealed on the first render keeps the reader's place.
|
|
6
|
+
* The rectangles work in both reading directions.
|
|
7
|
+
*/
|
|
8
|
+
export declare function revealTab(track: HTMLElement, tab: HTMLElement, pad: number, smooth: boolean): void;
|
|
@@ -1,2 +1,8 @@
|
|
|
1
1
|
export declare function manageTabList(list: HTMLElement, select: (name: string) => void, keyboard?: boolean): () => void;
|
|
2
2
|
export declare function panelNeedsFocus(panel: HTMLElement): boolean;
|
|
3
|
+
/**
|
|
4
|
+
* Scrolls the tab track just enough to show a tab clear of the edge fade (pad pixels). Only the track moves: unlike
|
|
5
|
+
* scrollIntoView this never scrolls the page, so a selected tab revealed on the first render keeps the reader's place.
|
|
6
|
+
* The rectangles work in both reading directions.
|
|
7
|
+
*/
|
|
8
|
+
export declare function revealTab(track: HTMLElement, tab: HTMLElement, pad: number, smooth: boolean): void;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export interface TableColumnGroup {
|
|
2
|
+
/** The label over the group's columns. */
|
|
3
|
+
label: string;
|
|
4
|
+
/** Keys of the columns it spans; they are drawn where `columns` puts them. */
|
|
5
|
+
columns: string[];
|
|
6
|
+
}
|
|
7
|
+
export type TableHeaderCell<Column> = {
|
|
8
|
+
kind: "group";
|
|
9
|
+
key: string;
|
|
10
|
+
label: string;
|
|
11
|
+
span: number;
|
|
12
|
+
columns: Column[];
|
|
13
|
+
} | {
|
|
14
|
+
kind: "column";
|
|
15
|
+
column: Column;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* The header's top row when groups apply: a group over each run of its shown columns, and the other columns standing
|
|
19
|
+
* alone across both rows. null when no group holds a shown column, so the header stays one row.
|
|
20
|
+
*/
|
|
21
|
+
export declare function tableHeaderRows<Column extends {
|
|
22
|
+
key: string;
|
|
23
|
+
}>(visible: readonly Column[], groups?: readonly TableColumnGroup[] | null): TableHeaderCell<Column>[] | null;
|
|
24
|
+
/**
|
|
25
|
+
* Each shown column's span in one row: a number above zero draws the cell over that many columns (never past the
|
|
26
|
+
* row's end), 0 marks a column a previous cell covers. A span that is not a whole number above one counts as 1.
|
|
27
|
+
*/
|
|
28
|
+
export declare function tableSpans<Column>(columns: readonly Column[], span?: ((column: Column) => number | null | undefined) | null): number[];
|
|
29
|
+
/** A column width given as a share of the table ("30%"), as a fraction; null for any other width. */
|
|
30
|
+
export declare function tablePercentWidth(width: number | string | null | undefined): number | null;
|
|
31
|
+
/**
|
|
32
|
+
* A column's width in px where the platform lays columns out itself (Native): a number or "120px" as given, a
|
|
33
|
+
* percent as that share of the table's own width, like a 100%-wide table on Web, and the fallback for anything else.
|
|
34
|
+
* Until the table has been measured (`viewport` 0) a percent column takes the fallback too.
|
|
35
|
+
*/
|
|
36
|
+
export declare function tableColumnWidth(width: number | string | null | undefined, viewport: number, fallback: number): number;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export interface TableColumnGroup {
|
|
2
|
+
/** The label over the group's columns. */
|
|
3
|
+
label: string;
|
|
4
|
+
/** Keys of the columns it spans; they are drawn where `columns` puts them. */
|
|
5
|
+
columns: string[];
|
|
6
|
+
}
|
|
7
|
+
export type TableHeaderCell<Column> = {
|
|
8
|
+
kind: "group";
|
|
9
|
+
key: string;
|
|
10
|
+
label: string;
|
|
11
|
+
span: number;
|
|
12
|
+
columns: Column[];
|
|
13
|
+
} | {
|
|
14
|
+
kind: "column";
|
|
15
|
+
column: Column;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* The header's top row when groups apply: a group over each run of its shown columns, and the other columns standing
|
|
19
|
+
* alone across both rows. null when no group holds a shown column, so the header stays one row.
|
|
20
|
+
*/
|
|
21
|
+
export declare function tableHeaderRows<Column extends {
|
|
22
|
+
key: string;
|
|
23
|
+
}>(visible: readonly Column[], groups?: readonly TableColumnGroup[] | null): TableHeaderCell<Column>[] | null;
|
|
24
|
+
/**
|
|
25
|
+
* Each shown column's span in one row: a number above zero draws the cell over that many columns (never past the
|
|
26
|
+
* row's end), 0 marks a column a previous cell covers. A span that is not a whole number above one counts as 1.
|
|
27
|
+
*/
|
|
28
|
+
export declare function tableSpans<Column>(columns: readonly Column[], span?: ((column: Column) => number | null | undefined) | null): number[];
|
|
29
|
+
/** A column width given as a share of the table ("30%"), as a fraction; null for any other width. */
|
|
30
|
+
export declare function tablePercentWidth(width: number | string | null | undefined): number | null;
|
|
31
|
+
/**
|
|
32
|
+
* A column's width in px where the platform lays columns out itself (Native): a number or "120px" as given, a
|
|
33
|
+
* percent as that share of the table's own width, like a 100%-wide table on Web, and the fallback for anything else.
|
|
34
|
+
* Until the table has been measured (`viewport` 0) a percent column takes the fallback too.
|
|
35
|
+
*/
|
|
36
|
+
export declare function tableColumnWidth(width: number | string | null | undefined, viewport: number, fallback: number): number;
|
|
@@ -16,22 +16,42 @@ export declare function sortTableRows<Row extends object>(data: readonly Row[],
|
|
|
16
16
|
export declare const tableRowKey: (row: object, rowKey: string, index?: number) => string | number;
|
|
17
17
|
/** What tells rows apart for selection: the rowKey value, or the row object itself when it has none. */
|
|
18
18
|
export declare const tableRowIdentity: (row: object, rowKey: string) => unknown;
|
|
19
|
-
|
|
19
|
+
/** Rows the app lets the user select (rowSelectable); without the rule every row can be. */
|
|
20
|
+
export type TableRowSelectable<Row extends object> = ((row: Row) => boolean) | undefined;
|
|
21
|
+
/** all and some count only the rows that can be selected, so a locked row never keeps the header box from filling. */
|
|
22
|
+
export declare function tableSelection<Row extends object>(rows: readonly Row[], selected: readonly Row[], rowKey: string, selectable?: TableRowSelectable<Row>): {
|
|
20
23
|
isSelected: (row: Row) => boolean;
|
|
24
|
+
isSelectable: (row: Row) => boolean;
|
|
21
25
|
all: boolean;
|
|
22
26
|
some: boolean;
|
|
27
|
+
selectableCount: number;
|
|
23
28
|
};
|
|
24
29
|
export declare const toggleSelectedRow: <Row extends object>(selected: readonly Row[], row: Row, rowKey: string) => Row[];
|
|
25
30
|
/**
|
|
26
31
|
* The header checkbox: with every shown row selected it clears just those rows, otherwise it adds the shown rows
|
|
27
|
-
* that are missing. Rows selected on other pages or outside the current search stay selected
|
|
32
|
+
* that are missing. Rows selected on other pages or outside the current search stay selected, and a row that cannot
|
|
33
|
+
* be selected is neither added nor removed.
|
|
28
34
|
*/
|
|
29
|
-
export declare function toggleAllRows<Row extends object>(rows: readonly Row[], selected: readonly Row[], rowKey: string, all: boolean): Row[];
|
|
35
|
+
export declare function toggleAllRows<Row extends object>(rows: readonly Row[], selected: readonly Row[], rowKey: string, all: boolean, selectable?: TableRowSelectable<Row>): Row[];
|
|
36
|
+
/**
|
|
37
|
+
* searchMode="client": the rows whose searched fields contain the query, ignoring case. Fields are searchKeys, or every
|
|
38
|
+
* column's key; a blank query keeps every row.
|
|
39
|
+
*/
|
|
40
|
+
export declare function filterTableRows<Row extends object>(rows: readonly Row[], query: string, keys: readonly string[], locale?: string): readonly Row[];
|
|
30
41
|
/** Each row's position in the sorted rows, so grouped bodies need not search for it. */
|
|
31
42
|
export declare const tableRowIndex: <Row extends object>(rows: readonly Row[]) => (row: Row) => number;
|
|
32
43
|
export declare const toggleExpandedRow: (expanded: readonly (string | number)[], id: string | number, single: boolean) => (string | number)[];
|
|
33
44
|
/** A row's name for its checkbox: the title column's text ("행 선택 한빛테크"), or its position when that is not text. */
|
|
34
45
|
export declare function tableRowLabel(row: object, titleKey: string | undefined, index: number): string | number;
|
|
46
|
+
/** The column that names a row: the card title, or the first column. */
|
|
47
|
+
export declare const tableTitleKey: (props: {
|
|
48
|
+
cardTitle?: string | null;
|
|
49
|
+
columns: readonly {
|
|
50
|
+
key: string;
|
|
51
|
+
}[];
|
|
52
|
+
}) => string;
|
|
53
|
+
/** A group's drawn name without renderGroupLabel: its value, or "-" for an empty one. */
|
|
54
|
+
export declare const tableGroupText: (value: unknown) => string;
|
|
35
55
|
/** The scroller a page-level sticky header sticks under: the nearest scrolling ancestor, or the viewport (null). */
|
|
36
56
|
export declare function stickyScroller(element: Element | null): Element | null;
|
|
37
57
|
/** Whether rows have scrolled under a page-level sticky header, measured against its own scroller. */
|
|
@@ -16,22 +16,42 @@ export declare function sortTableRows<Row extends object>(data: readonly Row[],
|
|
|
16
16
|
export declare const tableRowKey: (row: object, rowKey: string, index?: number) => string | number;
|
|
17
17
|
/** What tells rows apart for selection: the rowKey value, or the row object itself when it has none. */
|
|
18
18
|
export declare const tableRowIdentity: (row: object, rowKey: string) => unknown;
|
|
19
|
-
|
|
19
|
+
/** Rows the app lets the user select (rowSelectable); without the rule every row can be. */
|
|
20
|
+
export type TableRowSelectable<Row extends object> = ((row: Row) => boolean) | undefined;
|
|
21
|
+
/** all and some count only the rows that can be selected, so a locked row never keeps the header box from filling. */
|
|
22
|
+
export declare function tableSelection<Row extends object>(rows: readonly Row[], selected: readonly Row[], rowKey: string, selectable?: TableRowSelectable<Row>): {
|
|
20
23
|
isSelected: (row: Row) => boolean;
|
|
24
|
+
isSelectable: (row: Row) => boolean;
|
|
21
25
|
all: boolean;
|
|
22
26
|
some: boolean;
|
|
27
|
+
selectableCount: number;
|
|
23
28
|
};
|
|
24
29
|
export declare const toggleSelectedRow: <Row extends object>(selected: readonly Row[], row: Row, rowKey: string) => Row[];
|
|
25
30
|
/**
|
|
26
31
|
* The header checkbox: with every shown row selected it clears just those rows, otherwise it adds the shown rows
|
|
27
|
-
* that are missing. Rows selected on other pages or outside the current search stay selected
|
|
32
|
+
* that are missing. Rows selected on other pages or outside the current search stay selected, and a row that cannot
|
|
33
|
+
* be selected is neither added nor removed.
|
|
28
34
|
*/
|
|
29
|
-
export declare function toggleAllRows<Row extends object>(rows: readonly Row[], selected: readonly Row[], rowKey: string, all: boolean): Row[];
|
|
35
|
+
export declare function toggleAllRows<Row extends object>(rows: readonly Row[], selected: readonly Row[], rowKey: string, all: boolean, selectable?: TableRowSelectable<Row>): Row[];
|
|
36
|
+
/**
|
|
37
|
+
* searchMode="client": the rows whose searched fields contain the query, ignoring case. Fields are searchKeys, or every
|
|
38
|
+
* column's key; a blank query keeps every row.
|
|
39
|
+
*/
|
|
40
|
+
export declare function filterTableRows<Row extends object>(rows: readonly Row[], query: string, keys: readonly string[], locale?: string): readonly Row[];
|
|
30
41
|
/** Each row's position in the sorted rows, so grouped bodies need not search for it. */
|
|
31
42
|
export declare const tableRowIndex: <Row extends object>(rows: readonly Row[]) => (row: Row) => number;
|
|
32
43
|
export declare const toggleExpandedRow: (expanded: readonly (string | number)[], id: string | number, single: boolean) => (string | number)[];
|
|
33
44
|
/** A row's name for its checkbox: the title column's text ("행 선택 한빛테크"), or its position when that is not text. */
|
|
34
45
|
export declare function tableRowLabel(row: object, titleKey: string | undefined, index: number): string | number;
|
|
46
|
+
/** The column that names a row: the card title, or the first column. */
|
|
47
|
+
export declare const tableTitleKey: (props: {
|
|
48
|
+
cardTitle?: string | null;
|
|
49
|
+
columns: readonly {
|
|
50
|
+
key: string;
|
|
51
|
+
}[];
|
|
52
|
+
}) => string;
|
|
53
|
+
/** A group's drawn name without renderGroupLabel: its value, or "-" for an empty one. */
|
|
54
|
+
export declare const tableGroupText: (value: unknown) => string;
|
|
35
55
|
/** The scroller a page-level sticky header sticks under: the nearest scrolling ancestor, or the viewport (null). */
|
|
36
56
|
export declare function stickyScroller(element: Element | null): Element | null;
|
|
37
57
|
/** Whether rows have scrolled under a page-level sticky header, measured against its own scroller. */
|
|
@@ -20,9 +20,21 @@ export declare function tablePresentation<Row extends object>(props: TableProps<
|
|
|
20
20
|
footerActions: TableColumn<Row> | undefined;
|
|
21
21
|
/** One footer row holds the expand toggle and the row actions. */
|
|
22
22
|
cardFooter: boolean;
|
|
23
|
+
/** A reorderable card's move buttons end the title line unless a footer row already exists; then they join it. */
|
|
24
|
+
headerMover: boolean;
|
|
23
25
|
/** A section's field arrangement: rows cards put every field on a label-value line. */
|
|
24
26
|
cardBody(section: TableCardSection): "metrics" | "grid" | "stack" | "rows";
|
|
25
|
-
|
|
27
|
+
/**
|
|
28
|
+
* A section's fields for one row, in order. Spans are the grid's own (worked out once per row over the columns as
|
|
29
|
+
* shown), so a card leaves out exactly the fields the grid covers. A cell that spans other columns is a note about
|
|
30
|
+
* them, not the first column's value: it takes the whole line under its section's name (a column group's label),
|
|
31
|
+
* or no name without one.
|
|
32
|
+
*/
|
|
33
|
+
cardFields(row: Row, section: TableCardSection): {
|
|
34
|
+
column: TableColumn<Row>;
|
|
35
|
+
label: string;
|
|
36
|
+
full: boolean;
|
|
37
|
+
}[];
|
|
26
38
|
};
|
|
27
39
|
/** Narrow layouts have no header row to sort by, so the toolbar offers each sortable column in both orders. */
|
|
28
40
|
export declare function tableSortOptions<Row extends object>(props: TableProps<Row, unknown>, messages: {
|
|
@@ -63,18 +75,22 @@ export interface TableGroupingProps<Row extends object> {
|
|
|
63
75
|
summary: ((column: TableColumn<Row>, rows: Row[]) => ReactNode) | null;
|
|
64
76
|
}
|
|
65
77
|
/** Card parts: a card value starts at its label (cardValue) or ends a label-value line (cardRowValue); tiles use smaller titles and highlights. */
|
|
66
|
-
export type TableCellRole = "title" | "listTitle" | "listMeta" | "listValue" | "cardValue" | "cardRowValue" | "cardSubtitle" | "cardHighlight" | "tileTitle" | "tileHighlight";
|
|
78
|
+
export type TableCellRole = "title" | "listTitle" | "listMeta" | "listValue" | "cardValue" | "cardRowValue" | "cardSubtitle" | "cardHighlight" | "tileTitle" | "tileHighlight" | "merged";
|
|
79
|
+
/** A narrow layout's title opens the row when the row is clickable, so a cell drawn there is then never a button of its own. */
|
|
80
|
+
export declare const tableOpenerRole: (role?: TableCellRole) => role is "title" | "listTitle" | "tileTitle";
|
|
67
81
|
export interface TableRowsProps<Row extends object> {
|
|
68
82
|
initialLoading: boolean;
|
|
69
83
|
skeletonRows: number;
|
|
70
84
|
/** A loadingDelay is still running: the skeleton keeps its space but stays out of sight. */
|
|
71
85
|
skeletonHidden?: boolean;
|
|
72
|
-
state: Pick<ReturnType<typeof useTableModel<Row>>, "rows" | "rowIndex" | "key" | "expanded" | "selectedRow">;
|
|
86
|
+
state: Pick<ReturnType<typeof useTableModel<Row>>, "rows" | "rowIndex" | "key" | "expanded" | "selectedRow" | "selectableRow">;
|
|
73
87
|
onRowClick: TableProps<Row>["onRowClick"];
|
|
74
88
|
selectable: boolean;
|
|
75
89
|
expandable: boolean;
|
|
76
90
|
checkbox: (row: Row, index: number) => ReactNode;
|
|
77
91
|
expand: (row: Row, index: number) => ReactNode;
|
|
92
|
+
/** A reorderable table's move buttons for a row: the grid's last column, a card's footer or a list row's end. */
|
|
93
|
+
mover?: (row: Row, index: number) => ReactNode;
|
|
78
94
|
cell: (column: TableColumn<Row>, row: Row, index: number, role?: TableCellRole) => ReactNode;
|
|
79
95
|
renderExpand: TableProps<Row>["renderExpand"];
|
|
80
96
|
emptyContent: ReactNode;
|
|
@@ -89,11 +105,23 @@ export interface TableCardsProps<Row extends object> extends TableRowsProps<Row>
|
|
|
89
105
|
toggleGroup?: (key: string) => void;
|
|
90
106
|
groupLabel?: (group: TableRowGroup<Row>) => ReactNode;
|
|
91
107
|
groupTotals?: (rows: Row[]) => TableTotal[];
|
|
108
|
+
/** Native: the list's name (the web layouts take it with TableViewParts). */
|
|
109
|
+
ariaLabel?: string;
|
|
92
110
|
/** The cell's plain text, for a value read out with its label where the label is not drawn (tile highlight on Native). */
|
|
93
111
|
cellText?: (column: TableColumn<Row>, row: Row, index: number) => string | undefined;
|
|
94
112
|
}
|
|
113
|
+
/** The view's own parts that every layout takes: its name, a row's custom class and the row key handler. */
|
|
114
|
+
export interface TableViewParts<Row extends object, KeyEvent> {
|
|
115
|
+
ariaLabel: string;
|
|
116
|
+
customClass: (row: Row, index: number) => string;
|
|
117
|
+
rowKeyDown: (event: KeyEvent, row: Row, index: number) => void;
|
|
118
|
+
}
|
|
95
119
|
export interface TableGridProps<Row extends object, Height> extends TableRowsProps<Row>, TableGroupingProps<Row> {
|
|
96
|
-
|
|
120
|
+
/** Labels over runs of columns (TableProps.columnGroups). */
|
|
121
|
+
columnGroups?: TableProps<Row>["columnGroups"];
|
|
122
|
+
/** How many columns a row's cell covers (TableProps.cellSpan). */
|
|
123
|
+
cellSpan?: TableProps<Row>["cellSpan"];
|
|
124
|
+
state: TableRowsProps<Row>["state"] & Pick<ReturnType<typeof useTableModel<Row>>, "all" | "some" | "selectableCount" | "toggleAll" | "sort" | "sortColumn">;
|
|
97
125
|
visible: TableColumn<Row>[];
|
|
98
126
|
maxHeight?: Height;
|
|
99
127
|
stickyHeader: boolean;
|
|
@@ -102,6 +130,7 @@ export interface TableGridProps<Row extends object, Height> extends TableRowsPro
|
|
|
102
130
|
compact: boolean;
|
|
103
131
|
striped: boolean;
|
|
104
132
|
hoverable: boolean;
|
|
133
|
+
edgeInset?: "default" | "none";
|
|
105
134
|
}
|
|
106
135
|
export interface TableToolbarProps<Row extends object> {
|
|
107
136
|
selectable: boolean;
|
|
@@ -20,9 +20,21 @@ export declare function tablePresentation<Row extends object>(props: TableProps<
|
|
|
20
20
|
footerActions: TableColumn<Row> | undefined;
|
|
21
21
|
/** One footer row holds the expand toggle and the row actions. */
|
|
22
22
|
cardFooter: boolean;
|
|
23
|
+
/** A reorderable card's move buttons end the title line unless a footer row already exists; then they join it. */
|
|
24
|
+
headerMover: boolean;
|
|
23
25
|
/** A section's field arrangement: rows cards put every field on a label-value line. */
|
|
24
26
|
cardBody(section: TableCardSection): "metrics" | "grid" | "stack" | "rows";
|
|
25
|
-
|
|
27
|
+
/**
|
|
28
|
+
* A section's fields for one row, in order. Spans are the grid's own (worked out once per row over the columns as
|
|
29
|
+
* shown), so a card leaves out exactly the fields the grid covers. A cell that spans other columns is a note about
|
|
30
|
+
* them, not the first column's value: it takes the whole line under its section's name (a column group's label),
|
|
31
|
+
* or no name without one.
|
|
32
|
+
*/
|
|
33
|
+
cardFields(row: Row, section: TableCardSection): {
|
|
34
|
+
column: TableColumn<Row>;
|
|
35
|
+
label: string;
|
|
36
|
+
full: boolean;
|
|
37
|
+
}[];
|
|
26
38
|
};
|
|
27
39
|
/** Narrow layouts have no header row to sort by, so the toolbar offers each sortable column in both orders. */
|
|
28
40
|
export declare function tableSortOptions<Row extends object>(props: TableProps<Row, unknown>, messages: {
|
|
@@ -63,18 +75,22 @@ export interface TableGroupingProps<Row extends object> {
|
|
|
63
75
|
summary: ((column: TableColumn<Row>, rows: Row[]) => ReactNode) | null;
|
|
64
76
|
}
|
|
65
77
|
/** Card parts: a card value starts at its label (cardValue) or ends a label-value line (cardRowValue); tiles use smaller titles and highlights. */
|
|
66
|
-
export type TableCellRole = "title" | "listTitle" | "listMeta" | "listValue" | "cardValue" | "cardRowValue" | "cardSubtitle" | "cardHighlight" | "tileTitle" | "tileHighlight";
|
|
78
|
+
export type TableCellRole = "title" | "listTitle" | "listMeta" | "listValue" | "cardValue" | "cardRowValue" | "cardSubtitle" | "cardHighlight" | "tileTitle" | "tileHighlight" | "merged";
|
|
79
|
+
/** A narrow layout's title opens the row when the row is clickable, so a cell drawn there is then never a button of its own. */
|
|
80
|
+
export declare const tableOpenerRole: (role?: TableCellRole) => role is "title" | "listTitle" | "tileTitle";
|
|
67
81
|
export interface TableRowsProps<Row extends object> {
|
|
68
82
|
initialLoading: boolean;
|
|
69
83
|
skeletonRows: number;
|
|
70
84
|
/** A loadingDelay is still running: the skeleton keeps its space but stays out of sight. */
|
|
71
85
|
skeletonHidden?: boolean;
|
|
72
|
-
state: Pick<ReturnType<typeof useTableModel<Row>>, "rows" | "rowIndex" | "key" | "expanded" | "selectedRow">;
|
|
86
|
+
state: Pick<ReturnType<typeof useTableModel<Row>>, "rows" | "rowIndex" | "key" | "expanded" | "selectedRow" | "selectableRow">;
|
|
73
87
|
onRowClick: TableProps<Row>["onRowClick"];
|
|
74
88
|
selectable: boolean;
|
|
75
89
|
expandable: boolean;
|
|
76
90
|
checkbox: (row: Row, index: number) => ReactNode;
|
|
77
91
|
expand: (row: Row, index: number) => ReactNode;
|
|
92
|
+
/** A reorderable table's move buttons for a row: the grid's last column, a card's footer or a list row's end. */
|
|
93
|
+
mover?: (row: Row, index: number) => ReactNode;
|
|
78
94
|
cell: (column: TableColumn<Row>, row: Row, index: number, role?: TableCellRole) => ReactNode;
|
|
79
95
|
renderExpand: TableProps<Row>["renderExpand"];
|
|
80
96
|
emptyContent: ReactNode;
|
|
@@ -89,11 +105,23 @@ export interface TableCardsProps<Row extends object> extends TableRowsProps<Row>
|
|
|
89
105
|
toggleGroup?: (key: string) => void;
|
|
90
106
|
groupLabel?: (group: TableRowGroup<Row>) => ReactNode;
|
|
91
107
|
groupTotals?: (rows: Row[]) => TableTotal[];
|
|
108
|
+
/** Native: the list's name (the web layouts take it with TableViewParts). */
|
|
109
|
+
ariaLabel?: string;
|
|
92
110
|
/** The cell's plain text, for a value read out with its label where the label is not drawn (tile highlight on Native). */
|
|
93
111
|
cellText?: (column: TableColumn<Row>, row: Row, index: number) => string | undefined;
|
|
94
112
|
}
|
|
113
|
+
/** The view's own parts that every layout takes: its name, a row's custom class and the row key handler. */
|
|
114
|
+
export interface TableViewParts<Row extends object, KeyEvent> {
|
|
115
|
+
ariaLabel: string;
|
|
116
|
+
customClass: (row: Row, index: number) => string;
|
|
117
|
+
rowKeyDown: (event: KeyEvent, row: Row, index: number) => void;
|
|
118
|
+
}
|
|
95
119
|
export interface TableGridProps<Row extends object, Height> extends TableRowsProps<Row>, TableGroupingProps<Row> {
|
|
96
|
-
|
|
120
|
+
/** Labels over runs of columns (TableProps.columnGroups). */
|
|
121
|
+
columnGroups?: TableProps<Row>["columnGroups"];
|
|
122
|
+
/** How many columns a row's cell covers (TableProps.cellSpan). */
|
|
123
|
+
cellSpan?: TableProps<Row>["cellSpan"];
|
|
124
|
+
state: TableRowsProps<Row>["state"] & Pick<ReturnType<typeof useTableModel<Row>>, "all" | "some" | "selectableCount" | "toggleAll" | "sort" | "sortColumn">;
|
|
97
125
|
visible: TableColumn<Row>[];
|
|
98
126
|
maxHeight?: Height;
|
|
99
127
|
stickyHeader: boolean;
|
|
@@ -102,6 +130,7 @@ export interface TableGridProps<Row extends object, Height> extends TableRowsPro
|
|
|
102
130
|
compact: boolean;
|
|
103
131
|
striped: boolean;
|
|
104
132
|
hoverable: boolean;
|
|
133
|
+
edgeInset?: "default" | "none";
|
|
105
134
|
}
|
|
106
135
|
export interface TableToolbarProps<Row extends object> {
|
|
107
136
|
selectable: boolean;
|