@gingkoo/pandora-metabase 0.0.1-alpha.1 → 0.0.1-alpha.3

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 (89) hide show
  1. package/README.md +76 -90
  2. package/lib/es/common/Loading/index.d.ts +6 -0
  3. package/lib/es/common/SplitView/index.d.ts +17 -0
  4. package/lib/es/{metaBase/components → components}/dialog/const.d.ts +1 -1
  5. package/lib/es/{metaBase/components → components}/dialog/custom-column/dialog/select-list.d.ts +0 -1
  6. package/lib/es/components/dialog/custom-column/expression-editor.d.ts +9 -0
  7. package/lib/es/{metaBase/components → components}/dialog/custom-column/expressions/suggest.d.ts +1 -1
  8. package/lib/es/{metaBase/components → components}/dialog/custom-column/index.d.ts +2 -4
  9. package/lib/es/components/dialog/custom-column/tokenizedI-input.d.ts +16 -0
  10. package/lib/es/components/dialog/index.d.ts +8 -0
  11. package/lib/es/{metaBase/components → components}/dialog/select-column/index.d.ts +1 -2
  12. package/lib/es/{metaBase/components → components}/dialog/select-join/index.d.ts +1 -1
  13. package/lib/es/{metaBase/components → components}/dialog/select-join-column/index.d.ts +13 -9
  14. package/lib/es/components/dialog/select-permission-table/index.d.ts +15 -0
  15. package/lib/es/{metaBase/components → components}/dialog/select-summarize/index.d.ts +2 -3
  16. package/lib/es/components/dialog/select-table/index.d.ts +17 -0
  17. package/lib/es/{metaBase/components → components}/icons.d.ts +2 -0
  18. package/lib/es/components/metabase/index.d.ts +4 -0
  19. package/lib/es/components/modules/components/meta-icon.d.ts +6 -0
  20. package/lib/es/components/modules/custom-column.d.ts +7 -0
  21. package/lib/es/components/modules/filter.d.ts +6 -0
  22. package/lib/es/components/modules/index.d.ts +4 -0
  23. package/lib/es/components/modules/join-data.d.ts +6 -0
  24. package/lib/es/components/modules/permission-table.d.ts +6 -0
  25. package/lib/es/components/modules/row-limit.d.ts +6 -0
  26. package/lib/es/components/modules/sort.d.ts +6 -0
  27. package/lib/es/components/modules/summarize/group-by.d.ts +11 -0
  28. package/lib/es/components/modules/summarize/index.d.ts +7 -0
  29. package/lib/es/components/modules/summarize/select-index.d.ts +7 -0
  30. package/lib/es/components/modules/table-data.d.ts +6 -0
  31. package/lib/es/constants/enum.d.ts +15 -0
  32. package/lib/es/constants/index.d.ts +1 -0
  33. package/lib/es/constants/storageKey.d.ts +1 -0
  34. package/lib/es/hooks/winsize.d.ts +4 -0
  35. package/lib/es/index.d.ts +4 -2
  36. package/lib/es/index.js +1876 -973
  37. package/lib/es/index.js.map +1 -1
  38. package/lib/es/locale/en.d.ts +2 -0
  39. package/lib/es/locale/index.d.ts +3 -0
  40. package/lib/es/locale/zh.d.ts +2 -0
  41. package/lib/es/metabase.d.ts +6 -0
  42. package/lib/es/store/{metabase/enum.d.ts → enum.d.ts} +1 -4
  43. package/lib/es/store/index.d.ts +47 -0
  44. package/lib/es/store/{metabase/types.d.ts → types.d.ts} +26 -24
  45. package/lib/es/types.d.ts +11 -37
  46. package/lib/es/utils/cookies.d.ts +1 -0
  47. package/lib/es/utils/helper.d.ts +1 -11
  48. package/lib/es/utils/keydown.d.ts +21 -0
  49. package/lib/es/utils/platform.d.ts +12 -0
  50. package/lib/es/utils/storage.d.ts +22 -0
  51. package/lib/es/{metaBase/utils.d.ts → utils.d.ts} +2 -2
  52. package/package.json +8 -20
  53. package/lib/es/constant.d.ts +0 -1
  54. package/lib/es/enum.d.ts +0 -17
  55. package/lib/es/helper.d.ts +0 -16
  56. package/lib/es/icons.d.ts +0 -2
  57. package/lib/es/metaBase/components/dialog/custom-column/expression-editor.d.ts +0 -11
  58. package/lib/es/metaBase/components/dialog/custom-column/tokenizedI-input.d.ts +0 -3
  59. package/lib/es/metaBase/components/dialog/index.d.ts +0 -7
  60. package/lib/es/metaBase/components/dialog/select-table/index.d.ts +0 -17
  61. package/lib/es/metaBase/components/modules/components/meta-icon.d.ts +0 -3
  62. package/lib/es/metaBase/components/modules/custom-column.d.ts +0 -3
  63. package/lib/es/metaBase/components/modules/filter.d.ts +0 -3
  64. package/lib/es/metaBase/components/modules/index.d.ts +0 -3
  65. package/lib/es/metaBase/components/modules/join-data.d.ts +0 -3
  66. package/lib/es/metaBase/components/modules/row-limit.d.ts +0 -3
  67. package/lib/es/metaBase/components/modules/sort.d.ts +0 -3
  68. package/lib/es/metaBase/components/modules/summarize/group-by.d.ts +0 -8
  69. package/lib/es/metaBase/components/modules/summarize/index.d.ts +0 -3
  70. package/lib/es/metaBase/components/modules/summarize/select-index.d.ts +0 -3
  71. package/lib/es/metaBase/components/modules/table-data.d.ts +0 -3
  72. package/lib/es/metaBase/enum.d.ts +0 -54
  73. package/lib/es/metaBase/index.d.ts +0 -7
  74. package/lib/es/metaBase/interface.d.ts +0 -11
  75. package/lib/es/metaBase/locale.d.ts +0 -1
  76. package/lib/es/request.d.ts +0 -23
  77. package/lib/es/store/metabase/index.d.ts +0 -51
  78. /package/lib/es/{components → common}/Portal/index.d.ts +0 -0
  79. /package/lib/es/{metaBase/components → components}/dialog/custom-column/config.d.ts +0 -0
  80. /package/lib/es/{metaBase/components → components}/dialog/custom-column/dialog/function-tip.d.ts +0 -0
  81. /package/lib/es/{metaBase/components → components}/dialog/custom-column/expressions/tokenizer.d.ts +0 -0
  82. /package/lib/es/{metaBase/components → components}/dialog/custom-column/keyboard.d.ts +0 -0
  83. /package/lib/es/{metaBase/components → components}/dialog/custom-column/tokenized-expression.d.ts +0 -0
  84. /package/lib/es/{metaBase/components → components}/dialog/select-filter/index.d.ts +0 -0
  85. /package/lib/es/{metaBase/components/modules/components/wrapper.d.ts → components/modules/components/Wrapper.d.ts} +0 -0
  86. /package/lib/es/{metaBase/components → components}/modules/components/header.d.ts +0 -0
  87. /package/lib/es/{metaBase/components → components}/popup.d.ts +0 -0
  88. /package/lib/es/{metaBase/sql-formula.d.ts → sql-formula.d.ts} +0 -0
  89. /package/lib/es/store/{metabase/helper.d.ts → helper.d.ts} +0 -0
package/README.md CHANGED
@@ -1,93 +1,79 @@
1
- # pandora-sql
2
-
3
-
4
-
5
- ## Getting started
6
-
7
- To make it easy for you to get started with GitLab, here's a list of recommended next steps.
8
-
9
- Already a pro? Just edit this README.md and make it your own. Want to make it easy? [Use the template at the bottom](#editing-this-readme)!
10
-
11
- ## Add your files
12
-
13
- - [ ] [Create](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#create-a-file) or [upload](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#upload-a-file) files
14
- - [ ] [Add files using the command line](https://docs.gitlab.com/ee/gitlab-basics/add-file.html#add-a-file-using-the-command-line) or push an existing Git repository with the following command:
1
+ # Pandora-Metabase 使用指南
2
+
3
+ ## 功能概述
4
+
5
+ `Pandora-Metabase` 是一个用于动态生成 SQL 查询的工具库,支持通过可视化界面配置表结构、字段及查询逻辑。
6
+
7
+ ### 主要功能
8
+
9
+ - **动态获取表字段**:使用 `getTableColumns` 方法可以动态获取指定表的最新字段信息,并且可以通过设置 `isCacheColumns=true` 来启用缓存机制(默认开启),减少重复请求。
10
+ - **可视化 SQL 构建**:通过 `MetaBase` 组件,用户能够以图形化的方式构建 SQL 查询,支持多种元数据类型,如 `MetaData`, `MetaJoin`, `MetaFilter` 等。
11
+ - **灵活扩展**:提供了丰富的接口和类型定义,便于根据具体需求进行定制和扩展。
12
+
13
+ ### 类型定义
14
+
15
+ ```ts
16
+ export type MetaListType =
17
+ | MetaData
18
+ | MetaJoin
19
+ | MetaCustom
20
+ | MetaFilter
21
+ | MetaSummarize
22
+ | MetaSort
23
+ | MetaLimit;
24
+
25
+ export interface MetaData_TableType {
26
+ name: string; // 表名
27
+ alias: string; // 别名
28
+ }
29
+
30
+ export interface MetaData_ColumnsType {
31
+ name: string; // 字段名
32
+ name_zh: string; // 字段中文名称
33
+ database_type: SQL_COLUMN_TYPE | string; // 数据库中的字段类型
34
+ special_type: SpecialType | string; // 特殊类型,如主键、外键等
35
+ select: boolean; // 是否在查询中选中该字段
36
+ }
37
+
38
+ export type InitColumnsType = Omit<MetaData_ColumnsType, 'select'>;
39
+
40
+ export interface MetaBaseProps {
41
+ loading?: boolean; // 加载状态
42
+ value?: MetaListType[]; // 当前组件的值,用于回显数据
43
+ tableData?: MetaData_TableType[]; // 包含表别名的数据
44
+ showExecute?: boolean; // 是否显示执行按钮,默认为true
45
+ onExecute?: (params: MetaListType[]) => void; // 点击执行按钮时的回调函数
46
+ isCacheColumns?: boolean; // 是否启用列缓存,默认为true
47
+ getTableColumns?: (tableName: string) => Promise<InitColumnsType[]>; // 动态获取表列的方法
48
+ onChange?: (val: MetaListType[]) => void; // 当选择改变时触发的回调函数
49
+ }
15
50
 
16
51
  ```
17
- cd existing_repo
18
- git remote add origin http://git.server.gingkoo/frontend/pandora/pandora-components/pandora-sql.git
19
- git branch -M main
20
- git push -uf origin main
21
- ```
22
-
23
- ## Integrate with your tools
24
-
25
- - [ ] [Set up project integrations](http://git.server.gingkoo/frontend/pandora/pandora-components/pandora-sql/-/settings/integrations)
26
-
27
- ## Collaborate with your team
28
-
29
- - [ ] [Invite team members and collaborators](https://docs.gitlab.com/ee/user/project/members/)
30
- - [ ] [Create a new merge request](https://docs.gitlab.com/ee/user/project/merge_requests/creating_merge_requests.html)
31
- - [ ] [Automatically close issues from merge requests](https://docs.gitlab.com/ee/user/project/issues/managing_issues.html#closing-issues-automatically)
32
- - [ ] [Enable merge request approvals](https://docs.gitlab.com/ee/user/project/merge_requests/approvals/)
33
- - [ ] [Set auto-merge](https://docs.gitlab.com/ee/user/project/merge_requests/merge_when_pipeline_succeeds.html)
34
-
35
- ## Test and Deploy
36
-
37
- Use the built-in continuous integration in GitLab.
38
-
39
- - [ ] [Get started with GitLab CI/CD](https://docs.gitlab.com/ee/ci/quick_start/index.html)
40
- - [ ] [Analyze your code for known vulnerabilities with Static Application Security Testing (SAST)](https://docs.gitlab.com/ee/user/application_security/sast/)
41
- - [ ] [Deploy to Kubernetes, Amazon EC2, or Amazon ECS using Auto Deploy](https://docs.gitlab.com/ee/topics/autodevops/requirements.html)
42
- - [ ] [Use pull-based deployments for improved Kubernetes management](https://docs.gitlab.com/ee/user/clusters/agent/)
43
- - [ ] [Set up protected environments](https://docs.gitlab.com/ee/ci/environments/protected_environments.html)
44
-
45
- ***
46
-
47
- # Editing this README
48
-
49
- When you're ready to make this README your own, just edit this file and use the handy template below (or feel free to structure it however you want - this is just a starting point!). Thanks to [makeareadme.com](https://www.makeareadme.com/) for this template.
50
-
51
- ## Suggestions for a good README
52
-
53
- Every project is different, so consider which of these sections apply to yours. The sections used in the template are suggestions for most open source projects. Also keep in mind that while a README can be too long and detailed, too long is better than too short. If you think your README is too long, consider utilizing another form of documentation rather than cutting out information.
54
-
55
- ## Name
56
- Choose a self-explaining name for your project.
57
-
58
- ## Description
59
- Let people know what your project can do specifically. Provide context and add a link to any reference visitors might be unfamiliar with. A list of Features or a Background subsection can also be added here. If there are alternatives to your project, this is a good place to list differentiating factors.
60
-
61
- ## Badges
62
- On some READMEs, you may see small images that convey metadata, such as whether or not all the tests are passing for the project. You can use Shields to add some to your README. Many services also have instructions for adding a badge.
63
-
64
- ## Visuals
65
- Depending on what you are making, it can be a good idea to include screenshots or even a video (you'll frequently see GIFs rather than actual videos). Tools like ttygif can help, but check out Asciinema for a more sophisticated method.
66
-
67
- ## Installation
68
- Within a particular ecosystem, there may be a common way of installing things, such as using Yarn, NuGet, or Homebrew. However, consider the possibility that whoever is reading your README is a novice and would like more guidance. Listing specific steps helps remove ambiguity and gets people to using your project as quickly as possible. If it only runs in a specific context like a particular programming language version or operating system or has dependencies that have to be installed manually, also add a Requirements subsection.
69
-
70
- ## Usage
71
- Use examples liberally, and show the expected output if you can. It's helpful to have inline the smallest example of usage that you can demonstrate, while providing links to more sophisticated examples if they are too long to reasonably include in the README.
72
-
73
- ## Support
74
- Tell people where they can go to for help. It can be any combination of an issue tracker, a chat room, an email address, etc.
75
-
76
- ## Roadmap
77
- If you have ideas for releases in the future, it is a good idea to list them in the README.
78
-
79
- ## Contributing
80
- State if you are open to contributions and what your requirements are for accepting them.
81
-
82
- For people who want to make changes to your project, it's helpful to have some documentation on how to get started. Perhaps there is a script that they should run or some environment variables that they need to set. Make these steps explicit. These instructions could also be useful to your future self.
83
-
84
- You can also document commands to lint the code or run tests. These steps help to ensure high code quality and reduce the likelihood that the changes inadvertently break something. Having instructions for running tests is especially helpful if it requires external setup, such as starting a Selenium server for testing in a browser.
85
-
86
- ## Authors and acknowledgment
87
- Show your appreciation to those who have contributed to the project.
88
-
89
- ## License
90
- For open source projects, say how it is licensed.
91
52
 
92
- ## Project status
93
- If you have run out of energy or time for your project, put a note at the top of the README saying that development has slowed down or stopped completely. Someone may choose to fork your project or volunteer to step in as a maintainer or owner, allowing your project to keep going. You can also make an explicit request for maintainers.
53
+ ## 代码示例
54
+
55
+ ```tsx
56
+ const [table, setTable] = useState([]);
57
+ const [value, setValue] = useState<MetaListType[]>([]);
58
+
59
+ <MetaBase
60
+ value={value}
61
+ tableData={table}
62
+ onChange={setValue}
63
+ getTableColumns={async (name: string) => {
64
+ let data: MetaData_ColumnsType[] = [
65
+ {
66
+ database_type: 'STRING',
67
+ name: 'C_RSV5',
68
+ select: true,
69
+ special_type: '',
70
+ name_zh: '备用字段(项目组可使用)',
71
+ },
72
+ ];
73
+ return data;
74
+ }}
75
+ onExecute={(v) => {
76
+ console.log(v);
77
+ }}
78
+ />
79
+ ```
@@ -0,0 +1,6 @@
1
+ import './index.less';
2
+ declare const Loading: ({ show, msg }: {
3
+ show: boolean;
4
+ msg?: string;
5
+ }) => import("react/jsx-runtime").JSX.Element | null;
6
+ export default Loading;
@@ -0,0 +1,17 @@
1
+ import './index.less';
2
+ import React from 'react';
3
+ interface SplitViewProps {
4
+ children: any;
5
+ direction?: 'horizontal' | 'vertical';
6
+ defaultY?: number;
7
+ topY?: number;
8
+ bottomY?: number;
9
+ topMinH?: number;
10
+ bottomMinH?: number;
11
+ }
12
+ /**
13
+ * 先不考虑局部情况,只考虑该组件占据整个浏览器窗口
14
+ * @returns React.ReactNode
15
+ */
16
+ declare const SplitView: React.ForwardRefExoticComponent<SplitViewProps & React.RefAttributes<unknown>>;
17
+ export default SplitView;
@@ -1,4 +1,4 @@
1
- import { SQL_COLUMN_TYPE } from '../../../store/metabase/enum';
1
+ import { SQL_COLUMN_TYPE } from '../../store/enum';
2
2
  export declare const NUMBER_GROUP: SQL_COLUMN_TYPE[];
3
3
  export declare const STRING_GROUP: SQL_COLUMN_TYPE[];
4
4
  export declare const DATE_GROUP: SQL_COLUMN_TYPE[];
@@ -9,7 +9,6 @@ export interface PropsType {
9
9
  data: ListProps[];
10
10
  onSelect: (type: OptionsTypeEnum, val: string) => any;
11
11
  didUpdate?: Function;
12
- setPopupClosable?: Function;
13
12
  }
14
13
  declare const SelectList: ({ data, onSelect }: PropsType) => import("react/jsx-runtime").JSX.Element;
15
14
  export default SelectList;
@@ -0,0 +1,9 @@
1
+ import { MetaData_ColumnsType } from '../../../store/types';
2
+ interface PropsType {
3
+ store?: any;
4
+ data: MetaData_ColumnsType[];
5
+ expression: string;
6
+ onChange: (formula: string) => void;
7
+ }
8
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
9
+ export default _default;
@@ -1,4 +1,4 @@
1
- import { MetaData_ColumnsType } from '../../../../../store/metabase/types';
1
+ import { MetaData_ColumnsType } from '../../../../store/types';
2
2
  import { ListProps } from '../dialog/select-list';
3
3
  export declare enum OptionsTypeEnum {
4
4
  FUNCTION = "function",
@@ -1,12 +1,10 @@
1
1
  import './index.less';
2
- import { MetaCustom_Item, MetaData_ColumnsType } from '../../../../store/metabase/types';
2
+ import { MetaCustom_Item, MetaData_ColumnsType } from '../../../store/types';
3
3
  interface PropsType {
4
4
  value: MetaCustom_Item | null;
5
5
  data: MetaData_ColumnsType[];
6
6
  onChange: (record: MetaCustom_Item) => void;
7
7
  onClose: Function;
8
- popupClosable: boolean;
9
- setPopupClosable: Function;
10
8
  }
11
- declare const CustomColumn: ({ value, data, popupClosable, setPopupClosable, onChange, onClose, }: PropsType) => import("react/jsx-runtime").JSX.Element;
9
+ declare const CustomColumn: ({ value, data, onChange, onClose }: PropsType) => import("react/jsx-runtime").JSX.Element;
12
10
  export default CustomColumn;
@@ -0,0 +1,16 @@
1
+ import React from 'react';
2
+ interface PropsType {
3
+ forwardedRef?: any;
4
+ style: object;
5
+ className: string;
6
+ value: string;
7
+ onFocus: (e?: any) => any;
8
+ onBlur: (e?: any) => any;
9
+ onChange: (e?: any) => any;
10
+ onKeyDown: (e?: any) => any;
11
+ onClick: (e?: any) => any;
12
+ }
13
+ declare const _default: React.ForwardRefExoticComponent<Omit<Omit<PropsType, "forwardedRef"> & {
14
+ ref?: any;
15
+ }, "ref"> & React.RefAttributes<unknown>>;
16
+ export default _default;
@@ -0,0 +1,8 @@
1
+ export { default as CustomColumnPopup } from './custom-column/index';
2
+ export { default as SelectColumn } from './select-column/index';
3
+ export { default as SelectJoinColumn } from './select-join-column/index';
4
+ export { default as SelectFilter } from './select-filter/index';
5
+ export { default as SelectSummarize } from './select-summarize/index';
6
+ export { default as SelectJoin } from './select-join/index';
7
+ export { default as SelectTable } from './select-table/index';
8
+ export { default as SelectPermissionTable } from './select-permission-table/index';
@@ -5,11 +5,10 @@
5
5
  * 2、关联模块
6
6
  */
7
7
  import './index.less';
8
- import { MetaData_ColumnsType } from '../../../../store/metabase/types';
8
+ import { MetaData_ColumnsType } from '../../../store/types';
9
9
  interface PropsType {
10
10
  data: MetaData_ColumnsType[];
11
11
  onChange: (record: MetaData_ColumnsType[]) => void;
12
- setPopupClosable?: Function;
13
12
  }
14
13
  declare const SelectColumn: ({ data, onChange }: PropsType) => import("react/jsx-runtime").JSX.Element;
15
14
  export default SelectColumn;
@@ -4,7 +4,7 @@
4
4
  * 1、关联模块
5
5
  */
6
6
  import './index.less';
7
- import { JoinEnum } from '../../../../store/metabase/enum';
7
+ import { JoinEnum } from '../../../store/enum';
8
8
  interface PropsType {
9
9
  value: JoinEnum;
10
10
  onChange: (type: JoinEnum) => void;
@@ -7,8 +7,9 @@
7
7
  * 4、排序模块
8
8
  */
9
9
  import './index.less';
10
- import { ColumnsPopupThemeEnum, SQL_COLUMN_TYPE } from '../../../../store/metabase/enum';
11
- import { MetaData_ColumnsType } from '../../../../store/metabase/types';
10
+ import { ColumnsPopupThemeEnum, SQL_COLUMN_TYPE } from '../../../store/enum';
11
+ import { MetaData_ColumnsType } from '../../../store/types';
12
+ import { DatasourceType } from '../../../types';
12
13
  export declare const DATE_GROUP_MAP: Map<string, string>;
13
14
  export declare const NUMBER_GROUP_MAP: Map<string, string>;
14
15
  export interface ColumnType {
@@ -22,20 +23,23 @@ export interface ColumnGroupType {
22
23
  condition: string;
23
24
  quotes: string;
24
25
  }
25
- export interface DataType {
26
+ export type DataType = Partial<DatasourceType> & {
26
27
  table: string;
27
28
  alias: string;
28
29
  columns: MetaData_ColumnsType[];
29
- }
30
+ };
30
31
  interface PropsType {
31
32
  data: DataType[];
32
33
  value: ColumnType & Partial<ColumnGroupType>;
33
34
  theme: ColumnsPopupThemeEnum;
34
35
  isGroup?: boolean;
35
- onSelect?: (record: ColumnType) => void;
36
- onGroup?: (record: ColumnType & ColumnGroupType) => void;
36
+ onSelect?: (record: ColumnType & DatasourceType & {
37
+ realName: string;
38
+ }) => void;
39
+ onGroup?: (record: ColumnType & ColumnGroupType & {
40
+ realName?: string;
41
+ }) => void;
37
42
  didUpdate?: Function;
38
- setPopupClosable?: Function;
39
43
  }
40
- declare const SelectJoinColumn: ({ data, value, theme, onSelect, isGroup, onGroup, didUpdate, setPopupClosable, }: PropsType) => import("react/jsx-runtime").JSX.Element;
41
- export default SelectJoinColumn;
44
+ declare const _default: ({ data, value, theme, onSelect, isGroup, onGroup, didUpdate, }: PropsType) => import("react/jsx-runtime").JSX.Element;
45
+ export default _default;
@@ -0,0 +1,15 @@
1
+ /**
2
+ * 选择表弹框
3
+ * 谁在用?
4
+ * 1、选择权限表
5
+ */
6
+ import './index.less';
7
+ import { MetaData_TableType } from '../../../store/types';
8
+ interface PropsType {
9
+ data: MetaData_TableType[];
10
+ value: MetaData_TableType;
11
+ onChange: (reocrd: MetaData_TableType) => void;
12
+ didUpdate?: Function;
13
+ }
14
+ declare const _default: ({ data, value, onChange, didUpdate }: PropsType) => import("react/jsx-runtime").JSX.Element;
15
+ export default _default;
@@ -2,7 +2,7 @@
2
2
  * 关联模块 选择表字段
3
3
  */
4
4
  import './index.less';
5
- import { DataType, ColumnType } from '../../../../metaBase/components/dialog/select-join-column';
5
+ import { DataType, ColumnType } from '../select-join-column';
6
6
  export type ValueType = Partial<ColumnType> & {
7
7
  condition: string;
8
8
  quotes: string;
@@ -12,7 +12,6 @@ interface PropsType {
12
12
  value: ValueType;
13
13
  onChange: (reocrd: ValueType) => void;
14
14
  didUpdate?: Function;
15
- setPopupClosable?: Function;
16
15
  }
17
- declare const SelectSummarize: ({ data, value, onChange, didUpdate, setPopupClosable }: PropsType) => import("react/jsx-runtime").JSX.Element;
16
+ declare const SelectSummarize: ({ data, value, onChange, didUpdate }: PropsType) => import("react/jsx-runtime").JSX.Element;
18
17
  export default SelectSummarize;
@@ -0,0 +1,17 @@
1
+ /**
2
+ * 选择表弹框
3
+ * 谁在用?
4
+ * 1、数据模块
5
+ * 2、关联模块
6
+ */
7
+ import './index.less';
8
+ import { MetaData_TableType } from '../../../store/types';
9
+ import { DatasourceType } from '../../../types';
10
+ interface PropsType {
11
+ data: DatasourceType[];
12
+ value: MetaData_TableType;
13
+ onChange: (reocrd: MetaData_TableType) => void;
14
+ didUpdate?: Function;
15
+ }
16
+ declare const _default: ({ data, value, onChange, didUpdate }: PropsType) => import("react/jsx-runtime").JSX.Element;
17
+ export default _default;
@@ -7,6 +7,7 @@ export declare const CloseIcon2: (reset: any) => import("react/jsx-runtime").JSX
7
7
  export declare const FilterIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
8
8
  export declare const SummarizeIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
9
9
  export declare const JoinDataIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
10
+ export declare const PermissionTableIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
10
11
  export declare const CustomColumnIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
11
12
  export declare const SortIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
12
13
  export declare const RowLimitIcon: ({ width, height }: IconProps) => import("react/jsx-runtime").JSX.Element;
@@ -29,4 +30,5 @@ export declare const UpArrowIcon2: () => import("react/jsx-runtime").JSX.Element
29
30
  export declare const DownArrowIcon2: () => import("react/jsx-runtime").JSX.Element;
30
31
  export declare const LeftArrowIcon: () => import("react/jsx-runtime").JSX.Element;
31
32
  export declare const RightArrowIcon: () => import("react/jsx-runtime").JSX.Element;
33
+ export declare const DataSourceIcon: () => import("react/jsx-runtime").JSX.Element;
32
34
  export {};
@@ -0,0 +1,4 @@
1
+ import './index.less';
2
+ import type { MetabaseProps } from '../../types';
3
+ declare const Metabase: (props: MetabaseProps) => import("react/jsx-runtime").JSX.Element;
4
+ export default Metabase;
@@ -0,0 +1,6 @@
1
+ import { MetaListType } from '../../../store/types';
2
+ interface PropsType {
3
+ meta: MetaListType;
4
+ }
5
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element | null;
6
+ export default _default;
@@ -0,0 +1,7 @@
1
+ import { MetaCustom } from '../../store/types';
2
+ interface PropsType {
3
+ store?: any;
4
+ meta: MetaCustom;
5
+ }
6
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
7
+ export default _default;
@@ -0,0 +1,6 @@
1
+ import { MetaFilter } from '../../store/types';
2
+ interface PropsType {
3
+ meta: MetaFilter;
4
+ }
5
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
6
+ export default _default;
@@ -0,0 +1,4 @@
1
+ import { TypeEnum } from '../../store/enum';
2
+ type ModuleComponent = React.ComponentType<any>;
3
+ declare const _default: Map<TypeEnum, ModuleComponent>;
4
+ export default _default;
@@ -0,0 +1,6 @@
1
+ import { MetaJoin } from '../../store/types';
2
+ interface PropsType {
3
+ meta: MetaJoin;
4
+ }
5
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
6
+ export default _default;
@@ -0,0 +1,6 @@
1
+ import { MetaData } from '../../store/types';
2
+ interface PropsType {
3
+ meta: MetaData;
4
+ }
5
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
6
+ export default _default;
@@ -0,0 +1,6 @@
1
+ interface PropsType {
2
+ store?: any;
3
+ meta: any;
4
+ }
5
+ declare const RowLimit: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
6
+ export default RowLimit;
@@ -0,0 +1,6 @@
1
+ import { MetaSort } from '../../store/types';
2
+ interface PropsType {
3
+ meta: MetaSort;
4
+ }
5
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
6
+ export default _default;
@@ -0,0 +1,11 @@
1
+ import { MetaSummarize } from '../../../store/types';
2
+ import { ColumnType } from '../../dialog/select-join-column';
3
+ export type ValueType = ColumnType & {
4
+ condition: string;
5
+ quotes: string;
6
+ };
7
+ interface PropsType {
8
+ meta: MetaSummarize;
9
+ }
10
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
11
+ export default _default;
@@ -0,0 +1,7 @@
1
+ import { MetaSummarize } from '../../../store/types';
2
+ interface PropsType {
3
+ store?: any;
4
+ meta: MetaSummarize;
5
+ }
6
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
7
+ export default _default;
@@ -0,0 +1,7 @@
1
+ import { MetaSummarize } from '../../../store/types';
2
+ interface PropsType {
3
+ store?: any;
4
+ meta: MetaSummarize;
5
+ }
6
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
7
+ export default _default;
@@ -0,0 +1,6 @@
1
+ import { MetaData } from '../../store/types';
2
+ interface PropsType {
3
+ meta: MetaData;
4
+ }
5
+ declare const _default: (props: PropsType) => import("react/jsx-runtime").JSX.Element;
6
+ export default _default;
@@ -0,0 +1,15 @@
1
+ export declare const ThemeEnum: {
2
+ dark: string;
3
+ light: string;
4
+ };
5
+ export declare const GraphTypeEnum: {
6
+ workflow: string;
7
+ bpmFlow: string;
8
+ };
9
+ export declare enum ApiStatus {
10
+ FIRST_OPEN = "first_open",
11
+ LOADING = "loading",
12
+ ERROR = "error",
13
+ NO_DATA = "no_data",
14
+ SUCCESS = "success"
15
+ }
@@ -0,0 +1 @@
1
+ export declare const EditorVar: {};
@@ -0,0 +1 @@
1
+ export declare const THEME = "THEME";
@@ -0,0 +1,4 @@
1
+ export declare const useWinSize: () => {
2
+ width: number;
3
+ height: number;
4
+ };
package/lib/es/index.d.ts CHANGED
@@ -1,2 +1,4 @@
1
- export { default as MetaBase } from './metaBase';
2
- export { type MetaBaseProps, type MetaData_ColumnsType } from './metaBase';
1
+ export { default as Metabase } from './metabase';
2
+ export * from './types';
3
+ export * from './store/types';
4
+ export * from './store/helper';