impact-nova 2.6.0-alpha.0 → 2.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +25 -27
- package/dist/components/data/ag-grid-react/ag-grid.types.d.ts +3 -28
- package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.d.ts +3 -0
- package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.js +38 -31
- package/dist/components/data/ag-grid-react/cell-renderers/input-display-renderer.d.ts +1 -1
- package/dist/components/data/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.js +65 -75
- package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.d.ts +1 -1
- package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.js +54 -54
- package/dist/components/data/ag-grid-react/headers/components/date-filter-picker.d.ts +1 -1
- package/dist/components/data/ag-grid-react/headers/components/header-info.d.ts +9 -3
- package/dist/components/data/ag-grid-react/headers/components/header-info.js +69 -61
- package/dist/components/data/ag-grid-react/headers/components/info-modal.js +8 -8
- package/dist/components/data/ag-grid-react/headers/header-search-input.js +119 -122
- package/dist/components/data/ag-grid-react/headers/utils/date-utils.d.ts +1 -2
- package/dist/components/data/ag-grid-react/headers/utils/date-utils.js +20 -25
- package/dist/components/data/ag-grid-react/headers/utils/filter-utils.d.ts +1 -1
- package/dist/components/data/ag-grid-react/index.d.ts +1 -1
- package/dist/components/data/ag-grid-react/index.js +254 -481
- package/dist/components/data/ag-grid-react/theme.js +2 -6
- package/dist/components/data/ag-grid-react/value-formatter.types.d.ts +0 -4
- package/dist/components/data/ag-grid-react/value-formatters.d.ts +19 -0
- package/dist/components/data/ag-grid-react/value-formatters.js +90 -88
- package/dist/components/data/data-table/build-column-tree-from-grid.d.ts +2 -0
- package/dist/components/data/data-table/build-column-tree-from-grid.js +64 -58
- package/dist/components/data/data-table/column-picker-authority.d.ts +35 -0
- package/dist/components/data/data-table/column-picker-authority.js +118 -0
- package/dist/components/data/data-table/column-picker-drop-validation.d.ts +7 -0
- package/dist/components/data/data-table/column-picker-drop-validation.js +37 -0
- package/dist/components/data/data-table/column-savability.d.ts +3 -0
- package/dist/components/data/data-table/column-savability.js +10 -0
- package/dist/components/data/data-table/data-table-column-apply.d.ts +2 -0
- package/dist/components/data/data-table/data-table-column-apply.js +84 -73
- package/dist/components/data/data-table/data-table-column-def-pin.js +31 -34
- package/dist/components/data/data-table/data-table-column-list-tree-apply.d.ts +10 -0
- package/dist/components/data/data-table/data-table-column-list-tree-apply.js +79 -0
- package/dist/components/data/data-table/data-table-column-list.js +122 -64
- package/dist/components/data/data-table/data-table-column-tree-cache.d.ts +12 -6
- package/dist/components/data/data-table/data-table-column-tree-cache.js +250 -131
- package/dist/components/data/data-table/data-table-context.js +5 -5
- package/dist/components/data/data-table/data-table-flat-column-virtual-rows.d.ts +27 -0
- package/dist/components/data/data-table/data-table-flat-column-virtual-rows.js +196 -0
- package/dist/components/data/data-table/data-table-picker-column-eligibility.d.ts +1 -0
- package/dist/components/data/data-table/data-table-picker-column-eligibility.js +7 -0
- package/dist/components/data/data-table/data-table-sheet-context.js +1 -1
- package/dist/components/data/data-table/data-table-sheet.js +1 -2
- package/dist/components/data/data-table/index.d.ts +2 -0
- package/dist/components/data/data-table/index.js +32 -28
- package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.d.ts +5 -0
- package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.js +28 -10
- package/dist/components/data/data-table/reconcile-column-tree-from-grid.d.ts +12 -0
- package/dist/components/data/data-table/reconcile-column-tree-from-grid.js +12 -0
- package/dist/components/data/data-table/use-data-table-column-list-sync.d.ts +10 -0
- package/dist/components/data/data-table/use-data-table-column-list-sync.js +250 -196
- package/dist/components/data/nested-list/components/NestedListContent.d.ts +10 -2
- package/dist/components/data/nested-list/components/NestedListContent.js +253 -138
- package/dist/components/data/nested-list/components/SortableItem.d.ts +2 -1
- package/dist/components/data/nested-list/components/SortableItem.js +62 -60
- package/dist/components/data/nested-list/hooks/useNestedListDragDrop.d.ts +10 -20
- package/dist/components/data/nested-list/hooks/useNestedListDragDrop.js +44 -233
- package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.d.ts +24 -0
- package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.js +128 -0
- package/dist/components/data/nested-list/nested-list-constants.d.ts +4 -1
- package/dist/components/data/nested-list/nested-list-constants.js +10 -4
- package/dist/components/data/nested-list/nested-list-display-utils.d.ts +11 -0
- package/dist/components/data/nested-list/nested-list-display-utils.js +74 -0
- package/dist/components/data/nested-list/nested-list-drop-engine.d.ts +31 -0
- package/dist/components/data/nested-list/nested-list-drop-engine.js +209 -0
- package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.d.ts +26 -0
- package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.js +67 -0
- package/dist/components/data/nested-list/nested-list-item-tree-mutations.d.ts +4 -0
- package/dist/components/data/nested-list/nested-list-item-tree-mutations.js +43 -0
- package/dist/components/data/nested-list/nested-list-lazy-flat-rows.d.ts +3 -0
- package/dist/components/data/nested-list/nested-list-lazy-flat-rows.js +34 -0
- package/dist/components/data/nested-list/nested-list-row-estimates.d.ts +9 -0
- package/dist/components/data/nested-list/nested-list-row-estimates.js +14 -0
- package/dist/components/data/nested-list/nested-list-scroll-anchor.d.ts +36 -0
- package/dist/components/data/nested-list/nested-list-scroll-anchor.js +47 -0
- package/dist/components/data/nested-list/nested-list-virtual-drop.d.ts +59 -0
- package/dist/components/data/nested-list/nested-list-virtual-drop.js +341 -0
- package/dist/components/data/nested-list/nested-list.js +322 -336
- package/dist/components/data/nested-list/nested-list.types.d.ts +17 -0
- package/dist/components/data-display/calendar/calendar-available-view.d.ts +6 -2
- package/dist/components/data-display/calendar/calendar-available-view.js +18 -19
- package/dist/components/data-display/calendar/calendar-config.js +21 -22
- package/dist/components/data-display/calendar/calendar-day-button.js +21 -21
- package/dist/components/data-display/calendar/calendar-day-picker-view.js +35 -36
- package/dist/components/data-display/calendar/calendar-fiscal-labels.d.ts +3 -3
- package/dist/components/data-display/calendar/calendar-fiscal-labels.js +62 -50
- package/dist/components/data-display/calendar/calendar-quarter-utils.js +12 -12
- package/dist/components/data-display/calendar/calendar-week-utils.d.ts +6 -0
- package/dist/components/data-display/calendar/calendar-week-utils.js +33 -33
- package/dist/components/data-display/calendar/calendar-year-panes.js +68 -58
- package/dist/components/data-display/calendar/calendar-year-utils.d.ts +13 -0
- package/dist/components/data-display/calendar/calendar-year-utils.js +59 -50
- package/dist/components/data-display/calendar/calendar.js +156 -153
- package/dist/components/data-display/calendar/fiscal-period-caption-select.js +22 -23
- package/dist/components/data-display/calendar/use-calendar-i18n.d.ts +0 -1
- package/dist/components/data-display/calendar/use-calendar-i18n.js +9 -10
- package/dist/components/data-display/chart/chart.js +72 -72
- package/dist/components/data-display/chart/chart.utils.d.ts +1 -1
- package/dist/components/data-display/chart/chart.utils.js +31 -40
- package/dist/components/feedback/sheet/sheet.js +1 -1
- package/dist/components/feedback/toast/toast.d.ts +1 -1
- package/dist/components/feedback/toast/toast.variants.d.ts +1 -1
- package/dist/components/flows/filter-panel/filter-panel.d.ts +1 -1
- package/dist/components/flows/filter-panel/filter-panel.js +64 -65
- package/dist/components/flows/filter-panel/filter-panel.types.d.ts +0 -1
- package/dist/components/flows/guidance/guidance-layer.js +34 -31
- package/dist/components/flows/guidance/hooks/useGuidanceOverlayGeometry.js +29 -20
- package/dist/components/flows/guidance/renderers/announcement-renderer.d.ts +1 -1
- package/dist/components/flows/guidance/renderers/announcement-renderer.js +74 -28
- package/dist/components/flows/guidance/renderers/guidance-action-tap-icon.d.ts +5 -0
- package/dist/components/flows/guidance/renderers/guidance-action-tap-icon.js +68 -0
- package/dist/components/flows/guidance/renderers/guidance-announcement-surface.d.ts +5 -0
- package/dist/components/flows/guidance/renderers/guidance-announcement-surface.js +76 -0
- package/dist/components/flows/guidance/renderers/guidance-card-shared.d.ts +43 -2
- package/dist/components/flows/guidance/renderers/guidance-card-shared.js +322 -99
- package/dist/components/flows/guidance/renderers/guidance-renderer-shared.d.ts +3 -0
- package/dist/components/flows/guidance/renderers/guidance-renderer-shared.js +189 -148
- package/dist/components/flows/guidance/renderers/guidance-shortcut-display.d.ts +9 -0
- package/dist/components/flows/guidance/renderers/guidance-shortcut-display.js +36 -0
- package/dist/components/flows/guidance/renderers/guidance-tour-overlay.d.ts +2 -1
- package/dist/components/flows/guidance/renderers/guidance-tour-overlay.js +152 -89
- package/dist/components/forms/date-picker/date-picker.js +126 -125
- package/dist/components/forms/date-picker/date-range-picker.js +192 -191
- package/dist/components/forms/date-picker/fiscal-pass-through.d.ts +6 -6
- package/dist/components/forms/date-picker/fiscal-pass-through.js +7 -3
- package/dist/components/forms/date-picker/multi-date-picker.js +67 -66
- package/dist/components/forms/date-picker/multi-quarter-picker.js +87 -87
- package/dist/components/forms/date-picker/multi-week-picker.js +83 -82
- package/dist/components/forms/date-picker/multi-year-picker.js +81 -81
- package/dist/components/forms/date-picker/quarter-range-picker.js +84 -84
- package/dist/components/forms/date-picker/week-picker.js +175 -174
- package/dist/components/forms/date-picker/week-range-picker.js +214 -213
- package/dist/components/forms/date-picker/year-range-picker.js +79 -79
- package/dist/components/ui/local-raster-icons/rasterIcons.d.ts +0 -1
- package/dist/components/ui/local-raster-icons/rasterIcons.js +25 -27
- package/dist/form-react/Fields/ChipsField.js +49 -48
- package/dist/form-react/Fields/DateRangeField.js +25 -25
- package/dist/form-react/Fields/MonthRangeField.js +57 -57
- package/dist/form-react/Fields/MultiMonthPickerField.js +28 -26
- package/dist/form-react/Fields/MultiWeekPickerField.js +41 -38
- package/dist/form-react/Fields/MultiYearPickerField.js +45 -45
- package/dist/form-react/Fields/SelectField.js +24 -26
- package/dist/form-react/Fields/TextFieldWithBackendValidation.js +27 -26
- package/dist/form-react/Fields/WeekRangePicker.js +18 -16
- package/dist/form-react/Fields/YearPickerField.js +27 -27
- package/dist/form-react/Fields/YearRangePickerField.js +29 -29
- package/dist/form-react/fields.d.ts +3 -0
- package/dist/form-react/fields.js +35 -29
- package/dist/form-react/types/fields.types.d.ts +39 -0
- package/dist/form-react/utils/date.utils.d.ts +52 -2
- package/dist/form-react/utils/date.utils.js +198 -62
- package/dist/i18n/defaultMessages.d.ts +5 -143
- package/dist/i18n/defaultMessages.js +25 -163
- package/dist/i18n/getDateFnsLocale.d.ts +4 -5
- package/dist/i18n/getDateFnsLocale.js +16 -46
- package/dist/i18n/i18n.types.d.ts +0 -13
- package/dist/i18n/impact-nova-i18n-context.d.ts +1 -1
- package/dist/i18n/impact-nova-i18n-context.js +25 -33
- package/dist/i18n/impact-nova-i18n-defaults.js +6 -8
- package/dist/i18n/index.d.ts +1 -4
- package/dist/i18n/index.js +16 -41
- package/dist/i18n/locales/de.js +3 -141
- package/dist/i18n/locales/es.js +3 -141
- package/dist/i18n/locales/hi.js +3 -141
- package/dist/i18n/locales/kn.js +3 -141
- package/dist/impact-nova-components.css +0 -249
- package/dist/impact-nova-tokens.scss +22 -6
- package/dist/impact-nova.css +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +603 -622
- package/dist/lib/fiscal-calendar/index.d.ts +2 -2
- package/dist/lib/fiscal-calendar/index.js +26 -24
- package/dist/lib/fiscal-calendar/week-selection.d.ts +5 -0
- package/dist/lib/fiscal-calendar/week-selection.js +56 -49
- package/dist/lib/guidance/engine/guidance-engine.d.ts +9 -0
- package/dist/lib/guidance/engine/guidance-engine.js +127 -65
- package/dist/lib/guidance/engine/manifest-validator.js +37 -30
- package/dist/lib/guidance/targets/target-resolver.d.ts +1 -1
- package/dist/lib/guidance/targets/target-resolver.js +32 -30
- package/dist/lib/guidance/types/guidance.types.d.ts +41 -0
- package/dist/lib/hash/fnv1a128.d.ts +16 -0
- package/dist/lib/hash/fnv1a128.js +21 -0
- package/dist/llms/index.js +2 -26
- package/dist/llms/rules/ag-grid.js +1 -1
- package/dist/llms/rules/best-practices.js +1 -1
- package/dist/llms/rules/installation.js +1 -1
- package/dist/llms/rules/migration.js +1 -1
- package/dist/llms/rules/real-world-patterns.js +1 -1
- package/dist/llms/rules/requirements.js +1 -1
- package/dist/llms/rules/troubleshooting.js +1 -1
- package/dist/providers/app-providers.d.ts +1 -3
- package/dist/providers/app-providers.js +11 -22
- package/package.json +2 -13
- package/dist/components/data/ag-grid-react/chat/chat-capabilities.d.ts +0 -9
- package/dist/components/data/ag-grid-react/chat/chat-capabilities.js +0 -22
- package/dist/components/data/ag-grid-react/chat/chat-column.d.ts +0 -20
- package/dist/components/data/ag-grid-react/chat/chat-column.js +0 -81
- package/dist/components/data/ag-grid-react/chat/chat-composer.d.ts +0 -10
- package/dist/components/data/ag-grid-react/chat/chat-composer.js +0 -352
- package/dist/components/data/ag-grid-react/chat/chat-constants.d.ts +0 -17
- package/dist/components/data/ag-grid-react/chat/chat-constants.js +0 -22
- package/dist/components/data/ag-grid-react/chat/chat-format.d.ts +0 -41
- package/dist/components/data/ag-grid-react/chat/chat-format.js +0 -94
- package/dist/components/data/ag-grid-react/chat/chat-host.d.ts +0 -10
- package/dist/components/data/ag-grid-react/chat/chat-host.js +0 -651
- package/dist/components/data/ag-grid-react/chat/chat-host.types.d.ts +0 -13
- package/dist/components/data/ag-grid-react/chat/chat-html.d.ts +0 -2
- package/dist/components/data/ag-grid-react/chat/chat-html.js +0 -40
- package/dist/components/data/ag-grid-react/chat/chat-identity.d.ts +0 -13
- package/dist/components/data/ag-grid-react/chat/chat-identity.js +0 -24
- package/dist/components/data/ag-grid-react/chat/chat-menu.d.ts +0 -13
- package/dist/components/data/ag-grid-react/chat/chat-menu.js +0 -15
- package/dist/components/data/ag-grid-react/chat/chat-notify.d.ts +0 -17
- package/dist/components/data/ag-grid-react/chat/chat-notify.js +0 -124
- package/dist/components/data/ag-grid-react/chat/chat-persist.d.ts +0 -13
- package/dist/components/data/ag-grid-react/chat/chat-persist.js +0 -34
- package/dist/components/data/ag-grid-react/chat/chat-priority.d.ts +0 -13
- package/dist/components/data/ag-grid-react/chat/chat-priority.js +0 -79
- package/dist/components/data/ag-grid-react/chat/chat-summaries.d.ts +0 -2
- package/dist/components/data/ag-grid-react/chat/chat-summaries.js +0 -24
- package/dist/components/data/ag-grid-react/chat/chat-thread-ui.d.ts +0 -72
- package/dist/components/data/ag-grid-react/chat/chat-thread-ui.js +0 -713
- package/dist/components/data/ag-grid-react/chat/chat-toggle.d.ts +0 -6
- package/dist/components/data/ag-grid-react/chat/chat-toggle.js +0 -25
- package/dist/components/data/ag-grid-react/chat/chat-ui-actions.d.ts +0 -13
- package/dist/components/data/ag-grid-react/chat/chat-ui-actions.js +0 -26
- package/dist/components/data/ag-grid-react/chat/chat-window.d.ts +0 -14
- package/dist/components/data/ag-grid-react/chat/chat-window.js +0 -82
- package/dist/components/data/ag-grid-react/chat/chat-workspace.d.ts +0 -91
- package/dist/components/data/ag-grid-react/chat/chat-workspace.js +0 -555
- package/dist/components/data/ag-grid-react/chat/chat.types.d.ts +0 -319
- package/dist/components/data/ag-grid-react/chat/index.d.ts +0 -6
- package/dist/components/data/ag-grid-react/chat/index.js +0 -24
- package/dist/components/data/ag-grid-react/chat.story-data.d.ts +0 -34
- package/dist/components/data/ag-grid-react/chat.story-sources.d.ts +0 -4
- package/dist/components/data/ag-grid-react/comments/assets/comments-no-results.png.js +0 -4
- package/dist/components/data/ag-grid-react/comments/comment-mode-toggle.d.ts +0 -6
- package/dist/components/data/ag-grid-react/comments/comment-mode-toggle.js +0 -29
- package/dist/components/data/ag-grid-react/comments/comments-actions-menu.d.ts +0 -8
- package/dist/components/data/ag-grid-react/comments/comments-actions-menu.js +0 -18
- package/dist/components/data/ag-grid-react/comments/comments-ag-grid-presence.d.ts +0 -18
- package/dist/components/data/ag-grid-react/comments/comments-ag-grid-presence.js +0 -16
- package/dist/components/data/ag-grid-react/comments/comments-capabilities.d.ts +0 -11
- package/dist/components/data/ag-grid-react/comments/comments-capabilities.js +0 -26
- package/dist/components/data/ag-grid-react/comments/comments-constants.d.ts +0 -12
- package/dist/components/data/ag-grid-react/comments/comments-constants.js +0 -21
- package/dist/components/data/ag-grid-react/comments/comments-format.d.ts +0 -20
- package/dist/components/data/ag-grid-react/comments/comments-format.js +0 -49
- package/dist/components/data/ag-grid-react/comments/comments-generation.d.ts +0 -14
- package/dist/components/data/ag-grid-react/comments/comments-generation.js +0 -18
- package/dist/components/data/ag-grid-react/comments/comments-host.d.ts +0 -10
- package/dist/components/data/ag-grid-react/comments/comments-host.js +0 -343
- package/dist/components/data/ag-grid-react/comments/comments-host.types.d.ts +0 -18
- package/dist/components/data/ag-grid-react/comments/comments-identity.d.ts +0 -7
- package/dist/components/data/ag-grid-react/comments/comments-identity.js +0 -20
- package/dist/components/data/ag-grid-react/comments/comments-menu.d.ts +0 -29
- package/dist/components/data/ag-grid-react/comments/comments-menu.js +0 -35
- package/dist/components/data/ag-grid-react/comments/comments-overlay-anchor.d.ts +0 -22
- package/dist/components/data/ag-grid-react/comments/comments-overlay-anchor.js +0 -98
- package/dist/components/data/ag-grid-react/comments/comments-overlay.d.ts +0 -21
- package/dist/components/data/ag-grid-react/comments/comments-overlay.js +0 -406
- package/dist/components/data/ag-grid-react/comments/comments-panel.d.ts +0 -9
- package/dist/components/data/ag-grid-react/comments/comments-panel.js +0 -272
- package/dist/components/data/ag-grid-react/comments/comments-persist.d.ts +0 -11
- package/dist/components/data/ag-grid-react/comments/comments-persist.js +0 -19
- package/dist/components/data/ag-grid-react/comments/comments-reveal.d.ts +0 -11
- package/dist/components/data/ag-grid-react/comments/comments-reveal.js +0 -31
- package/dist/components/data/ag-grid-react/comments/comments-ui-actions.d.ts +0 -18
- package/dist/components/data/ag-grid-react/comments/comments-ui-actions.js +0 -22
- package/dist/components/data/ag-grid-react/comments/comments-window.d.ts +0 -10
- package/dist/components/data/ag-grid-react/comments/comments-window.js +0 -62
- package/dist/components/data/ag-grid-react/comments/comments.types.d.ts +0 -178
- package/dist/components/data/ag-grid-react/comments/index.d.ts +0 -5
- package/dist/components/data/ag-grid-react/comments/index.js +0 -15
- package/dist/components/data/ag-grid-react/comments-cell-renderers-showcase.d.ts +0 -25
- package/dist/components/data/ag-grid-react/comments.story-data.d.ts +0 -37
- package/dist/components/data/ag-grid-react/comments.story-sources.d.ts +0 -11
- package/dist/components/data/ag-grid-react/grid-cell-address.d.ts +0 -21
- package/dist/components/data/ag-grid-react/grid-cell-address.js +0 -21
- package/dist/components/data/ag-grid-react/grid-row-reveal.d.ts +0 -34
- package/dist/components/data/ag-grid-react/grid-row-reveal.js +0 -33
- package/dist/components/data/ag-grid-react/notes/index.d.ts +0 -2
- package/dist/components/data/ag-grid-react/notes/index.js +0 -1
- package/dist/components/data/ag-grid-react/notes/notes-ag-grid-adapter.d.ts +0 -25
- package/dist/components/data/ag-grid-react/notes/notes-ag-grid-adapter.js +0 -32
- package/dist/components/data/ag-grid-react/notes/notes-constants.d.ts +0 -2
- package/dist/components/data/ag-grid-react/notes/notes-constants.js +0 -4
- package/dist/components/data/ag-grid-react/notes/notes.types.d.ts +0 -12
- package/dist/components/data/ag-grid-react/notes.story-sources.d.ts +0 -7
- package/dist/components/data/ag-grid-react/nova-system-column.d.ts +0 -7
- package/dist/components/data/ag-grid-react/nova-system-column.js +0 -18
- package/dist/components/forms/date-picker/use-picker-i18n.d.ts +0 -6
- package/dist/components/forms/date-picker/use-picker-i18n.js +0 -11
- package/dist/components/ui/local-raster-icons/message3d.webp.js +0 -4
- package/dist/i18n/format/collator.d.ts +0 -1
- package/dist/i18n/format/collator.js +0 -7
- package/dist/i18n/format/date-pattern.d.ts +0 -5
- package/dist/i18n/format/date-pattern.js +0 -20
- package/dist/i18n/format/format-date.d.ts +0 -9
- package/dist/i18n/format/format-date.js +0 -56
- package/dist/i18n/format/format-number.d.ts +0 -20
- package/dist/i18n/format/format-number.js +0 -68
- package/dist/i18n/format/formatter-cache.d.ts +0 -9
- package/dist/i18n/format/formatter-cache.js +0 -66
- package/dist/i18n/format/index.d.ts +0 -6
- package/dist/i18n/format/parse-number.d.ts +0 -6
- package/dist/i18n/format/parse-number.js +0 -53
- package/dist/i18n/locale-config.d.ts +0 -28
- package/dist/i18n/locale-config.js +0 -32
- package/dist/i18n/week-start.d.ts +0 -6
- package/dist/i18n/week-start.js +0 -30
- package/dist/llms/rules/data-table-chat.js +0 -1
- package/dist/llms/rules/data-table-comments.js +0 -1
- package/dist/llms/rules/data-table-notes.js +0 -1
|
@@ -1,50 +1,51 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import * as
|
|
3
|
-
import { Cross as
|
|
4
|
-
import { format as
|
|
5
|
-
import { cn as
|
|
6
|
-
import { usePickerDismissActionsRef as nt, usePickerFooterDismissNudge as
|
|
7
|
-
import { useFieldChrome as
|
|
8
|
-
import { Popover as
|
|
9
|
-
import { Calendar as
|
|
1
|
+
import { jsx as h, jsxs as T } from "react/jsx-runtime";
|
|
2
|
+
import * as c from "react";
|
|
3
|
+
import { Cross as ot, CalendarMonth as rt } from "impact-nova-icons";
|
|
4
|
+
import { format as y } from "date-fns";
|
|
5
|
+
import { cn as G } from "../../../lib/utils.js";
|
|
6
|
+
import { usePickerDismissActionsRef as nt, usePickerFooterDismissNudge as st, createRangePickerOpenChangeHandler as it, parseDateInput as J, normalizeOrderedRange as lt, flashRangeReorder as at, isDateInputInvalid as ie, resolveRangeFieldBlur as V, resolveRangePickerDismissFlash as ct, handlePickerEscapeKeyDown as le, handlePickerSurfacePointerDown as ft, compareDates as Q, deferRangeInputBlur as dt, maskDateInput as ae, resolveDateInputOnBlur as O } from "./date-input-behavior.js";
|
|
7
|
+
import { useFieldChrome as pt } from "../../../lib/primitives/use-field-chrome.js";
|
|
8
|
+
import { Popover as ut, PopoverAnchor as mt, PopoverContent as gt } from "../../feedback/popover/popover.js";
|
|
9
|
+
import { Calendar as vt } from "../../data-display/calendar/calendar.js";
|
|
10
10
|
import { Tooltip as ce, TooltipTrigger as fe, TooltipContent as de } from "../../feedback/tooltip/tooltip.js";
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
11
|
+
import { useImpactNovaI18n as ht } from "../../../i18n/use-impact-nova-i18n.js";
|
|
12
|
+
import { getDateFnsLocale as yt } from "../../../i18n/getDateFnsLocale.js";
|
|
13
|
+
import { coerceDateRangeApply as Rt, coerceDateRange as Dt } from "./calendar-selection-adapters.js";
|
|
13
14
|
import { buildDateBoundsMatcher as kt } from "../../../lib/date-bounds-matcher.js";
|
|
14
15
|
import { fiscalCalendarPassThrough as xt } from "./fiscal-pass-through.js";
|
|
15
16
|
import { isDateRangeArray as I } from "../../data-display/calendar/calendar-interval-utils.js";
|
|
16
|
-
function
|
|
17
|
-
if (
|
|
18
|
-
return I(
|
|
17
|
+
function pe(i) {
|
|
18
|
+
if (i)
|
|
19
|
+
return I(i) ? i[i.length - 1] : i;
|
|
19
20
|
}
|
|
20
|
-
function
|
|
21
|
-
if (!
|
|
22
|
-
if (!
|
|
23
|
-
const
|
|
24
|
-
return !!(
|
|
21
|
+
function Ct(i, f) {
|
|
22
|
+
if (!i && !f) return !0;
|
|
23
|
+
if (!i || !f) return !1;
|
|
24
|
+
const r = !i.from && !f.from || i.from && f.from && Q(i.from, f.from) === 0, M = !i.to && !f.to || i.to && f.to && Q(i.to, f.to) === 0;
|
|
25
|
+
return !!(r && M);
|
|
25
26
|
}
|
|
26
|
-
const
|
|
27
|
+
const Pt = c.forwardRef(
|
|
27
28
|
({
|
|
28
|
-
value:
|
|
29
|
-
onChange:
|
|
30
|
-
format:
|
|
31
|
-
startPlaceholder:
|
|
32
|
-
endPlaceholder:
|
|
33
|
-
minDate:
|
|
29
|
+
value: i,
|
|
30
|
+
onChange: f,
|
|
31
|
+
format: r = "MM/dd/yyyy",
|
|
32
|
+
startPlaceholder: M,
|
|
33
|
+
endPlaceholder: ue,
|
|
34
|
+
minDate: me,
|
|
34
35
|
maxDate: ge,
|
|
35
|
-
startMonth:
|
|
36
|
-
endMonth:
|
|
36
|
+
startMonth: ve,
|
|
37
|
+
endMonth: he,
|
|
37
38
|
showFooter: g = !0,
|
|
38
|
-
weekStartsOn:
|
|
39
|
+
weekStartsOn: U,
|
|
39
40
|
disabled: d,
|
|
40
|
-
label:
|
|
41
|
-
helperText:
|
|
42
|
-
helperTextPosition:
|
|
43
|
-
prefix:
|
|
44
|
-
prefixClick:
|
|
45
|
-
isError:
|
|
46
|
-
error:
|
|
47
|
-
size:
|
|
41
|
+
label: ye,
|
|
42
|
+
helperText: Re,
|
|
43
|
+
helperTextPosition: De = "absolute",
|
|
44
|
+
prefix: bt,
|
|
45
|
+
prefixClick: It,
|
|
46
|
+
isError: ke,
|
|
47
|
+
error: xe,
|
|
48
|
+
size: W,
|
|
48
49
|
required: Ce,
|
|
49
50
|
className: Pe,
|
|
50
51
|
calendarKind: be,
|
|
@@ -58,236 +59,236 @@ const Ct = f.forwardRef(
|
|
|
58
59
|
autoNavigateToAvailable: Ae,
|
|
59
60
|
comparison: Ve,
|
|
60
61
|
onComparisonChange: Oe,
|
|
61
|
-
mode:
|
|
62
|
-
onRangesChange:
|
|
63
|
-
...
|
|
64
|
-
},
|
|
65
|
-
const {
|
|
66
|
-
label:
|
|
67
|
-
helperText:
|
|
68
|
-
helperTextPosition:
|
|
62
|
+
mode: K = "range",
|
|
63
|
+
onRangesChange: j,
|
|
64
|
+
...Me
|
|
65
|
+
}, Ke) => {
|
|
66
|
+
const { locale: X, t: b } = ht(), n = c.useMemo(() => yt(X), [X]), Y = M ?? b("datePicker.startDate"), Z = ue ?? b("datePicker.endDate"), _ = xe ?? ke, je = pt({
|
|
67
|
+
label: ye,
|
|
68
|
+
helperText: Re,
|
|
69
|
+
helperTextPosition: De,
|
|
69
70
|
error: _,
|
|
70
71
|
required: Ce,
|
|
71
72
|
disabled: d ?? void 0,
|
|
72
73
|
rootClassName: "w-full min-w-[240px]"
|
|
73
|
-
}),
|
|
74
|
-
|
|
75
|
-
const
|
|
76
|
-
I(
|
|
77
|
-
), [
|
|
78
|
-
I(
|
|
79
|
-
), [
|
|
80
|
-
|
|
81
|
-
const e =
|
|
82
|
-
|
|
83
|
-
}, [
|
|
84
|
-
const Je =
|
|
85
|
-
(e) =>
|
|
74
|
+
}), L = c.useRef(null), $ = c.useRef(null), F = c.useRef(null), N = c.useRef(null), q = c.useRef(null);
|
|
75
|
+
c.useImperativeHandle(Ke, () => L.current);
|
|
76
|
+
const l = pe(i), [p, m] = c.useState(!1), ee = nt(), { footerFlashKey: Le, footerFlashTarget: qe, popoverHandlers: ze } = st(g, p, ee, F), E = c.useRef(!1), [u, R] = c.useState(l), [te, B] = c.useState(
|
|
77
|
+
I(i) ? i : void 0
|
|
78
|
+
), [He, z] = c.useState(
|
|
79
|
+
I(i) ? i : void 0
|
|
80
|
+
), [v, k] = c.useState(l?.from ? y(l.from, r, { locale: n }) : ""), [D, x] = c.useState(l?.to ? y(l.to, r, { locale: n }) : ""), [Ge, w] = c.useState(l?.from || /* @__PURE__ */ new Date()), C = l?.from ? y(l.from, r, { locale: n }) : "", P = l?.to ? y(l.to, r, { locale: n }) : "";
|
|
81
|
+
c.useEffect(() => {
|
|
82
|
+
const e = pe(i);
|
|
83
|
+
k(e?.from ? y(e.from, r, { locale: n }) : ""), x(e?.to ? y(e.to, r, { locale: n }) : ""), R(e), B(I(i) ? i : void 0), z(I(i) ? i : void 0);
|
|
84
|
+
}, [i, r, n]);
|
|
85
|
+
const Je = c.useCallback(
|
|
86
|
+
(e) => it({
|
|
86
87
|
disabled: d ?? void 0,
|
|
87
88
|
showFooter: g,
|
|
88
89
|
containerRef: N,
|
|
89
|
-
popoverContentRef:
|
|
90
|
-
setOpen:
|
|
90
|
+
popoverContentRef: q,
|
|
91
|
+
setOpen: m
|
|
91
92
|
})(e),
|
|
92
93
|
[d, g]
|
|
93
|
-
),
|
|
94
|
-
|
|
95
|
-
if (
|
|
96
|
-
const e =
|
|
97
|
-
e.parsed ? w(e.parsed) :
|
|
94
|
+
), oe = c.useRef(!1);
|
|
95
|
+
c.useEffect(() => {
|
|
96
|
+
if (p && !oe.current) {
|
|
97
|
+
const e = J(v, r, n);
|
|
98
|
+
e.parsed ? w(e.parsed) : u?.from ? w(u.from) : l?.from && w(l.from);
|
|
98
99
|
}
|
|
99
|
-
|
|
100
|
-
}, [
|
|
100
|
+
oe.current = p;
|
|
101
|
+
}, [p, v, r, n, u?.from, l?.from]);
|
|
101
102
|
const Qe = (e) => {
|
|
102
103
|
if (I(e)) {
|
|
103
104
|
B(e);
|
|
104
|
-
const
|
|
105
|
-
|
|
105
|
+
const o = e[e.length - 1];
|
|
106
|
+
R(o), o?.from && k(y(o.from, r, { locale: n })), o?.to && x(y(o.to, r, { locale: n })), !g && e.every((s) => s.from && s.to) && (j?.(e), f?.(o), m(!1));
|
|
106
107
|
return;
|
|
107
108
|
}
|
|
108
|
-
const t =
|
|
109
|
-
|
|
110
|
-
}, S =
|
|
111
|
-
const
|
|
112
|
-
return
|
|
113
|
-
}, [
|
|
114
|
-
if (
|
|
115
|
-
const
|
|
116
|
-
|
|
117
|
-
const
|
|
118
|
-
|
|
109
|
+
const t = Dt(e);
|
|
110
|
+
R(t), t?.from && k(y(t.from, r, { locale: n })), t?.to && x(y(t.to, r, { locale: n })), g || t?.from && t?.to && t.from.getTime() !== t.to.getTime() && (f?.(t), m(!1));
|
|
111
|
+
}, S = c.useCallback((e, t) => {
|
|
112
|
+
const o = lt(e, t, Q);
|
|
113
|
+
return o.swapped && (o.from && k(y(o.from, r, { locale: n })), o.to && x(y(o.to, r, { locale: n })), at(N.current)), { from: o.from, to: o.to };
|
|
114
|
+
}, [r, n]), re = (e) => {
|
|
115
|
+
if (K === "multi-range") {
|
|
116
|
+
const s = I(e) ? e : te;
|
|
117
|
+
j?.(s);
|
|
118
|
+
const a = s?.[s.length - 1];
|
|
119
|
+
f?.(a), z(s), m(!1);
|
|
119
120
|
return;
|
|
120
121
|
}
|
|
121
|
-
let t = Rt(e,
|
|
122
|
+
let t = Rt(e, u);
|
|
122
123
|
t?.from && !t.to && (t = { from: t.from, to: t.from });
|
|
123
|
-
const
|
|
124
|
-
|
|
124
|
+
const o = S(t?.from, t?.to);
|
|
125
|
+
R({ from: o.from, to: o.to }), f?.({ from: o.from, to: o.to }), m(!1);
|
|
125
126
|
}, A = () => {
|
|
126
|
-
|
|
127
|
-
},
|
|
128
|
-
|
|
127
|
+
R(l), B(He), k(l?.from ? y(l.from, r, { locale: n }) : ""), x(l?.to ? y(l.to, r, { locale: n }) : ""), m(!1);
|
|
128
|
+
}, H = () => {
|
|
129
|
+
R(void 0), B(void 0), z(void 0), k(""), x(""), f?.(void 0), j?.(void 0), g || m(!1);
|
|
129
130
|
}, Ue = (e) => {
|
|
130
|
-
const t =
|
|
131
|
-
if (
|
|
132
|
-
const
|
|
133
|
-
|
|
131
|
+
const t = ae(e.target.value, r, v);
|
|
132
|
+
if (k(t), t === "") {
|
|
133
|
+
const a = { from: void 0, to: u?.to };
|
|
134
|
+
R(a), g || f?.(a);
|
|
134
135
|
return;
|
|
135
136
|
}
|
|
136
|
-
const { parsed:
|
|
137
|
-
if (
|
|
138
|
-
const
|
|
139
|
-
|
|
137
|
+
const { parsed: o, isValid: s } = J(t, r, n);
|
|
138
|
+
if (s && o) {
|
|
139
|
+
const a = { from: o, to: u?.to };
|
|
140
|
+
R(a), w(o), g || f?.(a);
|
|
140
141
|
}
|
|
141
142
|
}, We = (e) => {
|
|
142
|
-
const t =
|
|
143
|
-
if (
|
|
144
|
-
const
|
|
145
|
-
|
|
143
|
+
const t = ae(e.target.value, r, D);
|
|
144
|
+
if (x(t), t === "") {
|
|
145
|
+
const a = { from: u?.from, to: void 0 };
|
|
146
|
+
R(a), g || f?.(a);
|
|
146
147
|
return;
|
|
147
148
|
}
|
|
148
|
-
const { parsed:
|
|
149
|
-
if (
|
|
150
|
-
const
|
|
151
|
-
|
|
149
|
+
const { parsed: o, isValid: s } = J(t, r, n);
|
|
150
|
+
if (s && o) {
|
|
151
|
+
const a = { from: u?.from, to: o };
|
|
152
|
+
R(a), w(o), g || f?.(a);
|
|
152
153
|
}
|
|
153
154
|
}, ne = () => {
|
|
154
155
|
dt(
|
|
155
156
|
N,
|
|
156
|
-
|
|
157
|
+
q,
|
|
157
158
|
() => {
|
|
158
|
-
const e = V(
|
|
159
|
-
e.resetToCommitted ?
|
|
160
|
-
let
|
|
161
|
-
|
|
162
|
-
const
|
|
163
|
-
|
|
159
|
+
const e = V(v, r, C, n), t = V(D, r, P, n);
|
|
160
|
+
e.resetToCommitted ? k(C) : e.parsed && k(e.display), t.resetToCommitted ? x(P) : t.parsed && x(t.display);
|
|
161
|
+
let o = e.parsed ? e.parsed : e.resetToCommitted ? l?.from : u?.from, s = t.parsed ? t.parsed : t.resetToCommitted ? l?.to : u?.to;
|
|
162
|
+
o && s && ({ from: o, to: s } = S(o, s));
|
|
163
|
+
const a = o || s ? { from: o, to: s } : void 0;
|
|
164
|
+
R(a), g || (a ? f?.(a) : !v && !D && f?.(void 0));
|
|
164
165
|
}
|
|
165
166
|
);
|
|
166
167
|
}, Xe = () => {
|
|
167
|
-
const e = O(
|
|
168
|
-
e.resetToCommitted ?
|
|
169
|
-
let
|
|
170
|
-
|
|
171
|
-
const
|
|
172
|
-
|
|
173
|
-
},
|
|
174
|
-
if (
|
|
175
|
-
|
|
168
|
+
const e = O(v, r, C, n), t = O(D, r, P, n);
|
|
169
|
+
e.resetToCommitted ? k(C) : e.parsed && k(e.display), t.resetToCommitted ? x(P) : t.parsed && x(t.display);
|
|
170
|
+
let o = e.parsed ?? u?.from ?? l?.from, s = t.parsed ?? u?.to ?? l?.to;
|
|
171
|
+
o && s && ({ from: o, to: s } = S(o, s));
|
|
172
|
+
const a = o || s ? { from: o, to: s } : void 0;
|
|
173
|
+
a ? (R(a), f?.(a)) : !v && !D && (R(void 0), f?.(void 0));
|
|
174
|
+
}, se = () => {
|
|
175
|
+
if (p && g) {
|
|
176
|
+
re();
|
|
176
177
|
return;
|
|
177
178
|
}
|
|
178
|
-
if (!
|
|
179
|
+
if (!p) {
|
|
179
180
|
if (g) {
|
|
180
181
|
Xe();
|
|
181
182
|
return;
|
|
182
183
|
}
|
|
183
|
-
const e = O(
|
|
184
|
+
const e = O(v, r, C, n), t = O(D, r, P, n);
|
|
184
185
|
if (e.parsed || t.parsed) return;
|
|
185
|
-
E.current = !0,
|
|
186
|
+
E.current = !0, m(!0);
|
|
186
187
|
}
|
|
187
|
-
}, Ye =
|
|
188
|
-
const e = V(
|
|
189
|
-
let
|
|
190
|
-
|
|
191
|
-
const
|
|
188
|
+
}, Ye = v !== C, Ze = D !== P, _e = ie(v, r, n), $e = ie(D, r, n), Fe = c.useCallback(() => {
|
|
189
|
+
const e = V(v, r, C, n), t = V(D, r, P, n);
|
|
190
|
+
let o = e.parsed ? e.parsed : e.resetToCommitted ? l?.from : u?.from, s = t.parsed ? t.parsed : t.resetToCommitted ? l?.to : u?.to;
|
|
191
|
+
o && s && ({ from: o, to: s } = S(o, s));
|
|
192
|
+
const a = o || s ? { from: o, to: s } : void 0;
|
|
192
193
|
return ct({
|
|
193
|
-
startInput:
|
|
194
|
-
endInput:
|
|
194
|
+
startInput: v,
|
|
195
|
+
endInput: D,
|
|
195
196
|
committedStart: C,
|
|
196
197
|
committedEnd: P,
|
|
197
|
-
committedRange:
|
|
198
|
-
pendingRange:
|
|
199
|
-
computeEffectiveRange: () =>
|
|
200
|
-
rangesEqual: (et, tt) =>
|
|
198
|
+
committedRange: i,
|
|
199
|
+
pendingRange: u,
|
|
200
|
+
computeEffectiveRange: () => a,
|
|
201
|
+
rangesEqual: (et, tt) => Ct(et, tt)
|
|
201
202
|
});
|
|
202
203
|
}, [
|
|
203
|
-
|
|
204
|
-
|
|
204
|
+
v,
|
|
205
|
+
D,
|
|
205
206
|
C,
|
|
206
207
|
P,
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
208
|
+
l?.from,
|
|
209
|
+
l?.to,
|
|
210
|
+
i,
|
|
211
|
+
u,
|
|
212
|
+
r,
|
|
212
213
|
n,
|
|
213
214
|
S
|
|
214
215
|
]);
|
|
215
|
-
return
|
|
216
|
+
return c.useLayoutEffect(() => {
|
|
216
217
|
ee.current = {
|
|
217
218
|
onDismiss: A,
|
|
218
219
|
resolveFlash: Fe
|
|
219
220
|
};
|
|
220
|
-
}), /* @__PURE__ */
|
|
221
|
+
}), /* @__PURE__ */ h(
|
|
221
222
|
"div",
|
|
222
223
|
{
|
|
223
224
|
ref: F,
|
|
224
225
|
"data-component": "date-range-picker",
|
|
225
226
|
"data-disabled": d || void 0,
|
|
226
|
-
children:
|
|
227
|
-
/* @__PURE__ */ T(
|
|
228
|
-
/* @__PURE__ */
|
|
227
|
+
children: je.wrapControl(
|
|
228
|
+
/* @__PURE__ */ T(ut, { open: d ? !1 : p, onOpenChange: Je, children: [
|
|
229
|
+
/* @__PURE__ */ h(mt, { asChild: !0, children: /* @__PURE__ */ T(
|
|
229
230
|
"div",
|
|
230
231
|
{
|
|
231
232
|
ref: N,
|
|
232
|
-
"data-state":
|
|
233
|
+
"data-state": p ? "open" : "closed",
|
|
233
234
|
onPointerDown: (e) => ft({
|
|
234
235
|
disabled: d,
|
|
235
236
|
event: e,
|
|
236
|
-
onOpen: () =>
|
|
237
|
+
onOpen: () => m(!0),
|
|
237
238
|
focusField: (t) => {
|
|
238
|
-
t === "end" ? $.current?.focus() :
|
|
239
|
+
t === "end" ? $.current?.focus() : L.current?.focus();
|
|
239
240
|
}
|
|
240
241
|
}),
|
|
241
|
-
className:
|
|
242
|
+
className: G(
|
|
242
243
|
"flex w-full items-center justify-between gap-2 rounded-md border bg-canvas-elevated px-3 text-sm shadow-sm transition-colors hover:border-brand disabled:cursor-not-allowed disabled:bg-disabled-surface disabled:text-disabled-foreground disabled:border-stroke",
|
|
243
244
|
_ ? "border-destructive hover:border-destructive" : "border-field",
|
|
244
|
-
|
|
245
|
+
W === "sm" ? "h-6" : W === "md" ? "h-[28px]" : "h-8",
|
|
245
246
|
d && "pointer-events-none opacity-100 bg-disabled-surface border-stroke text-disabled-foreground hover:border-stroke",
|
|
246
247
|
"cursor-pointer",
|
|
247
248
|
Pe
|
|
248
249
|
),
|
|
249
250
|
children: [
|
|
250
251
|
/* @__PURE__ */ T("div", { className: "flex items-center gap-4 flex-1 min-w-0", children: [
|
|
251
|
-
/* @__PURE__ */
|
|
252
|
+
/* @__PURE__ */ h(
|
|
252
253
|
"input",
|
|
253
254
|
{
|
|
254
|
-
ref:
|
|
255
|
+
ref: L,
|
|
255
256
|
type: "text",
|
|
256
|
-
value:
|
|
257
|
+
value: v,
|
|
257
258
|
onChange: Ue,
|
|
258
259
|
onBlur: ne,
|
|
259
|
-
onClick: () => !d &&
|
|
260
|
+
onClick: () => !d && m(!0),
|
|
260
261
|
onKeyDown: (e) => {
|
|
261
|
-
e.key === "Enter" && !d && (e.preventDefault(),
|
|
262
|
+
e.key === "Enter" && !d && (e.preventDefault(), se()), e.key === "ArrowDown" && !p && !d && (e.preventDefault(), E.current = !0, m(!0)), e.key === "Escape" && p && le(e, { open: p, onCancel: A });
|
|
262
263
|
},
|
|
263
|
-
placeholder:
|
|
264
|
+
placeholder: p ? r : Y,
|
|
264
265
|
disabled: !!d,
|
|
265
266
|
"aria-label": Y,
|
|
266
267
|
"data-field": "start",
|
|
267
|
-
className:
|
|
268
|
+
className: G(
|
|
268
269
|
"flex-1 min-w-0 bg-transparent p-0 text-sm font-medium outline-none placeholder:font-medium placeholder:text-content-empty disabled:cursor-not-allowed disabled:opacity-50",
|
|
269
270
|
_e ? "text-destructive" : Ye ? "text-content-placeholder" : ""
|
|
270
271
|
),
|
|
271
|
-
...
|
|
272
|
+
...Me
|
|
272
273
|
}
|
|
273
274
|
),
|
|
274
|
-
/* @__PURE__ */
|
|
275
|
+
/* @__PURE__ */ h(
|
|
275
276
|
"input",
|
|
276
277
|
{
|
|
277
278
|
ref: $,
|
|
278
279
|
type: "text",
|
|
279
|
-
value:
|
|
280
|
+
value: D,
|
|
280
281
|
onChange: We,
|
|
281
282
|
onBlur: ne,
|
|
282
|
-
onClick: () => !d &&
|
|
283
|
+
onClick: () => !d && m(!0),
|
|
283
284
|
onKeyDown: (e) => {
|
|
284
|
-
e.key === "Enter" && !d && (e.preventDefault(),
|
|
285
|
+
e.key === "Enter" && !d && (e.preventDefault(), se()), e.key === "ArrowDown" && !p && !d && (e.preventDefault(), E.current = !0, m(!0)), e.key === "Escape" && p && le(e, { open: p, onCancel: A });
|
|
285
286
|
},
|
|
286
|
-
placeholder:
|
|
287
|
+
placeholder: p ? r : Z,
|
|
287
288
|
disabled: !!d,
|
|
288
289
|
"aria-label": Z,
|
|
289
290
|
"data-field": "end",
|
|
290
|
-
className:
|
|
291
|
+
className: G(
|
|
291
292
|
"flex-1 min-w-0 bg-transparent p-0 text-sm font-medium outline-none placeholder:font-medium placeholder:text-content-empty disabled:cursor-not-allowed disabled:opacity-50",
|
|
292
293
|
$e ? "text-destructive" : Ze ? "text-content-placeholder" : ""
|
|
293
294
|
)
|
|
@@ -295,68 +296,68 @@ const Ct = f.forwardRef(
|
|
|
295
296
|
)
|
|
296
297
|
] }),
|
|
297
298
|
/* @__PURE__ */ T("div", { className: "flex items-center gap-1 shrink-0", children: [
|
|
298
|
-
|
|
299
|
-
/* @__PURE__ */
|
|
299
|
+
l?.from && !d && /* @__PURE__ */ T(ce, { children: [
|
|
300
|
+
/* @__PURE__ */ h(fe, { asChild: !0, children: /* @__PURE__ */ h(
|
|
300
301
|
"button",
|
|
301
302
|
{
|
|
302
303
|
type: "button",
|
|
303
304
|
tabIndex: 0,
|
|
304
305
|
"aria-label": b("calendar.clear"),
|
|
305
306
|
onClick: (e) => {
|
|
306
|
-
e.stopPropagation(),
|
|
307
|
+
e.stopPropagation(), H();
|
|
307
308
|
},
|
|
308
309
|
onKeyDown: (e) => {
|
|
309
|
-
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), e.stopPropagation(),
|
|
310
|
+
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), e.stopPropagation(), H());
|
|
310
311
|
},
|
|
311
312
|
className: "inline-flex size-4 items-center justify-center bg-transparent border-none p-0 cursor-pointer",
|
|
312
|
-
children: /* @__PURE__ */
|
|
313
|
+
children: /* @__PURE__ */ h(ot, { className: "size-3 hover:text-content text-content-icon" })
|
|
313
314
|
}
|
|
314
315
|
) }),
|
|
315
|
-
/* @__PURE__ */
|
|
316
|
+
/* @__PURE__ */ h(de, { variant: "tertiary", side: "top", children: b("calendar.clear") })
|
|
316
317
|
] }),
|
|
317
318
|
/* @__PURE__ */ T(ce, { children: [
|
|
318
|
-
/* @__PURE__ */
|
|
319
|
-
e.stopPropagation(), d ||
|
|
319
|
+
/* @__PURE__ */ h(fe, { asChild: !0, children: /* @__PURE__ */ h("button", { type: "button", tabIndex: 0, "aria-label": b("datePicker.selectMonthRange"), onClick: (e) => {
|
|
320
|
+
e.stopPropagation(), d || m(!p);
|
|
320
321
|
}, onKeyDown: (e) => {
|
|
321
|
-
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), e.stopPropagation(), d || (E.current = !0,
|
|
322
|
-
}, className: "inline-flex items-center justify-center bg-transparent border-none p-0 cursor-pointer", children: /* @__PURE__ */
|
|
323
|
-
/* @__PURE__ */
|
|
322
|
+
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), e.stopPropagation(), d || (E.current = !0, m(!p)));
|
|
323
|
+
}, className: "inline-flex items-center justify-center bg-transparent border-none p-0 cursor-pointer", children: /* @__PURE__ */ h(rt, { className: "h-4 w-4 text-secondary-foreground" }) }) }),
|
|
324
|
+
/* @__PURE__ */ h(de, { variant: "tertiary", side: "top", children: b("datePicker.selectMonthRange") })
|
|
324
325
|
] })
|
|
325
326
|
] })
|
|
326
327
|
]
|
|
327
328
|
}
|
|
328
329
|
) }),
|
|
329
|
-
/* @__PURE__ */
|
|
330
|
+
/* @__PURE__ */ h(
|
|
330
331
|
gt,
|
|
331
332
|
{
|
|
332
|
-
ref:
|
|
333
|
+
ref: q,
|
|
333
334
|
className: "w-auto p-0",
|
|
334
335
|
align: "start",
|
|
335
336
|
"aria-label": b("datePicker.selectDateRange"),
|
|
336
337
|
onOpenAutoFocus: (e) => {
|
|
337
338
|
E.current || e.preventDefault(), E.current = !1;
|
|
338
339
|
},
|
|
339
|
-
...
|
|
340
|
-
children: /* @__PURE__ */
|
|
341
|
-
|
|
340
|
+
...ze,
|
|
341
|
+
children: /* @__PURE__ */ h(
|
|
342
|
+
vt,
|
|
342
343
|
{
|
|
343
|
-
mode:
|
|
344
|
-
selected:
|
|
345
|
-
footerFlashKey:
|
|
346
|
-
footerFlashTarget:
|
|
344
|
+
mode: K,
|
|
345
|
+
selected: K === "multi-range" ? te : u,
|
|
346
|
+
footerFlashKey: Le,
|
|
347
|
+
footerFlashTarget: qe,
|
|
347
348
|
onSelect: Qe,
|
|
348
349
|
month: Ge,
|
|
349
350
|
onMonthChange: w,
|
|
350
|
-
disabled: kt(
|
|
351
|
-
startMonth:
|
|
352
|
-
endMonth:
|
|
351
|
+
disabled: kt(me, ge),
|
|
352
|
+
startMonth: ve,
|
|
353
|
+
endMonth: he,
|
|
353
354
|
showFooter: g,
|
|
354
|
-
onApply:
|
|
355
|
+
onApply: re,
|
|
355
356
|
onCancel: A,
|
|
356
|
-
onClear:
|
|
357
|
+
onClear: H,
|
|
357
358
|
onRangesChange: B,
|
|
358
359
|
captionLayout: "dropdown",
|
|
359
|
-
...
|
|
360
|
+
...U !== void 0 ? { weekStartsOn: U } : {},
|
|
360
361
|
...xt({
|
|
361
362
|
calendarKind: be,
|
|
362
363
|
fiscalMode: Ie,
|
|
@@ -380,7 +381,7 @@ const Ct = f.forwardRef(
|
|
|
380
381
|
);
|
|
381
382
|
}
|
|
382
383
|
);
|
|
383
|
-
|
|
384
|
+
Pt.displayName = "DateRangePicker";
|
|
384
385
|
export {
|
|
385
|
-
|
|
386
|
+
Pt as DateRangePicker
|
|
386
387
|
};
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { FiscalPickerProps } from './date-picker.types';
|
|
2
2
|
export declare function fiscalCalendarPassThrough(props: FiscalPickerProps): {
|
|
3
|
-
showPresets: boolean | undefined;
|
|
4
|
-
showPeriodBoundaries: boolean | undefined;
|
|
5
|
-
autoNavigateToAvailable: boolean | undefined;
|
|
6
|
-
comparison: "prior-fy" | undefined;
|
|
7
|
-
onComparisonChange: ((value: import('../../..').YoYComparison | undefined) => void) | undefined;
|
|
8
|
-
weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6 | undefined;
|
|
9
3
|
calendarKind: "gregorian" | "fiscal" | undefined;
|
|
10
4
|
fiscalMode: "basic" | "advanced" | "custom" | undefined;
|
|
11
5
|
granularity: import('../../../lib/fiscal-calendar').Granularity | undefined;
|
|
12
6
|
fiscalMonthPattern: number[] | undefined;
|
|
13
7
|
fiscalYearStartMonth: number | undefined;
|
|
14
8
|
fiscalConfig: import('../../../lib/fiscal-calendar').FiscalCalendarConfig | undefined;
|
|
9
|
+
weekStartsOn: import('../../../lib/fiscal-calendar').Weekday;
|
|
10
|
+
showPresets: boolean | undefined;
|
|
11
|
+
showPeriodBoundaries: boolean | undefined;
|
|
12
|
+
autoNavigateToAvailable: boolean | undefined;
|
|
13
|
+
comparison: "prior-fy" | undefined;
|
|
14
|
+
onComparisonChange: ((value: import('../../..').YoYComparison | undefined) => void) | undefined;
|
|
15
15
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { resolveWeekStartsOn as e } from "../../../lib/fiscal-calendar/week-selection.js";
|
|
2
|
+
function i(a) {
|
|
2
3
|
return {
|
|
3
4
|
calendarKind: a.calendarKind,
|
|
4
5
|
fiscalMode: a.fiscalMode,
|
|
@@ -6,7 +7,10 @@ function e(a) {
|
|
|
6
7
|
fiscalMonthPattern: a.fiscalMonthPattern,
|
|
7
8
|
fiscalYearStartMonth: a.fiscalYearStartMonth,
|
|
8
9
|
fiscalConfig: a.fiscalConfig,
|
|
9
|
-
|
|
10
|
+
weekStartsOn: e({
|
|
11
|
+
weekStartsOn: a.weekStartsOn,
|
|
12
|
+
fiscalConfig: a.fiscalConfig
|
|
13
|
+
}),
|
|
10
14
|
showPresets: a.showPresets,
|
|
11
15
|
showPeriodBoundaries: a.showPeriodBoundaries,
|
|
12
16
|
autoNavigateToAvailable: a.autoNavigateToAvailable,
|
|
@@ -15,5 +19,5 @@ function e(a) {
|
|
|
15
19
|
};
|
|
16
20
|
}
|
|
17
21
|
export {
|
|
18
|
-
|
|
22
|
+
i as fiscalCalendarPassThrough
|
|
19
23
|
};
|