@lt-ui/uikit 0.0.0-stage → 0.0.2
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/_internal/base-button/base-button.d.ts +9 -0
- package/_internal/base-button/base-button.js +47 -0
- package/_internal/base-button/index.d.ts +2 -0
- package/_internal/base-button/index.js +1 -0
- package/_internal/base-button/styles.module.css +69 -0
- package/_internal/base-button/types.d.ts +42 -0
- package/_internal/base-button/types.js +1 -0
- package/_internal/collapse-box/collapse-box.d.ts +60 -0
- package/_internal/collapse-box/collapse-box.js +30 -0
- package/_internal/collapse-box/index.d.ts +2 -0
- package/_internal/collapse-box/index.js +1 -0
- package/_internal/collapse-box/styles.module.css +30 -0
- package/_internal/compat/context-provider.d.ts +17 -0
- package/_internal/compat/context-provider.js +13 -0
- package/_internal/compat/index.d.ts +4 -0
- package/_internal/compat/index.js +4 -0
- package/_internal/compat/react-version.d.ts +5 -0
- package/_internal/compat/react-version.js +6 -0
- package/_internal/compat/use-form-pending.d.ts +5 -0
- package/_internal/compat/use-form-pending.js +8 -0
- package/_internal/compat/with-ref.d.ts +10 -0
- package/_internal/compat/with-ref.js +22 -0
- package/_internal/context-selector/context-selector.d.ts +27 -0
- package/_internal/context-selector/context-selector.js +71 -0
- package/_internal/context-selector/index.d.ts +2 -0
- package/_internal/context-selector/index.js +1 -0
- package/_internal/date/date-format.d.ts +24 -0
- package/_internal/date/date-format.js +122 -0
- package/_internal/date/date-locale.d.ts +21 -0
- package/_internal/date/date-locale.js +60 -0
- package/_internal/date/date-utils.d.ts +44 -0
- package/_internal/date/date-utils.js +75 -0
- package/_internal/date/index.d.ts +3 -0
- package/_internal/date/index.js +3 -0
- package/_internal/empty-function.d.ts +1 -0
- package/_internal/empty-function.js +4 -0
- package/_internal/field/_motion.css +0 -0
- package/_internal/field/field-caption.d.ts +12 -0
- package/_internal/field/field-caption.js +5 -0
- package/_internal/field/field-clear-button.d.ts +16 -0
- package/_internal/field/field-clear-button.js +14 -0
- package/_internal/field/field-frame.d.ts +34 -0
- package/_internal/field/field-frame.js +36 -0
- package/_internal/field/field.module.css +353 -0
- package/_internal/field/index.d.ts +7 -0
- package/_internal/field/index.js +7 -0
- package/_internal/field/props.d.ts +81 -0
- package/_internal/field/props.js +1 -0
- package/_internal/field/types.d.ts +54 -0
- package/_internal/field/types.js +1 -0
- package/_internal/field/use-field-state.d.ts +38 -0
- package/_internal/field/use-field-state.js +46 -0
- package/_internal/floating/compute-position.d.ts +11 -0
- package/_internal/floating/compute-position.js +112 -0
- package/_internal/floating/index.d.ts +4 -0
- package/_internal/floating/index.js +2 -0
- package/_internal/floating/origin.d.ts +6 -0
- package/_internal/floating/origin.js +18 -0
- package/_internal/floating/types.d.ts +52 -0
- package/_internal/floating/types.js +1 -0
- package/_internal/floating/use-floating.d.ts +35 -0
- package/_internal/floating/use-floating.js +149 -0
- package/_internal/focus-trap/focus-trap.d.ts +25 -0
- package/_internal/focus-trap/focus-trap.js +111 -0
- package/_internal/focus-trap/index.d.ts +3 -0
- package/_internal/focus-trap/index.js +3 -0
- package/_internal/focus-trap/scroll-lock.d.ts +2 -0
- package/_internal/focus-trap/scroll-lock.js +32 -0
- package/_internal/focus-trap/tabbable.d.ts +2 -0
- package/_internal/focus-trap/tabbable.js +25 -0
- package/_internal/hooks/focus-when-ready.d.ts +6 -0
- package/_internal/hooks/focus-when-ready.js +21 -0
- package/_internal/hooks/index.d.ts +15 -0
- package/_internal/hooks/index.js +15 -0
- package/_internal/hooks/restore-focus.d.ts +6 -0
- package/_internal/hooks/restore-focus.js +11 -0
- package/_internal/hooks/use-arrow-navigation.d.ts +14 -0
- package/_internal/hooks/use-arrow-navigation.js +35 -0
- package/_internal/hooks/use-chips-nav.d.ts +22 -0
- package/_internal/hooks/use-chips-nav.js +100 -0
- package/_internal/hooks/use-collapse-motion.d.ts +30 -0
- package/_internal/hooks/use-collapse-motion.js +102 -0
- package/_internal/hooks/use-controllable-state.d.ts +13 -0
- package/_internal/hooks/use-controllable-state.js +28 -0
- package/_internal/hooks/use-effect-once.d.ts +2 -0
- package/_internal/hooks/use-effect-once.js +4 -0
- package/_internal/hooks/use-focus-on-context.d.ts +2 -0
- package/_internal/hooks/use-focus-on-context.js +4 -0
- package/_internal/hooks/use-focus-on-ignore.d.ts +8 -0
- package/_internal/hooks/use-focus-on-ignore.js +19 -0
- package/_internal/hooks/use-focused-state.d.ts +5 -0
- package/_internal/hooks/use-focused-state.js +8 -0
- package/_internal/hooks/use-popover-tab-flow.d.ts +18 -0
- package/_internal/hooks/use-popover-tab-flow.js +55 -0
- package/_internal/hooks/use-resize-observer.d.ts +2 -0
- package/_internal/hooks/use-resize-observer.js +24 -0
- package/_internal/hooks/use-return-focus.d.ts +15 -0
- package/_internal/hooks/use-return-focus.js +25 -0
- package/_internal/hooks/use-scroll-edges.d.ts +6 -0
- package/_internal/hooks/use-scroll-edges.js +28 -0
- package/_internal/hooks/use-synced-animation.d.ts +12 -0
- package/_internal/hooks/use-synced-animation.js +28 -0
- package/_internal/layer/index.d.ts +2 -0
- package/_internal/layer/index.js +2 -0
- package/_internal/layer/layer-manager.d.ts +47 -0
- package/_internal/layer/layer-manager.js +93 -0
- package/_internal/layer/use-layer.d.ts +13 -0
- package/_internal/layer/use-layer.js +30 -0
- package/_internal/picker/index.d.ts +5 -0
- package/_internal/picker/index.js +5 -0
- package/_internal/picker/picker-field.d.ts +77 -0
- package/_internal/picker/picker-field.js +23 -0
- package/_internal/picker/picker-field.module.css +28 -0
- package/_internal/picker/picker-sheet-search.d.ts +9 -0
- package/_internal/picker/picker-sheet-search.js +11 -0
- package/_internal/picker/picker-sheet.d.ts +30 -0
- package/_internal/picker/picker-sheet.js +14 -0
- package/_internal/picker/picker-sheet.module.css +11 -0
- package/_internal/picker/use-date-input.d.ts +27 -0
- package/_internal/picker/use-date-input.js +74 -0
- package/_internal/picker/use-picker-presentation.d.ts +25 -0
- package/_internal/picker/use-picker-presentation.js +30 -0
- package/_internal/transition/css-transition.d.ts +22 -0
- package/_internal/transition/css-transition.js +67 -0
- package/_internal/transition/index.d.ts +3 -0
- package/_internal/transition/index.js +3 -0
- package/_internal/transition/transition-group-context.d.ts +4 -0
- package/_internal/transition/transition-group-context.js +4 -0
- package/_internal/transition/transition-group.d.ts +20 -0
- package/_internal/transition/transition-group.js +126 -0
- package/_internal/transition/transition.d.ts +40 -0
- package/_internal/transition/transition.js +125 -0
- package/accordion/accordion-item.d.ts +289 -0
- package/accordion/accordion-item.js +16 -0
- package/accordion/accordion.d.ts +301 -0
- package/accordion/accordion.js +16 -0
- package/accordion/constants.d.ts +2 -0
- package/accordion/constants.js +2 -0
- package/accordion/context.d.ts +17 -0
- package/accordion/context.js +3 -0
- package/accordion/hooks/use-accordion-item-view-model.d.ts +45 -0
- package/accordion/hooks/use-accordion-item-view-model.js +223 -0
- package/accordion/hooks/use-accordion-view-model.d.ts +25 -0
- package/accordion/hooks/use-accordion-view-model.js +121 -0
- package/accordion/index.d.ts +3 -0
- package/accordion/index.js +2 -0
- package/accordion/store.d.ts +22 -0
- package/accordion/store.js +42 -0
- package/accordion/styles.module.css +182 -0
- package/accordion/types.d.ts +196 -0
- package/accordion/types.js +1 -0
- package/accordion/utils.d.ts +29 -0
- package/accordion/utils.js +111 -0
- package/accordion/views/accordion-item-view.d.ts +6 -0
- package/accordion/views/accordion-item-view.js +22 -0
- package/accordion/views/accordion-view.d.ts +7 -0
- package/accordion/views/accordion-view.js +18 -0
- package/adaptive/adaptive.d.ts +20 -0
- package/adaptive/adaptive.js +14 -0
- package/adaptive/adaptive.module.css +189 -0
- package/adaptive/index.d.ts +2 -0
- package/adaptive/index.js +1 -0
- package/adaptive/types.d.ts +35 -0
- package/adaptive/types.js +1 -0
- package/alert/alert-actions.d.ts +6 -0
- package/alert/alert-actions.js +22 -0
- package/alert/alert-content.d.ts +6 -0
- package/alert/alert-content.js +15 -0
- package/alert/alert-icon.d.ts +4 -0
- package/alert/alert-icon.js +9 -0
- package/alert/alert.d.ts +11 -0
- package/alert/alert.js +41 -0
- package/alert/index.d.ts +2 -0
- package/alert/index.js +1 -0
- package/alert/styles/alert-variants.module.css +38 -0
- package/alert/styles/alert.module.css +51 -0
- package/alert/types.d.ts +69 -0
- package/alert/types.js +1 -0
- package/alert/use-alert.d.ts +8 -0
- package/alert/use-alert.js +14 -0
- package/avatar/avatar-group.d.ts +47 -0
- package/avatar/avatar-group.js +31 -0
- package/avatar/avatar-group.module.css +13 -0
- package/avatar/avatar-inner.d.ts +2 -0
- package/avatar/avatar-inner.js +24 -0
- package/avatar/avatar.d.ts +10 -0
- package/avatar/avatar.js +68 -0
- package/avatar/constants.d.ts +6 -0
- package/avatar/constants.js +5 -0
- package/avatar/index.d.ts +3 -0
- package/avatar/index.js +2 -0
- package/avatar/styles.module.css +292 -0
- package/avatar/types.d.ts +87 -0
- package/avatar/types.js +1 -0
- package/avatar/utils.d.ts +4 -0
- package/avatar/utils.js +10 -0
- package/badge/badge.d.ts +23 -0
- package/badge/badge.js +31 -0
- package/badge/index.d.ts +2 -0
- package/badge/index.js +2 -0
- package/badge/styles.module.css +114 -0
- package/badge/types.d.ts +58 -0
- package/badge/types.js +1 -0
- package/breadcrumbs/breadcrumbs-context.d.ts +7 -0
- package/breadcrumbs/breadcrumbs-context.js +6 -0
- package/breadcrumbs/breadcrumbs-item.d.ts +6 -0
- package/breadcrumbs/breadcrumbs-item.js +18 -0
- package/breadcrumbs/breadcrumbs-menu.d.ts +12 -0
- package/breadcrumbs/breadcrumbs-menu.js +12 -0
- package/breadcrumbs/breadcrumbs.d.ts +28 -0
- package/breadcrumbs/breadcrumbs.js +61 -0
- package/breadcrumbs/index.d.ts +3 -0
- package/breadcrumbs/index.js +2 -0
- package/breadcrumbs/styles.module.css +190 -0
- package/breadcrumbs/types.d.ts +81 -0
- package/breadcrumbs/types.js +1 -0
- package/breadcrumbs/use-breadcrumbs-fit.d.ts +21 -0
- package/breadcrumbs/use-breadcrumbs-fit.js +43 -0
- package/breadcrumbs/use-breadcrumbs.d.ts +21 -0
- package/breadcrumbs/use-breadcrumbs.js +41 -0
- package/button/button.d.ts +13 -0
- package/button/button.js +45 -0
- package/button/close-button.d.ts +14 -0
- package/button/close-button.js +17 -0
- package/button/index.d.ts +7 -0
- package/button/index.js +5 -0
- package/button/styles.module.css +288 -0
- package/button/types.d.ts +95 -0
- package/button/types.js +1 -0
- package/button/use-button.d.ts +22 -0
- package/button/use-button.js +35 -0
- package/calendar/availability.d.ts +14 -0
- package/calendar/availability.js +30 -0
- package/calendar/calendar-header.d.ts +20 -0
- package/calendar/calendar-header.js +40 -0
- package/calendar/calendar.d.ts +11 -0
- package/calendar/calendar.js +35 -0
- package/calendar/day-grid.d.ts +13 -0
- package/calendar/day-grid.js +21 -0
- package/calendar/index.d.ts +6 -0
- package/calendar/index.js +3 -0
- package/calendar/labels.d.ts +4 -0
- package/calendar/labels.js +12 -0
- package/calendar/picker-grid.d.ts +15 -0
- package/calendar/picker-grid.js +63 -0
- package/calendar/selection.d.ts +17 -0
- package/calendar/selection.js +50 -0
- package/calendar/styles.module.css +283 -0
- package/calendar/types.d.ts +169 -0
- package/calendar/types.js +1 -0
- package/calendar/use-calendar.d.ts +74 -0
- package/calendar/use-calendar.js +397 -0
- package/caption/caption.d.ts +16 -0
- package/caption/caption.js +27 -0
- package/caption/index.d.ts +2 -0
- package/caption/index.js +1 -0
- package/caption/styles.module.css +33 -0
- package/caption/types.d.ts +30 -0
- package/caption/types.js +1 -0
- package/card/card.d.ts +19 -0
- package/card/card.js +31 -0
- package/card/index.d.ts +2 -0
- package/card/index.js +1 -0
- package/card/styles.module.css +80 -0
- package/card/types.d.ts +49 -0
- package/card/types.js +1 -0
- package/card/use-card.d.ts +24 -0
- package/card/use-card.js +36 -0
- package/checkbox/checkbox.d.ts +10 -0
- package/checkbox/checkbox.js +54 -0
- package/checkbox/index.d.ts +2 -0
- package/checkbox/index.js +1 -0
- package/checkbox/styles/style.module.css +257 -0
- package/checkbox/types.d.ts +68 -0
- package/checkbox/types.js +1 -0
- package/chip/chip.d.ts +40 -0
- package/chip/chip.js +63 -0
- package/chip/index.d.ts +2 -0
- package/chip/index.js +1 -0
- package/chip/styles.module.css +65 -0
- package/chip/types.d.ts +45 -0
- package/chip/types.js +1 -0
- package/chip-group/chip-group-transition-context.d.ts +9 -0
- package/chip-group/chip-group-transition-context.js +8 -0
- package/chip-group/chip-group-transition-provider.d.ts +6 -0
- package/chip-group/chip-group-transition-provider.js +11 -0
- package/chip-group/chip-group.d.ts +4 -0
- package/chip-group/chip-group.js +33 -0
- package/chip-group/index.d.ts +2 -0
- package/chip-group/index.js +1 -0
- package/chip-group/styles.module.css +4 -0
- package/chip-group/types.d.ts +5 -0
- package/chip-group/types.js +1 -0
- package/cjs/_internal/base-button/base-button.js +86 -0
- package/cjs/_internal/base-button/index.js +17 -0
- package/cjs/_internal/base-button/styles.module.css +69 -0
- package/cjs/_internal/base-button/types.js +2 -0
- package/cjs/_internal/collapse-box/collapse-box.js +69 -0
- package/cjs/_internal/collapse-box/index.js +5 -0
- package/cjs/_internal/collapse-box/styles.module.css +30 -0
- package/cjs/_internal/compat/context-provider.js +17 -0
- package/cjs/_internal/compat/index.js +11 -0
- package/cjs/_internal/compat/react-version.js +9 -0
- package/cjs/_internal/compat/use-form-pending.js +45 -0
- package/cjs/_internal/compat/with-ref.js +26 -0
- package/cjs/_internal/context-selector/context-selector.js +75 -0
- package/cjs/_internal/context-selector/index.js +6 -0
- package/cjs/_internal/date/date-format.js +129 -0
- package/cjs/_internal/date/date-locale.js +71 -0
- package/cjs/_internal/date/date-utils.js +104 -0
- package/cjs/_internal/date/index.js +19 -0
- package/cjs/_internal/empty-function.js +8 -0
- package/cjs/_internal/field/_motion.css +0 -0
- package/cjs/_internal/field/field-caption.js +12 -0
- package/cjs/_internal/field/field-clear-button.js +17 -0
- package/cjs/_internal/field/field-frame.js +42 -0
- package/cjs/_internal/field/field.module.css +353 -0
- package/cjs/_internal/field/index.js +17 -0
- package/cjs/_internal/field/props.js +2 -0
- package/cjs/_internal/field/types.js +2 -0
- package/cjs/_internal/field/use-field-state.js +49 -0
- package/cjs/_internal/floating/compute-position.js +118 -0
- package/cjs/_internal/floating/index.js +9 -0
- package/cjs/_internal/floating/origin.js +21 -0
- package/cjs/_internal/floating/types.js +2 -0
- package/cjs/_internal/floating/use-floating.js +152 -0
- package/cjs/_internal/focus-trap/focus-trap.js +148 -0
- package/cjs/_internal/focus-trap/index.js +19 -0
- package/cjs/_internal/focus-trap/scroll-lock.js +35 -0
- package/cjs/_internal/focus-trap/tabbable.js +28 -0
- package/cjs/_internal/hooks/focus-when-ready.js +24 -0
- package/cjs/_internal/hooks/index.js +31 -0
- package/cjs/_internal/hooks/restore-focus.js +14 -0
- package/cjs/_internal/hooks/use-arrow-navigation.js +38 -0
- package/cjs/_internal/hooks/use-chips-nav.js +106 -0
- package/cjs/_internal/hooks/use-collapse-motion.js +108 -0
- package/cjs/_internal/hooks/use-controllable-state.js +31 -0
- package/cjs/_internal/hooks/use-effect-once.js +8 -0
- package/cjs/_internal/hooks/use-focus-on-context.js +8 -0
- package/cjs/_internal/hooks/use-focus-on-ignore.js +23 -0
- package/cjs/_internal/hooks/use-focused-state.js +11 -0
- package/cjs/_internal/hooks/use-popover-tab-flow.js +60 -0
- package/cjs/_internal/hooks/use-resize-observer.js +28 -0
- package/cjs/_internal/hooks/use-return-focus.js +28 -0
- package/cjs/_internal/hooks/use-scroll-edges.js +31 -0
- package/cjs/_internal/hooks/use-synced-animation.js +32 -0
- package/cjs/_internal/layer/index.js +18 -0
- package/cjs/_internal/layer/layer-manager.js +96 -0
- package/cjs/_internal/layer/use-layer.js +33 -0
- package/cjs/_internal/picker/index.js +21 -0
- package/cjs/_internal/picker/picker-field.js +29 -0
- package/cjs/_internal/picker/picker-field.module.css +28 -0
- package/cjs/_internal/picker/picker-sheet-search.js +17 -0
- package/cjs/_internal/picker/picker-sheet.js +20 -0
- package/cjs/_internal/picker/picker-sheet.module.css +11 -0
- package/cjs/_internal/picker/use-date-input.js +77 -0
- package/cjs/_internal/picker/use-picker-presentation.js +35 -0
- package/cjs/_internal/transition/css-transition.js +70 -0
- package/cjs/_internal/transition/index.js +19 -0
- package/cjs/_internal/transition/transition-group-context.js +7 -0
- package/cjs/_internal/transition/transition-group.js +162 -0
- package/cjs/_internal/transition/transition.js +129 -0
- package/cjs/accordion/accordion-item.js +22 -0
- package/cjs/accordion/accordion.js +22 -0
- package/cjs/accordion/constants.js +5 -0
- package/cjs/accordion/context.js +6 -0
- package/cjs/accordion/hooks/use-accordion-item-view-model.js +227 -0
- package/cjs/accordion/hooks/use-accordion-view-model.js +127 -0
- package/cjs/accordion/index.js +7 -0
- package/cjs/accordion/store.js +45 -0
- package/cjs/accordion/styles.module.css +182 -0
- package/cjs/accordion/types.js +2 -0
- package/cjs/accordion/utils.js +123 -0
- package/cjs/accordion/views/accordion-item-view.js +28 -0
- package/cjs/accordion/views/accordion-view.js +24 -0
- package/cjs/adaptive/adaptive.js +53 -0
- package/cjs/adaptive/adaptive.module.css +189 -0
- package/cjs/adaptive/index.js +17 -0
- package/cjs/adaptive/types.js +2 -0
- package/cjs/alert/alert-actions.js +29 -0
- package/cjs/alert/alert-content.js +22 -0
- package/cjs/alert/alert-icon.js +16 -0
- package/cjs/alert/alert.js +47 -0
- package/cjs/alert/index.js +17 -0
- package/cjs/alert/styles/alert-variants.module.css +38 -0
- package/cjs/alert/styles/alert.module.css +51 -0
- package/cjs/alert/types.js +2 -0
- package/cjs/alert/use-alert.js +17 -0
- package/cjs/avatar/avatar-group.js +37 -0
- package/cjs/avatar/avatar-group.module.css +13 -0
- package/cjs/avatar/avatar-inner.js +31 -0
- package/cjs/avatar/avatar.js +107 -0
- package/cjs/avatar/constants.js +8 -0
- package/cjs/avatar/index.js +18 -0
- package/cjs/avatar/styles.module.css +292 -0
- package/cjs/avatar/types.js +2 -0
- package/cjs/avatar/utils.js +16 -0
- package/cjs/badge/badge.js +37 -0
- package/cjs/badge/index.js +18 -0
- package/cjs/badge/styles.module.css +114 -0
- package/cjs/badge/types.js +2 -0
- package/cjs/breadcrumbs/breadcrumbs-context.js +10 -0
- package/cjs/breadcrumbs/breadcrumbs-item.js +24 -0
- package/cjs/breadcrumbs/breadcrumbs-menu.js +18 -0
- package/cjs/breadcrumbs/breadcrumbs.js +100 -0
- package/cjs/breadcrumbs/index.js +7 -0
- package/cjs/breadcrumbs/styles.module.css +190 -0
- package/cjs/breadcrumbs/types.js +2 -0
- package/cjs/breadcrumbs/use-breadcrumbs-fit.js +46 -0
- package/cjs/breadcrumbs/use-breadcrumbs.js +77 -0
- package/cjs/button/button.js +51 -0
- package/cjs/button/close-button.js +24 -0
- package/cjs/button/index.js +23 -0
- package/cjs/button/styles.module.css +288 -0
- package/cjs/button/types.js +2 -0
- package/cjs/button/use-button.js +41 -0
- package/cjs/calendar/availability.js +35 -0
- package/cjs/calendar/calendar-header.js +46 -0
- package/cjs/calendar/calendar.js +41 -0
- package/cjs/calendar/day-grid.js +27 -0
- package/cjs/calendar/index.js +11 -0
- package/cjs/calendar/labels.js +16 -0
- package/cjs/calendar/picker-grid.js +69 -0
- package/cjs/calendar/selection.js +59 -0
- package/cjs/calendar/styles.module.css +283 -0
- package/cjs/calendar/types.js +2 -0
- package/cjs/calendar/use-calendar.js +400 -0
- package/cjs/caption/caption.js +66 -0
- package/cjs/caption/index.js +17 -0
- package/cjs/caption/styles.module.css +33 -0
- package/cjs/caption/types.js +2 -0
- package/cjs/card/card.js +37 -0
- package/cjs/card/index.js +17 -0
- package/cjs/card/styles.module.css +80 -0
- package/cjs/card/types.js +2 -0
- package/cjs/card/use-card.js +39 -0
- package/cjs/checkbox/checkbox.js +60 -0
- package/cjs/checkbox/index.js +17 -0
- package/cjs/checkbox/styles/style.module.css +257 -0
- package/cjs/checkbox/types.js +2 -0
- package/cjs/chip/chip.js +102 -0
- package/cjs/chip/index.js +5 -0
- package/cjs/chip/styles.module.css +65 -0
- package/cjs/chip/types.js +2 -0
- package/cjs/chip-group/chip-group-transition-context.js +14 -0
- package/cjs/chip-group/chip-group-transition-provider.js +18 -0
- package/cjs/chip-group/chip-group.js +74 -0
- package/cjs/chip-group/index.js +5 -0
- package/cjs/chip-group/styles.module.css +4 -0
- package/cjs/chip-group/types.js +2 -0
- package/cjs/container/container.js +46 -0
- package/cjs/container/index.js +17 -0
- package/cjs/container/styles.module.css +85 -0
- package/cjs/container/types.js +2 -0
- package/cjs/css-baseline/css-baseline.js +11 -0
- package/cjs/css-baseline/index.js +17 -0
- package/cjs/css-baseline/styles.css +36 -0
- package/cjs/date-picker/date-picker-panel.js +42 -0
- package/cjs/date-picker/date-picker-sheet-footer.js +16 -0
- package/cjs/date-picker/date-picker.js +76 -0
- package/cjs/date-picker/index.js +8 -0
- package/cjs/date-picker/range-time-panels.js +26 -0
- package/cjs/date-picker/styles.module.css +125 -0
- package/cjs/date-picker/types.js +2 -0
- package/cjs/date-picker/use-date-picker.js +286 -0
- package/cjs/date-picker/use-sheet-time.js +18 -0
- package/cjs/divider/divider.js +58 -0
- package/cjs/divider/index.js +17 -0
- package/cjs/divider/styles.module.css +28 -0
- package/cjs/divider/types.js +2 -0
- package/cjs/drawer/content.js +59 -0
- package/cjs/drawer/context.js +14 -0
- package/cjs/drawer/drawer.js +132 -0
- package/cjs/drawer/footer.js +67 -0
- package/cjs/drawer/header.js +66 -0
- package/cjs/drawer/index.js +21 -0
- package/cjs/drawer/normalize-padding.js +23 -0
- package/cjs/drawer/sheet-drag-config.js +16 -0
- package/cjs/drawer/sheet-drag-utils.js +39 -0
- package/cjs/drawer/styles.module.css +266 -0
- package/cjs/drawer/types.js +2 -0
- package/cjs/drawer/use-scroll-state.js +34 -0
- package/cjs/drawer/use-sheet-drag.js +163 -0
- package/cjs/dropdown-menu/dropdown-menu-button.js +61 -0
- package/cjs/dropdown-menu/dropdown-menu-context.js +14 -0
- package/cjs/dropdown-menu/dropdown-menu-item.js +16 -0
- package/cjs/dropdown-menu/dropdown-menu.js +44 -0
- package/cjs/dropdown-menu/index.js +19 -0
- package/cjs/dropdown-menu/styles.module.css +46 -0
- package/cjs/dropdown-menu/types.js +2 -0
- package/cjs/dropdown-menu/use-dropdown-menu.js +203 -0
- package/cjs/file/components/file-background-progress.js +20 -0
- package/cjs/file/components/file-emblem.js +38 -0
- package/cjs/file/components/file-interactive-shell.js +15 -0
- package/cjs/file/components/file-name.js +20 -0
- package/cjs/file/components/file-status-meta.js +20 -0
- package/cjs/file/constants.js +21 -0
- package/cjs/file/file-extensions.js +116 -0
- package/cjs/file/file.js +26 -0
- package/cjs/file/hooks/use-file-view-model.js +123 -0
- package/cjs/file/icons/file-extension-glyph-icon.js +13 -0
- package/cjs/file/icons/file-extension-glyphs.js +20 -0
- package/cjs/file/icons/file-extension-icons.js +19 -0
- package/cjs/file/image-frame-size-class.js +17 -0
- package/cjs/file/index.js +25 -0
- package/cjs/file/presets/remove-preset.js +37 -0
- package/cjs/file/presets/retry-preset.js +25 -0
- package/cjs/file/styles.module.css +565 -0
- package/cjs/file/types.js +2 -0
- package/cjs/file/utils/file-name-parts.js +25 -0
- package/cjs/file/utils/format-size.js +39 -0
- package/cjs/file/utils/get-file-presentation.js +51 -0
- package/cjs/file/utils/resolve-file-icon.js +21 -0
- package/cjs/file/utils/resolve-file-slot.js +61 -0
- package/cjs/file/utils/split-file-name.js +15 -0
- package/cjs/file/views/file-default-view.js +28 -0
- package/cjs/file/views/file-image-view.js +23 -0
- package/cjs/file-upload/components/drop-overlay.js +36 -0
- package/cjs/file-upload/components/file-upload-button-trigger.js +17 -0
- package/cjs/file-upload/components/file-upload-hint-caption.js +15 -0
- package/cjs/file-upload/components/file-upload-icon-button.js +20 -0
- package/cjs/file-upload/components/image-loader-icons.js +15 -0
- package/cjs/file-upload/components/image-loader-trigger.js +20 -0
- package/cjs/file-upload/constants.js +44 -0
- package/cjs/file-upload/file-upload.js +22 -0
- package/cjs/file-upload/hooks/use-drag-overlay.js +113 -0
- package/cjs/file-upload/hooks/use-file-list.js +191 -0
- package/cjs/file-upload/hooks/use-file-upload-view-model.js +188 -0
- package/cjs/file-upload/hooks/use-object-url.js +31 -0
- package/cjs/file-upload/index.js +40 -0
- package/cjs/file-upload/styles.module.css +345 -0
- package/cjs/file-upload/types-dropzone.js +2 -0
- package/cjs/file-upload/types-file-actions.js +2 -0
- package/cjs/file-upload/types-labels.js +2 -0
- package/cjs/file-upload/types.js +21 -0
- package/cjs/file-upload/utils/accept.js +48 -0
- package/cjs/file-upload/utils/build-file-slots.js +19 -0
- package/cjs/file-upload/utils/compute-drop-border-vertical-dash-style.js +49 -0
- package/cjs/file-upload/utils/get-drop-zone-typography.js +15 -0
- package/cjs/file-upload/utils/get-file-upload-presentation.js +68 -0
- package/cjs/file-upload/utils/max-count.js +26 -0
- package/cjs/file-upload/utils/normalize.js +67 -0
- package/cjs/file-upload/utils/render-drop-zone-hint-content.js +33 -0
- package/cjs/file-upload/utils/resolve-display-error.js +18 -0
- package/cjs/file-upload/utils/resolve-hint-content.js +59 -0
- package/cjs/file-upload/utils/resolve-labels.js +37 -0
- package/cjs/file-upload/utils/resolve-preset.js +49 -0
- package/cjs/file-upload/utils/resolve-upload-file-error.js +12 -0
- package/cjs/file-upload/utils/resolve-upload-text.js +9 -0
- package/cjs/file-upload/utils/run-before-upload.js +29 -0
- package/cjs/file-upload/utils/run-sequentially.js +7 -0
- package/cjs/file-upload/utils/uid.js +7 -0
- package/cjs/file-upload/views/file-upload-dropzone-view.js +54 -0
- package/cjs/file-upload/views/file-upload-errors-view.js +13 -0
- package/cjs/file-upload/views/file-upload-footer-view.js +23 -0
- package/cjs/file-upload/views/file-upload-list-view.js +44 -0
- package/cjs/file-upload/views/file-upload-trigger-view.js +101 -0
- package/cjs/file-upload/views/file-upload-view.js +23 -0
- package/cjs/grid/grid.js +153 -0
- package/cjs/grid/index.js +21 -0
- package/cjs/grid/presets.js +6 -0
- package/cjs/grid/styles.module.css +56 -0
- package/cjs/grid/types.js +2 -0
- package/cjs/grid-item/grid-item.js +19 -0
- package/cjs/grid-item/index.js +17 -0
- package/cjs/grid-item/types.js +2 -0
- package/cjs/hint/buttons/action-button.js +26 -0
- package/cjs/hint/buttons/close-button.js +30 -0
- package/cjs/hint/buttons/extra-button.js +26 -0
- package/cjs/hint/hint-content.js +27 -0
- package/cjs/hint/hint-provider.js +14 -0
- package/cjs/hint/hint.js +90 -0
- package/cjs/hint/index.js +21 -0
- package/cjs/hint/styles/buttons.module.css +16 -0
- package/cjs/hint/styles/hint-content.module.css +33 -0
- package/cjs/hint/styles/hint.module.css +37 -0
- package/cjs/hint/types.js +2 -0
- package/cjs/hooks/index.js +37 -0
- package/cjs/hooks/media-query/create-media-query.js +22 -0
- package/cjs/hooks/media-query/index.js +18 -0
- package/cjs/hooks/media-query/observe-media-query.js +29 -0
- package/cjs/hooks/media-query/types.js +2 -0
- package/cjs/hooks/media-query/use-media-query-listener.js +39 -0
- package/cjs/hooks/media-query/use-media-query.js +28 -0
- package/cjs/hooks/use-actual-ref.js +14 -0
- package/cjs/hooks/use-breakpoint.js +56 -0
- package/cjs/hooks/use-click-outside.js +43 -0
- package/cjs/hooks/use-component-tokens.js +20 -0
- package/cjs/hooks/use-cssvar-from-width.js +35 -0
- package/cjs/hooks/use-effect-once.js +13 -0
- package/cjs/hooks/use-isomorphic-layout-effect.js +9 -0
- package/cjs/hooks/use-keyboard-callbacks.js +124 -0
- package/cjs/hooks/use-keyboard-navigation.js +66 -0
- package/cjs/hooks/use-list-navigation/index.js +15 -0
- package/cjs/hooks/use-list-navigation/input-modality.js +59 -0
- package/cjs/hooks/use-list-navigation/store.js +70 -0
- package/cjs/hooks/use-list-navigation/types.js +2 -0
- package/cjs/hooks/use-list-navigation/use-list-navigation-item.js +39 -0
- package/cjs/hooks/use-list-navigation/use-list-navigation.js +262 -0
- package/cjs/hooks/use-list-navigation/utils.js +52 -0
- package/cjs/hooks/use-load-more.js +74 -0
- package/cjs/hooks/use-mount.js +13 -0
- package/cjs/hooks/use-persistent-callback.js +18 -0
- package/cjs/hooks/use-platform.js +38 -0
- package/cjs/hooks/use-responsive-value.js +39 -0
- package/cjs/hooks/use-uniq-id.js +21 -0
- package/cjs/hooks/use-unmount.js +16 -0
- package/cjs/hooks/use-update-effect.js +27 -0
- package/cjs/hooks/use-viewport-exit.js +33 -0
- package/cjs/hooks/use-virtual-window.js +86 -0
- package/cjs/hooks/use-window-size.js +28 -0
- package/cjs/icon/icon.js +71 -0
- package/cjs/icon/index.js +17 -0
- package/cjs/icon/pack-utils.js +33 -0
- package/cjs/icon/styles.module.css +17 -0
- package/cjs/icons/arrow-icon.js +16 -0
- package/cjs/icons/back-icon.js +10 -0
- package/cjs/icons/calendar-icon.js +10 -0
- package/cjs/icons/check-icon.js +11 -0
- package/cjs/icons/clock-icon.js +11 -0
- package/cjs/icons/close-icon.js +10 -0
- package/cjs/icons/del-icon.js +10 -0
- package/cjs/icons/double-arrow-icon.js +15 -0
- package/cjs/icons/error-icon.js +10 -0
- package/cjs/icons/eye-icon.js +12 -0
- package/cjs/icons/index.js +31 -0
- package/cjs/icons/magnifying-glass-icon.js +10 -0
- package/cjs/icons/minus-icon.js +10 -0
- package/cjs/icons/plus-icon.js +10 -0
- package/cjs/icons/reset-icon.js +10 -0
- package/cjs/icons/shopping-icon.js +10 -0
- package/cjs/icons/stars/star-fill-icon.js +10 -0
- package/cjs/icons/stars/star-half-icon.js +10 -0
- package/cjs/icons/stars/start-outline-icon.js +10 -0
- package/cjs/icons/types.js +2 -0
- package/cjs/image/image-viewer.js +47 -0
- package/cjs/image/image.js +73 -0
- package/cjs/image/index.js +17 -0
- package/cjs/image/style.module.css +65 -0
- package/cjs/image/types.js +2 -0
- package/cjs/image/use-image.js +47 -0
- package/cjs/image/viewer.module.css +80 -0
- package/cjs/index.js +87 -0
- package/cjs/input/fields/password-toggle.js +14 -0
- package/cjs/input/fields/text-field.js +29 -0
- package/cjs/input/fields/use-text-field.js +79 -0
- package/cjs/input/index.js +17 -0
- package/cjs/input/input.js +24 -0
- package/cjs/input/types.js +2 -0
- package/cjs/label/index.js +18 -0
- package/cjs/label/label.js +82 -0
- package/cjs/label/styles.module.css +25 -0
- package/cjs/label/types.js +2 -0
- package/cjs/list/clear-all-button/clear-all-button.js +47 -0
- package/cjs/list/clear-all-button/index.js +17 -0
- package/cjs/list/constants.js +4 -0
- package/cjs/list/index.js +24 -0
- package/cjs/list/list-context.js +14 -0
- package/cjs/list/list-divider/index.js +17 -0
- package/cjs/list/list-divider/list-divider.js +49 -0
- package/cjs/list/list-divider/styles.module.css +7 -0
- package/cjs/list/list-divider/use-list-divider.js +15 -0
- package/cjs/list/list-item/index.js +5 -0
- package/cjs/list/list-item/list-icon.js +61 -0
- package/cjs/list/list-item/list-item-provider.js +21 -0
- package/cjs/list/list-item/list-item.js +32 -0
- package/cjs/list/list-item/styles.module.css +216 -0
- package/cjs/list/list-item/types.js +2 -0
- package/cjs/list/list-item/use-list-item.js +78 -0
- package/cjs/list/list-item/use-nested-list.js +17 -0
- package/cjs/list/list-section/index.js +17 -0
- package/cjs/list/list-section/list-section.js +67 -0
- package/cjs/list/list-section/styles.module.css +27 -0
- package/cjs/list/list.js +39 -0
- package/cjs/list/styles.module.css +24 -0
- package/cjs/list/types.js +2 -0
- package/cjs/list/use-list.js +73 -0
- package/cjs/loader/index.js +17 -0
- package/cjs/loader/loader.js +31 -0
- package/cjs/loader/loader.module.css +80 -0
- package/cjs/locale/create-translator.js +13 -0
- package/cjs/locale/en.js +109 -0
- package/cjs/locale/index.js +13 -0
- package/cjs/locale/locale-provider.js +23 -0
- package/cjs/locale/ru.js +109 -0
- package/cjs/locale/types.js +2 -0
- package/cjs/locale/use-locale.js +11 -0
- package/cjs/masked-input/constants.js +8 -0
- package/cjs/masked-input/hooks.js +179 -0
- package/cjs/masked-input/index.js +5 -0
- package/cjs/masked-input/mask-types.js +2 -0
- package/cjs/masked-input/masked-input.js +27 -0
- package/cjs/masked-input/types.js +2 -0
- package/cjs/masked-input/use-mask.js +168 -0
- package/cjs/masked-input/utils/get-autofill-selector.js +14 -0
- package/cjs/masked-input/utils/helpers.js +61 -0
- package/cjs/masked-input/utils/index.js +20 -0
- package/cjs/masked-input/utils/mask-utils.js +211 -0
- package/cjs/masked-input/utils/parse-mask.js +61 -0
- package/cjs/masked-input/utils/validate-props.js +15 -0
- package/cjs/modal/constants.js +5 -0
- package/cjs/modal/index.js +26 -0
- package/cjs/modal/modal-close-button.js +20 -0
- package/cjs/modal/modal-content.js +43 -0
- package/cjs/modal/modal-context.js +13 -0
- package/cjs/modal/modal-footer.js +57 -0
- package/cjs/modal/modal-header.js +57 -0
- package/cjs/modal/modal.js +63 -0
- package/cjs/modal/styles/_animations.css +124 -0
- package/cjs/modal/styles/_config.css +0 -0
- package/cjs/modal/styles/modal-content.module.css +30 -0
- package/cjs/modal/styles/modal-footer.module.css +31 -0
- package/cjs/modal/styles/modal-header.module.css +56 -0
- package/cjs/modal/styles/modal.module.css +284 -0
- package/cjs/modal/types.js +2 -0
- package/cjs/modal/use-modal-refs.js +16 -0
- package/cjs/modal/use-modal.js +52 -0
- package/cjs/modal/utils.js +17 -0
- package/cjs/navigation/context.js +24 -0
- package/cjs/navigation/index.js +25 -0
- package/cjs/navigation/navigation-compact.js +122 -0
- package/cjs/navigation/navigation-control.js +89 -0
- package/cjs/navigation/navigation-item-content.js +33 -0
- package/cjs/navigation/navigation-list.js +87 -0
- package/cjs/navigation/navigation-rail.js +31 -0
- package/cjs/navigation/navigation-row.js +86 -0
- package/cjs/navigation/navigation-tree.js +100 -0
- package/cjs/navigation/navigation-views.js +114 -0
- package/cjs/navigation/navigation.js +153 -0
- package/cjs/navigation/storage.js +28 -0
- package/cjs/navigation/styles/navigation.module.css +567 -0
- package/cjs/navigation/types.js +2 -0
- package/cjs/navigation/use-item-tooltip.js +22 -0
- package/cjs/navigation/use-navigation-types.js +2 -0
- package/cjs/navigation/use-navigation.js +141 -0
- package/cjs/navigation/use-overflow.js +41 -0
- package/cjs/navigation/utils.js +102 -0
- package/cjs/number-input/format-types.js +8 -0
- package/cjs/number-input/format-utils.js +166 -0
- package/cjs/number-input/hooks/index.js +5 -0
- package/cjs/number-input/hooks/use-numeric-format.js +139 -0
- package/cjs/number-input/index.js +5 -0
- package/cjs/number-input/number-input.js +26 -0
- package/cjs/number-input/types.js +2 -0
- package/cjs/number-input/use-number-input.js +405 -0
- package/cjs/number-input/utils.js +323 -0
- package/cjs/pagination/index.js +9 -0
- package/cjs/pagination/items.js +48 -0
- package/cjs/pagination/labels.js +17 -0
- package/cjs/pagination/pagination.js +65 -0
- package/cjs/pagination/styles.module.css +125 -0
- package/cjs/pagination/types.js +2 -0
- package/cjs/pagination/use-pagination.js +27 -0
- package/cjs/pin-input/index.js +5 -0
- package/cjs/pin-input/pin-input.js +33 -0
- package/cjs/pin-input/styles.module.css +68 -0
- package/cjs/pin-input/types.js +2 -0
- package/cjs/pin-input/use-pin-input.js +137 -0
- package/cjs/pin-input/utils.js +17 -0
- package/cjs/popover/index.js +10 -0
- package/cjs/popover/popover.js +43 -0
- package/cjs/popover/styles.module.css +76 -0
- package/cjs/popover/types.js +2 -0
- package/cjs/popover/use-popover.js +125 -0
- package/cjs/portal/index.js +11 -0
- package/cjs/portal/portal-provider.js +21 -0
- package/cjs/portal/portal.js +48 -0
- package/cjs/portal/resolve-container.js +14 -0
- package/cjs/portal/types.js +2 -0
- package/cjs/portal/use-portal.js +51 -0
- package/cjs/progress-bar/index.js +17 -0
- package/cjs/progress-bar/progress-bar.js +57 -0
- package/cjs/progress-bar/styles.module.css +147 -0
- package/cjs/progress-bar/types.js +2 -0
- package/cjs/quantity-input/index.js +17 -0
- package/cjs/quantity-input/quantity-input.js +123 -0
- package/cjs/quantity-input/styles.module.css +44 -0
- package/cjs/quantity-input/types.js +2 -0
- package/cjs/quantity-input/utils.js +25 -0
- package/cjs/radio/index.js +18 -0
- package/cjs/radio/radio.js +50 -0
- package/cjs/radio/styles.module.css +161 -0
- package/cjs/radio/types.js +2 -0
- package/cjs/radio-group/index.js +20 -0
- package/cjs/radio-group/radio-group-context.js +11 -0
- package/cjs/radio-group/radio-group.js +81 -0
- package/cjs/radio-group/styles.module.css +12 -0
- package/cjs/radio-group/use-radio-group.js +8 -0
- package/cjs/segmented-control/index.js +7 -0
- package/cjs/segmented-control/segmented-control-context.js +11 -0
- package/cjs/segmented-control/segmented-control-item.js +79 -0
- package/cjs/segmented-control/segmented-control.js +75 -0
- package/cjs/segmented-control/styles/_variables.css +0 -0
- package/cjs/segmented-control/styles/segmented-control-item.module.css +194 -0
- package/cjs/segmented-control/styles/segmented-control.module.css +31 -0
- package/cjs/segmented-control/types.js +2 -0
- package/cjs/segmented-control/use-segmented-control.js +33 -0
- package/cjs/select/class-names-context.js +7 -0
- package/cjs/select/components/render-grouped-options.js +48 -0
- package/cjs/select/components/select-field-multiselect-value.js +56 -0
- package/cjs/select/components/select-field-value.js +60 -0
- package/cjs/select/components/select-field.js +221 -0
- package/cjs/select/components/select-load-more-indicator.js +13 -0
- package/cjs/select/components/select-multiselect-panel.js +202 -0
- package/cjs/select/components/select-option-list.js +111 -0
- package/cjs/select/components/select-option-row.js +79 -0
- package/cjs/select/components/select-options-scroll-area.js +14 -0
- package/cjs/select/components/select-panel-status.js +23 -0
- package/cjs/select/components/select-single-panel.js +47 -0
- package/cjs/select/hooks/use-auto-scroll-to-bottom.js +26 -0
- package/cjs/select/hooks/use-chips-row-count.js +65 -0
- package/cjs/select/hooks/use-multiselect-collapsed-display.js +137 -0
- package/cjs/select/hooks/use-select-dismiss.js +82 -0
- package/cjs/select/hooks/use-select-input-bindings.js +46 -0
- package/cjs/select/hooks/use-select-keyboard.js +174 -0
- package/cjs/select/hooks/use-select-multiselect-panel-state.js +31 -0
- package/cjs/select/hooks/use-select-search.js +261 -0
- package/cjs/select/hooks/use-select-view-model.js +169 -0
- package/cjs/select/hooks/use-select-virtual.js +35 -0
- package/cjs/select/hooks/use-select.js +438 -0
- package/cjs/select/index.js +40 -0
- package/cjs/select/presets/autocomplete.js +22 -0
- package/cjs/select/presets/index.js +17 -0
- package/cjs/select/select.js +25 -0
- package/cjs/select/styles/select-field.module.css +147 -0
- package/cjs/select/styles/select.module.css +457 -0
- package/cjs/select/types-search.js +2 -0
- package/cjs/select/types.js +2 -0
- package/cjs/select/utils/custom-search-option.js +42 -0
- package/cjs/select/utils/filter-options.js +28 -0
- package/cjs/select/utils/get-display-value.js +19 -0
- package/cjs/select/utils/get-element-content-width.js +14 -0
- package/cjs/select/utils/get-multiselect-display-labels.js +10 -0
- package/cjs/select/utils/get-status-content.js +13 -0
- package/cjs/select/utils/is-select-panel-compact-content.js +7 -0
- package/cjs/select/utils/measure-multiselect-row-width.js +19 -0
- package/cjs/select/utils/measure-text-width.js +78 -0
- package/cjs/select/utils/multiselect-collapsed-display-shared.js +156 -0
- package/cjs/select/utils/normalize-options.js +10 -0
- package/cjs/select/utils/normalize-value.js +23 -0
- package/cjs/select/utils/resolve-loading-state.js +13 -0
- package/cjs/select/utils/resolve-multiselect-collapsed-display.js +45 -0
- package/cjs/select/utils/resolve-search-content.js +9 -0
- package/cjs/select/utils/retain-combobox-focus.js +21 -0
- package/cjs/select/utils/select-keyboard-navigation.js +17 -0
- package/cjs/select/utils/select-load-more-scroll.js +24 -0
- package/cjs/select/utils/select-option-id.js +7 -0
- package/cjs/select/views/select-listbox.js +21 -0
- package/cjs/select/views/select-search-listbox.js +29 -0
- package/cjs/select/views/select-view.js +70 -0
- package/cjs/select/views/styles.module.css +45 -0
- package/cjs/show-more/hooks/use-show-more-view-model.js +79 -0
- package/cjs/show-more/index.js +5 -0
- package/cjs/show-more/show-more.js +21 -0
- package/cjs/show-more/styles.module.css +20 -0
- package/cjs/show-more/types.js +2 -0
- package/cjs/show-more/views/show-more-view.js +15 -0
- package/cjs/skeleton/index.js +18 -0
- package/cjs/skeleton/skeleton.js +50 -0
- package/cjs/skeleton/styles.module.css +300 -0
- package/cjs/skeleton/types.js +2 -0
- package/cjs/skeleton/use-skeleton.js +23 -0
- package/cjs/snackbar/index.js +21 -0
- package/cjs/snackbar/snack-button.js +57 -0
- package/cjs/snackbar/snack-view.js +105 -0
- package/cjs/snackbar/snack.js +64 -0
- package/cjs/snackbar/snackbar-context.js +13 -0
- package/cjs/snackbar/snackbar-provider.js +88 -0
- package/cjs/snackbar/snackbar.js +81 -0
- package/cjs/snackbar/styles/snack.module.css +195 -0
- package/cjs/snackbar/styles/snackbar.module.css +66 -0
- package/cjs/snackbar/types.js +2 -0
- package/cjs/snackbar/use-snack-timer.js +31 -0
- package/cjs/snackbar/use-snack.js +86 -0
- package/cjs/stack/index.js +17 -0
- package/cjs/stack/stack.js +40 -0
- package/cjs/stack/styles.module.css +46 -0
- package/cjs/stack/types.js +2 -0
- package/cjs/status/index.js +17 -0
- package/cjs/status/status-icon.js +26 -0
- package/cjs/status/styles.module.css +18 -0
- package/cjs/status/types.js +2 -0
- package/cjs/stepper/index.js +20 -0
- package/cjs/stepper/stepper.js +47 -0
- package/cjs/stepper/styles.module.css +172 -0
- package/cjs/stepper/types.js +2 -0
- package/cjs/stepper/use-stepper.js +28 -0
- package/cjs/switch/index.js +18 -0
- package/cjs/switch/styles/base.module.css +134 -0
- package/cjs/switch/switch.js +78 -0
- package/cjs/switch/types.js +2 -0
- package/cjs/tabs/context.js +13 -0
- package/cjs/tabs/index.js +23 -0
- package/cjs/tabs/styles/tab-list.module.css +23 -0
- package/cjs/tabs/styles/tab-panel.module.css +3 -0
- package/cjs/tabs/styles/tab.module.css +210 -0
- package/cjs/tabs/tab-list.js +109 -0
- package/cjs/tabs/tab-panel.js +55 -0
- package/cjs/tabs/tab.js +79 -0
- package/cjs/tabs/tabs.js +33 -0
- package/cjs/tabs/types.js +2 -0
- package/cjs/tabs/use-tabs.js +62 -0
- package/cjs/textarea/get-max-length-message.js +9 -0
- package/cjs/textarea/index.js +5 -0
- package/cjs/textarea/styles.module.css +37 -0
- package/cjs/textarea/textarea.js +26 -0
- package/cjs/textarea/types.js +2 -0
- package/cjs/textarea/use-auto-height.js +109 -0
- package/cjs/textarea/use-resize-handle.js +47 -0
- package/cjs/textarea/use-textarea.js +111 -0
- package/cjs/theme-provider/index.js +46 -0
- package/cjs/theme-provider/styles.module.css +332 -0
- package/cjs/theme-provider/theme-context.js +39 -0
- package/cjs/theme-provider/theme-provider.js +48 -0
- package/cjs/theme-provider/theme-scope.js +85 -0
- package/cjs/theme-provider/types.js +2 -0
- package/cjs/theme-provider/use-system-theme.js +26 -0
- package/cjs/theme-provider/use-theme-provider.js +28 -0
- package/cjs/time-picker/index.js +16 -0
- package/cjs/time-picker/picker-types.js +2 -0
- package/cjs/time-picker/single-time-picker.js +44 -0
- package/cjs/time-picker/styles.module.css +124 -0
- package/cjs/time-picker/time-model.js +149 -0
- package/cjs/time-picker/time-panel.js +87 -0
- package/cjs/time-picker/time-picker.js +80 -0
- package/cjs/time-picker/time-range-picker.js +51 -0
- package/cjs/time-picker/types.js +2 -0
- package/cjs/time-picker/use-time-panel.js +25 -0
- package/cjs/time-picker/use-time-picker.js +120 -0
- package/cjs/time-picker/use-time-range-picker.js +134 -0
- package/cjs/tokens/index.js +18 -0
- package/cjs/tooltip/index.js +17 -0
- package/cjs/tooltip/styles.module.css +46 -0
- package/cjs/tooltip/tooltip.js +70 -0
- package/cjs/tooltip/types.js +2 -0
- package/cjs/tooltip/use-tooltip.js +41 -0
- package/cjs/tree/check.js +106 -0
- package/cjs/tree/class-names-context.js +9 -0
- package/cjs/tree/highlight.js +29 -0
- package/cjs/tree/index.js +20 -0
- package/cjs/tree/model.js +119 -0
- package/cjs/tree/move.js +109 -0
- package/cjs/tree/styles.module.css +290 -0
- package/cjs/tree/tree-branch.js +78 -0
- package/cjs/tree/tree-placeholder.js +16 -0
- package/cjs/tree/tree-row-content.js +32 -0
- package/cjs/tree/tree-row-renderer.js +60 -0
- package/cjs/tree/tree-row.js +98 -0
- package/cjs/tree/tree-select-panel.js +15 -0
- package/cjs/tree/tree-select-selection.js +34 -0
- package/cjs/tree/tree-select-types.js +2 -0
- package/cjs/tree/tree-select.js +207 -0
- package/cjs/tree/tree-select.module.css +35 -0
- package/cjs/tree/tree.js +99 -0
- package/cjs/tree/types-row.js +2 -0
- package/cjs/tree/types.js +2 -0
- package/cjs/tree/use-tree-activate.js +17 -0
- package/cjs/tree/use-tree-checks.js +27 -0
- package/cjs/tree/use-tree-expansion.js +74 -0
- package/cjs/tree/use-tree-keyboard.js +94 -0
- package/cjs/tree/use-tree-virtual.js +76 -0
- package/cjs/tree/use-tree.js +111 -0
- package/cjs/tree/virtual-rows.js +15 -0
- package/cjs/types/size.js +2 -0
- package/cjs/typography/index.js +17 -0
- package/cjs/typography/styles.module.css +304 -0
- package/cjs/typography/types.js +2 -0
- package/cjs/typography/typography.js +30 -0
- package/cjs/utils/call-child-as-function.js +5 -0
- package/cjs/utils/class-names.js +168 -0
- package/cjs/utils/compose-event-handlers.js +18 -0
- package/cjs/utils/container-props-override.js +56 -0
- package/cjs/utils/create-id.js +13 -0
- package/cjs/utils/data-attributes.js +29 -0
- package/cjs/utils/decode-uri.js +50 -0
- package/cjs/utils/empty-function.js +7 -0
- package/cjs/utils/get-react-element-ref.js +16 -0
- package/cjs/utils/imperative-change-input-value.js +19 -0
- package/cjs/utils/index.js +38 -0
- package/cjs/utils/input-caret.js +48 -0
- package/cjs/utils/invariant.js +15 -0
- package/cjs/utils/is-browser.js +5 -0
- package/cjs/utils/is-new-theme.js +10 -0
- package/cjs/utils/merge-refs.js +39 -0
- package/cjs/utils/overridable-component.js +2 -0
- package/cjs/utils/shallow-objects-equal.js +20 -0
- package/cjs/utils/style/index.js +20 -0
- package/cjs/utils/style/props/color.js +9 -0
- package/cjs/utils/style/props/dimension.js +13 -0
- package/cjs/utils/style/props/index.js +19 -0
- package/cjs/utils/style/props/passthrough.js +5 -0
- package/cjs/utils/style/props/types.js +2 -0
- package/cjs/utils/style/types.js +2 -0
- package/cjs/utils/style/use-style-props.js +10 -0
- package/cjs/utils/style/utils/convert-style-props.js +26 -0
- package/cjs/utils/style/utils/index.js +17 -0
- package/cjs/utils/use-class-names.js +99 -0
- package/cjs/utils/utils.js +2 -0
- package/cjs/visually-hidden/index.js +17 -0
- package/cjs/visually-hidden/styles.module.css +9 -0
- package/cjs/visually-hidden/visually-hidden.js +12 -0
- package/container/container.d.ts +2 -0
- package/container/container.js +7 -0
- package/container/index.d.ts +2 -0
- package/container/index.js +1 -0
- package/container/styles.module.css +85 -0
- package/container/types.d.ts +9 -0
- package/container/types.js +1 -0
- package/css-baseline/css-baseline.d.ts +3 -0
- package/css-baseline/css-baseline.js +4 -0
- package/css-baseline/index.d.ts +1 -0
- package/css-baseline/index.js +1 -0
- package/css-baseline/styles.css +36 -0
- package/date-picker/date-picker-panel.d.ts +13 -0
- package/date-picker/date-picker-panel.js +35 -0
- package/date-picker/date-picker-sheet-footer.d.ts +6 -0
- package/date-picker/date-picker-sheet-footer.js +12 -0
- package/date-picker/date-picker.d.ts +12 -0
- package/date-picker/date-picker.js +70 -0
- package/date-picker/index.d.ts +4 -0
- package/date-picker/index.js +2 -0
- package/date-picker/range-time-panels.d.ts +16 -0
- package/date-picker/range-time-panels.js +19 -0
- package/date-picker/styles.module.css +125 -0
- package/date-picker/types.d.ts +173 -0
- package/date-picker/types.js +1 -0
- package/date-picker/use-date-picker.d.ts +56 -0
- package/date-picker/use-date-picker.js +282 -0
- package/date-picker/use-sheet-time.d.ts +8 -0
- package/date-picker/use-sheet-time.js +14 -0
- package/divider/divider.d.ts +10 -0
- package/divider/divider.js +18 -0
- package/divider/index.d.ts +2 -0
- package/divider/index.js +1 -0
- package/divider/styles.module.css +28 -0
- package/divider/types.d.ts +17 -0
- package/divider/types.js +1 -0
- package/drawer/content.d.ts +8 -0
- package/drawer/content.js +20 -0
- package/drawer/context.d.ts +13 -0
- package/drawer/context.js +11 -0
- package/drawer/drawer.d.ts +27 -0
- package/drawer/drawer.js +93 -0
- package/drawer/footer.d.ts +6 -0
- package/drawer/footer.js +28 -0
- package/drawer/header.d.ts +11 -0
- package/drawer/header.js +27 -0
- package/drawer/index.d.ts +5 -0
- package/drawer/index.js +5 -0
- package/drawer/normalize-padding.d.ts +2 -0
- package/drawer/normalize-padding.js +20 -0
- package/drawer/sheet-drag-config.d.ts +12 -0
- package/drawer/sheet-drag-config.js +13 -0
- package/drawer/sheet-drag-utils.d.ts +16 -0
- package/drawer/sheet-drag-utils.js +35 -0
- package/drawer/styles.module.css +266 -0
- package/drawer/types.d.ts +102 -0
- package/drawer/types.js +1 -0
- package/drawer/use-scroll-state.d.ts +11 -0
- package/drawer/use-scroll-state.js +31 -0
- package/drawer/use-sheet-drag.d.ts +25 -0
- package/drawer/use-sheet-drag.js +160 -0
- package/dropdown-menu/dropdown-menu-button.d.ts +8 -0
- package/dropdown-menu/dropdown-menu-button.js +22 -0
- package/dropdown-menu/dropdown-menu-context.d.ts +6 -0
- package/dropdown-menu/dropdown-menu-context.js +10 -0
- package/dropdown-menu/dropdown-menu-item.d.ts +6 -0
- package/dropdown-menu/dropdown-menu-item.js +9 -0
- package/dropdown-menu/dropdown-menu.d.ts +13 -0
- package/dropdown-menu/dropdown-menu.js +37 -0
- package/dropdown-menu/index.d.ts +4 -0
- package/dropdown-menu/index.js +3 -0
- package/dropdown-menu/styles.module.css +46 -0
- package/dropdown-menu/types.d.ts +64 -0
- package/dropdown-menu/types.js +1 -0
- package/dropdown-menu/use-dropdown-menu.d.ts +178 -0
- package/dropdown-menu/use-dropdown-menu.js +166 -0
- package/file/components/file-background-progress.d.ts +8 -0
- package/file/components/file-background-progress.js +14 -0
- package/file/components/file-emblem.d.ts +14 -0
- package/file/components/file-emblem.js +32 -0
- package/file/components/file-interactive-shell.d.ts +15 -0
- package/file/components/file-interactive-shell.js +9 -0
- package/file/components/file-name.d.ts +13 -0
- package/file/components/file-name.js +14 -0
- package/file/components/file-status-meta.d.ts +14 -0
- package/file/components/file-status-meta.js +14 -0
- package/file/constants.d.ts +32 -0
- package/file/constants.js +17 -0
- package/file/file-extensions.d.ts +2 -0
- package/file/file-extensions.js +113 -0
- package/file/file.d.ts +6 -0
- package/file/file.js +19 -0
- package/file/hooks/use-file-view-model.d.ts +31 -0
- package/file/hooks/use-file-view-model.js +117 -0
- package/file/icons/file-extension-glyph-icon.d.ts +6 -0
- package/file/icons/file-extension-glyph-icon.js +7 -0
- package/file/icons/file-extension-glyphs.d.ts +18 -0
- package/file/icons/file-extension-glyphs.js +17 -0
- package/file/icons/file-extension-icons.d.ts +3 -0
- package/file/icons/file-extension-icons.js +12 -0
- package/file/image-frame-size-class.d.ts +3 -0
- package/file/image-frame-size-class.js +11 -0
- package/file/index.d.ts +6 -0
- package/file/index.js +4 -0
- package/file/presets/remove-preset.d.ts +10 -0
- package/file/presets/remove-preset.js +29 -0
- package/file/presets/retry-preset.d.ts +9 -0
- package/file/presets/retry-preset.js +18 -0
- package/file/styles.module.css +565 -0
- package/file/types.d.ts +62 -0
- package/file/types.js +1 -0
- package/file/utils/file-name-parts.d.ts +15 -0
- package/file/utils/file-name-parts.js +21 -0
- package/file/utils/format-size.d.ts +7 -0
- package/file/utils/format-size.js +35 -0
- package/file/utils/get-file-presentation.d.ts +33 -0
- package/file/utils/get-file-presentation.js +48 -0
- package/file/utils/resolve-file-icon.d.ts +5 -0
- package/file/utils/resolve-file-icon.js +17 -0
- package/file/utils/resolve-file-slot.d.ts +10 -0
- package/file/utils/resolve-file-slot.js +52 -0
- package/file/utils/split-file-name.d.ts +6 -0
- package/file/utils/split-file-name.js +12 -0
- package/file/views/file-default-view.d.ts +6 -0
- package/file/views/file-default-view.js +22 -0
- package/file/views/file-image-view.d.ts +6 -0
- package/file/views/file-image-view.js +17 -0
- package/file-upload/components/drop-overlay.d.ts +8 -0
- package/file-upload/components/drop-overlay.js +29 -0
- package/file-upload/components/file-upload-button-trigger.d.ts +9 -0
- package/file-upload/components/file-upload-button-trigger.js +11 -0
- package/file-upload/components/file-upload-hint-caption.d.ts +8 -0
- package/file-upload/components/file-upload-hint-caption.js +9 -0
- package/file-upload/components/file-upload-icon-button.d.ts +10 -0
- package/file-upload/components/file-upload-icon-button.js +14 -0
- package/file-upload/components/image-loader-icons.d.ts +7 -0
- package/file-upload/components/image-loader-icons.js +8 -0
- package/file-upload/components/image-loader-trigger.d.ts +12 -0
- package/file-upload/components/image-loader-trigger.js +14 -0
- package/file-upload/constants.d.ts +33 -0
- package/file-upload/constants.js +39 -0
- package/file-upload/file-upload.d.ts +10 -0
- package/file-upload/file-upload.js +16 -0
- package/file-upload/hooks/use-drag-overlay.d.ts +11 -0
- package/file-upload/hooks/use-drag-overlay.js +110 -0
- package/file-upload/hooks/use-file-list.d.ts +22 -0
- package/file-upload/hooks/use-file-list.js +188 -0
- package/file-upload/hooks/use-file-upload-view-model.d.ts +51 -0
- package/file-upload/hooks/use-file-upload-view-model.js +185 -0
- package/file-upload/hooks/use-object-url.d.ts +3 -0
- package/file-upload/hooks/use-object-url.js +27 -0
- package/file-upload/index.d.ts +16 -0
- package/file-upload/index.js +10 -0
- package/file-upload/styles.module.css +345 -0
- package/file-upload/types-dropzone.d.ts +18 -0
- package/file-upload/types-dropzone.js +1 -0
- package/file-upload/types-file-actions.d.ts +13 -0
- package/file-upload/types-file-actions.js +1 -0
- package/file-upload/types-labels.d.ts +44 -0
- package/file-upload/types-labels.js +1 -0
- package/file-upload/types.d.ts +155 -0
- package/file-upload/types.js +2 -0
- package/file-upload/utils/accept.d.ts +3 -0
- package/file-upload/utils/accept.js +44 -0
- package/file-upload/utils/build-file-slots.d.ts +16 -0
- package/file-upload/utils/build-file-slots.js +16 -0
- package/file-upload/utils/compute-drop-border-vertical-dash-style.d.ts +18 -0
- package/file-upload/utils/compute-drop-border-vertical-dash-style.js +41 -0
- package/file-upload/utils/get-drop-zone-typography.d.ts +12 -0
- package/file-upload/utils/get-drop-zone-typography.js +11 -0
- package/file-upload/utils/get-file-upload-presentation.d.ts +35 -0
- package/file-upload/utils/get-file-upload-presentation.js +65 -0
- package/file-upload/utils/max-count.d.ts +6 -0
- package/file-upload/utils/max-count.js +20 -0
- package/file-upload/utils/normalize.d.ts +3 -0
- package/file-upload/utils/normalize.js +63 -0
- package/file-upload/utils/render-drop-zone-hint-content.d.ts +6 -0
- package/file-upload/utils/render-drop-zone-hint-content.js +27 -0
- package/file-upload/utils/resolve-display-error.d.ts +6 -0
- package/file-upload/utils/resolve-display-error.js +15 -0
- package/file-upload/utils/resolve-hint-content.d.ts +12 -0
- package/file-upload/utils/resolve-hint-content.js +56 -0
- package/file-upload/utils/resolve-labels.d.ts +21 -0
- package/file-upload/utils/resolve-labels.js +34 -0
- package/file-upload/utils/resolve-preset.d.ts +14 -0
- package/file-upload/utils/resolve-preset.js +39 -0
- package/file-upload/utils/resolve-upload-file-error.d.ts +1 -0
- package/file-upload/utils/resolve-upload-file-error.js +9 -0
- package/file-upload/utils/resolve-upload-text.d.ts +2 -0
- package/file-upload/utils/resolve-upload-text.js +6 -0
- package/file-upload/utils/run-before-upload.d.ts +6 -0
- package/file-upload/utils/run-before-upload.js +25 -0
- package/file-upload/utils/run-sequentially.d.ts +2 -0
- package/file-upload/utils/run-sequentially.js +4 -0
- package/file-upload/utils/uid.d.ts +1 -0
- package/file-upload/utils/uid.js +4 -0
- package/file-upload/views/file-upload-dropzone-view.d.ts +6 -0
- package/file-upload/views/file-upload-dropzone-view.js +48 -0
- package/file-upload/views/file-upload-errors-view.d.ts +8 -0
- package/file-upload/views/file-upload-errors-view.js +7 -0
- package/file-upload/views/file-upload-footer-view.d.ts +6 -0
- package/file-upload/views/file-upload-footer-view.js +17 -0
- package/file-upload/views/file-upload-list-view.d.ts +8 -0
- package/file-upload/views/file-upload-list-view.js +38 -0
- package/file-upload/views/file-upload-trigger-view.d.ts +8 -0
- package/file-upload/views/file-upload-trigger-view.js +62 -0
- package/file-upload/views/file-upload-view.d.ts +6 -0
- package/file-upload/views/file-upload-view.js +17 -0
- package/grid/grid.d.ts +23 -0
- package/grid/grid.js +111 -0
- package/grid/index.d.ts +3 -0
- package/grid/index.js +2 -0
- package/grid/presets.d.ts +1 -0
- package/grid/presets.js +1 -0
- package/grid/styles.module.css +56 -0
- package/grid/types.d.ts +52 -0
- package/grid/types.js +1 -0
- package/grid-item/grid-item.d.ts +2 -0
- package/grid-item/grid-item.js +13 -0
- package/grid-item/index.d.ts +2 -0
- package/grid-item/index.js +1 -0
- package/grid-item/types.d.ts +13 -0
- package/grid-item/types.js +1 -0
- package/hint/buttons/action-button.d.ts +9 -0
- package/hint/buttons/action-button.js +19 -0
- package/hint/buttons/close-button.d.ts +10 -0
- package/hint/buttons/close-button.js +23 -0
- package/hint/buttons/extra-button.d.ts +9 -0
- package/hint/buttons/extra-button.js +19 -0
- package/hint/hint-content.d.ts +17 -0
- package/hint/hint-content.js +21 -0
- package/hint/hint-provider.d.ts +6 -0
- package/hint/hint-provider.js +10 -0
- package/hint/hint.d.ts +12 -0
- package/hint/hint.js +50 -0
- package/hint/index.d.ts +6 -0
- package/hint/index.js +5 -0
- package/hint/styles/buttons.module.css +16 -0
- package/hint/styles/hint-content.module.css +33 -0
- package/hint/styles/hint.module.css +37 -0
- package/hint/types.d.ts +103 -0
- package/hint/types.js +1 -0
- package/hooks/index.d.ts +21 -0
- package/hooks/index.js +21 -0
- package/hooks/media-query/create-media-query.d.ts +2 -0
- package/hooks/media-query/create-media-query.js +19 -0
- package/hooks/media-query/index.d.ts +3 -0
- package/hooks/media-query/index.js +2 -0
- package/hooks/media-query/observe-media-query.d.ts +5 -0
- package/hooks/media-query/observe-media-query.js +25 -0
- package/hooks/media-query/types.d.ts +8 -0
- package/hooks/media-query/types.js +1 -0
- package/hooks/media-query/use-media-query-listener.d.ts +8 -0
- package/hooks/media-query/use-media-query-listener.js +32 -0
- package/hooks/media-query/use-media-query.d.ts +10 -0
- package/hooks/media-query/use-media-query.js +24 -0
- package/hooks/use-actual-ref.d.ts +7 -0
- package/hooks/use-actual-ref.js +11 -0
- package/hooks/use-breakpoint.d.ts +13 -0
- package/hooks/use-breakpoint.js +50 -0
- package/hooks/use-click-outside.d.ts +5 -0
- package/hooks/use-click-outside.js +40 -0
- package/hooks/use-component-tokens.d.ts +12 -0
- package/hooks/use-component-tokens.js +17 -0
- package/hooks/use-cssvar-from-width.d.ts +3 -0
- package/hooks/use-cssvar-from-width.js +31 -0
- package/hooks/use-effect-once.d.ts +6 -0
- package/hooks/use-effect-once.js +10 -0
- package/hooks/use-isomorphic-layout-effect.d.ts +2 -0
- package/hooks/use-isomorphic-layout-effect.js +6 -0
- package/hooks/use-keyboard-callbacks.d.ts +15 -0
- package/hooks/use-keyboard-callbacks.js +121 -0
- package/hooks/use-keyboard-navigation.d.ts +14 -0
- package/hooks/use-keyboard-navigation.js +63 -0
- package/hooks/use-list-navigation/index.d.ts +8 -0
- package/hooks/use-list-navigation/index.js +4 -0
- package/hooks/use-list-navigation/input-modality.d.ts +8 -0
- package/hooks/use-list-navigation/input-modality.js +52 -0
- package/hooks/use-list-navigation/store.d.ts +31 -0
- package/hooks/use-list-navigation/store.js +67 -0
- package/hooks/use-list-navigation/types.d.ts +108 -0
- package/hooks/use-list-navigation/types.js +1 -0
- package/hooks/use-list-navigation/use-list-navigation-item.d.ts +12 -0
- package/hooks/use-list-navigation/use-list-navigation-item.js +36 -0
- package/hooks/use-list-navigation/use-list-navigation.d.ts +29 -0
- package/hooks/use-list-navigation/use-list-navigation.js +257 -0
- package/hooks/use-list-navigation/utils.d.ts +12 -0
- package/hooks/use-list-navigation/utils.js +47 -0
- package/hooks/use-load-more.d.ts +48 -0
- package/hooks/use-load-more.js +69 -0
- package/hooks/use-mount.d.ts +4 -0
- package/hooks/use-mount.js +10 -0
- package/hooks/use-persistent-callback.d.ts +5 -0
- package/hooks/use-persistent-callback.js +15 -0
- package/hooks/use-platform.d.ts +5 -0
- package/hooks/use-platform.js +34 -0
- package/hooks/use-responsive-value.d.ts +20 -0
- package/hooks/use-responsive-value.js +34 -0
- package/hooks/use-uniq-id.d.ts +12 -0
- package/hooks/use-uniq-id.js +16 -0
- package/hooks/use-unmount.d.ts +4 -0
- package/hooks/use-unmount.js +13 -0
- package/hooks/use-update-effect.d.ts +8 -0
- package/hooks/use-update-effect.js +23 -0
- package/hooks/use-viewport-exit.d.ts +6 -0
- package/hooks/use-viewport-exit.js +29 -0
- package/hooks/use-virtual-window.d.ts +44 -0
- package/hooks/use-virtual-window.js +83 -0
- package/hooks/use-window-size.d.ts +7 -0
- package/hooks/use-window-size.js +23 -0
- package/icon/icon.d.ts +118 -0
- package/icon/icon.js +32 -0
- package/icon/index.d.ts +1 -0
- package/icon/index.js +1 -0
- package/icon/pack-utils.d.ts +19 -0
- package/icon/pack-utils.js +24 -0
- package/icon/styles.module.css +17 -0
- package/icons/arrow-icon.d.ts +8 -0
- package/icons/arrow-icon.js +9 -0
- package/icons/back-icon.d.ts +2 -0
- package/icons/back-icon.js +3 -0
- package/icons/calendar-icon.d.ts +2 -0
- package/icons/calendar-icon.js +3 -0
- package/icons/check-icon.d.ts +2 -0
- package/icons/check-icon.js +5 -0
- package/icons/clock-icon.d.ts +2 -0
- package/icons/clock-icon.js +5 -0
- package/icons/close-icon.d.ts +2 -0
- package/icons/close-icon.js +3 -0
- package/icons/del-icon.d.ts +2 -0
- package/icons/del-icon.js +3 -0
- package/icons/double-arrow-icon.d.ts +6 -0
- package/icons/double-arrow-icon.js +8 -0
- package/icons/error-icon.d.ts +2 -0
- package/icons/error-icon.js +3 -0
- package/icons/eye-icon.d.ts +3 -0
- package/icons/eye-icon.js +4 -0
- package/icons/index.d.ts +15 -0
- package/icons/index.js +15 -0
- package/icons/magnifying-glass-icon.d.ts +2 -0
- package/icons/magnifying-glass-icon.js +3 -0
- package/icons/minus-icon.d.ts +2 -0
- package/icons/minus-icon.js +3 -0
- package/icons/plus-icon.d.ts +2 -0
- package/icons/plus-icon.js +3 -0
- package/icons/reset-icon.d.ts +2 -0
- package/icons/reset-icon.js +3 -0
- package/icons/shopping-icon.d.ts +2 -0
- package/icons/shopping-icon.js +3 -0
- package/icons/stars/star-fill-icon.d.ts +2 -0
- package/icons/stars/star-fill-icon.js +3 -0
- package/icons/stars/star-half-icon.d.ts +4 -0
- package/icons/stars/star-half-icon.js +3 -0
- package/icons/stars/start-outline-icon.d.ts +5 -0
- package/icons/stars/start-outline-icon.js +3 -0
- package/icons/types.d.ts +2 -0
- package/icons/types.js +1 -0
- package/image/image-viewer.d.ts +17 -0
- package/image/image-viewer.js +41 -0
- package/image/image.d.ts +27 -0
- package/image/image.js +67 -0
- package/image/index.d.ts +2 -0
- package/image/index.js +1 -0
- package/image/style.module.css +65 -0
- package/image/types.d.ts +88 -0
- package/image/types.js +1 -0
- package/image/use-image.d.ts +18 -0
- package/image/use-image.js +44 -0
- package/image/viewer.module.css +80 -0
- package/index.d.ts +67 -0
- package/index.js +64 -0
- package/input/fields/password-toggle.d.ts +10 -0
- package/input/fields/password-toggle.js +10 -0
- package/input/fields/text-field.d.ts +3 -0
- package/input/fields/text-field.js +23 -0
- package/input/fields/use-text-field.d.ts +676 -0
- package/input/fields/use-text-field.js +76 -0
- package/input/index.d.ts +2 -0
- package/input/index.js +1 -0
- package/input/input.d.ts +13 -0
- package/input/input.js +18 -0
- package/input/types.d.ts +30 -0
- package/input/types.js +1 -0
- package/label/index.d.ts +2 -0
- package/label/index.js +2 -0
- package/label/label.d.ts +19 -0
- package/label/label.js +43 -0
- package/label/styles.module.css +25 -0
- package/label/types.d.ts +45 -0
- package/label/types.js +1 -0
- package/list/clear-all-button/clear-all-button.d.ts +9 -0
- package/list/clear-all-button/clear-all-button.js +11 -0
- package/list/clear-all-button/index.d.ts +1 -0
- package/list/clear-all-button/index.js +1 -0
- package/list/constants.d.ts +1 -0
- package/list/constants.js +1 -0
- package/list/index.d.ts +6 -0
- package/list/index.js +4 -0
- package/list/list-context.d.ts +15 -0
- package/list/list-context.js +10 -0
- package/list/list-divider/index.d.ts +1 -0
- package/list/list-divider/index.js +1 -0
- package/list/list-divider/list-divider.d.ts +2 -0
- package/list/list-divider/list-divider.js +10 -0
- package/list/list-divider/styles.module.css +7 -0
- package/list/list-divider/use-list-divider.d.ts +3 -0
- package/list/list-divider/use-list-divider.js +12 -0
- package/list/list-item/index.d.ts +2 -0
- package/list/list-item/index.js +1 -0
- package/list/list-item/list-icon.d.ts +11 -0
- package/list/list-item/list-icon.js +22 -0
- package/list/list-item/list-item-provider.d.ts +13 -0
- package/list/list-item/list-item-provider.js +14 -0
- package/list/list-item/list-item.d.ts +5 -0
- package/list/list-item/list-item.js +26 -0
- package/list/list-item/styles.module.css +216 -0
- package/list/list-item/types.d.ts +100 -0
- package/list/list-item/types.js +1 -0
- package/list/list-item/use-list-item.d.ts +28 -0
- package/list/list-item/use-list-item.js +75 -0
- package/list/list-item/use-nested-list.d.ts +4 -0
- package/list/list-item/use-nested-list.js +14 -0
- package/list/list-section/index.d.ts +1 -0
- package/list/list-section/index.js +1 -0
- package/list/list-section/list-section.d.ts +32 -0
- package/list/list-section/list-section.js +28 -0
- package/list/list-section/styles.module.css +27 -0
- package/list/list.d.ts +20 -0
- package/list/list.js +33 -0
- package/list/styles.module.css +24 -0
- package/list/types.d.ts +73 -0
- package/list/types.js +1 -0
- package/list/use-list.d.ts +17 -0
- package/list/use-list.js +70 -0
- package/loader/index.d.ts +1 -0
- package/loader/index.js +1 -0
- package/loader/loader.d.ts +46 -0
- package/loader/loader.js +24 -0
- package/loader/loader.module.css +80 -0
- package/locale/create-translator.d.ts +8 -0
- package/locale/create-translator.js +10 -0
- package/locale/en.d.ts +2 -0
- package/locale/en.js +106 -0
- package/locale/index.d.ts +8 -0
- package/locale/index.js +5 -0
- package/locale/locale-provider.d.ts +30 -0
- package/locale/locale-provider.js +17 -0
- package/locale/ru.d.ts +2 -0
- package/locale/ru.js +106 -0
- package/locale/types.d.ts +183 -0
- package/locale/types.js +1 -0
- package/locale/use-locale.d.ts +9 -0
- package/locale/use-locale.js +8 -0
- package/masked-input/constants.d.ts +5 -0
- package/masked-input/constants.js +5 -0
- package/masked-input/hooks.d.ts +14 -0
- package/masked-input/hooks.js +172 -0
- package/masked-input/index.d.ts +3 -0
- package/masked-input/index.js +1 -0
- package/masked-input/mask-types.d.ts +27 -0
- package/masked-input/mask-types.js +1 -0
- package/masked-input/masked-input.d.ts +12 -0
- package/masked-input/masked-input.js +21 -0
- package/masked-input/types.d.ts +27 -0
- package/masked-input/types.js +1 -0
- package/masked-input/use-mask.d.ts +648 -0
- package/masked-input/use-mask.js +164 -0
- package/masked-input/utils/get-autofill-selector.d.ts +1 -0
- package/masked-input/utils/get-autofill-selector.js +11 -0
- package/masked-input/utils/helpers.d.ts +17 -0
- package/masked-input/utils/helpers.js +50 -0
- package/masked-input/utils/index.d.ts +4 -0
- package/masked-input/utils/index.js +4 -0
- package/masked-input/utils/mask-utils.d.ts +20 -0
- package/masked-input/utils/mask-utils.js +207 -0
- package/masked-input/utils/parse-mask.d.ts +2 -0
- package/masked-input/utils/parse-mask.js +57 -0
- package/masked-input/utils/validate-props.d.ts +3 -0
- package/masked-input/utils/validate-props.js +10 -0
- package/modal/constants.d.ts +2 -0
- package/modal/constants.js +2 -0
- package/modal/index.d.ts +5 -0
- package/modal/index.js +5 -0
- package/modal/modal-close-button.d.ts +3 -0
- package/modal/modal-close-button.js +13 -0
- package/modal/modal-content.d.ts +5 -0
- package/modal/modal-content.js +37 -0
- package/modal/modal-context.d.ts +18 -0
- package/modal/modal-context.js +10 -0
- package/modal/modal-footer.d.ts +8 -0
- package/modal/modal-footer.js +18 -0
- package/modal/modal-header.d.ts +8 -0
- package/modal/modal-header.js +18 -0
- package/modal/modal.d.ts +22 -0
- package/modal/modal.js +56 -0
- package/modal/styles/_animations.css +124 -0
- package/modal/styles/_config.css +0 -0
- package/modal/styles/modal-content.module.css +30 -0
- package/modal/styles/modal-footer.module.css +31 -0
- package/modal/styles/modal-header.module.css +56 -0
- package/modal/styles/modal.module.css +284 -0
- package/modal/types.d.ts +74 -0
- package/modal/types.js +1 -0
- package/modal/use-modal-refs.d.ts +5 -0
- package/modal/use-modal-refs.js +12 -0
- package/modal/use-modal.d.ts +22 -0
- package/modal/use-modal.js +49 -0
- package/modal/utils.d.ts +11 -0
- package/modal/utils.js +12 -0
- package/navigation/context.d.ts +72 -0
- package/navigation/context.js +19 -0
- package/navigation/index.d.ts +5 -0
- package/navigation/index.js +3 -0
- package/navigation/navigation-compact.d.ts +12 -0
- package/navigation/navigation-compact.js +83 -0
- package/navigation/navigation-control.d.ts +15 -0
- package/navigation/navigation-control.js +53 -0
- package/navigation/navigation-item-content.d.ts +25 -0
- package/navigation/navigation-item-content.js +26 -0
- package/navigation/navigation-list.d.ts +15 -0
- package/navigation/navigation-list.js +51 -0
- package/navigation/navigation-rail.d.ts +9 -0
- package/navigation/navigation-rail.js +25 -0
- package/navigation/navigation-row.d.ts +8 -0
- package/navigation/navigation-row.js +47 -0
- package/navigation/navigation-tree.d.ts +11 -0
- package/navigation/navigation-tree.js +61 -0
- package/navigation/navigation-views.d.ts +23 -0
- package/navigation/navigation-views.js +72 -0
- package/navigation/navigation.d.ts +45 -0
- package/navigation/navigation.js +114 -0
- package/navigation/storage.d.ts +2 -0
- package/navigation/storage.js +23 -0
- package/navigation/styles/navigation.module.css +567 -0
- package/navigation/types.d.ts +189 -0
- package/navigation/types.js +1 -0
- package/navigation/use-item-tooltip.d.ts +14 -0
- package/navigation/use-item-tooltip.js +17 -0
- package/navigation/use-navigation-types.d.ts +33 -0
- package/navigation/use-navigation-types.js +1 -0
- package/navigation/use-navigation.d.ts +8 -0
- package/navigation/use-navigation.js +138 -0
- package/navigation/use-overflow.d.ts +16 -0
- package/navigation/use-overflow.js +38 -0
- package/navigation/utils.d.ts +30 -0
- package/navigation/utils.js +90 -0
- package/number-input/format-types.d.ts +58 -0
- package/number-input/format-types.js +5 -0
- package/number-input/format-utils.d.ts +11 -0
- package/number-input/format-utils.js +160 -0
- package/number-input/hooks/index.d.ts +2 -0
- package/number-input/hooks/index.js +1 -0
- package/number-input/hooks/use-numeric-format.d.ts +15 -0
- package/number-input/hooks/use-numeric-format.js +133 -0
- package/number-input/index.d.ts +2 -0
- package/number-input/index.js +1 -0
- package/number-input/number-input.d.ts +11 -0
- package/number-input/number-input.js +20 -0
- package/number-input/types.d.ts +47 -0
- package/number-input/types.js +1 -0
- package/number-input/use-number-input.d.ts +664 -0
- package/number-input/use-number-input.js +402 -0
- package/number-input/utils.d.ts +63 -0
- package/number-input/utils.js +300 -0
- package/package.json +361 -4
- package/pagination/index.d.ts +6 -0
- package/pagination/index.js +3 -0
- package/pagination/items.d.ts +21 -0
- package/pagination/items.js +44 -0
- package/pagination/labels.d.ts +4 -0
- package/pagination/labels.js +13 -0
- package/pagination/pagination.d.ts +30 -0
- package/pagination/pagination.js +59 -0
- package/pagination/styles.module.css +125 -0
- package/pagination/types.d.ts +99 -0
- package/pagination/types.js +1 -0
- package/pagination/use-pagination.d.ts +13 -0
- package/pagination/use-pagination.js +24 -0
- package/pin-input/index.d.ts +2 -0
- package/pin-input/index.js +1 -0
- package/pin-input/pin-input.d.ts +26 -0
- package/pin-input/pin-input.js +27 -0
- package/pin-input/styles.module.css +68 -0
- package/pin-input/types.d.ts +83 -0
- package/pin-input/types.js +1 -0
- package/pin-input/use-pin-input.d.ts +23 -0
- package/pin-input/use-pin-input.js +134 -0
- package/pin-input/utils.d.ts +7 -0
- package/pin-input/utils.js +11 -0
- package/popover/index.d.ts +5 -0
- package/popover/index.js +3 -0
- package/popover/popover.d.ts +13 -0
- package/popover/popover.js +37 -0
- package/popover/styles.module.css +76 -0
- package/popover/types.d.ts +115 -0
- package/popover/types.js +1 -0
- package/popover/use-popover.d.ts +24 -0
- package/popover/use-popover.js +121 -0
- package/portal/index.d.ts +4 -0
- package/portal/index.js +3 -0
- package/portal/portal-provider.d.ts +13 -0
- package/portal/portal-provider.js +17 -0
- package/portal/portal.d.ts +34 -0
- package/portal/portal.js +42 -0
- package/portal/resolve-container.d.ts +3 -0
- package/portal/resolve-container.js +11 -0
- package/portal/types.d.ts +25 -0
- package/portal/types.js +1 -0
- package/portal/use-portal.d.ts +14 -0
- package/portal/use-portal.js +45 -0
- package/progress-bar/index.d.ts +2 -0
- package/progress-bar/index.js +1 -0
- package/progress-bar/progress-bar.d.ts +12 -0
- package/progress-bar/progress-bar.js +50 -0
- package/progress-bar/styles.module.css +147 -0
- package/progress-bar/types.d.ts +45 -0
- package/progress-bar/types.js +1 -0
- package/quantity-input/index.d.ts +2 -0
- package/quantity-input/index.js +1 -0
- package/quantity-input/quantity-input.d.ts +22 -0
- package/quantity-input/quantity-input.js +84 -0
- package/quantity-input/styles.module.css +44 -0
- package/quantity-input/types.d.ts +54 -0
- package/quantity-input/types.js +1 -0
- package/quantity-input/utils.d.ts +10 -0
- package/quantity-input/utils.js +16 -0
- package/radio/index.d.ts +2 -0
- package/radio/index.js +2 -0
- package/radio/radio.d.ts +9 -0
- package/radio/radio.js +44 -0
- package/radio/styles.module.css +161 -0
- package/radio/types.d.ts +40 -0
- package/radio/types.js +1 -0
- package/radio-group/index.d.ts +2 -0
- package/radio-group/index.js +2 -0
- package/radio-group/radio-group-context.d.ts +14 -0
- package/radio-group/radio-group-context.js +5 -0
- package/radio-group/radio-group.d.ts +57 -0
- package/radio-group/radio-group.js +41 -0
- package/radio-group/styles.module.css +12 -0
- package/radio-group/use-radio-group.d.ts +8 -0
- package/radio-group/use-radio-group.js +4 -0
- package/scss/_functions.scss +101 -0
- package/scss/_grid.scss +89 -0
- package/scss/_index.scss +6 -0
- package/scss/_interaction.scss +36 -0
- package/scss/_mixins.scss +62 -0
- package/scss/_tokens.generated.scss +578 -0
- package/scss/_tokens.scss +2 -0
- package/scss/_typography.scss +316 -0
- package/segmented-control/index.d.ts +3 -0
- package/segmented-control/index.js +2 -0
- package/segmented-control/segmented-control-context.d.ts +13 -0
- package/segmented-control/segmented-control-context.js +8 -0
- package/segmented-control/segmented-control-item.d.ts +3 -0
- package/segmented-control/segmented-control-item.js +39 -0
- package/segmented-control/segmented-control.d.ts +21 -0
- package/segmented-control/segmented-control.js +36 -0
- package/segmented-control/styles/_variables.css +0 -0
- package/segmented-control/styles/segmented-control-item.module.css +194 -0
- package/segmented-control/styles/segmented-control.module.css +31 -0
- package/segmented-control/types.d.ts +95 -0
- package/segmented-control/types.js +1 -0
- package/segmented-control/use-segmented-control.d.ts +9 -0
- package/segmented-control/use-segmented-control.js +30 -0
- package/select/class-names-context.d.ts +18 -0
- package/select/class-names-context.js +3 -0
- package/select/components/render-grouped-options.d.ts +18 -0
- package/select/components/render-grouped-options.js +41 -0
- package/select/components/select-field-multiselect-value.d.ts +23 -0
- package/select/components/select-field-multiselect-value.js +17 -0
- package/select/components/select-field-value.d.ts +38 -0
- package/select/components/select-field-value.js +54 -0
- package/select/components/select-field.d.ts +41 -0
- package/select/components/select-field.js +182 -0
- package/select/components/select-load-more-indicator.d.ts +6 -0
- package/select/components/select-load-more-indicator.js +7 -0
- package/select/components/select-multiselect-panel.d.ts +60 -0
- package/select/components/select-multiselect-panel.js +163 -0
- package/select/components/select-option-list.d.ts +23 -0
- package/select/components/select-option-list.js +72 -0
- package/select/components/select-option-row.d.ts +19 -0
- package/select/components/select-option-row.js +40 -0
- package/select/components/select-options-scroll-area.d.ts +13 -0
- package/select/components/select-options-scroll-area.js +8 -0
- package/select/components/select-panel-status.d.ts +11 -0
- package/select/components/select-panel-status.js +17 -0
- package/select/components/select-single-panel.d.ts +27 -0
- package/select/components/select-single-panel.js +41 -0
- package/select/hooks/use-auto-scroll-to-bottom.d.ts +7 -0
- package/select/hooks/use-auto-scroll-to-bottom.js +23 -0
- package/select/hooks/use-chips-row-count.d.ts +23 -0
- package/select/hooks/use-chips-row-count.js +61 -0
- package/select/hooks/use-multiselect-collapsed-display.d.ts +8 -0
- package/select/hooks/use-multiselect-collapsed-display.js +134 -0
- package/select/hooks/use-select-dismiss.d.ts +17 -0
- package/select/hooks/use-select-dismiss.js +79 -0
- package/select/hooks/use-select-input-bindings.d.ts +37 -0
- package/select/hooks/use-select-input-bindings.js +43 -0
- package/select/hooks/use-select-keyboard.d.ts +24 -0
- package/select/hooks/use-select-keyboard.js +171 -0
- package/select/hooks/use-select-multiselect-panel-state.d.ts +8 -0
- package/select/hooks/use-select-multiselect-panel-state.js +28 -0
- package/select/hooks/use-select-search.d.ts +9 -0
- package/select/hooks/use-select-search.js +258 -0
- package/select/hooks/use-select-view-model.d.ts +58 -0
- package/select/hooks/use-select-view-model.js +166 -0
- package/select/hooks/use-select-virtual.d.ts +28 -0
- package/select/hooks/use-select-virtual.js +31 -0
- package/select/hooks/use-select.d.ts +9 -0
- package/select/hooks/use-select.js +435 -0
- package/select/index.d.ts +20 -0
- package/select/index.js +12 -0
- package/select/presets/autocomplete.d.ts +12 -0
- package/select/presets/autocomplete.js +16 -0
- package/select/presets/index.d.ts +1 -0
- package/select/presets/index.js +1 -0
- package/select/select.d.ts +25 -0
- package/select/select.js +19 -0
- package/select/styles/select-field.module.css +147 -0
- package/select/styles/select.module.css +457 -0
- package/select/types-search.d.ts +151 -0
- package/select/types-search.js +1 -0
- package/select/types.d.ts +374 -0
- package/select/types.js +1 -0
- package/select/utils/custom-search-option.d.ts +15 -0
- package/select/utils/custom-search-option.js +37 -0
- package/select/utils/filter-options.d.ts +5 -0
- package/select/utils/filter-options.js +23 -0
- package/select/utils/get-display-value.d.ts +13 -0
- package/select/utils/get-display-value.js +16 -0
- package/select/utils/get-element-content-width.d.ts +1 -0
- package/select/utils/get-element-content-width.js +11 -0
- package/select/utils/get-multiselect-display-labels.d.ts +3 -0
- package/select/utils/get-multiselect-display-labels.js +7 -0
- package/select/utils/get-status-content.d.ts +11 -0
- package/select/utils/get-status-content.js +10 -0
- package/select/utils/is-select-panel-compact-content.d.ts +3 -0
- package/select/utils/is-select-panel-compact-content.js +4 -0
- package/select/utils/measure-multiselect-row-width.d.ts +10 -0
- package/select/utils/measure-multiselect-row-width.js +15 -0
- package/select/utils/measure-text-width.d.ts +9 -0
- package/select/utils/measure-text-width.js +72 -0
- package/select/utils/multiselect-collapsed-display-shared.d.ts +40 -0
- package/select/utils/multiselect-collapsed-display-shared.js +145 -0
- package/select/utils/normalize-options.d.ts +4 -0
- package/select/utils/normalize-options.js +7 -0
- package/select/utils/normalize-value.d.ts +5 -0
- package/select/utils/normalize-value.js +18 -0
- package/select/utils/resolve-loading-state.d.ts +9 -0
- package/select/utils/resolve-loading-state.js +10 -0
- package/select/utils/resolve-multiselect-collapsed-display.d.ts +6 -0
- package/select/utils/resolve-multiselect-collapsed-display.js +42 -0
- package/select/utils/resolve-search-content.d.ts +3 -0
- package/select/utils/resolve-search-content.js +6 -0
- package/select/utils/retain-combobox-focus.d.ts +4 -0
- package/select/utils/retain-combobox-focus.js +17 -0
- package/select/utils/select-keyboard-navigation.d.ts +3 -0
- package/select/utils/select-keyboard-navigation.js +14 -0
- package/select/utils/select-load-more-scroll.d.ts +16 -0
- package/select/utils/select-load-more-scroll.js +20 -0
- package/select/utils/select-option-id.d.ts +3 -0
- package/select/utils/select-option-id.js +4 -0
- package/select/views/select-listbox.d.ts +10 -0
- package/select/views/select-listbox.js +15 -0
- package/select/views/select-search-listbox.d.ts +3 -0
- package/select/views/select-search-listbox.js +23 -0
- package/select/views/select-view.d.ts +6 -0
- package/select/views/select-view.js +64 -0
- package/select/views/styles.module.css +45 -0
- package/show-more/hooks/use-show-more-view-model.d.ts +24 -0
- package/show-more/hooks/use-show-more-view-model.js +76 -0
- package/show-more/index.d.ts +2 -0
- package/show-more/index.js +1 -0
- package/show-more/show-more.d.ts +21 -0
- package/show-more/show-more.js +15 -0
- package/show-more/styles.module.css +20 -0
- package/show-more/types.d.ts +46 -0
- package/show-more/types.js +1 -0
- package/show-more/views/show-more-view.d.ts +6 -0
- package/show-more/views/show-more-view.js +9 -0
- package/skeleton/index.d.ts +2 -0
- package/skeleton/index.js +2 -0
- package/skeleton/skeleton.d.ts +13 -0
- package/skeleton/skeleton.js +44 -0
- package/skeleton/styles.module.css +300 -0
- package/skeleton/types.d.ts +85 -0
- package/skeleton/types.js +1 -0
- package/skeleton/use-skeleton.d.ts +7 -0
- package/skeleton/use-skeleton.js +20 -0
- package/snackbar/index.d.ts +6 -0
- package/snackbar/index.js +5 -0
- package/snackbar/snack-button.d.ts +10 -0
- package/snackbar/snack-button.js +19 -0
- package/snackbar/snack-view.d.ts +8 -0
- package/snackbar/snack-view.js +66 -0
- package/snackbar/snack.d.ts +14 -0
- package/snackbar/snack.js +25 -0
- package/snackbar/snackbar-context.d.ts +9 -0
- package/snackbar/snackbar-context.js +10 -0
- package/snackbar/snackbar-provider.d.ts +17 -0
- package/snackbar/snackbar-provider.js +49 -0
- package/snackbar/snackbar.d.ts +26 -0
- package/snackbar/snackbar.js +41 -0
- package/snackbar/styles/snack.module.css +195 -0
- package/snackbar/styles/snackbar.module.css +66 -0
- package/snackbar/types.d.ts +152 -0
- package/snackbar/types.js +1 -0
- package/snackbar/use-snack-timer.d.ts +5 -0
- package/snackbar/use-snack-timer.js +28 -0
- package/snackbar/use-snack.d.ts +326 -0
- package/snackbar/use-snack.js +82 -0
- package/stack/index.d.ts +1 -0
- package/stack/index.js +1 -0
- package/stack/stack.d.ts +16 -0
- package/stack/stack.js +34 -0
- package/stack/styles.module.css +46 -0
- package/stack/types.d.ts +34 -0
- package/stack/types.js +1 -0
- package/status/index.d.ts +2 -0
- package/status/index.js +1 -0
- package/status/status-icon.d.ts +18 -0
- package/status/status-icon.js +19 -0
- package/status/styles.module.css +18 -0
- package/status/types.d.ts +12 -0
- package/status/types.js +1 -0
- package/stepper/index.d.ts +3 -0
- package/stepper/index.js +2 -0
- package/stepper/stepper.d.ts +24 -0
- package/stepper/stepper.js +41 -0
- package/stepper/styles.module.css +172 -0
- package/stepper/types.d.ts +69 -0
- package/stepper/types.js +1 -0
- package/stepper/use-stepper.d.ts +11 -0
- package/stepper/use-stepper.js +25 -0
- package/switch/index.d.ts +2 -0
- package/switch/index.js +2 -0
- package/switch/styles/base.module.css +134 -0
- package/switch/switch.d.ts +14 -0
- package/switch/switch.js +39 -0
- package/switch/types.d.ts +60 -0
- package/switch/types.js +1 -0
- package/tabs/context.d.ts +21 -0
- package/tabs/context.js +9 -0
- package/tabs/index.d.ts +6 -0
- package/tabs/index.js +5 -0
- package/tabs/styles/tab-list.module.css +23 -0
- package/tabs/styles/tab-panel.module.css +3 -0
- package/tabs/styles/tab.module.css +210 -0
- package/tabs/tab-list.d.ts +14 -0
- package/tabs/tab-list.js +70 -0
- package/tabs/tab-panel.d.ts +8 -0
- package/tabs/tab-panel.js +16 -0
- package/tabs/tab.d.ts +10 -0
- package/tabs/tab.js +40 -0
- package/tabs/tabs.d.ts +18 -0
- package/tabs/tabs.js +26 -0
- package/tabs/types.d.ts +92 -0
- package/tabs/types.js +1 -0
- package/tabs/use-tabs.d.ts +7 -0
- package/tabs/use-tabs.js +59 -0
- package/textarea/get-max-length-message.d.ts +1 -0
- package/textarea/get-max-length-message.js +5 -0
- package/textarea/index.d.ts +2 -0
- package/textarea/index.js +1 -0
- package/textarea/styles.module.css +37 -0
- package/textarea/textarea.d.ts +9 -0
- package/textarea/textarea.js +20 -0
- package/textarea/types.d.ts +44 -0
- package/textarea/types.js +1 -0
- package/textarea/use-auto-height.d.ts +16 -0
- package/textarea/use-auto-height.js +106 -0
- package/textarea/use-resize-handle.d.ts +8 -0
- package/textarea/use-resize-handle.js +44 -0
- package/textarea/use-textarea.d.ts +1241 -0
- package/textarea/use-textarea.js +108 -0
- package/theme-provider/index.d.ts +9 -0
- package/theme-provider/index.js +5 -0
- package/theme-provider/styles.module.css +332 -0
- package/theme-provider/theme-context.d.ts +31 -0
- package/theme-provider/theme-context.js +33 -0
- package/theme-provider/theme-provider.d.ts +14 -0
- package/theme-provider/theme-provider.js +45 -0
- package/theme-provider/theme-scope.d.ts +33 -0
- package/theme-provider/theme-scope.js +45 -0
- package/theme-provider/types.d.ts +82 -0
- package/theme-provider/types.js +1 -0
- package/theme-provider/use-system-theme.d.ts +6 -0
- package/theme-provider/use-system-theme.js +23 -0
- package/theme-provider/use-theme-provider.d.ts +8 -0
- package/theme-provider/use-theme-provider.js +22 -0
- package/time-picker/index.d.ts +8 -0
- package/time-picker/index.js +6 -0
- package/time-picker/picker-types.d.ts +77 -0
- package/time-picker/picker-types.js +1 -0
- package/time-picker/single-time-picker.d.ts +3 -0
- package/time-picker/single-time-picker.js +37 -0
- package/time-picker/styles.module.css +124 -0
- package/time-picker/time-model.d.ts +34 -0
- package/time-picker/time-model.js +140 -0
- package/time-picker/time-panel.d.ts +20 -0
- package/time-picker/time-panel.js +81 -0
- package/time-picker/time-picker.d.ts +13 -0
- package/time-picker/time-picker.js +43 -0
- package/time-picker/time-range-picker.d.ts +3 -0
- package/time-picker/time-range-picker.js +44 -0
- package/time-picker/types.d.ts +158 -0
- package/time-picker/types.js +1 -0
- package/time-picker/use-time-panel.d.ts +12 -0
- package/time-picker/use-time-panel.js +22 -0
- package/time-picker/use-time-picker.d.ts +29 -0
- package/time-picker/use-time-picker.js +117 -0
- package/time-picker/use-time-range-picker.d.ts +36 -0
- package/time-picker/use-time-range-picker.js +131 -0
- package/tokens/index.d.ts +1 -0
- package/tokens/index.js +2 -0
- package/tooltip/index.d.ts +2 -0
- package/tooltip/index.js +1 -0
- package/tooltip/styles.module.css +46 -0
- package/tooltip/tooltip.d.ts +12 -0
- package/tooltip/tooltip.js +30 -0
- package/tooltip/types.d.ts +41 -0
- package/tooltip/types.js +1 -0
- package/tooltip/use-tooltip.d.ts +18 -0
- package/tooltip/use-tooltip.js +37 -0
- package/tree/check.d.ts +16 -0
- package/tree/check.js +99 -0
- package/tree/class-names-context.d.ts +3 -0
- package/tree/class-names-context.js +5 -0
- package/tree/highlight.d.ts +3 -0
- package/tree/highlight.js +23 -0
- package/tree/index.d.ts +11 -0
- package/tree/index.js +6 -0
- package/tree/model.d.ts +59 -0
- package/tree/model.js +110 -0
- package/tree/move.d.ts +42 -0
- package/tree/move.js +103 -0
- package/tree/styles.module.css +290 -0
- package/tree/tree-branch.d.ts +23 -0
- package/tree/tree-branch.js +41 -0
- package/tree/tree-placeholder.d.ts +11 -0
- package/tree/tree-placeholder.js +10 -0
- package/tree/tree-row-content.d.ts +27 -0
- package/tree/tree-row-content.js +25 -0
- package/tree/tree-row-renderer.d.ts +12 -0
- package/tree/tree-row-renderer.js +54 -0
- package/tree/tree-row.d.ts +30 -0
- package/tree/tree-row.js +92 -0
- package/tree/tree-select-panel.d.ts +22 -0
- package/tree/tree-select-panel.js +9 -0
- package/tree/tree-select-selection.d.ts +20 -0
- package/tree/tree-select-selection.js +28 -0
- package/tree/tree-select-types.d.ts +102 -0
- package/tree/tree-select-types.js +1 -0
- package/tree/tree-select.d.ts +32 -0
- package/tree/tree-select.js +201 -0
- package/tree/tree-select.module.css +35 -0
- package/tree/tree.d.ts +57 -0
- package/tree/tree.js +93 -0
- package/tree/types-row.d.ts +51 -0
- package/tree/types-row.js +1 -0
- package/tree/types.d.ts +192 -0
- package/tree/types.js +1 -0
- package/tree/use-tree-activate.d.ts +3 -0
- package/tree/use-tree-activate.js +14 -0
- package/tree/use-tree-checks.d.ts +17 -0
- package/tree/use-tree-checks.js +24 -0
- package/tree/use-tree-expansion.d.ts +17 -0
- package/tree/use-tree-expansion.js +71 -0
- package/tree/use-tree-keyboard.d.ts +17 -0
- package/tree/use-tree-keyboard.js +91 -0
- package/tree/use-tree-virtual.d.ts +33 -0
- package/tree/use-tree-virtual.js +72 -0
- package/tree/use-tree.d.ts +26 -0
- package/tree/use-tree.js +108 -0
- package/tree/virtual-rows.d.ts +11 -0
- package/tree/virtual-rows.js +9 -0
- package/types/size.d.ts +6 -0
- package/types/size.js +1 -0
- package/typography/index.d.ts +2 -0
- package/typography/index.js +1 -0
- package/typography/styles.module.css +304 -0
- package/typography/types.d.ts +61 -0
- package/typography/types.js +1 -0
- package/typography/typography.d.ts +21 -0
- package/typography/typography.js +24 -0
- package/utils/call-child-as-function.d.ts +1 -0
- package/utils/call-child-as-function.js +1 -0
- package/utils/class-names.d.ts +68 -0
- package/utils/class-names.js +164 -0
- package/utils/compose-event-handlers.d.ts +2 -0
- package/utils/compose-event-handlers.js +15 -0
- package/utils/container-props-override.d.ts +10 -0
- package/utils/container-props-override.js +19 -0
- package/utils/create-id.d.ts +5 -0
- package/utils/create-id.js +9 -0
- package/utils/data-attributes.d.ts +14 -0
- package/utils/data-attributes.js +23 -0
- package/utils/decode-uri.d.ts +23 -0
- package/utils/decode-uri.js +46 -0
- package/utils/empty-function.d.ts +2 -0
- package/utils/empty-function.js +4 -0
- package/utils/get-react-element-ref.d.ts +2 -0
- package/utils/get-react-element-ref.js +10 -0
- package/utils/imperative-change-input-value.d.ts +4 -0
- package/utils/imperative-change-input-value.js +15 -0
- package/utils/index.d.ts +20 -0
- package/utils/index.js +16 -0
- package/utils/input-caret.d.ts +4 -0
- package/utils/input-caret.js +42 -0
- package/utils/invariant.d.ts +5 -0
- package/utils/invariant.js +12 -0
- package/utils/is-browser.d.ts +1 -0
- package/utils/is-browser.js +1 -0
- package/utils/is-new-theme.d.ts +1 -0
- package/utils/is-new-theme.js +7 -0
- package/utils/merge-refs.d.ts +9 -0
- package/utils/merge-refs.js +36 -0
- package/utils/overridable-component.d.ts +47 -0
- package/utils/overridable-component.js +1 -0
- package/utils/shallow-objects-equal.d.ts +4 -0
- package/utils/shallow-objects-equal.js +16 -0
- package/utils/style/index.d.ts +3 -0
- package/utils/style/index.js +2 -0
- package/utils/style/props/color.d.ts +2 -0
- package/utils/style/props/color.js +6 -0
- package/utils/style/props/dimension.d.ts +2 -0
- package/utils/style/props/dimension.js +10 -0
- package/utils/style/props/index.d.ts +4 -0
- package/utils/style/props/index.js +3 -0
- package/utils/style/props/passthrough.d.ts +1 -0
- package/utils/style/props/passthrough.js +1 -0
- package/utils/style/props/types.d.ts +7 -0
- package/utils/style/props/types.js +1 -0
- package/utils/style/types.d.ts +6 -0
- package/utils/style/types.js +1 -0
- package/utils/style/use-style-props.d.ts +5 -0
- package/utils/style/use-style-props.js +7 -0
- package/utils/style/utils/convert-style-props.d.ts +4 -0
- package/utils/style/utils/convert-style-props.js +23 -0
- package/utils/style/utils/index.d.ts +1 -0
- package/utils/style/utils/index.js +1 -0
- package/utils/use-class-names.d.ts +37 -0
- package/utils/use-class-names.js +87 -0
- package/utils/utils.d.ts +9 -0
- package/utils/utils.js +1 -0
- package/visually-hidden/index.d.ts +1 -0
- package/visually-hidden/index.js +1 -0
- package/visually-hidden/styles.module.css +9 -0
- package/visually-hidden/visually-hidden.d.ts +6 -0
- package/visually-hidden/visually-hidden.js +6 -0
- package/README.md +0 -3
|
@@ -0,0 +1,288 @@
|
|
|
1
|
+
.root {
|
|
2
|
+
--translate-distance: 1px;
|
|
3
|
+
--button-min-height: var(--control-height-m);
|
|
4
|
+
--button-border-radius: var(--lt-ui-button-radius, var(--rounding-m));
|
|
5
|
+
max-width: 100%;
|
|
6
|
+
}
|
|
7
|
+
.root:where(:not(.link, .compact)) {
|
|
8
|
+
min-height: var(--button-min-height);
|
|
9
|
+
}
|
|
10
|
+
@media (min-resolution: 1.5dppx), (min-resolution: 144dpi) {
|
|
11
|
+
.root {
|
|
12
|
+
--translate-distance: 2px;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
.root[disabled]:not(.loading) {
|
|
16
|
+
opacity: var(--opacity-40);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.root.pressed {
|
|
20
|
+
color: var(--button-hover-color);
|
|
21
|
+
background-color: var(--button-hover-bg);
|
|
22
|
+
border-color: var(--button-hover-border-color);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.primary {
|
|
26
|
+
--button-color: var(--lt-ui-button-primary-color, var(--text-invert));
|
|
27
|
+
--button-bg: var(--lt-ui-button-primary-bg, var(--control-primary));
|
|
28
|
+
--button-hover-bg: var(--lt-ui-button-primary-hover-bg, var(--control-hover-primary));
|
|
29
|
+
}
|
|
30
|
+
.primary.shadow {
|
|
31
|
+
box-shadow: var(--box-shadow-m);
|
|
32
|
+
}
|
|
33
|
+
@media (hover: hover) and (min-width: 768px) {
|
|
34
|
+
.primary.shadow:hover {
|
|
35
|
+
background-color: var(--control-primary);
|
|
36
|
+
box-shadow: var(--box-shadow-s);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
.primary.shadow:active {
|
|
40
|
+
background-color: var(--control-primary);
|
|
41
|
+
box-shadow: var(--box-shadow-s);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.secondary {
|
|
45
|
+
--button-color: var(--text-primary);
|
|
46
|
+
--button-bg: var(--lt-ui-button-secondary-bg, var(--control-minor));
|
|
47
|
+
--button-hover-bg: var(--lt-ui-button-secondary-hover-bg, var(--control-hover-minor));
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.accent {
|
|
51
|
+
--button-color: var(--lt-ui-button-accent-color, var(--text-on-accent));
|
|
52
|
+
--button-bg: var(--lt-ui-button-accent-bg, var(--control-accent));
|
|
53
|
+
--button-hover-bg: var(--lt-ui-button-accent-hover-bg, var(--control-hover-accent));
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.danger {
|
|
57
|
+
--button-color: var(--text-invert);
|
|
58
|
+
--button-bg: var(--lt-ui-button-danger-bg, var(--attention-primary));
|
|
59
|
+
--button-hover-bg: var(--lt-ui-button-danger-hover-bg, var(--attention-dark));
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.outline {
|
|
63
|
+
--button-color: var(--text-primary);
|
|
64
|
+
--button-border-color: var(--control-secondary);
|
|
65
|
+
--button-hover-border-color: var(--control-hover-secondary);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.ghost {
|
|
69
|
+
--button-color: var(--text-primary);
|
|
70
|
+
--button-hover-bg: var(--control-minor);
|
|
71
|
+
}
|
|
72
|
+
.ghost[disabled] {
|
|
73
|
+
--button-bg: var(--control-minor);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.danger-ghost {
|
|
77
|
+
--button-color: var(--attention-dark);
|
|
78
|
+
--button-hover-bg: var(--attention-light);
|
|
79
|
+
}
|
|
80
|
+
.danger-ghost[disabled] {
|
|
81
|
+
--button-bg: var(--attention-light);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.s {
|
|
85
|
+
--button-min-height: var(--control-height-s);
|
|
86
|
+
font-size: 15px;
|
|
87
|
+
font-weight: 600;
|
|
88
|
+
line-height: 1.3333333333;
|
|
89
|
+
letter-spacing: 0.2px;
|
|
90
|
+
padding: var(--space-4) 10px;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.m {
|
|
94
|
+
font-size: 15px;
|
|
95
|
+
font-weight: 600;
|
|
96
|
+
line-height: 1.3333333333;
|
|
97
|
+
letter-spacing: 0.2px;
|
|
98
|
+
padding: var(--space-8) 18px;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.l {
|
|
102
|
+
--button-min-height: var(--control-height-l);
|
|
103
|
+
font-size: 17px;
|
|
104
|
+
font-weight: 600;
|
|
105
|
+
line-height: 1.4117647059;
|
|
106
|
+
letter-spacing: 0.2px;
|
|
107
|
+
padding: 10px 22px;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.wide {
|
|
111
|
+
width: 100%;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.rounded {
|
|
115
|
+
--button-border-radius: var(--rounding-circular);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.square {
|
|
119
|
+
padding: 0;
|
|
120
|
+
line-height: 0;
|
|
121
|
+
}
|
|
122
|
+
.square.s {
|
|
123
|
+
width: 32px;
|
|
124
|
+
height: 32px;
|
|
125
|
+
}
|
|
126
|
+
.square.m {
|
|
127
|
+
width: 40px;
|
|
128
|
+
height: 40px;
|
|
129
|
+
}
|
|
130
|
+
.square.l {
|
|
131
|
+
width: 48px;
|
|
132
|
+
height: 48px;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.compact {
|
|
136
|
+
--button-border-width: 0;
|
|
137
|
+
min-inline-size: var(--target-size-min);
|
|
138
|
+
min-block-size: var(--target-size-min);
|
|
139
|
+
padding: 0;
|
|
140
|
+
line-height: 0;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.content {
|
|
144
|
+
z-index: 0;
|
|
145
|
+
display: inherit;
|
|
146
|
+
flex-direction: inherit;
|
|
147
|
+
align-items: inherit;
|
|
148
|
+
justify-content: inherit;
|
|
149
|
+
width: 100%;
|
|
150
|
+
min-width: 0;
|
|
151
|
+
overflow-wrap: anywhere;
|
|
152
|
+
white-space: normal;
|
|
153
|
+
transition: transform 0.2s ease-out;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.root:active .content {
|
|
157
|
+
transform: translateY(var(--translate-distance));
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.composite .content {
|
|
161
|
+
display: grid;
|
|
162
|
+
grid-template-columns: repeat(2, auto);
|
|
163
|
+
justify-content: space-between;
|
|
164
|
+
}
|
|
165
|
+
.composite.s .content {
|
|
166
|
+
column-gap: var(--space-24);
|
|
167
|
+
}
|
|
168
|
+
.composite.m .content {
|
|
169
|
+
column-gap: var(--space-40);
|
|
170
|
+
}
|
|
171
|
+
.composite.l .content {
|
|
172
|
+
column-gap: var(--space-48);
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.loading .content {
|
|
176
|
+
visibility: hidden;
|
|
177
|
+
}
|
|
178
|
+
.loading.l .loader {
|
|
179
|
+
transform: scale(0.7);
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.loader {
|
|
183
|
+
position: absolute;
|
|
184
|
+
color: var(--button-color);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.iconLeft {
|
|
188
|
+
margin-inline-end: var(--space-4);
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.iconRight {
|
|
192
|
+
margin-inline-start: var(--space-4);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
.link {
|
|
196
|
+
--button-border-width: 0;
|
|
197
|
+
--link-underline: var(--control-accent);
|
|
198
|
+
--link-underline-visited: var(--palette-purple-primary);
|
|
199
|
+
padding: 0;
|
|
200
|
+
text-decoration-line: underline;
|
|
201
|
+
text-decoration-thickness: 2px;
|
|
202
|
+
text-decoration-color: color-mix(in sRGB, var(--link-underline) 60%, transparent);
|
|
203
|
+
text-underline-offset: 2px;
|
|
204
|
+
transition: text-decoration-color 0.3s ease, text-decoration-thickness 0.3s ease;
|
|
205
|
+
}
|
|
206
|
+
.link:where(*) {
|
|
207
|
+
--button-color: var(--text-primary);
|
|
208
|
+
--button-hover-color: var(--text-primary);
|
|
209
|
+
}
|
|
210
|
+
.link:visited {
|
|
211
|
+
text-decoration-color: color-mix(in sRGB, var(--link-underline-visited) 60%, transparent);
|
|
212
|
+
}
|
|
213
|
+
@media (hover: hover) and (min-width: 768px) {
|
|
214
|
+
.link:hover {
|
|
215
|
+
text-decoration-thickness: 3px;
|
|
216
|
+
text-decoration-color: var(--link-underline);
|
|
217
|
+
}
|
|
218
|
+
.link:hover:visited {
|
|
219
|
+
text-decoration-color: var(--link-underline-visited);
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
.link:active {
|
|
223
|
+
text-decoration-thickness: 3px;
|
|
224
|
+
text-decoration-color: var(--link-underline);
|
|
225
|
+
}
|
|
226
|
+
.link:active:visited {
|
|
227
|
+
text-decoration-color: var(--link-underline-visited);
|
|
228
|
+
}
|
|
229
|
+
.link:focus-visible {
|
|
230
|
+
text-decoration-thickness: 3px;
|
|
231
|
+
text-decoration-color: var(--link-underline);
|
|
232
|
+
}
|
|
233
|
+
.link.s {
|
|
234
|
+
font-size: 13px;
|
|
235
|
+
font-weight: 400;
|
|
236
|
+
line-height: 1.2307692308;
|
|
237
|
+
letter-spacing: 0.25px;
|
|
238
|
+
}
|
|
239
|
+
.link.m {
|
|
240
|
+
font-size: 15px;
|
|
241
|
+
font-weight: 400;
|
|
242
|
+
line-height: 1.3333333333;
|
|
243
|
+
letter-spacing: 0.2px;
|
|
244
|
+
}
|
|
245
|
+
.link.l {
|
|
246
|
+
font-size: 17px;
|
|
247
|
+
font-weight: 400;
|
|
248
|
+
line-height: 1.4117647059;
|
|
249
|
+
letter-spacing: 0.2px;
|
|
250
|
+
}
|
|
251
|
+
@media (prefers-reduced-motion: reduce) {
|
|
252
|
+
.link {
|
|
253
|
+
transition: none;
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
.link-strong.s {
|
|
258
|
+
font-size: 13px;
|
|
259
|
+
font-weight: 600;
|
|
260
|
+
line-height: 1.2307692308;
|
|
261
|
+
letter-spacing: 0.25px;
|
|
262
|
+
}
|
|
263
|
+
.link-strong.m {
|
|
264
|
+
font-size: 15px;
|
|
265
|
+
font-weight: 600;
|
|
266
|
+
line-height: 1.3333333333;
|
|
267
|
+
letter-spacing: 0.2px;
|
|
268
|
+
}
|
|
269
|
+
.link-strong.l {
|
|
270
|
+
font-size: 17px;
|
|
271
|
+
font-weight: 600;
|
|
272
|
+
line-height: 1.4117647059;
|
|
273
|
+
letter-spacing: 0.2px;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
.link-secondary {
|
|
277
|
+
--button-color: var(--text-secondary);
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.link-minor {
|
|
281
|
+
--button-color: var(--text-minor);
|
|
282
|
+
--button-hover-color: var(--text-primary);
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
.link.square,
|
|
286
|
+
.link.compact {
|
|
287
|
+
line-height: 0;
|
|
288
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.useButton = useButton;
|
|
8
|
+
const clsx_1 = __importDefault(require("clsx"));
|
|
9
|
+
const styles_module_scss_1 = __importDefault(require("./styles.module.css"));
|
|
10
|
+
const ICON_SIZES = { s: 20, m: 20, l: 24 };
|
|
11
|
+
const COMPACT_ICON_SIZES = { s: 16, m: 20, l: 24 };
|
|
12
|
+
const LINK_ICON_SIZES = { s: 16, m: 20, l: 24 };
|
|
13
|
+
/**
|
|
14
|
+
* Что нужно кнопке для отрисовки: классы, размер иконок, признаки вида. Разметка — в `Button`.
|
|
15
|
+
* `shadow` — это `primary` на инвертированном фоне с тенью.
|
|
16
|
+
*/
|
|
17
|
+
function useButton({ variant, size, wide, rounded, loading, pressed, iconOnly, compact, composite, className, }) {
|
|
18
|
+
const shadow = variant === 'shadow';
|
|
19
|
+
const link = variant.startsWith('link');
|
|
20
|
+
const usedVariant = shadow ? 'primary' : variant;
|
|
21
|
+
const compactIcon = iconOnly && compact;
|
|
22
|
+
let iconSize = ICON_SIZES[size];
|
|
23
|
+
if (link)
|
|
24
|
+
iconSize = LINK_ICON_SIZES[size];
|
|
25
|
+
else if (compactIcon)
|
|
26
|
+
iconSize = COMPACT_ICON_SIZES[size];
|
|
27
|
+
return {
|
|
28
|
+
iconSize,
|
|
29
|
+
className: (0, clsx_1.default)(styles_module_scss_1.default.root, styles_module_scss_1.default[usedVariant], styles_module_scss_1.default[size], {
|
|
30
|
+
[styles_module_scss_1.default.link]: link,
|
|
31
|
+
[styles_module_scss_1.default.shadow]: shadow,
|
|
32
|
+
[styles_module_scss_1.default.wide]: wide,
|
|
33
|
+
[styles_module_scss_1.default.rounded]: rounded,
|
|
34
|
+
[styles_module_scss_1.default.square]: iconOnly && !compact,
|
|
35
|
+
[styles_module_scss_1.default.compact]: compactIcon,
|
|
36
|
+
[styles_module_scss_1.default.composite]: composite,
|
|
37
|
+
[styles_module_scss_1.default.loading]: loading,
|
|
38
|
+
[styles_module_scss_1.default.pressed]: pressed,
|
|
39
|
+
}, className),
|
|
40
|
+
};
|
|
41
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isDayAvailable = isDayAvailable;
|
|
4
|
+
exports.isUnitAvailable = isUnitAvailable;
|
|
5
|
+
exports.isDateAvailable = isDateAvailable;
|
|
6
|
+
const date_1 = require("../_internal/date");
|
|
7
|
+
function isDayAvailable(date, constraints) {
|
|
8
|
+
const { minDate, maxDate, disabledWeekDays, isDateDisabled } = constraints;
|
|
9
|
+
if (minDate && (0, date_1.isBeforeDay)(date, minDate))
|
|
10
|
+
return false;
|
|
11
|
+
if (maxDate && (0, date_1.isAfterDay)(date, maxDate))
|
|
12
|
+
return false;
|
|
13
|
+
if (disabledWeekDays === null || disabledWeekDays === void 0 ? void 0 : disabledWeekDays.includes((0, date_1.getIsoWeekday)(date)))
|
|
14
|
+
return false;
|
|
15
|
+
return !(isDateDisabled === null || isDateDisabled === void 0 ? void 0 : isDateDisabled(date));
|
|
16
|
+
}
|
|
17
|
+
/** Месяц или год доступен, если он хотя бы частично попадает между `minDate` и `maxDate` */
|
|
18
|
+
function isUnitAvailable(date, unit, constraints) {
|
|
19
|
+
const { minDate, maxDate } = constraints;
|
|
20
|
+
const start = unit === 'month' ? (0, date_1.startOfMonth)(date) : new Date(date.getFullYear(), 0, 1);
|
|
21
|
+
const end = unit === 'month'
|
|
22
|
+
? new Date(date.getFullYear(), date.getMonth() + 1, 0)
|
|
23
|
+
: new Date(date.getFullYear(), 11, 31);
|
|
24
|
+
if (minDate && (0, date_1.isBeforeDay)(end, minDate))
|
|
25
|
+
return false;
|
|
26
|
+
if (maxDate && (0, date_1.isAfterDay)(start, maxDate))
|
|
27
|
+
return false;
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
/** Доступна ли дата на уровне выбора: день — по всем правилам, месяц и год — по границам */
|
|
31
|
+
function isDateAvailable(date, view, constraints) {
|
|
32
|
+
if (view === 'day')
|
|
33
|
+
return isDayAvailable(date, constraints);
|
|
34
|
+
return isUnitAvailable(date, view, constraints);
|
|
35
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.CalendarHeader = CalendarHeader;
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const clsx_1 = __importDefault(require("clsx"));
|
|
9
|
+
const date_1 = require("../_internal/date");
|
|
10
|
+
const button_1 = require("../button");
|
|
11
|
+
const icon_1 = require("../icon");
|
|
12
|
+
const icons_1 = require("../icons");
|
|
13
|
+
const typography_1 = require("../typography");
|
|
14
|
+
const styles_module_scss_1 = __importDefault(require("./styles.module.css"));
|
|
15
|
+
function getLabel(view, month, decade, locale) {
|
|
16
|
+
if (view === 'year')
|
|
17
|
+
return `${decade}–${decade + 9}`;
|
|
18
|
+
if (view === 'month')
|
|
19
|
+
return String(month.getFullYear());
|
|
20
|
+
return (0, date_1.formatMonthLabel)(month, locale);
|
|
21
|
+
}
|
|
22
|
+
/** Шапка календаря: стрелки и подпись, по нажатию на которую открывается уровень выше */
|
|
23
|
+
function CalendarHeader({ vm, labels, size, month, id, showPrevious, showNext, interactive, classNames, }) {
|
|
24
|
+
const label = ((0, jsx_runtime_1.jsx)(typography_1.Typography, { variant: "body-s-strong", as: "span", children: getLabel(vm.view, month, vm.decade, vm.locale) }));
|
|
25
|
+
const buttonSize = size === 's' ? 's' : 'm';
|
|
26
|
+
// Стрелки влево/вправо ходят по кнопкам шапки по кругу, вверх/вниз возвращают в сетку
|
|
27
|
+
const onKeyDown = (event) => {
|
|
28
|
+
if (event.altKey || event.ctrlKey || event.metaKey)
|
|
29
|
+
return;
|
|
30
|
+
if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {
|
|
31
|
+
event.preventDefault();
|
|
32
|
+
vm.focusGrid();
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
if (event.key !== 'ArrowLeft' && event.key !== 'ArrowRight')
|
|
36
|
+
return;
|
|
37
|
+
const buttons = Array.from(event.currentTarget.querySelectorAll('button:not(:disabled)'));
|
|
38
|
+
const index = buttons.indexOf(event.target);
|
|
39
|
+
if (index === -1 || buttons.length < 2)
|
|
40
|
+
return;
|
|
41
|
+
event.preventDefault();
|
|
42
|
+
const shift = event.key === 'ArrowRight' ? 1 : -1;
|
|
43
|
+
buttons[(index + shift + buttons.length) % buttons.length].focus();
|
|
44
|
+
};
|
|
45
|
+
return ((0, jsx_runtime_1.jsxs)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.header, classNames.header), onKeyDown: onKeyDown, "data-calendar-header": true, children: [(0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.headerSide, children: showPrevious && ((0, jsx_runtime_1.jsx)(button_1.Button, { iconOnly: true, rounded: true, variant: "ghost", size: buttonSize, disabled: !vm.canGoPrevious, "aria-label": labels.previous[vm.view], onClick: vm.goPrevious, "data-calendar-nav": "previous", children: (0, jsx_runtime_1.jsx)(icons_1.ArrowIcon, { direction: "left" }) })) }), (0, jsx_runtime_1.jsx)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.caption, classNames.caption), id: id, "aria-live": "polite", children: interactive && vm.canGoUp ? ((0, jsx_runtime_1.jsx)(button_1.Button, { rounded: true, variant: "ghost", size: "s", onClick: vm.goUp, "aria-label": `${getLabel(vm.view, month, vm.decade, vm.locale)}. ${labels.goUp[vm.view]}`, iconRight: (0, jsx_runtime_1.jsx)(icon_1.Icon, { size: 16, children: (0, jsx_runtime_1.jsx)(icons_1.ArrowIcon, { direction: "bottom" }) }), children: label })) : ((0, jsx_runtime_1.jsx)("span", { children: label })) }), (0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.headerSide, children: showNext && ((0, jsx_runtime_1.jsx)(button_1.Button, { iconOnly: true, rounded: true, variant: "ghost", size: buttonSize, disabled: !vm.canGoNext, "aria-label": labels.next[vm.view], onClick: vm.goNext, "data-calendar-nav": "next", children: (0, jsx_runtime_1.jsx)(icons_1.ArrowIcon, { direction: "right" }) })) })] }));
|
|
46
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.Calendar = void 0;
|
|
8
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
9
|
+
const clsx_1 = __importDefault(require("clsx"));
|
|
10
|
+
const react_1 = require("react");
|
|
11
|
+
const compat_1 = require("../_internal/compat");
|
|
12
|
+
const button_1 = require("../button");
|
|
13
|
+
const hooks_1 = require("../hooks");
|
|
14
|
+
const use_locale_1 = require("../locale/use-locale");
|
|
15
|
+
const utils_1 = require("../utils");
|
|
16
|
+
const data_attributes_1 = require("../utils/data-attributes");
|
|
17
|
+
const calendar_header_1 = require("./calendar-header");
|
|
18
|
+
const day_grid_1 = require("./day-grid");
|
|
19
|
+
const labels_1 = require("./labels");
|
|
20
|
+
const picker_grid_1 = require("./picker-grid");
|
|
21
|
+
const styles_module_scss_1 = __importDefault(require("./styles.module.css"));
|
|
22
|
+
const use_calendar_1 = require("./use-calendar");
|
|
23
|
+
/**
|
|
24
|
+
* `<Calendar />` — календарь для выбора даты или диапазона: дни месяца, месяцы года и годы десятилетия.
|
|
25
|
+
* Значения — обычные `Date`; для своей разметки (ячейка таблицы, фильтр) есть хук `useCalendar`.
|
|
26
|
+
*
|
|
27
|
+
* @example ```tsx
|
|
28
|
+
* <Calendar value={date} onUpdate={setDate} minDate={new Date()} />
|
|
29
|
+
* <Calendar mode="range" numberOfMonths={2} value={range} onUpdate={setRange} />
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
32
|
+
exports.Calendar = (0, compat_1.withRef)(function Calendar(props, ref) {
|
|
33
|
+
const { presets, footer, size = 'm', fluid = false, className, classNames: classNamesProp, hideNavigation = false, labels: labelsProp, 'aria-label': ariaLabel, 'data-testid': testId = 'calendar', ...options } = props;
|
|
34
|
+
const classNames = (0, utils_1.useClassNames)('Calendar', classNamesProp);
|
|
35
|
+
const vm = (0, use_calendar_1.useCalendar)(options);
|
|
36
|
+
const { t } = (0, use_locale_1.useLocale)();
|
|
37
|
+
const labels = (0, react_1.useMemo)(() => ({ ...(0, labels_1.getDefaultLabels)(t), ...labelsProp }), [t, labelsProp]);
|
|
38
|
+
const id = (0, hooks_1.useUniqID)();
|
|
39
|
+
const mergedRef = (0, react_1.useMemo)(() => (0, utils_1.mergeRefs)([ref, vm.rootRef]), [ref, vm.rootRef]);
|
|
40
|
+
return ((0, jsx_runtime_1.jsxs)("div", { ref: mergedRef, className: (0, clsx_1.default)(styles_module_scss_1.default.calendar, styles_module_scss_1.default[size], fluid && styles_module_scss_1.default.fluid, classNames.root, className), "aria-label": ariaLabel, "data-testid": testId, ...(0, data_attributes_1.getDataAttributes)(props, 'calendar'), "data-lt-ui": "calendar", "data-view": vm.view, children: [vm.view === 'day' ? ((0, jsx_runtime_1.jsx)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.months, classNames.months), children: vm.months.map((month, index) => ((0, jsx_runtime_1.jsxs)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.month, classNames.month), children: [(0, jsx_runtime_1.jsx)(calendar_header_1.CalendarHeader, { vm: vm, labels: labels, size: size, month: month, id: `${id}-${index}`, showPrevious: !hideNavigation && index === 0, showNext: !hideNavigation && index === vm.months.length - 1, interactive: index === 0 && vm.months.length === 1, testId: testId, classNames: classNames }), (0, jsx_runtime_1.jsx)(day_grid_1.DayGrid, { vm: vm, month: month, labelledBy: `${id}-${index}`, testId: testId, classNames: classNames })] }, index))) })) : ((0, jsx_runtime_1.jsxs)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.month, classNames.month), children: [(0, jsx_runtime_1.jsx)(calendar_header_1.CalendarHeader, { vm: vm, labels: labels, size: size, month: vm.visibleMonth, id: id, showPrevious: !hideNavigation, showNext: !hideNavigation, interactive: true, testId: testId, classNames: classNames }), vm.view === 'month' ? ((0, jsx_runtime_1.jsx)(picker_grid_1.PickerGrid, { cells: vm.monthCells, label: labels.monthGrid, onSelect: vm.selectMonth, onExit: vm.focusHeader, testId: `${testId}-months`, classNames: classNames })) : ((0, jsx_runtime_1.jsx)(picker_grid_1.PickerGrid, { cells: vm.yearCells, label: labels.yearGrid, onSelect: vm.selectYear, onExit: vm.focusHeader, testId: `${testId}-years`, classNames: classNames }))] })), presets && presets.length > 0 && ((0, jsx_runtime_1.jsx)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.presets, classNames.presets), children: presets.map(preset => ((0, jsx_runtime_1.jsx)(button_1.Button, { rounded: true, size: "s", variant: "outline", onClick: () => vm.applyPreset(preset), children: preset.label }, preset.label))) })), footer && (0, jsx_runtime_1.jsx)("div", { className: (0, clsx_1.default)(styles_module_scss_1.default.footer, classNames.footer), children: footer })] }));
|
|
41
|
+
});
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.DayGrid = DayGrid;
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const clsx_1 = __importDefault(require("clsx"));
|
|
9
|
+
const react_1 = require("react");
|
|
10
|
+
const date_1 = require("../_internal/date");
|
|
11
|
+
const styles_module_scss_1 = __importDefault(require("./styles.module.css"));
|
|
12
|
+
const DayCell = (0, react_1.memo)(function DayCell({ state, label, onSelect, onHover, onFocusDay, dayClassName, }) {
|
|
13
|
+
const { date, disabled, outside } = state;
|
|
14
|
+
return ((0, jsx_runtime_1.jsx)("div", { role: "gridcell", className: styles_module_scss_1.default.cell, "aria-selected": outside ? undefined : state.selected || undefined, "aria-hidden": outside || undefined, "data-in-range": state.inRange || undefined, "data-range-start": state.rangeStart || undefined, "data-range-end": state.rangeEnd || undefined, children: (0, jsx_runtime_1.jsx)("button", { type: "button", className: (0, clsx_1.default)(styles_module_scss_1.default.day, dayClassName), tabIndex: state.focusable ? 0 : -1, disabled: disabled, "aria-label": outside ? undefined : label, "aria-current": state.today ? 'date' : undefined, "data-calendar-date": outside ? undefined : state.key, "data-today": state.today || undefined, "data-selected": state.selected || undefined, "data-outside": outside || undefined, onClick: () => onSelect(date), onMouseEnter: () => onHover(date), onFocus: () => {
|
|
15
|
+
onFocusDay(date);
|
|
16
|
+
onHover(date);
|
|
17
|
+
}, children: date.getDate() }) }));
|
|
18
|
+
});
|
|
19
|
+
/** Сетка дней одного месяца: заголовки дней недели и 6 недель */
|
|
20
|
+
function DayGrid({ vm, month, labelledBy, testId, classNames }) {
|
|
21
|
+
const days = (0, date_1.getMonthGrid)(month, vm.weekStartsOn);
|
|
22
|
+
const weeks = Array.from({ length: 6 }, (_, index) => days.slice(index * 7, index * 7 + 7));
|
|
23
|
+
return ((0, jsx_runtime_1.jsxs)("div", { role: "grid", "aria-labelledby": labelledBy, className: styles_module_scss_1.default.grid, onKeyDown: vm.onDayKeyDown, onMouseLeave: () => vm.hoverDay(null), children: [(0, jsx_runtime_1.jsx)("div", { role: "row", className: styles_module_scss_1.default.weekdays, children: vm.weekdayNames.map(name => ((0, jsx_runtime_1.jsx)("div", { role: "columnheader", className: (0, clsx_1.default)(styles_module_scss_1.default.weekday, classNames.weekday), children: name }, name))) }), weeks.map(week => ((0, jsx_runtime_1.jsx)("div", { role: "row", className: styles_module_scss_1.default.week, children: week.map(date => {
|
|
24
|
+
const state = vm.getDayState(date, month);
|
|
25
|
+
return ((0, jsx_runtime_1.jsx)(DayCell, { state: state, label: (0, date_1.formatFullDate)(date, vm.locale), onSelect: vm.selectDay, onHover: vm.hoverDay, onFocusDay: vm.focusDay, testId: testId, dayClassName: classNames.day }, state.key));
|
|
26
|
+
}) }, week[0].getTime())))] }));
|
|
27
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isDateAvailable = exports.isUnitAvailable = exports.isDayAvailable = exports.useCalendar = exports.Calendar = void 0;
|
|
4
|
+
var calendar_1 = require("./calendar");
|
|
5
|
+
Object.defineProperty(exports, "Calendar", { enumerable: true, get: function () { return calendar_1.Calendar; } });
|
|
6
|
+
var use_calendar_1 = require("./use-calendar");
|
|
7
|
+
Object.defineProperty(exports, "useCalendar", { enumerable: true, get: function () { return use_calendar_1.useCalendar; } });
|
|
8
|
+
var availability_1 = require("./availability");
|
|
9
|
+
Object.defineProperty(exports, "isDayAvailable", { enumerable: true, get: function () { return availability_1.isDayAvailable; } });
|
|
10
|
+
Object.defineProperty(exports, "isUnitAvailable", { enumerable: true, get: function () { return availability_1.isUnitAvailable; } });
|
|
11
|
+
Object.defineProperty(exports, "isDateAvailable", { enumerable: true, get: function () { return availability_1.isDateAvailable; } });
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getDefaultLabels = void 0;
|
|
4
|
+
/** Подписи кнопок календаря на языке ближайшего `LocaleProvider` */
|
|
5
|
+
const getDefaultLabels = (t) => ({
|
|
6
|
+
previous: {
|
|
7
|
+
day: t('calendar.previous.day'),
|
|
8
|
+
month: t('calendar.previous.month'),
|
|
9
|
+
year: t('calendar.previous.year'),
|
|
10
|
+
},
|
|
11
|
+
next: { day: t('calendar.next.day'), month: t('calendar.next.month'), year: t('calendar.next.year') },
|
|
12
|
+
goUp: { day: t('calendar.goUp.day'), month: t('calendar.goUp.month'), year: t('calendar.goUp.year') },
|
|
13
|
+
monthGrid: t('calendar.monthGrid'),
|
|
14
|
+
yearGrid: t('calendar.yearGrid'),
|
|
15
|
+
});
|
|
16
|
+
exports.getDefaultLabels = getDefaultLabels;
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.PickerGrid = PickerGrid;
|
|
8
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
9
|
+
const clsx_1 = __importDefault(require("clsx"));
|
|
10
|
+
const react_1 = require("react");
|
|
11
|
+
const styles_module_scss_1 = __importDefault(require("./styles.module.css"));
|
|
12
|
+
const MOVES = {
|
|
13
|
+
ArrowLeft: () => -1,
|
|
14
|
+
ArrowRight: () => 1,
|
|
15
|
+
ArrowUp: columns => -columns,
|
|
16
|
+
ArrowDown: columns => columns,
|
|
17
|
+
};
|
|
18
|
+
/** Сетка месяцев или годов 3×4 с блуждающим фокусом: Tab входит в сетку одним остановом, стрелки двигают по ячейкам */
|
|
19
|
+
function PickerGrid({ cells, columns = 3, label, onSelect, onExit, classNames, }) {
|
|
20
|
+
const buttons = (0, react_1.useRef)([]);
|
|
21
|
+
const enabled = (index) => !cells[index].disabled;
|
|
22
|
+
const initial = () => {
|
|
23
|
+
const index = cells.findIndex(cell => cell.selected && !cell.disabled);
|
|
24
|
+
if (index !== -1)
|
|
25
|
+
return index;
|
|
26
|
+
const current = cells.findIndex(cell => cell.current && !cell.disabled && !cell.outside);
|
|
27
|
+
return current !== -1
|
|
28
|
+
? current
|
|
29
|
+
: Math.max(0, cells.findIndex(cell => !cell.disabled && !cell.outside));
|
|
30
|
+
};
|
|
31
|
+
const [active, setActive] = (0, react_1.useState)(initial);
|
|
32
|
+
const roving = enabled(active) ? active : initial();
|
|
33
|
+
const focusCell = (index) => {
|
|
34
|
+
var _a;
|
|
35
|
+
setActive(index);
|
|
36
|
+
(_a = buttons.current[index]) === null || _a === void 0 ? void 0 : _a.focus();
|
|
37
|
+
};
|
|
38
|
+
const onKeyDown = (event) => {
|
|
39
|
+
let target = roving;
|
|
40
|
+
if (event.key === 'Home')
|
|
41
|
+
target = cells.findIndex((_, index) => enabled(index));
|
|
42
|
+
else if (event.key === 'End')
|
|
43
|
+
target = cells.length - 1 - [...cells].reverse().findIndex((_, i) => enabled(cells.length - 1 - i));
|
|
44
|
+
else if (MOVES[event.key]) {
|
|
45
|
+
const step = MOVES[event.key](columns);
|
|
46
|
+
let candidate = roving + step;
|
|
47
|
+
while (candidate >= 0 && candidate < cells.length && !enabled(candidate))
|
|
48
|
+
candidate += step;
|
|
49
|
+
if (candidate >= 0 && candidate < cells.length)
|
|
50
|
+
target = candidate;
|
|
51
|
+
else if (onExit && (event.key === 'ArrowUp' || event.key === 'ArrowDown')) {
|
|
52
|
+
event.preventDefault();
|
|
53
|
+
onExit();
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
event.preventDefault();
|
|
61
|
+
focusCell(target);
|
|
62
|
+
};
|
|
63
|
+
return ((0, jsx_runtime_1.jsx)("div", { role: "grid", "aria-label": label, className: (0, clsx_1.default)(styles_module_scss_1.default.picker, classNames.picker), "data-calendar-picker": true, onKeyDown: onKeyDown, children: Array.from({ length: cells.length / columns }, (_, row) => ((0, jsx_runtime_1.jsx)("div", { role: "row", className: styles_module_scss_1.default.pickerRow, children: cells.slice(row * columns, row * columns + columns).map((cell, offset) => {
|
|
64
|
+
const index = row * columns + offset;
|
|
65
|
+
return ((0, jsx_runtime_1.jsx)("div", { role: "gridcell", className: styles_module_scss_1.default.pickerCell, "aria-selected": cell.selected || undefined, "data-in-range": cell.inRange || undefined, "data-range-start": cell.rangeStart || undefined, "data-range-end": cell.rangeEnd || undefined, children: (0, jsx_runtime_1.jsx)("button", { type: "button", ref: node => {
|
|
66
|
+
buttons.current[index] = node;
|
|
67
|
+
}, className: (0, clsx_1.default)(styles_module_scss_1.default.pickerButton, classNames.pickerButton), tabIndex: index === roving ? 0 : -1, disabled: cell.disabled, "aria-current": cell.current ? 'date' : undefined, "data-selected": cell.selected || undefined, "data-current": cell.current || undefined, "data-outside": cell.outside || undefined, onClick: () => onSelect(cell.key), onFocus: () => setActive(index), children: cell.label }) }, cell.key));
|
|
68
|
+
}) }, row))) }));
|
|
69
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.clampToBounds = void 0;
|
|
4
|
+
exports.getSelectionView = getSelectionView;
|
|
5
|
+
exports.isSameUnit = isSameUnit;
|
|
6
|
+
exports.toUnitStart = toUnitStart;
|
|
7
|
+
exports.pickRangeBoundary = pickRangeBoundary;
|
|
8
|
+
exports.getVisibleRange = getVisibleRange;
|
|
9
|
+
exports.isInsideRange = isInsideRange;
|
|
10
|
+
const date_1 = require("../_internal/date");
|
|
11
|
+
const ORDER = ['day', 'month', 'year'];
|
|
12
|
+
/** Самый точный из доступных уровней — на нём выбор фиксирует значение */
|
|
13
|
+
function getSelectionView(views) {
|
|
14
|
+
var _a;
|
|
15
|
+
return (_a = ORDER.find(view => views.includes(view))) !== null && _a !== void 0 ? _a : 'day';
|
|
16
|
+
}
|
|
17
|
+
/** Сравнение значений на уровне: два дня — один день, два месяца — один месяц и так далее */
|
|
18
|
+
function isSameUnit(a, b, view) {
|
|
19
|
+
if (view === 'year')
|
|
20
|
+
return (0, date_1.isSameYear)(a, b);
|
|
21
|
+
if (view === 'month')
|
|
22
|
+
return (0, date_1.isSameMonth)(a, b);
|
|
23
|
+
return (0, date_1.isSameDay)(a, b);
|
|
24
|
+
}
|
|
25
|
+
/** Начало выбранной единицы: месяц — первое число, год — 1 января; день остаётся как есть */
|
|
26
|
+
function toUnitStart(date, view) {
|
|
27
|
+
if (view === 'year')
|
|
28
|
+
return (0, date_1.startOfYear)(date);
|
|
29
|
+
if (view === 'month')
|
|
30
|
+
return (0, date_1.startOfMonth)(date);
|
|
31
|
+
return date;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Новое значение диапазона после клика. Начало ещё не выбрано или диапазон уже собран — начинаем заново;
|
|
35
|
+
* иначе клик задаёт конец, а границы упорядочиваются.
|
|
36
|
+
*/
|
|
37
|
+
function pickRangeBoundary(current, picked, view = 'day') {
|
|
38
|
+
const [start, end] = current;
|
|
39
|
+
if (!start || end)
|
|
40
|
+
return [picked, null];
|
|
41
|
+
const startsFirst = (0, date_1.compareDays)(toUnitStart(picked, view), toUnitStart(start, view)) >= 0;
|
|
42
|
+
return startsFirst ? [start, picked] : [picked, start];
|
|
43
|
+
}
|
|
44
|
+
/** Диапазон для подсветки: выбранный или предварительный от начала до курсора */
|
|
45
|
+
function getVisibleRange(value, hovered) {
|
|
46
|
+
const [start, end] = value;
|
|
47
|
+
if (start && end)
|
|
48
|
+
return [start, end];
|
|
49
|
+
if (start && hovered) {
|
|
50
|
+
return (0, date_1.compareDays)(hovered, start) >= 0 ? [start, hovered] : [hovered, start];
|
|
51
|
+
}
|
|
52
|
+
return null;
|
|
53
|
+
}
|
|
54
|
+
function isInsideRange(date, range, view = 'day') {
|
|
55
|
+
if (!range)
|
|
56
|
+
return false;
|
|
57
|
+
return (0, date_1.isDayBetween)(toUnitStart(date, view), toUnitStart(range[0], view), toUnitStart(range[1], view));
|
|
58
|
+
}
|
|
59
|
+
exports.clampToBounds = date_1.clampDay;
|