@elliemae/ds-shuttle-v2 3.70.0-next.4 → 3.70.0-next.41
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/cjs/DSShuttleV2.js.map +2 -2
- package/dist/cjs/config/useAutoCalculated/index.js.map +2 -2
- package/dist/cjs/config/useAutoCalculated/useDataStructure.js.map +2 -2
- package/dist/cjs/config/useStore/useStore.js.map +1 -1
- package/dist/cjs/config/useValidateProps.js.map +2 -2
- package/dist/cjs/constants/index.js +3 -1
- package/dist/cjs/constants/index.js.map +2 -2
- package/dist/cjs/exported-related/ShuttleItem.js +27 -3
- package/dist/cjs/exported-related/ShuttleItem.js.map +2 -2
- package/dist/cjs/parts/Dnd/DndHandle.js +47 -21
- package/dist/cjs/parts/Dnd/DndHandle.js.map +2 -2
- package/dist/cjs/parts/Dnd/DragOverlay.js +1 -1
- package/dist/cjs/parts/Dnd/DragOverlay.js.map +2 -2
- package/dist/cjs/parts/HoC/withConditionalDnDRowContext.js +16 -14
- package/dist/cjs/parts/HoC/withConditionalDnDRowContext.js.map +2 -2
- package/dist/cjs/parts/Item/Item.js +29 -68
- package/dist/cjs/parts/Item/Item.js.map +3 -3
- package/dist/cjs/parts/Item/ItemActions/ItemActions.js +19 -5
- package/dist/cjs/parts/Item/ItemActions/ItemActions.js.map +2 -2
- package/dist/cjs/parts/Item/ItemActions/{useInnerRefHandlers.js → useInnerRefActionHandlers.js} +6 -6
- package/dist/cjs/parts/Item/ItemActions/useInnerRefActionHandlers.js.map +7 -0
- package/dist/cjs/parts/Item/ItemMiddleSection.js +1 -0
- package/dist/cjs/parts/Item/ItemMiddleSection.js.map +2 -2
- package/dist/cjs/parts/Item/ItemSelectionUi/CheckboxSelectionUI.js +72 -0
- package/dist/cjs/parts/Item/ItemSelectionUi/CheckboxSelectionUI.js.map +7 -0
- package/dist/cjs/parts/Item/ItemSelectionUi/ItemSelectionUI.js +83 -0
- package/dist/cjs/parts/Item/ItemSelectionUi/ItemSelectionUI.js.map +7 -0
- package/dist/cjs/parts/{HoC/withConditionalUseSortable.js → Item/ItemSelectionUi/ItemSelectionUI.types.js} +3 -18
- package/dist/cjs/parts/Item/ItemSelectionUi/ItemSelectionUI.types.js.map +7 -0
- package/dist/cjs/parts/Item/{ItemSelection.js → ItemSelectionUi/VerticalBarSelectionUI.js} +14 -12
- package/dist/cjs/parts/Item/ItemSelectionUi/VerticalBarSelectionUI.js.map +7 -0
- package/dist/cjs/parts/Item/useItemInnerRefHandlers.js +73 -0
- package/dist/cjs/parts/Item/useItemInnerRefHandlers.js.map +7 -0
- package/dist/cjs/parts/Panel/bottom/LoadMoreBtn.js +2 -2
- package/dist/cjs/parts/Panel/bottom/LoadMoreBtn.js.map +2 -2
- package/dist/cjs/parts/Panel/bottom/{useInnerRefHandlers.js → useLoadMoreBtnInnerRefHandlers.js} +6 -6
- package/dist/cjs/parts/Panel/bottom/useLoadMoreBtnInnerRefHandlers.js.map +7 -0
- package/dist/cjs/parts/Panel/middle/MultipleSelectionAction.js +65 -33
- package/dist/cjs/parts/Panel/middle/MultipleSelectionAction.js.map +2 -2
- package/dist/cjs/parts/Panel/middle/PanelContentMiddleSection.js +2 -2
- package/dist/cjs/parts/Panel/middle/PanelContentMiddleSection.js.map +2 -2
- package/dist/cjs/parts/Panel/top/SelectionHeader.js.map +2 -2
- package/dist/cjs/react-desc-prop-types.js +8 -4
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/typescript-testing/slot-props.js +181 -0
- package/dist/cjs/typescript-testing/slot-props.js.map +7 -0
- package/dist/cjs/typescript-testing/typescript-shuttle-v2-valid-with-datum.js +159 -0
- package/dist/cjs/typescript-testing/typescript-shuttle-v2-valid-with-datum.js.map +7 -0
- package/dist/cjs/typescript-testing/typescript-shuttle-v2-valid.js +0 -1
- package/dist/cjs/typescript-testing/typescript-shuttle-v2-valid.js.map +2 -2
- package/dist/esm/DSShuttleV2.js.map +2 -2
- package/dist/esm/config/useAutoCalculated/index.js.map +2 -2
- package/dist/esm/config/useAutoCalculated/useDataStructure.js.map +2 -2
- package/dist/esm/config/useStore/useStore.js.map +1 -1
- package/dist/esm/config/useValidateProps.js.map +2 -2
- package/dist/esm/constants/index.js +3 -1
- package/dist/esm/constants/index.js.map +2 -2
- package/dist/esm/exported-related/ShuttleItem.js +28 -4
- package/dist/esm/exported-related/ShuttleItem.js.map +2 -2
- package/dist/esm/parts/Dnd/DndHandle.js +48 -22
- package/dist/esm/parts/Dnd/DndHandle.js.map +2 -2
- package/dist/esm/parts/Dnd/DragOverlay.js +1 -1
- package/dist/esm/parts/Dnd/DragOverlay.js.map +2 -2
- package/dist/esm/parts/HoC/withConditionalDnDRowContext.js +16 -14
- package/dist/esm/parts/HoC/withConditionalDnDRowContext.js.map +2 -2
- package/dist/esm/parts/Item/Item.js +30 -69
- package/dist/esm/parts/Item/Item.js.map +2 -2
- package/dist/esm/parts/Item/ItemActions/ItemActions.js +19 -5
- package/dist/esm/parts/Item/ItemActions/ItemActions.js.map +2 -2
- package/dist/esm/parts/Item/ItemActions/{useInnerRefHandlers.js → useInnerRefActionHandlers.js} +3 -3
- package/dist/esm/parts/Item/ItemActions/useInnerRefActionHandlers.js.map +7 -0
- package/dist/esm/parts/Item/ItemMiddleSection.js +1 -0
- package/dist/esm/parts/Item/ItemMiddleSection.js.map +2 -2
- package/dist/esm/parts/Item/ItemSelectionUi/CheckboxSelectionUI.js +42 -0
- package/dist/esm/parts/Item/ItemSelectionUi/CheckboxSelectionUI.js.map +7 -0
- package/dist/esm/parts/Item/ItemSelectionUi/ItemSelectionUI.js +53 -0
- package/dist/esm/parts/Item/ItemSelectionUi/ItemSelectionUI.js.map +7 -0
- package/dist/esm/parts/Item/ItemSelectionUi/ItemSelectionUI.types.js +2 -0
- package/dist/esm/parts/Item/ItemSelectionUi/ItemSelectionUI.types.js.map +7 -0
- package/dist/esm/parts/Item/{ItemSelection.js → ItemSelectionUi/VerticalBarSelectionUI.js} +11 -9
- package/dist/esm/parts/Item/ItemSelectionUi/VerticalBarSelectionUI.js.map +7 -0
- package/dist/esm/parts/Item/useItemInnerRefHandlers.js +43 -0
- package/dist/esm/parts/Item/useItemInnerRefHandlers.js.map +7 -0
- package/dist/esm/parts/Panel/bottom/LoadMoreBtn.js +2 -2
- package/dist/esm/parts/Panel/bottom/LoadMoreBtn.js.map +2 -2
- package/dist/esm/parts/Panel/bottom/{useInnerRefHandlers.js → useLoadMoreBtnInnerRefHandlers.js} +3 -3
- package/dist/esm/parts/Panel/bottom/useLoadMoreBtnInnerRefHandlers.js.map +7 -0
- package/dist/esm/parts/Panel/middle/MultipleSelectionAction.js +66 -34
- package/dist/esm/parts/Panel/middle/MultipleSelectionAction.js.map +2 -2
- package/dist/esm/parts/Panel/middle/PanelContentMiddleSection.js +2 -2
- package/dist/esm/parts/Panel/middle/PanelContentMiddleSection.js.map +2 -2
- package/dist/esm/parts/Panel/top/SelectionHeader.js.map +2 -2
- package/dist/esm/react-desc-prop-types.js +8 -4
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/typescript-testing/slot-props.js +158 -0
- package/dist/esm/typescript-testing/slot-props.js.map +7 -0
- package/dist/esm/typescript-testing/typescript-shuttle-v2-valid-with-datum.js +136 -0
- package/dist/esm/typescript-testing/typescript-shuttle-v2-valid-with-datum.js.map +7 -0
- package/dist/esm/typescript-testing/typescript-shuttle-v2-valid.js +0 -1
- package/dist/esm/typescript-testing/typescript-shuttle-v2-valid.js.map +2 -2
- package/dist/types/DSShuttleV2.d.ts +2 -2
- package/dist/types/config/useAutoCalculated/index.d.ts +7 -7
- package/dist/types/config/useAutoCalculated/useDataStructure.d.ts +7 -7
- package/dist/types/config/useStore/useStore.d.ts +64 -64
- package/dist/types/config/useValidateProps.d.ts +1 -1
- package/dist/types/constants/index.d.ts +6 -2
- package/dist/types/parts/Dnd/DndHandle.d.ts +3 -10
- package/dist/types/parts/Item/Item.d.ts +1 -5
- package/dist/types/parts/Item/ItemActions/{useInnerRefHandlers.d.ts → useInnerRefActionHandlers.d.ts} +1 -1
- package/dist/types/parts/Item/ItemSelectionUi/CheckboxSelectionUI.d.ts +2 -0
- package/dist/types/parts/Item/ItemSelectionUi/ItemSelectionUI.d.ts +2 -0
- package/dist/types/parts/Item/ItemSelectionUi/ItemSelectionUI.types.d.ts +11 -0
- package/dist/types/parts/Item/ItemSelectionUi/VerticalBarSelectionUI.d.ts +2 -0
- package/dist/types/parts/Item/useItemInnerRefHandlers.d.ts +5 -0
- package/dist/types/parts/Panel/bottom/{useInnerRefHandlers.d.ts → useLoadMoreBtnInnerRefHandlers.d.ts} +1 -1
- package/dist/types/parts/Panel/middle/ItemListWrapper/useGetDatumHydratables.d.ts +2 -2
- package/dist/types/react-desc-prop-types.d.ts +111 -57
- package/package.json +25 -25
- package/dist/cjs/parts/HoC/withConditionalUseSortable.js.map +0 -7
- package/dist/cjs/parts/Item/ItemActions/useInnerRefHandlers.js.map +0 -7
- package/dist/cjs/parts/Item/ItemSelection.js.map +0 -7
- package/dist/cjs/parts/Panel/bottom/useInnerRefHandlers.js.map +0 -7
- package/dist/esm/parts/HoC/withConditionalUseSortable.js +0 -13
- package/dist/esm/parts/HoC/withConditionalUseSortable.js.map +0 -7
- package/dist/esm/parts/Item/ItemActions/useInnerRefHandlers.js.map +0 -7
- package/dist/esm/parts/Item/ItemSelection.js.map +0 -7
- package/dist/esm/parts/Panel/bottom/useInnerRefHandlers.js.map +0 -7
- package/dist/types/parts/HoC/withConditionalUseSortable.d.ts +0 -9
- package/dist/types/parts/Item/ItemSelection.d.ts +0 -3
- package/dist/types/tests/DSShuttlev2.PUI-16059.test.d.ts +0 -1
- package/dist/types/tests/configs/ControlledTestRender.d.ts +0 -1
- package/dist/types/tests/configs/basic.d.ts +0 -24
- package/dist/types/tests/configs/breadcrumb.d.ts +0 -1
- package/dist/types/tests/configs/dnd.d.ts +0 -1
- package/dist/types/tests/configs/filter.d.ts +0 -30
- package/dist/types/tests/configs/loadMore.d.ts +0 -28
- package/dist/types/tests/configs/soft-delete.d.ts +0 -1
- package/dist/types/tests/loadMore/ShuttleV2WithLoadMoreTestable.d.ts +0 -2
- package/dist/types/tests/loadMore/shuttle-v2.load-more.focus.test.d.ts +0 -1
- package/dist/types/tests/loadMore/shuttle-v2.load-more.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.a11y.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.data-testid.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.dnd.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.events.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.exports.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.get-owner-props.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.keyboard.test.d.ts +0 -1
- package/dist/types/tests/shuttle-v2.soft-delete.test.d.ts +0 -1
- package/dist/types/typescript-testing/typescript-shuttle-v2-valid.d.ts +0 -1
|
@@ -28,13 +28,12 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
var Item_exports = {};
|
|
30
30
|
__export(Item_exports, {
|
|
31
|
-
|
|
32
|
-
ItemSortable: () => ItemSortable,
|
|
33
|
-
default: () => Item_default
|
|
31
|
+
ItemSortable: () => ItemSortable
|
|
34
32
|
});
|
|
35
33
|
module.exports = __toCommonJS(Item_exports);
|
|
36
34
|
var React = __toESM(require("react"));
|
|
37
35
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
36
|
+
var import_ds_drag_and_drop = require("@elliemae/ds-drag-and-drop");
|
|
38
37
|
var import_ds_grid = require("@elliemae/ds-grid");
|
|
39
38
|
var import_ds_hooks_headless_tooltip = require("@elliemae/ds-hooks-headless-tooltip");
|
|
40
39
|
var import_ds_system = require("@elliemae/ds-system");
|
|
@@ -43,15 +42,14 @@ var import_useStore = require("../../config/useStore/index.js");
|
|
|
43
42
|
var import_constants = require("../../constants/index.js");
|
|
44
43
|
var import_DndHandle = require("../Dnd/DndHandle.js");
|
|
45
44
|
var import_DropIndicator = require("../Dnd/DropIndicator.js");
|
|
46
|
-
var import_withConditionalUseSortable = require("../HoC/withConditionalUseSortable.js");
|
|
47
45
|
var import_ItemActions = require("./ItemActions/index.js");
|
|
48
|
-
var
|
|
46
|
+
var import_useInnerRefActionHandlers = require("./ItemActions/useInnerRefActionHandlers.js");
|
|
49
47
|
var import_ItemMiddleSection = require("./ItemMiddleSection.js");
|
|
50
|
-
var
|
|
48
|
+
var import_ItemSelectionUI = require("./ItemSelectionUi/ItemSelectionUI.js");
|
|
51
49
|
var import_useItemArrowNavigation = require("./useItemArrowNavigation.js");
|
|
50
|
+
var import_useItemInnerRefHandlers = require("./useItemInnerRefHandlers.js");
|
|
52
51
|
var import_useItemKeyboardSelection = require("./useItemKeyboardSelection.js");
|
|
53
52
|
var import_useSelectionLogic = require("./useSelectionLogic.js");
|
|
54
|
-
var import_useThisItemIsFocused = require("./useThisItemIsFocused.js");
|
|
55
53
|
const cssDisabled = import_ds_system.css`
|
|
56
54
|
background-color: ${({ theme }) => theme.colors.neutral["100"]};
|
|
57
55
|
color: ${({ theme }) => theme.colors.neutral["300"]};
|
|
@@ -85,53 +83,17 @@ const ItemWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: im
|
|
|
85
83
|
|
|
86
84
|
${({ isDragging }) => isDragging && cssDisabled}
|
|
87
85
|
`;
|
|
88
|
-
const ItemSelectionWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_constants.DSShuttleV2Name, slot: import_constants.DSShuttleV2Slots.ITEM_CHECKBOX })`
|
|
89
|
-
height: 100%;
|
|
90
|
-
&:focus {
|
|
91
|
-
outline: none;
|
|
92
|
-
}
|
|
93
|
-
`;
|
|
94
|
-
const useInnerRefHandlers = (itemMeta) => {
|
|
95
|
-
const { datumInternalMeta, isDestinationPanel } = itemMeta;
|
|
96
|
-
const { hydratedId } = datumInternalMeta;
|
|
97
|
-
const setZustandRef = (0, import_useStore.useInternalStore)((state) => state.setZustandRef);
|
|
98
|
-
const setDeferFocusUntilFirstRender = (0, import_useStore.useInternalStore)((state) => state.setDeferFocusUntilFirstRender);
|
|
99
|
-
const deferedAfterFirstRender = (0, import_useStore.useInternalStore)((state) => state.getDeferFocusUntilFirstRender());
|
|
100
|
-
const isLoadingMore = (0, import_useStore.usePropsStore)(
|
|
101
|
-
(state) => isDestinationPanel ? state.destinationIsLoadingMore : state.sourceIsLoadingMore
|
|
102
|
-
);
|
|
103
|
-
const thisItemIsFocused = (0, import_useThisItemIsFocused.useThisItemIsFocused)(itemMeta);
|
|
104
|
-
const currRegion = isDestinationPanel ? import_constants.REGIONS_FOCUSES.DESTINATION_PANEL_ITEM : import_constants.REGIONS_FOCUSES.SOURCE_PANEL_ITEM;
|
|
105
|
-
const currItemId = hydratedId;
|
|
106
|
-
const innerRefHandlerParentItem = import_react.default.useCallback(
|
|
107
|
-
(node) => {
|
|
108
|
-
setZustandRef([currRegion, currItemId, "parent"], node);
|
|
109
|
-
if (deferedAfterFirstRender && thisItemIsFocused && node) {
|
|
110
|
-
setDeferFocusUntilFirstRender(false);
|
|
111
|
-
if (node.tabIndex === -1) node.tabIndex = 0;
|
|
112
|
-
node.focus();
|
|
113
|
-
}
|
|
114
|
-
},
|
|
115
|
-
[setZustandRef, currRegion, currItemId, thisItemIsFocused, deferedAfterFirstRender, setDeferFocusUntilFirstRender]
|
|
116
|
-
);
|
|
117
|
-
(0, import_react.useEffect)(
|
|
118
|
-
() => () => {
|
|
119
|
-
if (isLoadingMore) setDeferFocusUntilFirstRender(true);
|
|
120
|
-
},
|
|
121
|
-
[isLoadingMore, setDeferFocusUntilFirstRender]
|
|
122
|
-
);
|
|
123
|
-
return import_react.default.useMemo(
|
|
124
|
-
() => ({ innerRefHandlerParentItem, thisItemIsFocused }),
|
|
125
|
-
[innerRefHandlerParentItem, thisItemIsFocused]
|
|
126
|
-
);
|
|
127
|
-
};
|
|
128
86
|
const Item = import_react.default.memo((itemMeta) => {
|
|
129
87
|
const { datumInternalMeta, withDragNDrop, useSortableHelpers, hasMultipleSelection } = itemMeta;
|
|
130
|
-
const {
|
|
88
|
+
const { hydratedId, softDeleted } = datumInternalMeta;
|
|
89
|
+
const explicitSelectionUI = (0, import_useStore.usePropsStore)((store) => store.explicitSelectionUI);
|
|
131
90
|
const cols = (0, import_react.useMemo)(() => {
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
91
|
+
const selectionUIWidth = explicitSelectionUI ? "auto" : "5px";
|
|
92
|
+
const finalCols = [selectionUIWidth];
|
|
93
|
+
if (withDragNDrop) finalCols.push("auto");
|
|
94
|
+
finalCols.push("1fr", "auto");
|
|
95
|
+
return finalCols;
|
|
96
|
+
}, [withDragNDrop, explicitSelectionUI]);
|
|
135
97
|
const setDndDraggingItemMeta = (0, import_useStore.useInternalStore)((state) => state.setDndDraggingItemMeta);
|
|
136
98
|
const getIsDragAndDropHappening = (0, import_useStore.useInternalStore)((state) => state.getIsDragAndDropHappening);
|
|
137
99
|
const isDraggingThisItem = (0, import_useStore.useInternalStore)((state) => state.dndDraggingItem?.hydratedId === hydratedId);
|
|
@@ -153,8 +115,9 @@ const Item = import_react.default.memo((itemMeta) => {
|
|
|
153
115
|
},
|
|
154
116
|
[onItemKeyDownSelection, onItemContainerKeyDown]
|
|
155
117
|
);
|
|
156
|
-
const
|
|
157
|
-
const {
|
|
118
|
+
const itemInnerRefHandlers = (0, import_useItemInnerRefHandlers.useItemInnerRefHandlers)(itemMeta);
|
|
119
|
+
const { thisItemIsFocused } = itemInnerRefHandlers;
|
|
120
|
+
const { innerRefHandlerDnd } = (0, import_useInnerRefActionHandlers.useInnerRefActionHandlers)(itemMeta);
|
|
158
121
|
const overId = (0, import_useStore.useInternalStore)((state) => state.overId);
|
|
159
122
|
const isDropValid = (0, import_useStore.useInternalStore)((state) => state.isDropValid);
|
|
160
123
|
const dropIndicatorPosition = (0, import_useStore.useInternalStore)((state) => state.dropIndicatorPosition);
|
|
@@ -163,7 +126,6 @@ const Item = import_react.default.memo((itemMeta) => {
|
|
|
163
126
|
});
|
|
164
127
|
const config = import_react.default.useMemo(() => ({ hasFocus: thisItemIsFocused }), [thisItemIsFocused]);
|
|
165
128
|
const tooltipHelpers = (0, import_ds_hooks_headless_tooltip.useHeadlessTooltip)(config);
|
|
166
|
-
const idItem = (0, import_react.useMemo)(() => `${hydratedId}-wrapper${softDeleted ? "-soft-deleted" : ""}`, [hydratedId, softDeleted]);
|
|
167
129
|
const getOwnerProps = (0, import_useStore.usePropsStore)((store) => store.get);
|
|
168
130
|
const getOwnerPropsArguments = import_react.default.useCallback(() => itemMeta, [itemMeta]);
|
|
169
131
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
@@ -187,19 +149,11 @@ const Item = import_react.default.memo((itemMeta) => {
|
|
|
187
149
|
getOwnerPropsArguments,
|
|
188
150
|
children: [
|
|
189
151
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
190
|
-
|
|
152
|
+
import_ItemSelectionUI.ItemSelectionUI,
|
|
191
153
|
{
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
onBlur: tooltipHelpers.onBlur,
|
|
196
|
-
"aria-labelledby": `${hydratedId}-text-section${softDeleted ? "-soft-deleted" : ""}`,
|
|
197
|
-
id: idItem,
|
|
198
|
-
innerRef: innerRefHandlerParentItem,
|
|
199
|
-
"aria-disabled": softDeleted,
|
|
200
|
-
getOwnerProps,
|
|
201
|
-
getOwnerPropsArguments,
|
|
202
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ItemSelection.ItemSelection, { ...itemMeta })
|
|
154
|
+
tooltipHelpers,
|
|
155
|
+
itemInnerRefHandlers,
|
|
156
|
+
itemMeta
|
|
203
157
|
}
|
|
204
158
|
),
|
|
205
159
|
withDragNDrop && useSortableHelpers ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
@@ -221,6 +175,13 @@ const Item = import_react.default.memo((itemMeta) => {
|
|
|
221
175
|
}
|
|
222
176
|
);
|
|
223
177
|
});
|
|
224
|
-
const
|
|
225
|
-
|
|
178
|
+
const ItemWithSortable = (props) => {
|
|
179
|
+
const {
|
|
180
|
+
datumInternalMeta: { hydratedId }
|
|
181
|
+
} = props;
|
|
182
|
+
const useSortableConfig = (0, import_react.useMemo)(() => ({ id: hydratedId }), [hydratedId]);
|
|
183
|
+
const useSortableHelpers = (0, import_ds_drag_and_drop.useSortable)(useSortableConfig);
|
|
184
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Item, { ...props, useSortableHelpers });
|
|
185
|
+
};
|
|
186
|
+
const ItemSortable = (props) => props.withDragNDrop ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ItemWithSortable, { ...props }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Item, { ...props });
|
|
226
187
|
//# sourceMappingURL=Item.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/parts/Item/Item.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["/* eslint-disable max-lines */\n/* eslint-disable max-statements */\nimport { Grid } from '@elliemae/ds-grid';\nimport { useHeadlessTooltip } from '@elliemae/ds-hooks-headless-tooltip';\nimport { css, styled } from '@elliemae/ds-system';\nimport React, {
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;
|
|
6
|
-
"names": ["React"
|
|
4
|
+
"sourcesContent": ["/* eslint-disable max-lines */\n/* eslint-disable max-statements */\nimport { useSortable } from '@elliemae/ds-drag-and-drop';\nimport { Grid } from '@elliemae/ds-grid';\nimport { useHeadlessTooltip } from '@elliemae/ds-hooks-headless-tooltip';\nimport { css, styled } from '@elliemae/ds-system';\nimport React, { useMemo } from 'react';\nimport { useInternalStore, usePropsStore } from '../../config/useStore/index.js';\nimport { DSShuttleV2Name, DSShuttleV2Slots } from '../../constants/index.js';\nimport { type DSShuttleV2T } from '../../react-desc-prop-types.js';\nimport { DragHandle } from '../Dnd/DndHandle.js';\nimport { DropIndicator } from '../Dnd/DropIndicator.js';\nimport { ItemActions } from './ItemActions/index.js';\nimport { useInnerRefActionHandlers } from './ItemActions/useInnerRefActionHandlers.js';\nimport { ItemMiddleSection } from './ItemMiddleSection.js';\nimport { ItemSelectionUI } from './ItemSelectionUi/ItemSelectionUI.js';\nimport { useItemArrowNavigation } from './useItemArrowNavigation.js';\nimport { useItemInnerRefHandlers } from './useItemInnerRefHandlers.js';\nimport { useItemKeyboardSelection } from './useItemKeyboardSelection.js';\nimport { useSelectionLogic } from './useSelectionLogic.js';\n\n// we are using the class-name added via slot for the children `:hover` styling of icon colors\nconst cssDisabled = css`\n background-color: ${({ theme }) => theme.colors.neutral['100']};\n color: ${({ theme }) => theme.colors.neutral['300']};\n .DSShuttleV2-item-action-btn-to-source-icon > svg,\n .DSShuttleV2-item-action-btn-to-destination-icon > svg,\n .DSShuttleV2-item-action-btn-drilldown-icon > svg {\n fill: ${({ theme }) => theme.colors.neutral['300']};\n }\n`;\n\nconst focusRing = css`\n outline: 2px solid ${({ theme }) => theme.colors.brand['700']};\n outline-offset: -2px;\n`;\ninterface ItemWrapperT {\n isDragging: boolean;\n isDndActive: boolean;\n hasFocusRing: boolean;\n}\n\nconst ItemWrapper = styled(Grid, { name: DSShuttleV2Name, slot: DSShuttleV2Slots.ITEM_WRAPPER })<ItemWrapperT>`\n min-height: 2.769rem;\n position: relative;\n background-color: white;\n &:hover {\n background-color: ${({ isDndActive, theme }) => (!isDndActive ? theme.colors.brand['200'] : 'white')};\n .DSShuttleV2-item-action-btn-to-source-icon > svg,\n .DSShuttleV2-item-action-btn-to-destination-icon > svg,\n .DSShuttleV2-item-action-btn-drilldown-icon > svg {\n fill: brand-700;\n }\n ${({ isDragging }) => isDragging && cssDisabled}\n }\n\n ${({ hasFocusRing }) => hasFocusRing && focusRing}\n\n border-bottom: 1px solid neutral-100;\n\n ${({ isDragging }) => isDragging && cssDisabled}\n`;\nconst Item = React.memo((itemMeta: DSShuttleV2T.ItemMeta) => {\n const { datumInternalMeta, withDragNDrop, useSortableHelpers, hasMultipleSelection } = itemMeta;\n const { hydratedId, softDeleted } = datumInternalMeta;\n\n const explicitSelectionUI = usePropsStore((store) => store.explicitSelectionUI);\n const cols = useMemo(() => {\n const selectionUIWidth = explicitSelectionUI ? 'auto' : '5px';\n const finalCols = [selectionUIWidth];\n if (withDragNDrop) finalCols.push('auto');\n finalCols.push('1fr', 'auto');\n return finalCols;\n }, [withDragNDrop, explicitSelectionUI]);\n\n const setDndDraggingItemMeta = useInternalStore((state) => state.setDndDraggingItemMeta);\n const getIsDragAndDropHappening = useInternalStore((state) => state.getIsDragAndDropHappening);\n const isDraggingThisItem = useInternalStore((state) => state.dndDraggingItem?.hydratedId === hydratedId);\n\n React.useEffect(() => {\n if (isDraggingThisItem) {\n setDndDraggingItemMeta((prevItemMeta) => {\n if (prevItemMeta?.datumInternalMeta.hydratedId === hydratedId) return prevItemMeta;\n return itemMeta;\n });\n }\n }, [hydratedId, isDraggingThisItem, itemMeta, setDndDraggingItemMeta]);\n\n const { selectItem, onShiftMouseDownPreventTextSelection } = useSelectionLogic(itemMeta);\n const { onItemContainerKeyDown } = useItemArrowNavigation(itemMeta);\n const { onItemKeyDownSelection } = useItemKeyboardSelection(itemMeta);\n\n const handleItemKeyDown: React.KeyboardEventHandler<HTMLDivElement> = React.useCallback(\n (event) => {\n onItemKeyDownSelection(event);\n onItemContainerKeyDown(event);\n },\n [onItemKeyDownSelection, onItemContainerKeyDown],\n );\n const itemInnerRefHandlers = useItemInnerRefHandlers(itemMeta);\n const { thisItemIsFocused } = itemInnerRefHandlers;\n const { innerRefHandlerDnd } = useInnerRefActionHandlers(itemMeta);\n const overId = useInternalStore((state) => state.overId);\n const isDropValid = useInternalStore((state) => state.isDropValid);\n const dropIndicatorPosition = useInternalStore((state) => state.dropIndicatorPosition);\n\n const showDropIndicatorPosition = hydratedId === overId && dropIndicatorPosition;\n const sortableRef = useSortableHelpers?.setNodeRef ?? (() => {});\n\n // const thisItemIsFocused = useThisItemIsFocused(itemMeta);\n const config = React.useMemo(() => ({ hasFocus: thisItemIsFocused }), [thisItemIsFocused]);\n\n const tooltipHelpers = useHeadlessTooltip(config);\n\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = React.useCallback(() => itemMeta, [itemMeta]);\n\n return (\n <ItemWrapper\n isDragging={isDraggingThisItem}\n isDndActive={getIsDragAndDropHappening()}\n cols={cols}\n alignItems=\"center\"\n onClick={selectItem}\n innerRef={sortableRef}\n onKeyDown={handleItemKeyDown}\n onMouseDown={onShiftMouseDownPreventTextSelection}\n onMouseEnter={tooltipHelpers.onMouseEnter}\n onMouseLeave={tooltipHelpers.onMouseLeave}\n onPointerEnter={tooltipHelpers.onMouseEnter}\n onPointerLeave={tooltipHelpers.onMouseLeave}\n hasFocusRing={thisItemIsFocused}\n tabIndex={-1}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <ItemSelectionUI\n tooltipHelpers={tooltipHelpers}\n itemInnerRefHandlers={itemInnerRefHandlers}\n itemMeta={itemMeta}\n />\n {withDragNDrop && useSortableHelpers ? (\n <DragHandle\n id={hydratedId}\n useSortableHelpers={useSortableHelpers}\n isDndActive={getIsDragAndDropHappening()}\n isDragging={isDraggingThisItem}\n innerRef={innerRefHandlerDnd}\n disabled={hasMultipleSelection}\n ariaLabelledby={`${hydratedId}-text-section${softDeleted ? '-soft-deleted' : ''}`}\n />\n ) : null}\n <ItemMiddleSection {...itemMeta} tooltipHelpers={tooltipHelpers} />\n {!hasMultipleSelection ? <ItemActions {...itemMeta} /> : null}\n <DropIndicator vertical={false} dropIndicatorPosition={showDropIndicatorPosition} isDropValid={isDropValid} />\n </ItemWrapper>\n );\n});\n\nconst ItemWithSortable = (props: DSShuttleV2T.ItemMeta) => {\n const {\n datumInternalMeta: { hydratedId },\n } = props;\n const useSortableConfig = useMemo(() => ({ id: hydratedId }), [hydratedId]);\n const useSortableHelpers = useSortable(useSortableConfig);\n return <Item {...props} useSortableHelpers={useSortableHelpers} />;\n};\n\nexport const ItemSortable = (props: DSShuttleV2T.ItemMeta) =>\n props.withDragNDrop ? <ItemWithSortable {...props} /> : <Item {...props} />;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
|
+
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -39,10 +39,12 @@ var import_ds_grid = require("@elliemae/ds-grid");
|
|
|
39
39
|
var import_ds_button_v2 = require("@elliemae/ds-button-v2");
|
|
40
40
|
var import_ds_icons = require("@elliemae/ds-icons");
|
|
41
41
|
var import_useActionsHandlers = require("./useActionsHandlers.js");
|
|
42
|
-
var
|
|
42
|
+
var import_useInnerRefActionHandlers = require("./useInnerRefActionHandlers.js");
|
|
43
43
|
var import_constants = require("../../../constants/index.js");
|
|
44
44
|
var import_useStore = require("../../../config/useStore/useStore.js");
|
|
45
|
-
const StyledItemActions = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_constants.DSShuttleV2Name, slot: import_constants.DSShuttleV2Slots.ITEM_ACTIONS_WRAPPER })
|
|
45
|
+
const StyledItemActions = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_constants.DSShuttleV2Name, slot: import_constants.DSShuttleV2Slots.ITEM_ACTIONS_WRAPPER })`
|
|
46
|
+
height: 100%;
|
|
47
|
+
`;
|
|
46
48
|
const StyledItemActionWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_constants.DSShuttleV2Name, slot: import_constants.DSShuttleV2Slots.ITEM_ACTION_WRAPPER })``;
|
|
47
49
|
const StyledButton = (0, import_ds_system.styled)(import_ds_button_v2.DSButtonV3, { name: import_constants.DSShuttleV2Name, slot: import_constants.DSShuttleV2Slots.ITEM_ACTION_BTN })`
|
|
48
50
|
height: 1.692rem !important;
|
|
@@ -75,7 +77,7 @@ const ItemActions = import_react.default.memo((itemMeta) => {
|
|
|
75
77
|
} = itemMeta;
|
|
76
78
|
const { withActions, internallyDisabledDrilldown, internallyDisabledMove } = datumRenderFlags;
|
|
77
79
|
const { preventDrilldown, label } = datumHydratables;
|
|
78
|
-
const { innerRefHandlerDrilldown, innerRefHandlerMove } = (0,
|
|
80
|
+
const { innerRefHandlerDrilldown, innerRefHandlerMove } = (0, import_useInnerRefActionHandlers.useInnerRefActionHandlers)(itemMeta);
|
|
79
81
|
const { handleClickDrilldown, handleClickSingleMove, handleKeyDownSelectionBubbleUp } = (0, import_useActionsHandlers.useActionsHandlers)(itemMeta);
|
|
80
82
|
const drillDownAriaLabel = (0, import_react.useMemo)(() => `Drilldown into ${label} option`, [label]);
|
|
81
83
|
const moveAriaLabel = (0, import_react.useMemo)(
|
|
@@ -86,6 +88,16 @@ const ItemActions = import_react.default.memo((itemMeta) => {
|
|
|
86
88
|
const moveButtonProps = (0, import_useStore.usePropsStore)((state) => state.moveButtonProps);
|
|
87
89
|
const getOwnerProps = (0, import_useStore.usePropsStore)((store) => store.get);
|
|
88
90
|
const getOwnerPropsArguments = import_react.default.useCallback(() => itemMeta, [itemMeta]);
|
|
91
|
+
const getOwnerPropsArgumentsIcons = import_react.default.useCallback(
|
|
92
|
+
() => ({
|
|
93
|
+
panelMetaInfo: itemMeta,
|
|
94
|
+
extraMetaInfo: { itemMeta }
|
|
95
|
+
}),
|
|
96
|
+
[itemMeta]
|
|
97
|
+
);
|
|
98
|
+
const stopPropagation = import_react.default.useCallback((event) => {
|
|
99
|
+
event.stopPropagation();
|
|
100
|
+
}, []);
|
|
89
101
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
90
102
|
StyledItemActions,
|
|
91
103
|
{
|
|
@@ -94,6 +106,8 @@ const ItemActions = import_react.default.memo((itemMeta) => {
|
|
|
94
106
|
pl: "xs",
|
|
95
107
|
pr: "xxs",
|
|
96
108
|
alignItems: "center",
|
|
109
|
+
onClick: stopPropagation,
|
|
110
|
+
onMouseDown: stopPropagation,
|
|
97
111
|
getOwnerProps,
|
|
98
112
|
getOwnerPropsArguments,
|
|
99
113
|
children: withActions ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
@@ -137,7 +151,7 @@ const ItemActions = import_react.default.memo((itemMeta) => {
|
|
|
137
151
|
width: "1.538rem",
|
|
138
152
|
height: "1.538rem",
|
|
139
153
|
getOwnerProps,
|
|
140
|
-
getOwnerPropsArguments
|
|
154
|
+
getOwnerPropsArguments: getOwnerPropsArgumentsIcons
|
|
141
155
|
}
|
|
142
156
|
) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
143
157
|
StyledArrowShortRightIcon,
|
|
@@ -145,7 +159,7 @@ const ItemActions = import_react.default.memo((itemMeta) => {
|
|
|
145
159
|
width: "1.538rem",
|
|
146
160
|
height: "1.538rem",
|
|
147
161
|
getOwnerProps,
|
|
148
|
-
getOwnerPropsArguments
|
|
162
|
+
getOwnerPropsArguments: getOwnerPropsArgumentsIcons
|
|
149
163
|
}
|
|
150
164
|
)
|
|
151
165
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../src/parts/Item/ItemActions/ItemActions.tsx", "../../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React, { useMemo } from 'react';\nimport { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSButtonV3, BUTTON_SIZES } from '@elliemae/ds-button-v2';\nimport { ArrowShortReturn, ArrowShortRight, CloseMedium } from '@elliemae/ds-icons';\nimport { type DSShuttleV2T } from '../../../react-desc-prop-types.js';\nimport { useActionsHandlers } from './useActionsHandlers.js';\nimport {
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import React, { useMemo } from 'react';\nimport { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSButtonV3, BUTTON_SIZES } from '@elliemae/ds-button-v2';\nimport { ArrowShortReturn, ArrowShortRight, CloseMedium } from '@elliemae/ds-icons';\nimport { type DSShuttleV2T } from '../../../react-desc-prop-types.js';\nimport { useActionsHandlers } from './useActionsHandlers.js';\nimport { useInnerRefActionHandlers } from './useInnerRefActionHandlers.js';\nimport { DSShuttleV2Name, DSShuttleV2Slots } from '../../../constants/index.js';\nimport { useInternalStore, usePropsStore } from '../../../config/useStore/useStore.js';\n\nconst StyledItemActions = styled(Grid, { name: DSShuttleV2Name, slot: DSShuttleV2Slots.ITEM_ACTIONS_WRAPPER })`\n height: 100%;\n`;\nconst StyledItemActionWrapper = styled(Grid, { name: DSShuttleV2Name, slot: DSShuttleV2Slots.ITEM_ACTION_WRAPPER })``;\nconst StyledButton = styled(DSButtonV3, { name: DSShuttleV2Name, slot: DSShuttleV2Slots.ITEM_ACTION_BTN })`\n height: 1.692rem !important;\n svg {\n fill: brand-600;\n }\n :disabled svg {\n fill: neutral-200 !important;\n }\n`;\nconst StyledDrilldownIcon = styled(ArrowShortReturn, {\n name: DSShuttleV2Name,\n slot: DSShuttleV2Slots.ITEM_ACTION_BTN_DRILLDOWN_ICON,\n})``;\nconst StyledCloseMediumIcon = styled(CloseMedium, {\n name: DSShuttleV2Name,\n slot: DSShuttleV2Slots.ITEM_ACTION_BTN_TO_SOURCE_ICON,\n})``;\nconst StyledArrowShortRightIcon = styled(ArrowShortRight, {\n name: DSShuttleV2Name,\n slot: DSShuttleV2Slots.ITEM_ACTION_BTN_TO_DESTINATION_ICON,\n})``;\n\nconst actionsCols = ['1.538rem', '1.538rem'];\n\nexport const ItemActions = React.memo((itemMeta: DSShuttleV2T.ItemMeta) => {\n const {\n datumHydratables,\n isDestinationPanel,\n datumRenderFlags,\n datumInternalMeta: { hydratedPreventMove, hydratedId },\n } = itemMeta;\n // withActions is calculated in /src/config/configureAutoCalculated.ts\n const { withActions, internallyDisabledDrilldown, internallyDisabledMove } = datumRenderFlags;\n const { preventDrilldown, label } = datumHydratables;\n const { innerRefHandlerDrilldown, innerRefHandlerMove } = useInnerRefActionHandlers(itemMeta);\n const { handleClickDrilldown, handleClickSingleMove, handleKeyDownSelectionBubbleUp } = useActionsHandlers(itemMeta);\n const drillDownAriaLabel = useMemo(() => `Drilldown into ${label} option`, [label]);\n const moveAriaLabel = useMemo(\n () => `Move option ${label} into ${isDestinationPanel ? 'source' : 'destination'} panel`,\n [label, isDestinationPanel],\n );\n\n const isDraggingThisItem = useInternalStore((state) => state.dndDraggingItem?.hydratedId === hydratedId);\n\n const moveButtonProps = usePropsStore((state) => state.moveButtonProps);\n\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = React.useCallback(() => itemMeta, [itemMeta]);\n // The to-source / to-destination icon slots share a unified argument shape with the bulk-action\n // button (see MultipleSelectionAction). Here the per-item itemMeta is available via extraMetaInfo.\n const getOwnerPropsArgumentsIcons = React.useCallback(\n (): DSShuttleV2T.ItemActionIconArguments => ({\n panelMetaInfo: itemMeta,\n extraMetaInfo: { itemMeta },\n }),\n [itemMeta],\n );\n\n // Clicking an action button (drilldown / move) must not bubble up to the row's onClick\n // (selectItem) / onMouseDown handlers \u2014 using an action should not toggle item selection.\n const stopPropagation = React.useCallback((event: React.SyntheticEvent) => {\n event.stopPropagation();\n }, []);\n\n return (\n <StyledItemActions\n cols={actionsCols}\n gutter=\"xxs\"\n pl=\"xs\"\n pr=\"xxs\"\n alignItems=\"center\"\n onClick={stopPropagation}\n onMouseDown={stopPropagation}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {withActions ? (\n <>\n <StyledItemActionWrapper getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n <StyledButton\n buttonType=\"icon\"\n aria-label={drillDownAriaLabel}\n onClick={handleClickDrilldown}\n onKeyDown={handleKeyDownSelectionBubbleUp}\n size={BUTTON_SIZES.S}\n innerRef={innerRefHandlerDrilldown}\n tabIndex={-1} // We overwrite it via vanilla js on the focus manager\n disabled={internallyDisabledDrilldown || preventDrilldown === true || isDraggingThisItem}\n >\n <StyledDrilldownIcon\n width=\"1.538rem\"\n height=\"1.538rem\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n </StyledButton>\n </StyledItemActionWrapper>\n <StyledItemActionWrapper getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n <StyledButton\n buttonType=\"icon\"\n aria-label={moveAriaLabel}\n onClick={handleClickSingleMove}\n onKeyDown={handleKeyDownSelectionBubbleUp}\n size={BUTTON_SIZES.S}\n innerRef={innerRefHandlerMove}\n tabIndex={-1} // We overwrite it via vanilla js on the focus manager\n disabled={internallyDisabledMove || hydratedPreventMove === true || isDraggingThisItem}\n {...(moveButtonProps && moveButtonProps({ itemMeta, isDestinationPanel }))}\n >\n {isDestinationPanel ? (\n <StyledCloseMediumIcon\n width=\"1.538rem\"\n height=\"1.538rem\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArgumentsIcons}\n />\n ) : (\n <StyledArrowShortRightIcon\n width=\"1.538rem\"\n height=\"1.538rem\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArgumentsIcons}\n />\n )}\n </StyledButton>\n </StyledItemActionWrapper>\n </>\n ) : (\n // this is a place-holder used for mantainting the grid spacing when item has no actions (so when item is soft-deleted)\n <>\n <div />\n <div />\n </>\n )}\n </StyledItemActions>\n );\n});\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
package/dist/cjs/parts/Item/ItemActions/{useInnerRefHandlers.js → useInnerRefActionHandlers.js}
RENAMED
|
@@ -26,16 +26,16 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var
|
|
30
|
-
__export(
|
|
31
|
-
|
|
29
|
+
var useInnerRefActionHandlers_exports = {};
|
|
30
|
+
__export(useInnerRefActionHandlers_exports, {
|
|
31
|
+
useInnerRefActionHandlers: () => useInnerRefActionHandlers
|
|
32
32
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
33
|
+
module.exports = __toCommonJS(useInnerRefActionHandlers_exports);
|
|
34
34
|
var React = __toESM(require("react"));
|
|
35
35
|
var import_react = __toESM(require("react"));
|
|
36
36
|
var import_useStore = require("../../../config/useStore/index.js");
|
|
37
37
|
var import_constants = require("../../../constants/index.js");
|
|
38
|
-
const
|
|
38
|
+
const useInnerRefActionHandlers = ({ datumInternalMeta, isDestinationPanel }) => {
|
|
39
39
|
const setZustandRef = (0, import_useStore.useInternalStore)((state) => state.setZustandRef);
|
|
40
40
|
const currRegion = isDestinationPanel ? import_constants.REGIONS_FOCUSES.DESTINATION_PANEL_ITEM : import_constants.REGIONS_FOCUSES.SOURCE_PANEL_ITEM;
|
|
41
41
|
const currItemId = datumInternalMeta.hydratedId;
|
|
@@ -66,4 +66,4 @@ const useInnerRefHandlers = ({ datumInternalMeta, isDestinationPanel }) => {
|
|
|
66
66
|
[innerRefHandlerDrilldown, innerRefHandlerDnd, innerRefHandlerMove]
|
|
67
67
|
);
|
|
68
68
|
};
|
|
69
|
-
//# sourceMappingURL=
|
|
69
|
+
//# sourceMappingURL=useInnerRefActionHandlers.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../src/parts/Item/ItemActions/useInnerRefActionHandlers.tsx", "../../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { type DSShuttleV2T } from '../../../react-desc-prop-types.js';\nimport { useInternalStore } from '../../../config/useStore/index.js';\nimport { REGIONS_FOCUSES, ACTIONS_FOCUSES } from '../../../constants/index.js';\n\nexport const useInnerRefActionHandlers = ({ datumInternalMeta, isDestinationPanel }: DSShuttleV2T.ItemMeta) => {\n const setZustandRef = useInternalStore((state) => state.setZustandRef);\n const currRegion = isDestinationPanel ? REGIONS_FOCUSES.DESTINATION_PANEL_ITEM : REGIONS_FOCUSES.SOURCE_PANEL_ITEM;\n const currItemId = datumInternalMeta.hydratedId;\n const innerRefHandlerDrilldown = React.useCallback(\n (node: HTMLButtonElement) => {\n setZustandRef([currRegion, currItemId, ACTIONS_FOCUSES.DRILLDOWN_BTN], node);\n },\n [currItemId, currRegion, setZustandRef],\n );\n const innerRefHandlerMove = React.useCallback(\n (node: HTMLButtonElement) => {\n setZustandRef([currRegion, currItemId, ACTIONS_FOCUSES.MOVE_BTN], node);\n },\n [currItemId, currRegion, setZustandRef],\n );\n const innerRefHandlerDnd = React.useCallback(\n (node: HTMLDivElement | null) => {\n setZustandRef([currRegion, currItemId, ACTIONS_FOCUSES.DRAG_N_DROP], node);\n },\n [currItemId, currRegion, setZustandRef],\n );\n return React.useMemo(\n () => ({\n innerRefHandlerDnd,\n innerRefHandlerDrilldown,\n innerRefHandlerMove,\n }),\n [innerRefHandlerDrilldown, innerRefHandlerDnd, innerRefHandlerMove],\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;AAElB,sBAAiC;AACjC,uBAAiD;AAE1C,MAAM,4BAA4B,CAAC,EAAE,mBAAmB,mBAAmB,MAA6B;AAC7G,QAAM,oBAAgB,kCAAiB,CAAC,UAAU,MAAM,aAAa;AACrE,QAAM,aAAa,qBAAqB,iCAAgB,yBAAyB,iCAAgB;AACjG,QAAM,aAAa,kBAAkB;AACrC,QAAM,2BAA2B,aAAAA,QAAM;AAAA,IACrC,CAAC,SAA4B;AAC3B,oBAAc,CAAC,YAAY,YAAY,iCAAgB,aAAa,GAAG,IAAI;AAAA,IAC7E;AAAA,IACA,CAAC,YAAY,YAAY,aAAa;AAAA,EACxC;AACA,QAAM,sBAAsB,aAAAA,QAAM;AAAA,IAChC,CAAC,SAA4B;AAC3B,oBAAc,CAAC,YAAY,YAAY,iCAAgB,QAAQ,GAAG,IAAI;AAAA,IACxE;AAAA,IACA,CAAC,YAAY,YAAY,aAAa;AAAA,EACxC;AACA,QAAM,qBAAqB,aAAAA,QAAM;AAAA,IAC/B,CAAC,SAAgC;AAC/B,oBAAc,CAAC,YAAY,YAAY,iCAAgB,WAAW,GAAG,IAAI;AAAA,IAC3E;AAAA,IACA,CAAC,YAAY,YAAY,aAAa;AAAA,EACxC;AACA,SAAO,aAAAA,QAAM;AAAA,IACX,OAAO;AAAA,MACL;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,IACA,CAAC,0BAA0B,oBAAoB,mBAAmB;AAAA,EACpE;AACF;",
|
|
6
|
+
"names": ["React"]
|
|
7
|
+
}
|
|
@@ -47,6 +47,7 @@ const MidSection = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
|
47
47
|
name: import_constants.DSShuttleV2Name,
|
|
48
48
|
slot: import_constants.DSShuttleV2Slots.ITEM_MIDSECTION_WRAPPER
|
|
49
49
|
})`
|
|
50
|
+
height: 100%;
|
|
50
51
|
min-height: 1rem;
|
|
51
52
|
${(props) => {
|
|
52
53
|
if (props.$softDeleted)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/parts/Item/ItemMiddleSection.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { type DSShuttleV2T } from '../../react-desc-prop-types.js';\nimport { DSShuttleV2Name, DSShuttleV2Slots } from '../../constants/index.js';\nimport { TextSection } from './TextSection.js';\nimport { useThisItemIsFocused } from './useThisItemIsFocused.js';\nimport { usePropsStore } from '../../config/useStore/useStore.js';\n\nconst IconWrapper = styled(Grid, { name: DSShuttleV2Name, slot: DSShuttleV2Slots.ITEM_ICON_WRAPPER })`\n min-height: 1rem;\n`;\n\nconst MidSection = styled(Grid, {\n name: DSShuttleV2Name,\n slot: DSShuttleV2Slots.ITEM_MIDSECTION_WRAPPER,\n})<{ $softDeleted: boolean }>`\n min-height: 1rem;\n ${(props) => {\n if (props.$softDeleted)\n return `\n color: ${props.theme.colors.neutral[500]};\n svg {\n fill: ${props.theme.colors.neutral[400]};\n }\n `;\n return '';\n }};\n`;\nconst customMidSectionCols = ['1fr'];\nconst customMidSectionRows = ['1fr'];\n\nexport const ItemMiddleSection = React.memo(\n (props: DSShuttleV2T.ItemMeta & { tooltipHelpers?: DSShuttleV2T.ComponentProps['tooltipHelpers'] }) => {\n const { tooltipHelpers, ...itemMeta } = props;\n const { datum, datumHydratables, datumInternalMeta, isDestinationPanel, hasMultipleSelection } = itemMeta;\n const { Icon, CustomRenderer, ...componentlessHydratables } = datumHydratables;\n const { softDeleted, hydratedId } = datumInternalMeta;\n const thisItemIsFocused = useThisItemIsFocused(itemMeta);\n const customComponentProps = React.useMemo<DSShuttleV2T.ComponentProps>(\n () => ({\n datum,\n tooltipHelpers,\n thisItemIsFocused,\n panelMetaInfo: { isDestinationPanel, hasMultipleSelection },\n datumInternalMeta,\n datumHydratables: { ...componentlessHydratables, id: hydratedId },\n }),\n [\n componentlessHydratables,\n datum,\n datumInternalMeta,\n hasMultipleSelection,\n hydratedId,\n isDestinationPanel,\n thisItemIsFocused,\n tooltipHelpers,\n ],\n );\n const cols = React.useMemo(() => {\n // if CustomRenderer is defined, shortcircuit\n if (CustomRenderer) return [];\n const dynamicCols = [];\n if (Icon) dynamicCols.push('auto');\n dynamicCols.push('1fr');\n return dynamicCols;\n }, [CustomRenderer, Icon]);\n\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = React.useCallback(() => props, [props]);\n\n if (CustomRenderer)\n return (\n <MidSection\n cols={customMidSectionCols}\n rows={customMidSectionRows}\n $softDeleted={Boolean(softDeleted)}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <CustomRenderer {...customComponentProps} />\n </MidSection>\n );\n\n // if we ever need to do something for truncation and showing a tooltip in the future,\n // check out what has been done in exported-related/ShuttleItem.tsx\n // also, be aware that we have the headless logic alread inside tooltipHelpers\n // when this comment has been written, the logic was working with keyboard and mouse as per tooltip-v3\n // integrated with all the shuttle-v2 custom focus navigation\n return (\n <MidSection\n cols={cols}\n alignItems=\"center\"\n ml=\"xxs\"\n $softDeleted={Boolean(softDeleted)}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {Icon ? (\n <IconWrapper\n alignItems=\"center\"\n mr=\"xxs\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Icon {...customComponentProps} />\n </IconWrapper>\n ) : null}\n <TextSection {...itemMeta} />\n </MidSection>\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { type DSShuttleV2T } from '../../react-desc-prop-types.js';\nimport { DSShuttleV2Name, DSShuttleV2Slots } from '../../constants/index.js';\nimport { TextSection } from './TextSection.js';\nimport { useThisItemIsFocused } from './useThisItemIsFocused.js';\nimport { usePropsStore } from '../../config/useStore/useStore.js';\n\nconst IconWrapper = styled(Grid, { name: DSShuttleV2Name, slot: DSShuttleV2Slots.ITEM_ICON_WRAPPER })`\n min-height: 1rem;\n`;\n\nconst MidSection = styled(Grid, {\n name: DSShuttleV2Name,\n slot: DSShuttleV2Slots.ITEM_MIDSECTION_WRAPPER,\n})<{ $softDeleted: boolean }>`\n height: 100%;\n min-height: 1rem;\n ${(props) => {\n if (props.$softDeleted)\n return `\n color: ${props.theme.colors.neutral[500]};\n svg {\n fill: ${props.theme.colors.neutral[400]};\n }\n `;\n return '';\n }};\n`;\nconst customMidSectionCols = ['1fr'];\nconst customMidSectionRows = ['1fr'];\n\nexport const ItemMiddleSection = React.memo(\n (props: DSShuttleV2T.ItemMeta & { tooltipHelpers?: DSShuttleV2T.ComponentProps['tooltipHelpers'] }) => {\n const { tooltipHelpers, ...itemMeta } = props;\n const { datum, datumHydratables, datumInternalMeta, isDestinationPanel, hasMultipleSelection } = itemMeta;\n const { Icon, CustomRenderer, ...componentlessHydratables } = datumHydratables;\n const { softDeleted, hydratedId } = datumInternalMeta;\n const thisItemIsFocused = useThisItemIsFocused(itemMeta);\n const customComponentProps = React.useMemo<DSShuttleV2T.ComponentProps>(\n () => ({\n datum,\n tooltipHelpers,\n thisItemIsFocused,\n panelMetaInfo: { isDestinationPanel, hasMultipleSelection },\n datumInternalMeta,\n datumHydratables: { ...componentlessHydratables, id: hydratedId },\n }),\n [\n componentlessHydratables,\n datum,\n datumInternalMeta,\n hasMultipleSelection,\n hydratedId,\n isDestinationPanel,\n thisItemIsFocused,\n tooltipHelpers,\n ],\n );\n const cols = React.useMemo(() => {\n // if CustomRenderer is defined, shortcircuit\n if (CustomRenderer) return [];\n const dynamicCols = [];\n if (Icon) dynamicCols.push('auto');\n dynamicCols.push('1fr');\n return dynamicCols;\n }, [CustomRenderer, Icon]);\n\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = React.useCallback(() => props, [props]);\n\n if (CustomRenderer)\n return (\n <MidSection\n cols={customMidSectionCols}\n rows={customMidSectionRows}\n $softDeleted={Boolean(softDeleted)}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <CustomRenderer {...customComponentProps} />\n </MidSection>\n );\n\n // if we ever need to do something for truncation and showing a tooltip in the future,\n // check out what has been done in exported-related/ShuttleItem.tsx\n // also, be aware that we have the headless logic alread inside tooltipHelpers\n // when this comment has been written, the logic was working with keyboard and mouse as per tooltip-v3\n // integrated with all the shuttle-v2 custom focus navigation\n return (\n <MidSection\n cols={cols}\n alignItems=\"center\"\n ml=\"xxs\"\n $softDeleted={Boolean(softDeleted)}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {Icon ? (\n <IconWrapper\n alignItems=\"center\"\n mr=\"xxs\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Icon {...customComponentProps} />\n </IconWrapper>\n ) : null}\n <TextSection {...itemMeta} />\n </MidSection>\n );\n },\n);\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADiFb;AAjFV,mBAAkB;AAClB,uBAAuB;AACvB,qBAAqB;AAErB,uBAAkD;AAClD,yBAA4B;AAC5B,kCAAqC;AACrC,sBAA8B;AAE9B,MAAM,kBAAc,yBAAO,qBAAM,EAAE,MAAM,kCAAiB,MAAM,kCAAiB,kBAAkB,CAAC;AAAA;AAAA;AAIpG,MAAM,iBAAa,yBAAO,qBAAM;AAAA,EAC9B,MAAM;AAAA,EACN,MAAM,kCAAiB;AACzB,CAAC;AAAA;AAAA;AAAA,IAGG,CAAC,UAAU;AACX,MAAI,MAAM;AACR,WAAO;AAAA,eACE,MAAM,MAAM,OAAO,QAAQ,GAAG,CAAC;AAAA;AAAA,gBAE9B,MAAM,MAAM,OAAO,QAAQ,GAAG,CAAC;AAAA;AAAA;AAG3C,SAAO;AACT,CAAC;AAAA;AAEH,MAAM,uBAAuB,CAAC,KAAK;AACnC,MAAM,uBAAuB,CAAC,KAAK;AAE5B,MAAM,oBAAoB,aAAAA,QAAM;AAAA,EACrC,CAAC,UAAsG;AACrG,UAAM,EAAE,gBAAgB,GAAG,SAAS,IAAI;AACxC,UAAM,EAAE,OAAO,kBAAkB,mBAAmB,oBAAoB,qBAAqB,IAAI;AACjG,UAAM,EAAE,MAAM,gBAAgB,GAAG,yBAAyB,IAAI;AAC9D,UAAM,EAAE,aAAa,WAAW,IAAI;AACpC,UAAM,wBAAoB,kDAAqB,QAAQ;AACvD,UAAM,uBAAuB,aAAAA,QAAM;AAAA,MACjC,OAAO;AAAA,QACL;AAAA,QACA;AAAA,QACA;AAAA,QACA,eAAe,EAAE,oBAAoB,qBAAqB;AAAA,QAC1D;AAAA,QACA,kBAAkB,EAAE,GAAG,0BAA0B,IAAI,WAAW;AAAA,MAClE;AAAA,MACA;AAAA,QACE;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACF;AAAA,IACF;AACA,UAAM,OAAO,aAAAA,QAAM,QAAQ,MAAM;AAE/B,UAAI,eAAgB,QAAO,CAAC;AAC5B,YAAM,cAAc,CAAC;AACrB,UAAI,KAAM,aAAY,KAAK,MAAM;AACjC,kBAAY,KAAK,KAAK;AACtB,aAAO;AAAA,IACT,GAAG,CAAC,gBAAgB,IAAI,CAAC;AAEzB,UAAM,oBAAgB,+BAAc,CAAC,UAAU,MAAM,GAAG;AACxD,UAAM,yBAAyB,aAAAA,QAAM,YAAY,MAAM,OAAO,CAAC,KAAK,CAAC;AAErE,QAAI;AACF,aACE;AAAA,QAAC;AAAA;AAAA,UACC,MAAM;AAAA,UACN,MAAM;AAAA,UACN,cAAc,QAAQ,WAAW;AAAA,UACjC;AAAA,UACA;AAAA,UAEA,sDAAC,kBAAgB,GAAG,sBAAsB;AAAA;AAAA,MAC5C;AAQJ,WACE;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA,YAAW;AAAA,QACX,IAAG;AAAA,QACH,cAAc,QAAQ,WAAW;AAAA,QACjC;AAAA,QACA;AAAA,QAEC;AAAA,iBACC;AAAA,YAAC;AAAA;AAAA,cACC,YAAW;AAAA,cACX,IAAG;AAAA,cACH;AAAA,cACA;AAAA,cAEA,sDAAC,QAAM,GAAG,sBAAsB;AAAA;AAAA,UAClC,IACE;AAAA,UACJ,4CAAC,kCAAa,GAAG,UAAU;AAAA;AAAA;AAAA,IAC7B;AAAA,EAEJ;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var CheckboxSelectionUI_exports = {};
|
|
30
|
+
__export(CheckboxSelectionUI_exports, {
|
|
31
|
+
CheckboxSelectionUI: () => CheckboxSelectionUI
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(CheckboxSelectionUI_exports);
|
|
34
|
+
var React = __toESM(require("react"));
|
|
35
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
36
|
+
var import_ds_form_checkbox = require("@elliemae/ds-form-checkbox");
|
|
37
|
+
var import_ds_system = require("@elliemae/ds-system");
|
|
38
|
+
var import_react = __toESM(require("react"));
|
|
39
|
+
var import_useStore = require("../../../config/useStore/useStore.js");
|
|
40
|
+
var import_constants = require("../../../constants/index.js");
|
|
41
|
+
const StyledItemSelection = (0, import_ds_system.styled)(import_ds_form_checkbox.DSControlledCheckbox, {
|
|
42
|
+
name: import_constants.DSShuttleV2Name,
|
|
43
|
+
slot: import_constants.DSShuttleV2Slots.ITEM_SELECTION_CHECKBOX_UI
|
|
44
|
+
})`
|
|
45
|
+
margin-left: xxs2;
|
|
46
|
+
margin-right: xxs;
|
|
47
|
+
`;
|
|
48
|
+
const noOp = () => {
|
|
49
|
+
};
|
|
50
|
+
const CheckboxSelectionUI = (props) => {
|
|
51
|
+
const { itemMeta } = props;
|
|
52
|
+
const {
|
|
53
|
+
datumInternalMeta,
|
|
54
|
+
datumRenderFlags: { selectionPrevented }
|
|
55
|
+
} = itemMeta;
|
|
56
|
+
const { isSelected } = datumInternalMeta;
|
|
57
|
+
const getOwnerProps = (0, import_useStore.usePropsStore)((store) => store.get);
|
|
58
|
+
const getOwnerPropsArguments = import_react.default.useCallback(() => itemMeta, [itemMeta]);
|
|
59
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
60
|
+
StyledItemSelection,
|
|
61
|
+
{
|
|
62
|
+
applyAriaDisabled: selectionPrevented,
|
|
63
|
+
getOwnerProps,
|
|
64
|
+
getOwnerPropsArguments,
|
|
65
|
+
"aria-hidden": "true",
|
|
66
|
+
tabIndex: -1,
|
|
67
|
+
checked: isSelected,
|
|
68
|
+
onChange: noOp
|
|
69
|
+
}
|
|
70
|
+
);
|
|
71
|
+
};
|
|
72
|
+
//# sourceMappingURL=CheckboxSelectionUI.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../src/parts/Item/ItemSelectionUi/CheckboxSelectionUI.tsx", "../../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import { DSControlledCheckbox } from '@elliemae/ds-form-checkbox';\nimport { styled } from '@elliemae/ds-system';\nimport React from 'react';\nimport { usePropsStore } from '../../../config/useStore/useStore.js';\nimport { DSShuttleV2Name, DSShuttleV2Slots } from '../../../constants/index.js';\nimport type { SelectionUIProps } from './ItemSelectionUI.types.js';\n\nconst StyledItemSelection = styled(DSControlledCheckbox, {\n name: DSShuttleV2Name,\n slot: DSShuttleV2Slots.ITEM_SELECTION_CHECKBOX_UI,\n})`\n margin-left: xxs2;\n margin-right: xxs;\n`;\nconst noOp = () => {};\n\nexport const CheckboxSelectionUI = (props: SelectionUIProps) => {\n const { itemMeta } = props;\n const {\n datumInternalMeta,\n datumRenderFlags: { selectionPrevented },\n } = itemMeta;\n const { isSelected } = datumInternalMeta;\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = React.useCallback(() => itemMeta, [itemMeta]);\n\n return (\n <StyledItemSelection\n applyAriaDisabled={selectionPrevented}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n // the semantic is already conveyed by the wrapper's aria-checked and aria-disabled, so we hide this from assistive technologies to avoid redundancy\n // we are effectively treating this as a presentational element that only provides a visual cue, so it doesn't need to be announced on its own\n // this is also why we don't tab-index it and we don't onChange it directly, all of that is already handled by the wrapper.\n aria-hidden=\"true\"\n tabIndex={-1}\n checked={isSelected}\n onChange={noOp}\n />\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;AD2BnB;AA3BJ,8BAAqC;AACrC,uBAAuB;AACvB,mBAAkB;AAClB,sBAA8B;AAC9B,uBAAkD;AAGlD,MAAM,0BAAsB,yBAAO,8CAAsB;AAAA,EACvD,MAAM;AAAA,EACN,MAAM,kCAAiB;AACzB,CAAC;AAAA;AAAA;AAAA;AAID,MAAM,OAAO,MAAM;AAAC;AAEb,MAAM,sBAAsB,CAAC,UAA4B;AAC9D,QAAM,EAAE,SAAS,IAAI;AACrB,QAAM;AAAA,IACJ;AAAA,IACA,kBAAkB,EAAE,mBAAmB;AAAA,EACzC,IAAI;AACJ,QAAM,EAAE,WAAW,IAAI;AACvB,QAAM,oBAAgB,+BAAc,CAAC,UAAU,MAAM,GAAG;AACxD,QAAM,yBAAyB,aAAAA,QAAM,YAAY,MAAM,UAAU,CAAC,QAAQ,CAAC;AAE3E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,mBAAmB;AAAA,MACnB;AAAA,MACA;AAAA,MAIA,eAAY;AAAA,MACZ,UAAU;AAAA,MACV,SAAS;AAAA,MACT,UAAU;AAAA;AAAA,EACZ;AAEJ;",
|
|
6
|
+
"names": ["React"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var ItemSelectionUI_exports = {};
|
|
30
|
+
__export(ItemSelectionUI_exports, {
|
|
31
|
+
ItemSelectionUI: () => ItemSelectionUI
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(ItemSelectionUI_exports);
|
|
34
|
+
var React = __toESM(require("react"));
|
|
35
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
36
|
+
var import_ds_grid = require("@elliemae/ds-grid");
|
|
37
|
+
var import_ds_system = require("@elliemae/ds-system");
|
|
38
|
+
var import_react = __toESM(require("react"));
|
|
39
|
+
var import_useStore = require("../../../config/useStore/useStore.js");
|
|
40
|
+
var import_constants = require("../../../constants/index.js");
|
|
41
|
+
var import_CheckboxSelectionUI = require("./CheckboxSelectionUI.js");
|
|
42
|
+
var import_VerticalBarSelectionUI = require("./VerticalBarSelectionUI.js");
|
|
43
|
+
const ItemSelectionWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_constants.DSShuttleV2Name, slot: import_constants.DSShuttleV2Slots.ITEM_CHECKBOX })`
|
|
44
|
+
height: 100%;
|
|
45
|
+
&:focus {
|
|
46
|
+
outline: none;
|
|
47
|
+
}
|
|
48
|
+
`;
|
|
49
|
+
const ItemSelectionUI = (props) => {
|
|
50
|
+
const { tooltipHelpers, itemInnerRefHandlers, itemMeta } = props;
|
|
51
|
+
const {
|
|
52
|
+
datumInternalMeta,
|
|
53
|
+
datumRenderFlags: { selectionPrevented }
|
|
54
|
+
} = itemMeta;
|
|
55
|
+
const { isSelected, hydratedId, softDeleted } = datumInternalMeta;
|
|
56
|
+
const { innerRefHandlerParentItem } = itemInnerRefHandlers;
|
|
57
|
+
const getOwnerProps = (0, import_useStore.usePropsStore)((store) => store.get);
|
|
58
|
+
const explicitSelectionUI = (0, import_useStore.usePropsStore)((store) => store.explicitSelectionUI);
|
|
59
|
+
const getOwnerPropsArguments = import_react.default.useCallback(() => itemMeta, [itemMeta]);
|
|
60
|
+
const idItem = import_react.default.useMemo(
|
|
61
|
+
() => `${hydratedId}-wrapper${softDeleted ? "-soft-deleted" : ""}`,
|
|
62
|
+
[hydratedId, softDeleted]
|
|
63
|
+
);
|
|
64
|
+
const shouldDisable = softDeleted || selectionPrevented;
|
|
65
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
66
|
+
ItemSelectionWrapper,
|
|
67
|
+
{
|
|
68
|
+
role: "checkbox",
|
|
69
|
+
"aria-checked": isSelected,
|
|
70
|
+
onFocus: tooltipHelpers.onFocus,
|
|
71
|
+
onBlur: tooltipHelpers.onBlur,
|
|
72
|
+
"aria-labelledby": `${hydratedId}-text-section${softDeleted ? "-soft-deleted" : ""}`,
|
|
73
|
+
id: idItem,
|
|
74
|
+
innerRef: innerRefHandlerParentItem,
|
|
75
|
+
"aria-disabled": shouldDisable,
|
|
76
|
+
getOwnerProps,
|
|
77
|
+
getOwnerPropsArguments,
|
|
78
|
+
alignItems: "center",
|
|
79
|
+
children: explicitSelectionUI ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_CheckboxSelectionUI.CheckboxSelectionUI, { ...props }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_VerticalBarSelectionUI.VerticalBarSelectionUI, { ...props })
|
|
80
|
+
}
|
|
81
|
+
);
|
|
82
|
+
};
|
|
83
|
+
//# sourceMappingURL=ItemSelectionUI.js.map
|