aefis-core-ui 2.3.0-rc48 → 2.3.0-rc49

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.
@@ -6609,6 +6609,27 @@ function DataTable(props) {
6609
6609
  const handleSelectAllRows = checkbox => {
6610
6610
  setSelectAllRows(checkbox.target.checked);
6611
6611
  };
6612
+ const defaultHook = hooks => {
6613
+ const actionsColumn = {
6614
+ id: "_actions",
6615
+ disableResizing: true,
6616
+ minWidth: 75,
6617
+ width: 75,
6618
+ maxWidth: 75,
6619
+ Header: /*#__PURE__*/jsx("div", {}),
6620
+ Cell: data => {
6621
+ const rowData = data.row.original || undefined;
6622
+ const rowMenuObj = [{
6623
+ menu: props.rowMenu
6624
+ }];
6625
+ return props.rowMenu ? /*#__PURE__*/jsx(Actions$1, {
6626
+ configuration: rowMenuObj,
6627
+ data: rowData
6628
+ }) : "";
6629
+ }
6630
+ };
6631
+ hooks.allColumns.push(columns => props.rowMenu ? [...columns, actionsColumn] : [...columns]);
6632
+ };
6612
6633
  const selectionHook = hooks => {
6613
6634
  const CheckboxCell = ({
6614
6635
  row
@@ -6688,7 +6709,7 @@ function DataTable(props) {
6688
6709
  selectionGroupHeader.canResize = false;
6689
6710
  });
6690
6711
  };
6691
- const hooks = useMemo(() => [useColumnOrder, useFilters, useGroupBy, useSortBy, useFlexLayout, usePagination, useResizeColumns, useRowSelect, ...(props.selectable ? [selectionHook] : [])], [props.selectable]);
6712
+ const hooks = useMemo(() => [useColumnOrder, useFilters, useGroupBy, useSortBy, useFlexLayout, usePagination, useResizeColumns, useRowSelect, ...(props.selectable ? [selectionHook] : [defaultHook])], [props.selectable]);
6692
6713
  const useControlledState = state => {
6693
6714
  return useMemo(() => _extends({}, state, {
6694
6715
  selectedRowIds: singleSelection
@@ -10656,7 +10677,6 @@ const RichDataTable = /*#__PURE__*/forwardRef(function RichDatatable(props, ref)
10656
10677
  if (type === "filter") {
10657
10678
  setDrawerData();
10658
10679
  }
10659
-
10660
10680
  // TODO: component should not be state
10661
10681
  setDrawerContent(type !== "filter" ? drawerContent : /*#__PURE__*/jsx(FilterPanel, {
10662
10682
  configuration: props.filterPanelConfig,
@@ -11514,6 +11534,7 @@ const BusinessObjectPicker = _ref => {
11514
11534
  color: red[500]
11515
11535
  }
11516
11536
  }), listSelect !== true && /*#__PURE__*/jsx(IconButton, {
11537
+ name: open ? `hide options` : "show options",
11517
11538
  "aria-label": open ? `hide options` : "show options",
11518
11539
  size: "small",
11519
11540
  onClick: () => {
@@ -11527,6 +11548,7 @@ const BusinessObjectPicker = _ref => {
11527
11548
  })
11528
11549
  })
11529
11550
  }), enhancedSearch && /*#__PURE__*/jsx(IconButton, {
11551
+ name: "search",
11530
11552
  "aria-label": "search",
11531
11553
  size: "small",
11532
11554
  onKeyDown: handleKeyDown,
@@ -11558,6 +11580,7 @@ const BusinessObjectPicker = _ref => {
11558
11580
  padding: 1
11559
11581
  },
11560
11582
  children: /*#__PURE__*/jsx(IconButton, {
11583
+ name: "add item",
11561
11584
  onClick: () => {
11562
11585
  eventDispatch({
11563
11586
  name: events.OPEN_ADD_ITEM_DIALOG,