@qualtrics/ui-react 2.49.0 → 2.49.1-alpha.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/dist/__shared/cjs/{index-96632417.js → index-65fe6015.js} +71 -77
- package/dist/components/Button/Button2.js +9 -13
- package/dist/components/ColorPicker/Palette.js +33 -39
- package/dist/components/Combobox/Combobox.js +1 -1
- package/dist/components/ConfigPane/ConfigPane.js +5 -6
- package/dist/components/Dropdown/Dropdown.js +1 -1
- package/dist/components/Dropdown/DropdownButton.js +1 -1
- package/dist/components/NewMenu/BaseMenu.js +3 -3
- package/dist/components/Tabs/TabContextProvider.js +0 -2
- package/dist/components/Tooltip/Tooltip.js +2 -2
- package/dist/components/deprecated_NumberStepper/NumberStepperDecrement.js +1 -1
- package/dist/components/deprecated_NumberStepper/NumberStepperIncrement.js +1 -1
- package/dist/components/deprecated_Tabs/Tabs.js +2 -2
- package/dist/icons/index.d.ts +0 -2
- package/dist/index.d.ts +8 -4
- package/dist/index.js +1 -1
- package/dist/next/AdvancedTable/AdvancedTable.js +8 -6
- package/dist/next/AdvancedTable/AdvancedTable2.js +3 -3
- package/dist/next/AdvancedTable/AdvancedTableCheckbox.js +6 -1
- package/dist/next/AdvancedTable/AdvancedTableColumnHeader.js +15 -6
- package/dist/next/AdvancedTable/AdvancedTableDnDContext.js +32 -0
- package/dist/next/AdvancedTable/AdvancedTableDragPreview.js +9 -11
- package/dist/next/AdvancedTable/AdvancedTableRow.js +6 -1
- package/dist/next/AdvancedTable/AdvancedTableRowExpandButton.js +12 -3
- package/dist/next/AdvancedTable/useAdvancedTableDragAndDrop.js +30 -138
- package/dist/next/AdvancedTable/useDragAndDropConfig.js +191 -0
- package/dist/next/Drawer/Drawer.js +1 -1
- package/dist/next/Menu/Hooks/usePaneSearch.js +12 -7
- package/dist/next/PhoneNumberInput/PhoneNumberInput.js +1 -0
- package/dist/next/index.d.ts +14 -12
- package/dist/next/index.js +263 -126
- package/dist/utils/Text/Text.js +1 -1
- package/dist/utils/Translation/containsComponentOrElement.js +6 -3
- package/dist/utils/Translation/useTranslation.js +5 -1
- package/icons/package.json +9 -9
- package/next/package.json +9 -9
- package/package.json +40 -40
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import _extends from '@babel/runtime-corejs3/helpers/extends';
|
|
2
2
|
import React__default, { useMemo, useState, useCallback, useEffect, useRef } from 'react';
|
|
3
3
|
import classNames from 'classnames';
|
|
4
|
-
import { DndProvider } from 'react-dnd';
|
|
5
|
-
import { HTML5Backend } from 'react-dnd-html5-backend';
|
|
6
4
|
import useResizeObserver from '@react-hook/resize-observer';
|
|
7
5
|
import '../../utils/index.js';
|
|
8
6
|
import '../../hooks/index.js';
|
|
@@ -19,6 +17,7 @@ import '../../components/IconButton/index.js';
|
|
|
19
17
|
import '../../components/Dropdown/index.js';
|
|
20
18
|
import AdvancedTablePagination from './AdvancedTablePagination.js';
|
|
21
19
|
import AdvancedTableRowExpandButton from './AdvancedTableRowExpandButton.js';
|
|
20
|
+
import { AdvancedTableDnDContextProvider } from './AdvancedTableDnDContext.js';
|
|
22
21
|
import useId from '../../hooks/useId/useId.js';
|
|
23
22
|
import getSubDataTestId from '../../utils/getSubDataTestId/getSubDataTestId.js';
|
|
24
23
|
import Dropdown from '../../components/Dropdown/Dropdown.js';
|
|
@@ -32,7 +31,6 @@ import concatIds from '../../utils/concatIds/concatIds.js';
|
|
|
32
31
|
import useControllableState from '../../hooks/useControllableState/useControllableState.js';
|
|
33
32
|
import { useDidUpdate } from '../../hooks/useDidUpdate/useDidUpdate.js';
|
|
34
33
|
import useEventCallback from '../../hooks/useEventCallback/useEventCallback.js';
|
|
35
|
-
import canUseDOM from '../../utils/canUseDOM/canUseDOM.js';
|
|
36
34
|
import useLatest from '../../hooks/useLatest/useLatest.js';
|
|
37
35
|
import wrapAround from '../../utils/wrapAround/wrapAround.js';
|
|
38
36
|
|
|
@@ -611,9 +609,13 @@ const AdvancedTable = _ref => {
|
|
|
611
609
|
} = _ref7;
|
|
612
610
|
return ((_columnWidths$id2 = columnWidths[id]) !== null && _columnWidths$id2 !== void 0 ? _columnWidths$id2 : width) !== undefined;
|
|
613
611
|
});
|
|
614
|
-
return /*#__PURE__*/React__default.createElement(
|
|
615
|
-
|
|
616
|
-
|
|
612
|
+
return /*#__PURE__*/React__default.createElement(AdvancedTableDnDContextProvider, {
|
|
613
|
+
setDropTargetSide: setDropTargetSide,
|
|
614
|
+
setColumnOrder: setColumnOrder,
|
|
615
|
+
setDragSource: setDragSource,
|
|
616
|
+
setDropTarget: setDropTarget,
|
|
617
|
+
setPinnedColumns: setPinnedColumns,
|
|
618
|
+
dropTargetSide: dropTargetSide
|
|
617
619
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
618
620
|
className: styles.advancedTable,
|
|
619
621
|
ref: tableRef
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = "._-5cPq{overflow:auto;position:relative;max-width:100%;max-height:100%}._-5cPq,._ytUo4{background-color:#fff}._ytUo4{height:70px;z-index:100;display:flex;align-items:flex-end;justify-content:center;position:-webkit-sticky;position:sticky;left:0}._EOKSw{margin-bottom:4px}._PuAcQ{position:-webkit-sticky;position:sticky;top:0;z-index:100}._vDAE0{display:flex}._vDAE0:focus{outline:none}._vDAE0.focus-visible ._BjdNb:after,._vDAE0:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._vDAE0.focus-visible ._BjdNb:last-of-type:after,._vDAE0:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb:first-of-type:after,._vDAE0:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb._aQl69:after,._vDAE0:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._QQmA0{padding-right:3px}._CVqPg{max-width:100%;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}._02ABn{display:flex}._02ABn._-V45P ._BjdNb,._02ABn._-V45P ._Teg50{cursor:pointer}._02ABn._a2wz1 ._BjdNb,._02ABn._a2wz1 ._Teg50{background-color:rgba(11,110,208,.08);font-weight:500;box-shadow:inset 0 -1px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69,._02ABn._a2wz1 ._Teg50._aQl69{background-color:#fff;box-shadow:inset 0 -2px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69 ._5quOp,._02ABn._a2wz1 ._BjdNb._aQl69 ._Av4Wy,._02ABn._a2wz1 ._BjdNb._aQl69 ._Teg50,._02ABn._a2wz1 ._Teg50._aQl69 ._5quOp,._02ABn._a2wz1 ._Teg50._aQl69 ._Av4Wy,._02ABn._a2wz1 ._Teg50._aQl69 ._Teg50{background-color:rgba(11,110,208,.08)}._02ABn._-V45P:hover:not(._a2wz1) ._BjdNb,._02ABn._-V45P:hover:not(._a2wz1) ._Teg50{background-color:#f9f9f9}._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._BjdNb,._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._Teg50{background-color:#f3f3f3}._02ABn:focus{outline:none}._02ABn.focus-visible ._BjdNb:after,._02ABn:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn.focus-visible ._BjdNb:last-of-type:after,._02ABn:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb:first-of-type:after,._02ABn:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb._aQl69:after,._02ABn:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:last-of-type:focus{outline:none}._02ABn:last-of-type.focus-visible ._BjdNb:after,._02ABn:last-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:last-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:last-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._02ABn:last-of-type ._Av4Wy:focus{outline:none}._02ABn:last-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:last-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:last-of-type ._Av4Wy.focus-visible:after,._02ABn:last-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._02ABn:first-of-type:focus{outline:none}._02ABn:first-of-type.focus-visible ._BjdNb:after,._02ABn:first-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:first-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:first-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:first-of-type ._Av4Wy:focus{outline:none}._02ABn:first-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:first-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:first-of-type ._Av4Wy.focus-visible:after,._02ABn:first-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._NJw9v{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #d9d9d9;flex-shrink:0;font-size:12px;line-height:16px;font-weight:700;color:#6a6d70;background-color:#fff;position:relative}._NJw9v._ysUDX{flex-grow:1}._NJw9v._nVwTc{cursor:pointer}._NJw9v._nVwTc:hover:not(._f9Vm3){background-color:#f9f9f9;border-bottom-color:#6a6d70}._NJw9v._nVwTc:active:not(._f9Vm3){background-color:#f3f3f3}._NJw9v._wtiMS:not(._f9Vm3){color:#32363a;fill:#32363a;border-bottom-color:#8a8f94}._NJw9v._f9Vm3{cursor:move;background-color:#efefef;border-bottom-color:#ccc;border-top-left-radius:4px;border-top-right-radius:4px}._NJw9v ._zcv4x{background-color:#d9d9d9;position:absolute;width:1px;top:0;pointer-events:none}._NJw9v ._zcv4x._n9XSz{left:-1px}._NJw9v ._zcv4x._Txoqg{right:0}._NJw9v ._cRwS-{background-color:#0a6ed1;position:absolute;width:3px;top:4px;bottom:4px;border-radius:4px;pointer-events:none}._NJw9v ._cRwS-._n9XSz{left:-2px}._NJw9v ._cRwS-._Txoqg{right:-1px}._NJw9v:first-of-type ._n9XSz._zcv4x{left:0;width:2px;border-left:1px solid #fff}._NJw9v:first-of-type ._n9XSz._cRwS-{left:0}._NJw9v:last-of-type ._Txoqg._zcv4x{right:0;width:2px;border-right:1px solid #fff}._NJw9v:last-of-type ._Txoqg._cRwS-{right:0}._NJw9v ._ATviE{position:absolute;width:6px;right:-3px;top:0;cursor:ew-resize;z-index:50}._NJw9v ._ATviE ._Ahz4c{position:absolute;width:2px;right:2px;top:0;bottom:0}._NJw9v ._ATviE ._Ahz4c._2uClD{background-color:#0a6ed1}._NJw9v ._ATviE:hover ._Ahz4c:not(._2uClD){background-color:#d9d9d9}._NJw9v ._4pbio{display:flex;flex-grow:1;align-items:center;min-width:0;padding:14px 46px 13px 12px}._NJw9v ._4pbio._msRMX{flex-direction:row-reverse;justify-content:flex-start}._NJw9v ._4pbio._msRMX ._yWPyK{margin:1px 7px 1px 1px}._NJw9v ._4pbio ._MRqij{text-overflow:ellipsis;overflow:hidden;-webkit-hyphens:auto;hyphens:auto;pointer-events:none;overflow-wrap:break-word;display:-webkit-box;-webkit-box-orient:vertical}._NJw9v ._4pbio ._yWPyK{margin:1px 1px 1px 7px;flex-shrink:0}._NJw9v ._6IUON{position:absolute;right:4px;top:calc(50% - 18px);flex-shrink:0}._NJw9v ._jM3RR{pointer-events:none;position:absolute;top:0;left:0;bottom:0;right:0}._NJw9v:focus{outline:none}._NJw9v._WNXoQ.focus-visible:after,._NJw9v._WNXoQ:focus-visible:after,._NJw9v.focus-visible:after,._NJw9v:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._U2zZc{margin-right:6px}._aQl69{display:flex;border-right:3px solid #e5e5e5;position:-webkit-sticky;position:sticky;left:0;background-color:#fff;z-index:20}._aQl69[focus-within]{z-index:30}._aQl69:focus-within{z-index:30}._Av4Wy{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #eee;flex-shrink:0;font-size:14px;line-height:20px;overflow-wrap:break-word;color:#32363a;position:relative}._Av4Wy ._HhiP4{width:100%;padding:12px 12px 11px;overflow:hidden}._Av4Wy._f9Vm3{background-color:#efefef;border-bottom-color:#dfdfe1}._Av4Wy._ysUDX{flex-grow:1}._Av4Wy:focus{outline:none}._Av4Wy._WNXoQ.focus-visible:after,._Av4Wy._WNXoQ:focus-visible:after,._Av4Wy.focus-visible:after,._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-2px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._Teg50{display:flex!important;min-height:44px!important;align-items:center;justify-content:right;border-bottom:1px solid #eee;flex-shrink:0;position:relative}._Teg50._pFFCQ{border-bottom-color:#d9d9d9;background-color:#fff}._5quOp{display:flex;align-items:center;justify-content:center;min-height:44px;width:40px;border-bottom:1px solid #eee;padding:12px 12px 11px;flex-shrink:0;cursor:pointer}._5quOp._pFFCQ{border-bottom-color:#d9d9d9;padding:14px 12px 13px}._5quOp:focus input~span,._5quOp:hover input~span{border-color:#0b6ed0}._P2pZa{justify-content:flex-start}._OHIyY{justify-content:center;text-align:center}._msRMX{justify-content:flex-end;text-align:right}._5PSSP{display:none}._rp4JQ{opacity:0;height:0;width:0;overflow:hidden}._1O2QN,._rp4JQ{position:absolute}._1O2QN{
|
|
4
|
-
var styles = {"advancedTable":"_-5cPq","advancedTablePaginationContainer":"_ytUo4","advancedTablePagination":"_EOKSw","advancedTableColumnHeadersRowGroup":"_PuAcQ","advancedTableColumnHeaders":"_vDAE0","advancedTableRowChild":"_BjdNb","pinnedContainer":"_aQl69","advancedTableRowGroup":"_QQmA0","advancedTableRowRestrictedWidth":"_CVqPg","advancedTableRow":"_02ABn","hasRowAction":"_-V45P","advancedTableExpandRowSpacer":"_Teg50","isSelected":"_a2wz1","advancedTableCheckbox":"_5quOp","advancedTableCell":"_Av4Wy","showFocusRing":"_WNXoQ","advancedTableColumnHeader":"_NJw9v","fillRemainingSpace":"_ysUDX","isSortable":"_nVwTc","isDragging":"_f9Vm3","isSorted":"_wtiMS","dropTargetLine":"_zcv4x","dropTargetLeft":"_n9XSz","dropTargetRight":"_Txoqg","dropTargetMarker":"_cRwS-","resizeHandle":"_ATviE","resizeLine":"_Ahz4c","isResizing":"_2uClD","advancedTableColumnHeaderLabel":"_4pbio","rightAligned":"_msRMX","sortIcon":"_yWPyK","advancedTableColumnHeaderLabelText":"_MRqij","advancedTableColumnHeaderMenu":"_6IUON","advancedTableColumnHeaderMenuHiddenAnchor":"_jM3RR","advancedTableColumnHeaderMenuItemIcon":"_U2zZc","advancedTableCellContainer":"_HhiP4","header":"_pFFCQ","leftAligned":"_P2pZa","centerAligned":"_OHIyY","hiddenDescription":"_5PSSP","hiddenLiveRegion":"_rp4JQ","dragPreview":"_1O2QN","rowActionMenuPane":"_NlBzi"};
|
|
5
|
-
var stylesheet="._-5cPq{overflow:auto;position:relative;max-width:100%;max-height:100%}._-5cPq,._ytUo4{background-color:#fff}._ytUo4{height:70px;z-index:100;display:flex;align-items:flex-end;justify-content:center;position:-webkit-sticky;position:sticky;left:0}._EOKSw{margin-bottom:4px}._PuAcQ{position:-webkit-sticky;position:sticky;top:0;z-index:100}._vDAE0{display:flex}._vDAE0:focus{outline:none}._vDAE0.focus-visible ._BjdNb:after,._vDAE0:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._vDAE0.focus-visible ._BjdNb:last-of-type:after,._vDAE0:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb:first-of-type:after,._vDAE0:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb._aQl69:after,._vDAE0:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._QQmA0{padding-right:3px}._CVqPg{max-width:100%;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}._02ABn{display:flex}._02ABn._-V45P ._BjdNb,._02ABn._-V45P ._Teg50{cursor:pointer}._02ABn._a2wz1 ._BjdNb,._02ABn._a2wz1 ._Teg50{background-color:rgba(11,110,208,.08);font-weight:500;box-shadow:inset 0 -1px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69,._02ABn._a2wz1 ._Teg50._aQl69{background-color:#fff;box-shadow:inset 0 -2px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69 ._5quOp,._02ABn._a2wz1 ._BjdNb._aQl69 ._Av4Wy,._02ABn._a2wz1 ._BjdNb._aQl69 ._Teg50,._02ABn._a2wz1 ._Teg50._aQl69 ._5quOp,._02ABn._a2wz1 ._Teg50._aQl69 ._Av4Wy,._02ABn._a2wz1 ._Teg50._aQl69 ._Teg50{background-color:rgba(11,110,208,.08)}._02ABn._-V45P:hover:not(._a2wz1) ._BjdNb,._02ABn._-V45P:hover:not(._a2wz1) ._Teg50{background-color:#f9f9f9}._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._BjdNb,._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._Teg50{background-color:#f3f3f3}._02ABn:focus{outline:none}._02ABn.focus-visible ._BjdNb:after,._02ABn:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn.focus-visible ._BjdNb:last-of-type:after,._02ABn:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb:first-of-type:after,._02ABn:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb._aQl69:after,._02ABn:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:last-of-type:focus{outline:none}._02ABn:last-of-type.focus-visible ._BjdNb:after,._02ABn:last-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:last-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:last-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._02ABn:last-of-type ._Av4Wy:focus{outline:none}._02ABn:last-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:last-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:last-of-type ._Av4Wy.focus-visible:after,._02ABn:last-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._02ABn:first-of-type:focus{outline:none}._02ABn:first-of-type.focus-visible ._BjdNb:after,._02ABn:first-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:first-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:first-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:first-of-type ._Av4Wy:focus{outline:none}._02ABn:first-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:first-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:first-of-type ._Av4Wy.focus-visible:after,._02ABn:first-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._NJw9v{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #d9d9d9;flex-shrink:0;font-size:12px;line-height:16px;font-weight:700;color:#6a6d70;background-color:#fff;position:relative}._NJw9v._ysUDX{flex-grow:1}._NJw9v._nVwTc{cursor:pointer}._NJw9v._nVwTc:hover:not(._f9Vm3){background-color:#f9f9f9;border-bottom-color:#6a6d70}._NJw9v._nVwTc:active:not(._f9Vm3){background-color:#f3f3f3}._NJw9v._wtiMS:not(._f9Vm3){color:#32363a;fill:#32363a;border-bottom-color:#8a8f94}._NJw9v._f9Vm3{cursor:move;background-color:#efefef;border-bottom-color:#ccc;border-top-left-radius:4px;border-top-right-radius:4px}._NJw9v ._zcv4x{background-color:#d9d9d9;position:absolute;width:1px;top:0;pointer-events:none}._NJw9v ._zcv4x._n9XSz{left:-1px}._NJw9v ._zcv4x._Txoqg{right:0}._NJw9v ._cRwS-{background-color:#0a6ed1;position:absolute;width:3px;top:4px;bottom:4px;border-radius:4px;pointer-events:none}._NJw9v ._cRwS-._n9XSz{left:-2px}._NJw9v ._cRwS-._Txoqg{right:-1px}._NJw9v:first-of-type ._n9XSz._zcv4x{left:0;width:2px;border-left:1px solid #fff}._NJw9v:first-of-type ._n9XSz._cRwS-{left:0}._NJw9v:last-of-type ._Txoqg._zcv4x{right:0;width:2px;border-right:1px solid #fff}._NJw9v:last-of-type ._Txoqg._cRwS-{right:0}._NJw9v ._ATviE{position:absolute;width:6px;right:-3px;top:0;cursor:ew-resize;z-index:50}._NJw9v ._ATviE ._Ahz4c{position:absolute;width:2px;right:2px;top:0;bottom:0}._NJw9v ._ATviE ._Ahz4c._2uClD{background-color:#0a6ed1}._NJw9v ._ATviE:hover ._Ahz4c:not(._2uClD){background-color:#d9d9d9}._NJw9v ._4pbio{display:flex;flex-grow:1;align-items:center;min-width:0;padding:14px 46px 13px 12px}._NJw9v ._4pbio._msRMX{flex-direction:row-reverse;justify-content:flex-start}._NJw9v ._4pbio._msRMX ._yWPyK{margin:1px 7px 1px 1px}._NJw9v ._4pbio ._MRqij{text-overflow:ellipsis;overflow:hidden;-webkit-hyphens:auto;hyphens:auto;pointer-events:none;overflow-wrap:break-word;display:-webkit-box;-webkit-box-orient:vertical}._NJw9v ._4pbio ._yWPyK{margin:1px 1px 1px 7px;flex-shrink:0}._NJw9v ._6IUON{position:absolute;right:4px;top:calc(50% - 18px);flex-shrink:0}._NJw9v ._jM3RR{pointer-events:none;position:absolute;top:0;left:0;bottom:0;right:0}._NJw9v:focus{outline:none}._NJw9v._WNXoQ.focus-visible:after,._NJw9v._WNXoQ:focus-visible:after,._NJw9v.focus-visible:after,._NJw9v:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._U2zZc{margin-right:6px}._aQl69{display:flex;border-right:3px solid #e5e5e5;position:-webkit-sticky;position:sticky;left:0;background-color:#fff;z-index:20}._aQl69[focus-within]{z-index:30}._aQl69:focus-within{z-index:30}._Av4Wy{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #eee;flex-shrink:0;font-size:14px;line-height:20px;overflow-wrap:break-word;color:#32363a;position:relative}._Av4Wy ._HhiP4{width:100%;padding:12px 12px 11px;overflow:hidden}._Av4Wy._f9Vm3{background-color:#efefef;border-bottom-color:#dfdfe1}._Av4Wy._ysUDX{flex-grow:1}._Av4Wy:focus{outline:none}._Av4Wy._WNXoQ.focus-visible:after,._Av4Wy._WNXoQ:focus-visible:after,._Av4Wy.focus-visible:after,._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-2px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._Teg50{display:flex!important;min-height:44px!important;align-items:center;justify-content:right;border-bottom:1px solid #eee;flex-shrink:0;position:relative}._Teg50._pFFCQ{border-bottom-color:#d9d9d9;background-color:#fff}._5quOp{display:flex;align-items:center;justify-content:center;min-height:44px;width:40px;border-bottom:1px solid #eee;padding:12px 12px 11px;flex-shrink:0;cursor:pointer}._5quOp._pFFCQ{border-bottom-color:#d9d9d9;padding:14px 12px 13px}._5quOp:focus input~span,._5quOp:hover input~span{border-color:#0b6ed0}._P2pZa{justify-content:flex-start}._OHIyY{justify-content:center;text-align:center}._msRMX{justify-content:flex-end;text-align:right}._5PSSP{display:none}._rp4JQ{opacity:0;height:0;width:0;overflow:hidden}._1O2QN,._rp4JQ{position:absolute}._1O2QN{
|
|
3
|
+
var css_248z = "._-5cPq{overflow:auto;position:relative;max-width:100%;max-height:100%}._-5cPq,._ytUo4{background-color:#fff}._ytUo4{height:70px;z-index:100;display:flex;align-items:flex-end;justify-content:center;position:-webkit-sticky;position:sticky;left:0}._EOKSw{margin-bottom:4px}._PuAcQ{position:-webkit-sticky;position:sticky;top:0;z-index:100}._vDAE0{display:flex}._vDAE0:focus{outline:none}._vDAE0.focus-visible ._BjdNb:after,._vDAE0:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._vDAE0.focus-visible ._BjdNb:last-of-type:after,._vDAE0:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb:first-of-type:after,._vDAE0:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb._aQl69:after,._vDAE0:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._QQmA0{padding-right:3px}._CVqPg{max-width:100%;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}._02ABn{display:flex}._02ABn._-V45P ._BjdNb,._02ABn._-V45P ._Teg50{cursor:pointer}._02ABn._a2wz1 ._BjdNb,._02ABn._a2wz1 ._Teg50{background-color:rgba(11,110,208,.08);font-weight:500;box-shadow:inset 0 -1px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69,._02ABn._a2wz1 ._Teg50._aQl69{background-color:#fff;box-shadow:inset 0 -2px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69 ._5quOp,._02ABn._a2wz1 ._BjdNb._aQl69 ._Av4Wy,._02ABn._a2wz1 ._BjdNb._aQl69 ._Teg50,._02ABn._a2wz1 ._Teg50._aQl69 ._5quOp,._02ABn._a2wz1 ._Teg50._aQl69 ._Av4Wy,._02ABn._a2wz1 ._Teg50._aQl69 ._Teg50{background-color:rgba(11,110,208,.08)}._02ABn._-V45P:hover:not(._a2wz1) ._BjdNb,._02ABn._-V45P:hover:not(._a2wz1) ._Teg50{background-color:#f9f9f9}._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._BjdNb,._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._Teg50{background-color:#f3f3f3}._02ABn:focus{outline:none}._02ABn.focus-visible ._BjdNb:after,._02ABn:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn.focus-visible ._BjdNb:last-of-type:after,._02ABn:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb:first-of-type:after,._02ABn:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb._aQl69:after,._02ABn:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:last-of-type:focus{outline:none}._02ABn:last-of-type.focus-visible ._BjdNb:after,._02ABn:last-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:last-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:last-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._02ABn:last-of-type ._Av4Wy:focus{outline:none}._02ABn:last-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:last-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:last-of-type ._Av4Wy.focus-visible:after,._02ABn:last-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._02ABn:first-of-type:focus{outline:none}._02ABn:first-of-type.focus-visible ._BjdNb:after,._02ABn:first-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:first-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:first-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:first-of-type ._Av4Wy:focus{outline:none}._02ABn:first-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:first-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:first-of-type ._Av4Wy.focus-visible:after,._02ABn:first-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._NJw9v{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #d9d9d9;flex-shrink:0;font-size:12px;line-height:16px;font-weight:700;color:#6a6d70;background-color:#fff;position:relative}._NJw9v._ysUDX{flex-grow:1}._NJw9v._nVwTc{cursor:pointer}._NJw9v._nVwTc:hover:not(._f9Vm3){background-color:#f9f9f9;border-bottom-color:#6a6d70}._NJw9v._nVwTc:active:not(._f9Vm3){background-color:#f3f3f3}._NJw9v._wtiMS:not(._f9Vm3){color:#32363a;fill:#32363a;border-bottom-color:#8a8f94}._NJw9v._f9Vm3{cursor:move!important;background-color:#efefef;border-bottom-color:#ccc;border-top-left-radius:4px;border-top-right-radius:4px}._NJw9v ._zcv4x{background-color:#d9d9d9;position:absolute;width:1px;top:0;pointer-events:none}._NJw9v ._zcv4x._n9XSz{left:-1px}._NJw9v ._zcv4x._Txoqg{right:0}._NJw9v ._cRwS-{background-color:#0a6ed1;position:absolute;width:3px;top:4px;bottom:4px;border-radius:4px;pointer-events:none}._NJw9v ._cRwS-._n9XSz{left:-2px}._NJw9v ._cRwS-._Txoqg{right:-1px}._NJw9v:first-of-type ._n9XSz._zcv4x{left:0;width:2px;border-left:1px solid #fff}._NJw9v:first-of-type ._n9XSz._cRwS-{left:0}._NJw9v:last-of-type ._Txoqg._zcv4x{right:0;width:2px;border-right:1px solid #fff}._NJw9v:last-of-type ._Txoqg._cRwS-{right:0}._NJw9v ._ATviE{position:absolute;width:6px;right:-3px;top:0;cursor:ew-resize;z-index:50}._NJw9v ._ATviE ._Ahz4c{position:absolute;width:2px;right:2px;top:0;bottom:0}._NJw9v ._ATviE ._Ahz4c._2uClD{background-color:#0a6ed1}._NJw9v ._ATviE:hover ._Ahz4c:not(._2uClD){background-color:#d9d9d9}._NJw9v ._4pbio{display:flex;flex-grow:1;align-items:center;min-width:0;padding:14px 46px 13px 12px}._NJw9v ._4pbio._msRMX{flex-direction:row-reverse;justify-content:flex-start}._NJw9v ._4pbio._msRMX ._yWPyK{margin:1px 7px 1px 1px}._NJw9v ._4pbio ._MRqij{text-overflow:ellipsis;overflow:hidden;-webkit-hyphens:auto;hyphens:auto;pointer-events:none;overflow-wrap:break-word;display:-webkit-box;-webkit-box-orient:vertical}._NJw9v ._4pbio ._yWPyK{margin:1px 1px 1px 7px;flex-shrink:0}._NJw9v ._6IUON{position:absolute;right:4px;top:calc(50% - 18px);flex-shrink:0}._NJw9v ._jM3RR{pointer-events:none;position:absolute;top:0;left:0;bottom:0;right:0}._NJw9v:focus{outline:none}._NJw9v._WNXoQ.focus-visible:after,._NJw9v._WNXoQ:focus-visible:after,._NJw9v.focus-visible:after,._NJw9v:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._U2zZc{margin-right:6px}._aQl69{display:flex;border-right:3px solid #e5e5e5;position:-webkit-sticky;position:sticky;left:0;background-color:#fff;z-index:20}._aQl69[focus-within]{z-index:30}._aQl69:focus-within{z-index:30}._Av4Wy{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #eee;flex-shrink:0;font-size:14px;line-height:20px;overflow-wrap:break-word;color:#32363a;position:relative}._Av4Wy ._HhiP4{width:100%;padding:12px 12px 11px;overflow:hidden}._Av4Wy._f9Vm3{background-color:#efefef;border-bottom-color:#dfdfe1}._Av4Wy._ysUDX{flex-grow:1}._Av4Wy:focus{outline:none}._Av4Wy._WNXoQ.focus-visible:after,._Av4Wy._WNXoQ:focus-visible:after,._Av4Wy.focus-visible:after,._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-2px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._Teg50{display:flex!important;min-height:44px!important;align-items:center;justify-content:right;border-bottom:1px solid #eee;flex-shrink:0;position:relative}._Teg50._pFFCQ{border-bottom-color:#d9d9d9;background-color:#fff}._5quOp{display:flex;align-items:center;justify-content:center;min-height:44px;width:40px;border-bottom:1px solid #eee;padding:12px 12px 11px;flex-shrink:0;cursor:pointer}._5quOp._pFFCQ{border-bottom-color:#d9d9d9;padding:14px 12px 13px}._5quOp:focus input~span,._5quOp:hover input~span{border-color:#0b6ed0}._P2pZa{justify-content:flex-start}._OHIyY{justify-content:center;text-align:center}._msRMX{justify-content:flex-end;text-align:right}._5PSSP{display:none}._rp4JQ{opacity:0;height:0;width:0;overflow:hidden}._1O2QN,._rp4JQ{position:absolute}._1O2QN{background-color:rgba(11,110,208,.08);border-radius:4px;z-index:1000}._1O2QN,._dhJm1{cursor:move;pointer-events:none}._NlBzi{max-width:250px;min-width:150px!important}";
|
|
4
|
+
var styles = {"advancedTable":"_-5cPq","advancedTablePaginationContainer":"_ytUo4","advancedTablePagination":"_EOKSw","advancedTableColumnHeadersRowGroup":"_PuAcQ","advancedTableColumnHeaders":"_vDAE0","advancedTableRowChild":"_BjdNb","pinnedContainer":"_aQl69","advancedTableRowGroup":"_QQmA0","advancedTableRowRestrictedWidth":"_CVqPg","advancedTableRow":"_02ABn","hasRowAction":"_-V45P","advancedTableExpandRowSpacer":"_Teg50","isSelected":"_a2wz1","advancedTableCheckbox":"_5quOp","advancedTableCell":"_Av4Wy","showFocusRing":"_WNXoQ","advancedTableColumnHeader":"_NJw9v","fillRemainingSpace":"_ysUDX","isSortable":"_nVwTc","isDragging":"_f9Vm3","isSorted":"_wtiMS","dropTargetLine":"_zcv4x","dropTargetLeft":"_n9XSz","dropTargetRight":"_Txoqg","dropTargetMarker":"_cRwS-","resizeHandle":"_ATviE","resizeLine":"_Ahz4c","isResizing":"_2uClD","advancedTableColumnHeaderLabel":"_4pbio","rightAligned":"_msRMX","sortIcon":"_yWPyK","advancedTableColumnHeaderLabelText":"_MRqij","advancedTableColumnHeaderMenu":"_6IUON","advancedTableColumnHeaderMenuHiddenAnchor":"_jM3RR","advancedTableColumnHeaderMenuItemIcon":"_U2zZc","advancedTableCellContainer":"_HhiP4","header":"_pFFCQ","leftAligned":"_P2pZa","centerAligned":"_OHIyY","hiddenDescription":"_5PSSP","hiddenLiveRegion":"_rp4JQ","dragPreview":"_1O2QN","isColumnDragging":"_dhJm1","rowActionMenuPane":"_NlBzi"};
|
|
5
|
+
var stylesheet="._-5cPq{overflow:auto;position:relative;max-width:100%;max-height:100%}._-5cPq,._ytUo4{background-color:#fff}._ytUo4{height:70px;z-index:100;display:flex;align-items:flex-end;justify-content:center;position:-webkit-sticky;position:sticky;left:0}._EOKSw{margin-bottom:4px}._PuAcQ{position:-webkit-sticky;position:sticky;top:0;z-index:100}._vDAE0{display:flex}._vDAE0:focus{outline:none}._vDAE0.focus-visible ._BjdNb:after,._vDAE0:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._vDAE0.focus-visible ._BjdNb:last-of-type:after,._vDAE0:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb:first-of-type:after,._vDAE0:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._vDAE0.focus-visible ._BjdNb._aQl69:after,._vDAE0:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._QQmA0{padding-right:3px}._CVqPg{max-width:100%;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}._02ABn{display:flex}._02ABn._-V45P ._BjdNb,._02ABn._-V45P ._Teg50{cursor:pointer}._02ABn._a2wz1 ._BjdNb,._02ABn._a2wz1 ._Teg50{background-color:rgba(11,110,208,.08);font-weight:500;box-shadow:inset 0 -1px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69,._02ABn._a2wz1 ._Teg50._aQl69{background-color:#fff;box-shadow:inset 0 -2px 0 0 #0b6ed0}._02ABn._a2wz1 ._BjdNb._aQl69 ._5quOp,._02ABn._a2wz1 ._BjdNb._aQl69 ._Av4Wy,._02ABn._a2wz1 ._BjdNb._aQl69 ._Teg50,._02ABn._a2wz1 ._Teg50._aQl69 ._5quOp,._02ABn._a2wz1 ._Teg50._aQl69 ._Av4Wy,._02ABn._a2wz1 ._Teg50._aQl69 ._Teg50{background-color:rgba(11,110,208,.08)}._02ABn._-V45P:hover:not(._a2wz1) ._BjdNb,._02ABn._-V45P:hover:not(._a2wz1) ._Teg50{background-color:#f9f9f9}._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._BjdNb,._02ABn._-V45P:active:not(._a2wz1):not(._02ABn._-V45P:active:not(._a2wz1):has(._5quOp:active)) ._Teg50{background-color:#f3f3f3}._02ABn:focus{outline:none}._02ABn.focus-visible ._BjdNb:after,._02ABn:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn.focus-visible ._BjdNb:last-of-type:after,._02ABn:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb:first-of-type:after,._02ABn:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn.focus-visible ._BjdNb._aQl69:after,._02ABn:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:last-of-type:focus{outline:none}._02ABn:last-of-type.focus-visible ._BjdNb:after,._02ABn:last-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:-2px;bottom:0;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:last-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:last-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:last-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:last-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:1px}._02ABn:last-of-type ._Av4Wy:focus{outline:none}._02ABn:last-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:last-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:last-of-type ._Av4Wy.focus-visible:after,._02ABn:last-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._02ABn:first-of-type:focus{outline:none}._02ABn:first-of-type.focus-visible ._BjdNb:after,._02ABn:first-of-type:focus-visible ._BjdNb:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-bottom:2px solid #0a3f88;border-top:2px solid #0a3f88;z-index:50}._02ABn:first-of-type.focus-visible ._BjdNb:last-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:last-of-type:after{border-top-right-radius:2px;border-bottom-right-radius:2px;border-right:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb:first-of-type:after,._02ABn:first-of-type:focus-visible ._BjdNb:first-of-type:after{border-top-left-radius:2px;border-bottom-left-radius:2px;border-left:2px solid #0a3f88}._02ABn:first-of-type.focus-visible ._BjdNb._aQl69:after,._02ABn:first-of-type:focus-visible ._BjdNb._aQl69:after{right:-3px;bottom:0}._02ABn:first-of-type ._Av4Wy:focus{outline:none}._02ABn:first-of-type ._Av4Wy._WNXoQ.focus-visible:after,._02ABn:first-of-type ._Av4Wy._WNXoQ:focus-visible:after,._02ABn:first-of-type ._Av4Wy.focus-visible:after,._02ABn:first-of-type ._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._NJw9v{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #d9d9d9;flex-shrink:0;font-size:12px;line-height:16px;font-weight:700;color:#6a6d70;background-color:#fff;position:relative}._NJw9v._ysUDX{flex-grow:1}._NJw9v._nVwTc{cursor:pointer}._NJw9v._nVwTc:hover:not(._f9Vm3){background-color:#f9f9f9;border-bottom-color:#6a6d70}._NJw9v._nVwTc:active:not(._f9Vm3){background-color:#f3f3f3}._NJw9v._wtiMS:not(._f9Vm3){color:#32363a;fill:#32363a;border-bottom-color:#8a8f94}._NJw9v._f9Vm3{cursor:move!important;background-color:#efefef;border-bottom-color:#ccc;border-top-left-radius:4px;border-top-right-radius:4px}._NJw9v ._zcv4x{background-color:#d9d9d9;position:absolute;width:1px;top:0;pointer-events:none}._NJw9v ._zcv4x._n9XSz{left:-1px}._NJw9v ._zcv4x._Txoqg{right:0}._NJw9v ._cRwS-{background-color:#0a6ed1;position:absolute;width:3px;top:4px;bottom:4px;border-radius:4px;pointer-events:none}._NJw9v ._cRwS-._n9XSz{left:-2px}._NJw9v ._cRwS-._Txoqg{right:-1px}._NJw9v:first-of-type ._n9XSz._zcv4x{left:0;width:2px;border-left:1px solid #fff}._NJw9v:first-of-type ._n9XSz._cRwS-{left:0}._NJw9v:last-of-type ._Txoqg._zcv4x{right:0;width:2px;border-right:1px solid #fff}._NJw9v:last-of-type ._Txoqg._cRwS-{right:0}._NJw9v ._ATviE{position:absolute;width:6px;right:-3px;top:0;cursor:ew-resize;z-index:50}._NJw9v ._ATviE ._Ahz4c{position:absolute;width:2px;right:2px;top:0;bottom:0}._NJw9v ._ATviE ._Ahz4c._2uClD{background-color:#0a6ed1}._NJw9v ._ATviE:hover ._Ahz4c:not(._2uClD){background-color:#d9d9d9}._NJw9v ._4pbio{display:flex;flex-grow:1;align-items:center;min-width:0;padding:14px 46px 13px 12px}._NJw9v ._4pbio._msRMX{flex-direction:row-reverse;justify-content:flex-start}._NJw9v ._4pbio._msRMX ._yWPyK{margin:1px 7px 1px 1px}._NJw9v ._4pbio ._MRqij{text-overflow:ellipsis;overflow:hidden;-webkit-hyphens:auto;hyphens:auto;pointer-events:none;overflow-wrap:break-word;display:-webkit-box;-webkit-box-orient:vertical}._NJw9v ._4pbio ._yWPyK{margin:1px 1px 1px 7px;flex-shrink:0}._NJw9v ._6IUON{position:absolute;right:4px;top:calc(50% - 18px);flex-shrink:0}._NJw9v ._jM3RR{pointer-events:none;position:absolute;top:0;left:0;bottom:0;right:0}._NJw9v:focus{outline:none}._NJw9v._WNXoQ.focus-visible:after,._NJw9v._WNXoQ:focus-visible:after,._NJw9v.focus-visible:after,._NJw9v:focus-visible:after{content:\"\";display:block;position:absolute;top:0;bottom:-1px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._U2zZc{margin-right:6px}._aQl69{display:flex;border-right:3px solid #e5e5e5;position:-webkit-sticky;position:sticky;left:0;background-color:#fff;z-index:20}._aQl69[focus-within]{z-index:30}._aQl69:focus-within{z-index:30}._Av4Wy{display:flex;align-items:center;min-height:44px;width:200px;min-width:80px;border-bottom:1px solid #eee;flex-shrink:0;font-size:14px;line-height:20px;overflow-wrap:break-word;color:#32363a;position:relative}._Av4Wy ._HhiP4{width:100%;padding:12px 12px 11px;overflow:hidden}._Av4Wy._f9Vm3{background-color:#efefef;border-bottom-color:#dfdfe1}._Av4Wy._ysUDX{flex-grow:1}._Av4Wy:focus{outline:none}._Av4Wy._WNXoQ.focus-visible:after,._Av4Wy._WNXoQ:focus-visible:after,._Av4Wy.focus-visible:after,._Av4Wy:focus-visible:after{content:\"\";display:block;position:absolute;top:-2px;bottom:-2px;left:0;right:0;border-radius:2px;border:2px solid #0a3f88;z-index:10}._Teg50{display:flex!important;min-height:44px!important;align-items:center;justify-content:right;border-bottom:1px solid #eee;flex-shrink:0;position:relative}._Teg50._pFFCQ{border-bottom-color:#d9d9d9;background-color:#fff}._5quOp{display:flex;align-items:center;justify-content:center;min-height:44px;width:40px;border-bottom:1px solid #eee;padding:12px 12px 11px;flex-shrink:0;cursor:pointer}._5quOp._pFFCQ{border-bottom-color:#d9d9d9;padding:14px 12px 13px}._5quOp:focus input~span,._5quOp:hover input~span{border-color:#0b6ed0}._P2pZa{justify-content:flex-start}._OHIyY{justify-content:center;text-align:center}._msRMX{justify-content:flex-end;text-align:right}._5PSSP{display:none}._rp4JQ{opacity:0;height:0;width:0;overflow:hidden}._1O2QN,._rp4JQ{position:absolute}._1O2QN{background-color:rgba(11,110,208,.08);border-radius:4px;z-index:1000}._1O2QN,._dhJm1{cursor:move;pointer-events:none}._NlBzi{max-width:250px;min-width:150px!important}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|
|
@@ -4,6 +4,7 @@ import styles from './AdvancedTable2.js';
|
|
|
4
4
|
import Check from '../../components/Checkbox/Check.js';
|
|
5
5
|
import '../../utils/index.js';
|
|
6
6
|
import '../../hooks/index.js';
|
|
7
|
+
import { useAdvancedTableDnDContext } from './AdvancedTableDnDContext.js';
|
|
7
8
|
import useTranslation from '../../utils/Translation/useTranslation.js';
|
|
8
9
|
import useScreenReaderAnnouncement from '../../hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement.js';
|
|
9
10
|
|
|
@@ -21,6 +22,9 @@ const AdvancedTableCheckbox = _ref => {
|
|
|
21
22
|
const {
|
|
22
23
|
translate
|
|
23
24
|
} = useTranslation();
|
|
25
|
+
const {
|
|
26
|
+
isDragging
|
|
27
|
+
} = useAdvancedTableDnDContext();
|
|
24
28
|
const label = useMemo(() => {
|
|
25
29
|
const labels = {
|
|
26
30
|
true: translate('checked'),
|
|
@@ -39,7 +43,8 @@ const AdvancedTableCheckbox = _ref => {
|
|
|
39
43
|
"data-testid": dataTestId,
|
|
40
44
|
onClick: onClick,
|
|
41
45
|
className: classNames(styles.advancedTableCheckbox, className, {
|
|
42
|
-
[styles.header]: variant === 'header'
|
|
46
|
+
[styles.header]: variant === 'header',
|
|
47
|
+
[styles.isColumnDragging]: isDragging
|
|
43
48
|
}),
|
|
44
49
|
role: "presentation"
|
|
45
50
|
}, /*#__PURE__*/React__default.createElement(Check, {
|
|
@@ -10,6 +10,7 @@ import '../../icons/index.es.js';
|
|
|
10
10
|
import '../../utils/index.js';
|
|
11
11
|
import '../../hooks/index.js';
|
|
12
12
|
import useComputedWidth from './useComputedWidth.js';
|
|
13
|
+
import { useAdvancedTableDnDContext } from './AdvancedTableDnDContext.js';
|
|
13
14
|
import useEventListener from '../../hooks/useEventListener/useEventListener.js';
|
|
14
15
|
import useTranslation from '../../utils/Translation/useTranslation.js';
|
|
15
16
|
import Tooltip from '../../components/Tooltip/Tooltip.js';
|
|
@@ -56,6 +57,9 @@ const AdvancedTableColumnHeader = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
56
57
|
const [ellipsisShown, setEllipsisShown] = useState();
|
|
57
58
|
const columnHeaderRef = useRef(null);
|
|
58
59
|
const labelContainerRef = useRef(null);
|
|
60
|
+
const {
|
|
61
|
+
isDragging: isUserDragging
|
|
62
|
+
} = useAdvancedTableDnDContext();
|
|
59
63
|
const isSortable = Boolean(sortOptions === null || sortOptions === void 0 ? void 0 : sortOptions.length);
|
|
60
64
|
const isSorted = isSortable && selectedSortOption.columnId === id && selectedSortOption.index >= 0 && selectedSortOption.index < (sortOptions === null || sortOptions === void 0 ? void 0 : sortOptions.length) && (selectedSortOption.direction === 'ascending' || selectedSortOption.direction === 'descending');
|
|
61
65
|
const selectedSortIndex = isSorted ? selectedSortOption.index : -1;
|
|
@@ -94,7 +98,8 @@ const AdvancedTableColumnHeader = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
94
98
|
const hasDraggableColumns = !disableUserPinnableColumns && !disableUserReorderableColumns && !isRowActionMenuColumn;
|
|
95
99
|
const {
|
|
96
100
|
dragRef,
|
|
97
|
-
dropRef
|
|
101
|
+
dropRef,
|
|
102
|
+
listeners
|
|
98
103
|
} = useDragAndDrop({
|
|
99
104
|
isEnabled: hasDraggableColumns,
|
|
100
105
|
id,
|
|
@@ -247,7 +252,7 @@ const AdvancedTableColumnHeader = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
247
252
|
return /*#__PURE__*/React__default.createElement(Tooltip, {
|
|
248
253
|
content: label,
|
|
249
254
|
disabled: !ellipsisShown
|
|
250
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
255
|
+
}, /*#__PURE__*/React__default.createElement("div", _extends({
|
|
251
256
|
role: "columnheader",
|
|
252
257
|
"data-testid": dataTestId,
|
|
253
258
|
"aria-rowindex": 1,
|
|
@@ -271,13 +276,15 @@ const AdvancedTableColumnHeader = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
271
276
|
[styles.isSorted]: isSorted,
|
|
272
277
|
[styles.showFocusRing]: isHiddenMenuOpen,
|
|
273
278
|
[styles.isDragging]: isDragging,
|
|
274
|
-
[styles.fillRemainingSpace]: width === undefined
|
|
279
|
+
[styles.fillRemainingSpace]: width === undefined,
|
|
280
|
+
[styles.isColumnDragging]: isUserDragging
|
|
275
281
|
}),
|
|
276
282
|
style: {
|
|
277
283
|
width: computedWidth
|
|
278
284
|
},
|
|
279
|
-
ref: mergeRefs(columnHeaderRef, dragRef, dropRef, ref)
|
|
280
|
-
|
|
285
|
+
ref: mergeRefs(columnHeaderRef, dragRef, dropRef, ref),
|
|
286
|
+
draggable: hasDraggableColumns
|
|
287
|
+
}, listeners), /*#__PURE__*/React__default.createElement("div", {
|
|
281
288
|
role: isSortable ? 'button' : undefined,
|
|
282
289
|
className: classNames(styles.advancedTableColumnHeaderLabel, {
|
|
283
290
|
[styles.leftAligned]: alignment === 'left',
|
|
@@ -298,7 +305,9 @@ const AdvancedTableColumnHeader = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
298
305
|
anchor: /*#__PURE__*/React__default.createElement(IconButton, {
|
|
299
306
|
tabIndex: -1,
|
|
300
307
|
"aria-hidden": "true",
|
|
301
|
-
className: styles.advancedTableColumnHeaderMenu
|
|
308
|
+
className: classNames(styles.advancedTableColumnHeaderMenu, {
|
|
309
|
+
[styles.isColumnDragging]: isUserDragging
|
|
310
|
+
})
|
|
302
311
|
}, /*#__PURE__*/React__default.createElement(ChevronDownIcon, null))
|
|
303
312
|
})), /*#__PURE__*/React__default.createElement(AdvancedTableColumnHeaderMenu, _extends({}, commonMenuProps, {
|
|
304
313
|
isOpen: isHiddenMenuOpen,
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React__default, { createContext, useState, useMemo, useContext } from 'react';
|
|
2
|
+
import { DndContext } from '@dnd-kit/core';
|
|
3
|
+
import useDragAndDropConfig from './useDragAndDropConfig.js';
|
|
4
|
+
|
|
5
|
+
const defaultAdvancedTableDnDContext = {
|
|
6
|
+
isDragging: false,
|
|
7
|
+
setIsDragging: () => {}
|
|
8
|
+
};
|
|
9
|
+
const AdvancedTableDnDContext = /*#__PURE__*/createContext(defaultAdvancedTableDnDContext);
|
|
10
|
+
const AdvancedTableDnDContextProvider = _ref => {
|
|
11
|
+
let {
|
|
12
|
+
children,
|
|
13
|
+
setColumnOrder,
|
|
14
|
+
setDropTargetSide,
|
|
15
|
+
setPinnedColumns,
|
|
16
|
+
setDropTarget,
|
|
17
|
+
setDragSource,
|
|
18
|
+
dropTargetSide
|
|
19
|
+
} = _ref;
|
|
20
|
+
const [isDragging, setIsDragging] = useState(false);
|
|
21
|
+
const context = useMemo(() => ({
|
|
22
|
+
isDragging,
|
|
23
|
+
setIsDragging
|
|
24
|
+
}), [isDragging]);
|
|
25
|
+
const dndConfig = useDragAndDropConfig(setDragSource, setDropTarget, setDropTargetSide, setPinnedColumns, setColumnOrder, setIsDragging, dropTargetSide);
|
|
26
|
+
return /*#__PURE__*/React__default.createElement(AdvancedTableDnDContext.Provider, {
|
|
27
|
+
value: context
|
|
28
|
+
}, /*#__PURE__*/React__default.createElement(DndContext, dndConfig, children));
|
|
29
|
+
};
|
|
30
|
+
const useAdvancedTableDnDContext = () => useContext(AdvancedTableDnDContext);
|
|
31
|
+
|
|
32
|
+
export { AdvancedTableDnDContextProvider, useAdvancedTableDnDContext };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React__default from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { useDndContext } from '@dnd-kit/core';
|
|
3
3
|
import '../../utils/index.js';
|
|
4
4
|
import styles from './AdvancedTable2.js';
|
|
5
5
|
import Portal from '../../utils/Portal/Portal.js';
|
|
@@ -11,16 +11,14 @@ const AdvancedTableDragPreview = _ref => {
|
|
|
11
11
|
columnHeaderRefs
|
|
12
12
|
} = _ref;
|
|
13
13
|
const {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
const
|
|
21
|
-
const
|
|
22
|
-
const top = (currentOffset === null || currentOffset === void 0 ? void 0 : currentOffset.y) || 0;
|
|
23
|
-
const left = (currentOffset === null || currentOffset === void 0 ? void 0 : currentOffset.x) || 0;
|
|
14
|
+
active
|
|
15
|
+
} = useDndContext();
|
|
16
|
+
const item = active === null || active === void 0 ? void 0 : active.data.current;
|
|
17
|
+
const position = active === null || active === void 0 ? void 0 : active.rect.current.translated;
|
|
18
|
+
const width = (columnHeaderRefs === null || columnHeaderRefs === void 0 || (_columnHeaderRefs$ite = columnHeaderRefs[item === null || item === void 0 ? void 0 : item.columnIndex]) === null || _columnHeaderRefs$ite === void 0 || (_columnHeaderRefs$ite = _columnHeaderRefs$ite.getBoundingClientRect()) === null || _columnHeaderRefs$ite === void 0 ? void 0 : _columnHeaderRefs$ite.width) || 0;
|
|
19
|
+
const height = ((_tableRef$current = tableRef.current) === null || _tableRef$current === void 0 || (_tableRef$current = _tableRef$current.getBoundingClientRect()) === null || _tableRef$current === void 0 ? void 0 : _tableRef$current.height) || 0;
|
|
20
|
+
const top = ((position === null || position === void 0 ? void 0 : position.top) || 0) + window.scrollY;
|
|
21
|
+
const left = ((position === null || position === void 0 ? void 0 : position.left) || 0) + window.scrollX;
|
|
24
22
|
return /*#__PURE__*/React__default.createElement(Portal, null, /*#__PURE__*/React__default.createElement("div", {
|
|
25
23
|
className: styles.dragPreview,
|
|
26
24
|
style: {
|
|
@@ -2,6 +2,7 @@ import _extends from '@babel/runtime-corejs3/helpers/extends';
|
|
|
2
2
|
import React__default, { forwardRef } from 'react';
|
|
3
3
|
import classNames from 'classnames';
|
|
4
4
|
import styles from './AdvancedTable2.js';
|
|
5
|
+
import { useAdvancedTableDnDContext } from './AdvancedTableDnDContext.js';
|
|
5
6
|
|
|
6
7
|
const AdvancedTableRow = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
7
8
|
let {
|
|
@@ -17,6 +18,9 @@ const AdvancedTableRow = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
17
18
|
children,
|
|
18
19
|
...rest
|
|
19
20
|
} = _ref;
|
|
21
|
+
const {
|
|
22
|
+
isDragging
|
|
23
|
+
} = useAdvancedTableDnDContext();
|
|
20
24
|
return /*#__PURE__*/React__default.createElement("div", _extends({}, rest, {
|
|
21
25
|
role: "row",
|
|
22
26
|
"data-testid": dataTestId,
|
|
@@ -28,7 +32,8 @@ const AdvancedTableRow = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
28
32
|
className: classNames(styles.advancedTableRow, {
|
|
29
33
|
[styles.hasRowAction]: hasOnRowSelect,
|
|
30
34
|
[styles.isSelected]: hasOnRowSelect && isSelected,
|
|
31
|
-
[styles.advancedTableRowRestrictedWidth]: restrictedWidth
|
|
35
|
+
[styles.advancedTableRowRestrictedWidth]: restrictedWidth,
|
|
36
|
+
[styles.isColumnDragging]: isDragging
|
|
32
37
|
}),
|
|
33
38
|
ref: isFocusable ? ref : undefined
|
|
34
39
|
}), children);
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import React__default from 'react';
|
|
1
|
+
import React__default, { useMemo } from 'react';
|
|
2
|
+
import classNames from 'classnames';
|
|
2
3
|
import '../../utils/index.js';
|
|
3
4
|
import '../../icons/index.es.js';
|
|
4
5
|
import '../../components/index.js';
|
|
6
|
+
import { useAdvancedTableDnDContext } from './AdvancedTableDnDContext.js';
|
|
5
7
|
import iconButtonStyles from '../../components/IconButton/IconButton2.js';
|
|
6
8
|
import useTranslation from '../../utils/Translation/useTranslation.js';
|
|
7
9
|
import Tooltip from '../../components/Tooltip/Tooltip.js';
|
|
@@ -18,17 +20,24 @@ const AdvancedTableRowExpandButton = _ref => {
|
|
|
18
20
|
const {
|
|
19
21
|
translate
|
|
20
22
|
} = useTranslation();
|
|
23
|
+
const {
|
|
24
|
+
isDragging
|
|
25
|
+
} = useAdvancedTableDnDContext();
|
|
21
26
|
const state = isRowExpanded ? 'expanded' : 'collapsed';
|
|
22
27
|
const labels = {
|
|
23
28
|
expanded: translate('advancedTable.collapseRow'),
|
|
24
29
|
collapsed: translate('advancedTable.expandRow')
|
|
25
30
|
};
|
|
31
|
+
const buttonClasses = useMemo(() => classNames(iconButtonStyles.button, {
|
|
32
|
+
[iconButtonStyles.disabled]: isDragging
|
|
33
|
+
}), [isDragging]);
|
|
26
34
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
27
35
|
onClick: onClick
|
|
28
36
|
}, /*#__PURE__*/React__default.createElement(Tooltip, {
|
|
29
|
-
content: labels[state]
|
|
37
|
+
content: labels[state],
|
|
38
|
+
disabled: isDragging
|
|
30
39
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
31
|
-
className:
|
|
40
|
+
className: buttonClasses,
|
|
32
41
|
"data-testid": dataTestId,
|
|
33
42
|
role: "presentation"
|
|
34
43
|
}, state === 'expanded' ? /*#__PURE__*/React__default.createElement(CaretDownIcon, {
|
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
import { useEffect } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import { getEmptyImage } from 'react-dnd-html5-backend';
|
|
4
|
-
import '../../hooks/index.js';
|
|
5
|
-
import useLatest from '../../hooks/useLatest/useLatest.js';
|
|
2
|
+
import { useDraggable, useDroppable } from '@dnd-kit/core';
|
|
6
3
|
|
|
7
4
|
const useDragAndDrop = _ref => {
|
|
8
5
|
let {
|
|
@@ -12,143 +9,37 @@ const useDragAndDrop = _ref => {
|
|
|
12
9
|
columnIndex,
|
|
13
10
|
columnHeaderRef,
|
|
14
11
|
isPinned,
|
|
15
|
-
setPinnedColumns,
|
|
16
|
-
setColumnOrder,
|
|
17
|
-
setDragSource,
|
|
18
12
|
setDropTarget,
|
|
19
|
-
dropTargetSide,
|
|
20
13
|
setDropTargetSide
|
|
21
14
|
} = _ref;
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
setDropTarget('');
|
|
35
|
-
setDropTargetSide(undefined);
|
|
36
|
-
},
|
|
37
|
-
canDrag: () => isEnabled,
|
|
38
|
-
options: {
|
|
39
|
-
dropEffect: 'move'
|
|
15
|
+
const {
|
|
16
|
+
setNodeRef: dragRef,
|
|
17
|
+
listeners
|
|
18
|
+
} = useDraggable({
|
|
19
|
+
id,
|
|
20
|
+
disabled: !isEnabled,
|
|
21
|
+
data: {
|
|
22
|
+
type: tableId,
|
|
23
|
+
isPinned,
|
|
24
|
+
columnIndex,
|
|
25
|
+
id,
|
|
26
|
+
columnHeaderRef
|
|
40
27
|
}
|
|
41
|
-
})
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
var _monitor$getClientOff, _columnHeaderRef$curr;
|
|
57
|
-
const {
|
|
58
|
-
id: dragSourceId,
|
|
59
|
-
columnIndex: dragSourceColumnIndex,
|
|
60
|
-
isPinned: dragSourceIsPinned
|
|
61
|
-
} = item;
|
|
62
|
-
setDropTarget(id);
|
|
63
|
-
if (id === dragSourceId) {
|
|
64
|
-
setDropTargetSide(undefined);
|
|
65
|
-
return;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
// Calculate which column line is closest
|
|
69
|
-
const dropX = (_monitor$getClientOff = monitor.getClientOffset()) === null || _monitor$getClientOff === void 0 ? void 0 : _monitor$getClientOff.x;
|
|
70
|
-
const {
|
|
71
|
-
x,
|
|
72
|
-
width
|
|
73
|
-
} = (_columnHeaderRef$curr = columnHeaderRef.current) === null || _columnHeaderRef$curr === void 0 ? void 0 : _columnHeaderRef$curr.getBoundingClientRect();
|
|
74
|
-
const diffLeft = Math.abs(dropX - x) || 0;
|
|
75
|
-
const diffRight = Math.abs(dropX - (x + width)) || 0;
|
|
76
|
-
if (diffLeft < diffRight) {
|
|
77
|
-
// hover over left side
|
|
78
|
-
if (columnIndex - dragSourceColumnIndex === 1 && isPinned === dragSourceIsPinned) {
|
|
79
|
-
setDropTargetSide(undefined);
|
|
80
|
-
} else {
|
|
81
|
-
setDropTargetSide('left');
|
|
82
|
-
}
|
|
83
|
-
} else if (diffLeft >= diffRight) {
|
|
84
|
-
// hover over right side
|
|
85
|
-
if (dragSourceColumnIndex - columnIndex === 1 && isPinned === dragSourceIsPinned) {
|
|
86
|
-
setDropTargetSide(undefined);
|
|
87
|
-
} else {
|
|
88
|
-
setDropTargetSide('right');
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
},
|
|
92
|
-
drop: item => {
|
|
93
|
-
const {
|
|
94
|
-
id: dragSourceId,
|
|
95
|
-
columnIndex: dragSourceColumnIndex,
|
|
96
|
-
isPinned: dragSourceIsPinned
|
|
97
|
-
} = item;
|
|
98
|
-
if (id === dragSourceId || dropTargetSideRef.current === undefined) {
|
|
99
|
-
return;
|
|
100
|
-
}
|
|
101
|
-
if (isPinned && !dragSourceIsPinned) {
|
|
102
|
-
// Dragging from an unpinned column onto a pinned column
|
|
103
|
-
setPinnedColumns(pinnedColumns => {
|
|
104
|
-
const newPinnedColumns = [...pinnedColumns];
|
|
105
|
-
const newIndex = dropTargetSideRef.current === 'right' ? columnIndex + 1 : columnIndex;
|
|
106
|
-
newPinnedColumns.splice(newIndex, 0, dragSourceId);
|
|
107
|
-
return newPinnedColumns;
|
|
108
|
-
});
|
|
109
|
-
} else if (!isPinned && dragSourceIsPinned) {
|
|
110
|
-
// Dragging from a pinned column onto an upinned column
|
|
111
|
-
setPinnedColumns(pinnedColumns => {
|
|
112
|
-
const newPinnedColumns = [...pinnedColumns];
|
|
113
|
-
newPinnedColumns.splice(dragSourceColumnIndex, 1);
|
|
114
|
-
return newPinnedColumns;
|
|
115
|
-
});
|
|
116
|
-
setColumnOrder(currentColumnOrder => {
|
|
117
|
-
const newColumnOrder = [...currentColumnOrder];
|
|
118
|
-
const dragSourceColumnOrderIndex = newColumnOrder.indexOf(dragSourceId);
|
|
119
|
-
newColumnOrder.splice(dragSourceColumnOrderIndex, 1);
|
|
120
|
-
const columnOrderIndex = newColumnOrder.indexOf(id);
|
|
121
|
-
const newIndex = dropTargetSideRef.current === 'right' ? columnOrderIndex + 1 : columnOrderIndex;
|
|
122
|
-
newColumnOrder.splice(newIndex, 0, dragSourceId);
|
|
123
|
-
return newColumnOrder;
|
|
124
|
-
});
|
|
125
|
-
} else if (isPinned) {
|
|
126
|
-
// Dragging from a pinned column onto a pinned column
|
|
127
|
-
setPinnedColumns(pinnedColumns => {
|
|
128
|
-
const newPinnedColumns = [...pinnedColumns];
|
|
129
|
-
newPinnedColumns.splice(dragSourceColumnIndex, 1);
|
|
130
|
-
const newIndex = dropTargetSideRef.current === 'right' ? columnIndex + 1 : columnIndex;
|
|
131
|
-
newPinnedColumns.splice(newIndex, 0, dragSourceId);
|
|
132
|
-
return newPinnedColumns;
|
|
133
|
-
});
|
|
134
|
-
} else {
|
|
135
|
-
// Dragging from an upinned column onto an upinned column
|
|
136
|
-
setColumnOrder(currentColumnOrder => {
|
|
137
|
-
const newColumnOrder = [...currentColumnOrder];
|
|
138
|
-
const dropIndex = newColumnOrder.indexOf(dragSourceId);
|
|
139
|
-
newColumnOrder.splice(dropIndex, 1);
|
|
140
|
-
const columnOrderIndex = newColumnOrder.indexOf(id);
|
|
141
|
-
const newIndex = dropTargetSideRef.current === 'right' ? columnOrderIndex + 1 : columnOrderIndex;
|
|
142
|
-
newColumnOrder.splice(newIndex, 0, dragSourceId);
|
|
143
|
-
return newColumnOrder;
|
|
144
|
-
});
|
|
145
|
-
}
|
|
146
|
-
},
|
|
147
|
-
canDrop: () => isEnabled,
|
|
148
|
-
collect: monitor => ({
|
|
149
|
-
isOver: monitor.isOver()
|
|
150
|
-
})
|
|
151
|
-
}), [id, tableId, isPinned, columnIndex, isEnabled, setDropTarget, dropTargetSideRef, setDropTargetSide]);
|
|
28
|
+
});
|
|
29
|
+
const {
|
|
30
|
+
isOver,
|
|
31
|
+
setNodeRef: dropRef
|
|
32
|
+
} = useDroppable({
|
|
33
|
+
id,
|
|
34
|
+
disabled: !isEnabled,
|
|
35
|
+
data: {
|
|
36
|
+
type: tableId,
|
|
37
|
+
isPinned,
|
|
38
|
+
columnIndex,
|
|
39
|
+
id,
|
|
40
|
+
columnHeaderRef
|
|
41
|
+
}
|
|
42
|
+
});
|
|
152
43
|
|
|
153
44
|
// Clear dropTarget when header is no longer being hovered
|
|
154
45
|
useEffect(() => {
|
|
@@ -164,7 +55,8 @@ const useDragAndDrop = _ref => {
|
|
|
164
55
|
}, [id, isOver, setDropTarget, setDropTargetSide]);
|
|
165
56
|
return {
|
|
166
57
|
dragRef,
|
|
167
|
-
dropRef
|
|
58
|
+
dropRef,
|
|
59
|
+
listeners
|
|
168
60
|
};
|
|
169
61
|
};
|
|
170
62
|
|