@devtable/dashboard 6.7.0 → 6.9.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/dist/dashboard.es.js +14928 -5334
- package/dist/dashboard.umd.js +76 -21
- package/dist/definition-editor/minimal-monaco-editor.d.ts +9 -0
- package/dist/definition-editor/sql-snippet-editor/item-editor.d.ts +11 -0
- package/dist/filter/filter-tree-select/editor.d.ts +7 -0
- package/dist/filter/filter-tree-select/expected-structure.d.ts +2 -0
- package/dist/filter/filter-tree-select/render/index.d.ts +12 -0
- package/dist/filter/filter-tree-select/render/query-data-to-tree.d.ts +2 -0
- package/dist/filter/filter-tree-select/render/switcher-icon.d.ts +3 -0
- package/dist/filter/filter-tree-select/render/tree-icon.d.ts +3 -0
- package/dist/filter/filter-tree-select/render/widget.d.ts +14 -0
- package/dist/filter/filter-tree-select/render/widget.styles.d.ts +10 -0
- package/dist/filter/filter-tree-select/types.d.ts +5 -0
- package/dist/model/filters/filter/common.d.ts +1 -0
- package/dist/model/filters/filter/tree-select.d.ts +90 -0
- package/dist/model/sql-snippets/index.d.ts +27 -0
- package/dist/model/sql-snippets/sql-snippet.d.ts +1 -0
- package/dist/model/sql-snippets/types.d.ts +3 -0
- package/dist/style.css +1 -1
- package/package.json +3 -1
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
interface IMinimalMonacoEditor {
|
|
3
|
+
value: string;
|
|
4
|
+
onChange?: (v: string) => void;
|
|
5
|
+
height?: string;
|
|
6
|
+
defaultLanguage?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const MinimalMonacoEditor: ({ value, onChange, height, defaultLanguage, }: IMinimalMonacoEditor) => JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { SQLSnippetModelInstance } from '~/model';
|
|
3
|
+
interface ISQLSnippetItemEditor {
|
|
4
|
+
item: SQLSnippetModelInstance;
|
|
5
|
+
remove: () => void;
|
|
6
|
+
onKeyChanged: (newKey: string) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare const SQLSnippetItemEditor: (({ item, remove, onKeyChanged }: ISQLSnippetItemEditor) => JSX.Element) & {
|
|
9
|
+
displayName: string;
|
|
10
|
+
};
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { IFilterConfig_TreeSelect } from '../../model/filters/filter/tree-select';
|
|
3
|
+
interface IFilterEditorTreeSelect {
|
|
4
|
+
config: IFilterConfig_TreeSelect;
|
|
5
|
+
}
|
|
6
|
+
export declare const FilterEditorTreeSelect: import("react").FunctionComponent<IFilterEditorTreeSelect>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FilterModelInstance } from '../../../model';
|
|
3
|
+
import { IFilterConfig_TreeSelect } from '../../../model/filters/filter/tree-select';
|
|
4
|
+
interface IFilterTreeSelect extends Omit<FilterModelInstance, 'key' | 'type' | 'config'> {
|
|
5
|
+
config: IFilterConfig_TreeSelect;
|
|
6
|
+
value: $TSFixMe;
|
|
7
|
+
onChange: (v: $TSFixMe) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const FilterTreeSelect: (({ label, config, value, onChange }: IFilterTreeSelect) => JSX.Element) & {
|
|
10
|
+
displayName: string;
|
|
11
|
+
};
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { DefaultProps, MantineNumberSize, Selectors } from '@mantine/core';
|
|
3
|
+
import useStyles, { TreeSelectWidgetStylesParams } from './widget.styles';
|
|
4
|
+
declare type MyComponentStylesNames = Selectors<typeof useStyles>;
|
|
5
|
+
interface IFilterTreeSelectWidget extends DefaultProps<MyComponentStylesNames, TreeSelectWidgetStylesParams> {
|
|
6
|
+
radius?: MantineNumberSize;
|
|
7
|
+
style?: Record<string, any>;
|
|
8
|
+
label: string;
|
|
9
|
+
value: string[];
|
|
10
|
+
onChange: (v: string[]) => void;
|
|
11
|
+
treeData: $TSFixMe;
|
|
12
|
+
}
|
|
13
|
+
export declare const FilterTreeSelectWidget: ({ classNames, styles, unstyled, radius, style, label, value, onChange, treeData, }: IFilterTreeSelectWidget) => JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { MantineNumberSize } from '@mantine/core';
|
|
2
|
+
export interface TreeSelectWidgetStylesParams {
|
|
3
|
+
radius?: MantineNumberSize;
|
|
4
|
+
}
|
|
5
|
+
declare const _default: (params: TreeSelectWidgetStylesParams, options?: import("@mantine/core").UseStylesOptions<"label" | "root" | "dropdown"> | undefined) => {
|
|
6
|
+
classes: Record<"label" | "root" | "dropdown", string>;
|
|
7
|
+
cx: (...args: any) => string;
|
|
8
|
+
theme: import("@mantine/core").MantineTheme;
|
|
9
|
+
};
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { Instance } from 'mobx-state-tree';
|
|
2
|
+
export declare const FilterConfigModel_TreeSelect: import("mobx-state-tree").IModelType<{
|
|
3
|
+
_name: import("mobx-state-tree").ISimpleType<"tree-select">;
|
|
4
|
+
default_value: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IArrayType<import("mobx-state-tree").ISimpleType<string>>, [undefined]>;
|
|
5
|
+
min_width: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
6
|
+
} & {
|
|
7
|
+
static_options: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IArrayType<import("mobx-state-tree").IModelType<{
|
|
8
|
+
label: import("mobx-state-tree").ISimpleType<string>;
|
|
9
|
+
value: import("mobx-state-tree").ISimpleType<string>;
|
|
10
|
+
}, {
|
|
11
|
+
setLabel(label: string): void;
|
|
12
|
+
setValue(value: string): void;
|
|
13
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>, [undefined]>;
|
|
14
|
+
options_query_id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
15
|
+
select_first_by_default: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
16
|
+
}, {
|
|
17
|
+
readonly options: any;
|
|
18
|
+
} & {
|
|
19
|
+
addStaticOption(option: {
|
|
20
|
+
label: string;
|
|
21
|
+
value: string;
|
|
22
|
+
}): void;
|
|
23
|
+
removeStaticOption(index: number): void;
|
|
24
|
+
setSelectFirstByDefault(v: boolean): void;
|
|
25
|
+
setOptionsQueryID(id: string): void;
|
|
26
|
+
} & {
|
|
27
|
+
setDefaultValue(default_value: string[]): void;
|
|
28
|
+
setMinWidth(v: string): void;
|
|
29
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>;
|
|
30
|
+
export declare type IFilterConfig_TreeSelect = Instance<typeof FilterConfigModel_TreeSelect>;
|
|
31
|
+
export declare const createFilterConfig_TreeSelect: () => {
|
|
32
|
+
_name: "tree-select";
|
|
33
|
+
default_value: import("mobx-state-tree").IMSTArray<import("mobx-state-tree").ISimpleType<string>> & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IArrayType<import("mobx-state-tree").ISimpleType<string>>, [undefined]>>;
|
|
34
|
+
min_width: string;
|
|
35
|
+
static_options: import("mobx-state-tree").IMSTArray<import("mobx-state-tree").IModelType<{
|
|
36
|
+
label: import("mobx-state-tree").ISimpleType<string>;
|
|
37
|
+
value: import("mobx-state-tree").ISimpleType<string>;
|
|
38
|
+
}, {
|
|
39
|
+
setLabel(label: string): void;
|
|
40
|
+
setValue(value: string): void;
|
|
41
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>> & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IArrayType<import("mobx-state-tree").IModelType<{
|
|
42
|
+
label: import("mobx-state-tree").ISimpleType<string>;
|
|
43
|
+
value: import("mobx-state-tree").ISimpleType<string>;
|
|
44
|
+
}, {
|
|
45
|
+
setLabel(label: string): void;
|
|
46
|
+
setValue(value: string): void;
|
|
47
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>, [undefined]>>;
|
|
48
|
+
options_query_id: string;
|
|
49
|
+
select_first_by_default: boolean;
|
|
50
|
+
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
51
|
+
readonly options: any;
|
|
52
|
+
} & {
|
|
53
|
+
addStaticOption(option: {
|
|
54
|
+
label: string;
|
|
55
|
+
value: string;
|
|
56
|
+
}): void;
|
|
57
|
+
removeStaticOption(index: number): void;
|
|
58
|
+
setSelectFirstByDefault(v: boolean): void;
|
|
59
|
+
setOptionsQueryID(id: string): void;
|
|
60
|
+
} & {
|
|
61
|
+
setDefaultValue(default_value: string[]): void;
|
|
62
|
+
setMinWidth(v: string): void;
|
|
63
|
+
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
64
|
+
_name: import("mobx-state-tree").ISimpleType<"tree-select">;
|
|
65
|
+
default_value: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IArrayType<import("mobx-state-tree").ISimpleType<string>>, [undefined]>;
|
|
66
|
+
min_width: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
67
|
+
} & {
|
|
68
|
+
static_options: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IArrayType<import("mobx-state-tree").IModelType<{
|
|
69
|
+
label: import("mobx-state-tree").ISimpleType<string>;
|
|
70
|
+
value: import("mobx-state-tree").ISimpleType<string>;
|
|
71
|
+
}, {
|
|
72
|
+
setLabel(label: string): void;
|
|
73
|
+
setValue(value: string): void;
|
|
74
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>, [undefined]>;
|
|
75
|
+
options_query_id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
76
|
+
select_first_by_default: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
77
|
+
}, {
|
|
78
|
+
readonly options: any;
|
|
79
|
+
} & {
|
|
80
|
+
addStaticOption(option: {
|
|
81
|
+
label: string;
|
|
82
|
+
value: string;
|
|
83
|
+
}): void;
|
|
84
|
+
removeStaticOption(index: number): void;
|
|
85
|
+
setSelectFirstByDefault(v: boolean): void;
|
|
86
|
+
setOptionsQueryID(id: string): void;
|
|
87
|
+
} & {
|
|
88
|
+
setDefaultValue(default_value: string[]): void;
|
|
89
|
+
setMinWidth(v: string): void;
|
|
90
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
|
|
@@ -8,6 +8,7 @@ export declare const SQLSnippetsModel: import("mobx-state-tree").IModelType<{
|
|
|
8
8
|
key: string;
|
|
9
9
|
value: string;
|
|
10
10
|
};
|
|
11
|
+
isADuplicatedKey(newKey: string): boolean;
|
|
11
12
|
} & {
|
|
12
13
|
setKey(key: string): void;
|
|
13
14
|
setValue(value: string): void;
|
|
@@ -18,6 +19,32 @@ export declare const SQLSnippetsModel: import("mobx-state-tree").IModelType<{
|
|
|
18
19
|
value: string;
|
|
19
20
|
}[];
|
|
20
21
|
readonly record: Record<string, string>;
|
|
22
|
+
readonly firstKey: string | undefined;
|
|
23
|
+
findByKey(key: string): ({
|
|
24
|
+
key: string;
|
|
25
|
+
value: string;
|
|
26
|
+
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
27
|
+
readonly json: {
|
|
28
|
+
key: string;
|
|
29
|
+
value: string;
|
|
30
|
+
};
|
|
31
|
+
isADuplicatedKey(newKey: string): boolean;
|
|
32
|
+
} & {
|
|
33
|
+
setKey(key: string): void;
|
|
34
|
+
setValue(value: string): void;
|
|
35
|
+
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
36
|
+
key: import("mobx-state-tree").ISimpleType<string>;
|
|
37
|
+
value: import("mobx-state-tree").ISimpleType<string>;
|
|
38
|
+
}, {
|
|
39
|
+
readonly json: {
|
|
40
|
+
key: string;
|
|
41
|
+
value: string;
|
|
42
|
+
};
|
|
43
|
+
isADuplicatedKey(newKey: string): boolean;
|
|
44
|
+
} & {
|
|
45
|
+
setKey(key: string): void;
|
|
46
|
+
setValue(value: string): void;
|
|
47
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>) | undefined;
|
|
21
48
|
} & {
|
|
22
49
|
replace(current: Array<SQLSnippetModelInstance>): void;
|
|
23
50
|
append(item: SQLSnippetModelInstance): void;
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.filter-settings-tabs{width:100%;height:100%}.filter-settings-tabs .mantine-Tabs-panel{height:calc(100% - 25px)}.filter-settings-tabs .mantine-Tabs-tabsListWrapper{flex:0}.filter-settings-tabs .mantine-Tabs-body{flex:1;overflow:scroll}.panel-root{height:100%;width:100%;max-width:100%;background:transparent;border-radius:4px;position:relative}.panel-settings-tabs{width:100%;height:100%}.panel-settings-tabs .mantine-Tabs-panel{height:calc(100% - 25px)}.panel-settings-tabs .mantine-Tabs-tabsListWrapper{flex:0}.panel-settings-tabs .mantine-Tabs-body{flex:1;overflow:scroll}.viz-root{width:100%;overflow:scroll;flex-grow:1;background-color:#fff}.panel-dropdown-target{text-align:center;transition:background-color .3s ease}.panel-dropdown-target:hover{cursor:pointer;background-color:#6464640d}.react-grid-item{padding:0}.remove-panel{position:absolute;right:2px;top:0;cursor:pointer}.code-textarea textarea{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.dashboard-root{overflow:scroll;padding:0 10px 10px;height:100%}.dashboard-sticky-area{z-index:100;background:white;margin:0;padding:0 10px}*::-webkit-scrollbar{width:0!important;height:0!important}*{overflow:-moz-scrollbars-none;-ms-overflow-style:none}
|
|
1
|
+
.filter-settings-tabs{width:100%;height:100%}.filter-settings-tabs .mantine-Tabs-panel{height:calc(100% - 25px)}.filter-settings-tabs .mantine-Tabs-tabsListWrapper{flex:0}.filter-settings-tabs .mantine-Tabs-body{flex:1;overflow:scroll}.panel-root{height:100%;width:100%;max-width:100%;background:transparent;border-radius:4px;position:relative}.panel-settings-tabs{width:100%;height:100%}.panel-settings-tabs .mantine-Tabs-panel{height:calc(100% - 25px)}.panel-settings-tabs .mantine-Tabs-tabsListWrapper{flex:0}.panel-settings-tabs .mantine-Tabs-body{flex:1;overflow:scroll}.viz-root{width:100%;overflow:scroll;flex-grow:1;background-color:#fff}.panel-dropdown-target{text-align:center;transition:background-color .3s ease}.panel-dropdown-target:hover{cursor:pointer;background-color:#6464640d}.react-grid-item{padding:0}.remove-panel{position:absolute;right:2px;top:0;cursor:pointer}.code-textarea textarea{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.dashboard-root{overflow:scroll;padding:0 10px 10px;height:100%}.dashboard-sticky-area{z-index:100;background:white;margin:0;padding:0 10px}*::-webkit-scrollbar{width:0!important;height:0!important}*{overflow:-moz-scrollbars-none;-ms-overflow-style:none}.minimal-monaco-editor{border-radius:4px;overflow:hidden;background-color:#1e1e1e;padding-top:14px}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devtable/dashboard",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.9.0",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public",
|
|
@@ -33,8 +33,10 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@types/chroma-js": "^2.1.4",
|
|
35
35
|
"file-saver": "2.0.5",
|
|
36
|
+
"performant-array-to-tree": "1.11.0",
|
|
36
37
|
"popmotion": "^11.0.3",
|
|
37
38
|
"@monaco-editor/react": "4.4.6",
|
|
39
|
+
"rc-tree-select": "5.5.5",
|
|
38
40
|
"stickybits": "3.7.11"
|
|
39
41
|
},
|
|
40
42
|
"devDependencies": {
|