@equinor/echo-components 0.7.17 → 0.7.18

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.
@@ -1,9 +1,9 @@
1
1
  import React from 'react';
2
- type RiskLevel = 'low' | 'medium' | 'high';
3
- interface PCMatrixProps {
2
+ export type RiskLevel = 'low' | 'medium' | 'high';
3
+ export interface PCMatrixProps {
4
4
  className?: string;
5
5
  consequence: RiskLevel;
6
6
  probability: RiskLevel;
7
7
  }
8
+ export type RiskTuple = [number, number];
8
9
  export declare const PCMatrix: ({ consequence, probability, className }: PCMatrixProps) => React.JSX.Element;
9
- export {};
@@ -16,6 +16,8 @@ export interface FloatingSearchBarProps {
16
16
  suggestionGroups?: SuggestionGroup[];
17
17
  onSuggestionClick: (suggestion: Suggestion) => void;
18
18
  isLoading: boolean;
19
+ preOpenSuggestionsGroup?: boolean;
20
+ defaultValue?: string;
19
21
  }
20
22
  /**
21
23
  * Floating search bar
@@ -16,6 +16,8 @@ export interface Props extends React.HTMLProps<HTMLFormElement> {
16
16
  suggestionGroups?: SuggestionGroup[];
17
17
  onSuggestionClick: (suggestion: Suggestion) => void;
18
18
  isLoading: boolean;
19
+ preOpenSuggestionsGroup?: boolean;
20
+ defaultValue?: string;
19
21
  }
20
22
  /**
21
23
  * Floating search bar
@@ -7,5 +7,5 @@ interface SideSheetProps extends SheetProps, SheetTopAreaProps {
7
7
  children: React.ReactNode;
8
8
  }
9
9
  declare function SideSheet({ open, side, orientation, floating, children, className, style, ...topBarProps }: SideSheetProps): JSX.Element | null;
10
- export type { SideSheetProps };
11
10
  export { SideSheet, SideSheetOrientation };
11
+ export type { SideSheetProps };
@@ -15,5 +15,5 @@ interface SheetProps extends Style {
15
15
  floating?: boolean;
16
16
  }
17
17
  declare function Sheet({ side, orientation, floating, children, className, style }: SheetProps): React.JSX.Element;
18
- export type { SheetProps };
19
18
  export { Sheet };
19
+ export type { SheetProps };
@@ -1,2 +1,2 @@
1
1
  import { SideSheetOrientation } from '../enums';
2
- export declare function GetSheetContainerClass(side?: 'left' | 'right', orientation?: SideSheetOrientation, floating?: boolean, isMobile?: boolean): string;
2
+ export declare function GetSheetContainerClass(side?: 'left' | 'right', orientation?: SideSheetOrientation, floating?: boolean): string;
@@ -1,16 +1,24 @@
1
1
  import React from 'react';
2
2
  import { SideSheetOrientation } from '../enums';
3
+ type EnabledOrientations = {
4
+ vertical?: boolean;
5
+ horizontal?: boolean;
6
+ fullscreen?: boolean;
7
+ };
3
8
  interface SheetTopAreaProps extends Partial<SheetOrientationActionsProps> {
4
9
  closeSheet?: () => void;
5
10
  previous?: React.ReactNode;
11
+ /** If omitted, all orientation toggles are rendered. */
12
+ enabledOrientations?: EnabledOrientations;
6
13
  }
7
- declare function SheetTopArea({ orientation, onOrientationChange, closeSheet, previous }: SheetTopAreaProps): JSX.Element | null;
14
+ declare function SheetTopArea({ orientation, onOrientationChange, closeSheet, previous, enabledOrientations }: SheetTopAreaProps): JSX.Element | null;
8
15
  interface SheetOrientationActionsProps {
9
16
  orientation: SideSheetOrientation;
17
+ enabledOrientations: EnabledOrientations;
10
18
  /**
11
19
  * Providing this function allows the developer to control sheet orientation.
12
20
  */
13
21
  onOrientationChange: (orientationTarget: SideSheetOrientation) => void;
14
22
  }
15
- export type { SheetTopAreaProps };
16
23
  export { SheetTopArea };
24
+ export type { SheetTopAreaProps };
@@ -0,0 +1,3 @@
1
+ import { IconData } from '@equinor/eds-icons';
2
+ export declare const badge_first: IconData;
3
+ export declare const badge_second: IconData;
@@ -5,3 +5,4 @@ export * from './punches';
5
5
  export * from './workOrders';
6
6
  export * from './misc';
7
7
  export * from './maps';
8
+ export * from './badges';