react-science 0.28.1 → 0.30.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/lib-esm/app/hooks/file-loading.d.ts +2 -1
- package/lib-esm/app/hooks/file-loading.d.ts.map +1 -1
- package/lib-esm/app/hooks/file-loading.js.map +1 -1
- package/lib-esm/app/panels/SignalProcessingPanel.d.ts.map +1 -1
- package/lib-esm/app/panels/SignalProcessingPanel.js +3 -3
- package/lib-esm/app/panels/SignalProcessingPanel.js.map +1 -1
- package/lib-esm/components/button/Button.d.ts +8 -14
- package/lib-esm/components/button/Button.d.ts.map +1 -1
- package/lib-esm/components/button/Button.js +7 -31
- package/lib-esm/components/button/Button.js.map +1 -1
- package/lib-esm/components/drop-zone/DropZone.d.ts +6 -2
- package/lib-esm/components/drop-zone/DropZone.d.ts.map +1 -1
- package/lib-esm/components/drop-zone/DropZone.js +9 -15
- package/lib-esm/components/drop-zone/DropZone.js.map +1 -1
- package/lib-esm/components/forms/index.d.ts +0 -5
- package/lib-esm/components/forms/index.d.ts.map +1 -1
- package/lib-esm/components/forms/index.js +0 -5
- package/lib-esm/components/forms/index.js.map +1 -1
- package/lib-esm/components/forms/radio-group/RadioGroup.d.ts +1 -0
- package/lib-esm/components/forms/radio-group/RadioGroup.d.ts.map +1 -1
- package/lib-esm/components/forms/radio-group/RadioGroup.js +2 -2
- package/lib-esm/components/forms/radio-group/RadioGroup.js.map +1 -1
- package/lib-esm/components/forms/styles.d.ts +0 -22
- package/lib-esm/components/forms/styles.d.ts.map +1 -1
- package/lib-esm/components/forms/styles.js +0 -72
- package/lib-esm/components/forms/styles.js.map +1 -1
- package/lib-esm/components/header/PanelHeader.d.ts.map +1 -1
- package/lib-esm/components/header/PanelHeader.js +1 -2
- package/lib-esm/components/header/PanelHeader.js.map +1 -1
- package/lib-esm/components/index.d.ts +0 -2
- package/lib-esm/components/index.d.ts.map +1 -1
- package/lib-esm/components/index.js +0 -2
- package/lib-esm/components/index.js.map +1 -1
- package/lib-esm/components/info-panel/InfoPanel.d.ts.map +1 -1
- package/lib-esm/components/info-panel/InfoPanel.js +5 -4
- package/lib-esm/components/info-panel/InfoPanel.js.map +1 -1
- package/lib-esm/components/modal/ConfirmModal.d.ts.map +1 -1
- package/lib-esm/components/modal/ConfirmModal.js +1 -7
- package/lib-esm/components/modal/ConfirmModal.js.map +1 -1
- package/lib-esm/components/modal/Modal.d.ts.map +1 -1
- package/lib-esm/components/modal/Modal.js +2 -2
- package/lib-esm/components/modal/Modal.js.map +1 -1
- package/lib-esm/components/toolbar/PanelPreferencesToolbar.d.ts.map +1 -1
- package/lib-esm/components/toolbar/PanelPreferencesToolbar.js +1 -2
- package/lib-esm/components/toolbar/PanelPreferencesToolbar.js.map +1 -1
- package/lib-esm/components/toolbar/Toolbar.d.ts.map +1 -1
- package/lib-esm/components/toolbar/Toolbar.js +16 -12
- package/lib-esm/components/toolbar/Toolbar.js.map +1 -1
- package/package.json +25 -23
- package/src/app/hooks/file-loading.ts +4 -2
- package/src/app/panels/SignalProcessingPanel.tsx +3 -6
- package/src/components/button/Button.tsx +29 -59
- package/src/components/drop-zone/DropZone.tsx +42 -25
- package/src/components/forms/index.ts +0 -5
- package/src/components/forms/radio-group/RadioGroup.tsx +3 -0
- package/src/components/forms/styles.ts +0 -92
- package/src/components/header/PanelHeader.tsx +1 -8
- package/src/components/index.ts +0 -2
- package/src/components/info-panel/InfoPanel.tsx +6 -3
- package/src/components/modal/ConfirmModal.tsx +2 -16
- package/src/components/modal/Modal.tsx +10 -2
- package/src/components/toolbar/PanelPreferencesToolbar.tsx +2 -15
- package/src/components/toolbar/Toolbar.tsx +25 -29
- package/lib-esm/components/dropdown-menu/DropdownMenu.d.ts +0 -28
- package/lib-esm/components/dropdown-menu/DropdownMenu.d.ts.map +0 -1
- package/lib-esm/components/dropdown-menu/DropdownMenu.js +0 -41
- package/lib-esm/components/dropdown-menu/DropdownMenu.js.map +0 -1
- package/lib-esm/components/dropdown-menu/MenuItems.d.ts +0 -19
- package/lib-esm/components/dropdown-menu/MenuItems.d.ts.map +0 -1
- package/lib-esm/components/dropdown-menu/MenuItems.js +0 -77
- package/lib-esm/components/dropdown-menu/MenuItems.js.map +0 -1
- package/lib-esm/components/dropdown-menu/index.d.ts +0 -3
- package/lib-esm/components/dropdown-menu/index.d.ts.map +0 -1
- package/lib-esm/components/dropdown-menu/index.js +0 -2
- package/lib-esm/components/dropdown-menu/index.js.map +0 -1
- package/lib-esm/components/dropdown-menu/useContextMenuPlacement.d.ts +0 -18
- package/lib-esm/components/dropdown-menu/useContextMenuPlacement.d.ts.map +0 -1
- package/lib-esm/components/dropdown-menu/useContextMenuPlacement.js +0 -49
- package/lib-esm/components/dropdown-menu/useContextMenuPlacement.js.map +0 -1
- package/lib-esm/components/forms/Checkbox.d.ts +0 -11
- package/lib-esm/components/forms/Checkbox.d.ts.map +0 -1
- package/lib-esm/components/forms/Checkbox.js +0 -35
- package/lib-esm/components/forms/Checkbox.js.map +0 -1
- package/lib-esm/components/forms/Input.d.ts +0 -19
- package/lib-esm/components/forms/Input.d.ts.map +0 -1
- package/lib-esm/components/forms/Input.js +0 -60
- package/lib-esm/components/forms/Input.js.map +0 -1
- package/lib-esm/components/forms/Select.d.ts +0 -21
- package/lib-esm/components/forms/Select.d.ts.map +0 -1
- package/lib-esm/components/forms/Select.js +0 -90
- package/lib-esm/components/forms/Select.js.map +0 -1
- package/lib-esm/components/forms/TextArea.d.ts +0 -8
- package/lib-esm/components/forms/TextArea.d.ts.map +0 -1
- package/lib-esm/components/forms/TextArea.js +0 -19
- package/lib-esm/components/forms/TextArea.js.map +0 -1
- package/lib-esm/components/forms/context/FieldsContext.d.ts +0 -16
- package/lib-esm/components/forms/context/FieldsContext.d.ts.map +0 -1
- package/lib-esm/components/forms/context/FieldsContext.js +0 -47
- package/lib-esm/components/forms/context/FieldsContext.js.map +0 -1
- package/lib-esm/components/forms/context/index.d.ts +0 -2
- package/lib-esm/components/forms/context/index.d.ts.map +0 -1
- package/lib-esm/components/forms/context/index.js +0 -2
- package/lib-esm/components/forms/context/index.js.map +0 -1
- package/lib-esm/components/modal/ModalCloseButton.d.ts +0 -4
- package/lib-esm/components/modal/ModalCloseButton.d.ts.map +0 -1
- package/lib-esm/components/modal/ModalCloseButton.js +0 -11
- package/lib-esm/components/modal/ModalCloseButton.js.map +0 -1
- package/lib-esm/components/spinner/FullSpinner.d.ts +0 -7
- package/lib-esm/components/spinner/FullSpinner.d.ts.map +0 -1
- package/lib-esm/components/spinner/FullSpinner.js +0 -24
- package/lib-esm/components/spinner/FullSpinner.js.map +0 -1
- package/lib-esm/components/spinner/index.d.ts +0 -2
- package/lib-esm/components/spinner/index.d.ts.map +0 -1
- package/lib-esm/components/spinner/index.js +0 -2
- package/lib-esm/components/spinner/index.js.map +0 -1
- package/src/components/dropdown-menu/DropdownMenu.tsx +0 -160
- package/src/components/dropdown-menu/MenuItems.tsx +0 -146
- package/src/components/dropdown-menu/index.ts +0 -2
- package/src/components/dropdown-menu/useContextMenuPlacement.ts +0 -76
- package/src/components/forms/Checkbox.tsx +0 -77
- package/src/components/forms/Input.tsx +0 -144
- package/src/components/forms/Select.tsx +0 -197
- package/src/components/forms/TextArea.tsx +0 -45
- package/src/components/forms/context/FieldsContext.tsx +0 -82
- package/src/components/forms/context/index.ts +0 -1
- package/src/components/modal/ModalCloseButton.tsx +0 -21
- package/src/components/spinner/FullSpinner.tsx +0 -57
- package/src/components/spinner/index.ts +0 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import { UseQueryResult } from '@tanstack/react-query';
|
|
1
2
|
import { FileCollection } from 'filelist-utils';
|
|
2
3
|
import { AppDispatch } from '../../app-data/index';
|
|
3
4
|
type LoadFn = (files: File[] | FileCollection, dispatch: AppDispatch) => Promise<void>;
|
|
4
|
-
export declare function useLoadFileCollectionFromHash(onLoad: LoadFn):
|
|
5
|
+
export declare function useLoadFileCollectionFromHash(onLoad: LoadFn): UseQueryResult<true | null>;
|
|
5
6
|
export declare function useDropFiles(onLoad: LoadFn): (files: File[]) => void;
|
|
6
7
|
export {};
|
|
7
8
|
//# sourceMappingURL=file-loading.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-loading.d.ts","sourceRoot":"","sources":["../../../src/app/hooks/file-loading.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"file-loading.d.ts","sourceRoot":"","sources":["../../../src/app/hooks/file-loading.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAY,MAAM,uBAAuB,CAAC;AACjE,OAAO,EAAE,cAAc,EAA+B,MAAM,gBAAgB,CAAC;AAG7E,OAAO,EAAE,WAAW,EAAkB,MAAM,sBAAsB,CAAC;AAGnE,KAAK,MAAM,GAAG,CACZ,KAAK,EAAE,IAAI,EAAE,GAAG,cAAc,EAC9B,QAAQ,EAAE,WAAW,KAClB,OAAO,CAAC,IAAI,CAAC,CAAC;AAEnB,wBAAgB,6BAA6B,CAC3C,MAAM,EAAE,MAAM,GACb,cAAc,CAAC,IAAI,GAAG,IAAI,CAAC,CAsB7B;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,MAAM,WAG/B,IAAI,EAAE,UAMjB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-loading.js","sourceRoot":"","sources":["../../../src/app/hooks/file-loading.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"file-loading.js","sourceRoot":"","sources":["../../../src/app/hooks/file-loading.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,EAAkB,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AAC7E,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAEpC,OAAO,EAAe,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AA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,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAKzD,MAAM,WAAW,MAAM,CAAC,WAAW,GAAG,MAAM,GAAG,MAAM;IACnD,IAAI,EAAE,YAAY,CAAC,MAAM,CAAC,CAAC;IAC3B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;CACvC;AACD,MAAM,WAAW,0BAA0B;IACzC,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,QAAQ,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;CACvC;AAyBD,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,0BAA0B,
|
|
1
|
+
{"version":3,"file":"SignalProcessingPanel.d.ts","sourceRoot":"","sources":["../../../src/app/panels/SignalProcessingPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAKzD,MAAM,WAAW,MAAM,CAAC,WAAW,GAAG,MAAM,GAAG,MAAM;IACnD,IAAI,EAAE,YAAY,CAAC,MAAM,CAAC,CAAC;IAC3B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;CACvC;AACD,MAAM,WAAW,0BAA0B;IACzC,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,QAAQ,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;CACvC;AAyBD,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,0BAA0B,2CAoGtE"}
|
|
@@ -18,11 +18,11 @@ const defaultFilters = filterXY.anyOf.map(({ properties }) => {
|
|
|
18
18
|
});
|
|
19
19
|
export function SignalProcessingPanel(props) {
|
|
20
20
|
const { filters = [], onChange } = props;
|
|
21
|
-
return (_jsxs("div", { children: [_jsxs(Table, { border: false, children: [_jsxs(Table.Header, { children: [_jsx(ValueRenderers.Title, { value: " " }), _jsx(ValueRenderers.Title, { value: "Name" }), _jsx(ValueRenderers.Title, { value: "Options" })] }), filters.map(({ name, options }, i) => (_jsxs(Table.Row, { border: true, children: [_jsx(ValueRenderers.Component, { children: _jsxs("div", { style: { display: 'flex', gap: '3px' }, children: [_jsx(Button, { style: { width: '15px' },
|
|
21
|
+
return (_jsxs("div", { children: [_jsxs(Table, { border: false, children: [_jsxs(Table.Header, { children: [_jsx(ValueRenderers.Title, { value: " " }), _jsx(ValueRenderers.Title, { value: "Name" }), _jsx(ValueRenderers.Title, { value: "Options" })] }), filters.map(({ name, options }, i) => (_jsxs(Table.Row, { border: true, children: [_jsx(ValueRenderers.Component, { children: _jsxs("div", { style: { display: 'flex', gap: '3px' }, children: [_jsx(Button, { style: { width: '15px' }, intent: "success", onClick: () => {
|
|
22
22
|
const newFilters = [...filters];
|
|
23
23
|
newFilters.splice(i + 1, 0, getDefaultFilter(defaultFilters[0]));
|
|
24
24
|
onChange?.(newFilters);
|
|
25
|
-
}, children: "+" }), _jsx(Button, { style: { width: '15px' },
|
|
25
|
+
}, children: "+" }), _jsx(Button, { style: { width: '15px' }, intent: "danger", onClick: () => {
|
|
26
26
|
onChange?.(filters.filter((_, j) => j !== i));
|
|
27
27
|
}, children: "-" })] }) }), _jsx(ValueRenderers.Component, { children: _jsx("select", { onChange: ({ target }) => {
|
|
28
28
|
const value = Number(target.value);
|
|
@@ -44,7 +44,7 @@ export function SignalProcessingPanel(props) {
|
|
|
44
44
|
const newFilters = [...filters];
|
|
45
45
|
newFilters[i] = filter;
|
|
46
46
|
onChange?.(newFilters);
|
|
47
|
-
})) }))] }, name)))] }), filters.length === 0 && (_jsx(Button, { style: { width: '15px', margin: '5px 20px' },
|
|
47
|
+
})) }))] }, name)))] }), filters.length === 0 && (_jsx(Button, { style: { width: '15px', margin: '5px 20px' }, intent: "success", onClick: () => {
|
|
48
48
|
const newFilters = [getDefaultFilter(defaultFilters[0])];
|
|
49
49
|
onChange?.(newFilters);
|
|
50
50
|
}, children: "+" }))] }));
|
|
@@ -1 +1 @@
|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AAE,YAAG,WAAW,GAAS,KAlCrB,GAAG,CAmCpC,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -1,16 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
color?: Colorhover;
|
|
10
|
-
onClick?: () => void;
|
|
11
|
-
style?: CSSProperties;
|
|
12
|
-
disabled?: boolean;
|
|
13
|
-
}
|
|
14
|
-
export declare function Button(props: ButtonProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
1
|
+
import { ButtonProps as BlueprintButtonProps, AnchorButtonProps as BlueprintAnchorButtonProps, TooltipProps } from '@blueprintjs/core';
|
|
2
|
+
type BlueprintProps = {
|
|
3
|
+
[key in keyof BlueprintButtonProps & keyof BlueprintAnchorButtonProps]?: BlueprintButtonProps[key] & BlueprintAnchorButtonProps[key];
|
|
4
|
+
};
|
|
5
|
+
export type ButtonProps = BlueprintProps & {
|
|
6
|
+
tooltipProps?: Omit<TooltipProps, 'children'>;
|
|
7
|
+
};
|
|
8
|
+
export declare function Button(props: ButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
15
9
|
export {};
|
|
16
10
|
//# sourceMappingURL=Button.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/components/button/Button.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/components/button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGL,WAAW,IAAI,oBAAoB,EACnC,iBAAiB,IAAI,0BAA0B,EAE/C,YAAY,EACb,MAAM,mBAAmB,CAAC;AAE3B,KAAK,cAAc,GAAG;KACnB,GAAG,IAAI,MAAM,oBAAoB,GAChC,MAAM,0BAA0B,CAAC,CAAC,EAAE,oBAAoB,CAAC,GAAG,CAAC,GAC7D,0BAA0B,CAAC,GAAG,CAAC;CAClC,CAAC;AACF,MAAM,MAAM,WAAW,GAAG,cAAc,GAAG;IACzC,YAAY,CAAC,EAAE,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;CAC/C,CAAC;AAEF,wBAAgB,MAAM,CAAC,KAAK,EAAE,WAAW,2CAiBxC"}
|
|
@@ -1,34 +1,10 @@
|
|
|
1
|
-
import { jsx as _jsx } from "
|
|
2
|
-
|
|
3
|
-
import { css } from '@emotion/react';
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Button as BlueprintButton, AnchorButton as BlueprintAnchorButton, Tooltip, } from '@blueprintjs/core';
|
|
4
3
|
export function Button(props) {
|
|
5
|
-
const {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
return (_jsx(
|
|
10
|
-
display: 'flex',
|
|
11
|
-
alignItems: 'center',
|
|
12
|
-
paddingLeft: 10,
|
|
13
|
-
paddingRight: 10,
|
|
14
|
-
paddingTop: 6,
|
|
15
|
-
paddingBottom: 6,
|
|
16
|
-
borderWidth: 1,
|
|
17
|
-
borderColor: 'transparent',
|
|
18
|
-
fontSize: '1.125em',
|
|
19
|
-
borderRadius: 6,
|
|
20
|
-
color: color.basic,
|
|
21
|
-
minWidth: 30,
|
|
22
|
-
justifyContent: 'center',
|
|
23
|
-
backgroundColor: backgroundColor.basic,
|
|
24
|
-
':hover:enabled': {
|
|
25
|
-
color: color.hover,
|
|
26
|
-
backgroundColor: backgroundColor.hover,
|
|
27
|
-
},
|
|
28
|
-
':disabled': {
|
|
29
|
-
opacity: 0.5,
|
|
30
|
-
cursor: 'not-allowed',
|
|
31
|
-
},
|
|
32
|
-
}), type: "button", disabled: disabled, children: children }));
|
|
4
|
+
const { tooltipProps, children, ...buttonProps } = props;
|
|
5
|
+
const InnerButton = buttonProps.disabled
|
|
6
|
+
? BlueprintAnchorButton
|
|
7
|
+
: BlueprintButton;
|
|
8
|
+
return (_jsx(Tooltip, { fill: tooltipProps?.fill || buttonProps.fill, ...tooltipProps, renderTarget: (targetProps) => (_jsx(InnerButton, { ...targetProps, ...buttonProps, children: children })) }));
|
|
33
9
|
}
|
|
34
10
|
//# sourceMappingURL=Button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.js","sourceRoot":"","sources":["../../../src/components/button/Button.tsx"],"names":[],"mappings":";AAAA,
|
|
1
|
+
{"version":3,"file":"Button.js","sourceRoot":"","sources":["../../../src/components/button/Button.tsx"],"names":[],"mappings":";AAAA,OAAO,EACL,MAAM,IAAI,eAAe,EACzB,YAAY,IAAI,qBAAqB,EAGrC,OAAO,GAER,MAAM,mBAAmB,CAAC;AAW3B,MAAM,UAAU,MAAM,CAAC,KAAkB;IACvC,MAAM,EAAE,YAAY,EAAE,QAAQ,EAAE,GAAG,WAAW,EAAE,GAAG,KAAK,CAAC;IAEzD,MAAM,WAAW,GAAG,WAAW,CAAC,QAAQ;QACtC,CAAC,CAAC,qBAAqB;QACvB,CAAC,CAAC,eAAe,CAAC;IACpB,OAAO,CACL,KAAC,OAAO,IACN,IAAI,EAAE,YAAY,EAAE,IAAI,IAAI,WAAW,CAAC,IAAI,KACxC,YAAY,EAChB,YAAY,EAAE,CAAC,WAAW,EAAE,EAAE,CAAC,CAC7B,KAAC,WAAW,OAAK,WAAW,KAAM,WAAW,YAC1C,QAAQ,GACG,CACf,GACD,CACH,CAAC;AACJ,CAAC"}
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import type { IconName } from '@blueprintjs/icons';
|
|
2
3
|
import { FileError, FileRejection } from 'react-dropzone';
|
|
3
4
|
export interface DropZoneProps {
|
|
4
|
-
color?: string;
|
|
5
5
|
borderColor?: string;
|
|
6
6
|
onDrop?: <T extends File>(acceptedFiles: T[], rejectedFiles?: FileRejection[]) => void;
|
|
7
7
|
fileValidator?: <T extends File>(file: T) => FileError | FileError[] | null;
|
|
8
|
-
|
|
8
|
+
emptyIcon?: IconName;
|
|
9
|
+
emptyTitle?: string;
|
|
10
|
+
emptyDescription?: string;
|
|
11
|
+
emptyButtonText?: string;
|
|
12
|
+
emptyButtonIcon?: IconName;
|
|
9
13
|
}
|
|
10
14
|
export declare function DropZone(props: DropZoneProps): import("react/jsx-runtime").JSX.Element;
|
|
11
15
|
export interface DropZoneContainerProps extends DropZoneProps {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropZone.d.ts","sourceRoot":"","sources":["../../../src/components/drop-zone/DropZone.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"DropZone.d.ts","sourceRoot":"","sources":["../../../src/components/drop-zone/DropZone.tsx"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAInD,OAAO,EAAE,SAAS,EAAE,aAAa,EAAe,MAAM,gBAAgB,CAAC;AAEvE,MAAM,WAAW,aAAa;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,CAAC,CAAC,SAAS,IAAI,EACtB,aAAa,EAAE,CAAC,EAAE,EAClB,aAAa,CAAC,EAAE,aAAa,EAAE,KAC5B,IAAI,CAAC;IACV,aAAa,CAAC,EAAE,CAAC,CAAC,SAAS,IAAI,EAAE,IAAI,EAAE,CAAC,KAAK,SAAS,GAAG,SAAS,EAAE,GAAG,IAAI,CAAC;IAC5E,SAAS,CAAC,EAAE,QAAQ,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,eAAe,CAAC,EAAE,QAAQ,CAAC;CAC5B;AA0CD,wBAAgB,QAAQ,CAAC,KAAK,EAAE,aAAa,2CAE5C;AAED,MAAM,WAAW,sBAAuB,SAAQ,aAAa;IAC3D,QAAQ,EAAE,GAAG,CAAC,OAAO,GAAG,IAAI,CAAC;CAC9B;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,sBAAsB,2CAE9D"}
|
|
@@ -1,38 +1,33 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { NonIdealState, Button, Colors } from '@blueprintjs/core';
|
|
2
3
|
import styled from '@emotion/styled';
|
|
4
|
+
import { rgba } from 'polished';
|
|
3
5
|
import { useCallback, useMemo } from 'react';
|
|
4
6
|
import { useDropzone } from 'react-dropzone';
|
|
5
|
-
import { FaCloudUploadAlt } from 'react-icons/fa';
|
|
6
7
|
const DropzoneRoot = styled.div `
|
|
7
8
|
position: relative;
|
|
8
9
|
height: 100%;
|
|
9
10
|
width: 100%;
|
|
10
11
|
`;
|
|
11
12
|
const DropzoneDragActive = styled.div `
|
|
12
|
-
font-size: 1.5em;
|
|
13
|
-
font-weight: 600;
|
|
14
13
|
position: absolute;
|
|
15
14
|
top: 0;
|
|
16
15
|
bottom: 0;
|
|
17
16
|
left: 0;
|
|
18
17
|
right: 0;
|
|
19
|
-
|
|
20
|
-
background-color: white;
|
|
18
|
+
background-color: rgb(255, 255, 255, 0.7);
|
|
21
19
|
border: 5px dashed;
|
|
22
20
|
display: flex;
|
|
23
21
|
flex-direction: column;
|
|
24
22
|
align-items: center;
|
|
25
23
|
justify-content: center;
|
|
26
24
|
|
|
27
|
-
border-color: ${({ borderColor }) => borderColor};
|
|
28
|
-
color: ${({ color }) => color};
|
|
25
|
+
border-color: ${({ borderColor }) => borderColor ? rgba(borderColor, 0.7) : ''};
|
|
29
26
|
`;
|
|
30
27
|
const DropzoneEmpty = styled.div `
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
align-items: center;
|
|
35
|
-
justify-content: center;
|
|
28
|
+
:hover .dropzone-button {
|
|
29
|
+
background-color: ${rgba(Colors.BLUE3, 0.15)};
|
|
30
|
+
}
|
|
36
31
|
width: 100%;
|
|
37
32
|
height: 100%;
|
|
38
33
|
padding: 1em;
|
|
@@ -40,7 +35,6 @@ const DropzoneEmpty = styled.div `
|
|
|
40
35
|
cursor: pointer;
|
|
41
36
|
|
|
42
37
|
border-color: ${({ borderColor }) => borderColor};
|
|
43
|
-
color: ${({ color }) => color};
|
|
44
38
|
`;
|
|
45
39
|
export function DropZone(props) {
|
|
46
40
|
return _jsx(DropZoneContent, { ...props });
|
|
@@ -49,7 +43,7 @@ export function DropZoneContainer(props) {
|
|
|
49
43
|
return _jsx(DropZoneContent, { ...props });
|
|
50
44
|
}
|
|
51
45
|
function DropZoneContent(props) {
|
|
52
|
-
const {
|
|
46
|
+
const { borderColor = Colors.GRAY3, children = null, onDrop, onClick, fileValidator, emptyIcon = 'import', emptyTitle = 'No data loaded', emptyDescription = 'You can load data by drag-and-dropping files here', emptyButtonText = 'Select files', emptyButtonIcon = 'plus', } = props;
|
|
53
47
|
const hasChildren = children !== null;
|
|
54
48
|
const handleOnDrop = useCallback((acceptedFiles, rejectedFiles) => {
|
|
55
49
|
onDrop?.(acceptedFiles, rejectedFiles);
|
|
@@ -64,6 +58,6 @@ function DropZoneContent(props) {
|
|
|
64
58
|
return { onClick };
|
|
65
59
|
}
|
|
66
60
|
}, [onClick]);
|
|
67
|
-
return (_jsxs(DropzoneRoot, { ...getRootProps(getPropsOptions), children: [children, isDragActive ? (
|
|
61
|
+
return (_jsxs(DropzoneRoot, { ...getRootProps(getPropsOptions), children: [children, isDragActive ? (_jsx(DropzoneDragActive, { borderColor: borderColor, children: _jsx(NonIdealState, { icon: "cloud-upload", title: "Drop the files here" }) })) : !hasChildren ? (_jsx(DropzoneEmpty, { borderColor: borderColor, children: _jsx(NonIdealState, { icon: emptyIcon, title: emptyTitle, description: emptyDescription, action: _jsx(Button, { className: "dropzone-button", outlined: true, text: emptyButtonText, icon: emptyButtonIcon, intent: "primary" }) }) })) : null, _jsx("input", { ...getInputProps() })] }));
|
|
68
62
|
}
|
|
69
63
|
//# sourceMappingURL=DropZone.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropZone.js","sourceRoot":"","sources":["../../../src/components/drop-zone/DropZone.tsx"],"names":[],"mappings":";AAAA,OAAO,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"DropZone.js","sourceRoot":"","sources":["../../../src/components/drop-zone/DropZone.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAElE,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAChC,OAAO,EAAoC,WAAW,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAC/E,OAAO,EAA4B,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAgBvE,MAAM,YAAY,GAAG,MAAM,CAAC,GAAG,CAAA;;;;CAI9B,CAAC;AAMF,MAAM,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAAoB;;;;;;;;;;;;;kBAavC,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAClC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE;CAC5C,CAAC;AAEF,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAAoB;;wBAE5B,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,IAAI,CAAC;;;;;;;;kBAQ9B,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,WAAW;CACjD,CAAC;AAEF,MAAM,UAAU,QAAQ,CAAC,KAAoB;IAC3C,OAAO,KAAC,eAAe,OAAK,KAAK,GAAI,CAAC;AACxC,CAAC;AAMD,MAAM,UAAU,iBAAiB,CAAC,KAA6B;IAC7D,OAAO,KAAC,eAAe,OAAK,KAAK,GAAI,CAAC;AACxC,CAAC;AAED,SAAS,eAAe,CACtB,KAQC;IAED,MAAM,EACJ,WAAW,GAAG,MAAM,CAAC,KAAK,EAC1B,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B,QAAQ,QACR,IAAI,EAAE,eAAe,EACrB,IAAI,EAAE,eAAe,EACrB,MAAM,EAAC,SAAS,GAChB,GAEJ,GACY,CACjB,CAAC,CAAC,CAAC,IAAI,EACR,mBAAW,aAAa,EAAE,GAAI,IACjB,CAChB,CAAC;AACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/forms/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/forms/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/forms/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/forms/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC"}
|
|
@@ -13,6 +13,7 @@ export interface RadioGroupProps {
|
|
|
13
13
|
name?: string;
|
|
14
14
|
disabled?: boolean;
|
|
15
15
|
variant?: InputVariant;
|
|
16
|
+
id?: string;
|
|
16
17
|
}
|
|
17
18
|
export declare function RadioGroup(props: RadioGroupProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
18
19
|
//# sourceMappingURL=RadioGroup.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RadioGroup.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/radio-group/RadioGroup.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElC,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAKzC,MAAM,WAAW,WAAW;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,SAAS,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AACD,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,EAAE,WAAW,CAAC;IACvB,IAAI,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC5B,OAAO,CAAC,EAAE,WAAW,EAAE,CAAC;IACxB,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,WAAW,KAAK,IAAI,CAAC;IACzC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"RadioGroup.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/radio-group/RadioGroup.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElC,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAKzC,MAAM,WAAW,WAAW;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,SAAS,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AACD,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,EAAE,WAAW,CAAC;IACvB,IAAI,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC5B,OAAO,CAAC,EAAE,WAAW,EAAE,CAAC;IACxB,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,WAAW,KAAK,IAAI,CAAC;IACzC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,EAAE,CAAC,EAAE,MAAM,CAAC;CACb;AAkBD,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,oDA2ChD"}
|
|
@@ -21,8 +21,8 @@ const rootStyles = {
|
|
|
21
21
|
}),
|
|
22
22
|
};
|
|
23
23
|
export function RadioGroup(props) {
|
|
24
|
-
const { selected, type = 'classic', disabled: groupDisabled = false, options = [], onSelect, name = '', variant = 'default', } = props;
|
|
25
|
-
return (_jsx(RadioGroupRadix.Root, { css: [
|
|
24
|
+
const { id, selected, type = 'classic', disabled: groupDisabled = false, options = [], onSelect, name = '', variant = 'default', } = props;
|
|
25
|
+
return (_jsx(RadioGroupRadix.Root, { id: id, css: [
|
|
26
26
|
rootStyles.basic,
|
|
27
27
|
type === 'classic' ? null : rootStyles.button(variant),
|
|
28
28
|
], style: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RadioGroup.js","sourceRoot":"","sources":["../../../../src/components/forms/radio-group/RadioGroup.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,KAAK,eAAe,MAAM,6BAA6B,CAAC;AAK/D,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"RadioGroup.js","sourceRoot":"","sources":["../../../../src/components/forms/radio-group/RadioGroup.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,KAAK,eAAe,MAAM,6BAA6B,CAAC;AAK/D,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAiBtD,MAAM,UAAU,GAAG;IACjB,KAAK,EAAE,GAAG,CAAC;QACT,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,KAAK;QACpB,KAAK,EAAE,aAAa;KACrB,CAAC;IACF,MAAM,EAAE,CAAC,OAAqB,EAAE,EAAE,CAChC,GAAG,CAAC;QACF,gDAAgD,EAAE;YAChD,YAAY,EAAE,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,aAAa;SACpE;QACD,8CAA8C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F,KAAC,eAAe,OAAK,UAAU,GAAI,CACpC,CAAC;QACJ,CAAC,CAAC,GACmB,CACxB,CAAC;AACJ,CAAC"}
|
|
@@ -1,26 +1,4 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
export type InputVariant = 'default' | 'small';
|
|
3
|
-
interface StyledProps {
|
|
4
|
-
variant: InputVariant;
|
|
5
|
-
hasLeading?: boolean;
|
|
6
|
-
hasTrailing?: boolean;
|
|
7
|
-
}
|
|
8
2
|
export declare const enabledColor = "#1677ff";
|
|
9
3
|
export declare const disabledColor = "#b8b8b8";
|
|
10
|
-
export declare const LabelStyled: import("@emotion/styled").StyledComponent<{
|
|
11
|
-
theme?: import("@emotion/react").Theme | undefined;
|
|
12
|
-
as?: import("react").ElementType<any> | undefined;
|
|
13
|
-
} & StyledProps, import("react").DetailedHTMLProps<import("react").LabelHTMLAttributes<HTMLLabelElement>, HTMLLabelElement>, {}>;
|
|
14
|
-
export declare const GroupStyled: import("@emotion/styled").StyledComponent<{
|
|
15
|
-
theme?: import("@emotion/react").Theme | undefined;
|
|
16
|
-
as?: import("react").ElementType<any> | undefined;
|
|
17
|
-
} & {
|
|
18
|
-
hasError: boolean;
|
|
19
|
-
hasValid: boolean;
|
|
20
|
-
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
21
|
-
export declare const InputContainer: import("@emotion/styled").StyledComponent<{
|
|
22
|
-
theme?: import("@emotion/react").Theme | undefined;
|
|
23
|
-
as?: import("react").ElementType<any> | undefined;
|
|
24
|
-
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
25
|
-
export {};
|
|
26
4
|
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/forms/styles.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/forms/styles.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,CAAC;AAE/C,eAAO,MAAM,YAAY,YAAY,CAAC;AACtC,eAAO,MAAM,aAAa,YAAY,CAAC"}
|
|
@@ -1,75 +1,3 @@
|
|
|
1
|
-
import styled from '@emotion/styled';
|
|
2
1
|
export const enabledColor = '#1677ff';
|
|
3
2
|
export const disabledColor = '#b8b8b8';
|
|
4
|
-
export const LabelStyled = styled.label `
|
|
5
|
-
padding: ${(props) => props.variant === 'default'
|
|
6
|
-
? props.hasTrailing
|
|
7
|
-
? '2px 9px 4px 9px'
|
|
8
|
-
: '2px 9px'
|
|
9
|
-
: props.hasTrailing
|
|
10
|
-
? '1px 7px 1px 7px'
|
|
11
|
-
: '1px 7px'};
|
|
12
|
-
|
|
13
|
-
font-size: ${(props) => (props.variant === 'small' ? '1em' : '1.125em')};
|
|
14
|
-
line-height: '17px';
|
|
15
|
-
|
|
16
|
-
background-color: white;
|
|
17
|
-
border-width: 1px;
|
|
18
|
-
align-items: center;
|
|
19
|
-
flex-direction: row;
|
|
20
|
-
flex: 1 1 0%;
|
|
21
|
-
display: flex;
|
|
22
|
-
position: relative;
|
|
23
|
-
|
|
24
|
-
border-top-right-radius: ${(props) => props.hasLeading && !props.hasTrailing && '0.375rem'};
|
|
25
|
-
|
|
26
|
-
border-bottom-right-radius: ${(props) => props.hasLeading && !props.hasTrailing && '0.375rem'};
|
|
27
|
-
|
|
28
|
-
border-top-left-radius: ${(props) => props.hasTrailing && !props.hasLeading && '0.375rem'};
|
|
29
|
-
|
|
30
|
-
border-bottom-left-radius: ${(props) => props.hasTrailing && !props.hasLeading && '0.375rem'};
|
|
31
|
-
|
|
32
|
-
border-radius: ${(props) => !props.hasLeading && !props.hasTrailing && '0.375rem'};
|
|
33
|
-
|
|
34
|
-
border-color: var(--custom-border-color);
|
|
35
|
-
`;
|
|
36
|
-
function getStyleColor(hasError, hasValid) {
|
|
37
|
-
if (hasError) {
|
|
38
|
-
return {
|
|
39
|
-
default: '#ffa39e',
|
|
40
|
-
hover: '#f95d55',
|
|
41
|
-
};
|
|
42
|
-
}
|
|
43
|
-
if (hasValid) {
|
|
44
|
-
return {
|
|
45
|
-
default: '#6adc24',
|
|
46
|
-
hover: '#62cb21',
|
|
47
|
-
};
|
|
48
|
-
}
|
|
49
|
-
return {
|
|
50
|
-
default: 'rgb(217, 217, 217)',
|
|
51
|
-
hover: '#4096ff',
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
export const GroupStyled = styled.div `
|
|
55
|
-
display: flex;
|
|
56
|
-
border-radius: 0.375rem;
|
|
57
|
-
margin-top: 0.25rem;
|
|
58
|
-
|
|
59
|
-
.addon {
|
|
60
|
-
color: ${({ hasError }) => hasError && '#f95d55'};
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
--custom-border-color: ${({ hasError, hasValid }) => getStyleColor(hasError, hasValid).default};
|
|
64
|
-
|
|
65
|
-
:hover,
|
|
66
|
-
:focus-within {
|
|
67
|
-
--custom-border-color: ${({ hasError, hasValid }) => getStyleColor(hasError, hasValid).hover};
|
|
68
|
-
}
|
|
69
|
-
`;
|
|
70
|
-
export const InputContainer = styled.div `
|
|
71
|
-
display: flex;
|
|
72
|
-
flex-direction: column;
|
|
73
|
-
gap: 2px;
|
|
74
|
-
`;
|
|
75
3
|
//# sourceMappingURL=styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.js","sourceRoot":"","sources":["../../../src/components/forms/styles.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"styles.js","sourceRoot":"","sources":["../../../src/components/forms/styles.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,YAAY,GAAG,SAAS,CAAC;AACtC,MAAM,CAAC,MAAM,aAAa,GAAG,SAAS,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanelHeader.d.ts","sourceRoot":"","sources":["../../../src/components/header/PanelHeader.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAqB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"PanelHeader.d.ts","sourceRoot":"","sources":["../../../src/components/header/PanelHeader.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAqB,MAAM,OAAO,CAAC;AA6BrD,UAAU,gBAAgB;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB;AAED,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,OAAO,EACP,QAAQ,EACR,eAAe,GAChB,EAAE,gBAAgB,oDAwBlB"}
|
|
@@ -2,7 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "@emotion/react/jsx-runtime";
|
|
|
2
2
|
/** @jsxImportSource @emotion/react */
|
|
3
3
|
import { css } from '@emotion/react';
|
|
4
4
|
import { useEffect, useRef } from 'react';
|
|
5
|
-
import { FaCog } from 'react-icons/fa';
|
|
6
5
|
import { Button } from '../button/Button';
|
|
7
6
|
const styles = {
|
|
8
7
|
container: css({
|
|
@@ -43,6 +42,6 @@ export function PanelHeader({ total, current, children, onClickSettings, }) {
|
|
|
43
42
|
labelRef.current.textContent = `[ ${total} ]`;
|
|
44
43
|
}
|
|
45
44
|
}, [current, total]);
|
|
46
|
-
return (_jsxs("div", { css: styles.container, children: [_jsx("div", { css: styles.leftContainer, children: children }), _jsx("p", { ref: labelRef, css: styles.counterLabel }), onClickSettings && (_jsx(Button, {
|
|
45
|
+
return (_jsxs("div", { css: styles.container, children: [_jsx("div", { css: styles.leftContainer, children: children }), _jsx("p", { ref: labelRef, css: styles.counterLabel }), onClickSettings && (_jsx(Button, { color: "black", minimal: true, onClick: onClickSettings, icon: "cog" }))] }));
|
|
47
46
|
}
|
|
48
47
|
//# sourceMappingURL=PanelHeader.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanelHeader.js","sourceRoot":"","sources":["../../../src/components/header/PanelHeader.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,EAAa,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"PanelHeader.js","sourceRoot":"","sources":["../../../src/components/header/PanelHeader.tsx"],"names":[],"mappings":";AAAA,sCAAsC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,EAAa,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAErD,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAE1C,MAAM,MAAM,GAAG;IACb,SAAS,EAAE,GAAG,CAAC;QACb,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,KAAK;QACpB,UAAU,EAAE,QAAQ;QACpB,cAAc,EAAE,eAAe;QAC/B,YAAY,EAAE,iCAAiC;KAChD,CAAC;IACF,aAAa,EAAE,GAAG,CAAC;QACjB,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,KAAK;QACpB,IAAI,EAAE,CAAC;QACP,YAAY,EAAE;YACZ,OAAO,EAAE,OAAO;YAChB,QAAQ,EAAE,MAAM;SACjB;KACF,CAAC;IACF,YAAY,EAAE,GAAG,CAAC;QAChB,MAAM,EAAE,CAAC;QACT,SAAS,EAAE,OAAO;QAClB,UAAU,EAAE,MAAM;QAClB,UAAU,EAAE,QAAQ;KACrB,CAAC;CACH,CAAC;AASF,MAAM,UAAU,WAAW,CAAC,EAC1B,KAAK,EACL,OAAO,EACP,QAAQ,EACR,eAAe,GACE;IACjB,MAAM,QAAQ,GAAG,MAAM,CAAuB,IAAI,CAAC,CAAC;IAEpD,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,CAAC,QAAQ,CAAC,OAAO;YAAE,OAAO;QAE9B,IAAI,OAAO,KAAK,SAAS,IAAI,KAAK,KAAK,SAAS,EAAE;YAChD,QAAQ,CAAC,OAAO,CAAC,WAAW,GAAG,GAAG,OAAO,MAAM,KAAK,EAAE,CAAC;SACxD;aAAM,IAAI,OAAO,KAAK,SAAS,EAAE;YAChC,QAAQ,CAAC,OAAO,CAAC,WAAW,GAAG,KAAK,OAAO,IAAI,CAAC;SACjD;aAAM,IAAI,KAAK,KAAK,SAAS,EAAE;YAC9B,QAAQ,CAAC,OAAO,CAAC,WAAW,GAAG,KAAK,KAAK,IAAI,CAAC;SAC/C;IACH,CAAC,EAAE,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC;IAErB,OAAO,CACL,eAAK,GAAG,EAAE,MAAM,CAAC,SAAS,aACxB,cAAK,GAAG,EAAE,MAAM,CAAC,aAAa,YAAG,QAAQ,GAAO,EAChD,YAAG,GAAG,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,CAAC,YAAY,GAAI,EAC7C,eAAe,IAAI,CAClB,KAAC,MAAM,IAAC,KAAK,EAAC,OAAO,EAAC,OAAO,QAAC,OAAO,EAAE,eAAe,EAAE,IAAI,EAAC,KAAK,GAAG,CACtE,IACG,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -2,7 +2,6 @@ export * from './accordion/index';
|
|
|
2
2
|
export * from './button/index';
|
|
3
3
|
export * from './color-picker/index';
|
|
4
4
|
export * from './drop-zone/index';
|
|
5
|
-
export * from './dropdown-menu/index';
|
|
6
5
|
export * from './forms/index';
|
|
7
6
|
export * from './fullscreen/index';
|
|
8
7
|
export * from './header/index';
|
|
@@ -11,7 +10,6 @@ export * from './info-panel/index';
|
|
|
11
10
|
export * from './layout-manager/index';
|
|
12
11
|
export * from './modal/index';
|
|
13
12
|
export * from './root-layout/index';
|
|
14
|
-
export * from './spinner/index';
|
|
15
13
|
export * from './split-pane/index';
|
|
16
14
|
export * from './table/index';
|
|
17
15
|
export * from './tabs/index';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,OAAO,KAAK,cAAc,MAAM,yBAAyB,CAAC"}
|
|
@@ -2,7 +2,6 @@ export * from './accordion/index';
|
|
|
2
2
|
export * from './button/index';
|
|
3
3
|
export * from './color-picker/index';
|
|
4
4
|
export * from './drop-zone/index';
|
|
5
|
-
export * from './dropdown-menu/index';
|
|
6
5
|
export * from './forms/index';
|
|
7
6
|
export * from './fullscreen/index';
|
|
8
7
|
export * from './header/index';
|
|
@@ -11,7 +10,6 @@ export * from './info-panel/index';
|
|
|
11
10
|
export * from './layout-manager/index';
|
|
12
11
|
export * from './modal/index';
|
|
13
12
|
export * from './root-layout/index';
|
|
14
|
-
export * from './spinner/index';
|
|
15
13
|
export * from './split-pane/index';
|
|
16
14
|
export * from './table/index';
|
|
17
15
|
export * from './tabs/index';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,OAAO,KAAK,cAAc,MAAM,yBAAyB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InfoPanel.d.ts","sourceRoot":"","sources":["../../../src/components/info-panel/InfoPanel.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"InfoPanel.d.ts","sourceRoot":"","sources":["../../../src/components/info-panel/InfoPanel.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,aAAa,EAAY,MAAM,OAAO,CAAC;AAMhD,MAAM,WAAW,aAAa;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,GAAG,CAAC,CAAC;CAChE;AAED,UAAU,cAAc;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,aAAa,EAAE,CAAC;IACvB,UAAU,CAAC,EAAE,aAAa,CAAC;IAC3B,UAAU,CAAC,EAAE,aAAa,CAAC;IAC3B,UAAU,CAAC,EAAE,aAAa,CAAC;CAC5B;AAwBD,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,oDAkF9C"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "@emotion/react/jsx-runtime";
|
|
2
2
|
/** @jsxImportSource @emotion/react */
|
|
3
|
+
import { InputGroup } from '@blueprintjs/core';
|
|
3
4
|
import { css } from '@emotion/react';
|
|
4
5
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment, @typescript-eslint/prefer-ts-expect-error
|
|
5
6
|
// @ts-ignore
|
|
6
7
|
import { Disclosure } from '@headlessui/react';
|
|
7
8
|
import { useState } from 'react';
|
|
8
9
|
import { FaChevronRight } from 'react-icons/fa';
|
|
9
|
-
import {
|
|
10
|
+
import { ValueRenderers } from '../index';
|
|
10
11
|
import { Table } from '../table/Table';
|
|
11
12
|
const style = {
|
|
12
13
|
container: css({
|
|
@@ -57,10 +58,10 @@ export function InfoPanel(props) {
|
|
|
57
58
|
}
|
|
58
59
|
return [...exactMatch, ...startsWith, ...includes, ...valueContains].map(([key, value]) => (_jsxs(Table.Row, { children: [_jsx(ValueRenderers.Text, { value: key }), valueCell(value)] }, key)));
|
|
59
60
|
}
|
|
60
|
-
return (_jsxs("div", { css: style.container, children: [_jsx("div", { style: titleStyle, children: title }), _jsx(
|
|
61
|
+
return (_jsxs("div", { css: style.container, children: [_jsx("div", { style: titleStyle, children: title }), _jsx(InputGroup, { placeholder: "search for a parameter ...", value: search, onChange: ({ target }) => {
|
|
61
62
|
if (target.value !== undefined)
|
|
62
63
|
setSearch(target.value);
|
|
63
|
-
}, style: inputStyle }), data.map(({ description, data }) => {
|
|
64
|
+
}, style: inputStyle, leftIcon: "search", type: "search" }), data.map(({ description, data }) => {
|
|
64
65
|
const content = viewData(data);
|
|
65
66
|
return content.length > 0 ? (_jsx(Disclosure, { defaultOpen: true, children: ({ open }) => (_jsxs(_Fragment, { children: [_jsxs(Disclosure.Button, { css: style.button, children: [_jsx(FaChevronRight, { css: style.chevron(open) }), description] }), _jsx(Disclosure.Panel, { children: _jsxs(Table, { css: style.table, style: tableStyle, children: [_jsxs(Table.Header, { children: [_jsx(ValueRenderers.Title, { value: "Parameter" }), _jsx(ValueRenderers.Title, { value: "Value" })] }), content] }) })] })) }, description)) : null;
|
|
66
67
|
})] }));
|
|
@@ -73,7 +74,7 @@ export function InfoPanel(props) {
|
|
|
73
74
|
function valueCell(value) {
|
|
74
75
|
switch (typeof value) {
|
|
75
76
|
case 'boolean':
|
|
76
|
-
return _jsx(ValueRenderers.
|
|
77
|
+
return _jsx(ValueRenderers.Text, { value: value ? 'Yes' : 'No' });
|
|
77
78
|
case 'number':
|
|
78
79
|
return _jsx(ValueRenderers.Number, { value: value });
|
|
79
80
|
case 'object':
|