@nocobase/plugin-data-visualization 1.3.39-beta → 1.4.0-alpha

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 (80) hide show
  1. package/dist/client/block/ChartBlockProvider.d.ts +10 -0
  2. package/dist/client/block/GlobalAutoRefreshProvider.d.ts +19 -0
  3. package/dist/client/block/index.d.ts +2 -0
  4. package/dist/client/chart/chart.d.ts +9 -6
  5. package/dist/client/chart/configs.d.ts +212 -19
  6. package/dist/client/chart/group.d.ts +9 -4
  7. package/dist/client/configure/schemas/configure.d.ts +1 -1
  8. package/dist/client/filter/utils.d.ts +2 -1
  9. package/dist/client/hooks/chart.d.ts +20 -0
  10. package/dist/client/hooks/index.d.ts +1 -0
  11. package/dist/client/index.d.ts +1 -0
  12. package/dist/client/index.js +30 -30
  13. package/dist/client/initializers/BlockRefreshAction.d.ts +14 -0
  14. package/dist/client/initializers/RefreshAction.d.ts +14 -0
  15. package/dist/client/initializers/chartActions.d.ts +10 -0
  16. package/dist/client/initializers/chartBlockActions.d.ts +10 -0
  17. package/dist/client/renderer/ChartRendererDesigner.d.ts +10 -0
  18. package/dist/client/renderer/ChartRendererProvider.d.ts +6 -0
  19. package/dist/client/settings/AutoRefreshItem.d.ts +13 -0
  20. package/dist/client/settings/chartActionRefresh.d.ts +10 -0
  21. package/dist/client/settings/chartBlockActionRefresh.d.ts +10 -0
  22. package/dist/client/utils.d.ts +42 -0
  23. package/dist/externalVersion.js +8 -8
  24. package/dist/locale/en-US.json +15 -14
  25. package/dist/locale/zh-CN.json +10 -9
  26. package/dist/node_modules/koa-compose/package.json +1 -1
  27. package/dist/node_modules/moment-timezone/LICENSE +20 -0
  28. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data-10-year-range.js +1548 -0
  29. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data-10-year-range.min.js +1 -0
  30. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data-1970-2030.js +1548 -0
  31. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data-1970-2030.min.js +1 -0
  32. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data-2012-2022.js +1560 -0
  33. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data-2012-2022.min.js +1 -0
  34. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data.js +1548 -0
  35. package/dist/node_modules/moment-timezone/builds/moment-timezone-with-data.min.js +1 -0
  36. package/dist/node_modules/moment-timezone/builds/moment-timezone.min.js +1 -0
  37. package/dist/node_modules/moment-timezone/composer.json +43 -0
  38. package/dist/node_modules/moment-timezone/data/meta/latest.json +5889 -0
  39. package/dist/node_modules/moment-timezone/data/packed/latest.json +852 -0
  40. package/dist/node_modules/moment-timezone/index.d.ts +78 -0
  41. package/dist/node_modules/moment-timezone/index.js +15 -0
  42. package/dist/node_modules/moment-timezone/moment-timezone-utils.d.ts +70 -0
  43. package/dist/node_modules/moment-timezone/moment-timezone-utils.js +339 -0
  44. package/dist/node_modules/moment-timezone/moment-timezone.js +696 -0
  45. package/dist/node_modules/moment-timezone/package.json +1 -0
  46. package/dist/server/actions/query.d.ts +0 -1
  47. package/dist/server/actions/query.js +11 -75
  48. package/dist/server/formatter/formatter.d.ts +27 -0
  49. package/dist/server/formatter/formatter.js +85 -0
  50. package/dist/server/formatter/mysql-formatter.d.ts +14 -0
  51. package/dist/server/formatter/mysql-formatter.js +86 -0
  52. package/dist/server/formatter/oracle-formatter.d.ts +14 -0
  53. package/dist/server/formatter/oracle-formatter.js +74 -0
  54. package/dist/server/formatter/postgres-formatter.d.ts +14 -0
  55. package/dist/server/formatter/postgres-formatter.js +74 -0
  56. package/dist/server/formatter/sqlite-formatter.d.ts +15 -0
  57. package/dist/server/formatter/sqlite-formatter.js +83 -0
  58. package/dist/server/migrations/20240921214400-rename-charttype.d.ts +14 -0
  59. package/dist/server/migrations/20240921214400-rename-charttype.js +64 -0
  60. package/dist/server/plugin.js +1 -1
  61. package/dist/server/query-parser/index.d.ts +11 -0
  62. package/dist/server/query-parser/index.js +56 -0
  63. package/dist/server/query-parser/mysql-query-parser.d.ts +15 -0
  64. package/dist/server/query-parser/mysql-query-parser.js +43 -0
  65. package/dist/server/query-parser/oracle-query-parser.d.ts +18 -0
  66. package/dist/server/query-parser/oracle-query-parser.js +60 -0
  67. package/dist/server/query-parser/postgres-query-parser.d.ts +15 -0
  68. package/dist/server/query-parser/postgres-query-parser.js +43 -0
  69. package/dist/server/query-parser/query-parser.d.ts +31 -0
  70. package/dist/server/query-parser/query-parser.js +134 -0
  71. package/dist/server/query-parser/sqlite-query-parser.d.ts +15 -0
  72. package/dist/server/query-parser/sqlite-query-parser.js +43 -0
  73. package/dist/server/types.d.ts +46 -0
  74. package/dist/server/types.js +24 -0
  75. package/package.json +2 -2
  76. package/dist/client/chart/g2plot/configs.d.ts +0 -122
  77. package/dist/server/actions/formatter.d.ts +0 -12
  78. package/dist/server/actions/formatter.js +0 -101
  79. /package/dist/locale/{ja_JP.json → ja-JP.json} +0 -0
  80. /package/dist/locale/{ko_KR.json → ko-KR.json} +0 -0
@@ -0,0 +1,14 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import React from 'react';
10
+ export declare const BlockRefreshButton: React.FC;
11
+ export declare const useChartBlockRefreshActionProps: () => {
12
+ onClick: () => void;
13
+ };
14
+ export declare const BlockRefreshActionInitializer: (props: any) => React.JSX.Element;
@@ -0,0 +1,14 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import React from 'react';
10
+ export declare const RefreshButton: React.FC;
11
+ export declare const useChartRefreshActionProps: () => {
12
+ onClick: any;
13
+ };
14
+ export declare const RefreshActionInitializer: (props: any) => React.JSX.Element;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import { SchemaInitializer } from '@nocobase/client';
10
+ export declare const chartActionsInitializer: SchemaInitializer<import("antd").ButtonProps, {}>;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import { SchemaInitializer } from '@nocobase/client';
10
+ export declare const chartBlockActionsInitializer: SchemaInitializer<import("antd").ButtonProps, {}>;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import React from 'react';
10
+ export declare function ChartRendererDesigner(): React.JSX.Element;
@@ -45,12 +45,18 @@ export type ChartRendererProps = {
45
45
  chartType: string;
46
46
  general: any;
47
47
  advanced: any;
48
+ title?: string;
49
+ bordered?: boolean;
48
50
  };
49
51
  transform?: TransformProps[];
50
52
  mode?: 'builder' | 'sql';
53
+ disableAutoRefresh?: boolean;
51
54
  };
52
55
  export declare const ChartRendererContext: React.Context<{
53
56
  service: any;
54
57
  data?: any[];
58
+ autoRefresh?: number | boolean;
59
+ setAutoRefresh?: (autoRefresh: number | boolean) => void;
60
+ showActionBar?: boolean;
55
61
  } & ChartRendererProps>;
56
62
  export declare const ChartRendererProvider: React.FC<ChartRendererProps>;
@@ -0,0 +1,13 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import React from 'react';
10
+ export declare const AutoRefreshItem: React.FC<{
11
+ value: number | boolean;
12
+ onChange?: (value: any) => void;
13
+ }>;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import { SchemaSettings } from '@nocobase/client';
10
+ export declare const chartActionRefreshSettings: SchemaSettings<{}>;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import { SchemaSettings } from '@nocobase/client';
10
+ export declare const chartBlockActionRefreshSettings: SchemaSettings<{}>;
@@ -24,9 +24,51 @@ export declare const createRendererSchema: (decoratorProps: any, componentProps?
24
24
  'x-initializer': string;
25
25
  properties: {
26
26
  [x: string]: {
27
+ type: string;
28
+ 'x-decorator': string;
29
+ 'x-decorator-props': {
30
+ style: {
31
+ position: string;
32
+ top: number;
33
+ right: number;
34
+ zIndex: number;
35
+ };
36
+ };
37
+ 'x-component': string;
38
+ 'x-component-props': {
39
+ style: {
40
+ marginRight: string;
41
+ marginTop: string;
42
+ };
43
+ };
44
+ 'x-initializer': string;
45
+ } | {
27
46
  type: string;
28
47
  'x-component': string;
29
48
  'x-component-props': {};
49
+ 'x-decorator'?: undefined;
50
+ 'x-decorator-props'?: undefined;
51
+ 'x-initializer'?: undefined;
52
+ };
53
+ actions: {
54
+ type: string;
55
+ 'x-decorator': string;
56
+ 'x-decorator-props': {
57
+ style: {
58
+ position: string;
59
+ top: number;
60
+ right: number;
61
+ zIndex: number;
62
+ };
63
+ };
64
+ 'x-component': string;
65
+ 'x-component-props': {
66
+ style: {
67
+ marginRight: string;
68
+ marginTop: string;
69
+ };
70
+ };
71
+ 'x-initializer': string;
30
72
  };
31
73
  };
32
74
  };
@@ -8,24 +8,24 @@
8
8
  */
9
9
 
10
10
  module.exports = {
11
- "@nocobase/client": "1.3.39-beta",
11
+ "@nocobase/client": "1.4.0-alpha",
12
12
  "dayjs": "1.11.10",
13
13
  "@formily/react": "2.3.0",
14
14
  "@formily/shared": "2.3.0",
15
15
  "lodash": "4.17.21",
16
- "@nocobase/cache": "1.3.39-beta",
17
- "@nocobase/server": "1.3.39-beta",
18
- "@nocobase/test": "1.3.39-beta",
19
16
  "react": "18.2.0",
17
+ "@nocobase/cache": "1.4.0-alpha",
18
+ "@nocobase/server": "1.4.0-alpha",
19
+ "@nocobase/test": "1.4.0-alpha",
20
20
  "@emotion/css": "11.13.0",
21
21
  "@ant-design/icons": "5.2.6",
22
22
  "ahooks": "3.7.8",
23
23
  "antd": "5.12.8",
24
24
  "@formily/antd-v5": "1.1.9",
25
25
  "@formily/core": "2.3.0",
26
- "@nocobase/utils": "1.3.39-beta",
26
+ "@nocobase/utils": "1.4.0-alpha",
27
27
  "react-i18next": "11.18.6",
28
- "sequelize": "6.35.2",
29
- "@nocobase/actions": "1.3.39-beta",
30
- "@nocobase/database": "1.3.39-beta"
28
+ "@nocobase/actions": "1.4.0-alpha",
29
+ "@nocobase/database": "1.4.0-alpha",
30
+ "sequelize": "6.35.2"
31
31
  };
@@ -34,19 +34,19 @@
34
34
  "Type": "Type",
35
35
  "Add field": "Add field",
36
36
  "Add chart": "Add chart",
37
- "xField": "xField",
38
- "yField": "yField",
39
- "seriesField": "seriesField",
40
- "angleField": "angleField",
41
- "colorField": "colorField",
42
- "Line Chart": "Line Chart",
43
- "Area Chart": "Area Chart",
44
- "Column Chart": "Column Chart",
45
- "Bar Chart": "Bar Chart",
46
- "Pie Chart": "Pie Chart",
47
- "Dual Axes Chart": "Dual Axes Chart",
48
- "Scatter Chart": "Scatter Chart",
49
- "Gauge Chart": "Gauge Chart",
37
+ "xField": "X field",
38
+ "yField": "Y field",
39
+ "seriesField": "Series field",
40
+ "angleField": "Angle field",
41
+ "colorField": "Color field",
42
+ "Line": "Line",
43
+ "Area": "Area",
44
+ "Column": "Column",
45
+ "Bar": "Bar",
46
+ "Pie": "Pie",
47
+ "Dual axes": "Dual axes",
48
+ "Scatter": "Scatter",
49
+ "Gauge": "Gauge",
50
50
  "Statistic": "Statistic",
51
51
  "Currency": "Currency",
52
52
  "Percent": "Percent",
@@ -95,5 +95,6 @@
95
95
  "Fixed height": "Fixed height",
96
96
  "Show background": "Show background",
97
97
  "Show padding": "Show padding",
98
- "Distinct": "Distinct"
98
+ "Distinct": "Distinct",
99
+ "Auto refresh": "Auto refresh"
99
100
  }
@@ -39,14 +39,14 @@
39
39
  "seriesField": "分类字段",
40
40
  "angleField": "角度字段",
41
41
  "colorField": "颜色字段",
42
- "Line Chart": "折线图",
43
- "Area Chart": "面积图",
44
- "Column Chart": "柱状图",
45
- "Bar Chart": "条形图",
46
- "Pie Chart": "饼图",
47
- "Dual Axes Chart": "双轴图",
48
- "Scatter Chart": "散点图",
49
- "Gauge Chart": "仪表盘",
42
+ "Line": "折线图",
43
+ "Area": "面积图",
44
+ "Column": "柱状图",
45
+ "Bar": "条形图",
46
+ "Pie": "饼图",
47
+ "Dual axes": "双轴图",
48
+ "Scatter": "散点图",
49
+ "Gauge": "仪表盘",
50
50
  "Statistic": "统计",
51
51
  "Currency": "货币",
52
52
  "Percent": "百分比",
@@ -96,5 +96,6 @@
96
96
  "Fixed height": "固定高度",
97
97
  "Show background": "显示背景",
98
98
  "Show padding": "显示内边距",
99
- "Distinct": "去重"
99
+ "Distinct": "去重",
100
+ "Auto refresh": "自动刷新"
100
101
  }
@@ -1 +1 @@
1
- {"name":"koa-compose","description":"compose Koa middleware","repository":"koajs/compose","version":"4.1.0","keywords":["koa","middleware","compose"],"files":["index.js"],"dependencies":{},"devDependencies":{"codecov":"^3.0.0","jest":"^21.0.0","matcha":"^0.7.0","standard":"^10.0.3"},"scripts":{"bench":"matcha bench/bench.js","lint":"standard --fix .","test":"jest --forceExit --coverage"},"jest":{"testEnvironment":"node"},"license":"MIT","_lastModified":"2024-10-24T04:45:37.884Z"}
1
+ {"name":"koa-compose","description":"compose Koa middleware","repository":"koajs/compose","version":"4.1.0","keywords":["koa","middleware","compose"],"files":["index.js"],"dependencies":{},"devDependencies":{"codecov":"^3.0.0","jest":"^21.0.0","matcha":"^0.7.0","standard":"^10.0.3"},"scripts":{"bench":"matcha bench/bench.js","lint":"standard --fix .","test":"jest --forceExit --coverage"},"jest":{"testEnvironment":"node"},"license":"MIT","_lastModified":"2024-10-24T14:07:30.452Z"}
@@ -0,0 +1,20 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) JS Foundation and other contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
6
+ this software and associated documentation files (the "Software"), to deal in
7
+ the Software without restriction, including without limitation the rights to
8
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9
+ the Software, and to permit persons to whom the Software is furnished to do so,
10
+ 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, FITNESS
17
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.