@persona/design-system 0.2.1 → 0.3.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/CHANGELOG.md +18 -0
- package/dist/{Action-DnR0YTxO.d.mts → Action-CnNf5T-l.d.mts} +2 -2
- package/dist/Action.d.mts +1 -1
- package/dist/AdvancedFilterRuleRow.d.mts +3 -3
- package/dist/AdvancedFilterRulesPopover.d.mts +3 -3
- package/dist/ArrayValueControl.d.mts +1 -1
- package/dist/Attribute.d.mts +2 -2
- package/dist/AttributeGrid.d.mts +1 -1
- package/dist/{Badge-DRn_r6is.mjs → Badge-BqS6Nk4J.mjs} +2 -2
- package/dist/{Badge-DRn_r6is.mjs.map → Badge-BqS6Nk4J.mjs.map} +1 -1
- package/dist/Banner.d.mts +1 -1
- package/dist/BooleanValueControl.d.mts +1 -1
- package/dist/{Breadcrumbs-Byf2ye6H.mjs → Breadcrumbs-CqKtnZqu.mjs} +8 -8
- package/dist/{Breadcrumbs-Byf2ye6H.mjs.map → Breadcrumbs-CqKtnZqu.mjs.map} +1 -1
- package/dist/{Button-DkjwN_Op.d.mts → Button-C0F0F2IL.d.mts} +2 -2
- package/dist/Button.d.mts +1 -1
- package/dist/ButtonGroup.d.mts +1 -1
- package/dist/Calendar-BvLNcHQM.d.mts +12 -0
- package/dist/Calendar.d.mts +2 -12
- package/dist/CalendarBase.d.mts +1 -1
- package/dist/{Card-CLTkZLKr.mjs → Card-BMCB9eFC.mjs} +4 -4
- package/dist/{Card-CLTkZLKr.mjs.map → Card-BMCB9eFC.mjs.map} +1 -1
- package/dist/{Card-DxFajLnx.d.mts → Card-BxNoIQWw.d.mts} +3 -3
- package/dist/Card.d.mts +1 -1
- package/dist/Card2.d.mts +1 -1
- package/dist/{CardV2-m9yOInMU.mjs → CardV2-B0ZweQYk.mjs} +22 -16
- package/dist/CardV2-B0ZweQYk.mjs.map +1 -0
- package/dist/{Checkbox-Bmm-r5ei.d.mts → Checkbox-Bm8exUfH.d.mts} +1 -1
- package/dist/{Checkbox-CU27-Aa8.mjs → Checkbox-DAvbgZgO.mjs} +5 -5
- package/dist/Checkbox-DAvbgZgO.mjs.map +1 -0
- package/dist/Checkbox.d.mts +1 -1
- package/dist/CheckboxGroupField.d.mts +2 -2
- package/dist/ChoicesValueControl.d.mts +1 -1
- package/dist/{Combobox-BgKEHP9p.d.mts → Combobox-C8ue0cBP.d.mts} +3 -3
- package/dist/{Combobox-DhTUY8JT.mjs → Combobox-xBrxiUAu.mjs} +18 -18
- package/dist/Combobox-xBrxiUAu.mjs.map +1 -0
- package/dist/Combobox.d.mts +2 -2
- package/dist/{ComboboxBase-Dmzn8a53.d.mts → ComboboxBase-DJGTMf1_.d.mts} +6 -6
- package/dist/ComboboxBase.d.mts +1 -1
- package/dist/{ComboboxMultiSelect-BLKUKNEW.d.mts → ComboboxMultiSelect-D7A2bbWU.d.mts} +2 -2
- package/dist/ComboboxMultiSelect.d.mts +1 -1
- package/dist/{ComboboxSingleSelect-Kpl-iOok.d.mts → ComboboxSingleSelect-D1uzEyKj.d.mts} +4 -4
- package/dist/ComboboxSingleSelect.d.mts +1 -1
- package/dist/{CompactBar-E9hPDRvI.d.mts → CompactBar-DMuvqaV5.d.mts} +3 -3
- package/dist/CompactBar.d.mts +1 -1
- package/dist/{ConfigFormGroup-GgzSDzgL.mjs → ConfigFormGroup-D2_sajXe.mjs} +2 -2
- package/dist/{ConfigFormGroup-GgzSDzgL.mjs.map → ConfigFormGroup-D2_sajXe.mjs.map} +1 -1
- package/dist/{ControlBar-DYrjBDzu.d.mts → ControlBar-Dg8JeU8f.d.mts} +2 -2
- package/dist/ControlBar.d.mts +1 -1
- package/dist/DataTable.d.mts +4 -4
- package/dist/DateField-Com9f2-j.d.mts +23 -0
- package/dist/DateField.d.mts +2 -23
- package/dist/DatePicker-BGO6doLx.d.mts +19 -0
- package/dist/{DatePicker-DpGvo7Bd.mjs → DatePicker-BlnE2MBD.mjs} +17 -16
- package/dist/{DatePicker-DpGvo7Bd.mjs.map → DatePicker-BlnE2MBD.mjs.map} +1 -1
- package/dist/DatePicker.d.mts +2 -19
- package/dist/DateRangePicker-DfRBm9z4.d.mts +53 -0
- package/dist/DateRangePicker.d.mts +2 -53
- package/dist/DateRangeValueControl.d.mts +19 -0
- package/dist/DateValueControl.d.mts +1 -1
- package/dist/{DropdownButton-DGgfGW_o.mjs → DropdownButton-CpWNRUma.mjs} +3 -3
- package/dist/{DropdownButton-DGgfGW_o.mjs.map → DropdownButton-CpWNRUma.mjs.map} +1 -1
- package/dist/DropdownButton.d.mts +2 -2
- package/dist/{DropdownMenu-DZIFSJXD.mjs → DropdownMenu-BCyV8nC0.mjs} +3 -3
- package/dist/{DropdownMenu-DZIFSJXD.mjs.map → DropdownMenu-BCyV8nC0.mjs.map} +1 -1
- package/dist/{DropdownMenu-B2t3Bwky.d.mts → DropdownMenu-CnaK78rP.d.mts} +3 -3
- package/dist/DropdownMenu.d.mts +1 -1
- package/dist/{ErrorProps-DX50vo-U.d.mts → ErrorProps-CN2XjaOX.d.mts} +1 -1
- package/dist/ErrorProps.d.mts +1 -1
- package/dist/{FieldRegistry-COyIA4VU.d.mts → FieldRegistry-DdA63Vnh.d.mts} +2 -2
- package/dist/FieldRegistry.d.mts +1 -1
- package/dist/{FilterBar-CS2YjiTr.d.mts → FilterBar-CxNsBVrn.d.mts} +5 -8
- package/dist/FilterBar.d.mts +1 -1
- package/dist/FilterPickerMenu.d.mts +3 -3
- package/dist/FilterPill.d.mts +1 -1
- package/dist/FilterPopover.d.mts +3 -13
- package/dist/FloatValueControl.d.mts +1 -1
- package/dist/FloatingPanel.d.mts +80 -0
- package/dist/FloatingPanelContext.d.mts +33 -0
- package/dist/FloatingPanelRenderer.d.mts +7 -0
- package/dist/{FormControl-CZFmub1N.d.mts → FormControl-Doj2gvF0.d.mts} +3 -3
- package/dist/{FormControl-BIXJ-FPI.mjs → FormControl-HVzZEqJH.mjs} +4 -4
- package/dist/FormControl-HVzZEqJH.mjs.map +1 -0
- package/dist/FormControl.d.mts +1 -1
- package/dist/{FormField-DcGQvgNW.mjs → FormField-B9P3BWvS.mjs} +50 -48
- package/dist/FormField-B9P3BWvS.mjs.map +1 -0
- package/dist/{FormField-8rlT8pm0.d.mts → FormField-D8dHbqZZ.d.mts} +2 -2
- package/dist/FormField.d.mts +1 -1
- package/dist/{Header-OLZuv8fF.d.mts → Header-CBlB65NY.d.mts} +2 -2
- package/dist/Header.d.mts +1 -1
- package/dist/{HelperTooltip-CJDG7Ugp.d.mts → HelperTooltip-C28h1zFl.d.mts} +3 -3
- package/dist/HelperTooltip.d.mts +1 -1
- package/dist/{HoverCopyableField-BHdCaR-R.mjs → HoverCopyableField-0Bzygbp9.mjs} +6 -6
- package/dist/{HoverCopyableField-BHdCaR-R.mjs.map → HoverCopyableField-0Bzygbp9.mjs.map} +1 -1
- package/dist/HoverCopyableField.d.mts +1 -1
- package/dist/{IconButton-DC4rh6ow.mjs → IconButton-BfDlic2K.mjs} +8 -8
- package/dist/IconButton-BfDlic2K.mjs.map +1 -0
- package/dist/{IconButton-Dc17jZPG.d.mts → IconButton-CBcW7ZU8.d.mts} +2 -2
- package/dist/IconButton.d.mts +1 -1
- package/dist/ImageTile.d.mts +2 -2
- package/dist/InlineCombobox.d.mts +2 -2
- package/dist/InlineInput.d.mts +1 -1
- package/dist/{Input-PWfwMSJ7.mjs → Input-Bimw8KFj.mjs} +4 -4
- package/dist/{Input-PWfwMSJ7.mjs.map → Input-Bimw8KFj.mjs.map} +1 -1
- package/dist/{Input-DsS4J78T.d.mts → Input-CVdjkX88.d.mts} +4 -4
- package/dist/Input.d.mts +1 -1
- package/dist/{InputProps-Buxtnz77.d.mts → InputProps-BwKkmImn.d.mts} +2 -2
- package/dist/InputProps.d.mts +1 -1
- package/dist/IntegerValueControl.d.mts +1 -1
- package/dist/Link.d.mts +1 -1
- package/dist/{ListBox-Nl9aOBeh.d.mts → ListBox-CDl5oZPX.d.mts} +5 -5
- package/dist/{ListBox-BwD-q7wF.mjs → ListBox-DKZpGYjo.mjs} +22 -15
- package/dist/ListBox-DKZpGYjo.mjs.map +1 -0
- package/dist/ListBox.d.mts +1 -1
- package/dist/ListBoxField.d.mts +6 -3
- package/dist/{LoadingShimmer-BPYPtFE1.mjs → LoadingShimmer-DC2vqicd.mjs} +1 -1
- package/dist/{LoadingShimmer-BPYPtFE1.mjs.map → LoadingShimmer-DC2vqicd.mjs.map} +1 -1
- package/dist/LoadingShimmer.d.mts +1 -1
- package/dist/{LogicRow-BAREMenx.d.mts → LogicRow-CkbyvrUw.d.mts} +4 -4
- package/dist/LogicRow.d.mts +1 -1
- package/dist/MaskedInput.d.mts +1 -1
- package/dist/{Menu-DM9OoZ71.d.mts → Menu-CYRdEnfo.d.mts} +4 -4
- package/dist/{Menu-DpM8o234.mjs → Menu-Dir03WA9.mjs} +3 -3
- package/dist/{Menu-DpM8o234.mjs.map → Menu-Dir03WA9.mjs.map} +1 -1
- package/dist/Menu.d.mts +1 -1
- package/dist/{MiddleTruncatedText-Bzpg3zAU.mjs → MiddleTruncatedText-GXI-CPvs.mjs} +3 -3
- package/dist/{MiddleTruncatedText-Bzpg3zAU.mjs.map → MiddleTruncatedText-GXI-CPvs.mjs.map} +1 -1
- package/dist/Modal.d.mts +3 -3
- package/dist/{PageHeader-Dq-J3san.mjs → PageHeader-C2IUKhCg.mjs} +3 -3
- package/dist/{PageHeader-Dq-J3san.mjs.map → PageHeader-C2IUKhCg.mjs.map} +1 -1
- package/dist/PageHeader.d.mts +1 -1
- package/dist/PageLayout.d.mts +1 -1
- package/dist/{PageSelector-Ca4TcyxG.d.mts → PageSelector-vay4jpMp.d.mts} +3 -3
- package/dist/PageSelector.d.mts +1 -1
- package/dist/{Pagination-GALyid4q.mjs → Pagination-0VhVdXv0.mjs} +9 -9
- package/dist/{Pagination-GALyid4q.mjs.map → Pagination-0VhVdXv0.mjs.map} +1 -1
- package/dist/{Pagination-Dcmv7bVe.d.mts → Pagination-ygLutOst.d.mts} +2 -2
- package/dist/Pagination.d.mts +1 -1
- package/dist/{Pii-BalLvfze.mjs → Pii-C7pA72Bh.mjs} +2 -2
- package/dist/{Pii-BalLvfze.mjs.map → Pii-C7pA72Bh.mjs.map} +1 -1
- package/dist/Pii.d.mts +1 -1
- package/dist/PillShell.d.mts +1 -1
- package/dist/{Popover-BZ5Bs80y.mjs → Popover-BkDpDdaO.mjs} +5 -5
- package/dist/{Popover-BZ5Bs80y.mjs.map → Popover-BkDpDdaO.mjs.map} +1 -1
- package/dist/Popover.d.mts +1 -1
- package/dist/ProgressBar.d.mts +1 -1
- package/dist/ProgressIndicator.d.mts +1 -1
- package/dist/{Radio-CtPz3EzX.mjs → Radio-BaFutxgV.mjs} +3 -3
- package/dist/Radio-BaFutxgV.mjs.map +1 -0
- package/dist/{RadioGroup-Xn46ovrV.d.mts → RadioGroup-BuJaitgG.d.mts} +1 -1
- package/dist/{RadioGroup-sjBzFE_-.mjs → RadioGroup-ClMzOZl0.mjs} +3 -3
- package/dist/{RadioGroup-sjBzFE_-.mjs.map → RadioGroup-ClMzOZl0.mjs.map} +1 -1
- package/dist/RadioGroup.d.mts +1 -1
- package/dist/RangeCalendar.d.mts +1 -1
- package/dist/RangeCalendarPresets.d.mts +1 -1
- package/dist/RuleEditorFields.d.mts +3 -3
- package/dist/RulesPill.d.mts +1 -1
- package/dist/{SearchInput-Try11aJD.d.mts → SearchInput-Ca3_np5e.d.mts} +3 -3
- package/dist/SearchInput.d.mts +1 -1
- package/dist/Section.d.mts +1 -1
- package/dist/SectionHeading.d.mts +77 -2
- package/dist/{SegmentedControl-BugnH-h2.mjs → SegmentedControl-DgyJL4uN.mjs} +3 -3
- package/dist/{SegmentedControl-BugnH-h2.mjs.map → SegmentedControl-DgyJL4uN.mjs.map} +1 -1
- package/dist/{SegmentedControl-DckAdhcD.d.mts → SegmentedControl-_I4sWeD7.d.mts} +2 -2
- package/dist/SegmentedControl.d.mts +1 -1
- package/dist/{Select-DL-AjL0Q.mjs → Select-D6MqSYVa.mjs} +8 -8
- package/dist/{Select-DL-AjL0Q.mjs.map → Select-D6MqSYVa.mjs.map} +1 -1
- package/dist/{Select-BmJ1OjXA.d.mts → Select-vwXGlHuW.d.mts} +4 -4
- package/dist/Select.d.mts +1 -1
- package/dist/Slider.d.mts +1 -1
- package/dist/SliderRHF.d.mts +1 -1
- package/dist/SliderThumb.d.mts +1 -1
- package/dist/{Spacer-Ln3KChb5.mjs → Spacer-CJp0lwkL.mjs} +1 -1
- package/dist/{Spacer-Ln3KChb5.mjs.map → Spacer-CJp0lwkL.mjs.map} +1 -1
- package/dist/{Stack-ckRN7LrP.mjs → Stack-Bl54WmhY.mjs} +1 -1
- package/dist/{Stack-ckRN7LrP.mjs.map → Stack-Bl54WmhY.mjs.map} +1 -1
- package/dist/{Stack-CbcJykx9.d.mts → Stack-CkV7k7TE.d.mts} +2 -2
- package/dist/Stack.d.mts +1 -1
- package/dist/StatusIndicator.d.mts +1 -1
- package/dist/{Sticker-BIVuastf.d.mts → Sticker-Dhx2wqTL.d.mts} +4 -4
- package/dist/{Sticker-B0TbkV4o.mjs → Sticker-xtDMuOoN.mjs} +3 -3
- package/dist/{Sticker-B0TbkV4o.mjs.map → Sticker-xtDMuOoN.mjs.map} +1 -1
- package/dist/Sticker.d.mts +1 -1
- package/dist/StringValueControl.d.mts +1 -1
- package/dist/SwatchPicker.d.mts +1 -1
- package/dist/Tab.d.mts +2 -2
- package/dist/{TabBar-DLf4Hwa4.mjs → TabBar-D6UocZXi.mjs} +4 -4
- package/dist/{TabBar-DLf4Hwa4.mjs.map → TabBar-D6UocZXi.mjs.map} +1 -1
- package/dist/TabBarIconButton.d.mts +1 -1
- package/dist/{Table-C-mx8Uj0.mjs → Table-D1WyUQuv.mjs} +4 -4
- package/dist/{Table-C-mx8Uj0.mjs.map → Table-D1WyUQuv.mjs.map} +1 -1
- package/dist/{Table-8jXlKYLy.d.mts → Table-cO7ZwGPM.d.mts} +1 -1
- package/dist/Table.d.mts +1 -1
- package/dist/{TableBody-ByEcFueE.d.mts → TableBody-CirMgfAV.d.mts} +1 -1
- package/dist/TableBody.d.mts +1 -1
- package/dist/{TableBox-DGjKVQFO.mjs → TableBox-C5qWhr82.mjs} +12 -12
- package/dist/{TableBox-DGjKVQFO.mjs.map → TableBox-C5qWhr82.mjs.map} +1 -1
- package/dist/TableBox.d.mts +2 -2
- package/dist/{TableBoxCell-BmoPs1u1.d.mts → TableBoxCell-DmVX_tgn.d.mts} +7 -7
- package/dist/TableBoxCell.d.mts +1 -1
- package/dist/TableBoxField.d.mts +4 -4
- package/dist/{TableBoxRow-BAYvEDjT.d.mts → TableBoxRow-nwq41Bpi.d.mts} +4 -4
- package/dist/TableBoxRow.d.mts +1 -1
- package/dist/{TableBoxRowActions-DRs4MdK0.d.mts → TableBoxRowActions-B4_ojiQo.d.mts} +2 -2
- package/dist/TableBoxRowActions.d.mts +1 -1
- package/dist/TableCell.d.mts +1 -1
- package/dist/{TableControls-BK8DCsqi.mjs → TableControls-CZ9iu3ma.mjs} +181 -62
- package/dist/TableControls-CZ9iu3ma.mjs.map +1 -0
- package/dist/{TableControls-DscP6fyt.d.mts → TableControls-RwIPBxyU.d.mts} +4 -4
- package/dist/TableControls.d.mts +1 -1
- package/dist/{TableControlsContext-BeJ7GHPN.d.mts → TableControlsContext-D_SBFZN1.d.mts} +2 -2
- package/dist/TableControlsContext.d.mts +1 -1
- package/dist/{TableHead-g3afLl5B.d.mts → TableHead-DMq_q_W0.d.mts} +1 -1
- package/dist/TableHead.d.mts +1 -1
- package/dist/{TableHeaderCell-CWTMf2Fe.d.mts → TableHeaderCell-C2pqXBYO.d.mts} +1 -1
- package/dist/TableHeaderCell.d.mts +1 -1
- package/dist/{TableLayout-hPlVO3dD.d.mts → TableLayout-DQKu6Rcj.d.mts} +1 -1
- package/dist/TableLayout.d.mts +1 -1
- package/dist/{TableRow-lvjbVccA.d.mts → TableRow-CPqZ8DK3.d.mts} +1 -1
- package/dist/TableRow.d.mts +1 -1
- package/dist/TableTH.d.mts +1 -1
- package/dist/{TableViewConfigurationDropdown-Ccxtk5dA.d.mts → TableViewConfigurationDropdown-BYPh4dIP.d.mts} +2 -2
- package/dist/TableViewConfigurationDropdown.d.mts +1 -1
- package/dist/{TechnicalSticker-BrvR0zhC.mjs → TechnicalSticker-DTjg6d2F.mjs} +5 -5
- package/dist/{TechnicalSticker-BrvR0zhC.mjs.map → TechnicalSticker-DTjg6d2F.mjs.map} +1 -1
- package/dist/TechnicalSticker.d.mts +1 -1
- package/dist/{Text-hEoPeOc9.mjs → Text-RcEfNFLx.mjs} +1 -1
- package/dist/{Text-hEoPeOc9.mjs.map → Text-RcEfNFLx.mjs.map} +1 -1
- package/dist/{TextArea-DiKEhpfD.d.mts → TextArea-DhPBI_1-.d.mts} +2 -2
- package/dist/{TextArea-BFsXUkuj.mjs → TextArea-ZMgbE_Lh.mjs} +2 -2
- package/dist/{TextArea-BFsXUkuj.mjs.map → TextArea-ZMgbE_Lh.mjs.map} +1 -1
- package/dist/TextArea.d.mts +1 -1
- package/dist/{TextUnderlineTooltip-Bs6Jn5yr.d.mts → TextUnderlineTooltip-BzmmiJlC.d.mts} +3 -3
- package/dist/TextUnderlineTooltip.d.mts +1 -1
- package/dist/Tile.d.mts +2 -2
- package/dist/Toast.d.mts +1 -1
- package/dist/{Toggle-oukvAn6V.d.mts → Toggle-BGGQ4Ukl.d.mts} +1 -1
- package/dist/{Toggle-CC2FTAKS.mjs → Toggle-BPgfSjuu.mjs} +4 -4
- package/dist/{Toggle-CC2FTAKS.mjs.map → Toggle-BPgfSjuu.mjs.map} +1 -1
- package/dist/Toggle.d.mts +1 -1
- package/dist/{Tooltip-CDvOu1UN.mjs → Tooltip-BvDbmXak.mjs} +3 -3
- package/dist/{Tooltip-CDvOu1UN.mjs.map → Tooltip-BvDbmXak.mjs.map} +1 -1
- package/dist/{Tooltip-0iXDCV2O.d.mts → Tooltip-D_a-RwAN.d.mts} +3 -3
- package/dist/Tooltip.d.mts +1 -1
- package/dist/{TruncatedText-CdeU19Ev.d.mts → TruncatedText-BJnowVTx.d.mts} +1 -1
- package/dist/components/Attribute/index.mjs +9 -10
- package/dist/components/Attribute/index.mjs.map +1 -1
- package/dist/components/Badge/index.mjs +1 -1
- package/dist/components/Banner/index.mjs +1 -1
- package/dist/components/Breadcrumbs/index.mjs +1 -1
- package/dist/components/Button/index.d.mts +2 -2
- package/dist/components/Button/index.mjs +1 -1
- package/dist/components/ButtonGroup/index.mjs +2 -2
- package/dist/components/Card/index.d.mts +2 -2
- package/dist/components/Card/index.mjs +1 -1
- package/dist/components/CardV2/index.d.mts +3 -2
- package/dist/components/CardV2/index.mjs +2 -2
- package/dist/components/Checkbox/index.d.mts +1 -1
- package/dist/components/Checkbox/index.mjs +1 -1
- package/dist/components/Combobox/index.d.mts +2 -2
- package/dist/components/Combobox/index.mjs +1 -1
- package/dist/components/ConfigFormGroup/index.mjs +1 -1
- package/dist/components/DataTable/TableControls/index.d.mts +16 -16
- package/dist/components/DataTable/TableControls/index.mjs +2 -2
- package/dist/components/DataTable/index.mjs +27 -29
- package/dist/components/DataTable/index.mjs.map +1 -1
- package/dist/components/DataTable/types.d.mts +2 -2
- package/dist/components/DatePicker/index.d.mts +4 -4
- package/dist/components/DatePicker/index.mjs +1 -1
- package/dist/components/DropdownButton/index.mjs +1 -1
- package/dist/components/DropdownMenu/index.d.mts +1 -1
- package/dist/components/DropdownMenu/index.mjs +1 -1
- package/dist/components/FloatingPanel/index.d.mts +5 -0
- package/dist/components/FloatingPanel/index.mjs +635 -0
- package/dist/components/FloatingPanel/index.mjs.map +1 -0
- package/dist/components/FormControl/index.d.mts +2 -2
- package/dist/components/FormControl/index.mjs +1 -1
- package/dist/components/FormField/index.d.mts +1 -1
- package/dist/components/FormField/index.mjs +1 -1
- package/dist/components/HoverCopyableField/index.mjs +1 -1
- package/dist/components/ImageTile/index.mjs +8 -8
- package/dist/components/Input/index.d.mts +1 -1
- package/dist/components/Input/index.mjs +1 -1
- package/dist/components/Link/index.mjs +1 -1
- package/dist/components/ListBox/index.d.mts +3 -3
- package/dist/components/ListBox/index.mjs +1 -1
- package/dist/components/LoadingShimmer/index.mjs +1 -1
- package/dist/components/MaskedInput/index.mjs +2 -2
- package/dist/components/Menu/index.d.mts +1 -1
- package/dist/components/Menu/index.mjs +1 -1
- package/dist/components/Modal/index.mjs +11 -12
- package/dist/components/Modal/index.mjs.map +1 -1
- package/dist/components/PageHeader/index.mjs +1 -1
- package/dist/components/Pagination/index.d.mts +3 -3
- package/dist/components/Pagination/index.mjs +1 -1
- package/dist/components/Pii/index.mjs +1 -1
- package/dist/components/Popover/index.mjs +1 -1
- package/dist/components/ProgressBar/index.mjs +3 -3
- package/dist/components/ProgressBar/index.mjs.map +1 -1
- package/dist/components/Radio/index.mjs +1 -1
- package/dist/components/RadioGroup/index.d.mts +1 -1
- package/dist/components/RadioGroup/index.mjs +1 -1
- package/dist/components/SegmentedControl/index.d.mts +1 -1
- package/dist/components/SegmentedControl/index.mjs +1 -1
- package/dist/components/Select/index.d.mts +1 -1
- package/dist/components/Select/index.mjs +1 -1
- package/dist/components/Slider/index.mjs +4 -4
- package/dist/components/Slider/index.mjs.map +1 -1
- package/dist/components/Spacer/index.mjs +1 -1
- package/dist/components/Stack/index.d.mts +1 -1
- package/dist/components/Stack/index.mjs +1 -1
- package/dist/components/Sticker/index.d.mts +1 -1
- package/dist/components/Sticker/index.mjs +1 -1
- package/dist/components/TabBar/index.mjs +1 -1
- package/dist/components/Table/index.d.mts +7 -7
- package/dist/components/Table/index.mjs +1 -1
- package/dist/components/TableBox/index.d.mts +2 -2
- package/dist/components/TableBox/index.mjs +1 -1
- package/dist/components/TechnicalSticker/index.mjs +1 -1
- package/dist/components/Text/index.mjs +1 -1
- package/dist/components/TextArea/index.d.mts +1 -1
- package/dist/components/TextArea/index.mjs +1 -1
- package/dist/components/Tile/index.mjs +4 -4
- package/dist/components/Toast/index.mjs +1 -1
- package/dist/components/Toggle/index.d.mts +1 -1
- package/dist/components/Toggle/index.mjs +1 -1
- package/dist/components/Tooltip/index.d.mts +3 -3
- package/dist/components/Tooltip/index.mjs +1 -1
- package/dist/compound-expression.d.mts +1 -1
- package/dist/{constants-bA9kCzRQ.d.mts → constants-BASogfT_.d.mts} +1 -1
- package/dist/constants.d.mts +1 -1
- package/dist/display.d.mts +1 -1
- package/dist/fieldPickerOptions.d.mts +2 -2
- package/dist/{filter-size-context-C1TvrE_O.d.mts → filter-size-context-Bw5F7082.d.mts} +2 -2
- package/dist/filter-size-context.d.mts +1 -1
- package/dist/helpers.d.mts +1 -1
- package/dist/{index-BC4edEsD.d.mts → index--5Mfhlkj.d.mts} +2 -2
- package/dist/{index-DJn4AeE4.d.mts → index-C1bz13uw.d.mts} +4 -4
- package/dist/{index-CdaoOvFH.d.mts → index-DiCnyORA.d.mts} +5 -5
- package/dist/index.d.mts +1 -1
- package/dist/index2.d.mts +1 -1
- package/dist/index3.d.mts +3 -3
- package/dist/index4.d.mts +11 -11
- package/dist/{input-D3Qd6dI8.d.mts → input-CzO-6_1V.d.mts} +2 -2
- package/dist/inputFields.d.mts +12 -26
- package/dist/lib/ConfigContext.d.mts +4 -1
- package/dist/lib/ConfigContext.mjs.map +1 -1
- package/dist/lib/MiddleTruncatedText.mjs +1 -1
- package/dist/lib/TruncatedText.d.mts +1 -1
- package/dist/lib/TruncatedText.mjs +1 -1
- package/dist/lib/TruncatedTextWithTooltip.d.mts +1 -1
- package/dist/lib/TruncatedTextWithTooltip.mjs +2 -2
- package/dist/lib/message.d.mts +1 -1
- package/dist/lib/pseudoClass.d.mts +7 -7
- package/dist/{message-CsK3sIq0.d.mts → message-Cu84fcqB.d.mts} +1 -1
- package/dist/mixins/input.d.mts +1 -1
- package/dist/{operators-C_xPzItk.d.mts → operators-CmSqHnTH.d.mts} +24 -3
- package/dist/operators.d.mts +2 -2
- package/dist/patterns/LayoutLoadingShimmer/index.mjs +5 -5
- package/dist/{types-mb3woqzE.d.mts → types-C-TkDdkG.d.mts} +6 -3
- package/dist/{types-CjHuZoVJ.d.mts → types-DEh_pXgS.d.mts} +1 -1
- package/dist/{types-BKEwt0uq.d.mts → types-NJtAxsU1.d.mts} +2 -2
- package/dist/{types-DVsBRqjZ.d.mts → types-TV9nVfSe.d.mts} +1 -1
- package/dist/types.d.mts +1 -1
- package/dist/types2.d.mts +1 -1
- package/dist/types3.d.mts +1 -1
- package/dist/types4.d.mts +1 -1
- package/dist/useComboboxFooterAction.d.mts +1 -1
- package/dist/{useFilterStateV2-CGzRyv0i.d.mts → useFilterStateV2-C4itmN4S.d.mts} +3 -3
- package/dist/useFilterStateV2.d.mts +1 -1
- package/dist/{useFormField-DhwEi45-.d.mts → useFormField-B2U4GOH4.d.mts} +2 -2
- package/dist/useFormField.d.mts +1 -1
- package/dist/{useTableBoxDragAndDrop-CsnN52lx.d.mts → useTableBoxDragAndDrop-CpemHLhL.d.mts} +1 -1
- package/dist/useTableBoxDragAndDrop.d.mts +1 -1
- package/dist/{useToggle-3k3EkV8V.mjs → useToggle-Bo3yd14Y.mjs} +1 -1
- package/dist/{useToggle-3k3EkV8V.mjs.map → useToggle-Bo3yd14Y.mjs.map} +1 -1
- package/dist/useTruncation.d.mts +1 -1
- package/dist/utils/storybook.mjs +1 -1
- package/dist/utils/testing.d.mts +1 -1
- package/dist/utils/testing.mjs +1 -1
- package/dist/utils.d.mts +1 -1
- package/dist/utils3.d.mts +7 -0
- package/dist/{validation-BdP2vajF.d.mts → validation-B5IXsdkE.d.mts} +3 -3
- package/dist/validation.d.mts +1 -1
- package/dist/{value-control-resolver-CiGEHQAc.d.mts → value-control-resolver-BPlTeIX7.d.mts} +2 -2
- package/dist/value-control-resolver.d.mts +1 -1
- package/llms.txt +1 -1
- package/package.json +5 -2
- package/skills/ui-authoring/SKILL.md +1 -1
- package/dist/CardV2-m9yOInMU.mjs.map +0 -1
- package/dist/Checkbox-CU27-Aa8.mjs.map +0 -1
- package/dist/Combobox-DhTUY8JT.mjs.map +0 -1
- package/dist/FormControl-BIXJ-FPI.mjs.map +0 -1
- package/dist/FormField-DcGQvgNW.mjs.map +0 -1
- package/dist/IconButton-DC4rh6ow.mjs.map +0 -1
- package/dist/ListBox-BwD-q7wF.mjs.map +0 -1
- package/dist/Radio-CtPz3EzX.mjs.map +0 -1
- package/dist/SectionHeading-DvP9NEgN.d.mts +0 -71
- package/dist/TableControls-BK8DCsqi.mjs.map +0 -1
- /package/dist/{index-0-W_aPej.d.mts → index-BMBcfD_R.d.mts} +0 -0
- /package/dist/{index-7in8TPrM.d.mts → index-BYd3Btr1.d.mts} +0 -0
- /package/dist/{index-B4woaFSm.d.mts → index-CNxS4Tlu.d.mts} +0 -0
- /package/dist/{index-BINnViIh.d.mts → index-CWB6exYm.d.mts} +0 -0
- /package/dist/{index-BNRXMhlr.d.mts → index-CtJuGxUp.d.mts} +0 -0
- /package/dist/{index-BO_854F2.d.mts → index-CzItj62a.d.mts} +0 -0
- /package/dist/{index-CCt0lwyI.d.mts → index-D4DUvwPf.d.mts} +0 -0
- /package/dist/{index-CREkvfw9.d.mts → index-D5tSVhTd.d.mts} +0 -0
- /package/dist/{index-Ci-uuV07.d.mts → index-DGsJdI5l.d.mts} +0 -0
- /package/dist/{index-CzUpNo0e.d.mts → index-DkrC-i1D.d.mts} +0 -0
- /package/dist/{index-DDdPqD_H.d.mts → index-DztUdPP_.d.mts} +0 -0
- /package/dist/{index-DeVKzGce.d.mts → index-IE5cwTAE2.d.mts} +0 -0
- /package/dist/{index-uMNhmxEh.d.mts → index-e6k85DKM.d.mts} +0 -0
package/dist/TableBoxField.d.mts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { l as MenuItemProps } from "./Menu-
|
|
1
|
+
import { l as MenuItemProps } from "./Menu-CYRdEnfo.mjs";
|
|
2
2
|
import { ImplementsFormField } from "./inputFields.mjs";
|
|
3
|
-
import { r as TableBoxRowProps } from "./TableBoxRow-
|
|
4
|
-
import { n as TableBoxCellProps, s as TableBoxProps } from "./TableBoxCell-
|
|
5
|
-
import { MouseEvent, ReactNode } from "react";
|
|
3
|
+
import { r as TableBoxRowProps } from "./TableBoxRow-nwq41Bpi.mjs";
|
|
4
|
+
import { n as TableBoxCellProps, s as TableBoxProps } from "./TableBoxCell-DmVX_tgn.mjs";
|
|
6
5
|
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
6
|
+
import { MouseEvent, ReactNode } from "react";
|
|
7
7
|
|
|
8
8
|
//#region components/FormField/TableBoxField.d.ts
|
|
9
9
|
interface TableBoxFieldAction extends Omit<MenuItemProps, 'children'> {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { l as MenuItemProps } from "./Menu-
|
|
2
|
-
import { t as TableRow } from "./TableRow-
|
|
3
|
-
import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
1
|
+
import { l as MenuItemProps } from "./Menu-CYRdEnfo.mjs";
|
|
2
|
+
import { t as TableRow } from "./TableRow-CPqZ8DK3.mjs";
|
|
4
3
|
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
4
|
+
import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
5
5
|
|
|
6
6
|
//#region components/TableBox/TableBoxRow.d.ts
|
|
7
7
|
interface TableBoxRowProps extends ComponentPropsWithoutRef<typeof TableRow> {
|
|
@@ -83,4 +83,4 @@ declare const TableBoxRowOverlay: ({
|
|
|
83
83
|
}) => _$react_jsx_runtime0.JSX.Element;
|
|
84
84
|
//#endregion
|
|
85
85
|
export { TableBoxRowOverlay as n, TableBoxRowProps as r, TableBoxRow as t };
|
|
86
|
-
//# sourceMappingURL=TableBoxRow-
|
|
86
|
+
//# sourceMappingURL=TableBoxRow-nwq41Bpi.d.mts.map
|
package/dist/TableBoxRow.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as TableBoxRowOverlay, r as TableBoxRowProps, t as TableBoxRow } from "./TableBoxRow-
|
|
1
|
+
import { n as TableBoxRowOverlay, r as TableBoxRowProps, t as TableBoxRow } from "./TableBoxRow-nwq41Bpi.mjs";
|
|
2
2
|
export { TableBoxRowOverlay, TableBoxRowProps, TableBoxRow as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { l as MenuItemProps } from "./Menu-
|
|
1
|
+
import { l as MenuItemProps } from "./Menu-CYRdEnfo.mjs";
|
|
2
2
|
import * as _$styled_components0 from "styled-components";
|
|
3
3
|
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
4
4
|
|
|
@@ -54,4 +54,4 @@ declare const RowActions: ({
|
|
|
54
54
|
}: RowActionsProps) => _$react_jsx_runtime0.JSX.Element | null;
|
|
55
55
|
//#endregion
|
|
56
56
|
export { RowActionsContainerWithFadeWidth as i, RowActions as n, RowActionsContainer as r, RowAction as t };
|
|
57
|
-
//# sourceMappingURL=TableBoxRowActions-
|
|
57
|
+
//# sourceMappingURL=TableBoxRowActions-B4_ojiQo.d.mts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as RowActionsContainerWithFadeWidth, n as RowActions, r as RowActionsContainer, t as RowAction } from "./TableBoxRowActions-
|
|
1
|
+
import { i as RowActionsContainerWithFadeWidth, n as RowActions, r as RowActionsContainer, t as RowAction } from "./TableBoxRowActions-B4_ojiQo.mjs";
|
|
2
2
|
export { RowAction, RowActions, RowActionsContainer, RowActionsContainerWithFadeWidth };
|
package/dist/TableCell.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TableCellProps, c as TableTD, i as TableCell, l as TableTR, n as StickyTH, o as TableCellTitle, r as TableActionTD, s as TableIconTD, t as StickyTD } from "./index-
|
|
1
|
+
import { a as TableCellProps, c as TableTD, i as TableCell, l as TableTR, n as StickyTH, o as TableCellTitle, r as TableActionTD, s as TableIconTD, t as StickyTD } from "./index-C1bz13uw.mjs";
|
|
2
2
|
export { StickyTD, StickyTH, TableActionTD, TableCellProps, TableCellTitle, TableIconTD, TableTD, TableTR, TableCell as default };
|
|
@@ -2,37 +2,37 @@ import { isActive, isFocused, isHovered, isNotDisabled } from "./lib/pseudoClass
|
|
|
2
2
|
import { focusOutline, focusWithinOutline } from "./mixins/focus.mjs";
|
|
3
3
|
import "./variables/transitions.mjs";
|
|
4
4
|
import { paragraphMixins } from "./mixins/text.mjs";
|
|
5
|
+
import { n as Stack, t as HStack } from "./Stack-Bl54WmhY.mjs";
|
|
5
6
|
import { TruncatedText } from "./lib/TruncatedText.mjs";
|
|
6
|
-
import { t as Card_default } from "./Card-
|
|
7
|
-
import { t as Spacer_default } from "./Spacer-
|
|
8
|
-
import { i as Paragraph, r as Label$1 } from "./Text-
|
|
9
|
-
import { a as Tooltip } from "./Tooltip-
|
|
7
|
+
import { t as Card_default } from "./Card-BMCB9eFC.mjs";
|
|
8
|
+
import { t as Spacer_default } from "./Spacer-CJp0lwkL.mjs";
|
|
9
|
+
import { i as Paragraph, r as Label$1 } from "./Text-RcEfNFLx.mjs";
|
|
10
|
+
import { a as Tooltip } from "./Tooltip-BvDbmXak.mjs";
|
|
10
11
|
import { useScrollOverflow } from "./lib/useScrollOverflow.mjs";
|
|
11
12
|
import { Z_INDICES } from "./lib/zindex.mjs";
|
|
12
|
-
import { n as
|
|
13
|
-
import {
|
|
14
|
-
import { r as InputGroup } from "./Input-PWfwMSJ7.mjs";
|
|
13
|
+
import { n as Button, t as IconButton } from "./IconButton-BfDlic2K.mjs";
|
|
14
|
+
import { r as InputGroup } from "./Input-Bimw8KFj.mjs";
|
|
15
15
|
import Input_default from "./components/Input/index.mjs";
|
|
16
|
-
import { c as MenuList, s as MenuItem } from "./Menu-
|
|
17
|
-
import { n as DropdownMenu_default } from "./DropdownMenu-
|
|
18
|
-
import { t as Combobox } from "./Combobox-
|
|
19
|
-
import { s as Popover_default } from "./Popover-
|
|
20
|
-
import { i as TabBar, n as StyledTab, r as Tab } from "./TabBar-
|
|
21
|
-
import { t as Toggle } from "./Toggle-
|
|
22
|
-
import { t as ListBox } from "./ListBox-
|
|
23
|
-
import { m as FormField, o as ComboboxField } from "./FormField-
|
|
24
|
-
import { n as DatePicker } from "./DatePicker-
|
|
16
|
+
import { c as MenuList, s as MenuItem } from "./Menu-Dir03WA9.mjs";
|
|
17
|
+
import { n as DropdownMenu_default } from "./DropdownMenu-BCyV8nC0.mjs";
|
|
18
|
+
import { t as Combobox } from "./Combobox-xBrxiUAu.mjs";
|
|
19
|
+
import { s as Popover_default } from "./Popover-BkDpDdaO.mjs";
|
|
20
|
+
import { i as TabBar, n as StyledTab, r as Tab } from "./TabBar-D6UocZXi.mjs";
|
|
21
|
+
import { t as Toggle } from "./Toggle-BPgfSjuu.mjs";
|
|
22
|
+
import { t as ListBox } from "./ListBox-DKZpGYjo.mjs";
|
|
23
|
+
import { m as FormField, o as ComboboxField } from "./FormField-B9P3BWvS.mjs";
|
|
24
|
+
import { n as DatePicker, t as DateRangePicker } from "./DatePicker-BlnE2MBD.mjs";
|
|
25
25
|
import { BorderRadius, Color, Spacing, Typography } from "@persona/design-tokens";
|
|
26
26
|
import styled, { createGlobalStyle, css } from "styled-components";
|
|
27
|
-
import { Fragment,
|
|
28
|
-
import { Fragment as Fragment$1,
|
|
27
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
28
|
+
import { Fragment as Fragment$1, createContext, createElement, forwardRef, useCallback, useContext, useEffect, useLayoutEffect, useMemo, useRef, useState } from "react";
|
|
29
29
|
import { CaretDownIcon, CheckIcon, CircleInfoIcon, CirclePlusIcon, CopyIcon, FilterIcon, MoreIcon, PlusIcon, RotateCcwIcon, SaveIcon, SearchIcon, SettingsIcon, TrashIcon, XIcon } from "@persona/icons";
|
|
30
30
|
import { CaretDownIcon as CaretDownIcon$1, CircleInfoIcon as CircleInfoIcon$1, LockedIcon as LockedIcon$1, MoreIcon as MoreIcon$1, PlusIcon as PlusIcon$1, SearchIcon as SearchIcon$1, XIcon as XIcon$1 } from "@persona/icons/12px";
|
|
31
|
-
import { isEqual, noop, startCase, uniqueId } from "lodash";
|
|
32
|
-
import { debounce as debounce$1, union, uniqueId as uniqueId$1 } from "lodash/fp.js";
|
|
31
|
+
import { debounce, isEqual, noop, startCase, union, uniqueId } from "lodash-es";
|
|
33
32
|
import { useId } from "react-aria";
|
|
34
33
|
import Fuse from "fuse.js";
|
|
35
34
|
import { DragIcon as DragIcon$1 } from "@persona/icons/24px";
|
|
35
|
+
import { DateTime } from "luxon";
|
|
36
36
|
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
|
37
37
|
import { DragDropContext, Draggable, Droppable } from "@hello-pangea/dnd";
|
|
38
38
|
import { parseDate } from "@internationalized/date";
|
|
@@ -207,7 +207,7 @@ const CompactSearchInput = styled(SearchInput)`
|
|
|
207
207
|
const CompactBar = ({ title, searchProps, showFilters, setShowFilters, filtersId, isLoading, propertiesButton, tableActions, "data-tour-target": dataTourTarget, filterPanel }) => {
|
|
208
208
|
const autoExpandSearch = !title;
|
|
209
209
|
const [showSearch, setShowSearch] = useState(autoExpandSearch);
|
|
210
|
-
return /* @__PURE__ */ jsxs(Fragment
|
|
210
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs(DataTableCompactBar, {
|
|
211
211
|
"data-tour-target": dataTourTarget,
|
|
212
212
|
justify: "space-between",
|
|
213
213
|
align: "center",
|
|
@@ -617,7 +617,7 @@ const ControlBar = ({ presetViews, currentView, onSelectView, views, onAddView,
|
|
|
617
617
|
children: displayLabel
|
|
618
618
|
}, key);
|
|
619
619
|
});
|
|
620
|
-
return /* @__PURE__ */ jsxs(Fragment
|
|
620
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
621
621
|
/* @__PURE__ */ jsx(ProductTourStyles, {}),
|
|
622
622
|
(title || showViews || canEditViews && onSaveView || tableActions || bulkActions) && /* @__PURE__ */ jsx(ViewsBar, {
|
|
623
623
|
ref: tabListRef,
|
|
@@ -645,7 +645,7 @@ const ControlBar = ({ presetViews, currentView, onSelectView, views, onAddView,
|
|
|
645
645
|
tableActions
|
|
646
646
|
]
|
|
647
647
|
}),
|
|
648
|
-
children: showViews && /* @__PURE__ */ jsxs(Fragment
|
|
648
|
+
children: showViews && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
649
649
|
/* @__PURE__ */ jsx(LockedViewTab, {
|
|
650
650
|
id: `${TAB_ID_PREFIX}default`,
|
|
651
651
|
selected: !currentView,
|
|
@@ -1158,6 +1158,7 @@ const OPERATORS_BY_TYPE = {
|
|
|
1158
1158
|
"is",
|
|
1159
1159
|
"before",
|
|
1160
1160
|
"after",
|
|
1161
|
+
"between",
|
|
1161
1162
|
"is_empty",
|
|
1162
1163
|
"is_not_empty"
|
|
1163
1164
|
],
|
|
@@ -1172,6 +1173,14 @@ const OPERATORS_BY_TYPE = {
|
|
|
1172
1173
|
};
|
|
1173
1174
|
/** Operators that have no value control (the operator itself is the predicate). */
|
|
1174
1175
|
const VALUELESS_OPERATORS = new Set(["is_empty", "is_not_empty"]);
|
|
1176
|
+
/**
|
|
1177
|
+
* Operators whose value is a {@link DateRangeFilterValue} rather than the
|
|
1178
|
+
* scalar its field type would otherwise carry. The value control, the draft
|
|
1179
|
+
* seed, and every validator branch on this rather than on field type alone —
|
|
1180
|
+
* a `date` field carries an ISO day string for `is` / `before` / `after` and
|
|
1181
|
+
* a `{ startDate, endDate }` pair for `between`.
|
|
1182
|
+
*/
|
|
1183
|
+
const RANGE_OPERATORS = new Set(["between"]);
|
|
1175
1184
|
function getOperatorsForType(type) {
|
|
1176
1185
|
return OPERATORS_BY_TYPE[type] ?? [];
|
|
1177
1186
|
}
|
|
@@ -1199,6 +1208,19 @@ function getDefaultOperatorForType(type) {
|
|
|
1199
1208
|
function isValuelessOperator(operator) {
|
|
1200
1209
|
return VALUELESS_OPERATORS.has(operator);
|
|
1201
1210
|
}
|
|
1211
|
+
function isRangeOperator(operator) {
|
|
1212
|
+
return RANGE_OPERATORS.has(operator);
|
|
1213
|
+
}
|
|
1214
|
+
/**
|
|
1215
|
+
* Whether `value` carries both endpoints of a range. Shared by the pill,
|
|
1216
|
+
* the validators, and the serialize boundary so "complete enough to send"
|
|
1217
|
+
* has one definition.
|
|
1218
|
+
*/
|
|
1219
|
+
function isCompleteDateRange(value) {
|
|
1220
|
+
if (value == null || typeof value !== "object" || Array.isArray(value)) return false;
|
|
1221
|
+
const { startDate, endDate } = value;
|
|
1222
|
+
return typeof startDate === "string" && startDate.length > 0 && typeof endDate === "string" && endDate.length > 0;
|
|
1223
|
+
}
|
|
1202
1224
|
/**
|
|
1203
1225
|
* Whether a concrete field's operator selector should be shown. A field
|
|
1204
1226
|
* pinned to one operator renders it as static text rather than a caret that
|
|
@@ -1220,7 +1242,8 @@ const OPERATOR_LABELS = {
|
|
|
1220
1242
|
is_true: "is true",
|
|
1221
1243
|
is_false: "is false",
|
|
1222
1244
|
before: "before",
|
|
1223
|
-
after: "after"
|
|
1245
|
+
after: "after",
|
|
1246
|
+
between: "is between"
|
|
1224
1247
|
};
|
|
1225
1248
|
/**
|
|
1226
1249
|
* Field-type-specific label overrides. The operator vocabulary itself
|
|
@@ -1253,6 +1276,40 @@ function emptyValueForFieldType(type) {
|
|
|
1253
1276
|
default: return "";
|
|
1254
1277
|
}
|
|
1255
1278
|
}
|
|
1279
|
+
/**
|
|
1280
|
+
* Empty endpoints are written as `''` rather than omitted so the object still
|
|
1281
|
+
* reads as a date range after a JSON round-trip — `undefined` keys don't
|
|
1282
|
+
* survive `JSON.stringify`, and a bare `{}` is indistinguishable from a
|
|
1283
|
+
* corrupted value at the validation boundary.
|
|
1284
|
+
*/
|
|
1285
|
+
function emptyDateRange() {
|
|
1286
|
+
return {
|
|
1287
|
+
startDate: "",
|
|
1288
|
+
endDate: ""
|
|
1289
|
+
};
|
|
1290
|
+
}
|
|
1291
|
+
/**
|
|
1292
|
+
* Empty-but-present value for a concrete `(field, operator)` pair. Prefer this
|
|
1293
|
+
* over {@link emptyValueForFieldType} anywhere an operator is in hand: the same
|
|
1294
|
+
* `date` field seeds an empty string for `before` and an empty range for
|
|
1295
|
+
* `between`.
|
|
1296
|
+
*/
|
|
1297
|
+
function emptyValueForRule(field, operator) {
|
|
1298
|
+
if (isValuelessOperator(operator)) return null;
|
|
1299
|
+
if (isRangeOperator(operator) || field.type === "date_range") return emptyDateRange();
|
|
1300
|
+
return emptyValueForFieldType(field.type);
|
|
1301
|
+
}
|
|
1302
|
+
/**
|
|
1303
|
+
* Carry `value` across an operator change, replacing it with a fresh draft
|
|
1304
|
+
* when the two operators disagree about value shape. Switching a date pill
|
|
1305
|
+
* from `after` to `between` must not leave the old ISO day string behind —
|
|
1306
|
+
* the range control can't read it and the wire format would reject it.
|
|
1307
|
+
*/
|
|
1308
|
+
function reconcileValueForOperator(field, nextOperator, previousOperator, value) {
|
|
1309
|
+
if (isValuelessOperator(nextOperator)) return null;
|
|
1310
|
+
if (isRangeOperator(nextOperator) !== isRangeOperator(previousOperator)) return emptyValueForRule(field, nextOperator);
|
|
1311
|
+
return value ?? emptyValueForRule(field, nextOperator);
|
|
1312
|
+
}
|
|
1256
1313
|
//#endregion
|
|
1257
1314
|
//#region components/DataTable/TableControls/FiltersV2/AdvancedFilterRulesPopover/display.ts
|
|
1258
1315
|
function valueDisplayString(value, optionLabels) {
|
|
@@ -1266,10 +1323,16 @@ function valueDisplayString(value, optionLabels) {
|
|
|
1266
1323
|
if (typeof value === "boolean") return value ? "true" : "false";
|
|
1267
1324
|
if (typeof value === "number") return String(value);
|
|
1268
1325
|
if (typeof value === "string") return value.length > 0 ? display(value) : void 0;
|
|
1326
|
+
if (typeof value === "object") {
|
|
1327
|
+
const { startDate, endDate } = value;
|
|
1328
|
+
if (startDate && endDate) return `${startDate} – ${endDate}`;
|
|
1329
|
+
return startDate || endDate || void 0;
|
|
1330
|
+
}
|
|
1269
1331
|
}
|
|
1270
1332
|
function draftValueFor(field, operator) {
|
|
1271
1333
|
if (isValuelessOperator(operator)) return null;
|
|
1272
1334
|
if (field.type === "boolean") return true;
|
|
1335
|
+
if (isRangeOperator(operator)) return emptyValueForRule(field, operator);
|
|
1273
1336
|
if (field.type === "multi_choices") return [];
|
|
1274
1337
|
return "";
|
|
1275
1338
|
}
|
|
@@ -1380,7 +1443,7 @@ function buildFieldPickerOptions(registry, visibleCustomFieldParents, excludeFie
|
|
|
1380
1443
|
//#region components/DataTable/TableControls/FiltersV2/AdvancedFilterRulesPopover/RuleEditorFields.tsx
|
|
1381
1444
|
function RuleEditorFields({ registry, field, groupIndex, ruleIndex, rule, size, operators, operatorConfigurable, onFieldChange, onOperatorChange, onValueChange, renderValueControl }) {
|
|
1382
1445
|
const fieldOptions = useMemo(() => buildFieldPickerOptions(registry), [registry]);
|
|
1383
|
-
return /* @__PURE__ */ jsxs(Fragment
|
|
1446
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1384
1447
|
/* @__PURE__ */ jsx(ComboboxField, {
|
|
1385
1448
|
label: "Value",
|
|
1386
1449
|
labelProps: { size },
|
|
@@ -1422,7 +1485,7 @@ function RuleEditorFields({ registry, field, groupIndex, ruleIndex, rule, size,
|
|
|
1422
1485
|
field && !isValuelessOperator(rule.operator) ? /* @__PURE__ */ jsx(FormField, {
|
|
1423
1486
|
label: "Value",
|
|
1424
1487
|
labelProps: { size },
|
|
1425
|
-
children: /* @__PURE__ */ jsx(Fragment
|
|
1488
|
+
children: /* @__PURE__ */ jsx(Fragment, { children: renderValueControl(field, rule.operator, rule.value, (next) => onValueChange(groupIndex, ruleIndex, next)) })
|
|
1426
1489
|
}) : null
|
|
1427
1490
|
] });
|
|
1428
1491
|
}
|
|
@@ -1745,12 +1808,17 @@ const AdvancedFilterRulesPopover = ({ registry, compound, onChange, trigger, ope
|
|
|
1745
1808
|
const handleOperatorChange = useCallback((groupIndex, ruleIndex, nextOperator) => {
|
|
1746
1809
|
const prev = compound.groups[groupIndex]?.rules[ruleIndex];
|
|
1747
1810
|
if (!prev) return;
|
|
1811
|
+
const field = registry.get(prev.fieldId);
|
|
1748
1812
|
onChange(setRuleInGroup(compound, groupIndex, ruleIndex, {
|
|
1749
1813
|
fieldId: prev.fieldId,
|
|
1750
1814
|
operator: nextOperator,
|
|
1751
|
-
value:
|
|
1815
|
+
value: field ? reconcileValueForOperator(field, nextOperator, prev.operator, prev.value) : null
|
|
1752
1816
|
}));
|
|
1753
|
-
}, [
|
|
1817
|
+
}, [
|
|
1818
|
+
compound,
|
|
1819
|
+
onChange,
|
|
1820
|
+
registry
|
|
1821
|
+
]);
|
|
1754
1822
|
const handleValueChange = useCallback((groupIndex, ruleIndex, nextValue) => {
|
|
1755
1823
|
const prev = compound.groups[groupIndex]?.rules[ruleIndex];
|
|
1756
1824
|
if (!prev) return;
|
|
@@ -1802,7 +1870,7 @@ const AdvancedFilterRulesPopover = ({ registry, compound, onChange, trigger, ope
|
|
|
1802
1870
|
const isEmptyGroup = group.rules.length === 0;
|
|
1803
1871
|
const hideGroupMenu = isOnlyGroup && isEmptyGroup;
|
|
1804
1872
|
const deleteGroupLabel = isOnlyGroup && !isEmptyGroup ? "Clear all" : "Delete group";
|
|
1805
|
-
return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs(GroupCard, {
|
|
1873
|
+
return /* @__PURE__ */ jsx(Fragment$1, { children: /* @__PURE__ */ jsxs(GroupCard, {
|
|
1806
1874
|
"data-test": `advanced-filter-rules__group-${groupIndex}`,
|
|
1807
1875
|
role: "group",
|
|
1808
1876
|
"aria-label": `Filter group ${groupIndex + 1}`,
|
|
@@ -2074,6 +2142,63 @@ function ChoicesValueControl({ field, operator, value, onChange, onCommit, ariaL
|
|
|
2074
2142
|
});
|
|
2075
2143
|
}
|
|
2076
2144
|
//#endregion
|
|
2145
|
+
//#region components/DataTable/TableControls/FiltersV2/value-controls/DateRangeValueControl/DateRangeValueControl.tsx
|
|
2146
|
+
const CALENDAR_DATE = /^(\d{4}-\d{2}-\d{2})/;
|
|
2147
|
+
const parseIsoDate$1 = (value) => {
|
|
2148
|
+
if (typeof value !== "string") return;
|
|
2149
|
+
const calendarDay = CALENDAR_DATE.exec(value)?.[1];
|
|
2150
|
+
if (calendarDay == null) return;
|
|
2151
|
+
try {
|
|
2152
|
+
const parsed = parseDate(calendarDay);
|
|
2153
|
+
return DateTime.fromObject({
|
|
2154
|
+
year: parsed.year,
|
|
2155
|
+
month: parsed.month,
|
|
2156
|
+
day: parsed.day
|
|
2157
|
+
});
|
|
2158
|
+
} catch {
|
|
2159
|
+
return;
|
|
2160
|
+
}
|
|
2161
|
+
};
|
|
2162
|
+
const readIsoEndpoints = (value) => {
|
|
2163
|
+
if (value == null || typeof value !== "object" || Array.isArray(value)) return {};
|
|
2164
|
+
return value;
|
|
2165
|
+
};
|
|
2166
|
+
const useDateRange = (value) => {
|
|
2167
|
+
const { startDate, endDate } = readIsoEndpoints(value);
|
|
2168
|
+
return useMemo(() => ({
|
|
2169
|
+
startDate: parseIsoDate$1(startDate),
|
|
2170
|
+
endDate: parseIsoDate$1(endDate)
|
|
2171
|
+
}), [startDate, endDate]);
|
|
2172
|
+
};
|
|
2173
|
+
const DateRangeValueControl = ({ field, operator, value, onChange, ariaLabel, hidePresets, portalContainer, visibleMonths }) => {
|
|
2174
|
+
const size = useFilterBarSize();
|
|
2175
|
+
const dateRange = useDateRange(value);
|
|
2176
|
+
const handleChange = useCallback((range) => {
|
|
2177
|
+
if (!range?.start || !range.end || range.start.compare(range.end) > 0) {
|
|
2178
|
+
onChange(null);
|
|
2179
|
+
return;
|
|
2180
|
+
}
|
|
2181
|
+
onChange({
|
|
2182
|
+
startDate: range.start.toString(),
|
|
2183
|
+
endDate: range.end.toString()
|
|
2184
|
+
});
|
|
2185
|
+
}, [onChange]);
|
|
2186
|
+
if (isValuelessOperator(operator)) return null;
|
|
2187
|
+
const hasCompleteRange = dateRange.startDate != null && dateRange.endDate != null;
|
|
2188
|
+
return /* @__PURE__ */ jsx(DateRangePicker, {
|
|
2189
|
+
"aria-label": ariaLabel ?? `${field.label} value`,
|
|
2190
|
+
calendarZIndex: Z_INDICES.modalDropdown,
|
|
2191
|
+
dateRange,
|
|
2192
|
+
hidePresets,
|
|
2193
|
+
label: null,
|
|
2194
|
+
onChange: handleChange,
|
|
2195
|
+
portalContainer,
|
|
2196
|
+
showClear: false,
|
|
2197
|
+
size,
|
|
2198
|
+
visibleMonths
|
|
2199
|
+
}, hasCompleteRange ? "range" : "empty");
|
|
2200
|
+
};
|
|
2201
|
+
//#endregion
|
|
2077
2202
|
//#region components/DataTable/TableControls/FiltersV2/value-controls/DateValueControl/DateValueControl.tsx
|
|
2078
2203
|
const parseIsoDate = (value) => {
|
|
2079
2204
|
if (typeof value !== "string") return null;
|
|
@@ -2159,7 +2284,7 @@ const FloatValueControl = ({ field, operator, value, onChange, ariaLabel }) => {
|
|
|
2159
2284
|
const size = useFilterBarSize();
|
|
2160
2285
|
const [localValue, setLocalValue] = useState(() => numericDisplayValue(value));
|
|
2161
2286
|
const isFocusedRef = useRef(false);
|
|
2162
|
-
const debouncedOnChange = useMemo(() => debounce
|
|
2287
|
+
const debouncedOnChange = useMemo(() => debounce(onChange, 300), [onChange]);
|
|
2163
2288
|
useEffect(() => {
|
|
2164
2289
|
const cancelPendingChange = () => {
|
|
2165
2290
|
debouncedOnChange.cancel();
|
|
@@ -2230,7 +2355,7 @@ const IntegerValueControl = ({ field, operator, value, onChange, ariaLabel }) =>
|
|
|
2230
2355
|
const size = useFilterBarSize();
|
|
2231
2356
|
const [localValue, setLocalValue] = useState(() => numericDisplayValue(value));
|
|
2232
2357
|
const isFocusedRef = useRef(false);
|
|
2233
|
-
const debouncedOnChange = useMemo(() => debounce
|
|
2358
|
+
const debouncedOnChange = useMemo(() => debounce(onChange, 300), [onChange]);
|
|
2234
2359
|
useEffect(() => {
|
|
2235
2360
|
const cancelPendingChange = () => {
|
|
2236
2361
|
debouncedOnChange.cancel();
|
|
@@ -2280,7 +2405,7 @@ function StringValueControl({ field, operator, value, onChange, ariaLabel, input
|
|
|
2280
2405
|
const resolvedInputType = inputType ?? (field.type === "email" ? "email" : "text");
|
|
2281
2406
|
const size = useFilterBarSize();
|
|
2282
2407
|
const [localValue, setLocalValue] = useState(typeof value === "string" ? value : "");
|
|
2283
|
-
const debouncedOnChange = useMemo(() => debounce
|
|
2408
|
+
const debouncedOnChange = useMemo(() => debounce(onChange, DEBOUNCE_MS), [onChange]);
|
|
2284
2409
|
useEffect(() => () => {
|
|
2285
2410
|
debouncedOnChange.cancel();
|
|
2286
2411
|
}, [debouncedOnChange]);
|
|
@@ -2318,7 +2443,8 @@ const RESOLVERS = {
|
|
|
2318
2443
|
...opts
|
|
2319
2444
|
}),
|
|
2320
2445
|
boolean: (opts) => /* @__PURE__ */ jsx(BooleanValueControl, { ...opts }),
|
|
2321
|
-
date: (opts) => /* @__PURE__ */ jsx(DateValueControl, { ...opts }),
|
|
2446
|
+
date: (opts) => isRangeOperator(opts.operator) ? /* @__PURE__ */ jsx(DateRangeValueControl, { ...opts }) : /* @__PURE__ */ jsx(DateValueControl, { ...opts }),
|
|
2447
|
+
date_range: (opts) => /* @__PURE__ */ jsx(DateRangeValueControl, { ...opts }),
|
|
2322
2448
|
integer: (opts) => /* @__PURE__ */ jsx(IntegerValueControl, { ...opts }),
|
|
2323
2449
|
float: (opts) => /* @__PURE__ */ jsx(FloatValueControl, { ...opts }),
|
|
2324
2450
|
array: (opts) => /* @__PURE__ */ jsx(ArrayValueControl, { ...opts })
|
|
@@ -2540,7 +2666,7 @@ const PillShell = forwardRef(function PillShell({ variant, children, bodyAriaLab
|
|
|
2540
2666
|
"aria-haspopup": "dialog",
|
|
2541
2667
|
"aria-expanded": ariaExpanded,
|
|
2542
2668
|
children
|
|
2543
|
-
}), onDismiss ? /* @__PURE__ */ jsxs(Fragment
|
|
2669
|
+
}), onDismiss ? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(DismissibleCaretWrapper, {
|
|
2544
2670
|
"aria-hidden": "true",
|
|
2545
2671
|
$size: resolvedSize,
|
|
2546
2672
|
children: /* @__PURE__ */ jsx(CaretIcon, {})
|
|
@@ -2618,9 +2744,10 @@ function normalizeValueToDisplay(value, optionLabels) {
|
|
|
2618
2744
|
return value.map((entry) => lookup(String(entry)));
|
|
2619
2745
|
}
|
|
2620
2746
|
if (typeof value === "object") {
|
|
2621
|
-
const
|
|
2622
|
-
if (
|
|
2623
|
-
|
|
2747
|
+
const { startDate, endDate } = value;
|
|
2748
|
+
if (startDate && endDate) return [`${startDate} – ${endDate}`];
|
|
2749
|
+
const single = startDate || endDate;
|
|
2750
|
+
return single ? [single] : [];
|
|
2624
2751
|
}
|
|
2625
2752
|
if (typeof value === "boolean") return [value ? "True" : "False"];
|
|
2626
2753
|
if (typeof value === "number") return [String(value)];
|
|
@@ -2640,7 +2767,7 @@ function buildAccessibleName(field, rule, displayedValues) {
|
|
|
2640
2767
|
return `${field.label} ${operatorLabel} ${displayedValues.join(", ")}`;
|
|
2641
2768
|
}
|
|
2642
2769
|
const FilterPill = forwardRef(function FilterPill({ field, rule, onClick, onDismiss, variant = "default", optionLabels, size, ...rest }, ref) {
|
|
2643
|
-
const reactId = useMemo(() => uniqueId
|
|
2770
|
+
const reactId = useMemo(() => uniqueId("filter-pill-"), []);
|
|
2644
2771
|
const resolvedSize = useFilterBarSize(size);
|
|
2645
2772
|
const displayedValues = useMemo(() => rule && !isValuelessOperator(rule.operator) ? normalizeValueToDisplay(rule.value, optionLabels) : [], [rule, optionLabels]);
|
|
2646
2773
|
const accessibleName = buildAccessibleName(field, rule, displayedValues);
|
|
@@ -2789,7 +2916,7 @@ const Footer = styled(HStack).attrs({
|
|
|
2789
2916
|
* back through `onChangeOperator` and forwards open/close transitions
|
|
2790
2917
|
* through Radix's controlled props.
|
|
2791
2918
|
*/
|
|
2792
|
-
const FilterPopover = ({ field, operator, onChangeOperator, valueControlSlot, onClose, trigger, open, onOpenChange, size
|
|
2919
|
+
const FilterPopover = ({ field, operator, onChangeOperator, valueControlSlot, onClose, trigger, open, onOpenChange, size }) => {
|
|
2793
2920
|
const resolvedSize = useFilterBarSize(size);
|
|
2794
2921
|
const valueless = isValuelessOperator(operator);
|
|
2795
2922
|
const CaretIcon = resolvedSize === "sm" ? CaretDownIcon$1 : CaretDownIcon;
|
|
@@ -2827,15 +2954,14 @@ const FilterPopover = ({ field, operator, onChangeOperator, valueControlSlot, on
|
|
|
2827
2954
|
return /* @__PURE__ */ jsxs(Popover_default, {
|
|
2828
2955
|
open,
|
|
2829
2956
|
onOpenChange: handleOpenChange,
|
|
2830
|
-
portalProps: portalContainer ? { container: portalContainer } : void 0,
|
|
2831
2957
|
children: [/* @__PURE__ */ jsx(Popover_default.Trigger, {
|
|
2832
2958
|
asChild: true,
|
|
2833
2959
|
children: trigger
|
|
2834
2960
|
}), /* @__PURE__ */ jsx(Popover_default.Card, {
|
|
2835
2961
|
align: "start",
|
|
2836
2962
|
sideOffset: 4,
|
|
2837
|
-
avoidCollisions:
|
|
2838
|
-
zIndex: Z_INDICES.
|
|
2963
|
+
avoidCollisions: true,
|
|
2964
|
+
zIndex: Z_INDICES.floatingBar,
|
|
2839
2965
|
"aria-label": `Edit filter for ${field.label}`,
|
|
2840
2966
|
noPadding: true,
|
|
2841
2967
|
children: /* @__PURE__ */ jsxs(PopoverPanel, {
|
|
@@ -2857,7 +2983,6 @@ const FilterPopover = ({ field, operator, onChangeOperator, valueControlSlot, on
|
|
|
2857
2983
|
}),
|
|
2858
2984
|
align: "start",
|
|
2859
2985
|
portal: true,
|
|
2860
|
-
portalProps: portalContainer ? { container: portalContainer } : void 0,
|
|
2861
2986
|
zIndex: Z_INDICES.layeredDropdown,
|
|
2862
2987
|
children: operatorOptions.map((op) => /* @__PURE__ */ jsx(DropdownMenu_default.Item, {
|
|
2863
2988
|
size: resolvedSize,
|
|
@@ -2988,7 +3113,8 @@ const OPERATOR_SET = new Set([
|
|
|
2988
3113
|
"is_true",
|
|
2989
3114
|
"is_false",
|
|
2990
3115
|
"before",
|
|
2991
|
-
"after"
|
|
3116
|
+
"after",
|
|
3117
|
+
"between"
|
|
2992
3118
|
]);
|
|
2993
3119
|
/**
|
|
2994
3120
|
* Returns `true` when `value` is a structurally-valid `FilterStateV2`,
|
|
@@ -3037,7 +3163,7 @@ function isFilterRuleValue(value) {
|
|
|
3037
3163
|
}
|
|
3038
3164
|
if (typeof value === "object") {
|
|
3039
3165
|
const record = value;
|
|
3040
|
-
if ("startDate"
|
|
3166
|
+
if (Object.keys(record).every((key) => key === "startDate" || key === "endDate")) {
|
|
3041
3167
|
const { startDate, endDate } = record;
|
|
3042
3168
|
return (startDate == null || typeof startDate === "string") && (endDate == null || typeof endDate === "string");
|
|
3043
3169
|
}
|
|
@@ -3127,6 +3253,7 @@ function isDraftRuleValue(rule, registry) {
|
|
|
3127
3253
|
if (isValuelessOperator(rule.operator)) return false;
|
|
3128
3254
|
const field = registry.get(rule.fieldId);
|
|
3129
3255
|
if (!field) return false;
|
|
3256
|
+
if (isRangeOperator(rule.operator)) return !isCompleteDateRange(rule.value);
|
|
3130
3257
|
switch (field.type) {
|
|
3131
3258
|
case "multi_choices":
|
|
3132
3259
|
case "tags_conditions": return Array.isArray(rule.value) && rule.value.length === 0;
|
|
@@ -3141,18 +3268,14 @@ function isRuleAllowed(rule, registry, options = { allowDraftValues: false }) {
|
|
|
3141
3268
|
if (!registry.operatorsFor(rule.fieldId).includes(rule.operator)) return false;
|
|
3142
3269
|
if (isValuelessOperator(rule.operator)) return rule.value == null;
|
|
3143
3270
|
if (options.allowDraftValues && isDraftRuleValue(rule, registry)) return true;
|
|
3271
|
+
if (isRangeOperator(rule.operator)) return isCompleteDateRange(rule.value);
|
|
3144
3272
|
if (registry.get(rule.fieldId)?.type === "boolean") return typeof rule.value === "boolean";
|
|
3145
3273
|
if (registry.get(rule.fieldId)?.type === "date") return typeof rule.value === "string" && rule.value.length > 0;
|
|
3146
3274
|
if (registry.get(rule.fieldId)?.type === "multi_choices") {
|
|
3147
3275
|
if (Array.isArray(rule.value)) return rule.value.length > 0;
|
|
3148
3276
|
return typeof rule.value === "string" && rule.value.length > 0;
|
|
3149
3277
|
}
|
|
3150
|
-
if (registry.get(rule.fieldId)?.type === "date_range")
|
|
3151
|
-
const value = rule.value;
|
|
3152
|
-
if (value == null || typeof value !== "object" || Array.isArray(value)) return false;
|
|
3153
|
-
const { startDate, endDate } = value;
|
|
3154
|
-
return typeof startDate === "string" && startDate.length > 0 && typeof endDate === "string" && endDate.length > 0;
|
|
3155
|
-
}
|
|
3278
|
+
if (registry.get(rule.fieldId)?.type === "date_range") return isCompleteDateRange(rule.value);
|
|
3156
3279
|
if (registry.get(rule.fieldId)?.type === "tags_conditions") return Array.isArray(rule.value) && rule.value.length > 0;
|
|
3157
3280
|
return rule.value != null && typeof rule.value !== "boolean";
|
|
3158
3281
|
}
|
|
@@ -3171,16 +3294,13 @@ function hasCompleteValue(rule, registry) {
|
|
|
3171
3294
|
if (isValuelessOperator(rule.operator)) return rule.value == null;
|
|
3172
3295
|
const { value } = rule;
|
|
3173
3296
|
if (value == null) return false;
|
|
3297
|
+
if (isRangeOperator(rule.operator)) return isCompleteDateRange(value);
|
|
3174
3298
|
switch (registry.get(rule.fieldId)?.type) {
|
|
3175
3299
|
case "boolean": return typeof value === "boolean";
|
|
3176
3300
|
case "date": return typeof value === "string" && value.length > 0;
|
|
3177
3301
|
case "multi_choices": return Array.isArray(value) ? value.length > 0 : typeof value === "string" && value.length > 0;
|
|
3178
3302
|
case "tags_conditions": return Array.isArray(value) && value.length > 0;
|
|
3179
|
-
case "date_range":
|
|
3180
|
-
if (typeof value !== "object" || Array.isArray(value)) return false;
|
|
3181
|
-
const { startDate, endDate } = value;
|
|
3182
|
-
return typeof startDate === "string" && startDate.length > 0 && typeof endDate === "string" && endDate.length > 0;
|
|
3183
|
-
}
|
|
3303
|
+
case "date_range": return isCompleteDateRange(value);
|
|
3184
3304
|
default:
|
|
3185
3305
|
if (typeof value === "string") return value.length > 0;
|
|
3186
3306
|
if (Array.isArray(value)) return value.length > 0;
|
|
@@ -3495,7 +3615,7 @@ function useStableFieldIds(fieldIds) {
|
|
|
3495
3615
|
if (previous == null || fieldIds == null || previous.length !== fieldIds.length || fieldIds.some((id, index) => previous[index] !== id)) stable.current = fieldIds;
|
|
3496
3616
|
return stable.current;
|
|
3497
3617
|
}
|
|
3498
|
-
function FilterBar({ registry, initialState, onChange, advancedRulesEnabled = true, singleUseFields = false, size = "md", valueControlResolver
|
|
3618
|
+
function FilterBar({ registry, initialState, onChange, advancedRulesEnabled = true, singleUseFields = false, size = "md", valueControlResolver }) {
|
|
3499
3619
|
const filterState = useFilterStateV2({
|
|
3500
3620
|
registry,
|
|
3501
3621
|
initialState,
|
|
@@ -3622,7 +3742,7 @@ function FilterBar({ registry, initialState, onChange, advancedRulesEnabled = tr
|
|
|
3622
3742
|
enabled: true,
|
|
3623
3743
|
isOpen: rulesPopoverOpen
|
|
3624
3744
|
})
|
|
3625
|
-
}) : null, hasPills ? /* @__PURE__ */ jsxs(Fragment
|
|
3745
|
+
}) : null, hasPills ? /* @__PURE__ */ jsxs(Fragment, { children: [filterState.advancedRulesEnabled ? /* @__PURE__ */ jsx(Divider, {
|
|
3626
3746
|
"aria-hidden": "true",
|
|
3627
3747
|
$size: size
|
|
3628
3748
|
}) : null, /* @__PURE__ */ jsxs(PillsScrollRegion, {
|
|
@@ -3644,7 +3764,7 @@ function FilterBar({ registry, initialState, onChange, advancedRulesEnabled = tr
|
|
|
3644
3764
|
filterState.updateTopLevelRule(rule.id, {
|
|
3645
3765
|
...rule,
|
|
3646
3766
|
operator: op,
|
|
3647
|
-
value:
|
|
3767
|
+
value: reconcileValueForOperator(field, op, rule.operator, rule.value)
|
|
3648
3768
|
});
|
|
3649
3769
|
},
|
|
3650
3770
|
valueControlSlot: resolveValueControl({
|
|
@@ -3660,7 +3780,6 @@ function FilterBar({ registry, initialState, onChange, advancedRulesEnabled = tr
|
|
|
3660
3780
|
onClose: () => setEditingRuleId(null),
|
|
3661
3781
|
open: isOpen,
|
|
3662
3782
|
onOpenChange: (open) => setEditingRuleId(open ? rule.id : null),
|
|
3663
|
-
portalContainer,
|
|
3664
3783
|
trigger: /* @__PURE__ */ jsx(FilterPill, {
|
|
3665
3784
|
ref: (node) => {
|
|
3666
3785
|
if (node) pillNodesRef.current.set(rule.id, node);
|
|
@@ -3926,6 +4045,6 @@ function normalizeFieldSource(raw) {
|
|
|
3926
4045
|
return raw === "system" ? "system" : "custom";
|
|
3927
4046
|
}
|
|
3928
4047
|
//#endregion
|
|
3929
|
-
export { DataTableCompactBar as S,
|
|
4048
|
+
export { TableViewConfigurationDropdown as C, DataTableCompactBar as E, TableViewConfiguration as S, ControlBar as T, isValuelessOperator as _, hasCompleteValue as a, TableControlsProvider as b, EMPTY_FILTER_STATE as c, emptyValueForRule as d, getDefaultOperatorForType as f, isRangeOperator as g, isCompleteDateRange as h, useFilterStateV2 as i, resolveValueControl as l, getOperatorsForType as m, buildFieldRegistry as n, isFilterStateV2 as o, getOperatorsForField as p, FilterBar_default as r, pruneToRegistry as s, FieldRegistry as t, useFilterBarSize as u, reconcileValueForOperator as v, TableControls as w, useTableControls as x, TableControlsContext as y };
|
|
3930
4049
|
|
|
3931
|
-
//# sourceMappingURL=TableControls-
|
|
4050
|
+
//# sourceMappingURL=TableControls-CZ9iu3ma.mjs.map
|