@devtable/dashboard 1.17.0 → 1.20.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.
Files changed (36) hide show
  1. package/dist/api-caller/index.d.ts +3 -3
  2. package/dist/contexts/definition-context.d.ts +2 -2
  3. package/dist/contexts/panel-context.d.ts +2 -2
  4. package/dist/dashboard.es.js +323 -225
  5. package/dist/dashboard.umd.js +8 -8
  6. package/dist/definition-editor/{data-source-editor → query-editor}/context-and-snippets.d.ts +0 -0
  7. package/dist/definition-editor/{data-source-editor → query-editor}/data-preview.d.ts +0 -0
  8. package/dist/definition-editor/query-editor/editor.d.ts +7 -0
  9. package/dist/definition-editor/query-editor/form.d.ts +8 -0
  10. package/dist/definition-editor/query-editor/index.d.ts +5 -0
  11. package/dist/definition-editor/{data-source-editor → query-editor}/preview-sql.d.ts +0 -0
  12. package/dist/definition-editor/query-editor/select-or-add-query.d.ts +7 -0
  13. package/dist/panel/index.d.ts +1 -1
  14. package/dist/panel/settings/common/data-field-selector.d.ts +12 -0
  15. package/dist/panel/settings/pick-query/index.d.ts +5 -0
  16. package/dist/panel/viz/bar-3d/panel.d.ts +2 -2
  17. package/dist/panel/viz/cartesian/panel/index.d.ts +1 -1
  18. package/dist/panel/viz/cartesian/panel/series/fields.bar.d.ts +9 -0
  19. package/dist/panel/viz/cartesian/panel/series/fields.line.d.ts +9 -0
  20. package/dist/panel/viz/cartesian/panel/{series.d.ts → series/index.d.ts} +3 -2
  21. package/dist/panel/viz/cartesian/panel/series/series-item.d.ts +16 -0
  22. package/dist/panel/viz/cartesian/type.d.ts +4 -1
  23. package/dist/panel/viz/pie/panel.d.ts +1 -1
  24. package/dist/panel/viz/stats/panel.d.ts +1 -1
  25. package/dist/panel/viz/sunburst/panel.d.ts +1 -1
  26. package/dist/panel/viz/table/panel.d.ts +1 -1
  27. package/dist/style.css +1 -1
  28. package/dist/types/dashboard.d.ts +3 -3
  29. package/dist/types/viz-panel.d.ts +1 -0
  30. package/package.json +1 -1
  31. package/dist/definition-editor/data-source-editor/editor.d.ts +0 -7
  32. package/dist/definition-editor/data-source-editor/form.d.ts +0 -8
  33. package/dist/definition-editor/data-source-editor/index.d.ts +0 -5
  34. package/dist/definition-editor/data-source-editor/select-or-add-data-source.d.ts +0 -7
  35. package/dist/panel/settings/pick-data-source/index.d.ts +0 -5
  36. package/dist/panel/viz/bar-3d/type.d.ts +0 -4
@@ -2,7 +2,7 @@ export interface IVizConfig {
2
2
  type: string;
3
3
  conf: Record<string, any>;
4
4
  }
5
- export interface IDataSource {
5
+ export interface IQuery {
6
6
  type: 'postgresql';
7
7
  key: string;
8
8
  sql: string;
@@ -20,7 +20,7 @@ export interface IDashboardPanel {
20
20
  moved?: boolean;
21
21
  static?: boolean;
22
22
  };
23
- dataSourceID: string;
23
+ queryID: string;
24
24
  viz: IVizConfig;
25
25
  }
26
26
  export declare enum DashboardMode {
@@ -34,7 +34,7 @@ export interface ISQLSnippet {
34
34
  }
35
35
  export interface IDashboardDefinition {
36
36
  sqlSnippets: ISQLSnippet[];
37
- dataSources: IDataSource[];
37
+ queries: IQuery[];
38
38
  }
39
39
  export interface IDashboard {
40
40
  id: string;
@@ -2,4 +2,5 @@ import { IVizConfig } from "./dashboard";
2
2
  export interface IVizPanelProps {
3
3
  conf: IVizConfig['conf'];
4
4
  setConf: (conf: IVizConfig['conf']) => void;
5
+ data: any[];
5
6
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devtable/dashboard",
3
- "version": "1.17.0",
3
+ "version": "1.20.0",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org/"
@@ -1,7 +0,0 @@
1
- import React from "react";
2
- interface IDataSourceEditor {
3
- id: string;
4
- setID: React.Dispatch<React.SetStateAction<string>>;
5
- }
6
- export declare function DataSourceEditor({ id, setID }: IDataSourceEditor): JSX.Element | null;
7
- export {};
@@ -1,8 +0,0 @@
1
- /// <reference types="react" />
2
- import { IDataSource } from "../../types";
3
- interface IDataSourceForm {
4
- value: IDataSource;
5
- onChange: any;
6
- }
7
- export declare function DataSourceForm({ value, onChange }: IDataSourceForm): JSX.Element;
8
- export {};
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- interface IEditDataSources {
3
- }
4
- export declare function EditDataSources({}: IEditDataSources): JSX.Element;
5
- export {};
@@ -1,7 +0,0 @@
1
- import React from "react";
2
- interface ISelectOrAddDataSource {
3
- id: string;
4
- setID: React.Dispatch<React.SetStateAction<string>>;
5
- }
6
- export declare function SelectOrAddDataSource({ id, setID }: ISelectOrAddDataSource): JSX.Element;
7
- export {};
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- interface IPickDataSource {
3
- }
4
- export declare function PickDataSource({}: IPickDataSource): JSX.Element;
5
- export {};
@@ -1,4 +0,0 @@
1
- export interface IVizBar3DPanel {
2
- conf: any;
3
- setConf: (values: any) => void;
4
- }