@equinor/echo-framework 0.20.17 → 0.20.19-beta-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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@equinor/echo-framework",
3
- "version": "0.20.17",
3
+ "version": "0.20.19-beta-0",
4
4
  "peerDependencies": {
5
5
  "@equinor/echo-base": ">= 0.7.0 < 0.8.0",
6
6
  "@equinor/echo-components": ">= 0.11.0 < 0.12.0",
package/src/index.d.ts CHANGED
@@ -28,6 +28,7 @@ export { WorkOrderContent } from './lib/feature/workOrder/WorkOrderContent';
28
28
  export { RegisteredHookName } from './lib/hooks/hookLibrary';
29
29
  export { useIsCompactLayout } from './lib/hooks/useIsCompactLayout';
30
30
  export { useIsFullScreenModeEnabled } from './lib/hooks/useIsFullScreenModeEnabled';
31
+ export { useOpenPrepview } from './lib/hooks/useOpenPrepview';
31
32
  export { useScreenOrientation } from './lib/hooks/useScreenOrientation';
32
33
  export { useScreenValues } from './lib/hooks/useScreenValues';
33
34
  export { getPlantsCachedOrApi, getPlantsFromApi } from './lib/services/api/api-plants';
@@ -36,7 +36,7 @@ export declare enum LegendStatus {
36
36
  LO = "LO",
37
37
  OnWatch = "OnWatch",
38
38
  InProgress = "InProgress",
39
- AnnotationError = "AnnotationError"
39
+ IocAnnotationError = "IocAnnotationError"
40
40
  }
41
41
  export declare enum LegendType {
42
42
  Stid = "Stid",
@@ -50,5 +50,5 @@ export declare enum LegendType {
50
50
  ValvePosition = "ValvePosition",
51
51
  MeasuringPosition = "MeasuringPosition",
52
52
  WorkPermit = "WorkPermit",
53
- Annotations = "Annotations"
53
+ IocAnnotations = "IocAnnotations"
54
54
  }
@@ -0,0 +1,10 @@
1
+ export declare function useOpenPrepview(): (args: {
2
+ prepviewInput: {
3
+ notificationId?: string;
4
+ workOrderId?: string;
5
+ punchId?: string;
6
+ instCode?: string;
7
+ };
8
+ panelKey: string;
9
+ keepLastNavigationItem?: boolean;
10
+ }) => void;
@@ -3,7 +3,7 @@ interface PanelUserSettings {
3
3
  readonly isTagsVisible: boolean;
4
4
  readonly isWorkOrdersVisible: boolean;
5
5
  readonly isEquipmentsVisible: boolean;
6
- readonly isAnnotationsVisible: boolean;
6
+ readonly isIocAnnotationsVisible: boolean;
7
7
  }
8
8
  interface DataLayerPanelState {
9
9
  readonly isOpen: boolean;
@@ -14,7 +14,7 @@ interface DataLayerPanelActions {
14
14
  toggleWorkOrders: () => void;
15
15
  toggleEquipments: () => void;
16
16
  toggleTags: () => void;
17
- toggleAnnotations: () => void;
17
+ toggleIocAnnotations: () => void;
18
18
  }
19
19
  type DataLayerPanelStore = DataLayerPanelState & DataLayerPanelActions;
20
20
  export declare const useDataLayerPanelStore: import("zustand").UseBoundStore<Omit<Omit<Omit<Omit<import("zustand").StoreApi<DataLayerPanelStore>, "setState"> & {
@@ -1,13 +1,13 @@
1
1
  import { LeftPanelNavigationStore } from './leftPanelNavigation.store.types';
2
- export declare const useLeftPanelNavigationStore: import("zustand").UseBoundStore<Omit<Omit<import("zustand").StoreApi<unknown>, "subscribe"> & {
2
+ export declare const useLeftPanelNavigationStore: import("zustand").UseBoundStore<Omit<Omit<import("zustand").StoreApi<LeftPanelNavigationStore>, "subscribe"> & {
3
3
  subscribe: {
4
- (listener: (selectedState: unknown, previousSelectedState: unknown) => void): () => void;
5
- <U>(selector: (state: unknown) => U, listener: (selectedState: U, previousSelectedState: U) => void, options?: {
4
+ (listener: (selectedState: LeftPanelNavigationStore, previousSelectedState: LeftPanelNavigationStore) => void): () => void;
5
+ <U>(selector: (state: LeftPanelNavigationStore) => U, listener: (selectedState: U, previousSelectedState: U) => void, options?: {
6
6
  equalityFn?: ((a: U, b: U) => boolean) | undefined;
7
7
  fireImmediately?: boolean;
8
8
  } | undefined): () => void;
9
9
  };
10
10
  }, "setState"> & {
11
- setState(nextStateOrUpdater: unknown, shouldReplace?: boolean | undefined): void;
11
+ setState(nextStateOrUpdater: LeftPanelNavigationStore | Partial<LeftPanelNavigationStore> | ((state: import("immer").WritableDraft<LeftPanelNavigationStore>) => void), shouldReplace?: boolean | undefined): void;
12
12
  }>;
13
13
  export declare function getLeftPanelNavigationState(): LeftPanelNavigationStore;
@@ -1,25 +1,36 @@
1
1
  interface UserSettings {
2
2
  measuringPointsEnabled: boolean;
3
+ }
4
+ interface UserSettingsActions {
3
5
  setMeasuringPointsEnabled: (value: boolean) => void;
4
6
  }
5
- export declare function userSettingsSnapshot(): UserSettings;
6
- export declare const useUserSettingsStore: import("zustand").UseBoundStore<Omit<Omit<Omit<import("zustand").StoreApi<UserSettings>, "setState"> & {
7
+ type UserSettingsStore = UserSettings & UserSettingsActions;
8
+ export declare const useUserSettingsStore: import("zustand").UseBoundStore<Omit<Omit<Omit<Omit<import("zustand").StoreApi<UserSettingsStore>, "setState"> & {
7
9
  setState<A extends string | {
8
10
  type: string;
9
- }>(partial: UserSettings | Partial<UserSettings> | ((state: UserSettings) => UserSettings | Partial<UserSettings>), replace?: boolean | undefined, action?: A | undefined): void;
11
+ }>(partial: UserSettingsStore | Partial<UserSettingsStore> | ((state: UserSettingsStore) => UserSettingsStore | Partial<UserSettingsStore>), replace?: boolean | undefined, action?: A | undefined): void;
12
+ }, "subscribe"> & {
13
+ subscribe: {
14
+ (listener: (selectedState: UserSettingsStore, previousSelectedState: UserSettingsStore) => void): () => void;
15
+ <U>(selector: (state: UserSettingsStore) => U, listener: (selectedState: U, previousSelectedState: U) => void, options?: {
16
+ equalityFn?: ((a: U, b: U) => boolean) | undefined;
17
+ fireImmediately?: boolean;
18
+ } | undefined): () => void;
19
+ };
10
20
  }, "persist"> & {
11
21
  persist: {
12
- setOptions: (options: Partial<import("zustand/middleware").PersistOptions<UserSettings, unknown>>) => void;
22
+ setOptions: (options: Partial<import("zustand/middleware").PersistOptions<UserSettingsStore, unknown>>) => void;
13
23
  clearStorage: () => void;
14
24
  rehydrate: () => Promise<void> | void;
15
25
  hasHydrated: () => boolean;
16
- onHydrate: (fn: (state: UserSettings) => void) => () => void;
17
- onFinishHydration: (fn: (state: UserSettings) => void) => () => void;
18
- getOptions: () => Partial<import("zustand/middleware").PersistOptions<UserSettings, unknown>>;
26
+ onHydrate: (fn: (state: UserSettingsStore) => void) => () => void;
27
+ onFinishHydration: (fn: (state: UserSettingsStore) => void) => () => void;
28
+ getOptions: () => Partial<import("zustand/middleware").PersistOptions<UserSettingsStore, unknown>>;
19
29
  };
20
30
  }, "setState"> & {
21
- setState(nextStateOrUpdater: UserSettings | Partial<UserSettings> | ((state: import("immer").WritableDraft<UserSettings>) => void), shouldReplace?: boolean | undefined, action?: string | {
31
+ setState(nextStateOrUpdater: UserSettingsStore | Partial<UserSettingsStore> | ((state: import("immer").WritableDraft<UserSettingsStore>) => void), shouldReplace?: boolean | undefined, action?: string | {
22
32
  type: string;
23
33
  } | undefined): void;
24
34
  }>;
35
+ export declare function userSettingsSnapshot(): UserSettingsStore;
25
36
  export {};
@@ -1,6 +1,5 @@
1
1
  export type { FullScreenModeEvent } from './fullScreenModeEvent';
2
2
  export type { LegendChangedEvent, LegendStatusesChangedEvent } from './legendEvent';
3
- export type { OnMainSearchTriggerEvent } from './onMainSearchTriggerEvent';
4
3
  export type { PlantEvent } from './plantEvent';
5
4
  export type { PrepviewEvent } from './prepviewEvent';
6
5
  export type { SearchItemDetailsClosedEvent } from './searchDetailsContainerEvents';
@@ -9,5 +9,5 @@ export declare enum SearchItemDetailsType {
9
9
  WorkOrder = "WorkOrder",
10
10
  MeasuringPoint = "MeasuringPoint",
11
11
  Equipment = "Equipment",
12
- Annotation = "Annotation"
12
+ IocAnnotation = "IocAnnotation"
13
13
  }
@@ -1,15 +0,0 @@
1
- import React from 'react';
2
- interface MeasuringPointImageViewProps {
3
- title: string;
4
- date: string;
5
- triggerScrim: () => void;
6
- showPrevious: () => void;
7
- showNext: () => void;
8
- showPrevIcon: boolean;
9
- showNextIcon: boolean;
10
- imageSrc: string;
11
- description?: string;
12
- open: boolean;
13
- }
14
- export declare const MeasuringPointImageView: React.FC<React.PropsWithChildren<MeasuringPointImageViewProps>>;
15
- export {};
@@ -1,7 +0,0 @@
1
- import React from 'react';
2
- interface MeasuringPointImageViewFooterProps {
3
- description?: string;
4
- date: string;
5
- }
6
- export declare const MeasuringPointImageViewFooter: React.FC<MeasuringPointImageViewFooterProps>;
7
- export {};
@@ -1,10 +0,0 @@
1
- import React from 'react';
2
- interface MeasuringPointImageViewMediaProps {
3
- imageSrc: string;
4
- showPrevious: () => void;
5
- showNext: () => void;
6
- showNextIcon: boolean;
7
- showPrevIcon: boolean;
8
- }
9
- export declare const MeasuringPointImageViewMedia: React.FC<React.PropsWithChildren<MeasuringPointImageViewMediaProps>>;
10
- export {};
@@ -1,8 +0,0 @@
1
- type Direction = 'previous' | 'next';
2
- interface NavigationButtonProps {
3
- direction: Direction;
4
- onClick: () => void;
5
- disabled?: boolean;
6
- }
7
- export declare const NavigationButton: React.FC<NavigationButtonProps>;
8
- export {};
@@ -1,10 +0,0 @@
1
- import React from 'react';
2
- interface DesktopMediaViewProps {
3
- imageSrc: string;
4
- showPrevious: () => void;
5
- showNext: () => void;
6
- showNextIcon: boolean;
7
- showPrevIcon: boolean;
8
- }
9
- export declare const DesktopMediaView: React.FC<React.PropsWithChildren<DesktopMediaViewProps>>;
10
- export {};
@@ -1,3 +0,0 @@
1
- import React from 'react';
2
- import { SwipeableProps } from 'react-swipeable';
3
- export declare const Swipeable: React.FC<React.PropsWithChildren<SwipeableProps>>;
@@ -1,10 +0,0 @@
1
- import React from 'react';
2
- interface MobileMediaViewProps {
3
- imageSrc: string;
4
- showPrevious: () => void;
5
- showNext: () => void;
6
- showNextIcon: boolean;
7
- showPrevIcon: boolean;
8
- }
9
- export declare const MobileMediaView: React.FC<React.PropsWithChildren<MobileMediaViewProps>>;
10
- export {};
@@ -1,3 +0,0 @@
1
- export interface OnMainSearchTriggerEvent {
2
- searchText: string;
3
- }