@12-apps/ui 6.89.1 → 6.90.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/components-catalog.md +1 -1
- package/dist/_internal/components/data-display/Alert/Alert.js +3 -3
- package/dist/_internal/components/data-display/Avatar/Avatar.js +4 -4
- package/dist/_internal/components/data-display/Avatar/Avatar.view.js +2 -2
- package/dist/_internal/components/data-display/CardKit/card-actions-context.js +4 -4
- package/dist/_internal/components/data-display/CardKit/use-remove-confirm.js +5 -5
- package/dist/_internal/components/data-display/Carousel/Carousel.chrome.js +4 -3
- package/dist/_internal/components/data-display/Carousel/Carousel.js +6 -5
- package/dist/_internal/components/data-display/Carousel/Carousel.parts.js +3 -2
- package/dist/_internal/components/data-display/Chart/Chart.js +3 -3
- package/dist/_internal/components/data-display/Chart/SpecChart.js +6 -6
- package/dist/_internal/components/data-display/Chart/chart-renderers.js +2 -2
- package/dist/_internal/components/data-display/Chart/chart-spec.js +2 -2
- package/dist/_internal/components/data-display/DataGrid/DataGrid.js +2 -2
- package/dist/_internal/components/data-display/DataViews/DataViewsGrid.js +48 -23
- package/dist/_internal/components/data-display/DataViews/DataViewsTableBase.js +53 -28
- package/dist/_internal/components/data-display/DataViews/base-list-card-geometry.js +1 -1
- package/dist/_internal/components/data-display/DataViews/base-list-card-layout.js +1 -1
- package/dist/_internal/components/data-display/DataViews/base-list-card.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-bar-controls.js +5 -3
- package/dist/_internal/components/data-display/DataViews/data-views-day-input.js +1 -1
- package/dist/_internal/components/data-display/DataViews/data-views-filter-panel.js +31 -6
- package/dist/_internal/components/data-display/DataViews/data-views-grid-bodies.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-grid-parts.js +47 -22
- package/dist/_internal/components/data-display/DataViews/data-views-inline-bar.js +37 -12
- package/dist/_internal/components/data-display/DataViews/data-views-more-fields.js +32 -7
- package/dist/_internal/components/data-display/DataViews/data-views-more-filters.js +33 -8
- package/dist/_internal/components/data-display/DataViews/data-views-number-input.js +1 -1
- package/dist/_internal/components/data-display/DataViews/data-views-preset-chips.js +10 -3
- package/dist/_internal/components/data-display/DataViews/data-views-range-bounds.js +47 -0
- package/dist/_internal/components/data-display/DataViews/data-views-range-bounds.js.map +1 -0
- package/dist/_internal/components/data-display/DataViews/data-views-range-calendar.js +36 -0
- package/dist/_internal/components/data-display/DataViews/data-views-range-calendar.js.map +1 -0
- package/dist/_internal/components/data-display/DataViews/data-views-range-pill.js +32 -6
- package/dist/_internal/components/data-display/DataViews/data-views-range-summary.js +12 -0
- package/dist/_internal/components/data-display/DataViews/data-views-range-summary.js.map +1 -0
- package/dist/_internal/components/data-display/DataViews/data-views-shell-toolbar.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-still-anchor.js +9 -0
- package/dist/_internal/components/data-display/DataViews/data-views-still-anchor.js.map +1 -0
- package/dist/_internal/components/data-display/DataViews/data-views-table-parts.js +4 -4
- package/dist/_internal/components/data-display/DataViews/data-views-toolbar.js +2 -2
- package/dist/_internal/components/data-display/DayRuler/DayRuler.js +3 -3
- package/dist/_internal/components/data-display/DayRuler/DayRuler.parts.js +2 -2
- package/dist/_internal/components/data-display/DayRuler/DayRuler.styles.js +3 -1
- package/dist/_internal/components/data-display/FleetMap/FleetBody.js +9 -8
- package/dist/_internal/components/data-display/FleetMap/FleetCanvas.js +8 -7
- package/dist/_internal/components/data-display/FleetMap/FleetMap.fixtures.js +2 -1
- package/dist/_internal/components/data-display/FleetMap/FleetMap.fixtures.js.map +1 -1
- package/dist/_internal/components/data-display/FleetMap/FleetMap.js +9 -9
- package/dist/_internal/components/data-display/MapPreview/MapControlBar.js +4 -3
- package/dist/_internal/components/data-display/MapPreview/MapLayers.js +5 -4
- package/dist/_internal/components/data-display/MapPreview/MapMarkers.js +4 -3
- package/dist/_internal/components/data-display/MapPreview/MapPreview.helpers.js +3 -2
- package/dist/_internal/components/data-display/MapPreview/MapPreview.js +7 -6
- package/dist/_internal/components/data-display/index.js +38 -38
- package/dist/_internal/components/feedback/NotificationStatusNotice/NotificationStatusNotice.js +4 -4
- package/dist/_internal/components/feedback/SequenceResolver/SequenceResolver.js +6 -6
- package/dist/_internal/components/feedback/SequenceResolver/SequenceResolver.overview.js +5 -5
- package/dist/_internal/components/feedback/SequenceResolver/SequenceResolver.parts.js +4 -4
- package/dist/_internal/components/feedback/index.js +7 -7
- package/dist/_internal/components/form/Calendar/Calendar.js +5 -5
- package/dist/_internal/components/form/Calendar/CalendarDay.js +1 -1
- package/dist/_internal/components/form/Calendar/CalendarDayCell.js +2 -2
- package/dist/_internal/components/form/Calendar/CalendarMonth.js +3 -3
- package/dist/_internal/components/form/Calendar/CalendarSelectorsMonth.js +4 -4
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.hooks.js +3 -3
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.js +10 -10
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.range.js +2 -2
- package/dist/_internal/components/form/DateRangePicker/DateRangePickerFields.js +3 -3
- package/dist/_internal/components/form/index.js +24 -24
- package/dist/_internal/components/index.js +66 -66
- package/dist/_internal/en-US.data-display.js +2 -1
- package/dist/_internal/pt-BR.data-display.js +2 -1
- package/dist/_internal/user-avatar/user-avatar.js +5 -5
- package/dist/charts.js +11 -11
- package/dist/{chunk-FJ3UZ4RC.js → chunk-2FKWKLSC.js} +5 -3
- package/dist/chunk-2FKWKLSC.js.map +1 -0
- package/dist/{chunk-BO6MT2S2.js → chunk-3HZKUN5J.js} +7 -6
- package/dist/chunk-3HZKUN5J.js.map +1 -0
- package/dist/{chunk-TYXFFNPM.js → chunk-3OTGREQG.js} +10 -10
- package/dist/{chunk-BEHT4IHH.js → chunk-3X2MA47R.js} +2 -2
- package/dist/{chunk-XHIBFBNP.js → chunk-3ZRK3BRN.js} +4 -2
- package/dist/chunk-3ZRK3BRN.js.map +1 -0
- package/dist/{chunk-X5OGIT2F.js → chunk-4L54KUZV.js} +22 -4
- package/dist/chunk-4L54KUZV.js.map +1 -0
- package/dist/{chunk-TRYR424I.js → chunk-6LOWZCH7.js} +15 -1
- package/dist/chunk-6LOWZCH7.js.map +1 -0
- package/dist/{chunk-6WHIJPEF.js → chunk-6PU5P7QT.js} +2 -2
- package/dist/chunk-7CUZTWKW.js +52 -0
- package/dist/chunk-7CUZTWKW.js.map +1 -0
- package/dist/{chunk-JIEVKHOH.js → chunk-7YJYIMWP.js} +7 -7
- package/dist/{chunk-YNZUYZ2O.js → chunk-A3DDEKLV.js} +2 -2
- package/dist/{chunk-KHREN7Y7.js → chunk-ACM3HHZY.js} +2 -2
- package/dist/{chunk-FEKWKWGK.js → chunk-ARGVUTTL.js} +15 -1
- package/dist/chunk-ARGVUTTL.js.map +1 -0
- package/dist/{chunk-DYHOBKPU.js → chunk-BLZDSCIZ.js} +6 -6
- package/dist/{chunk-E2UOEI7N.js → chunk-BV2LOTMC.js} +2 -2
- package/dist/{chunk-O63ZROSY.js → chunk-BZBLPXV7.js} +4 -4
- package/dist/{chunk-OKRITX4S.js → chunk-CJ6XXM4X.js} +4 -4
- package/dist/{chunk-LV6AD6XC.js → chunk-DBI6AMNY.js} +4 -4
- package/dist/{chunk-QRRWLLXW.js → chunk-DSBC6O46.js} +2 -2
- package/dist/{chunk-3YFDGFEK.js → chunk-DVX4HDNP.js} +2 -2
- package/dist/{chunk-CJUK32UH.js → chunk-EEO7M5GU.js} +2 -2
- package/dist/{chunk-7XSCEHGA.js → chunk-EOQ6EKTS.js} +7 -7
- package/dist/{chunk-5RSK5M6M.js → chunk-FI2CQOGC.js} +63 -126
- package/dist/chunk-FI2CQOGC.js.map +1 -0
- package/dist/{chunk-Q2ERGAQO.js → chunk-FYAW5GBF.js} +33 -6
- package/dist/chunk-FYAW5GBF.js.map +1 -0
- package/dist/{chunk-EOJSA2EK.js → chunk-G2PVUPE7.js} +26 -18
- package/dist/chunk-G2PVUPE7.js.map +1 -0
- package/dist/{chunk-AMLHEKSV.js → chunk-HI7JPDD6.js} +5 -5
- package/dist/{chunk-2H6SCVLD.js → chunk-HMEGQKNQ.js} +3 -3
- package/dist/chunk-J2AVWIMM.js +60 -0
- package/dist/chunk-J2AVWIMM.js.map +1 -0
- package/dist/{chunk-7QKIL5YF.js → chunk-J2GDA64N.js} +4 -4
- package/dist/{chunk-BAQ3ITZV.js → chunk-JFD742C3.js} +2 -2
- package/dist/{chunk-OBA75Y5O.js → chunk-JHWEL4NX.js} +61 -33
- package/dist/chunk-JHWEL4NX.js.map +1 -0
- package/dist/{chunk-HQCZT6TO.js → chunk-JVOEVTCZ.js} +5 -5
- package/dist/{chunk-WAO7UQRS.js → chunk-KANCE4MS.js} +3 -3
- package/dist/{chunk-XLU5WFSY.js → chunk-KRBPWTXW.js} +2 -2
- package/dist/{chunk-S6D7NOV7.js → chunk-L6JAALMX.js} +3 -3
- package/dist/{chunk-72HOUWAW.js → chunk-L6YTVXGN.js} +5 -3
- package/dist/{chunk-72HOUWAW.js.map → chunk-L6YTVXGN.js.map} +1 -1
- package/dist/chunk-LZNUBQ5I.js +181 -0
- package/dist/chunk-LZNUBQ5I.js.map +1 -0
- package/dist/{chunk-BECKKDYG.js → chunk-M2M4IDFU.js} +2 -2
- package/dist/{chunk-CSGBHYW6.js → chunk-M5Y42AZ4.js} +2 -2
- package/dist/chunk-MICX23P4.js +122 -0
- package/dist/chunk-MICX23P4.js.map +1 -0
- package/dist/{chunk-5CP5Z3YU.js → chunk-MPWA55CF.js} +4 -4
- package/dist/{chunk-5KK3I42O.js → chunk-NK6O4NE4.js} +13 -10
- package/dist/chunk-NK6O4NE4.js.map +1 -0
- package/dist/{chunk-RCTHCXS6.js → chunk-PJNIJIE6.js} +2 -2
- package/dist/{chunk-6ATXOJVQ.js → chunk-QADTI63U.js} +4 -4
- package/dist/{chunk-MW7P2C2C.js → chunk-QAEO52Z4.js} +2 -2
- package/dist/{chunk-5S5K73I6.js → chunk-QSOCOXVL.js} +3 -3
- package/dist/{chunk-NQCTANF3.js → chunk-QVDEGBME.js} +7 -7
- package/dist/{chunk-BQBEN44R.js → chunk-RDCIST7P.js} +2 -2
- package/dist/{chunk-HUXAIQC5.js → chunk-RZ3P4X2I.js} +2 -2
- package/dist/{chunk-WJMSND5Q.js → chunk-SCXVTNLE.js} +2 -2
- package/dist/{chunk-K6FCSB6T.js → chunk-SK2CTB3O.js} +6 -6
- package/dist/{chunk-QLJU7UUI.js → chunk-T7OIVPCO.js} +38 -3
- package/dist/chunk-T7OIVPCO.js.map +1 -0
- package/dist/{chunk-U2ILXZDG.js → chunk-TB5CRHTF.js} +2 -2
- package/dist/{chunk-SB2SEGR6.js → chunk-TIM4PXWN.js} +3 -3
- package/dist/{chunk-YDIC6LSP.js → chunk-VCQFDQM3.js} +27 -7
- package/dist/chunk-VCQFDQM3.js.map +1 -0
- package/dist/chunk-VIMMEADQ.js +164 -0
- package/dist/chunk-VIMMEADQ.js.map +1 -0
- package/dist/{chunk-6D5AMANO.js → chunk-WH3LUOCQ.js} +2 -2
- package/dist/{chunk-OWRQOYUE.js → chunk-WWR6APJR.js} +2 -2
- package/dist/{chunk-5BVAUUWL.js → chunk-X37NTEVS.js} +2 -2
- package/dist/{chunk-WW3F7DCX.js → chunk-Z2WZDVGG.js} +2 -2
- package/dist/{chunk-EXVCVXFX.js → chunk-ZH6NYB6Y.js} +3 -3
- package/dist/data-display/Alert.js +3 -3
- package/dist/data-display/Avatar.js +4 -4
- package/dist/data-display/CardKit.js +11 -11
- package/dist/data-display/Carousel.js +6 -5
- package/dist/data-display/Chart.js +11 -11
- package/dist/data-display/DataGrid.js +2 -2
- package/dist/data-display/DataViews.js +60 -35
- package/dist/data-display/DayRuler.js +3 -3
- package/dist/data-display/FleetMap.js +9 -9
- package/dist/data-display/MapPreview.js +7 -6
- package/dist/en-US.js +1 -1
- package/dist/feedback/NotificationStatusNotice.js +4 -4
- package/dist/feedback/SequenceResolver.js +6 -6
- package/dist/form/Calendar.js +5 -5
- package/dist/form/DateRangePicker.js +10 -10
- package/dist/locales.js +5 -5
- package/dist/pt-BR.js +1 -1
- package/dist/types/components/data-display/DataViews/data-views-bar-controls.d.ts +15 -1
- package/dist/types/components/data-display/DataViews/data-views-bar-controls.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-copy.d.ts +35 -0
- package/dist/types/components/data-display/DataViews/data-views-copy.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-day-input.d.ts +7 -1
- package/dist/types/components/data-display/DataViews/data-views-day-input.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-more-fields.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-more-filters.d.ts +5 -3
- package/dist/types/components/data-display/DataViews/data-views-more-filters.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-number-input.d.ts +10 -2
- package/dist/types/components/data-display/DataViews/data-views-number-input.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-preset-chips.d.ts +10 -0
- package/dist/types/components/data-display/DataViews/data-views-preset-chips.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-range-bounds.d.ts +35 -0
- package/dist/types/components/data-display/DataViews/data-views-range-bounds.d.ts.map +1 -0
- package/dist/types/components/data-display/DataViews/data-views-range-calendar.d.ts +35 -0
- package/dist/types/components/data-display/DataViews/data-views-range-calendar.d.ts.map +1 -0
- package/dist/types/components/data-display/DataViews/data-views-range-pill.d.ts +2 -11
- package/dist/types/components/data-display/DataViews/data-views-range-pill.d.ts.map +1 -1
- package/dist/types/components/data-display/DataViews/data-views-range-summary.d.ts +21 -0
- package/dist/types/components/data-display/DataViews/data-views-range-summary.d.ts.map +1 -0
- package/dist/types/components/data-display/DataViews/data-views-still-anchor.d.ts +45 -0
- package/dist/types/components/data-display/DataViews/data-views-still-anchor.d.ts.map +1 -0
- package/dist/types/components/data-display/DayRuler/DayRuler.styles.d.ts +6 -1
- package/dist/types/components/data-display/DayRuler/DayRuler.styles.d.ts.map +1 -1
- package/dist/types/components/data-display/LazyImage/LazyImage.hooks.d.ts +1 -1
- package/dist/types/components/form/Calendar/Calendar.d.ts.map +1 -1
- package/dist/types/components/form/Calendar/CalendarDay.d.ts +2 -0
- package/dist/types/components/form/Calendar/CalendarDay.d.ts.map +1 -1
- package/dist/types/components/form/Calendar/CalendarDayCell.d.ts +2 -0
- package/dist/types/components/form/Calendar/CalendarDayCell.d.ts.map +1 -1
- package/dist/types/components/form/Calendar/CalendarMonth.d.ts +5 -0
- package/dist/types/components/form/Calendar/CalendarMonth.d.ts.map +1 -1
- package/dist/types/en-US.data-display.d.ts.map +1 -1
- package/dist/types/pt-BR.data-display.d.ts.map +1 -1
- package/dist/user-avatar.js +5 -5
- package/package.json +1 -1
- package/src/components/data-display/DataViews/RESPONSIVE-BEHAVIOUR.md +59 -0
- package/src/components/data-display/DataViews/data-views-bar-controls.tsx +56 -1
- package/src/components/data-display/DataViews/data-views-copy.ts +36 -0
- package/src/components/data-display/DataViews/data-views-day-input.tsx +9 -1
- package/src/components/data-display/DataViews/data-views-inline-bar.tsx +5 -3
- package/src/components/data-display/DataViews/data-views-more-fields.tsx +1 -0
- package/src/components/data-display/DataViews/data-views-more-filters.tsx +82 -29
- package/src/components/data-display/DataViews/data-views-number-input.tsx +19 -9
- package/src/components/data-display/DataViews/data-views-preset-chips.tsx +165 -16
- package/src/components/data-display/DataViews/data-views-range-bounds.tsx +223 -0
- package/src/components/data-display/DataViews/data-views-range-calendar.tsx +185 -0
- package/src/components/data-display/DataViews/data-views-range-pill.tsx +71 -154
- package/src/components/data-display/DataViews/data-views-range-summary.tsx +66 -0
- package/src/components/data-display/DataViews/data-views-still-anchor.ts +93 -0
- package/src/components/data-display/DayRuler/DayRuler.styles.ts +29 -16
- package/src/components/form/Calendar/Calendar.md +17 -2
- package/src/components/form/Calendar/Calendar.tsx +56 -3
- package/src/components/form/Calendar/CalendarDay.tsx +33 -3
- package/src/components/form/Calendar/CalendarDayCell.tsx +4 -0
- package/src/components/form/Calendar/CalendarMonth.tsx +27 -5
- package/src/en-US.data-display.ts +12 -0
- package/src/pt-BR.data-display.ts +12 -0
- package/dist/chunk-5KK3I42O.js.map +0 -1
- package/dist/chunk-5RSK5M6M.js.map +0 -1
- package/dist/chunk-7D7CJRL7.js +0 -78
- package/dist/chunk-7D7CJRL7.js.map +0 -1
- package/dist/chunk-BO6MT2S2.js.map +0 -1
- package/dist/chunk-EOJSA2EK.js.map +0 -1
- package/dist/chunk-FEKWKWGK.js.map +0 -1
- package/dist/chunk-FJ3UZ4RC.js.map +0 -1
- package/dist/chunk-OBA75Y5O.js.map +0 -1
- package/dist/chunk-Q2ERGAQO.js.map +0 -1
- package/dist/chunk-QLJU7UUI.js.map +0 -1
- package/dist/chunk-TRYR424I.js.map +0 -1
- package/dist/chunk-X5OGIT2F.js.map +0 -1
- package/dist/chunk-XHIBFBNP.js.map +0 -1
- package/dist/chunk-YDIC6LSP.js.map +0 -1
- /package/dist/{chunk-TYXFFNPM.js.map → chunk-3OTGREQG.js.map} +0 -0
- /package/dist/{chunk-BEHT4IHH.js.map → chunk-3X2MA47R.js.map} +0 -0
- /package/dist/{chunk-6WHIJPEF.js.map → chunk-6PU5P7QT.js.map} +0 -0
- /package/dist/{chunk-JIEVKHOH.js.map → chunk-7YJYIMWP.js.map} +0 -0
- /package/dist/{chunk-YNZUYZ2O.js.map → chunk-A3DDEKLV.js.map} +0 -0
- /package/dist/{chunk-KHREN7Y7.js.map → chunk-ACM3HHZY.js.map} +0 -0
- /package/dist/{chunk-DYHOBKPU.js.map → chunk-BLZDSCIZ.js.map} +0 -0
- /package/dist/{chunk-E2UOEI7N.js.map → chunk-BV2LOTMC.js.map} +0 -0
- /package/dist/{chunk-O63ZROSY.js.map → chunk-BZBLPXV7.js.map} +0 -0
- /package/dist/{chunk-OKRITX4S.js.map → chunk-CJ6XXM4X.js.map} +0 -0
- /package/dist/{chunk-LV6AD6XC.js.map → chunk-DBI6AMNY.js.map} +0 -0
- /package/dist/{chunk-QRRWLLXW.js.map → chunk-DSBC6O46.js.map} +0 -0
- /package/dist/{chunk-3YFDGFEK.js.map → chunk-DVX4HDNP.js.map} +0 -0
- /package/dist/{chunk-CJUK32UH.js.map → chunk-EEO7M5GU.js.map} +0 -0
- /package/dist/{chunk-7XSCEHGA.js.map → chunk-EOQ6EKTS.js.map} +0 -0
- /package/dist/{chunk-AMLHEKSV.js.map → chunk-HI7JPDD6.js.map} +0 -0
- /package/dist/{chunk-2H6SCVLD.js.map → chunk-HMEGQKNQ.js.map} +0 -0
- /package/dist/{chunk-7QKIL5YF.js.map → chunk-J2GDA64N.js.map} +0 -0
- /package/dist/{chunk-BAQ3ITZV.js.map → chunk-JFD742C3.js.map} +0 -0
- /package/dist/{chunk-HQCZT6TO.js.map → chunk-JVOEVTCZ.js.map} +0 -0
- /package/dist/{chunk-WAO7UQRS.js.map → chunk-KANCE4MS.js.map} +0 -0
- /package/dist/{chunk-XLU5WFSY.js.map → chunk-KRBPWTXW.js.map} +0 -0
- /package/dist/{chunk-S6D7NOV7.js.map → chunk-L6JAALMX.js.map} +0 -0
- /package/dist/{chunk-BECKKDYG.js.map → chunk-M2M4IDFU.js.map} +0 -0
- /package/dist/{chunk-CSGBHYW6.js.map → chunk-M5Y42AZ4.js.map} +0 -0
- /package/dist/{chunk-5CP5Z3YU.js.map → chunk-MPWA55CF.js.map} +0 -0
- /package/dist/{chunk-RCTHCXS6.js.map → chunk-PJNIJIE6.js.map} +0 -0
- /package/dist/{chunk-6ATXOJVQ.js.map → chunk-QADTI63U.js.map} +0 -0
- /package/dist/{chunk-MW7P2C2C.js.map → chunk-QAEO52Z4.js.map} +0 -0
- /package/dist/{chunk-5S5K73I6.js.map → chunk-QSOCOXVL.js.map} +0 -0
- /package/dist/{chunk-NQCTANF3.js.map → chunk-QVDEGBME.js.map} +0 -0
- /package/dist/{chunk-BQBEN44R.js.map → chunk-RDCIST7P.js.map} +0 -0
- /package/dist/{chunk-HUXAIQC5.js.map → chunk-RZ3P4X2I.js.map} +0 -0
- /package/dist/{chunk-WJMSND5Q.js.map → chunk-SCXVTNLE.js.map} +0 -0
- /package/dist/{chunk-K6FCSB6T.js.map → chunk-SK2CTB3O.js.map} +0 -0
- /package/dist/{chunk-U2ILXZDG.js.map → chunk-TB5CRHTF.js.map} +0 -0
- /package/dist/{chunk-SB2SEGR6.js.map → chunk-TIM4PXWN.js.map} +0 -0
- /package/dist/{chunk-6D5AMANO.js.map → chunk-WH3LUOCQ.js.map} +0 -0
- /package/dist/{chunk-OWRQOYUE.js.map → chunk-WWR6APJR.js.map} +0 -0
- /package/dist/{chunk-5BVAUUWL.js.map → chunk-X37NTEVS.js.map} +0 -0
- /package/dist/{chunk-WW3F7DCX.js.map → chunk-Z2WZDVGG.js.map} +0 -0
- /package/dist/{chunk-EXVCVXFX.js.map → chunk-ZH6NYB6Y.js.map} +0 -0
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The `De`/`Até` pair of a range filter, its preset chips, the line under it
|
|
5
|
+
* and — for a day range — the calendar under that (FUT-4144). Shared by the
|
|
6
|
+
* pill's popover, the slide-in panel and the "Mais" sheet, so the three cannot
|
|
7
|
+
* drift on what a bound accepts or how it clears.
|
|
8
|
+
*/
|
|
9
|
+
import Box from '@mui/material/Box/index.js';
|
|
10
|
+
import Typography from '@mui/material/Typography/index.js';
|
|
11
|
+
import React, { useState } from 'react';
|
|
12
|
+
|
|
13
|
+
import { useDataViewsCopy } from './data-views-copy-context';
|
|
14
|
+
import { DayBoundInput } from './data-views-day-input';
|
|
15
|
+
import { NumberBoundInput } from './data-views-number-input';
|
|
16
|
+
import { RangePresets } from './data-views-preset-chips';
|
|
17
|
+
import { DayRangeCalendar } from './data-views-range-calendar';
|
|
18
|
+
import { presetsFor } from './data-views-range-presets';
|
|
19
|
+
import { useOutsideResetKey } from './data-views-range-reset';
|
|
20
|
+
import { isRangeInverted } from './data-views-range-values';
|
|
21
|
+
import type { RangeFieldConfig, RangeValue } from './data-views-types';
|
|
22
|
+
import { sxRem } from '../../../tokens/relative';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* One end of the range. A day keeps its `AAAA-MM-DD` string verbatim (the form
|
|
26
|
+
* both the field and the backend speak) and is typed through the masked
|
|
27
|
+
* `dd/mm/aaaa` field rather than a native date input — see
|
|
28
|
+
* {@link DayBoundInput} for why. A number parses, and an unparseable/blank
|
|
29
|
+
* entry CLEARS the bound rather than writing `NaN`.
|
|
30
|
+
*/
|
|
31
|
+
function BoundField<T extends Record<string, unknown>>({
|
|
32
|
+
field,
|
|
33
|
+
label,
|
|
34
|
+
value,
|
|
35
|
+
onChange,
|
|
36
|
+
testId,
|
|
37
|
+
fill,
|
|
38
|
+
}: {
|
|
39
|
+
field: RangeFieldConfig<T>;
|
|
40
|
+
label: string;
|
|
41
|
+
value: number | string | undefined;
|
|
42
|
+
onChange: (bound: number | string | undefined) => void;
|
|
43
|
+
testId: string;
|
|
44
|
+
/** A number box takes its cell's width; a day box always does. */
|
|
45
|
+
fill: boolean;
|
|
46
|
+
}): React.JSX.Element {
|
|
47
|
+
const copy = useDataViewsCopy();
|
|
48
|
+
if (field.kind === 'day') {
|
|
49
|
+
return (
|
|
50
|
+
<DayBoundInput
|
|
51
|
+
fill
|
|
52
|
+
mask={copy.filters.dayMask}
|
|
53
|
+
invalidMessage={copy.filters.dayInvalid}
|
|
54
|
+
label={label}
|
|
55
|
+
value={value == null ? undefined : String(value)}
|
|
56
|
+
onChange={onChange}
|
|
57
|
+
testId={testId}
|
|
58
|
+
/>
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
return (
|
|
62
|
+
<NumberBoundInput
|
|
63
|
+
fill={fill}
|
|
64
|
+
label={label}
|
|
65
|
+
value={value}
|
|
66
|
+
unit={field.unit}
|
|
67
|
+
onChange={onChange}
|
|
68
|
+
testId={testId}
|
|
69
|
+
/>
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
/** One box of the pair: an equal share of the row for a day, as it was for a number. */
|
|
75
|
+
function BoundCell({ grow, children }: { grow: boolean; children: React.ReactNode }): React.JSX.Element {
|
|
76
|
+
if (!grow) return <>{children}</>;
|
|
77
|
+
return <Box sx={{ flex: '1 1 0', minWidth: 0 }}>{children}</Box>;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* The line under the pair: why an inverted window matches nothing, or — for a
|
|
82
|
+
* day range — that BOTH days are in the result. Saying so is FUT-668's other
|
|
83
|
+
* half: the bounds compare as ISO strings precisely so `até` keeps its whole
|
|
84
|
+
* day, and nothing on screen would otherwise tell the merchant that.
|
|
85
|
+
*/
|
|
86
|
+
function RangeNote({
|
|
87
|
+
day,
|
|
88
|
+
inverted,
|
|
89
|
+
testId,
|
|
90
|
+
}: {
|
|
91
|
+
day: boolean;
|
|
92
|
+
inverted: boolean;
|
|
93
|
+
testId: string;
|
|
94
|
+
}): React.JSX.Element | null {
|
|
95
|
+
const copy = useDataViewsCopy();
|
|
96
|
+
if (inverted) {
|
|
97
|
+
return (
|
|
98
|
+
<Typography
|
|
99
|
+
component="p"
|
|
100
|
+
data-testid={`${testId}-inverted`}
|
|
101
|
+
sx={{ mt: 0.75, fontSize: sxRem(12), color: 'error.main' }}
|
|
102
|
+
>
|
|
103
|
+
{copy.filters.rangeInvalid}
|
|
104
|
+
</Typography>
|
|
105
|
+
);
|
|
106
|
+
}
|
|
107
|
+
if (!day) return null;
|
|
108
|
+
return (
|
|
109
|
+
<Typography
|
|
110
|
+
component="p"
|
|
111
|
+
data-testid={`${testId}-inclusive`}
|
|
112
|
+
// `text.secondary`, not `disabled`: the note is read, and disabled grey
|
|
113
|
+
// at 12px is 2.68:1 (FUT-4144 UI review).
|
|
114
|
+
sx={{ mt: { xs: 0.25, sm: 0.75 }, fontSize: sxRem(12), color: 'text.secondary' }}
|
|
115
|
+
>
|
|
116
|
+
{copy.filters.rangeInclusiveNote}
|
|
117
|
+
</Typography>
|
|
118
|
+
);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
/** Props of {@link RangeBounds}. */
|
|
122
|
+
interface RangeBoundsProps<T extends Record<string, unknown>> {
|
|
123
|
+
field: RangeFieldConfig<T>;
|
|
124
|
+
value: RangeValue;
|
|
125
|
+
onChange: (range: RangeValue) => void;
|
|
126
|
+
testId: string;
|
|
127
|
+
/**
|
|
128
|
+
* Months the day calendar shows side by side (FUT-4144). Two where the
|
|
129
|
+
* popover has the room; one, with the month/year selectors, on a phone and
|
|
130
|
+
* in the panels.
|
|
131
|
+
*/
|
|
132
|
+
calendarMonths?: 1 | 2;
|
|
133
|
+
/**
|
|
134
|
+
* Whether the day calendar is mounted. A host that keeps the pair mounted
|
|
135
|
+
* while hidden (the slide-in panel) passes its open state, so a closed panel
|
|
136
|
+
* holds no calendar of its own.
|
|
137
|
+
*/
|
|
138
|
+
showCalendar?: boolean;
|
|
139
|
+
/**
|
|
140
|
+
* A NUMBER pair splits the row equally too, as a day pair always does. Set
|
|
141
|
+
* by the panels, whose width is the row's; the pill's popover sizes itself to
|
|
142
|
+
* its content and keeps the boxes' own width.
|
|
143
|
+
*/
|
|
144
|
+
fillRow?: boolean;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* The `De`/`Até` pair for a range — shared by the pill's popover and the
|
|
149
|
+
* slide-in panel's day fields, so the two surfaces cannot drift on what a bound
|
|
150
|
+
* accepts or how it clears.
|
|
151
|
+
*/
|
|
152
|
+
export function RangeBounds<T extends Record<string, unknown>>({
|
|
153
|
+
field,
|
|
154
|
+
value,
|
|
155
|
+
onChange,
|
|
156
|
+
testId,
|
|
157
|
+
calendarMonths = 1,
|
|
158
|
+
showCalendar = true,
|
|
159
|
+
fillRow = false,
|
|
160
|
+
}: RangeBoundsProps<T>): React.JSX.Element {
|
|
161
|
+
const copy = useDataViewsCopy();
|
|
162
|
+
const { key, emitted } = useOutsideResetKey(value);
|
|
163
|
+
// Moves the calendar to a TYPED day. A typed write is the fields' own, so
|
|
164
|
+
// the outside key above does not see it; a tap on the calendar moves
|
|
165
|
+
// neither, which is what keeps it still under the finger.
|
|
166
|
+
const [typed, setTyped] = useState(0);
|
|
167
|
+
const typedChange = (range: RangeValue) => {
|
|
168
|
+
setTyped((n) => n + 1);
|
|
169
|
+
onChange(emitted(range));
|
|
170
|
+
};
|
|
171
|
+
const day = field.kind === 'day';
|
|
172
|
+
return (
|
|
173
|
+
<Box data-testid={`${testId}-panel`}>
|
|
174
|
+
{/* Above the inputs, not below: the presets are the answer for most
|
|
175
|
+
merchants, and the two date pickers are the escape hatch. */}
|
|
176
|
+
<Box sx={{ '&:not(:empty)': { mb: { xs: 1, sm: 1.5 } } }}>
|
|
177
|
+
<RangePresets presets={presetsFor(field, copy)} value={value} onChange={onChange} testId={testId} />
|
|
178
|
+
</Box>
|
|
179
|
+
{/* Top-aligned: a day that does not exist grows ITS field by a message
|
|
180
|
+
line, and centring would push the other box half a line down. The two
|
|
181
|
+
boxes are one height, so with no message this is the same row. */}
|
|
182
|
+
<Box sx={{ display: 'flex', alignItems: 'flex-start', gap: 1.5 }}>
|
|
183
|
+
{/* A day pair shares the row equally, so it spans the calendar under
|
|
184
|
+
it; a number pair keeps its own widths. */}
|
|
185
|
+
<BoundCell grow={day || fillRow}>
|
|
186
|
+
<BoundField
|
|
187
|
+
key={`min-${key}`}
|
|
188
|
+
field={field}
|
|
189
|
+
label={copy.filters.rangeStart}
|
|
190
|
+
value={value.min}
|
|
191
|
+
onChange={(min) => typedChange({ ...value, min })}
|
|
192
|
+
testId={`${testId}-min`}
|
|
193
|
+
fill={fillRow}
|
|
194
|
+
/>
|
|
195
|
+
</BoundCell>
|
|
196
|
+
<BoundCell grow={day || fillRow}>
|
|
197
|
+
<BoundField
|
|
198
|
+
key={`max-${key}`}
|
|
199
|
+
field={field}
|
|
200
|
+
label={copy.filters.rangeEnd}
|
|
201
|
+
value={value.max}
|
|
202
|
+
onChange={(max) => typedChange({ ...value, max })}
|
|
203
|
+
testId={`${testId}-max`}
|
|
204
|
+
fill={fillRow}
|
|
205
|
+
/>
|
|
206
|
+
</BoundCell>
|
|
207
|
+
</Box>
|
|
208
|
+
<RangeNote day={day} inverted={isRangeInverted(value)} testId={testId} />
|
|
209
|
+
{/* Under the boxes and the note, with no button to reach it: the typed
|
|
210
|
+
path stays as short as it was, and a period is two taps (FUT-4144). */}
|
|
211
|
+
{day && showCalendar && (
|
|
212
|
+
<DayRangeCalendar
|
|
213
|
+
fieldLabel={field.label}
|
|
214
|
+
value={value}
|
|
215
|
+
onChange={(range) => onChange(emitted(range))}
|
|
216
|
+
months={calendarMonths}
|
|
217
|
+
viewKey={`${key}-${typed}`}
|
|
218
|
+
testId={testId}
|
|
219
|
+
/>
|
|
220
|
+
)}
|
|
221
|
+
</Box>
|
|
222
|
+
);
|
|
223
|
+
}
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The range calendar under a day filter's `De`/`Até` boxes (FUT-4144).
|
|
5
|
+
*
|
|
6
|
+
* The owner picked it ALWAYS OPEN (option B of the prototype): a period is
|
|
7
|
+
* three taps — open the filter, the first day, the last day — against five for
|
|
8
|
+
* a calendar button in each box and four for a link to a separate sheet. It
|
|
9
|
+
* sits BELOW the boxes, with no button of its own, so the typed path is not one
|
|
10
|
+
* keystroke longer than it was.
|
|
11
|
+
*
|
|
12
|
+
* The boxes and the calendar are two views of ONE range: a tap writes the
|
|
13
|
+
* boxes, a typed day moves and repaints the calendar, an impossible typed day
|
|
14
|
+
* (which writes nothing) leaves it alone, and "Limpar" empties both.
|
|
15
|
+
*
|
|
16
|
+
* It is `Calendar` in `selectionMode="range"`, the same one `DateRangePicker`
|
|
17
|
+
* mounts — not a second calendar. Its own rule picks the period: the first tap
|
|
18
|
+
* starts it, the second closes it, and a second tap BEFORE the first swaps the
|
|
19
|
+
* two, so the boxes never show a period backwards.
|
|
20
|
+
*/
|
|
21
|
+
import Box from '@mui/material/Box/index.js';
|
|
22
|
+
import Typography from '@mui/material/Typography/index.js';
|
|
23
|
+
import React from 'react';
|
|
24
|
+
|
|
25
|
+
import { EN_US_DATA_VIEWS_COPY } from '../../../en-US.data-display';
|
|
26
|
+
import type { Theme } from '@mui/material/styles/index.js';
|
|
27
|
+
import { rem, sxRem } from '../../../tokens/relative';
|
|
28
|
+
import { Calendar, type DateRange } from '../../form/Calendar';
|
|
29
|
+
import { toDayString, toLocalDay } from '../../form/DateRangePicker/DateRangePicker.dates';
|
|
30
|
+
import type { DataViewsDayCalendarCopy } from './data-views-copy';
|
|
31
|
+
import { useDataViewsCopy } from './data-views-copy-context';
|
|
32
|
+
import type { RangeValue } from './data-views-types';
|
|
33
|
+
|
|
34
|
+
const CALENDAR_CLASS = 'data-views-range-calendar';
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* `Calendar` draws its own `Paper` with 24px of padding and a shadow. Inside
|
|
38
|
+
* the filter's popover that reads as a card inside a card, so the inner frame
|
|
39
|
+
* is flattened through the class hook the component offers for this — the
|
|
40
|
+
* same thing `DateRangePicker` does.
|
|
41
|
+
*/
|
|
42
|
+
const ROOT_SX = (theme: Theme) => ({
|
|
43
|
+
mt: { xs: 1, sm: 1.5 },
|
|
44
|
+
// Below `sm` the caption and the weekday row give up their bottom margins,
|
|
45
|
+
// so the whole popover fits a 320×568 screen under its pill (FUT-4144).
|
|
46
|
+
'& :has(> * > [data-testid="calendar-month-select"])': { mb: { xs: 0.5, sm: 2 } },
|
|
47
|
+
'& :has(> [role="columnheader"])': { mb: { xs: 0, sm: 1 } },
|
|
48
|
+
'& [role="columnheader"]': { height: { xs: rem(theme, 24), sm: rem(theme, 32) } },
|
|
49
|
+
// The days carry no column gap of their own (`Calendar`, FUT-4162), so the
|
|
50
|
+
// seven columns are what a day's 40px target is carved from below `sm`; the
|
|
51
|
+
// range band and its round endpoints are the Calendar's, untouched here.
|
|
52
|
+
// The month/year caption on ONE row at 320: the selectors give up the slack
|
|
53
|
+
// around their text before the arrows are pushed onto a second row.
|
|
54
|
+
'& [data-testid="calendar-month-select"], & [data-testid="calendar-year-select"]': { px: 0.5, minWidth: 0 },
|
|
55
|
+
[`& .${CALENDAR_CLASS}`]: {
|
|
56
|
+
p: 0,
|
|
57
|
+
boxShadow: 'none',
|
|
58
|
+
backgroundColor: 'transparent',
|
|
59
|
+
backgroundImage: 'none',
|
|
60
|
+
// A tapped day already rings itself; the whole grid framed in the primary
|
|
61
|
+
// colour after every tap is noise in a popover. The frame stays for the
|
|
62
|
+
// keyboard reaching the grid itself.
|
|
63
|
+
'&:focus-within': { outline: 'none' },
|
|
64
|
+
'&:focus-visible': {
|
|
65
|
+
outline: (theme: Theme) => `${rem(theme, 2)} solid`,
|
|
66
|
+
outlineColor: 'primary.main',
|
|
67
|
+
outlineOffset: sxRem(2),
|
|
68
|
+
},
|
|
69
|
+
},
|
|
70
|
+
});
|
|
71
|
+
|
|
72
|
+
/** The two ends of a range, as `Calendar` reads them. */
|
|
73
|
+
function rangeOf(value: RangeValue): DateRange {
|
|
74
|
+
return {
|
|
75
|
+
start: toLocalDay(typeof value.min === 'string' ? value.min : null),
|
|
76
|
+
end: toLocalDay(typeof value.max === 'string' ? value.max : null),
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* What a tap on the calendar makes of the range.
|
|
82
|
+
*
|
|
83
|
+
* `Calendar` reports the period it holds after the tap: a fresh start (`end`
|
|
84
|
+
* null) or a closed one, already in order. The one case it cannot see is a
|
|
85
|
+
* range with only `Até` — typed, or left by a saved view — where its first tap
|
|
86
|
+
* would drop that `Até`. A first day on or before it keeps it, so "até 15/10"
|
|
87
|
+
* plus one tap on the 3rd is 03/10–15/10, as the prototype does.
|
|
88
|
+
*/
|
|
89
|
+
export function rangeFromCalendar(previous: RangeValue, picked: DateRange): RangeValue {
|
|
90
|
+
const min = dayOf(picked.start);
|
|
91
|
+
const max = dayOf(picked.end) ?? keptEnd(previous, min);
|
|
92
|
+
return { ...(min ? { min } : {}), ...(max ? { max } : {}) };
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
const dayOf = (date: Date | null | undefined): string | undefined => (date ? toDayString(date) : undefined);
|
|
96
|
+
|
|
97
|
+
/** The `Até` of a range that has ONLY one, when the new first day is on or before it. */
|
|
98
|
+
function keptEnd(previous: RangeValue, min: string | undefined): string | undefined {
|
|
99
|
+
if (previous.min != null || typeof previous.max !== 'string') return undefined;
|
|
100
|
+
return min && min <= previous.max ? previous.max : undefined;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* The month the calendar opens on while `De` is empty. With `De` set it opens
|
|
105
|
+
* on De's month, which `Calendar` does by itself.
|
|
106
|
+
*
|
|
107
|
+
* With two months the current month sits on the RIGHT (setembro | outubro), so
|
|
108
|
+
* the days a filter usually asks about — the ones just past — are on screen;
|
|
109
|
+
* with only `Até` set, its month takes that place.
|
|
110
|
+
*/
|
|
111
|
+
function openingMonth(value: RangeValue, months: number): Date | undefined {
|
|
112
|
+
const end = toLocalDay(typeof value.max === 'string' ? value.max : null);
|
|
113
|
+
const anchor = end ?? new Date();
|
|
114
|
+
return new Date(anchor.getFullYear(), anchor.getMonth() - (months > 1 ? 1 : 0), 1);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/** Props of {@link DayRangeCalendar}. */
|
|
118
|
+
export interface DayRangeCalendarProps {
|
|
119
|
+
/** The filter's own label ("Data"), which names the calendar. */
|
|
120
|
+
fieldLabel: string;
|
|
121
|
+
value: RangeValue;
|
|
122
|
+
/** Called with the range a tap leaves; never for a typed day. */
|
|
123
|
+
onChange: (range: RangeValue) => void;
|
|
124
|
+
/**
|
|
125
|
+
* Months side by side. Two read as a period at a glance where there is room;
|
|
126
|
+
* one, with the month/year selectors, where there is not.
|
|
127
|
+
*/
|
|
128
|
+
months: 1 | 2;
|
|
129
|
+
/**
|
|
130
|
+
* Changes when the range moved from OUTSIDE the calendar (typed, a preset,
|
|
131
|
+
* "Limpar"), so the calendar re-opens on it. Never for its own taps: a
|
|
132
|
+
* calendar that jumped under the finger picking in it would be unusable.
|
|
133
|
+
*/
|
|
134
|
+
viewKey: string;
|
|
135
|
+
testId: string;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
export function DayRangeCalendar({
|
|
139
|
+
fieldLabel,
|
|
140
|
+
value,
|
|
141
|
+
onChange,
|
|
142
|
+
months,
|
|
143
|
+
viewKey,
|
|
144
|
+
testId,
|
|
145
|
+
}: DayRangeCalendarProps): React.JSX.Element {
|
|
146
|
+
const copy: DataViewsDayCalendarCopy =
|
|
147
|
+
useDataViewsCopy().filters.dayCalendar ?? (EN_US_DATA_VIEWS_COPY.filters.dayCalendar as DataViewsDayCalendarCopy);
|
|
148
|
+
const range = rangeOf(value);
|
|
149
|
+
const pick = (picked: DateRange) => onChange(rangeFromCalendar(value, picked));
|
|
150
|
+
const waitingForEnd = Boolean(range.start && !range.end);
|
|
151
|
+
|
|
152
|
+
return (
|
|
153
|
+
<Box sx={ROOT_SX} data-testid={`${testId}-calendar`}>
|
|
154
|
+
<Calendar
|
|
155
|
+
key={viewKey}
|
|
156
|
+
ariaLabel={copy.label(fieldLabel)}
|
|
157
|
+
className={CALENDAR_CLASS}
|
|
158
|
+
selectionMode="range"
|
|
159
|
+
locale={copy.locale}
|
|
160
|
+
labels={copy.caption}
|
|
161
|
+
// Sunday first, as a pt-BR calendar reads (`D S T Q Q S S`) and as the
|
|
162
|
+
// presets' "Esta semana" counts.
|
|
163
|
+
firstDayOfWeek={0}
|
|
164
|
+
numberOfMonths={months}
|
|
165
|
+
// Side by side, a day of the next month in this one is the same day
|
|
166
|
+
// twice; one month alone keeps them, muted, as a six-week frame.
|
|
167
|
+
showOutsideDays={months === 1}
|
|
168
|
+
captionLayout={months > 1 ? 'arrows' : 'selectors'}
|
|
169
|
+
defaultMonth={openingMonth(value, months)}
|
|
170
|
+
range={range}
|
|
171
|
+
// The intermediate callback does the work: the other fires only on the
|
|
172
|
+
// tap that CLOSES a period, so the first tap would write nothing.
|
|
173
|
+
onIntermediateRangeChange={pick}
|
|
174
|
+
/>
|
|
175
|
+
<Typography
|
|
176
|
+
component="p"
|
|
177
|
+
aria-live="polite"
|
|
178
|
+
data-testid={`${testId}-calendar-hint`}
|
|
179
|
+
sx={{ mt: { xs: 0.25, sm: 1 }, fontSize: sxRem(12), color: 'text.secondary' }}
|
|
180
|
+
>
|
|
181
|
+
{waitingForEnd ? copy.pickEnd : copy.pickStart}
|
|
182
|
+
</Typography>
|
|
183
|
+
</Box>
|
|
184
|
+
);
|
|
185
|
+
}
|