@servicetitan/anvil2 1.45.2 → 1.46.1

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.
Files changed (109) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/{Calendar-BK861SAW.js → Calendar-BQ5F2ENO.js} +2 -2
  3. package/dist/{Calendar-BK861SAW.js.map → Calendar-BQ5F2ENO.js.map} +1 -1
  4. package/dist/Calendar.js +1 -1
  5. package/dist/{Checkbox-ZphVb1l0.js → Checkbox-DDrmVC-u.js} +2 -2
  6. package/dist/{Checkbox-ZphVb1l0.js.map → Checkbox-DDrmVC-u.js.map} +1 -1
  7. package/dist/{Checkbox-CYNjFdtO.js → Checkbox-Dl4KTwEJ.js} +2 -2
  8. package/dist/{Checkbox-CYNjFdtO.js.map → Checkbox-Dl4KTwEJ.js.map} +1 -1
  9. package/dist/Checkbox.js +2 -2
  10. package/dist/{useInfiniteCombobox-BaYWUxjg.js → Combobox-B9nesJuc.js} +18 -185
  11. package/dist/Combobox-B9nesJuc.js.map +1 -0
  12. package/dist/Combobox.js +2 -1
  13. package/dist/Combobox.js.map +1 -1
  14. package/dist/{DateField-DnasO2rB.js → DateField-DXxPsRtf.js} +2 -2
  15. package/dist/{DateField-DnasO2rB.js.map → DateField-DXxPsRtf.js.map} +1 -1
  16. package/dist/DateField.js +1 -1
  17. package/dist/{DateFieldRange-Ba-8T-Nz.js → DateFieldRange-Xauviu1w.js} +6 -6
  18. package/dist/DateFieldRange-Xauviu1w.js.map +1 -0
  19. package/dist/DateFieldRange.js +1 -1
  20. package/dist/{DateFieldSingle-BBu5Hi9c.js → DateFieldSingle-yLnwpVzd.js} +4 -4
  21. package/dist/{DateFieldSingle-BBu5Hi9c.js.map → DateFieldSingle-yLnwpVzd.js.map} +1 -1
  22. package/dist/DateFieldSingle.js +1 -1
  23. package/dist/Dnd.js +1 -1
  24. package/dist/DndSort.js +1 -1
  25. package/dist/{ListView-DEAMQopB.js → ListView-pb3rIcze.js} +2 -2
  26. package/dist/{ListView-DEAMQopB.js.map → ListView-pb3rIcze.js.map} +1 -1
  27. package/dist/ListView.js +1 -1
  28. package/dist/{Menu-C8we5CHP.js → Menu-DEVZz9xZ.js} +8 -3
  29. package/dist/Menu-DEVZz9xZ.js.map +1 -0
  30. package/dist/Menu.js +1 -1
  31. package/dist/{Page-cKXkjMmd.js → Page-BMDkbDcU.js} +2 -2
  32. package/dist/{Page-cKXkjMmd.js.map → Page-BMDkbDcU.js.map} +1 -1
  33. package/dist/Page.js +1 -1
  34. package/dist/{Pagination-ta8a2cJN.js → Pagination-BJsCppgW.js} +2 -2
  35. package/dist/{Pagination-ta8a2cJN.js.map → Pagination-BJsCppgW.js.map} +1 -1
  36. package/dist/Pagination.js +1 -1
  37. package/dist/{SearchField-BKXkoWPs.js → SearchField-Bb0uObwG.js} +2 -2
  38. package/dist/{SearchField-BKXkoWPs.js.map → SearchField-Bb0uObwG.js.map} +1 -1
  39. package/dist/SearchField.js +1 -1
  40. package/dist/{SelectCard-BWh8Yp7T.js → SelectCard-BTYZg9TG.js} +2 -2
  41. package/dist/{SelectCard-BWh8Yp7T.js.map → SelectCard-BTYZg9TG.js.map} +1 -1
  42. package/dist/SelectCard.js +1 -1
  43. package/dist/Toolbar-D4zuUFhb.js +2077 -0
  44. package/dist/Toolbar-D4zuUFhb.js.map +1 -0
  45. package/dist/Toolbar.css +139 -28
  46. package/dist/Toolbar.d.ts +3 -3
  47. package/dist/Toolbar.js +1 -1
  48. package/dist/assets/icons/st/gnav_legacy_search_filled.svg +1 -1
  49. package/dist/assets/icons/st/gnav_legacy_search_outline.svg +1 -1
  50. package/dist/beta/components/Toolbar/Filters/FilterButton.d.ts +30 -0
  51. package/dist/beta/components/Toolbar/Filters/FilterDateRange.d.ts +37 -0
  52. package/dist/beta/components/Toolbar/Filters/FilterDateSingle.d.ts +30 -0
  53. package/dist/beta/components/Toolbar/Filters/FilterDrawer.d.ts +15 -0
  54. package/dist/beta/components/Toolbar/Filters/FilterGroup.d.ts +25 -0
  55. package/dist/beta/components/Toolbar/Filters/FilterItemWrapper.d.ts +24 -0
  56. package/dist/beta/components/Toolbar/Filters/FilterSelect.d.ts +29 -0
  57. package/dist/beta/components/Toolbar/Filters/FilterToggleButton.d.ts +24 -0
  58. package/dist/beta/components/Toolbar/Filters/internal/FilterGroupContext.d.ts +40 -0
  59. package/dist/beta/components/Toolbar/Filters/internal/types.d.ts +130 -0
  60. package/dist/beta/components/Toolbar/Filters/internal/utils/filter-state.d.ts +40 -0
  61. package/dist/beta/components/Toolbar/Filters/internal/utils/test.d.ts +57 -0
  62. package/dist/beta/components/Toolbar/Toolbar.d.ts +302 -0
  63. package/dist/beta/components/Toolbar/ToolbarButton.d.ts +41 -0
  64. package/dist/beta/components/Toolbar/ToolbarButtonLink.d.ts +43 -0
  65. package/dist/beta/components/Toolbar/ToolbarButtonToggle.d.ts +42 -0
  66. package/dist/beta/components/Toolbar/ToolbarControlGroup.d.ts +20 -0
  67. package/dist/beta/components/Toolbar/ToolbarSearchField.d.ts +20 -0
  68. package/dist/beta/components/Toolbar/ToolbarSelect.d.ts +108 -0
  69. package/dist/beta/components/Toolbar/index.d.ts +9 -0
  70. package/dist/beta/components/Toolbar/internal/ToolbarItemOverflowContext.d.ts +19 -0
  71. package/dist/beta/components/Toolbar/internal/ToolbarItemWrapper.d.ts +40 -0
  72. package/dist/beta/components/Toolbar/internal/ToolbarOverflowContext.d.ts +35 -0
  73. package/dist/beta/components/Toolbar/internal/ToolbarOverflowMenu.d.ts +29 -0
  74. package/dist/beta/components/Toolbar/internal/utils/accessibility.d.ts +26 -0
  75. package/dist/beta/components/Toolbar/internal/utils/test.d.ts +29 -0
  76. package/dist/beta/components/Toolbar/types.d.ts +50 -0
  77. package/dist/beta/components/index.d.ts +1 -0
  78. package/dist/beta/index.d.ts +1 -0
  79. package/dist/beta.d.ts +2 -0
  80. package/dist/beta.js +2 -0
  81. package/dist/beta.js.map +1 -0
  82. package/dist/components/Combobox/ComboboxTypes.d.ts +8 -0
  83. package/dist/components/DateFieldRange/internal/DateFieldRangeCalendar.d.ts +1 -1
  84. package/dist/components/Dialog/index.d.ts +1 -1
  85. package/dist/{indeterminate_check_box-Bg24oeHy.js → indeterminate_check_box-RY9zr3xS.js} +17 -17
  86. package/dist/{indeterminate_check_box-Bg24oeHy.js.map → indeterminate_check_box-RY9zr3xS.js.map} +1 -1
  87. package/dist/indeterminate_check_box.css +72 -66
  88. package/dist/{index-CqdP5W00.js → index-V5Ez2gq_.js} +2 -2
  89. package/dist/{index-CqdP5W00.js.map → index-V5Ez2gq_.js.map} +1 -1
  90. package/dist/index.css +125 -26
  91. package/dist/index.js +759 -27
  92. package/dist/index.js.map +1 -1
  93. package/dist/index2.css +88 -105
  94. package/dist/internal/hooks/index.d.ts +1 -0
  95. package/dist/internal/hooks/useContainerQuery/index.d.ts +1 -0
  96. package/dist/internal/hooks/useContainerQuery/useContainerQuery.d.ts +46 -0
  97. package/dist/{useDateFieldOrchestration-DPLftOxu.js → useDateFieldOrchestration-BNJCsRkS.js} +2 -2
  98. package/dist/{useDateFieldOrchestration-DPLftOxu.js.map → useDateFieldOrchestration-BNJCsRkS.js.map} +1 -1
  99. package/dist/useInfiniteCombobox-WcRgC9p6.js +179 -0
  100. package/dist/useInfiniteCombobox-WcRgC9p6.js.map +1 -0
  101. package/dist/useIntersectionObserver-BEmMDO3P.js +70 -0
  102. package/dist/useIntersectionObserver-BEmMDO3P.js.map +1 -0
  103. package/package.json +2 -1
  104. package/dist/DateFieldRange-Ba-8T-Nz.js.map +0 -1
  105. package/dist/Menu-C8we5CHP.js.map +0 -1
  106. package/dist/Toolbar-DK7tXy_W.js +0 -807
  107. package/dist/Toolbar-DK7tXy_W.js.map +0 -1
  108. package/dist/useInfiniteCombobox-BaYWUxjg.js.map +0 -1
  109. /package/dist/{useInfiniteCombobox.css → Combobox.css} +0 -0
package/dist/Toolbar.css CHANGED
@@ -11,17 +11,24 @@ button[data-anv=toolbar-select] {
11
11
  /* REVERT LAYER BUGFIX END */
12
12
  /* -- Toolbar Base */
13
13
  @layer base {
14
- ._toolbar_7lbdr_13 {
15
- gap: 0.75rem;
16
- }
17
- ._toolbar_7lbdr_13[aria-orientation=vertical] {
14
+ ._toolbar_bslcr_13[aria-orientation=vertical] {
18
15
  height: 100%;
19
16
  max-height: inherit;
20
17
  }
21
- ._toolbar-content_7lbdr_20 {
22
- gap: 0.25rem;
18
+ ._toolbar-outline-spacer_bslcr_17:not(:has([data-anv=toolbar-filter-group], [data-anv=toolbar-control-group])) {
19
+ padding: 0.25rem;
20
+ }
21
+ ._toolbar-content_bslcr_20 {
22
+ align-items: flex-start;
23
+ width: 100%;
23
24
  }
24
- ._toolbar-overflow-content_7lbdr_23 {
25
+ ._overflow-wrap_bslcr_24 {
26
+ flex-wrap: wrap;
27
+ }
28
+ ._overflow-collapse_bslcr_27 {
29
+ flex-wrap: nowrap;
30
+ }
31
+ ._toolbar-overflow-content_bslcr_30 {
25
32
  display: flex;
26
33
  flex-direction: column;
27
34
  gap: 0.75rem;
@@ -29,54 +36,158 @@ button[data-anv=toolbar-select] {
29
36
  padding: 0.5rem !important;
30
37
  margin: 0 !important;
31
38
  }
32
- ._toolbar-overflow-content_7lbdr_23 ._toolbar-button-item_7lbdr_31 {
39
+ ._toolbar-overflow-content_bslcr_30 ._toolbar-button-item_bslcr_38 {
33
40
  width: 100%;
34
41
  }
35
42
  }
36
43
  /* -- Toolbar Overflow and Orientation States */
37
44
  @layer state {
38
- [aria-orientation=vertical] ._toolbar-item_7lbdr_37,
39
- [aria-orientation=vertical] ._toolbar-button-item_7lbdr_31 {
45
+ [aria-orientation=vertical] ._toolbar-item_bslcr_44,
46
+ [aria-orientation=vertical] ._toolbar-button-item_bslcr_38 {
40
47
  width: 100%;
41
48
  }
42
- ._overflow-collapse_7lbdr_41 {
49
+ ._overflow-collapse_bslcr_27 {
43
50
  overflow: hidden;
44
51
  }
45
- [aria-orientation=horizontal] ._overflow-collapse_7lbdr_41 ._toolbar-item_7lbdr_37 {
46
- padding-block: 0.25rem;
47
- }
48
- [aria-orientation=horizontal] ._overflow-collapse_7lbdr_41 ._toolbar-item_7lbdr_37:first-of-type {
49
- padding-inline-start: 0.25rem;
50
- }
51
- [aria-orientation=vertical] ._overflow-collapse_7lbdr_41 {
52
+ [aria-orientation=vertical] ._overflow-collapse_bslcr_27 {
52
53
  height: 100%;
53
54
  }
54
- [aria-orientation=vertical] ._overflow-collapse_7lbdr_41 ._toolbar-item_7lbdr_37:first-of-type {
55
- padding-block-start: 0.25rem;
56
- }
57
55
  }
58
56
  /* -- Toolbar Items Component Overrides */
59
57
  @layer application {
60
- ._toolbar-button-item_7lbdr_31 {
58
+ ._toolbar-button-item_bslcr_38 {
61
59
  white-space: nowrap;
62
60
  font-size: 0.75rem;
63
61
  min-width: -moz-min-content;
64
62
  min-width: min-content;
65
63
  padding: 0.375rem;
66
64
  }
67
- ._toolbar-button-toggle-item_7lbdr_65[aria-pressed=false] {
65
+ ._toolbar-button-toggle-item_bslcr_63[aria-pressed=false] {
68
66
  border-color: var(--button-primary-foreground-color, #ffffff);
69
67
  }
70
- ._toolbar-button-toggle-item_7lbdr_65[aria-pressed=true] {
68
+ ._toolbar-button-toggle-item_bslcr_63[aria-pressed=true] {
71
69
  border-color: var(--background-color-primary-subdued, #E0F2FF);
72
70
  }
73
- ._toolbar-overflow-trigger_7lbdr_71 {
71
+ ._toolbar-overflow-trigger_bslcr_69 {
74
72
  padding: 0.5rem;
75
73
  }
76
- ._toolbar-overflow-trigger_7lbdr_71[aria-expanded=true] {
74
+ ._toolbar-overflow-trigger_bslcr_69[aria-expanded=true] {
77
75
  --button-background-color: var(--button-ghost-background-color-hover, rgba(20, 20, 20, 0.0784313725));
78
76
  }
79
- [aria-orientation=vertical] ._toolbar-overflow-trigger_7lbdr_71 {
80
- width: 100%;
77
+ }@layer starter, reset, base, state, application;
78
+
79
+ button[data-anv=toolbar-button],
80
+ a[data-anv=toolbar-button-link],
81
+ button[data-anv=toolbar-button-toggle],
82
+ button[data-anv=filter-group-drawer-trigger],
83
+ button[data-anv=toolbar-boolean-filter],
84
+ button[data-anv=toolbar-select] {
85
+ all: revert-layer;
86
+ line-height: 1rem;
87
+ }
88
+
89
+ [data-anv=filter-group-drawer] > section,
90
+ [data-anv=filter-button-apply],
91
+ [data-anv=filter-button-content] {
92
+ all: revert-layer;
93
+ }
94
+
95
+ @layer base {
96
+ ._filter-button-trigger_320zf_18 {
97
+ font-size: 0.75rem;
98
+ white-space: nowrap;
99
+ }
100
+ ._filter-button-content_320zf_22 {
101
+ min-width: 12.5rem;
102
+ max-width: 22.5rem;
103
+ }
104
+ ._filter-drawer-trigger_320zf_26 {
105
+ position: sticky;
106
+ right: 0;
107
+ border: none;
108
+ }
109
+ ._filter-button-buttons_320zf_31 {
110
+ padding-block-start: 1rem;
111
+ }
112
+ [data-anv=toolbar-filter-group] {
113
+ container-type: inline-size;
114
+ }
115
+ ._filter-item_320zf_37 {
116
+ max-height: 1.75rem;
117
+ }
118
+ @container (max-width: primitive.$breakpoint-md) {
119
+ ._filter-item_320zf_37 {
120
+ display: none;
121
+ }
122
+ }
123
+ ._filter-select-search_320zf_45 {
124
+ padding-block-end: 1rem;
125
+ }
126
+ }
127
+ @layer application {
128
+ ._filter-button-trigger_320zf_18 {
129
+ max-height: 1.75rem;
130
+ padding: 0.3125rem 0.375rem;
131
+ }
132
+ ._filter-button-trigger_320zf_18[aria-expanded=true]:not(._filter-button-trigger--selected_320zf_54) {
133
+ --button-background-color: var(--button-ghost-background-color-hover, rgba(20, 20, 20, 0.0784313725));
134
+ }
135
+ ._filter-button-trigger--selected_320zf_54 {
136
+ --button-background-color: var(--background-color-primary-subdued, #E0F2FF);
137
+ color: var(--foreground-color-primary, #0265DC);
138
+ }
139
+ ._filter-drawer-trigger_320zf_26 {
140
+ padding-inline: 0.5rem;
141
+ }
142
+ ._filter-drawer-trigger--chipped_320zf_64 {
143
+ background-color: var(--background-color-primary-subdued, #E0F2FF);
144
+ color: var(--foreground-color-primary, #0265DC);
145
+ min-width: -moz-max-content;
146
+ min-width: max-content;
147
+ }
148
+ }@layer starter, reset, base, state, application;
149
+ @layer base {
150
+ ._toolbar-control-group_13h8p_2 {
151
+ overflow: hidden;
152
+ flex: var(--toolbar-group-flex);
153
+ flex-wrap: var(--toolbar-group-wrap, wrap);
154
+ padding-block: 0.5rem;
155
+ padding-inline: 0.25rem;
156
+ }
157
+ ._toolbar-control-group_13h8p_2[data-anv=toolbar-filter-group] {
158
+ min-width: 5.625rem;
159
+ }
160
+ ._toolbar-control-group_13h8p_2[data-anv=toolbar-control-group] {
161
+ justify-content: flex-end;
162
+ }
163
+ [data-anv=toolbar-content]:has(._toolbar-control-group_13h8p_2) {
164
+ flex-wrap: nowrap;
165
+ }
166
+ [data-anv=toolbar-content]:has(._toolbar-control-group_13h8p_2)[data-overflow=collapse] > [data-anv=toolbar-filter-group] {
167
+ --toolbar-group-flex: 1 0 0;
168
+ --toolbar-group-wrap: nowrap;
169
+ }
170
+ [data-anv=toolbar-content]:has(._toolbar-control-group_13h8p_2)[data-overflow=collapse] > [data-anv=toolbar-control-group] {
171
+ --toolbar-group-flex: 0 1 auto;
172
+ --toolbar-group-wrap: nowrap;
173
+ }
174
+ [data-anv=toolbar-content]:has(._toolbar-control-group_13h8p_2)[data-overflow=wrap] > [data-anv=toolbar-filter-group] {
175
+ --toolbar-group-flex: 1 0 0;
176
+ }
177
+ [data-anv=toolbar-content]:has(._toolbar-control-group_13h8p_2)[data-overflow=wrap] > [data-anv=toolbar-control-group] {
178
+ --toolbar-group-flex: 0 1 auto;
179
+ }
180
+ }@layer starter, reset, base, state, application;
181
+ @layer application {
182
+ ._toolbar-search-field-container_9jh3s_2 {
183
+ padding-block: 0.5rem;
184
+ }
185
+ ._toolbar-search-field_9jh3s_2 {
186
+ height: 1.75rem;
187
+ max-width: 12.5rem;
188
+ padding-inline-start: 0.25rem;
189
+ }
190
+ ._toolbar-search-field_9jh3s_2 input {
191
+ padding-block: 0;
81
192
  }
82
193
  }
package/dist/Toolbar.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- export * from './components/Toolbar/index'
1
+ export * from './beta/components/Toolbar/index'
2
2
  export {}
3
- import _default from './components/Toolbar/index'
3
+ import _default from './beta/components/Toolbar/index'
4
4
  export default _default
5
- export * from './components/Toolbar/index'
5
+ export * from './beta/components/Toolbar/index'
6
6
  export {}
package/dist/Toolbar.js CHANGED
@@ -1,2 +1,2 @@
1
- export { T as Toolbar, a as ToolbarButton, c as ToolbarButtonLink, b as ToolbarButtonToggle, e as ToolbarElement, d as ToolbarSelect, T as default } from './Toolbar-DK7tXy_W.js';
1
+ export { T as Toolbar, a as ToolbarButton, c as ToolbarButtonLink, b as ToolbarButtonToggle, e as ToolbarControlGroup, g as ToolbarElement, f as ToolbarSearchField, d as ToolbarSelect, T as default } from './Toolbar-D4zuUFhb.js';
2
2
  //# sourceMappingURL=Toolbar.js.map
@@ -1 +1 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill-rule="evenodd" d="M22.395 20.801c.29-.185.486-.488.567-.86.08-.371.034-.72-.15-1.01l-3.26-5.16a6.2 6.2 0 0 0 1.225-1.557c.324-.604.578-1.22.717-1.859.404-1.847.104-3.579-.913-5.17-1.006-1.592-2.427-2.592-4.265-3.01q-2.774-.61-5.132.906c-1.595 1.011-2.6 2.452-3.005 4.3-.416 1.836-.104 3.567.902 5.17 1.005 1.58 2.427 2.592 4.276 2.998a6.6 6.6 0 0 0 1.965.151 6.2 6.2 0 0 0 1.953-.464l3.26 5.147c.184.29.462.5.843.581.37.082.705.023 1.017-.163M14.43 4.503a1 1 0 0 0 .142 1.995 2.12 2.12 0 0 1 2.267 1.968 1 1 0 0 0 1.995-.131 4.12 4.12 0 0 0-4.404-3.832" clip-rule="evenodd"/><path d="M5.5 4h-3a1.5 1.5 0 1 0 0 3h3a1.5 1.5 0 1 0 0-3m0 7h-3a1.5 1.5 0 0 0 0 3h3a1.5 1.5 0 0 0 0-3m6 7h-9a1.5 1.5 0 0 0 0 3h9a1.5 1.5 0 0 0 0-3"/></svg>
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M4.9 7.701H1.225a1.231 1.231 0 0 1 0-2.46H4.9a1.231 1.231 0 0 1 0 2.46m0 3.691H1.225a1.231 1.231 0 0 0 0 2.46H4.9a1.231 1.231 0 0 0 0-2.46m17.002 7.739-3.822-3.839a6.08 6.08 0 0 1-3.674 1.01c-2.904-.136-5.39-2.412-5.782-5.304a6.2 6.2 0 0 1 1.827-5.27 6.14 6.14 0 0 1 5.314-1.632c2.389.406 4.373 2.276 4.9 4.65a6.17 6.17 0 0 1-.857 4.8l3.834 3.85a1.229 1.229 0 0 1-1.74 1.735m-3.528-8.97c0-2.03-1.653-3.69-3.674-3.69s-3.675 1.66-3.675 3.69 1.653 3.692 3.675 3.692c2.02 0 3.674-1.661 3.674-3.691M1.225 20.005h9.8a1.231 1.231 0 0 0 0-2.46h-9.8a1.231 1.231 0 0 0 0 2.46"/><path fill-rule="evenodd" d="M23.652 19.14c.218-.22.33-.523.33-.865-.003-.34-.111-.638-.329-.856L19.79 13.53c.341-.49.601-1.03.77-1.603.167-.593.27-1.182.267-1.77-.006-1.697-.606-3.157-1.808-4.354-1.192-1.2-2.632-1.799-4.325-1.807Q12.144 4 10.372 5.79C9.17 6.987 8.57 8.446 8.575 10.145c-.007 1.69.604 3.147 1.798 4.356 1.19 1.19 2.633 1.8 4.333 1.795a6 6 0 0 0 1.752-.25 5.6 5.6 0 0 0 1.622-.788l3.86 3.877c.218.219.502.348.852.345.34 0 .623-.117.86-.34M13.494 6.403a.898.898 0 0 0 .514 1.721 1.903 1.903 0 0 1 2.37 1.284.898.898 0 0 0 1.724-.504 3.7 3.7 0 0 0-4.608-2.501" clip-rule="evenodd"/></svg>
@@ -1 +1 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="m22.812 18.95-3.276-5.157a6.2 6.2 0 0 0 1.258-1.573c.334-.59.565-1.202.715-1.85.403-1.861.103-3.584-.888-5.168-1.015-1.596-2.445-2.614-4.28-3.018-1.845-.417-3.563-.128-5.155.89-1.591 1.018-2.595 2.44-3.01 4.29-.404 1.85-.115 3.573.888 5.168 1.015 1.596 2.434 2.602 4.279 3.018a7.1 7.1 0 0 0 1.984.14 5.9 5.9 0 0 0 1.937-.452l3.264 5.146c.185.3.473.497.842.578.38.08.727.034 1.015-.15.3-.197.496-.486.577-.856.08-.382.034-.729-.15-1.018zm-3.98-9.181c-.241 1.121-.841 1.977-1.798 2.59-.958.601-1.996.786-3.103.52-1.118-.242-1.972-.844-2.583-1.803-.612-.96-.785-1.99-.53-3.11.253-1.11.853-1.967 1.81-2.58.957-.612 1.984-.786 3.102-.531 1.108.242 1.961.844 2.572 1.803.612.96.785 2 .53 3.11M5.5 4h-3a1.5 1.5 0 1 0 0 3h3a1.5 1.5 0 1 0 0-3m0 7h-3a1.5 1.5 0 0 0 0 3h3a1.5 1.5 0 0 0 0-3m6 7h-9a1.5 1.5 0 0 0 0 3h9a1.5 1.5 0 0 0 0-3"/></svg>
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M4.9 7.697H1.225a1.231 1.231 0 0 1 0-2.46H4.9a1.231 1.231 0 0 1 0 2.46m0 3.69H1.225a1.231 1.231 0 0 0 0 2.461H4.9a1.231 1.231 0 0 0 0-2.46m17.002 7.74-3.822-3.84a6.08 6.08 0 0 1-3.674 1.01c-2.904-.136-5.39-2.412-5.782-5.303a6.2 6.2 0 0 1 1.827-5.27 6.13 6.13 0 0 1 5.314-1.632c2.389.406 4.373 2.276 4.9 4.65a6.17 6.17 0 0 1-.857 4.799l3.834 3.85a1.23 1.23 0 0 1-1.74 1.736m-3.528-8.97c0-2.03-1.653-3.69-3.674-3.69s-3.675 1.66-3.675 3.69 1.653 3.691 3.675 3.691c2.02 0 3.674-1.66 3.674-3.69M1.225 20h9.8a1.231 1.231 0 0 0 0-2.46h-9.8a1.231 1.231 0 0 0 0 2.46"/></svg>
@@ -0,0 +1,30 @@
1
+ import { ReactNode } from 'react';
2
+ import { Filter } from './internal/types';
3
+ /**
4
+ * Props for the FilterButton component
5
+ */
6
+ interface FilterButtonProps {
7
+ /** Filter configuration object */
8
+ filter: Filter;
9
+ /** Optional child content for non-custom filter types */
10
+ children?: ReactNode;
11
+ /** Optional class name for the popover content */
12
+ className?: string;
13
+ }
14
+ /**
15
+ * FilterButton component provides a popover interface for filter selection.
16
+ * Handles both controlled and uncontrolled filter updates.
17
+ * Built into FilterGroup for single-select, multi-select, date, and date range filter rendering.
18
+ *
19
+ * Features:
20
+ * - Maintains draft state for controlled filters
21
+ * - Updates immediately for uncontrolled filters
22
+ * - Provides Apply and Cancel actions in controlled mode
23
+ * - Supports keyboard navigation and accessibility
24
+ * - Renders custom, single-select, multi-select, date, and date range filter types
25
+ * - Integrates with FilterGroup context for state management
26
+ * - Displays appropriate icons for date-based filters
27
+ * - Shows formatted date values in button labels
28
+ */
29
+ export declare const FilterButton: ({ filter, children, className, }: FilterButtonProps) => import("react/jsx-runtime").JSX.Element;
30
+ export {};
@@ -0,0 +1,37 @@
1
+ import { DateRangeFilter } from './internal/types';
2
+ /**
3
+ * Props for the FilterDateRange component
4
+ */
5
+ interface FilterDateRangeProps {
6
+ /**
7
+ * The date range filter configuration object containing mode and other settings
8
+ */
9
+ filter: DateRangeFilter;
10
+ /**
11
+ * The current draft value for the date range filter with start and end dates in ISO 8601 format
12
+ */
13
+ draftValue: {
14
+ startDate: string | null;
15
+ endDate: string | null;
16
+ } | null;
17
+ /**
18
+ * Callback function to update the draft value when the date range changes
19
+ */
20
+ onDraftChange: (value: {
21
+ startDate: string | null;
22
+ endDate: string | null;
23
+ } | null) => void;
24
+ }
25
+ /**
26
+ * FilterDateRange component for selecting a date range in toolbar filters.
27
+ *
28
+ * Features:
29
+ * - Renders a masked date range input field with format validation
30
+ * - Provides calendar popup for date range selection
31
+ * - Integrates with toolbar filter state management
32
+ * - Supports controlled and uncontrolled date range selection
33
+ * - Maintains draft state for filter changes
34
+ * - Handles start and end date selection independently
35
+ */
36
+ export declare const FilterDateRange: ({ filter, draftValue, onDraftChange, }: FilterDateRangeProps) => import("react/jsx-runtime").JSX.Element;
37
+ export {};
@@ -0,0 +1,30 @@
1
+ import { DateFilter } from './internal/types';
2
+ /**
3
+ * Props for the FilterDateSingle component
4
+ */
5
+ interface FilterDateSingleProps {
6
+ /**
7
+ * The date filter configuration object containing mode and other settings
8
+ */
9
+ filter: DateFilter;
10
+ /**
11
+ * The current draft value for the date filter in ISO 8601 format
12
+ */
13
+ draftValue: string | null;
14
+ /**
15
+ * Callback function to update the draft value when the date changes
16
+ */
17
+ onDraftChange: (value: string | null) => void;
18
+ }
19
+ /**
20
+ * FilterDateSingle component for selecting a single date in toolbar filters.
21
+ *
22
+ * Features:
23
+ * - Renders a masked date input field with format validation
24
+ * - Provides calendar popup for date selection
25
+ * - Integrates with toolbar filter state management
26
+ * - Supports controlled and uncontrolled date selection
27
+ * - Maintains draft state for filter changes
28
+ */
29
+ export declare const FilterDateSingle: ({ filter, draftValue, onDraftChange, }: FilterDateSingleProps) => import("react/jsx-runtime").JSX.Element;
30
+ export {};
@@ -0,0 +1,15 @@
1
+ /**
2
+ * FilterDrawer component provides a drawer interface for filter selection.
3
+ * Always operates in controlled mode with batch updates.
4
+ * Built into FilterGroup for mobile and overflow filter editing.
5
+ *
6
+ * Features:
7
+ * - Shows all available filters in a side panel
8
+ * - Maintains separate draft state for all filters
9
+ * - Updates filters only when Apply is clicked
10
+ * - Provides Clear All functionality
11
+ * - Supports boolean, custom, single-select, multi-select, date, and date range filter types
12
+ * - Integrates with FilterGroup context for state management
13
+ * - Handles date and date range filters with appropriate input components
14
+ */
15
+ export declare const FilterDrawer: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,25 @@
1
+ import { ComponentPropsWithoutRef } from 'react';
2
+ import { Filter } from './internal/types';
3
+ import { LayoutUtilProps } from '../../../../types';
4
+ /**
5
+ * Props for the FilterGroup component
6
+ *
7
+ * @extends ComponentPropsWithoutRef<"div">
8
+ * @extends LayoutUtilProps
9
+ */
10
+ export type FilterGroupProps = ComponentPropsWithoutRef<"div"> & LayoutUtilProps & {
11
+ /** Array of filter objects */
12
+ filters: Filter[];
13
+ /** Callback function when filters change */
14
+ onFilterChange?: (filters: Filter[]) => void;
15
+ /** Whether the filters are submission is controlled via an apply button */
16
+ controlledFiltering?: boolean;
17
+ };
18
+ export declare const FilterGroup: import('react').ForwardRefExoticComponent<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & LayoutUtilProps & {
19
+ /** Array of filter objects */
20
+ filters: Filter[];
21
+ /** Callback function when filters change */
22
+ onFilterChange?: (filters: Filter[]) => void;
23
+ /** Whether the filters are submission is controlled via an apply button */
24
+ controlledFiltering?: boolean;
25
+ } & import('react').RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,24 @@
1
+ import { Filter } from './internal/types';
2
+ /**
3
+ * Props for the FilterItemWrapper component
4
+ */
5
+ type FilterItemWrapperProps = {
6
+ /**
7
+ * Optional filter object. If provided, visibility changes will be tracked in FilterGroupContext.
8
+ * If not provided, only basic visibility tracking will be used.
9
+ */
10
+ filter?: Filter;
11
+ /** The content to render inside the wrapper */
12
+ children: React.ReactNode;
13
+ };
14
+ /**
15
+ * FilterItemWrapper extends ToolbarItemWrapper to handle filter-specific visibility.
16
+ * Uses FilterGroupContext to track hidden filters instead of overflow menu.
17
+ * Built into FilterButton and other filter components for consistent overflow handling.
18
+ *
19
+ * Features:
20
+ * - Wraps filter controls for consistent overflow and visibility handling
21
+ * - Integrates with FilterGroupContext to track hidden filters
22
+ */
23
+ export declare const FilterItemWrapper: ({ filter, children, }: FilterItemWrapperProps) => import("react/jsx-runtime").JSX.Element;
24
+ export {};
@@ -0,0 +1,29 @@
1
+ import { MultiSelectFilter, SingleSelectFilter } from './internal/types';
2
+ /**
3
+ * Props for the FilterSelect component
4
+ */
5
+ interface FilterSelectProps<Item extends {
6
+ id: string;
7
+ label: string;
8
+ }> {
9
+ /** The filter configuration object */
10
+ filter: SingleSelectFilter<Item> | MultiSelectFilter<Item>;
11
+ /** The current draft value for the filter */
12
+ draftValue: Item | Item[] | undefined;
13
+ /** Callback to update the draft value */
14
+ onDraftChange: (value: Item | Item[] | undefined) => void;
15
+ }
16
+ /**
17
+ * FilterSelect component renders a Listbox or ListView for single or multi-select filters.
18
+ * Built into FilterButton and FilterDrawer for filter selection UI.
19
+ *
20
+ * Features:
21
+ * - Renders a Listbox for single select filters
22
+ * - Renders a ListView for multi select filters
23
+ * - Supports search field for filtering options
24
+ */
25
+ export declare const FilterSelect: <Item extends {
26
+ id: string;
27
+ label: string;
28
+ }>({ filter, draftValue, onDraftChange, }: FilterSelectProps<Item>) => import("react/jsx-runtime").JSX.Element;
29
+ export {};
@@ -0,0 +1,24 @@
1
+ import { ToolbarButtonToggleProps } from '../ToolbarButtonToggle';
2
+ /**
3
+ * Props for the FilterToggleButton component
4
+ *
5
+ * @extends Omit<ToolbarButtonToggleProps, "checked">
6
+ */
7
+ export type FilterToggleButtonProps = Omit<ToolbarButtonToggleProps, "checked"> & {
8
+ /** Unique identifier for the filter */
9
+ id: string;
10
+ /** Whether the toggle is checked */
11
+ checked: boolean;
12
+ /** The content to display inside the toggle button */
13
+ children: React.ReactNode;
14
+ };
15
+ /**
16
+ * FilterToggleButton wraps ToolbarButtonToggle in a FilterItemWrapper for consistent overflow behavior with other filter types.
17
+ * Built into FilterGroup for boolean filter rendering.
18
+ *
19
+ * Features:
20
+ * - Renders a toggle button for boolean filters
21
+ * - Integrates with FilterGroup and FilterItemWrapper for overflow handling
22
+ * - Supports accessibility and keyboard navigation
23
+ */
24
+ export declare const FilterToggleButton: ({ id, checked, children, ...props }: FilterToggleButtonProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,40 @@
1
+ import { RefObject } from 'react';
2
+ import { FilterGroupProps } from '../FilterGroup';
3
+ import { Filter, FilterValue } from './types';
4
+ /**
5
+ * Context for sharing filter state and operations between FilterGroup and its children
6
+ *
7
+ * @extends FilterGroupProps
8
+ */
9
+ type FilterGroupContextProps = FilterGroupProps & {
10
+ /** Reference to the filter group DOM element
11
+ * @default { current: null }
12
+ */
13
+ filterGroupRef: RefObject<HTMLDivElement>;
14
+ /** Current filters array
15
+ * @default []
16
+ */
17
+ filters: Filter[];
18
+ /** Function to update a single filter and submit if needed
19
+ * @default () => {}
20
+ */
21
+ updateFilter: (filterId: string, value: FilterValue, submit: boolean) => void;
22
+ /** Array of filters that are currently hidden due to overflow
23
+ * @default []
24
+ */
25
+ hiddenFilters: Filter[];
26
+ /** Function to mark a filter as hidden
27
+ * @default () => {}
28
+ */
29
+ addHiddenFilter: (filter: Filter) => void;
30
+ /** Function to mark a filter as visible
31
+ * @default () => {}
32
+ */
33
+ removeHiddenFilter: (filter: Filter) => void;
34
+ };
35
+ /**
36
+ * Context provider for filter-related operations
37
+ * Used to share filter state between FilterGroup and FilterDrawer
38
+ */
39
+ export declare const FilterGroupContext: import('react').Context<FilterGroupContextProps>;
40
+ export {};
@@ -0,0 +1,130 @@
1
+ import { ReactNode } from 'react';
2
+ import { DateFieldSingleProps } from '../../../../../components/DateFieldSingle';
3
+ import { DateFieldRangeProps } from '../../../../../components/DateFieldRange';
4
+ /**
5
+ * Base properties shared by all filter types
6
+ */
7
+ export type BaseFilter = {
8
+ /** Unique identifier for the filter */
9
+ id: string;
10
+ /** Display label for the filter */
11
+ label: string;
12
+ };
13
+ /**
14
+ * Built-in boolean filter type
15
+ * Used for simple true/false filtering
16
+ */
17
+ export type BooleanFilter = BaseFilter & {
18
+ /** Identifies this as a boolean filter */
19
+ type: "boolean";
20
+ /** Current state of the boolean filter */
21
+ checked: boolean;
22
+ };
23
+ /**
24
+ * Props passed to custom filter render functions
25
+ */
26
+ export type FilterRenderProps<T = unknown> = {
27
+ /** Current value of the filter */
28
+ value?: T;
29
+ /** Callback to update the filter value */
30
+ onChange: (value?: T) => void;
31
+ };
32
+ /**
33
+ * Custom filter type allowing for complex filter implementations
34
+ */
35
+ export type CustomFilter<T = unknown> = BaseFilter & {
36
+ /** Identifies this as a custom filter */
37
+ type: "custom";
38
+ /** Function to render the filter content in the button/popover */
39
+ buttonRender: (props: FilterRenderProps<T>) => ReactNode;
40
+ /** Function to render the filter content in the drawer */
41
+ drawerRender: (props: FilterRenderProps<T>) => ReactNode;
42
+ /** Current value of the custom filter */
43
+ value?: T;
44
+ /** Optional number to display in a label chip */
45
+ labelChipCount?: number;
46
+ };
47
+ /**
48
+ * Single select filter type using Listbox component with optional search
49
+ */
50
+ export type SingleSelectFilter<Item = {
51
+ id: string;
52
+ label: string;
53
+ }> = BaseFilter & {
54
+ /** Identifies this as a single select filter */
55
+ type: "singleSelect";
56
+ /** Array of items to select from */
57
+ items: Item[];
58
+ /** Currently selected item */
59
+ selectedItem?: Item;
60
+ } & ({
61
+ /** Whether to show the search field */
62
+ hasSearch: true;
63
+ /** Required callback for search functionality when hasSearch is true */
64
+ onSearch: (searchTerm: string) => void;
65
+ /** Optional callback when search is cleared (only used when hasSearch is true) */
66
+ onSearchClear: () => void;
67
+ simpleDrawerVariant?: never;
68
+ } | {
69
+ /** Whether to show the search field */
70
+ hasSearch?: false;
71
+ onSearch?: never;
72
+ onSearchClear?: never;
73
+ /** Whether to use simplified drawer rendering */
74
+ simpleDrawerVariant?: boolean;
75
+ });
76
+ /**
77
+ * Multi select filter type using ListView component with optional search
78
+ */
79
+ export type MultiSelectFilter<Item = {
80
+ id: string;
81
+ label: string;
82
+ }> = BaseFilter & {
83
+ /** Identifies this as a multi select filter */
84
+ type: "multiSelect";
85
+ /** Array of items to select from */
86
+ items: Item[];
87
+ /** Currently selected items array */
88
+ selectedItems: Item[] | [];
89
+ /** Whether to use simplified drawer rendering */
90
+ simpleDrawerVariant?: boolean;
91
+ } & ({
92
+ /** Whether to show the search field */
93
+ hasSearch: true;
94
+ /** Current search value */
95
+ searchValue?: string;
96
+ /** Required callback for search functionality when hasSearch is true */
97
+ onSearch: (searchTerm: string) => void;
98
+ /** Optional callback when search is cleared (only used when hasSearch is true) */
99
+ onSearchClear: () => void;
100
+ simpleDrawerVariant?: never;
101
+ } | {
102
+ /** Whether to show the search field */
103
+ hasSearch?: false;
104
+ searchValue?: never;
105
+ onSearch?: never;
106
+ onSearchClear?: never;
107
+ /** Whether to use simplified drawer rendering */
108
+ simpleDrawerVariant?: boolean;
109
+ });
110
+ /**
111
+ * Single date filter type using DateFieldSingle component
112
+ * Used for selecting a single date with calendar support
113
+ */
114
+ export type DateFilter = BaseFilter & Pick<DateFieldSingleProps, "value" | "mode"> & {
115
+ type: "date";
116
+ };
117
+ /**
118
+ * Date range filter type using DateFieldRange component
119
+ * Used for selecting a date range with calendar support
120
+ */
121
+ export type DateRangeFilter = BaseFilter & Pick<DateFieldRangeProps, "value" | "mode"> & {
122
+ type: "dateRange";
123
+ };
124
+ /**
125
+ * Union type of all available filter types
126
+ * Uses unknown instead of any for better type safety
127
+ */
128
+ export type Filter = BooleanFilter | CustomFilter<any> | SingleSelectFilter<any> | MultiSelectFilter<any> | DateFilter | DateRangeFilter;
129
+ /** Type representing all possible filter values */
130
+ export type FilterValue = boolean | CustomFilter["value"] | SingleSelectFilter["selectedItem"] | MultiSelectFilter["selectedItems"] | DateFilter["value"] | DateRangeFilter["value"];