@equinor/echo-framework 4.3.0-beta-0 → 4.3.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/{f4c85313e79b1662.svg → 1bd97dd2170d0f64.svg} +850 -850
- package/{063009f06499d102.svg → 47deeba42768c5d1.svg} +8 -8
- package/README.md +48 -48
- package/index.cjs.js +2 -2
- package/index.d.ts +2 -2
- package/package.json +6 -6
- package/src/index.d.ts +1 -1
- package/src/lib/components/prepview/panels/objects/objects.logic.d.ts +7 -0
- package/src/lib/components/prepview/panels/objects/objects.utils.d.ts +14 -0
- package/src/lib/components/prepview/panels/objects/selectionActionBarMultiple/AddSelectionListWithSameNameDialog.d.ts +8 -0
- package/src/lib/components/prepview/panels/objects/selectionActionBarMultiple/SelectionActionBarMultiple.d.ts +9 -0
- package/src/lib/components/prepview/panels/objects/selectionActionBarMultiple/logic/selectionActionBarMultiple.colors.d.ts +2 -0
- package/src/lib/components/prepview/panels/objects/selectionActionBarMultiple/logic/selectionActionBarMultiple.constants.d.ts +1 -0
- package/src/lib/components/prepview/panels/objects/selectionActionBarMultiple/logic/selectionActionBarMultiple.orchestration.d.ts +10 -0
- package/src/lib/components/prepview/panels/objects/selectionActionBarMultiple/logic/selectionActionBarMultiple.utils.d.ts +3 -0
- package/src/lib/feature/globalSelection/components/{SelectionActionBar.d.ts → selectionActionBar/SelectionActionBar.d.ts} +1 -1
- package/src/lib/feature/globalSelection/globalSelection.api.d.ts +3 -2
- package/src/lib/feature/globalSelection/globalSelectionColorService.d.ts +3 -3
- package/src/lib/feature/globalSelection/globalSelectionColorService.types.d.ts +1 -0
- package/src/lib/feature/globalSelection/index.d.ts +2 -2
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/actions/addItems.action.d.ts +5 -4
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/actions/removeAllItemsById.action.d.ts +1 -1
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/actions/removeItemsById.action.d.ts +1 -1
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/actions/selectionTree.action.types.d.ts +5 -4
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/selectionTree.store.d.ts +11 -11
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/selectionTree.store.types.d.ts +4 -3
- package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/selectionTree.store.utils.d.ts +9 -7
- /package/src/lib/feature/globalSelection/components/{RemoveSelectionItemsConfirmDialog.d.ts → selectionActionBar/RemoveSelectionItemsConfirmDialog.d.ts} +0 -0
- /package/src/lib/feature/globalSelection/components/{SelectionActionBar → selectionActionBar}/SelectionActionBarMenuItem.d.ts +0 -0
package/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from "./src
|
|
2
|
-
export { default } from "./src
|
|
1
|
+
export * from "./src/index";
|
|
2
|
+
export { default } from "./src/index";
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/echo-framework",
|
|
3
|
-
"version": "4.3.0
|
|
3
|
+
"version": "4.3.0",
|
|
4
4
|
"peerDependencies": {
|
|
5
|
-
"@equinor/echo-base": "4.3.0
|
|
6
|
-
"@equinor/echo-components": "4.3.0
|
|
7
|
-
"@equinor/echo-core": "4.3.0
|
|
8
|
-
"@equinor/echo-search": "4.3.0
|
|
9
|
-
"@equinor/echo-utils": "4.3.0
|
|
5
|
+
"@equinor/echo-base": ">= 4.3.0 < 5.0.0",
|
|
6
|
+
"@equinor/echo-components": ">= 4.3.0 < 5.0.0",
|
|
7
|
+
"@equinor/echo-core": ">= 4.3.0 < 5.0.0",
|
|
8
|
+
"@equinor/echo-search": ">= 4.3.0 < 5.0.0",
|
|
9
|
+
"@equinor/echo-utils": ">= 4.3.0 < 5.0.0",
|
|
10
10
|
"@equinor/eds-core-react": "0.49.0",
|
|
11
11
|
"@equinor/eds-icons": "0.22.0",
|
|
12
12
|
"@equinor/eds-tokens": "2.1.0",
|
package/src/index.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ export { ReturnToExternalAppButton } from './lib/feature/echoView/ReturnToExtern
|
|
|
19
19
|
export { fetchEquipmentFromApi } from './lib/feature/equipment/api/api-equipmentWithMeasuringPoints';
|
|
20
20
|
export * from './lib/feature/equipment/index';
|
|
21
21
|
export * from './lib/feature/globalSelection';
|
|
22
|
-
export { ItemDetailsSelectionActionBar, SelectionActionBar } from './lib/feature/globalSelection/components/SelectionActionBar';
|
|
22
|
+
export { ItemDetailsSelectionActionBar, SelectionActionBar } from './lib/feature/globalSelection/components/selectionActionBar/SelectionActionBar';
|
|
23
23
|
export { PanTo3DButton } from './lib/feature/globalSelection/panToEcho3d/panTo3DButton';
|
|
24
24
|
export { useIsAllIGlobalSelectionItemsHidden } from './lib/feature/globalSelection/selectionMenu/hooks/useIsAllIGlobalSelectionItemsHidden';
|
|
25
25
|
export { useSelectionColorFrequencyByIds } from './lib/feature/globalSelection/selectionMenu/hooks/useSelectionColorFrequency';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { GlobalSelectionTypes } from '../../../../feature/globalSelection/globalSelectionStore/globalSelectionStore.types';
|
|
2
|
+
import type { PrepviewObject } from '../../types/workorder';
|
|
3
|
+
export declare function fetchWorkOrderObjectsWithSelectionIds(workOrderId: string): Promise<{
|
|
4
|
+
workOrderObjects: PrepviewObject[];
|
|
5
|
+
tagIds: GlobalSelectionTypes.TagId[];
|
|
6
|
+
equipmentIds: GlobalSelectionTypes.EquipmentId[];
|
|
7
|
+
}>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { GlobalSelectionTypes } from '../../../../feature/globalSelection/globalSelectionStore/globalSelectionStore.types';
|
|
2
|
+
import type { PrepviewObject } from '../../types/workorder';
|
|
3
|
+
/**
|
|
4
|
+
* Extracts tag IDs from the given work order objects.
|
|
5
|
+
* @param workOrderObjects The work order objects to extract tag IDs from.
|
|
6
|
+
* @returns A promise that resolves to an array of tag IDs.
|
|
7
|
+
*/
|
|
8
|
+
export declare function extractTagIdsFromWorkOrderObjects(workOrderObjects: ReadonlyArray<PrepviewObject>): Promise<GlobalSelectionTypes.TagId[]>;
|
|
9
|
+
/**
|
|
10
|
+
* Extracts equipment IDs from the given work order objects.
|
|
11
|
+
* @param workOrderObjects The work order objects to extract equipment IDs from.
|
|
12
|
+
* @returns An array of equipment IDs.
|
|
13
|
+
*/
|
|
14
|
+
export declare function extractEquipmentIdsFromWorkOrderObjects(workOrderObjects: ReadonlyArray<PrepviewObject>): GlobalSelectionTypes.EquipmentId[];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface AddSelectionListWithSameNameDialogProps {
|
|
3
|
+
readonly isOpen: boolean;
|
|
4
|
+
readonly onClose: () => void;
|
|
5
|
+
readonly onAddNewList: () => void | Promise<void>;
|
|
6
|
+
}
|
|
7
|
+
export declare const AddSelectionListWithSameNameDialog: React.FC<AddSelectionListWithSameNameDialogProps>;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { GlobalSelectionTypes } from '../../../../../feature/globalSelection/globalSelectionStore/globalSelectionStore.types';
|
|
2
|
+
export interface SelectionActionBarMultipleProps {
|
|
3
|
+
readonly selectionItemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
4
|
+
readonly hiddenSelectionItemIds?: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
5
|
+
readonly labelSelectionGroup: string;
|
|
6
|
+
readonly subLabelSelectionGroup?: string;
|
|
7
|
+
readonly className?: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const SelectionActionBarMultiple: React.FC<SelectionActionBarMultipleProps>;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { GlobalSelectionItemType } from '../../../../../../feature/globalSelection/globalSelectionStore/globalSelectionStore.types';
|
|
2
|
+
export declare function getUniqueSelectionItemTypes(itemTypes: ReadonlyArray<GlobalSelectionItemType>): ReadonlyArray<GlobalSelectionItemType>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const OBJECT_LIST_FOR_WORK_ORDER_LABEL_PREFIX = "Object list for WO ";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Guid } from '@equinor/echo-utils';
|
|
2
|
+
import { type GlobalSelectionTypes } from '../../../../../../feature/globalSelection/globalSelectionStore/globalSelectionStore.types';
|
|
3
|
+
import { SelectionTreeTypes } from '../../../../../../feature/globalSelection/selectionMenu/selectionTreeStore/selectionTree.store.types';
|
|
4
|
+
export declare function addSelectionItemsToNewSelectionGroup(args: {
|
|
5
|
+
readonly selectionItemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
6
|
+
readonly hiddenSelectionItemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
7
|
+
readonly label: string;
|
|
8
|
+
readonly subLabel: string;
|
|
9
|
+
readonly selectionGroups: ReadonlyArray<SelectionTreeTypes.Group>;
|
|
10
|
+
}): Promise<Guid>;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { SelectionTreeTypes } from '../../../../../../feature/globalSelection/selectionMenu/selectionTreeStore/selectionTree.store.types';
|
|
2
|
+
export declare function doesSelectionGroupLabelExist(label: string, groups: ReadonlyArray<SelectionTreeTypes.Group>): boolean;
|
|
3
|
+
export declare function getNextAvailableGroupLabel(label: string, groups: ReadonlyArray<SelectionTreeTypes.Group>): string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GlobalSelectionTypes } from '
|
|
1
|
+
import { GlobalSelectionTypes } from '../../globalSelectionStore/globalSelectionStore.types';
|
|
2
2
|
export interface SelectionActionBarProps {
|
|
3
3
|
readonly itemId: GlobalSelectionTypes.ItemId;
|
|
4
4
|
readonly className?: string;
|
|
@@ -29,7 +29,7 @@ export declare const globalSelectionApi: Readonly<{
|
|
|
29
29
|
itemsById: (args: {
|
|
30
30
|
groupId?: import("@equinor/echo-utils").Guid;
|
|
31
31
|
categoryId: GlobalSelectionCategoryId;
|
|
32
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
32
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
33
33
|
}) => void;
|
|
34
34
|
/**
|
|
35
35
|
* Removes all items by their IDs, from all groups, from the state.
|
|
@@ -109,8 +109,9 @@ export declare const globalSelectionApi: Readonly<{
|
|
|
109
109
|
*
|
|
110
110
|
*/
|
|
111
111
|
addItems: (args: {
|
|
112
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
112
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
113
113
|
groupId?: import("@equinor/echo-utils").Guid;
|
|
114
|
+
useDefaultSelectionTypeColors?: boolean;
|
|
114
115
|
}) => Promise<void>;
|
|
115
116
|
}>;
|
|
116
117
|
search: {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { SelectionColor } from './globalSelectionColorService.types';
|
|
1
2
|
import { GlobalSelectionItemType } from './globalSelectionStore/globalSelectionStore.types';
|
|
2
3
|
type ColorServiceState = {
|
|
3
4
|
/**
|
|
@@ -43,8 +44,7 @@ export declare const SELECTION_COLOR_PICKER_COLORS: Readonly<string>[];
|
|
|
43
44
|
declare const UNIFIED_COLOR_POOL: string[];
|
|
44
45
|
export { UNIFIED_COLOR_POOL };
|
|
45
46
|
/**
|
|
46
|
-
*
|
|
47
|
-
*
|
|
47
|
+
* *
|
|
48
48
|
* Returns the color associated with a given `GlobalSelectionItemType`.
|
|
49
49
|
*
|
|
50
50
|
* This function maps specific item types to their corresponding selection colors,
|
|
@@ -54,4 +54,4 @@ export { UNIFIED_COLOR_POOL };
|
|
|
54
54
|
* @param itemType - The type of the global selection item for which to retrieve the color.
|
|
55
55
|
* @returns The color string associated with the specified item type.
|
|
56
56
|
*/
|
|
57
|
-
export declare function
|
|
57
|
+
export declare function getDefaultSelectionColorByItemType(itemType: GlobalSelectionItemType): SelectionColor;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export * from './globalSelectionStore/globalSelectionStore.types';
|
|
2
2
|
export * from './selectionMenu/selectionTreeStore/selectionTree.api.types';
|
|
3
3
|
export * from './selectionMenu/selectionTreeStore/selectionTree.store.types';
|
|
4
|
-
export {
|
|
4
|
+
export { PDMS_INTERNAL_TAG_TYPES, isPdmsInternalTagType } from './pdmsTag/pdmsTag.types';
|
|
5
5
|
export type { PdmsInternalTagType, PdmsTagId, PdmsTagSummaryDto, StidTagId } from './pdmsTag/pdmsTag.types';
|
|
6
6
|
export { useAreAllItemsVisible } from './hooks/useAreAllItemsVisible';
|
|
7
7
|
export { useGlobalSelectionByItemId } from './hooks/useGlobalSelectionByItemId';
|
|
@@ -18,7 +18,7 @@ export { useCurrentSelectionId } from './selectionMenu/hooks/useCurrentSelection
|
|
|
18
18
|
export { useFetchSelectionHistory } from './selectionMenu/hooks/useFetchSelectionHistory';
|
|
19
19
|
export { useGlobalSelectionGroups } from './selectionMenu/hooks/useGlobalSelectionGroups';
|
|
20
20
|
export { useMostUsedSelectionColorByIds } from './selectionMenu/hooks/useSelectionColorFrequency';
|
|
21
|
-
export { RemoveSelectionItemsConfirmDialog } from './components/RemoveSelectionItemsConfirmDialog';
|
|
21
|
+
export { RemoveSelectionItemsConfirmDialog } from './components/selectionActionBar/RemoveSelectionItemsConfirmDialog';
|
|
22
22
|
export { globalSelectionApi } from './globalSelection.api';
|
|
23
23
|
export { globalSelectionInternal } from './globalSelection.internal';
|
|
24
24
|
export { SELECTION_COLOR_PICKER_COLORS } from './globalSelectionColorService';
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import { Guid } from '@equinor/echo-utils';
|
|
2
2
|
import { GlobalSelectionTypes } from '../../../globalSelectionStore/globalSelectionStore.types';
|
|
3
3
|
import { SelectionTreeStore } from '../selectionTree.store.types';
|
|
4
|
+
export type AddItemsActionArgs = {
|
|
5
|
+
readonly itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
6
|
+
readonly groupId?: Guid;
|
|
7
|
+
readonly useDefaultSelectionTypeColors?: boolean;
|
|
8
|
+
};
|
|
4
9
|
/**
|
|
5
10
|
* Adds items to the selection tree store by categorizing them into tags, work orders,
|
|
6
11
|
* equipments, and measuring points, then dispatching the appropriate add actions for each type.
|
|
@@ -10,7 +15,3 @@ import { SelectionTreeStore } from '../selectionTree.store.types';
|
|
|
10
15
|
* @returns A promise that resolves when all items have been added to the store.
|
|
11
16
|
*/
|
|
12
17
|
export declare function addItems(get: () => SelectionTreeStore, args: AddItemsActionArgs): Promise<void>;
|
|
13
|
-
export type AddItemsActionArgs = {
|
|
14
|
-
itemIds: GlobalSelectionTypes.ItemId[];
|
|
15
|
-
groupId?: Guid;
|
|
16
|
-
};
|
|
@@ -10,6 +10,6 @@ type SetFunction = (set: (state: SelectionTreeStore) => void, shouldReplace?: bo
|
|
|
10
10
|
* @returns {void}
|
|
11
11
|
*/
|
|
12
12
|
export declare function removeAllItemsById(set: SetFunction, args: {
|
|
13
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
13
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
14
14
|
}): void;
|
|
15
15
|
export {};
|
|
@@ -19,6 +19,6 @@ export declare function removeItemsById(set: SetFunction, args: RemoveItemsByIdA
|
|
|
19
19
|
type RemoveItemsByIdArgs = {
|
|
20
20
|
groupId?: Guid;
|
|
21
21
|
categoryId: GlobalSelectionCategoryId;
|
|
22
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
22
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
23
23
|
};
|
|
24
24
|
export {};
|
|
@@ -2,9 +2,10 @@ import { ResultArray } from '@equinor/echo-search';
|
|
|
2
2
|
import { Guid } from '@equinor/echo-utils';
|
|
3
3
|
import { GlobalSelectionItemType, GlobalSelectionItemTypeToDataMap, GlobalSelectionTypes, SelectionItemTypeToItemIdMap } from '../../../globalSelectionStore/globalSelectionStore.types';
|
|
4
4
|
type AddItemArgsBase<ItemIdType extends GlobalSelectionTypes.ItemId> = {
|
|
5
|
-
itemIds: Readonly<ItemIdType[]>;
|
|
6
|
-
replaceItems?: boolean;
|
|
7
|
-
|
|
5
|
+
readonly itemIds: Readonly<ItemIdType[]>;
|
|
6
|
+
readonly replaceItems?: boolean;
|
|
7
|
+
readonly useDefaultSelectionTypeColors?: boolean;
|
|
8
|
+
readonly getActionResult?: boolean;
|
|
8
9
|
};
|
|
9
10
|
type AddItemArgsExclusive = {
|
|
10
11
|
groupId: Guid;
|
|
@@ -20,7 +21,7 @@ export type AddItemsResponse<T extends GlobalSelectionItemType> = {
|
|
|
20
21
|
fetchResults: ResultArray<GlobalSelectionItemTypeToDataMap[T]>[];
|
|
21
22
|
itemsAdded: Readonly<SelectionItemTypeToItemIdMap[T][]>;
|
|
22
23
|
actionResult: SelectionTreeActionResult;
|
|
23
|
-
affectedGroupId
|
|
24
|
+
affectedGroupId: Guid | undefined;
|
|
24
25
|
};
|
|
25
26
|
export type SelectionTreeActionResult = 'ItemsUpdated' | 'ItemsAdded' | 'NewGroupCreated' | 'NoChanges';
|
|
26
27
|
export {};
|
package/src/lib/feature/globalSelection/selectionMenu/selectionTreeStore/selectionTree.store.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Guid } from '@equinor/echo-utils';
|
|
2
|
-
import { GlobalSelectionTypes } from '../../globalSelectionStore/globalSelectionStore.types';
|
|
3
2
|
import { SelectionGroup, SelectionTreeStore } from './selectionTree.store.types';
|
|
4
3
|
/**
|
|
5
4
|
* Zustand store hook for managing the selection tree state in the global selection feature.
|
|
@@ -34,13 +33,14 @@ export declare const useSelectionTreeStore: import("zustand").UseBoundStore<Omit
|
|
|
34
33
|
guid: Guid | undefined;
|
|
35
34
|
}) => void;
|
|
36
35
|
addItems: (args: {
|
|
37
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
36
|
+
itemIds: ReadonlyArray<import("../..").GlobalSelectionTypes.ItemId>;
|
|
38
37
|
groupId?: Guid;
|
|
38
|
+
useDefaultSelectionTypeColors?: boolean;
|
|
39
39
|
}) => Promise<void>;
|
|
40
|
-
addTags: (args: import("./actions/selectionTree.action.types").AddItemArgs<GlobalSelectionTypes.TagId>) => import("./selectionTree.store.types").AddTagsReturnType;
|
|
41
|
-
addWorkOrders: (args: import("./actions/selectionTree.action.types").AddItemArgs<GlobalSelectionTypes.WorkOrderId>) => import("./selectionTree.store.types").AddWorkOrdersReturnType;
|
|
42
|
-
addEquipments: (args: import("./actions/selectionTree.action.types").AddItemArgs<GlobalSelectionTypes.EquipmentId>) => import("./selectionTree.store.types").AddEquipmentsReturnType;
|
|
43
|
-
addMeasuringPoints: (args: import("./actions/selectionTree.action.types").AddItemArgs<GlobalSelectionTypes.MeasuringPointId>) => import("./selectionTree.store.types").AddMeasuringPointsReturnType;
|
|
40
|
+
addTags: (args: import("./actions/selectionTree.action.types").AddItemArgs<import("../..").GlobalSelectionTypes.TagId>) => import("./selectionTree.store.types").AddTagsReturnType;
|
|
41
|
+
addWorkOrders: (args: import("./actions/selectionTree.action.types").AddItemArgs<import("../..").GlobalSelectionTypes.WorkOrderId>) => import("./selectionTree.store.types").AddWorkOrdersReturnType;
|
|
42
|
+
addEquipments: (args: import("./actions/selectionTree.action.types").AddItemArgs<import("../..").GlobalSelectionTypes.EquipmentId>) => import("./selectionTree.store.types").AddEquipmentsReturnType;
|
|
43
|
+
addMeasuringPoints: (args: import("./actions/selectionTree.action.types").AddItemArgs<import("../..").GlobalSelectionTypes.MeasuringPointId>) => import("./selectionTree.store.types").AddMeasuringPointsReturnType;
|
|
44
44
|
createGroup: (args: {
|
|
45
45
|
groupId?: string;
|
|
46
46
|
label: string;
|
|
@@ -59,15 +59,15 @@ export declare const useSelectionTreeStore: import("zustand").UseBoundStore<Omit
|
|
|
59
59
|
removeItemsById: (args: {
|
|
60
60
|
groupId?: Guid;
|
|
61
61
|
categoryId: import("./selectionTree.store.types").GlobalSelectionCategoryId;
|
|
62
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
62
|
+
itemIds: ReadonlyArray<import("../..").GlobalSelectionTypes.ItemId>;
|
|
63
63
|
}) => void;
|
|
64
64
|
removeAllItemsById: (args: {
|
|
65
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
65
|
+
itemIds: ReadonlyArray<import("../..").GlobalSelectionTypes.ItemId>;
|
|
66
66
|
}) => void;
|
|
67
67
|
moveItems: (args: {
|
|
68
68
|
sourceGroupId: Guid;
|
|
69
69
|
sourceCategoryId?: import("./selectionTree.store.types").GlobalSelectionCategoryId;
|
|
70
|
-
sourceItemId?: GlobalSelectionTypes.ItemId;
|
|
70
|
+
sourceItemId?: import("../..").GlobalSelectionTypes.ItemId;
|
|
71
71
|
targetGroupId: Guid;
|
|
72
72
|
}) => void;
|
|
73
73
|
setVisibilityById: (args: {
|
|
@@ -85,7 +85,7 @@ export declare const useSelectionTreeStore: import("zustand").UseBoundStore<Omit
|
|
|
85
85
|
categories: {
|
|
86
86
|
id: import("./selectionTree.store.types").GlobalSelectionCategoryId;
|
|
87
87
|
label: string;
|
|
88
|
-
items: Map<GlobalSelectionTypes.ItemIdString, {
|
|
88
|
+
items: Map<import("../..").GlobalSelectionTypes.ItemIdString, {
|
|
89
89
|
id: {
|
|
90
90
|
workOrderId: string;
|
|
91
91
|
} | {
|
|
@@ -102,7 +102,7 @@ export declare const useSelectionTreeStore: import("zustand").UseBoundStore<Omit
|
|
|
102
102
|
} | {
|
|
103
103
|
measuringPointId: string;
|
|
104
104
|
};
|
|
105
|
-
type: import("
|
|
105
|
+
type: import("../..").GlobalSelectionItemType;
|
|
106
106
|
}>;
|
|
107
107
|
}[];
|
|
108
108
|
groupId: Guid;
|
|
@@ -35,8 +35,9 @@ export interface SelectionTreeStore extends SelectionTreeData {
|
|
|
35
35
|
guid: Guid | undefined;
|
|
36
36
|
}) => void;
|
|
37
37
|
addItems: (args: {
|
|
38
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
38
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
39
39
|
groupId?: Guid;
|
|
40
|
+
useDefaultSelectionTypeColors?: boolean;
|
|
40
41
|
}) => Promise<void>;
|
|
41
42
|
addTags: (args: AddItemArgs<GlobalSelectionTypes.TagId>) => AddTagsReturnType;
|
|
42
43
|
addWorkOrders: (args: AddItemArgs<GlobalSelectionTypes.WorkOrderId>) => AddWorkOrdersReturnType;
|
|
@@ -60,10 +61,10 @@ export interface SelectionTreeStore extends SelectionTreeData {
|
|
|
60
61
|
removeItemsById: (args: {
|
|
61
62
|
groupId?: Guid;
|
|
62
63
|
categoryId: GlobalSelectionCategoryId;
|
|
63
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
64
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
64
65
|
}) => void;
|
|
65
66
|
removeAllItemsById: (args: {
|
|
66
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
67
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
67
68
|
}) => void;
|
|
68
69
|
moveItems: (args: {
|
|
69
70
|
sourceGroupId: Guid;
|
|
@@ -50,7 +50,7 @@ export declare function findSelectionCategoryById(args: {
|
|
|
50
50
|
*/
|
|
51
51
|
export declare function itemsNotFoundInSelectionTree(args: {
|
|
52
52
|
groups: SelectionTreeTypes.Group[];
|
|
53
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
53
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
54
54
|
}): GlobalSelectionTypes.ItemId[];
|
|
55
55
|
/**
|
|
56
56
|
* Get an array of group IDs where any of the item IDs are found.
|
|
@@ -64,7 +64,7 @@ export declare function itemsNotFoundInSelectionTree(args: {
|
|
|
64
64
|
* @returns {Object[]} An array of group IDs, with labels and sublabels, where any of the item IDs are found.
|
|
65
65
|
*/
|
|
66
66
|
export declare function getGroupIdsByItemIds(args: {
|
|
67
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
67
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
68
68
|
groups: SelectionTreeTypes.Group[];
|
|
69
69
|
}): {
|
|
70
70
|
id: Guid;
|
|
@@ -103,8 +103,8 @@ export declare function isSelectionEmpty(groups: SelectionTreeTypes.Group[]): bo
|
|
|
103
103
|
* @param {GlobalSelectionTypes.ItemId[]} itemIds - The list of item IDs to be checked and potentially removed.
|
|
104
104
|
* @returns {void}
|
|
105
105
|
*/
|
|
106
|
-
export declare function removeStaleItemsFromGlobalSelection(groups: SelectionTreeTypes.Group[], itemIds: GlobalSelectionTypes.ItemId
|
|
107
|
-
export declare function getItemsByIdsFromGlobalSelectionStore(itemIds: GlobalSelectionTypes.ItemId
|
|
106
|
+
export declare function removeStaleItemsFromGlobalSelection(groups: SelectionTreeTypes.Group[], itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>): void;
|
|
107
|
+
export declare function getItemsByIdsFromGlobalSelectionStore(itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>): GlobalSelectionTypes.SelectionItem[];
|
|
108
108
|
/**
|
|
109
109
|
* Returns an array of selection colors sorted by their frequency for the specified item IDs within a group.
|
|
110
110
|
*
|
|
@@ -122,7 +122,7 @@ export declare function getItemsByIdsFromGlobalSelectionStore(itemIds: GlobalSel
|
|
|
122
122
|
*/
|
|
123
123
|
export declare function getSelectionColorFrequencyByIds(args: {
|
|
124
124
|
groupId: string;
|
|
125
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
125
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
126
126
|
allGroups: ReadonlyArray<SelectionTreeTypes.Group>;
|
|
127
127
|
}): string[];
|
|
128
128
|
/**
|
|
@@ -143,8 +143,9 @@ export declare function handleItemColorization(args: {
|
|
|
143
143
|
itemType: GlobalSelectionItemType;
|
|
144
144
|
treeState: SelectionTreeStore;
|
|
145
145
|
affectedGroupId?: Guid;
|
|
146
|
-
itemIds: GlobalSelectionTypes.ItemId
|
|
146
|
+
itemIds: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
147
147
|
handleColorConflicts?: boolean;
|
|
148
|
+
useDefaultSelectionTypeColors?: boolean;
|
|
148
149
|
}): string | undefined;
|
|
149
150
|
/**
|
|
150
151
|
* Assigns a color to a set of items within a specified group in the selection tree.
|
|
@@ -164,5 +165,6 @@ export declare function assignColorToItemsInGroup(args: {
|
|
|
164
165
|
itemType: GlobalSelectionItemType;
|
|
165
166
|
allGroups: ReadonlyArray<SelectionTreeTypes.Group>;
|
|
166
167
|
groupId: string;
|
|
167
|
-
itemIdsToColor: GlobalSelectionTypes.ItemId
|
|
168
|
+
itemIdsToColor: ReadonlyArray<GlobalSelectionTypes.ItemId>;
|
|
169
|
+
useDefaultSelectionTypeColors?: boolean;
|
|
168
170
|
}): string | undefined;
|
|
File without changes
|