@dazhicheng/ui 1.5.1 → 1.5.4

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 (46) hide show
  1. package/dist/components/tt-button/index.d.ts +476 -476
  2. package/dist/components/tt-button/index.vue.d.ts +272 -272
  3. package/dist/components/tt-checkbox/index.d.ts +5 -5
  4. package/dist/components/tt-checkbox/index.vue.d.ts +2 -2
  5. package/dist/components/tt-drawer/index.d.ts +540 -540
  6. package/dist/components/tt-drawer/src/RenderDrawer.vue.d.ts +297 -297
  7. package/dist/components/tt-form/src/form/RenderContent.vue.d.ts +2 -2
  8. package/dist/components/tt-form/src/form-render/dependencies.d.ts +118 -118
  9. package/dist/components/tt-form-item-error-tooltip/index.d.ts +196 -196
  10. package/dist/components/tt-form-item-error-tooltip/index.vue.d.ts +98 -98
  11. package/dist/components/tt-icon/index.d.ts +3 -3
  12. package/dist/components/tt-icon/index.vue.d.ts +1 -1
  13. package/dist/components/tt-image/index.d.ts +5 -5
  14. package/dist/components/tt-image/src/components/ImageViewer.d.ts +2 -2
  15. package/dist/components/tt-image/tt-image.d.ts +5 -5
  16. package/dist/components/tt-loading/index.d.ts +3 -3
  17. package/dist/components/tt-loading/src/loading.vue.d.ts +3 -3
  18. package/dist/components/tt-modal/index.d.ts +184 -184
  19. package/dist/components/tt-modal/src/RenderModal.vue.d.ts +101 -101
  20. package/dist/components/tt-modal/src/components/ModalWrapper.vue.d.ts +10 -10
  21. package/dist/components/tt-modal/src/hooks/useModalRender.d.ts +33 -33
  22. package/dist/components/tt-part/index.d.ts +12 -12
  23. package/dist/components/tt-part/index.vue.d.ts +4 -4
  24. package/dist/components/tt-select/src/Select.vue.d.ts +89 -89
  25. package/dist/components/tt-select/src/components/SelectTable.vue.d.ts +7 -7
  26. package/dist/components/tt-select/src/components/Table.vue.d.ts +9 -9
  27. package/dist/components/tt-table/src/Table.vue.d.ts +185 -179
  28. package/dist/components/tt-table/src/components/TableColumnModal.vue.d.ts +1 -1
  29. package/dist/components/tt-table/src/components/TableToobalTools.vue.d.ts +198 -228
  30. package/dist/components/tt-table/src/hooks/useCustomColumns.d.ts +1 -5
  31. package/dist/components/tt-table/src/hooks/useLeftRightSlot.d.ts +128 -128
  32. package/dist/components/tt-table/src/hooks/usePagination.d.ts +2 -2
  33. package/dist/components/tt-table/src/hooks/useTableRender.d.ts +7 -8
  34. package/dist/components/tt-table/src/props.d.ts +8 -5
  35. package/dist/components/tt-table/src/toolProps.d.ts +3 -21
  36. package/dist/components/tt-table/src/types/table.d.ts +8 -11
  37. package/dist/components/tt-table/src/types/tableTools.d.ts +2 -13
  38. package/dist/components/tt-text/index.d.ts +3 -3
  39. package/dist/components/tt-text/index.vue.d.ts +1 -1
  40. package/dist/components/tt-validate/src/Field.d.ts +4 -4
  41. package/dist/components/tt-validate/src/Form.d.ts +1 -1
  42. package/dist/components/tt-validate/src/utils/assertions.d.ts +1 -1
  43. package/dist/components/types.d.ts +10 -33
  44. package/dist/index.js +5942 -5976
  45. package/dist/style.css +1 -1
  46. package/package.json +1 -1
@@ -54,11 +54,9 @@ export declare function useTableRender(options: TtTableProps): readonly [DefineS
54
54
  isHanderSubmit?: boolean;
55
55
  modelValue?: Array<Recordable>;
56
56
  formApi?: Partial<import('../../../tt-form').TtExtendedFormApi>;
57
- columnsKey?: string;
57
+ columnsKey?: string | (() => string);
58
58
  showSetting?: boolean;
59
59
  showSetColumn?: boolean;
60
- showFullScreen?: boolean;
61
- fullscreen?: boolean;
62
60
  leftSlotWidth?: number;
63
61
  rightSlotWidth?: number;
64
62
  showLineHeight?: boolean;
@@ -66,20 +64,21 @@ export declare function useTableRender(options: TtTableProps): readonly [DefineS
66
64
  useHttpCache?: boolean;
67
65
  defaultDisplayFields?: string[];
68
66
  getColumnsApi?: (params: {
69
- columnsKey: string;
67
+ permissionOnlyCode: string;
70
68
  userId: string | number;
71
69
  }) => Promise<{
72
70
  data: any;
73
71
  }>;
74
72
  setColumnsApi?: (params: {
75
- columnKey: string;
76
- columns: string[];
73
+ permissionOnlyCode: string;
74
+ json: string;
77
75
  userId: string | number;
78
76
  }) => Promise<any>;
79
77
  updateColumnsApi?: (params: {
80
- columnKey: string;
81
- columns: string[];
78
+ permissionOnlyCode: string;
79
+ json: string;
82
80
  userId: string | number;
81
+ id: string | number;
83
82
  }) => Promise<any>;
84
83
  getSyncSlotComponent?: (column: any, row: any, type: "default" | "edit") => import('vue').VNode | import('vue').VNode[] | string;
85
84
  customizeColumn?: (column: import("vxe-table").VxeTableDefines.ColumnOptions) => import("vxe-table").VxeTableDefines.ColumnOptions;
@@ -30,7 +30,7 @@ export declare const tableProps: {
30
30
  /** 是否显示自定义行距 */
31
31
  showLineHeight: {
32
32
  type: BooleanConstructor;
33
- default: () => boolean | undefined;
33
+ default: () => any;
34
34
  };
35
35
  /** 不可自定义列数组 field数组 */
36
36
  notSetColumnField: any;
@@ -55,7 +55,7 @@ export declare const tableProps: {
55
55
  * @deprecated
56
56
  */
57
57
  resultCode: {
58
- type: (NumberConstructor | StringConstructor)[];
58
+ type: (StringConstructor | NumberConstructor)[];
59
59
  default: number;
60
60
  };
61
61
  /** 请求后的回调 */
@@ -214,8 +214,11 @@ export declare const tableProps: {
214
214
  };
215
215
  /** 是否手动触发查询事件 */
216
216
  isHanderSubmit: any;
217
- /** 储存的key */
218
- columnsKey: any;
217
+ /** 储存的key值,支持函数动态获取 */
218
+ columnsKey: {
219
+ type: PropType<string | (() => string)>;
220
+ default: string;
221
+ };
219
222
  /** 是否开启服务端缓存 */
220
223
  useHttpCache: {
221
224
  type: BooleanConstructor;
@@ -382,7 +385,7 @@ export declare const tableOtherProps: {
382
385
  * 表格的高度;支持铺满父容器或者固定高度,如果设置 auto 为铺满父容器(如果设置为 auto,则必须确保存在父节点且不允许存在相邻元素)
383
386
  */
384
387
  height: {
385
- type: (NumberConstructor | StringConstructor)[];
388
+ type: (StringConstructor | NumberConstructor)[];
386
389
  default: undefined;
387
390
  };
388
391
  /**
@@ -1,11 +1,5 @@
1
1
  import { PropType } from 'vue';
2
- import { VxeGridPropTypes } from 'vxe-table';
3
2
  export declare const toolProps: {
4
- /** 表格的size */
5
- size: {
6
- type: PropType<VxeGridPropTypes.Size>;
7
- default: () => import('vxe-pc-ui').VxeComponentSizeType | undefined;
8
- };
9
3
  /** 是否显示设置 */
10
4
  showSetting: {
11
5
  type: BooleanConstructor;
@@ -21,21 +15,9 @@ export declare const toolProps: {
21
15
  type: BooleanConstructor;
22
16
  default: boolean;
23
17
  };
24
- /** 是否开启本地缓存 */
25
- useCache: {
26
- type: BooleanConstructor;
27
- default: boolean;
28
- };
29
- /** 储存的key */
30
- columnsKey: any;
31
- /** 刷新按钮icon */
32
- refreshIcon: {
33
- type: StringConstructor;
34
- default: string;
35
- };
36
- /** 列设置icon */
37
- columnIcon: {
38
- type: StringConstructor;
18
+ /** 储存的key,支持函数动态获取 */
19
+ columnsKey: {
20
+ type: PropType<string | (() => string)>;
39
21
  default: string;
40
22
  };
41
23
  };
@@ -151,8 +151,8 @@ export type TtTableProps = {
151
151
  modelValue?: Array<Recordable>;
152
152
  /** form-methods */
153
153
  formApi?: Partial<TtExtendedFormApi>;
154
- /** 储存的列key */
155
- columnsKey?: string;
154
+ /** 储存的列key值,支持函数动态获取 */
155
+ columnsKey?: string | (() => string);
156
156
  /**
157
157
  * 是否显示设置按钮icon
158
158
  * @default true
@@ -163,10 +163,6 @@ export type TtTableProps = {
163
163
  * @default true
164
164
  */
165
165
  showSetColumn?: boolean;
166
- /** 是否显示全屏 */
167
- showFullScreen?: boolean;
168
- /** 是否全屏 */
169
- fullscreen?: boolean;
170
166
  /** 左侧插槽的宽度 */
171
167
  leftSlotWidth?: number;
172
168
  /** 右侧插槽的宽度 */
@@ -187,22 +183,23 @@ export type TtTableProps = {
187
183
  defaultDisplayFields?: string[];
188
184
  /** 自定义列服务端配置接口 - 获取 */
189
185
  getColumnsApi?: (params: {
190
- columnsKey: string;
186
+ permissionOnlyCode: string;
191
187
  userId: string | number;
192
188
  }) => Promise<{
193
189
  data: any;
194
190
  }>;
195
191
  /** 自定义列服务端配置接口 - 当没有id值得时候 */
196
192
  setColumnsApi?: (params: {
197
- columnKey: string;
198
- columns: string[];
193
+ permissionOnlyCode: string;
194
+ json: string;
199
195
  userId: string | number;
200
196
  }) => Promise<any>;
201
197
  /** 自定义列服务端配置接口 - 当有id值得时候 */
202
198
  updateColumnsApi?: (params: {
203
- columnKey: string;
204
- columns: string[];
199
+ permissionOnlyCode: string;
200
+ json: string;
205
201
  userId: string | number;
202
+ id: string | number;
206
203
  }) => Promise<any>;
207
204
  /** 外部插槽 */
208
205
  getSyncSlotComponent?: (column: any, row: any, type: "default" | "edit") => VNode | VNode[] | string;
@@ -1,6 +1,3 @@
1
- import { VxeGridPropTypes } from 'vxe-table';
2
- export type TtTableToolsRowHeightValue = string | number | boolean;
3
- export type TtTableToolsDisabledType = "export" | "import";
4
1
  export type TtTableToolsProps = {
5
2
  /** 是否显示设置 */
6
3
  showSetting?: boolean;
@@ -8,14 +5,6 @@ export type TtTableToolsProps = {
8
5
  showRefresh?: boolean;
9
6
  /** 是否显示列设置按钮 */
10
7
  showSetColumn?: boolean;
11
- /** 储存的key */
12
- columnsKey?: string;
13
- /** 是否开启本地缓存 */
14
- useCache?: boolean;
15
- /** 刷新按钮icon */
16
- refreshIcon?: string;
17
- /** 列设置icon */
18
- columnIcon?: string;
19
- /** 表格的size */
20
- size?: VxeGridPropTypes.Size;
8
+ /** 储存的key,支持函数动态获取 */
9
+ columnsKey?: string | (() => string);
21
10
  };
@@ -13,11 +13,11 @@ export declare const TtText: import('../../../../utils/src').SFCWithInstall<{
13
13
  }> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, import('vue').PublicProps, {
14
14
  placement: string;
15
15
  visible: boolean;
16
- copy: boolean;
17
16
  toolTip: boolean;
18
17
  toolTipLine: number;
19
18
  toolTipMaxWidth: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
20
19
  toolTipMaxHeight: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
20
+ copy: boolean;
21
21
  }, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, any, import('vue').ComponentProvideOptions, {
22
22
  P: {};
23
23
  B: {};
@@ -38,11 +38,11 @@ export declare const TtText: import('../../../../utils/src').SFCWithInstall<{
38
38
  }> & Readonly<{}>, {}, {}, {}, {}, {
39
39
  placement: string;
40
40
  visible: boolean;
41
- copy: boolean;
42
41
  toolTip: boolean;
43
42
  toolTipLine: number;
44
43
  toolTipMaxWidth: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
45
44
  toolTipMaxHeight: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
45
+ copy: boolean;
46
46
  }>;
47
47
  __isFragment?: never;
48
48
  __isTeleport?: never;
@@ -60,11 +60,11 @@ export declare const TtText: import('../../../../utils/src').SFCWithInstall<{
60
60
  }> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, {
61
61
  placement: string;
62
62
  visible: boolean;
63
- copy: boolean;
64
63
  toolTip: boolean;
65
64
  toolTipLine: number;
66
65
  toolTipMaxWidth: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
67
66
  toolTipMaxHeight: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
67
+ copy: boolean;
68
68
  }, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & (new () => {
69
69
  $slots: Readonly<{
70
70
  default: () => any;
@@ -35,11 +35,11 @@ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
35
35
  declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
36
36
  placement: string;
37
37
  visible: boolean;
38
- copy: boolean;
39
38
  toolTip: boolean;
40
39
  toolTipLine: number;
41
40
  toolTipMaxWidth: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
42
41
  toolTipMaxHeight: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800;
42
+ copy: boolean;
43
43
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
44
44
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
45
45
  export default _default;
@@ -35,7 +35,7 @@ declare const FieldImpl: import('vue').DefineComponent<import('vue').ExtractProp
35
35
  * @default undefined
36
36
  */
37
37
  as: {
38
- type: (ObjectConstructor | StringConstructor)[];
38
+ type: (StringConstructor | ObjectConstructor)[];
39
39
  default: undefined;
40
40
  };
41
41
  /**
@@ -222,7 +222,7 @@ declare const FieldImpl: import('vue').DefineComponent<import('vue').ExtractProp
222
222
  * @default undefined
223
223
  */
224
224
  as: {
225
- type: (ObjectConstructor | StringConstructor)[];
225
+ type: (StringConstructor | ObjectConstructor)[];
226
226
  default: undefined;
227
227
  };
228
228
  /**
@@ -393,10 +393,10 @@ declare const FieldImpl: import('vue').DefineComponent<import('vue').ExtractProp
393
393
  default: boolean;
394
394
  };
395
395
  }>> & Readonly<{}>, {
396
- label: string;
397
396
  modelValue: any;
398
- 'onUpdate:modelValue': ((e: any) => unknown) | undefined;
397
+ label: string;
399
398
  rules: RuleExpression<unknown>;
399
+ 'onUpdate:modelValue': ((e: any) => unknown) | undefined;
400
400
  modelModifiers: any;
401
401
  as: string | Record<string, any>;
402
402
  validateOnMount: boolean;
@@ -234,8 +234,8 @@ declare const FormImpl: import('vue').DefineComponent<import('vue').ExtractPropT
234
234
  default: string;
235
235
  };
236
236
  }>> & Readonly<{}>, {
237
- onSubmit: SubmissionHandler<GenericObject>;
238
237
  name: string;
238
+ onSubmit: SubmissionHandler<GenericObject>;
239
239
  initialValues: Record<string, any>;
240
240
  as: string | null;
241
241
  validateOnMount: boolean;
@@ -3,7 +3,7 @@ import { Locator } from '../types';
3
3
  export declare const isClient: boolean;
4
4
  export declare function isLocator(value: unknown): value is Locator;
5
5
  export declare function isStandardSchema(value: unknown): value is StandardSchemaV1;
6
- export declare function hasCheckedAttr(type: unknown): type is "checkbox" | "radio";
6
+ export declare function hasCheckedAttr(type: unknown): type is "radio" | "checkbox";
7
7
  export declare function isContainerValue(value: unknown): value is Record<string, unknown>;
8
8
  /**
9
9
  * True if the value is an empty object or array
@@ -9,23 +9,25 @@ export type TtUiGlobalConfig = {
9
9
  */
10
10
  userId?: string | number;
11
11
  table?: {
12
+ /** 自定义列服务端配置的key,支持函数动态获取 */
13
+ columnsKey?: string | (() => string);
12
14
  /** 自定义列服务端配置接口 - 获取 */
13
15
  getColumnsApi?: (params: {
14
- columnsKey: string;
16
+ permissionOnlyCode: string;
15
17
  userId: string | number;
16
18
  }) => Promise<{
17
19
  data: any;
18
20
  }>;
19
21
  /** 自定义列服务端配置接口 - 当没有id值得时候 */
20
22
  setColumnsApi?: (params: {
21
- columnKey: string;
22
- columns: string[];
23
+ permissionOnlyCode: string;
24
+ json: string;
23
25
  userId: string | number;
24
26
  }) => Promise<any>;
25
27
  /** 自定义列服务端配置接口 - 当有id值得时候 */
26
28
  updateColumnsApi?: (params: {
27
- columnKey: string;
28
- columns: string[];
29
+ permissionOnlyCode: string;
30
+ json: string;
29
31
  userId: string | number;
30
32
  }) => Promise<any>;
31
33
  /**
@@ -115,8 +117,10 @@ export type TtUiGlobalConfig = {
115
117
  radioConfig?: VxeTablePropTypes.RadioConfig;
116
118
  /** 表格的size */
117
119
  size?: VxeGridPropTypes.Size;
120
+ /** 表格边框 */
121
+ border?: "full" | "inner" | boolean;
118
122
  /**
119
- * 是否开启本地缓存
123
+ * 是否开启缓存
120
124
  * @default-false 不开启
121
125
  */
122
126
  useCache?: boolean;
@@ -130,42 +134,15 @@ export type TtUiGlobalConfig = {
130
134
  * @default-true 显示
131
135
  */
132
136
  showSetting?: boolean;
133
- /**
134
- * 是否显示自定义列
135
- * @default-true 显示
136
- * @deprecated 已弃用,使用 showSetColumn 替换
137
- */
138
- showCustomColumn?: boolean;
139
137
  /**
140
138
  * 是否显示自定义列
141
139
  * @default-true 显示
142
140
  */
143
141
  showSetColumn?: boolean;
144
- /**
145
- * 是否显示自定义行距
146
- * @default-true 显示
147
- */
148
- showLineHeight?: boolean;
149
- /**
150
- * 是否显示行边框设置
151
- * @default-false 不显示
152
- */
153
- showSetRowBorder?: boolean;
154
- /**
155
- * 是否显示行高设置
156
- * @default-true 显示
157
- */
158
- showSetRowHeight?: boolean;
159
142
  /** 自定义函数 */
160
143
  customizeColumn?: TtTableProps["customizeColumn"];
161
144
  /** 外部插槽 */
162
145
  getSyncSlotComponent?: TtTableProps["getSyncSlotComponent"];
163
- /**
164
- * 表格边框
165
- * @description 支持 full 完整边框,inner 内边框,不填默认 inner,true 完整边框,false 默认 inner
166
- * @default 'full'
167
- */
168
- border?: "full" | "inner" | boolean;
169
146
  /**
170
147
  * 表格斑马线
171
148
  * @default- false