@equinor/echo-components 0.5.8-rc2 → 0.5.11
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/LICENSE +21 -21
- package/README.md +62 -62
- package/dist/components/buttonWithPopover/ButtonWithPopover.d.ts +21 -21
- package/dist/components/contextMenu/ContextMenu.d.ts +35 -35
- package/dist/components/contextMenuPopover/DataInfoButton.d.ts +19 -19
- package/dist/components/contextMenuPopover/DataInfoPopover.d.ts +18 -18
- package/dist/components/datePicker/PopupHeader.d.ts +19 -19
- package/dist/components/datePicker/ReactDatePicker.d.ts +19 -19
- package/dist/components/dialogGenerator/DialogGenerator.d.ts +26 -26
- package/dist/components/dropdown/Dropdown.d.ts +37 -37
- package/dist/components/echoBottomBar/EchoBottomBar.d.ts +7 -7
- package/dist/components/echoCard/Body.d.ts +7 -7
- package/dist/components/echoCard/DateSection.d.ts +8 -8
- package/dist/components/echoCard/EchoCard.d.ts +7 -7
- package/dist/components/echoCard/LinkSection.d.ts +8 -8
- package/dist/components/echoCard/Title.d.ts +13 -13
- package/dist/components/echoCard/index.d.ts +14 -14
- package/dist/components/echoHeader/EchoHeader.d.ts +20 -20
- package/dist/components/floatingActionButton/FloatingActionButton.d.ts +29 -29
- package/dist/components/floatingSearchBar/FloatingSearchBar.d.ts +31 -0
- package/dist/components/index.d.ts +20 -17
- package/dist/components/inlineTagIconLink/InlineTagIconLink.d.ts +12 -12
- package/dist/components/listItem/ListItem.d.ts +50 -50
- package/dist/components/listItem/index.d.ts +1 -1
- package/dist/components/listRow/ListRow.d.ts +29 -29
- package/dist/components/rightPanel/PanelContextWrapper.d.ts +19 -19
- package/dist/components/rightPanel/index.d.ts +5 -5
- package/dist/components/rightPanel/menuButton/MenuButton.d.ts +26 -26
- package/dist/components/rightPanel/panel/Panel.d.ts +18 -18
- package/dist/components/rightPanel/panelContent/PanelContent.d.ts +21 -21
- package/dist/components/rightPanel/panelWrapper/PanelWrapper.d.ts +21 -21
- package/dist/components/rightPanel/usePanelContext.d.ts +8 -8
- package/dist/components/sidebarButton/SidebarButton.d.ts +61 -41
- package/dist/components/sidesheet/enums.d.ts +5 -5
- package/dist/components/sidesheet/index.d.ts +11 -11
- package/dist/components/sidesheet/sheet/Sheet.d.ts +19 -19
- package/dist/components/sidesheet/sheet/index.d.ts +1 -1
- package/dist/components/sidesheet/sheet/utils.d.ts +2 -2
- package/dist/components/sidesheet/sheetTopArea/SheetTopArea.d.ts +16 -16
- package/dist/components/sidesheet/sheetTopArea/index.d.ts +1 -1
- package/dist/components/splitView/SplitView.d.ts +10 -0
- package/dist/components/splitView/index.d.ts +8 -0
- package/dist/components/splitView/left/SplitViewLeft.d.ts +7 -0
- package/dist/components/tagContextMenu/TagContextMenu.d.ts +30 -30
- package/dist/components/timePicker/TimePicker.d.ts +12 -12
- package/dist/elements/draggableItemsWrapper/DraggableItemsWrapper.d.ts +18 -18
- package/dist/elements/icon/Icon.d.ts +20 -20
- package/dist/elements/index.d.ts +8 -8
- package/dist/elements/radioButtonGroup/RadioButtonGroup.d.ts +20 -20
- package/dist/elements/roundIconButton/RoundIconButton.d.ts +13 -13
- package/dist/elements/sliderField/SliderField.d.ts +25 -25
- package/dist/elements/tagIcon/TagIcon.d.ts +16 -16
- package/dist/elements/tagIcon/TagIconShadow.d.ts +13 -13
- package/dist/elements/textIconButton/TextIconButton.d.ts +19 -19
- package/dist/helpers/classnames.d.ts +5 -5
- package/dist/helpers/getIcon.d.ts +2 -2
- package/dist/helpers/index.d.ts +3 -3
- package/dist/helpers/tagCategoryIcon.d.ts +38 -38
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/useEventListener.d.ts +3 -0
- package/dist/hooks/useKeyboardNavigation.d.ts +21 -0
- package/dist/icons/echoAssets/external.d.ts +5 -3
- package/dist/icons/echoAssets/index.d.ts +3 -2
- package/dist/icons/echoAssets/notifications.d.ts +9 -0
- package/dist/icons/echoAssets/workOrders.d.ts +11 -0
- package/dist/icons/index.d.ts +3 -1
- package/dist/index.d.ts +9 -8
- package/dist/index.js +1789 -580
- package/dist/index.js.map +1 -1
- package/dist/setupTests.d.ts +1 -1
- package/dist/structure/iconList/IconList.d.ts +32 -32
- package/dist/structure/iconList/createListRow.d.ts +14 -14
- package/dist/structure/index.d.ts +3 -3
- package/dist/structure/linkCard/LinkCard.d.ts +26 -26
- package/dist/structure/optionsList/OptionsList.d.ts +24 -24
- package/dist/theme/index.d.ts +1 -1
- package/dist/theme/themeConst.d.ts +65 -65
- package/dist/types/actionButton.d.ts +6 -6
- package/dist/types/dataInformation.d.ts +8 -8
- package/dist/types/draggableItem.d.ts +5 -5
- package/dist/types/expandableRowProps.d.ts +6 -6
- package/dist/types/iconItem.d.ts +4 -4
- package/dist/types/iconListItem.d.ts +6 -6
- package/dist/types/index.d.ts +10 -10
- package/dist/types/linkCardItem.d.ts +5 -5
- package/dist/types/menuItem.d.ts +9 -9
- package/dist/types/optionsItem.d.ts +6 -6
- package/dist/types/radioButtonItem.d.ts +4 -4
- package/package.json +126 -126
- package/dist/icons/echoAssets/data.d.ts +0 -3
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2020 Equinor
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2020 Equinor
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,63 +1,63 @@
|
|
|
1
|
-

|
|
2
|
-
|
|
3
|
-
# Echo-Components
|
|
4
|
-
|
|
5
|
-
Package for creating echo related components.
|
|
6
|
-
|
|
7
|
-
[](https://npmjs.org/package/@equinor/echo-components)
|
|
8
|
-
[](https://npmjs.org/package/@equinor/echo-components)
|
|
9
|
-
[](https://github.com/equinor/fusion/blob/master/package.json)
|
|
10
|
-
[](https://npmjs.org/package/@equinor/echo-components)
|
|
11
|
-
|
|
12
|
-
/bundlephobia/:format/:packageName
|
|
13
|
-
|
|
14
|
-
- [Echo-Components](#echo-components)
|
|
15
|
-
- [Install](#install)
|
|
16
|
-
- [NPM](#npm)
|
|
17
|
-
- [Development](#development)
|
|
18
|
-
- [Run](#run)
|
|
19
|
-
- [Test](#test)
|
|
20
|
-
- [Storybook](#storybook)
|
|
21
|
-
|
|
22
|
-
# Install
|
|
23
|
-
|
|
24
|
-
### NPM
|
|
25
|
-
|
|
26
|
-
```sh-session
|
|
27
|
-
npm install @equinor/echo-components --save
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
# Development
|
|
31
|
-
|
|
32
|
-
## Run
|
|
33
|
-
|
|
34
|
-
For development we have provided a test playground to be able to test components. This can be run by using.
|
|
35
|
-
|
|
36
|
-
```sh-session
|
|
37
|
-
npm start
|
|
38
|
-
```
|
|
39
|
-
|
|
40
|
-
## Test
|
|
41
|
-
|
|
42
|
-
Echo components is set upt to run Jest test suite. To run tests use.
|
|
43
|
-
|
|
44
|
-
```sh-session
|
|
45
|
-
npm run test
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
For abetter overview, run tests with test coverage.
|
|
49
|
-
|
|
50
|
-
```sh-session
|
|
51
|
-
npm run test-coverage
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
# Storybook
|
|
55
|
-
|
|
56
|
-
You can see and test the components using storybook.
|
|
57
|
-
Run:
|
|
58
|
-
|
|
59
|
-
```sh-session
|
|
60
|
-
npm run storybook
|
|
61
|
-
```
|
|
62
|
-
|
|
1
|
+

|
|
2
|
+
|
|
3
|
+
# Echo-Components
|
|
4
|
+
|
|
5
|
+
Package for creating echo related components.
|
|
6
|
+
|
|
7
|
+
[](https://npmjs.org/package/@equinor/echo-components)
|
|
8
|
+
[](https://npmjs.org/package/@equinor/echo-components)
|
|
9
|
+
[](https://github.com/equinor/fusion/blob/master/package.json)
|
|
10
|
+
[](https://npmjs.org/package/@equinor/echo-components)
|
|
11
|
+
|
|
12
|
+
/bundlephobia/:format/:packageName
|
|
13
|
+
|
|
14
|
+
- [Echo-Components](#echo-components)
|
|
15
|
+
- [Install](#install)
|
|
16
|
+
- [NPM](#npm)
|
|
17
|
+
- [Development](#development)
|
|
18
|
+
- [Run](#run)
|
|
19
|
+
- [Test](#test)
|
|
20
|
+
- [Storybook](#storybook)
|
|
21
|
+
|
|
22
|
+
# Install
|
|
23
|
+
|
|
24
|
+
### NPM
|
|
25
|
+
|
|
26
|
+
```sh-session
|
|
27
|
+
npm install @equinor/echo-components --save
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
# Development
|
|
31
|
+
|
|
32
|
+
## Run
|
|
33
|
+
|
|
34
|
+
For development we have provided a test playground to be able to test components. This can be run by using.
|
|
35
|
+
|
|
36
|
+
```sh-session
|
|
37
|
+
npm start
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Test
|
|
41
|
+
|
|
42
|
+
Echo components is set upt to run Jest test suite. To run tests use.
|
|
43
|
+
|
|
44
|
+
```sh-session
|
|
45
|
+
npm run test
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
For abetter overview, run tests with test coverage.
|
|
49
|
+
|
|
50
|
+
```sh-session
|
|
51
|
+
npm run test-coverage
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
# Storybook
|
|
55
|
+
|
|
56
|
+
You can see and test the components using storybook.
|
|
57
|
+
Run:
|
|
58
|
+
|
|
59
|
+
```sh-session
|
|
60
|
+
npm run storybook
|
|
61
|
+
```
|
|
62
|
+
|
|
63
63
|
Online storybook: https://equinor.github.io/EchoComponents/
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { DataInformation } from '../../types/dataInformation';
|
|
3
|
-
export interface ButtonWithPopoverProps {
|
|
4
|
-
onShowMoreClicked: () => void;
|
|
5
|
-
fetchedData: DataInformation[];
|
|
6
|
-
isLoading: boolean;
|
|
7
|
-
expanded: boolean;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Component that renders a round button, that opens a popover upon being clicked
|
|
11
|
-
*
|
|
12
|
-
* @param {ButtonWithPopoverProps} {
|
|
13
|
-
* onShowMoreClicked: method called upon button clicked
|
|
14
|
-
* fetchedData: array of DataInformation that popover should be displayed when button is clicked.
|
|
15
|
-
* Meant to be the return value of the fetchDataToShow method
|
|
16
|
-
* isLoading: flag to show loading state if data fetch takes some time
|
|
17
|
-
* expanded: flag to determine if popover should be expanded or not
|
|
18
|
-
* @return {*} {JSX.Element} Round button with belonging popover to display data information buttons
|
|
19
|
-
*/
|
|
20
|
-
export declare const ButtonWithPopover: React.FC<ButtonWithPopoverProps>;
|
|
21
|
-
export default ButtonWithPopover;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { DataInformation } from '../../types/dataInformation';
|
|
3
|
+
export interface ButtonWithPopoverProps {
|
|
4
|
+
onShowMoreClicked: () => void;
|
|
5
|
+
fetchedData: DataInformation[];
|
|
6
|
+
isLoading: boolean;
|
|
7
|
+
expanded: boolean;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Component that renders a round button, that opens a popover upon being clicked
|
|
11
|
+
*
|
|
12
|
+
* @param {ButtonWithPopoverProps} {
|
|
13
|
+
* onShowMoreClicked: method called upon button clicked
|
|
14
|
+
* fetchedData: array of DataInformation that popover should be displayed when button is clicked.
|
|
15
|
+
* Meant to be the return value of the fetchDataToShow method
|
|
16
|
+
* isLoading: flag to show loading state if data fetch takes some time
|
|
17
|
+
* expanded: flag to determine if popover should be expanded or not
|
|
18
|
+
* @return {*} {JSX.Element} Round button with belonging popover to display data information buttons
|
|
19
|
+
*/
|
|
20
|
+
export declare const ButtonWithPopover: React.FC<ButtonWithPopoverProps>;
|
|
21
|
+
export default ButtonWithPopover;
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import React, { CSSProperties } from 'react';
|
|
2
|
-
interface ContextMenuProps {
|
|
3
|
-
icon: JSX.Element;
|
|
4
|
-
legendColor: string;
|
|
5
|
-
expanded: boolean;
|
|
6
|
-
setExpanded: (expanded: boolean) => void;
|
|
7
|
-
tagNo: string;
|
|
8
|
-
description: string;
|
|
9
|
-
positionStyle: CSSProperties;
|
|
10
|
-
openTagInformation: () => void;
|
|
11
|
-
selectedClassName?: string;
|
|
12
|
-
selected: boolean;
|
|
13
|
-
children?: React.ReactNode;
|
|
14
|
-
}
|
|
15
|
-
/**
|
|
16
|
-
* Component that renders full context menu functionality, meant for displaying tag context menu.
|
|
17
|
-
* With the ability to provide more information button and related popover that should be wrapped with the context menu
|
|
18
|
-
*
|
|
19
|
-
* @param {ContextMenuProps} {
|
|
20
|
-
* icon: icon to be displayed
|
|
21
|
-
* expanded: flag to determine if context menu should be expanded or not
|
|
22
|
-
* legendColor: color used for the tag icon
|
|
23
|
-
* setExpanded: method to update expanded flag
|
|
24
|
-
* tagNo: The tag number to display
|
|
25
|
-
* description: The tag description to display
|
|
26
|
-
* positionStyle: The position styling element used to position the context menu
|
|
27
|
-
* openTagInformation: Method that will be called when expanded context menu is clicked
|
|
28
|
-
* selected: Flag to handle if there are multiple context menu's on a page, and a selected style should be applied
|
|
29
|
-
* selectedClassName: styling used to handle multiple tag visible on the page at the same time, class will be added to tagIcon when context menu is not expanded
|
|
30
|
-
* children: Related elements to display, e.g. more information button
|
|
31
|
-
* }
|
|
32
|
-
* @return {*} {JSX.Element} Context menu with relevant children wrapped
|
|
33
|
-
*/
|
|
34
|
-
export declare const ContextMenu: React.FC<ContextMenuProps>;
|
|
35
|
-
export default ContextMenu;
|
|
1
|
+
import React, { CSSProperties } from 'react';
|
|
2
|
+
interface ContextMenuProps {
|
|
3
|
+
icon: JSX.Element;
|
|
4
|
+
legendColor: string;
|
|
5
|
+
expanded: boolean;
|
|
6
|
+
setExpanded: (expanded: boolean) => void;
|
|
7
|
+
tagNo: string;
|
|
8
|
+
description: string;
|
|
9
|
+
positionStyle: CSSProperties;
|
|
10
|
+
openTagInformation: () => void;
|
|
11
|
+
selectedClassName?: string;
|
|
12
|
+
selected: boolean;
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Component that renders full context menu functionality, meant for displaying tag context menu.
|
|
17
|
+
* With the ability to provide more information button and related popover that should be wrapped with the context menu
|
|
18
|
+
*
|
|
19
|
+
* @param {ContextMenuProps} {
|
|
20
|
+
* icon: icon to be displayed
|
|
21
|
+
* expanded: flag to determine if context menu should be expanded or not
|
|
22
|
+
* legendColor: color used for the tag icon
|
|
23
|
+
* setExpanded: method to update expanded flag
|
|
24
|
+
* tagNo: The tag number to display
|
|
25
|
+
* description: The tag description to display
|
|
26
|
+
* positionStyle: The position styling element used to position the context menu
|
|
27
|
+
* openTagInformation: Method that will be called when expanded context menu is clicked
|
|
28
|
+
* selected: Flag to handle if there are multiple context menu's on a page, and a selected style should be applied
|
|
29
|
+
* selectedClassName: styling used to handle multiple tag visible on the page at the same time, class will be added to tagIcon when context menu is not expanded
|
|
30
|
+
* children: Related elements to display, e.g. more information button
|
|
31
|
+
* }
|
|
32
|
+
* @return {*} {JSX.Element} Context menu with relevant children wrapped
|
|
33
|
+
*/
|
|
34
|
+
export declare const ContextMenu: React.FC<ContextMenuProps>;
|
|
35
|
+
export default ContextMenu;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { DataInformation } from '../../types/dataInformation';
|
|
3
|
-
export interface DataInfoButtonProps {
|
|
4
|
-
data: DataInformation;
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* Component that renders a data information button with a badge to indicate the number of items under that scoped type
|
|
8
|
-
*
|
|
9
|
-
* @param {DataInfoButtonProps} { data } Contains data information related to how the button should be rendered
|
|
10
|
-
* numberOfItems: If number is 1 or less no badge will be displayed on the button. If number is over 99,
|
|
11
|
-
* then the text 99+ will be displayed. Otherwise the provided number will be displayed
|
|
12
|
-
* label: The name of the data type, will be displayed on the button
|
|
13
|
-
* ariaLabel: The aria label set on the button, if empty the label will be used
|
|
14
|
-
* onTagInfoClicked: The method to be called when button is pressed
|
|
15
|
-
* itemButtonClassName: Used to style button if default styling is not wanted. class name might need higher precedence for overriding existing styling e.g. "div.itemButtonClassName { background-color: blue !important}"
|
|
16
|
-
* @return {*} {JSX.Element} Data information button with or without a badge based on the provided data object
|
|
17
|
-
*/
|
|
18
|
-
export declare const DataInfoButton: React.FC<DataInfoButtonProps>;
|
|
19
|
-
export default DataInfoButton;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { DataInformation } from '../../types/dataInformation';
|
|
3
|
+
export interface DataInfoButtonProps {
|
|
4
|
+
data: DataInformation;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Component that renders a data information button with a badge to indicate the number of items under that scoped type
|
|
8
|
+
*
|
|
9
|
+
* @param {DataInfoButtonProps} { data } Contains data information related to how the button should be rendered
|
|
10
|
+
* numberOfItems: If number is 1 or less no badge will be displayed on the button. If number is over 99,
|
|
11
|
+
* then the text 99+ will be displayed. Otherwise the provided number will be displayed
|
|
12
|
+
* label: The name of the data type, will be displayed on the button
|
|
13
|
+
* ariaLabel: The aria label set on the button, if empty the label will be used
|
|
14
|
+
* onTagInfoClicked: The method to be called when button is pressed
|
|
15
|
+
* itemButtonClassName: Used to style button if default styling is not wanted. class name might need higher precedence for overriding existing styling e.g. "div.itemButtonClassName { background-color: blue !important}"
|
|
16
|
+
* @return {*} {JSX.Element} Data information button with or without a badge based on the provided data object
|
|
17
|
+
*/
|
|
18
|
+
export declare const DataInfoButton: React.FC<DataInfoButtonProps>;
|
|
19
|
+
export default DataInfoButton;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { DataInformation } from '../../types/dataInformation';
|
|
3
|
-
export interface DataInfoPopoverProps {
|
|
4
|
-
dataToShow: DataInformation[];
|
|
5
|
-
isLoading: boolean;
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Component that renders a popover with data information buttons
|
|
9
|
-
*
|
|
10
|
-
* @param {DataInfoPopoverProps} {
|
|
11
|
-
* dataToShow: list of DataInformation objects to be displayed.
|
|
12
|
-
* The itemType in these objects are used to group them together in the popover
|
|
13
|
-
* isLoading: loading flag that tells if a dot progress should be displayed if data is being fetched
|
|
14
|
-
* }
|
|
15
|
-
* @return {*} {JSX.Element} Popover with data information buttons based on the provided DataInformation objects
|
|
16
|
-
*/
|
|
17
|
-
declare const DataInfoPopover: React.FC<DataInfoPopoverProps>;
|
|
18
|
-
export default DataInfoPopover;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { DataInformation } from '../../types/dataInformation';
|
|
3
|
+
export interface DataInfoPopoverProps {
|
|
4
|
+
dataToShow: DataInformation[];
|
|
5
|
+
isLoading: boolean;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Component that renders a popover with data information buttons
|
|
9
|
+
*
|
|
10
|
+
* @param {DataInfoPopoverProps} {
|
|
11
|
+
* dataToShow: list of DataInformation objects to be displayed.
|
|
12
|
+
* The itemType in these objects are used to group them together in the popover
|
|
13
|
+
* isLoading: loading flag that tells if a dot progress should be displayed if data is being fetched
|
|
14
|
+
* }
|
|
15
|
+
* @return {*} {JSX.Element} Popover with data information buttons based on the provided DataInformation objects
|
|
16
|
+
*/
|
|
17
|
+
declare const DataInfoPopover: React.FC<DataInfoPopoverProps>;
|
|
18
|
+
export default DataInfoPopover;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface PopupHeaderProps {
|
|
3
|
-
monthDate: Date;
|
|
4
|
-
date: Date;
|
|
5
|
-
changeYear: (year: number) => void;
|
|
6
|
-
changeMonth: (month: number) => void;
|
|
7
|
-
customHeaderCount: number;
|
|
8
|
-
decreaseMonth: VoidFunction;
|
|
9
|
-
increaseMonth: VoidFunction;
|
|
10
|
-
prevMonthButtonDisabled: boolean;
|
|
11
|
-
nextMonthButtonDisabled: boolean;
|
|
12
|
-
decreaseYear: VoidFunction;
|
|
13
|
-
increaseYear: VoidFunction;
|
|
14
|
-
prevYearButtonDisabled: boolean;
|
|
15
|
-
nextYearButtonDisabled: boolean;
|
|
16
|
-
changeDate?: (date: Date) => void;
|
|
17
|
-
}
|
|
18
|
-
declare const PopupHeader: React.FC<PopupHeaderProps>;
|
|
19
|
-
export default PopupHeader;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface PopupHeaderProps {
|
|
3
|
+
monthDate: Date;
|
|
4
|
+
date: Date;
|
|
5
|
+
changeYear: (year: number) => void;
|
|
6
|
+
changeMonth: (month: number) => void;
|
|
7
|
+
customHeaderCount: number;
|
|
8
|
+
decreaseMonth: VoidFunction;
|
|
9
|
+
increaseMonth: VoidFunction;
|
|
10
|
+
prevMonthButtonDisabled: boolean;
|
|
11
|
+
nextMonthButtonDisabled: boolean;
|
|
12
|
+
decreaseYear: VoidFunction;
|
|
13
|
+
increaseYear: VoidFunction;
|
|
14
|
+
prevYearButtonDisabled: boolean;
|
|
15
|
+
nextYearButtonDisabled: boolean;
|
|
16
|
+
changeDate?: (date: Date) => void;
|
|
17
|
+
}
|
|
18
|
+
declare const PopupHeader: React.FC<PopupHeaderProps>;
|
|
19
|
+
export default PopupHeader;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import 'react-datepicker/dist/react-datepicker.css';
|
|
3
|
-
import './reactDatePicker.css';
|
|
4
|
-
declare type PopperPlacement = 'auto-start' | 'auto' | 'auto-end' | 'top-start' | 'top' | 'top-end' | 'right-start' | 'right' | 'right-end' | 'bottom-end' | 'bottom' | 'bottom-start' | 'left-end' | 'left' | 'left-start';
|
|
5
|
-
export interface DatePickerProps {
|
|
6
|
-
id: string;
|
|
7
|
-
value: Date | undefined | null;
|
|
8
|
-
label: string;
|
|
9
|
-
onChanged(date: Date | null): void;
|
|
10
|
-
disableFuture?: boolean;
|
|
11
|
-
disableBeforeDate?: Date;
|
|
12
|
-
className?: string;
|
|
13
|
-
popperPlacement?: PopperPlacement;
|
|
14
|
-
showTimeSelect?: boolean;
|
|
15
|
-
maxDate?: Date;
|
|
16
|
-
minDate?: Date;
|
|
17
|
-
}
|
|
18
|
-
export declare const ReactDatePicker: React.FC<DatePickerProps>;
|
|
19
|
-
export default ReactDatePicker;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import 'react-datepicker/dist/react-datepicker.css';
|
|
3
|
+
import './reactDatePicker.css';
|
|
4
|
+
declare type PopperPlacement = 'auto-start' | 'auto' | 'auto-end' | 'top-start' | 'top' | 'top-end' | 'right-start' | 'right' | 'right-end' | 'bottom-end' | 'bottom' | 'bottom-start' | 'left-end' | 'left' | 'left-start';
|
|
5
|
+
export interface DatePickerProps {
|
|
6
|
+
id: string;
|
|
7
|
+
value: Date | undefined | null;
|
|
8
|
+
label: string;
|
|
9
|
+
onChanged(date: Date | null): void;
|
|
10
|
+
disableFuture?: boolean;
|
|
11
|
+
disableBeforeDate?: Date;
|
|
12
|
+
className?: string;
|
|
13
|
+
popperPlacement?: PopperPlacement;
|
|
14
|
+
showTimeSelect?: boolean;
|
|
15
|
+
maxDate?: Date;
|
|
16
|
+
minDate?: Date;
|
|
17
|
+
}
|
|
18
|
+
export declare const ReactDatePicker: React.FC<DatePickerProps>;
|
|
19
|
+
export default ReactDatePicker;
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import React, { CSSProperties } from 'react';
|
|
2
|
-
import { ActionButton } from '../../types/actionButton';
|
|
3
|
-
export interface DialogGeneratorProps {
|
|
4
|
-
dialogStyle?: CSSProperties;
|
|
5
|
-
children: React.ReactNode;
|
|
6
|
-
title: string;
|
|
7
|
-
actionButtons: ActionButton[];
|
|
8
|
-
open: boolean;
|
|
9
|
-
isDismissable?: boolean;
|
|
10
|
-
onClose?: () => void;
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
* Component that renders a dialog box based on input properties
|
|
14
|
-
*
|
|
15
|
-
* @param {DialogGeneratorProps} {
|
|
16
|
-
* dialogStyle: style property to override existing styling on the dialog wrapper
|
|
17
|
-
* title: the title of the dialog
|
|
18
|
-
* children: The main content of the dialog
|
|
19
|
-
* actionButtons: the buttons to show in the dialog
|
|
20
|
-
* open: if the dialog should be open
|
|
21
|
-
* isDismissable: if the modal is closable by clicking aside or by hitting ESC key
|
|
22
|
-
* onClose: callback to be called when the dialog is closed
|
|
23
|
-
* }
|
|
24
|
-
* @return {*} {JSX.Element} Dialog component
|
|
25
|
-
*/
|
|
26
|
-
export declare const DialogGenerator: React.FC<DialogGeneratorProps>;
|
|
1
|
+
import React, { CSSProperties } from 'react';
|
|
2
|
+
import { ActionButton } from '../../types/actionButton';
|
|
3
|
+
export interface DialogGeneratorProps {
|
|
4
|
+
dialogStyle?: CSSProperties;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
title: string;
|
|
7
|
+
actionButtons: ActionButton[];
|
|
8
|
+
open: boolean;
|
|
9
|
+
isDismissable?: boolean;
|
|
10
|
+
onClose?: () => void;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Component that renders a dialog box based on input properties
|
|
14
|
+
*
|
|
15
|
+
* @param {DialogGeneratorProps} {
|
|
16
|
+
* dialogStyle: style property to override existing styling on the dialog wrapper
|
|
17
|
+
* title: the title of the dialog
|
|
18
|
+
* children: The main content of the dialog
|
|
19
|
+
* actionButtons: the buttons to show in the dialog
|
|
20
|
+
* open: if the dialog should be open
|
|
21
|
+
* isDismissable: if the modal is closable by clicking aside or by hitting ESC key
|
|
22
|
+
* onClose: callback to be called when the dialog is closed
|
|
23
|
+
* }
|
|
24
|
+
* @return {*} {JSX.Element} Dialog component
|
|
25
|
+
*/
|
|
26
|
+
export declare const DialogGenerator: React.FC<DialogGeneratorProps>;
|
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
interface DropdownItemProps {
|
|
3
|
-
selected: string;
|
|
4
|
-
setSelected: (selected: string) => void;
|
|
5
|
-
data: any[];
|
|
6
|
-
openDownWards: boolean;
|
|
7
|
-
placeholder: string;
|
|
8
|
-
filterFunc?: (data: any[], filter: string) => any[];
|
|
9
|
-
isDisabled?: boolean;
|
|
10
|
-
disabledText?: string;
|
|
11
|
-
maxCharacterCount?: number;
|
|
12
|
-
variant?: 'compact' | 'default';
|
|
13
|
-
showSearch: boolean;
|
|
14
|
-
position?: 'relative' | 'absolute';
|
|
15
|
-
triggerOpen?: (value: boolean) => void;
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* Component that renders a dropdown menu, e.g., for a plant selector.
|
|
19
|
-
* Additional possibility to make the list searchable by adding a search field.
|
|
20
|
-
* @param {DropdownItemProps} {
|
|
21
|
-
* selected: The item that is currently selected from the list.
|
|
22
|
-
* data: The list of data items to be displayed in the dropdown.
|
|
23
|
-
* placeholder: Placeholder text to be displayed when no item is selected.
|
|
24
|
-
* openDownWards: Flag which decides if the menu is opened downwards or upwards.
|
|
25
|
-
* filterFunc: Function which filters the list of data based on the value of the search field.
|
|
26
|
-
* setSelected: Function for setting the selected item.
|
|
27
|
-
* isDisabled: Flag which disables the dropdown.
|
|
28
|
-
* disabledText: The title text that displays when the dropdown is disabled.
|
|
29
|
-
* variant: Decides which style the dropdown should have. Either default or compact.
|
|
30
|
-
* showSearch: Flag which decides whether we should include the search field or not.
|
|
31
|
-
* position: Determines if the dropdown position should be relative or absolute.
|
|
32
|
-
* triggerOpen: Callback to trigger when the dropdown is opened.
|
|
33
|
-
* }
|
|
34
|
-
* @return {*} {JSX.Element} The dropdown component.
|
|
35
|
-
*/
|
|
36
|
-
export declare const Dropdown: React.FC<DropdownItemProps>;
|
|
37
|
-
export default Dropdown;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface DropdownItemProps {
|
|
3
|
+
selected: string;
|
|
4
|
+
setSelected: (selected: string) => void;
|
|
5
|
+
data: any[];
|
|
6
|
+
openDownWards: boolean;
|
|
7
|
+
placeholder: string;
|
|
8
|
+
filterFunc?: (data: any[], filter: string) => any[];
|
|
9
|
+
isDisabled?: boolean;
|
|
10
|
+
disabledText?: string;
|
|
11
|
+
maxCharacterCount?: number;
|
|
12
|
+
variant?: 'compact' | 'default';
|
|
13
|
+
showSearch: boolean;
|
|
14
|
+
position?: 'relative' | 'absolute';
|
|
15
|
+
triggerOpen?: (value: boolean) => void;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Component that renders a dropdown menu, e.g., for a plant selector.
|
|
19
|
+
* Additional possibility to make the list searchable by adding a search field.
|
|
20
|
+
* @param {DropdownItemProps} {
|
|
21
|
+
* selected: The item that is currently selected from the list.
|
|
22
|
+
* data: The list of data items to be displayed in the dropdown.
|
|
23
|
+
* placeholder: Placeholder text to be displayed when no item is selected.
|
|
24
|
+
* openDownWards: Flag which decides if the menu is opened downwards or upwards.
|
|
25
|
+
* filterFunc: Function which filters the list of data based on the value of the search field.
|
|
26
|
+
* setSelected: Function for setting the selected item.
|
|
27
|
+
* isDisabled: Flag which disables the dropdown.
|
|
28
|
+
* disabledText: The title text that displays when the dropdown is disabled.
|
|
29
|
+
* variant: Decides which style the dropdown should have. Either default or compact.
|
|
30
|
+
* showSearch: Flag which decides whether we should include the search field or not.
|
|
31
|
+
* position: Determines if the dropdown position should be relative or absolute.
|
|
32
|
+
* triggerOpen: Callback to trigger when the dropdown is opened.
|
|
33
|
+
* }
|
|
34
|
+
* @return {*} {JSX.Element} The dropdown component.
|
|
35
|
+
*/
|
|
36
|
+
export declare const Dropdown: React.FC<DropdownItemProps>;
|
|
37
|
+
export default Dropdown;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface EchoBottomBarProps {
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
style?: React.CSSProperties;
|
|
5
|
-
}
|
|
6
|
-
export declare const EchoBottomBar: React.FC<EchoBottomBarProps>;
|
|
7
|
-
export default EchoBottomBar;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface EchoBottomBarProps {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
style?: React.CSSProperties;
|
|
5
|
+
}
|
|
6
|
+
export declare const EchoBottomBar: React.FC<EchoBottomBarProps>;
|
|
7
|
+
export default EchoBottomBar;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export declare type BodyProps = {
|
|
3
|
-
children?: React.ReactNode;
|
|
4
|
-
className?: string;
|
|
5
|
-
bodyText?: string;
|
|
6
|
-
};
|
|
7
|
-
export declare const Body: ({ bodyText, children, className }: Partial<BodyProps>) => JSX.Element;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare type BodyProps = {
|
|
3
|
+
children?: React.ReactNode;
|
|
4
|
+
className?: string;
|
|
5
|
+
bodyText?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const Body: ({ bodyText, children, className }: Partial<BodyProps>) => JSX.Element;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export declare type DateSectionProps = {
|
|
3
|
-
date?: Date | null;
|
|
4
|
-
dateSectionText?: string;
|
|
5
|
-
children?: React.ReactNode;
|
|
6
|
-
className?: string;
|
|
7
|
-
};
|
|
8
|
-
export declare const DateSection: ({ dateSectionText, date, children, className }: Partial<DateSectionProps>) => JSX.Element;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare type DateSectionProps = {
|
|
3
|
+
date?: Date | null;
|
|
4
|
+
dateSectionText?: string;
|
|
5
|
+
children?: React.ReactNode;
|
|
6
|
+
className?: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const DateSection: ({ dateSectionText, date, children, className }: Partial<DateSectionProps>) => JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface EchoCardProps {
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
className?: string;
|
|
5
|
-
style?: React.CSSProperties;
|
|
6
|
-
}
|
|
7
|
-
export declare const EchoCard: React.FC<EchoCardProps>;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface EchoCardProps {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
className?: string;
|
|
5
|
+
style?: React.CSSProperties;
|
|
6
|
+
}
|
|
7
|
+
export declare const EchoCard: React.FC<EchoCardProps>;
|