@geotab/zenith 3.16.0-beta.3 → 3.16.0-nightly.20260923.3d291e8

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 (95) hide show
  1. package/README.md +35 -1
  2. package/README.md.baseline +1 -0
  3. package/dist/checkboxListWithAction/checkboxListWithAction.d.ts +2 -0
  4. package/dist/checkboxListWithAction/checkboxListWithAction.js +1 -1
  5. package/dist/commonStyles/colors/colors.less +18 -0
  6. package/dist/dataGrid/dataGrid.d.ts +5 -1
  7. package/dist/dataGrid/dataGrid.js +39 -2
  8. package/dist/dataGrid/lazyLoadingEnd/lazyLoadingEnd.d.ts +3 -0
  9. package/dist/dataGrid/lazyLoadingEnd/lazyLoadingEnd.js +54 -0
  10. package/dist/dropdown/dropdownTrigger.d.ts +1 -1
  11. package/dist/dropdownRaw/dropdownHelper.d.ts +4 -0
  12. package/dist/dropdownRaw/dropdownHelper.js +11 -10
  13. package/dist/dropdownRaw/dropdownRaw.js +4 -3
  14. package/dist/dropdownRaw/dropdownSearchableTrigger.d.ts +2 -1
  15. package/dist/dropdownRaw/dropdownSearchableTrigger.js +4 -3
  16. package/dist/dropdownRaw/dropdownTrigger.d.ts +2 -1
  17. package/dist/dropdownRaw/dropdownTrigger.js +2 -2
  18. package/dist/dropdownRaw/types.d.ts +2 -0
  19. package/dist/filterButton/filterButton.d.ts +1 -1
  20. package/dist/formGroup/hooks/rowHooks/useLabelClasses.js +8 -2
  21. package/dist/header/components/collapsedItemsControl/collapsedItemsControl.d.ts +1 -1
  22. package/dist/header/components/collapsedItemsControl/collapsedItemsControl.js +6 -2
  23. package/dist/header/headerButton.d.ts +3 -1
  24. package/dist/header/headerButton.js +1 -1
  25. package/dist/header/headerMenu.d.ts +2 -0
  26. package/dist/header/headerMenu.js +1 -1
  27. package/dist/index.css +190 -30
  28. package/dist/index.d.ts +1 -0
  29. package/dist/index.js +6 -3
  30. package/dist/menu/components/menuButton.d.ts +3 -1
  31. package/dist/menu/components/menuButton.js +12 -11
  32. package/dist/menu/components/menuItem.js +4 -4
  33. package/dist/pagination/pagination.d.ts +19 -4
  34. package/dist/pagination/pagination.js +21 -1
  35. package/dist/pagination/paginationText/paginationText.d.ts +7 -1
  36. package/dist/pagination/paginationText/paginationText.js +6 -3
  37. package/dist/selectList/selectList.js +1 -0
  38. package/dist/selectList/selectListItem.d.ts +4 -1
  39. package/dist/selectList/selectListItem.js +4 -3
  40. package/dist/table/children/tablePagination.d.ts +1 -1
  41. package/dist/table/children/useTableChildren.d.ts +2 -1
  42. package/dist/table/children/useTableChildren.js +36 -12
  43. package/dist/table/selectable/interfaces.d.ts +13 -0
  44. package/dist/table/selectable/useSelectableRows.js +46 -12
  45. package/dist/table/selectable/utils/calculateSelectionState.js +35 -0
  46. package/dist/table/selectable/utils/isRowChecked.js +12 -1
  47. package/dist/table/table.js +21 -5
  48. package/dist/utils/localization/translations/en.json +3 -0
  49. package/dist/waiting/waiting.js +95 -1
  50. package/esm/checkboxListWithAction/checkboxListWithAction.d.ts +2 -0
  51. package/esm/checkboxListWithAction/checkboxListWithAction.js +1 -1
  52. package/esm/dataGrid/dataGrid.d.ts +5 -1
  53. package/esm/dataGrid/dataGrid.js +38 -2
  54. package/esm/dataGrid/lazyLoadingEnd/lazyLoadingEnd.d.ts +3 -0
  55. package/esm/dataGrid/lazyLoadingEnd/lazyLoadingEnd.js +45 -0
  56. package/esm/dropdown/dropdownTrigger.d.ts +1 -1
  57. package/esm/dropdownRaw/dropdownHelper.d.ts +4 -0
  58. package/esm/dropdownRaw/dropdownHelper.js +11 -10
  59. package/esm/dropdownRaw/dropdownRaw.js +4 -3
  60. package/esm/dropdownRaw/dropdownSearchableTrigger.d.ts +2 -1
  61. package/esm/dropdownRaw/dropdownSearchableTrigger.js +4 -3
  62. package/esm/dropdownRaw/dropdownTrigger.d.ts +2 -1
  63. package/esm/dropdownRaw/dropdownTrigger.js +2 -2
  64. package/esm/dropdownRaw/types.d.ts +2 -0
  65. package/esm/filterButton/filterButton.d.ts +1 -1
  66. package/esm/formGroup/hooks/rowHooks/useLabelClasses.js +8 -2
  67. package/esm/header/components/collapsedItemsControl/collapsedItemsControl.d.ts +1 -1
  68. package/esm/header/components/collapsedItemsControl/collapsedItemsControl.js +6 -2
  69. package/esm/header/headerButton.d.ts +3 -1
  70. package/esm/header/headerButton.js +1 -1
  71. package/esm/header/headerMenu.d.ts +2 -0
  72. package/esm/header/headerMenu.js +1 -1
  73. package/esm/index.d.ts +1 -0
  74. package/esm/index.js +1 -0
  75. package/esm/menu/components/menuButton.d.ts +3 -1
  76. package/esm/menu/components/menuButton.js +12 -11
  77. package/esm/menu/components/menuItem.js +4 -4
  78. package/esm/pagination/pagination.d.ts +19 -4
  79. package/esm/pagination/pagination.js +21 -1
  80. package/esm/pagination/paginationText/paginationText.d.ts +7 -1
  81. package/esm/pagination/paginationText/paginationText.js +6 -3
  82. package/esm/selectList/selectList.js +1 -0
  83. package/esm/selectList/selectListItem.d.ts +4 -1
  84. package/esm/selectList/selectListItem.js +4 -3
  85. package/esm/table/children/tablePagination.d.ts +1 -1
  86. package/esm/table/children/useTableChildren.d.ts +2 -1
  87. package/esm/table/children/useTableChildren.js +36 -12
  88. package/esm/table/selectable/interfaces.d.ts +13 -0
  89. package/esm/table/selectable/useSelectableRows.js +46 -12
  90. package/esm/table/selectable/utils/calculateSelectionState.js +35 -0
  91. package/esm/table/selectable/utils/isRowChecked.js +12 -1
  92. package/esm/table/table.js +22 -6
  93. package/esm/utils/localization/translations/en.json +3 -0
  94. package/esm/waiting/waiting.js +96 -2
  95. package/package.json +2 -1
package/README.md CHANGED
@@ -164,7 +164,7 @@ Zenith library provides components defined in Zenith Design System. It includes
164
164
 
165
165
  ### 3.10.0
166
166
 
167
- - Add `wrap` and `vertical` props to `ListItem`
167
+ - Add `vertical` props to `ListItem`
168
168
  - Add `data-analytics-id` prop to `Tab`, `TabItem`, and `Bookmark`
169
169
  - `Nav` component: support show/hide separator between Core and Apps sections
170
170
  - `Nav` empty state support
@@ -764,6 +764,40 @@ Upgrade today to take advantage of modern JavaScript module support and improved
764
764
  - Improve sizing of the title in Header
765
765
  - Add the property `triggerAriaLabel` to `Dropdown`
766
766
 
767
+ ### 1.14.0
768
+
769
+ - Create the Layout
770
+ - Update strings
771
+ - Add aria-label to Stepper, Range and FilterButton
772
+ - Improve accessibility of icons
773
+
774
+ ### 1.13.1
775
+
776
+ - Improve behavior of the DateRange selection
777
+ - Improve imports in Zenith
778
+ - Fix date position in PillExpandable
779
+ - Update package description, add license
780
+ - Add option to open links in new tab in PillExpandable
781
+ - Fix visual styles of MiniTabs
782
+ - Allow passing fragment as a child of the Header
783
+ - Stepper max value not working as expected
784
+ - Allow text formatting in the description of the PillExpandable
785
+ - Prevent rerendering in useMobile
786
+
787
+ ### 1.13.0
788
+
789
+ - New component Table
790
+ - Clean search input in Dropdown on close popup
791
+ - Fix tabbing through all rows in a table
792
+ - Rename "All filters" to "Filters" in FiltersBar
793
+ - Improve tooltip accessibility
794
+ - Add ecosystem icons
795
+ - Increase focus area in search input
796
+ - Fix issue with loosing seconds when changing date or time in calendar
797
+ - The new component Skeleton for loading animation
798
+ - Fix the Select component selection issue
799
+ - Update npm dependencies
800
+
767
801
  ## Feedback
768
802
 
769
803
  For any questions or feedback please email zenith@geotab.com.
@@ -0,0 +1 @@
1
+ 844121ca3e0f2233c3ae7ac5348ee03c3e60441d59b6150408db3401e9346141
@@ -11,6 +11,8 @@ export interface ICheckboxListWithActionOption {
11
11
  isWithAction: boolean;
12
12
  countSelectedChild?: number;
13
13
  color?: IColor;
14
+ /** When true, renders a 1px separator line below this item. */
15
+ divider?: boolean;
14
16
  }
15
17
  export interface IChangeCheckbox {
16
18
  id: string;
@@ -443,7 +443,7 @@ const CheckboxListWithAction = ({
443
443
  const labelForRender = selectSearchTerm(opt.label);
444
444
  const labelElement = renderLabel(opt, labelForRender, titleForRender, ind);
445
445
  return (0, jsx_runtime_1.jsxs)("li", {
446
- className: (0, classNames_1.classNames)(["zen-checkbox-list-with-action__action-item", opt.isWithAction ? "zen-checkbox-list-with-action__action-item--action" : ""]),
446
+ className: (0, classNames_1.classNames)(["zen-checkbox-list-with-action__action-item", opt.isWithAction ? "zen-checkbox-list-with-action__action-item--action" : "", opt.divider && ind < optionsArr.length - 1 ? "zen-checkbox-list-with-action__action-item--divider" : ""]),
447
447
  "data-item": opt.property,
448
448
  children: [(0, jsx_runtime_1.jsx)(checkbox_1.Checkbox, {
449
449
  id: `${checkboxId}${opt.property}`,
@@ -82,6 +82,24 @@
82
82
  --data--categorical-yellow: #f5bd60;
83
83
  --data--categorical-red: #e56a6a;
84
84
  --data--categorical-grey: #8a94a2;
85
+
86
+ // data visualization - sequential
87
+ --data--sequential-1: #8cb6f9;
88
+ --data--sequential-2: #6ca1f8;
89
+ --data--sequential-3: #428aff;
90
+ --data--sequential-4: #2e76ea;
91
+ --data--sequential-5: #1862d5;
92
+ --data--sequential-6: #0d51b7;
93
+ --data--sequential-7: #084197;
94
+
95
+ // data visualization - diverging
96
+ --data--diverging-1: #782c0e;
97
+ --data--diverging-2: #cb591f;
98
+ --data--diverging-3: #f98c41;
99
+ --data--diverging-4: #f5bd60;
100
+ --data--diverging-5: #428aff;
101
+ --data--diverging-6: #1862d5;
102
+ --data--diverging-7: #084197;
85
103
  }
86
104
 
87
105
  .zen-dark {
@@ -11,7 +11,7 @@ export interface IDataGrid<T, N = T> extends Omit<IZenComponentProps, "children"
11
11
  description?: string;
12
12
  emptyCellTitle?: string;
13
13
  resetScroll?: boolean;
14
- children?: ReturnType<typeof EmptyList> | ReturnType<typeof Footer>;
14
+ children?: ReturnType<typeof EmptyList> | ReturnType<typeof Footer> | ReturnType<typeof EndOfList>;
15
15
  rowClassName?: TRowClassName<T>;
16
16
  expandedRows?: string[];
17
17
  onExpandedChange?: (id: string, isExpanded: boolean) => void;
@@ -37,10 +37,14 @@ export declare const VERTICAL_SCROLL_MODIFIER = "zen-data-grid--vertical-scroll"
37
37
  export declare const MIN_CELL_WIDTH = 100;
38
38
  export declare const EmptyList: FC<PropsWithChildren>;
39
39
  export declare const Footer: FC<PropsWithChildren>;
40
+ export declare const EndOfList: FC<PropsWithChildren<{
41
+ style?: React.CSSProperties;
42
+ }>>;
40
43
  declare const DataGridInner: <T extends IRowEntity<N>, N extends IEntityWithId = T>({ entities, columns, className, description, emptyCellTitle, children, rowClassName, expandedRows, onExpandedChange, active, onClick, onScrollEnd, isLoading }: IDataGrid<T, N>, ref: ForwardedRef<HTMLElement>) => import("react/jsx-runtime").JSX.Element;
41
44
  export interface IDataGridStaticProps {
42
45
  EmptyList: typeof EmptyList;
43
46
  Footer: typeof Footer;
47
+ EndOfList: typeof EndOfList;
44
48
  }
45
49
  declare const DataGrid: (<T extends IRowEntity<N>, N extends IEntityWithId = T>(props: IDataGrid<T, N> & {
46
50
  ref?: React.ForwardedRef<HTMLElement>;
@@ -6,7 +6,7 @@ const {
6
6
  Object.defineProperty(exports, "__esModule", {
7
7
  value: true
8
8
  });
9
- exports.TRANSLATIONS = exports.DataGrid = exports.Footer = exports.EmptyList = exports.MIN_CELL_WIDTH = exports.VERTICAL_SCROLL_MODIFIER = exports.HORIZONTAL_SCROLL_MODIFIER = exports.DRAGGING_MODIFIER = exports.NOT_INTERACTIVE_MODIFIER = void 0;
9
+ exports.TRANSLATIONS = exports.DataGrid = exports.EndOfList = exports.Footer = exports.EmptyList = exports.MIN_CELL_WIDTH = exports.VERTICAL_SCROLL_MODIFIER = exports.HORIZONTAL_SCROLL_MODIFIER = exports.DRAGGING_MODIFIER = exports.NOT_INTERACTIVE_MODIFIER = void 0;
10
10
  const jsx_runtime_1 = require("react/jsx-runtime");
11
11
  injectString("cs", "Action", "Akce");
12
12
  injectString("da-DK", "Action", "Handling");
@@ -78,6 +78,20 @@ const Footer = ({
78
78
  children: children
79
79
  });
80
80
  exports.Footer = Footer;
81
+ // Rendered right after the last data row (desktop infinite scroll only) to indicate there is no
82
+ // more data to load. See Table's `isEndOfList` (table.tsx). `style` is set by DataGridInner to the
83
+ // table's actual rendered width (see `tableRef`/`tableObserverResult` below), so the row — and the
84
+ // centered content inside it (see `lazyLoadingEnd.less`) — spans the full table width even when
85
+ // columns overflow the visible viewport, rather than just the currently-scrolled-into-view portion.
86
+ const EndOfList = ({
87
+ children,
88
+ style
89
+ }) => (0, jsx_runtime_1.jsx)("div", {
90
+ className: "zen-data-grid__end-of-list",
91
+ style: style,
92
+ children: children
93
+ });
94
+ exports.EndOfList = EndOfList;
81
95
  const FIRST_RENDERED_ROWS = 100;
82
96
  const SCROLL_END_THRESHOLD = 100;
83
97
  const DataGridInner = ({
@@ -107,6 +121,12 @@ const DataGridInner = ({
107
121
  const [verticalScrollApplied, setVerticalScrollApplied] = (0, react_1.useState)(false);
108
122
  // Refs
109
123
  const gridRef = (0, react_1.useRef)(null);
124
+ // Separate from `gridRef` (which is the outer *scrolling container*, used above for available
125
+ // column-allocation space). This tracks the `<table>` element itself, whose rendered width
126
+ // already reflects `max(sum of column widths, container width)` per its `min-width: 100%` CSS —
127
+ // i.e. it's wider than the container when columns overflow. Used to size the end-of-list row to
128
+ // the table's true full width instead of just the visible/scrolled-into-view portion.
129
+ const tableRef = (0, react_1.useRef)(null);
110
130
  const bodyRef = (0, react_1.useRef)(null);
111
131
  const lazyRenderTimerRef = (0, react_1.useRef)(0);
112
132
  const scrollEndFiredRef = (0, react_1.useRef)(false);
@@ -114,6 +134,7 @@ const DataGridInner = ({
114
134
  const rowsMap = (0, react_1.useMemo)(() => new Map(entities.map(entity => [entity.id, entity])), [entities]);
115
135
  const emptyList = (0, react_1.useMemo)(() => react_1.Children.toArray(children).find(child => child.type === exports.EmptyList), [children]);
116
136
  const footer = (0, react_1.useMemo)(() => react_1.Children.toArray(children).find(child => child.type === exports.Footer), [children]);
137
+ const endOfList = (0, react_1.useMemo)(() => react_1.Children.toArray(children).find(child => child.type === exports.EndOfList), [children]);
117
138
  (0, react_1.useImperativeHandle)(ref, () => gridRef.current, []);
118
139
  const getVisibleRows = () => {
119
140
  if (!gridRef.current || !bodyRef.current) {
@@ -171,6 +192,14 @@ const DataGridInner = ({
171
192
  } = (0, useResizeObserver_1.useResizeObserver)({
172
193
  target: gridRef.current
173
194
  });
195
+ // Only observe the table's width when an `EndOfList` child is actually present — avoids a
196
+ // second ResizeObserver instance (and its resulting re-renders) on the vast majority of
197
+ // `DataGrid` usages that never render this row.
198
+ const {
199
+ result: tableObserverResult
200
+ } = (0, useResizeObserver_1.useResizeObserver)({
201
+ target: endOfList ? tableRef.current : null
202
+ });
174
203
  const allocatedSpace = listOfDefaultWidthColumns.reduce((acc, width, index) => acc + (width === undefined ? 0 : getColumnWidth(width, listOfMinWidthColumns[index])), 0);
175
204
  const unallocatedSpace = observerResult && observerResult.contentRect.width - allocatedSpace || 0;
176
205
  const flexibleColumnsQty = listOfDefaultWidthColumns.filter(width => width === undefined).length;
@@ -308,6 +337,7 @@ const DataGridInner = ({
308
337
  "aria-label": description,
309
338
  "aria-busy": !!isLoading,
310
339
  role: isTreeGrid ? "treegrid" : undefined,
340
+ ref: tableRef,
311
341
  children: [(0, jsx_runtime_1.jsx)("thead", {
312
342
  className: "zen-data-grid__header",
313
343
  children: (0, jsx_runtime_1.jsx)("tr", {
@@ -318,7 +348,13 @@ const DataGridInner = ({
318
348
  ref: bodyRef,
319
349
  children: body
320
350
  })]
321
- }), emptyList && entities.length === 0 ? emptyList : null, footer]
351
+ }), endOfList ? (0, react_1.cloneElement)(endOfList, {
352
+ style: Object.assign(Object.assign({}, tableObserverResult ? {
353
+ width: tableObserverResult.contentRect.width
354
+ } : {}), observerResult ? {
355
+ "--zen-end-of-list-viewport-width": `${observerResult.contentRect.width}px`
356
+ } : {})
357
+ }) : null, emptyList && entities.length === 0 ? emptyList : null, footer]
322
358
  })
323
359
  });
324
360
  };
@@ -326,4 +362,5 @@ const DataGrid = (0, react_1.forwardRef)(DataGridInner);
326
362
  exports.DataGrid = DataGrid;
327
363
  DataGrid.EmptyList = exports.EmptyList;
328
364
  DataGrid.Footer = exports.Footer;
365
+ DataGrid.EndOfList = exports.EndOfList;
329
366
  exports.TRANSLATIONS = ["Action"];
@@ -0,0 +1,3 @@
1
+ import "./lazyLoadingEnd.less";
2
+ export declare const LazyLoadingEnd: () => import("react/jsx-runtime").JSX.Element;
3
+ export declare const TRANSLATIONS: string[];
@@ -0,0 +1,54 @@
1
+ "use strict";
2
+
3
+ const {
4
+ injectString
5
+ } = require("../../utils/localization/translationsDictionary");
6
+ Object.defineProperty(exports, "__esModule", {
7
+ value: true
8
+ });
9
+ exports.TRANSLATIONS = exports.LazyLoadingEnd = void 0;
10
+ const jsx_runtime_1 = require("react/jsx-runtime");
11
+ const imageNothingFound_1 = require("../../images/imageNothingFound");
12
+ const useLanguage_1 = require("../../utils/localization/useLanguage");
13
+ injectString("en", "No further results found", "No further results found");
14
+ injectString("en", "We couldn't find any more data matching your current selection. Try broadening your search.", "We couldn't find any more data matching your current selection. Try broadening your search.");
15
+ // Shown as the last "row" of a desktop infinite-scroll table (Table's `onScrollEnd`) once all rows
16
+ // have been loaded, i.e. `entities.length >= total` from the `Table.Pagination` child. See
17
+ // `dataGrid.tsx`'s `EndOfList` slot and `table.tsx`'s `isEndOfList`.
18
+ //
19
+ // Two layers: the outer `zen-lazy-loading-end` is sized by `dataGrid.tsx` to the table's actual
20
+ // rendered width (can be much wider than the viewport once columns overflow), so its background/
21
+ // border span the full table at any scroll position. The inner `__sticky` wrapper is given an
22
+ // explicit, narrower width (the scrollport's own width, via `dataGrid.tsx`'s
23
+ // `--zen-end-of-list-viewport-width` CSS variable) and `position: sticky; inset-inline-start: 0`, so
24
+ // it floats and tracks the *currently visible* horizontal scroll position — `position: sticky` alone
25
+ // doesn't shrink a normal block box's width, so without the explicit width it would just render at
26
+ // the outer layer's full table width and never visibly move. With it, the icon and text stay centered
27
+ // on whatever part of the table you're actually looking at, rather than on the table's mathematical
28
+ // midpoint (which could be scrolled far out of view). See lazyLoadingEnd.less.
29
+ const LazyLoadingEnd = () => {
30
+ const {
31
+ translate
32
+ } = (0, useLanguage_1.useLanguage)();
33
+ return (0, jsx_runtime_1.jsx)("div", {
34
+ className: "zen-lazy-loading-end",
35
+ children: (0, jsx_runtime_1.jsxs)("div", {
36
+ className: "zen-lazy-loading-end__sticky",
37
+ children: [(0, jsx_runtime_1.jsx)(imageNothingFound_1.ImageNothingFound, {
38
+ className: "zen-lazy-loading-end__image",
39
+ focusable: false
40
+ }), (0, jsx_runtime_1.jsxs)("div", {
41
+ className: "zen-lazy-loading-end__content",
42
+ children: [(0, jsx_runtime_1.jsx)("div", {
43
+ className: "zen-lazy-loading-end__title",
44
+ children: translate("No further results found")
45
+ }), (0, jsx_runtime_1.jsx)("div", {
46
+ className: "zen-lazy-loading-end__description",
47
+ children: translate("We couldn't find any more data matching your current selection. Try broadening your search.")
48
+ })]
49
+ })]
50
+ })
51
+ });
52
+ };
53
+ exports.LazyLoadingEnd = LazyLoadingEnd;
54
+ exports.TRANSLATIONS = ["No further results found", "We couldn't find any more data matching your current selection. Try broadening your search."];
@@ -1 +1 @@
1
- export declare const DropdownTrigger: ({ name, onBlur, isActive, id, triggerRef, searchField, placeholder, disabled, fullWidth, currentSelection, handleClick, inputValue, className, onSearchChange, width, title, triggerAriaLabel, count, inputRef, autocomplete, buttonType, isError, popupId, handleFocusOnPopup, allyPattern, dataAnalyticsId, ...otherProps }: import("../dropdownRaw/dropdownTrigger").IDropdownTrigger) => import("react/jsx-runtime").JSX.Element;
1
+ export declare const DropdownTrigger: ({ name, onBlur, isActive, id, triggerRef, searchField, placeholder, disabled, fullWidth, currentSelection, handleClick, inputValue, className, onSearchChange, width, title, triggerAriaLabel, count, inputRef, autocomplete, buttonType, isError, popupId, handleFocusOnPopup, allyPattern, dataAnalyticsId, isFormItem, ...otherProps }: import("../dropdownRaw/dropdownTrigger").IDropdownTrigger) => import("react/jsx-runtime").JSX.Element;
@@ -13,14 +13,18 @@ export declare function prepareComboOptionsForList(actionListData: Set<string>,
13
13
  export declare const createOptions: (stateObj: IDropdownState, translate: (s: string) => string, listItem: IDropdownRawItem[], isAllSelected?: boolean) => ICheckboxListWithActionOption[];
14
14
  export declare const sortDropdownItemArray: (arr: IDropdownRawItem[], sortFn?: (a: IDropdownRawItem, b: IDropdownRawItem) => number) => IDropdownRawItem[];
15
15
  export declare const createSingleListOptions: (stateObj: IDropdownState, translate: (s: string) => string, listItem: IDropdownRawItem[]) => {
16
+ divider?: boolean | undefined;
16
17
  id: string;
17
18
  children: string;
19
+ title: string;
18
20
  disabled: boolean | undefined;
19
21
  multiLevel: boolean | undefined;
20
22
  }[];
21
23
  export declare const createListDataOptions: (stateObj: IDropdownState, translate: (s: string) => string, listItem: IDropdownRawItem[], isMultiselect: boolean, isAllSelected?: boolean) => ICheckboxListWithActionOption[] | {
24
+ divider?: boolean | undefined;
22
25
  id: string;
23
26
  children: string;
27
+ title: string;
24
28
  disabled: boolean | undefined;
25
29
  multiLevel: boolean | undefined;
26
30
  }[];
@@ -55,7 +55,7 @@ function prepareComboOptionsForList(actionListData, translate, options, getSelec
55
55
  const preparedOptions = options && options.length
56
56
  ? options.map(option => {
57
57
  const selectedChild = getSelectedChildFn(option.id);
58
- return Object.assign({ label: (0, groupsHelper_1.getGroupDescription)(option, translate), property: option.id, checked: isAllSelected ? true : selectedIds.has(option.id), isWithAction: actionListData.has(option.id), partialChecked: isAllSelected ? false : selectedChild.length > 0, countSelectedChild: 0, blocked: isFlatList ? option.disabled || false : false }, (getTitle ? { title: getTitle(option.id) } : {}));
58
+ return Object.assign(Object.assign({ label: (0, groupsHelper_1.getGroupDescription)(option, translate), property: option.id, checked: isAllSelected ? true : selectedIds.has(option.id), isWithAction: actionListData.has(option.id), partialChecked: isAllSelected ? false : selectedChild.length > 0, countSelectedChild: 0, blocked: isFlatList ? option.disabled || false : false }, (getTitle ? { title: getTitle(option.id) } : {})), (option.divider ? { divider: true } : {}));
59
59
  })
60
60
  : [];
61
61
  return preparedOptions;
@@ -95,14 +95,14 @@ const sortDropdownItemArray = (arr, sortFn) => {
95
95
  exports.sortDropdownItemArray = sortDropdownItemArray;
96
96
  const createSingleListOptions = (stateObj, translate, listItem) => {
97
97
  const preparedOptions = listItem && listItem.length
98
- ? listItem.map(option => ({
99
- id: option.id,
100
- children: (0, groupsHelper_1.getGroupDescription)(stateObj.groupsMap[option.id] || option, translate),
101
- disabled: option.disabled,
102
- multiLevel: Object.keys(stateObj.groupsMap).length === 0
103
- ? false
104
- : option.children && option.children.length > 0 && stateObj.groupsMap[option.id] !== undefined
105
- }))
98
+ ? listItem.map(option => {
99
+ const description = (0, groupsHelper_1.getGroupDescription)(stateObj.groupsMap[option.id] || option, translate);
100
+ return Object.assign({ id: option.id, children: description,
101
+ // Long names are truncated by `zen-ellipsis`, so expose the full text on hover
102
+ title: description, disabled: option.disabled, multiLevel: Object.keys(stateObj.groupsMap).length === 0
103
+ ? false
104
+ : option.children && option.children.length > 0 && stateObj.groupsMap[option.id] !== undefined }, (option.divider ? { divider: true } : {}));
105
+ })
106
106
  : [];
107
107
  return preparedOptions;
108
108
  };
@@ -124,7 +124,8 @@ const compareObjectsArrays = (arr1, arr2) => arr1.length === arr2.length &&
124
124
  const sameDisabled = el.disabled === el2.disabled ||
125
125
  (el.disabled === undefined && el2.disabled === false) ||
126
126
  (el2.disabled === undefined && el.disabled === false);
127
- return sameId && sameDisabled;
127
+ const sameDivider = el.divider === el2.divider || (el.divider === undefined && el2.divider === false) || (el2.divider === undefined && el.divider === false);
128
+ return sameId && sameDisabled && sameDivider;
128
129
  });
129
130
  exports.compareObjectsArrays = compareObjectsArrays;
130
131
  const prepareSelectedIdsToItems = (selectedIds, groupsMap, groupsMapSelected) => {
@@ -945,7 +945,7 @@ const DropdownRaw = props => {
945
945
  const currentAbort = abortToken.current;
946
946
  controlData(currentAbort.signal, newValue, state.isChecked);
947
947
  }, [controlData, state.isChecked]);
948
- const containerClassName = (0, classNames_1.classNames)(["zen-dropdown", isFormSection ? "zen-dropdown--form-item" : "", "zen-dropdown__container", className || ""]);
948
+ const containerClassName = (0, classNames_1.classNames)(["zen-dropdown", isFormSection || isFormItemVal ? "zen-dropdown--form-item" : "", "zen-dropdown__container", className || ""]);
949
949
  const handleCheckboxChange = (0, react_1.useCallback)(e => {
950
950
  const isChecked = e.target.checked;
951
951
  dispatchState({
@@ -1219,7 +1219,7 @@ const DropdownRaw = props => {
1219
1219
  isError: isError,
1220
1220
  disabled: disabled,
1221
1221
  count: showCounterPill ? countSelected : 0,
1222
- fullWidth: fullWidthTriggerButton,
1222
+ fullWidth: isFormItemVal && !searchField ? true : fullWidthTriggerButton,
1223
1223
  inputValue: state.inputValue,
1224
1224
  placeholder: placeholder || translate("Filter by group"),
1225
1225
  searchField: searchField && !isMobile ? searchField : false,
@@ -1235,7 +1235,8 @@ const DropdownRaw = props => {
1235
1235
  handleFocusOnPopup: handleFocusOnPopup,
1236
1236
  popupId: memoizedAllyPattern === "selectOnlyCombobox" ? selectListId : popupId,
1237
1237
  allyPattern: memoizedAllyPattern,
1238
- dataAnalyticsId: dataAnalyticsId
1238
+ dataAnalyticsId: dataAnalyticsId,
1239
+ isFormItem: isFormItemVal
1239
1240
  }, accessibilityProps)), (0, jsx_runtime_1.jsx)(dropdownPopup_1.DropdownPopup, {
1240
1241
  alignment: alignment,
1241
1242
  triggerRef: triggerRef,
@@ -23,9 +23,10 @@ interface IDropdownSearchableTrigger {
23
23
  autocomplete?: string;
24
24
  handleFocusOnPopup?: () => void;
25
25
  dataAnalyticsId?: string;
26
+ isFormItem?: boolean;
26
27
  }
27
28
  export declare const DropdownSearchableTrigger: {
28
- ({ value, className, onChange, placeholder, isOpenPopup, inputRef, handleClick, width, title, id, disabled, count, currentSelection, isError, fullWidth, ref, name, onBlur, popupId, autocomplete, handleFocusOnPopup, dataAnalyticsId, ...otherProps }: IDropdownSearchableTrigger): import("react/jsx-runtime").JSX.Element;
29
+ ({ value, className, onChange, placeholder, isOpenPopup, inputRef, handleClick, width, title, id, disabled, count, currentSelection, isError, fullWidth, ref, name, onBlur, popupId, autocomplete, handleFocusOnPopup, dataAnalyticsId, isFormItem, ...otherProps }: IDropdownSearchableTrigger): import("react/jsx-runtime").JSX.Element;
29
30
  displayName: string;
30
31
  };
31
32
  export declare const TRANSLATIONS: string[];
@@ -180,9 +180,10 @@ const DropdownSearchableTrigger = _a => {
180
180
  popupId,
181
181
  autocomplete,
182
182
  handleFocusOnPopup,
183
- dataAnalyticsId
183
+ dataAnalyticsId,
184
+ isFormItem
184
185
  } = _a,
185
- otherProps = __rest(_a, ["value", "className", "onChange", "placeholder", "isOpenPopup", "inputRef", "handleClick", "width", "title", "id", "disabled", "count", "currentSelection", "isError", "fullWidth", "ref", "name", "onBlur", "popupId", "autocomplete", "handleFocusOnPopup", "dataAnalyticsId"])
186
+ otherProps = __rest(_a, ["value", "className", "onChange", "placeholder", "isOpenPopup", "inputRef", "handleClick", "width", "title", "id", "disabled", "count", "currentSelection", "isError", "fullWidth", "ref", "name", "onBlur", "popupId", "autocomplete", "handleFocusOnPopup", "dataAnalyticsId", "isFormItem"])
186
187
  // eslint-disable-next-line complexity
187
188
  ;
188
189
  const {
@@ -230,7 +231,7 @@ const DropdownSearchableTrigger = _a => {
230
231
  onChange(undefined);
231
232
  };
232
233
  return (0, jsx_runtime_1.jsxs)("div", Object.assign({
233
- className: (0, classNames_1.classNames)(["zen-dropdown-searchable-trigger", isError ? "zen-dropdown-searchable-trigger--error" : "", driveComponentClass || "", isFormSection ? "zen-dropdown-searchable-trigger--form-item" : "", disabled ? "zen-dropdown-searchable-trigger--disabled" : ""])
234
+ className: (0, classNames_1.classNames)(["zen-dropdown-searchable-trigger", isError ? "zen-dropdown-searchable-trigger--error" : "", driveComponentClass || "", isFormSection || isFormItem ? "zen-dropdown-searchable-trigger--form-item" : "", disabled ? "zen-dropdown-searchable-trigger--disabled" : ""])
234
235
  }, inputStyle, {
235
236
  ref: ref
236
237
  }, otherProps, {
@@ -27,6 +27,7 @@ export interface IDropdownTrigger extends IZenComponentProps {
27
27
  handleFocusOnPopup?: () => void;
28
28
  allyPattern?: "selectOnlyCombobox" | "comboboxWithDialog" | "buttonWithDialog" | "buttonWithMenu";
29
29
  dataAnalyticsId?: string;
30
+ isFormItem?: boolean;
30
31
  }
31
- export declare const DropdownTrigger: ({ name, onBlur, isActive, id, triggerRef, searchField, placeholder, disabled, fullWidth, currentSelection, handleClick, inputValue, className, onSearchChange, width, title, triggerAriaLabel, count, inputRef, autocomplete, buttonType, isError, popupId, handleFocusOnPopup, allyPattern, dataAnalyticsId, ...otherProps }: IDropdownTrigger) => import("react/jsx-runtime").JSX.Element;
32
+ export declare const DropdownTrigger: ({ name, onBlur, isActive, id, triggerRef, searchField, placeholder, disabled, fullWidth, currentSelection, handleClick, inputValue, className, onSearchChange, width, title, triggerAriaLabel, count, inputRef, autocomplete, buttonType, isError, popupId, handleFocusOnPopup, allyPattern, dataAnalyticsId, isFormItem, ...otherProps }: IDropdownTrigger) => import("react/jsx-runtime").JSX.Element;
32
33
  export declare const TRANSLATIONS: string[];
@@ -19,13 +19,13 @@ const react_1 = require("react");
19
19
  const classNames_1 = require("../commonHelpers/classNames/classNames");
20
20
  const dropdownHelper_1 = require("./dropdownHelper");
21
21
  const DropdownTrigger = (_a) => {
22
- var { name, onBlur, isActive, id, triggerRef, searchField, placeholder, disabled, fullWidth, currentSelection, handleClick, inputValue, className, onSearchChange = () => { }, width, title, triggerAriaLabel, count, inputRef, autocomplete, buttonType, isError, popupId, handleFocusOnPopup, allyPattern = "buttonWithDialog", dataAnalyticsId } = _a, otherProps = __rest(_a, ["name", "onBlur", "isActive", "id", "triggerRef", "searchField", "placeholder", "disabled", "fullWidth", "currentSelection", "handleClick", "inputValue", "className", "onSearchChange", "width", "title", "triggerAriaLabel", "count", "inputRef", "autocomplete", "buttonType", "isError", "popupId", "handleFocusOnPopup", "allyPattern", "dataAnalyticsId"]);
22
+ var { name, onBlur, isActive, id, triggerRef, searchField, placeholder, disabled, fullWidth, currentSelection, handleClick, inputValue, className, onSearchChange = () => { }, width, title, triggerAriaLabel, count, inputRef, autocomplete, buttonType, isError, popupId, handleFocusOnPopup, allyPattern = "buttonWithDialog", dataAnalyticsId, isFormItem } = _a, otherProps = __rest(_a, ["name", "onBlur", "isActive", "id", "triggerRef", "searchField", "placeholder", "disabled", "fullWidth", "currentSelection", "handleClick", "inputValue", "className", "onSearchChange", "width", "title", "triggerAriaLabel", "count", "inputRef", "autocomplete", "buttonType", "isError", "popupId", "handleFocusOnPopup", "allyPattern", "dataAnalyticsId", "isFormItem"]);
23
23
  const elInpRef = (0, react_1.useRef)(null);
24
24
  const handleButtonClick = () => {
25
25
  handleClick(!isActive);
26
26
  };
27
27
  const allyTriggerProps = (0, react_1.useMemo)(() => (0, dropdownHelper_1.getAllyTriggerProps)(allyPattern), [allyPattern]);
28
- return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: searchField ? ((0, jsx_runtime_1.jsx)(dropdownSearchableTrigger_1.DropdownSearchableTrigger, Object.assign({ value: inputValue || "", name: name, onChange: onSearchChange, isOpenPopup: isActive, inputRef: inputRef || elInpRef, handleClick: handleClick, handleFocusOnPopup: handleFocusOnPopup, ref: triggerRef, width: width, placeholder: placeholder, disabled: disabled, id: id, title: title, count: count, currentSelection: currentSelection, className: className, isError: isError, fullWidth: fullWidth, popupId: popupId, autocomplete: autocomplete, dataAnalyticsId: dataAnalyticsId }, otherProps))) : ((0, jsx_runtime_1.jsx)(filterButton_1.FilterButton, Object.assign({ ref: triggerRef, id: id, name: name, onBlur: onBlur, className: (0, classNames_1.classNames)(["zen-dropdown__trigger-button", isError ? "zen-dropdown__trigger-button--error" : "", className || ""]), onClick: handleButtonClick, disabled: disabled, isActive: isActive, fullWidth: width ? true : fullWidth, maxWidth: width, minWidth: width, quantity: count || undefined, type: buttonType, title: title, ariaLabel: triggerAriaLabel || currentSelection || placeholder, "aria-expanded": isActive, "aria-controls": popupId }, allyTriggerProps, { dataAnalyticsId: dataAnalyticsId }, otherProps, { children: currentSelection ? ((0, jsx_runtime_1.jsx)("span", { className: (0, classNames_1.classNames)([
28
+ return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: searchField ? ((0, jsx_runtime_1.jsx)(dropdownSearchableTrigger_1.DropdownSearchableTrigger, Object.assign({ value: inputValue || "", name: name, onChange: onSearchChange, isOpenPopup: isActive, inputRef: inputRef || elInpRef, handleClick: handleClick, handleFocusOnPopup: handleFocusOnPopup, ref: triggerRef, width: width, placeholder: placeholder, disabled: disabled, id: id, title: title, count: count, currentSelection: currentSelection, className: className, isError: isError, fullWidth: fullWidth, popupId: popupId, autocomplete: autocomplete, dataAnalyticsId: dataAnalyticsId, isFormItem: isFormItem }, otherProps))) : ((0, jsx_runtime_1.jsx)(filterButton_1.FilterButton, Object.assign({ ref: triggerRef, id: id, name: name, onBlur: onBlur, className: (0, classNames_1.classNames)(["zen-dropdown__trigger-button", isError ? "zen-dropdown__trigger-button--error" : "", className || ""]), onClick: handleButtonClick, disabled: disabled, isActive: isActive, fullWidth: width ? true : fullWidth, maxWidth: width, minWidth: width, quantity: count || undefined, type: buttonType, title: title, ariaLabel: triggerAriaLabel || currentSelection || placeholder, "aria-expanded": isActive, "aria-controls": popupId }, allyTriggerProps, { dataAnalyticsId: dataAnalyticsId }, otherProps, { children: currentSelection ? ((0, jsx_runtime_1.jsx)("span", { className: (0, classNames_1.classNames)([
29
29
  "zen-dropdown__trigger-button-text",
30
30
  buttonType ? `zen-dropdown__trigger-button-text--${buttonType.toString()}` : ""
31
31
  ]), children: currentSelection })) : (placeholder) }))) }));
@@ -15,6 +15,8 @@ export interface IDropdownRawItem extends IEntityWithId {
15
15
  children?: IEntityWithId[];
16
16
  color?: IColor;
17
17
  disabled?: boolean;
18
+ /** When true, renders a 1px separator line below this item. Purely visual — does not affect selection or keyboard navigation. */
19
+ divider?: boolean;
18
20
  }
19
21
  interface IFetchState<T> {
20
22
  data: T | undefined;
@@ -2,7 +2,7 @@ import React, { RefObject } from "react";
2
2
  import "./filterButton.less";
3
3
  import { IZenComponentProps } from "../commonHelpers/zenComponent";
4
4
  import { ButtonType } from "../button/buttonType";
5
- export type TFilterButton = typeof ButtonType.Secondary | typeof ButtonType.Tertiary | typeof ButtonType.TertiaryBlack;
5
+ export type TFilterButton = typeof ButtonType.Primary | typeof ButtonType.Destructive | typeof ButtonType.Secondary | typeof ButtonType.Tertiary | typeof ButtonType.TertiaryBlack | typeof ButtonType.TertiaryDestructive;
6
6
  export interface IFilterButton extends IZenComponentProps {
7
7
  id?: string;
8
8
  name?: string;
@@ -8,7 +8,9 @@ const getOneLabelOneControlClasses_1 = require("../../utils/getLabelClasses/getO
8
8
  const useLabelAlign_1 = require("../useLabelAlign");
9
9
  const useMode_1 = require("../useMode");
10
10
  const useSectionType_1 = require("../useSectionType");
11
+ const TOP_ALIGN_CLASS = "zen-form-field-label--top";
11
12
  const useLabelClasses = (state) => {
13
+ var _a, _b;
12
14
  const type = (0, useSectionType_1.useSectionType)();
13
15
  const mode = (0, useMode_1.useMode)();
14
16
  const columns = (0, useColumns_1.useColumns)();
@@ -18,11 +20,15 @@ const useLabelClasses = (state) => {
18
20
  return;
19
21
  }
20
22
  const { labelClasses1, labelClasses2 } = (0, getLabelClasses_1.getLabelClasses)(state, columns, labelAlign, mode, type);
23
+ const effectiveLabelAlign1 = ((_a = state.elements.label1) === null || _a === void 0 ? void 0 : _a.labelAlign) || labelAlign;
24
+ const effectiveLabelAlign2 = ((_b = state.elements.label2) === null || _b === void 0 ? void 0 : _b.labelAlign) || labelAlign;
25
+ const topAlignClass1 = effectiveLabelAlign1 === "top" ? ` ${TOP_ALIGN_CLASS}` : "";
26
+ const topAlignClass2 = effectiveLabelAlign2 === "top" ? ` ${TOP_ALIGN_CLASS}` : "";
21
27
  if (state.elements.label1 && labelClasses1) {
22
- state.elements.label1.className = `${labelClasses1} ${state.elements.label1.className || ""}`;
28
+ state.elements.label1.className = `${labelClasses1}${topAlignClass1} ${state.elements.label1.className || ""}`;
23
29
  }
24
30
  if (state.elements.label2 && labelClasses2) {
25
- state.elements.label2.className = `${labelClasses2} ${state.elements.label2.className || ""}`;
31
+ state.elements.label2.className = `${labelClasses2}${topAlignClass2} ${state.elements.label2.className || ""}`;
26
32
  }
27
33
  };
28
34
  exports.useLabelClasses = useLabelClasses;
@@ -5,7 +5,7 @@ import { IMenuItem } from "../../../menu/components/menuItem";
5
5
  export interface ICustomContent {
6
6
  [key: string]: React.ReactElement<PropsWithChildren> | undefined;
7
7
  }
8
- export interface IHeaderCustomMenuComponent extends Pick<IMenuItem, "id" | "name" | "disabled" | "link" | "target" | "rel" | "icon"> {
8
+ export interface IHeaderCustomMenuComponent extends Pick<IMenuItem, "id" | "name" | "disabled" | "link" | "target" | "rel" | "icon" | "iconOpen" | "destructive"> {
9
9
  }
10
10
  export interface IHeaderCustomContent {
11
11
  content: ICustomContent | null;
@@ -109,7 +109,9 @@ const PageToolbarCollapsedItemsControl = ({
109
109
  link: child.props.link,
110
110
  target: child.props.target,
111
111
  rel: child.props.rel,
112
- icon: child.props.icon
112
+ icon: child.props.icon,
113
+ iconOpen: child.props.iconOpen,
114
+ destructive: child.props.destructive
113
115
  });
114
116
  items.push(el);
115
117
  }
@@ -122,7 +124,9 @@ const PageToolbarCollapsedItemsControl = ({
122
124
  link: child.props.link,
123
125
  target: child.props.target,
124
126
  rel: child.props.rel,
125
- icon: child.props.icon
127
+ icon: child.props.icon,
128
+ iconOpen: child.props.iconOpen,
129
+ destructive: child.props.destructive
126
130
  }, child.props.children);
127
131
  items.push(el);
128
132
  }
@@ -7,6 +7,8 @@ export interface IHeaderButton extends Omit<IButton, "onClick"> {
7
7
  important?: boolean;
8
8
  inContextMenu?: boolean;
9
9
  icon?: React.FC<IIcon>;
10
+ iconOpen?: boolean;
11
+ destructive?: boolean;
10
12
  iconPosition?: TButtonIconPosition;
11
13
  iconClasses?: string;
12
14
  iconSize?: TSvgIconSize;
@@ -14,6 +16,6 @@ export interface IHeaderButton extends Omit<IButton, "onClick"> {
14
16
  }
15
17
  export declare const HeaderButtonDisplayName = "HeaderButton";
16
18
  export declare const HeaderButton: {
17
- ({ id, children, icon, iconPosition, className, important, onClick, inContextMenu, ...restProps }: IHeaderButton): import("react/jsx-runtime").JSX.Element;
19
+ ({ id, children, icon, iconOpen, destructive, iconPosition, className, important, onClick, inContextMenu, ...restProps }: IHeaderButton): import("react/jsx-runtime").JSX.Element;
18
20
  displayName: string;
19
21
  };
@@ -18,7 +18,7 @@ const textIconButton_1 = require("../textIconButton/textIconButton");
18
18
  const classNames_1 = require("../commonHelpers/classNames/classNames");
19
19
  exports.HeaderButtonDisplayName = "HeaderButton";
20
20
  const HeaderButton = (_a) => {
21
- var { id, children, icon, iconPosition = textIconButton_1.ButtonIconPosition.Start, className = "", important, onClick, inContextMenu } = _a, restProps = __rest(_a, ["id", "children", "icon", "iconPosition", "className", "important", "onClick", "inContextMenu"]);
21
+ var { id, children, icon, iconOpen, destructive, iconPosition = textIconButton_1.ButtonIconPosition.Start, className = "", important, onClick, inContextMenu } = _a, restProps = __rest(_a, ["id", "children", "icon", "iconOpen", "destructive", "iconPosition", "className", "important", "onClick", "inContextMenu"]);
22
22
  const fullClassName = (0, classNames_1.classNames)(["zen-header-button", className]);
23
23
  const props = Object.assign(Object.assign({}, restProps), { "data-important": important ? "1" : "0" });
24
24
  return icon ? ((0, jsx_runtime_1.jsx)(textIconButton_1.TextIconButton, Object.assign({ id: id, icon: icon, iconPosition: iconPosition, className: fullClassName, onClick: onClick ? e => onClick(id, e) : undefined }, props, { children: children }))) : ((0, jsx_runtime_1.jsx)(button_1.Button, Object.assign({ id: id, className: fullClassName, onClick: onClick ? e => onClick(id, e) : undefined }, props, { children: children })));
@@ -10,6 +10,8 @@ export interface IHeaderMenu extends Omit<IButton, "onClick"> {
10
10
  important?: boolean;
11
11
  inContextMenu?: boolean;
12
12
  icon?: FC<IIcon>;
13
+ iconOpen?: boolean;
14
+ destructive?: boolean;
13
15
  iconSize?: TSvgIconSize;
14
16
  alignment?: TAlignment;
15
17
  onlyIcon?: boolean;
@@ -24,7 +24,7 @@ const useDrive_1 = require("../utils/theme/useDrive");
24
24
  const useDriveClassName_1 = require("../utils/theme/useDriveClassName");
25
25
  exports.HeaderMenuDisplayName = "HeaderMenu";
26
26
  const HeaderMenu = (_a) => {
27
- var { name, children, icon, iconSize = "large", className = "", important, alignment = "bottom-end", inContextMenu, onlyIcon } = _a, restProps = __rest(_a, ["name", "children", "icon", "iconSize", "className", "important", "alignment", "inContextMenu", "onlyIcon"]);
27
+ var { name, children, icon, iconOpen, destructive, iconSize = "large", className = "", important, alignment = "bottom-end", inContextMenu, onlyIcon } = _a, restProps = __rest(_a, ["name", "children", "icon", "iconOpen", "destructive", "iconSize", "className", "important", "alignment", "inContextMenu", "onlyIcon"]);
28
28
  const isMobile = (0, useMobile_1.useMobile)();
29
29
  const isDrive = (0, useDrive_1.useDrive)();
30
30
  const driveClassName = (0, useDriveClassName_1.useDriveClassName)("zen-header-button-with-dropdown");