@dazhicheng/ui 1.4.23 → 1.5.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 (35) hide show
  1. package/dist/components/tt-drawer/index.d.ts +3703 -0
  2. package/dist/components/tt-drawer/src/RenderDrawer.vue.d.ts +2121 -0
  3. package/dist/components/tt-drawer/src/components/DrawerFooter.vue.d.ts +94 -0
  4. package/dist/components/tt-drawer/src/components/DrawerHeader.vue.d.ts +27 -0
  5. package/dist/components/tt-drawer/src/hooks/useDrawerRender.d.ts +10 -0
  6. package/dist/components/tt-drawer/src/hooks/useResizable.d.ts +9 -0
  7. package/dist/components/tt-drawer/src/index.d.ts +10 -0
  8. package/dist/components/tt-drawer/src/props.d.ts +99 -0
  9. package/dist/components/tt-drawer/src/typing.d.ts +154 -0
  10. package/dist/components/tt-drawer/src/utils/drawer-api.d.ts +87 -0
  11. package/dist/components/tt-form/src/types.d.ts +2 -1
  12. package/dist/components/tt-modal/index.d.ts +112 -111
  13. package/dist/components/tt-modal/src/RenderModal.vue.d.ts +57 -57
  14. package/dist/components/tt-modal/src/components/ModalFooter.vue.d.ts +5 -5
  15. package/dist/components/tt-modal/src/components/ModalWrapper.vue.d.ts +5 -5
  16. package/dist/components/tt-modal/src/hooks/useModalRender.d.ts +22 -20
  17. package/dist/components/tt-modal/src/index.d.ts +5 -6
  18. package/dist/components/tt-modal/src/typing.d.ts +5 -5
  19. package/dist/components/tt-select/index.d.ts +2 -3
  20. package/dist/components/tt-select/src/Select.vue.d.ts +71 -71
  21. package/dist/components/tt-select/src/components/SelectTable.vue.d.ts +8 -8
  22. package/dist/components/tt-select/src/components/Table.vue.d.ts +12 -12
  23. package/dist/components/tt-select/src/hooks/useDataSource.d.ts +8 -8
  24. package/dist/components/tt-select/src/hooks/useGrid.d.ts +2 -2
  25. package/dist/components/tt-select/src/hooks/useKeyboard.d.ts +3 -3
  26. package/dist/components/tt-select/src/hooks/useSelect.d.ts +7 -7
  27. package/dist/components/tt-select/src/hooks/useSelectTableEvent.d.ts +16 -16
  28. package/dist/components/tt-select/src/props.d.ts +14 -14
  29. package/dist/components/tt-select/src/types/index.d.ts +15 -15
  30. package/dist/components/tt-table/src/Table.vue.d.ts +11 -11
  31. package/dist/components/tt-table/src/components/TableToobalTools.vue.d.ts +2 -2
  32. package/dist/index.d.ts +1 -0
  33. package/dist/index.js +8821 -8094
  34. package/dist/style.css +1 -1
  35. package/package.json +3 -3
@@ -1,7 +1,7 @@
1
1
  import { ElSelect } from 'element-plus';
2
2
  import { ComputedRef, Ref } from 'vue';
3
- import { SjzySelectV2Props } from '../props';
4
- import { SjzySelectKeyboardType, SjzySelectSelectOptions, SjzySelectV2DataOptions } from '../types';
3
+ import { TtSelectProps } from '../props';
4
+ import { TtSelectKeyboardType, TtSelectSelectOptions, TtSelectDataOptions } from '../types';
5
5
  /**
6
6
  * 定义选项类型,包含选择器的各种配置和方法
7
7
  */
@@ -13,7 +13,7 @@ type OptType = {
13
13
  /**
14
14
  * 选中的选项
15
15
  */
16
- selectOption: Ref<SjzySelectSelectOptions>;
16
+ selectOption: Ref<TtSelectSelectOptions>;
17
17
  /**
18
18
  * 选择器实例引用
19
19
  */
@@ -41,11 +41,11 @@ type OptType = {
41
41
  /**
42
42
  * 选项列表
43
43
  */
44
- options: Ref<SjzySelectV2DataOptions[]>;
44
+ options: Ref<TtSelectDataOptions[]>;
45
45
  /**
46
46
  * 数据列表
47
47
  */
48
- dataList: Ref<SjzySelectV2DataOptions[]>;
48
+ dataList: Ref<TtSelectDataOptions[]>;
49
49
  /**
50
50
  * 搜索字段
51
51
  */
@@ -63,7 +63,7 @@ type OptType = {
63
63
  /**
64
64
  * 获取键盘事件处理函数的方法
65
65
  */
66
- getKeyboardEvent: () => Record<SjzySelectKeyboardType, Fn>;
66
+ getKeyboardEvent: () => Record<TtSelectKeyboardType, Fn>;
67
67
  /**
68
68
  * 设置活动索引的方法
69
69
  */
@@ -75,7 +75,7 @@ type OptType = {
75
75
  * @param opt - 选项配置
76
76
  * @returns 包含选择器属性、计算最大折叠标签数和计算选择器宽度的对象
77
77
  */
78
- export declare function useSelect(props: ComputedRef<SjzySelectV2Props["selectProps"]>, opt: OptType): {
78
+ export declare function useSelect(props: ComputedRef<TtSelectProps["selectProps"]>, opt: OptType): {
79
79
  getOtherSelectProps: ComputedRef<Partial<Omit<import('element-plus').SelectProps, "modelValue">>>;
80
80
  calcMaxCollapseTags: () => void;
81
81
  calcSelectWidth: ComputedRef<string>;
@@ -1,8 +1,8 @@
1
1
  import { ElSelect } from 'element-plus';
2
2
  import { ComputedRef, MaybeRef, Ref } from 'vue';
3
3
  import { VxeGridDefines, VxeGridPropTypes } from 'vxe-table';
4
- import { SjzySelectV2Props } from '../props';
5
- import { SjzySelectModelUnionType, SjzySelectModelValueType, SjzySelectSelectOptions, SjzySelectV2DataOptions } from '../types';
4
+ import { TtSelectProps } from '../props';
5
+ import { TtSelectModelUnionType, TtSelectModelValueType, TtSelectSelectOptions, TtSelectDataOptions } from '../types';
6
6
  import { default as SelectTable } from './components/SelectTable.vue';
7
7
  /**
8
8
  * 定义选项类型,包含表格、选择器、数据、分页等相关的引用和方法
@@ -19,21 +19,21 @@ type OptType = {
19
19
  /**
20
20
  * 选择器选中的值
21
21
  */
22
- selectValue: Ref<SjzySelectModelValueType>;
22
+ selectValue: Ref<TtSelectModelValueType>;
23
23
  /**
24
24
  * 设置选择器选中的值
25
25
  * @param val 选中的值
26
26
  * @param opt 选中的选项
27
27
  */
28
- setSelectValue: (val: SjzySelectModelValueType, opt?: SjzySelectSelectOptions, isEmitChange?: boolean) => void;
28
+ setSelectValue: (val: TtSelectModelValueType, opt?: TtSelectSelectOptions, isEmitChange?: boolean) => void;
29
29
  /**
30
30
  * 选项列表
31
31
  */
32
- options: Ref<SjzySelectV2DataOptions[]>;
32
+ options: Ref<TtSelectDataOptions[]>;
33
33
  /**
34
34
  * 选中的选项
35
35
  */
36
- selectOption: Ref<SjzySelectSelectOptions>;
36
+ selectOption: Ref<TtSelectSelectOptions>;
37
37
  /**
38
38
  * 是否多选
39
39
  */
@@ -106,13 +106,13 @@ type OptType = {
106
106
  getIsSelectFirstOption: ComputedRef<boolean | undefined>;
107
107
  };
108
108
  type EmitType = {
109
- (e: 'visible-change', visible: boolean): void;
110
- (e: 'scroll', event: VxeGridDefines.ScrollEventParams): void;
111
- (e: 'scroll-boundary', event: VxeGridDefines.ScrollBoundaryEventParams): void;
112
- (e: 'focus'): void;
113
- (e: 'blur'): void;
114
- (e: 'clear'): void;
115
- (e: 'remove-tag', tagValue: SjzySelectModelUnionType): void;
109
+ (e: "visible-change", visible: boolean): void;
110
+ (e: "scroll", event: VxeGridDefines.ScrollEventParams): void;
111
+ (e: "scroll-boundary", event: VxeGridDefines.ScrollBoundaryEventParams): void;
112
+ (e: "focus"): void;
113
+ (e: "blur"): void;
114
+ (e: "clear"): void;
115
+ (e: "remove-tag", tagValue: TtSelectModelUnionType): void;
116
116
  };
117
117
  /**
118
118
  * 用于处理选择表格事件的钩子函数
@@ -120,7 +120,7 @@ type EmitType = {
120
120
  * @param opt 选项配置
121
121
  * @returns 包含表格事件、选择器事件和键盘事件的对象
122
122
  */
123
- export declare function useSelectTableEvent(props: ComputedRef<SjzySelectV2Props>, opt: OptType, emit: EmitType): {
123
+ export declare function useSelectTableEvent(props: ComputedRef<TtSelectProps>, opt: OptType, emit: EmitType): {
124
124
  gridEvent: {
125
125
  /**
126
126
  * 单选框改变事件处理函数
@@ -160,13 +160,13 @@ export declare function useSelectTableEvent(props: ComputedRef<SjzySelectV2Props
160
160
  * beforeChangeCheck(val, row):val 为当前操作的值,row 为当前操作的响应式对象
161
161
  * @param val 选中的选项(el-select 的 v-model:单选为对象,多选为对象数组)
162
162
  */
163
- change: (val: SjzySelectSelectOptions) => Promise<void>;
163
+ change: (val: TtSelectSelectOptions) => Promise<void>;
164
164
  /**
165
165
  * 选择器键盘按下捕获事件处理函数
166
166
  * @param event 键盘事件对象
167
167
  */
168
168
  keydownCapture: (event: KeyboardEvent) => void;
169
- removeTag: (tagValue: SjzySelectModelUnionType) => void;
169
+ removeTag: (tagValue: TtSelectModelUnionType) => void;
170
170
  };
171
171
  keyboardEvent: {
172
172
  ArrowUp: () => void;
@@ -2,9 +2,9 @@ import { TipConfig } from '../../../directives/disabled-tip';
2
2
  import { SelectProps } from 'element-plus';
3
3
  import { ExtractPropTypes, PropType } from 'vue';
4
4
  import { VxeGridProps } from 'vxe-table';
5
- import { SjzySelectModelUnionType, SjzySelectModelValueType, SjzySelectV2ConfigProps, SjzySelectV2DataOptions } from './types';
6
- export declare const configDefault: SjzySelectV2ConfigProps;
7
- export type SjzySelectGridProps = VxeGridProps & {
5
+ import { TtSelectModelUnionType, TtSelectModelValueType, TtSelectConfigProps, TtSelectDataOptions } from './types';
6
+ export declare const configDefault: TtSelectConfigProps;
7
+ export type TtSelectGridProps = VxeGridProps & {
8
8
  /** 是否展示checkbox */
9
9
  showCheckbox?: boolean;
10
10
  };
@@ -13,7 +13,7 @@ export declare const selectProps: {
13
13
  * 绑定值
14
14
  */
15
15
  modelValue: {
16
- type: PropType<SjzySelectModelValueType>;
16
+ type: PropType<TtSelectModelValueType>;
17
17
  default: undefined;
18
18
  };
19
19
  /**
@@ -27,7 +27,7 @@ export declare const selectProps: {
27
27
  * vxe-grid 的Props
28
28
  */
29
29
  gridProps: {
30
- type: PropType<SjzySelectGridProps>;
30
+ type: PropType<TtSelectGridProps>;
31
31
  default: () => {};
32
32
  };
33
33
  /**
@@ -43,8 +43,8 @@ export declare const selectProps: {
43
43
  };
44
44
  /** 数据相关的配置 */
45
45
  configProps: {
46
- type: PropType<SjzySelectV2ConfigProps>;
47
- default: () => SjzySelectV2ConfigProps;
46
+ type: PropType<TtSelectConfigProps>;
47
+ default: () => TtSelectConfigProps;
48
48
  };
49
49
  extra: {
50
50
  type: PropType<Record<string, any>>;
@@ -58,7 +58,7 @@ export declare const selectProps: {
58
58
  * @returns 是否改变
59
59
  */
60
60
  beforeChange: {
61
- type: PropType<(val: SjzySelectModelUnionType, oVal: SjzySelectModelUnionType, option?: SjzySelectV2DataOptions) => Promise<boolean>>;
61
+ type: PropType<(val: TtSelectModelUnionType, oVal: TtSelectModelUnionType, option?: TtSelectDataOptions) => Promise<boolean>>;
62
62
  default: null;
63
63
  };
64
64
  /** 是否加载 */
@@ -99,16 +99,16 @@ export declare const selectProps: {
99
99
  default: boolean;
100
100
  };
101
101
  };
102
- export type SjzySelectV2Props = ExtractPropTypes<typeof selectProps>;
102
+ export type TtSelectProps = ExtractPropTypes<typeof selectProps>;
103
103
  export declare const selectTableProps: {
104
104
  /** configProps */
105
105
  configProps: {
106
- type: PropType<SjzySelectV2Props["configProps"]>;
106
+ type: PropType<TtSelectProps["configProps"]>;
107
107
  default: () => {};
108
108
  };
109
109
  /** 表格的参数 */
110
110
  grid: {
111
- type: PropType<SjzySelectV2Props["gridProps"]>;
111
+ type: PropType<TtSelectProps["gridProps"]>;
112
112
  default: () => {};
113
113
  };
114
114
  /** 数据源 */
@@ -138,12 +138,12 @@ export declare const selectTableProps: {
138
138
  };
139
139
  /** 禁用的方法 */
140
140
  disableFn: {
141
- type: PropType<SjzySelectV2ConfigProps["disableFn"]>;
141
+ type: PropType<TtSelectConfigProps["disableFn"]>;
142
142
  default: null;
143
143
  };
144
144
  /** 选中的值 */
145
145
  selectValue: {
146
- type: PropType<SjzySelectModelValueType>;
146
+ type: PropType<TtSelectModelValueType>;
147
147
  default: () => never[];
148
148
  };
149
149
  /** 下拉框的宽度 */
@@ -187,4 +187,4 @@ export declare const selectTableProps: {
187
187
  default: number;
188
188
  };
189
189
  };
190
- export type SjzySelectV2TableProps = ExtractPropTypes<typeof selectTableProps>;
190
+ export type TtSelectTableProps = ExtractPropTypes<typeof selectTableProps>;
@@ -1,9 +1,9 @@
1
1
  import { MaybeRef, Ref } from 'vue';
2
2
  /**
3
- * 定义 SjzySelectV2 组件的数据选项类型
3
+ * 定义 TtSelect 组件的数据选项类型
4
4
  * 该类型包含了每个选项的基本信息,如标签、值、原始数据项等
5
5
  */
6
- export type SjzySelectV2DataOptions = {
6
+ export type TtSelectDataOptions = {
7
7
  label?: string;
8
8
  value?: any;
9
9
  item?: Record<string, any>;
@@ -12,32 +12,32 @@ export type SjzySelectV2DataOptions = {
12
12
  [key: string]: any;
13
13
  };
14
14
  /**
15
- * 定义 SjzySelectV2 组件的选中选项类型
15
+ * 定义 TtSelect 组件的选中选项类型
16
16
  * 该类型可以是单个选项、选项数组或未定义
17
17
  */
18
- export type SjzySelectSelectOptions = SjzySelectV2DataOptions[] | SjzySelectV2DataOptions | undefined;
18
+ export type TtSelectSelectOptions = TtSelectDataOptions[] | TtSelectDataOptions | undefined;
19
19
  /**
20
- * 定义 SjzySelectV2 组件的模型值类型
20
+ * 定义 TtSelect 组件的模型值类型
21
21
  * 该类型可以是字符串、数字、字符串或数字的数组,也可以是 null 或未定义
22
22
  */
23
- export type SjzySelectModelValueType = string | number | boolean | (string | number | boolean)[] | null | undefined;
23
+ export type TtSelectModelValueType = string | number | boolean | (string | number | boolean)[] | null | undefined;
24
24
  /**
25
- * 定义 SjzySelectV2 组件的模型值联合类型
25
+ * 定义 TtSelect 组件的模型值联合类型
26
26
  * 该类型可以是选中选项类型或模型值类型
27
27
  */
28
- export type SjzySelectModelUnionType = SjzySelectSelectOptions | SjzySelectModelValueType;
28
+ export type TtSelectModelUnionType = TtSelectSelectOptions | TtSelectModelValueType;
29
29
  /**
30
- * 定义 SjzySelectV2 组件的键盘事件类型
30
+ * 定义 TtSelect 组件的键盘事件类型
31
31
  * 该类型包含了向上箭头、向下箭头和回车键三种键盘事件
32
32
  */
33
- export type SjzySelectKeyboardType = "ArrowUp" | "ArrowDown" | "Enter";
34
- export type SjzySelectV2ConfigProps = {
33
+ export type TtSelectKeyboardType = "ArrowUp" | "ArrowDown" | "Enter";
34
+ export type TtSelectConfigProps = {
35
35
  /** api */
36
36
  api?: (...arg: any[]) => Promise<any>;
37
37
  /** 是否分页 */
38
38
  isPage?: boolean;
39
39
  /** 数据 */
40
- data?: SjzySelectV2DataOptions[];
40
+ data?: TtSelectDataOptions[];
41
41
  /** 是否初始化加载数据 */
42
42
  immediate?: boolean;
43
43
  /** 请求后的回调 */
@@ -84,9 +84,9 @@ export type SjzySelectV2ConfigProps = {
84
84
  /** 监听额外参数的字段 */
85
85
  watchExtraField?: string[];
86
86
  /** 默认选中的数据 */
87
- defaultChecked?: SjzySelectV2DataOptions[] | SjzySelectV2DataOptions;
87
+ defaultChecked?: TtSelectDataOptions[] | TtSelectDataOptions;
88
88
  /** 禁用选项的方法 */
89
- disableFn?: (value: any, modelValue?: SjzySelectModelValueType, option?: SjzySelectV2DataOptions) => boolean;
89
+ disableFn?: (value: any, modelValue?: TtSelectModelValueType, option?: TtSelectDataOptions) => boolean;
90
90
  /**
91
91
  * 连接字符函数
92
92
  * @example (labels: string[]) => labels.join(',')
@@ -105,7 +105,7 @@ export type SjzySelectV2ConfigProps = {
105
105
  * 自定义选项
106
106
  * @example () => ({ label: '*', value: '*' })
107
107
  */
108
- customDefault?: SjzySelectV2DataOptions;
108
+ customDefault?: TtSelectDataOptions;
109
109
  /** 默认的数据,传递给接口的数据 */
110
110
  defaultData?: Record<string, any> | Ref<Record<string, any>>;
111
111
  /** 是否过滤空值 */
@@ -1085,17 +1085,6 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
1085
1085
  keyboardConfig: import("vxe-table").VxeTablePropTypes.KeyboardConfig<any>;
1086
1086
  emptyText: string;
1087
1087
  clearTreeExpand: any;
1088
- currentPageField: string;
1089
- pageSizeField: string;
1090
- totalField: string;
1091
- dataField: string;
1092
- tableRowId: string;
1093
- resultCode: string | number;
1094
- noSearchText: string;
1095
- useHttpCache: boolean;
1096
- showSetting: boolean;
1097
- showRefresh: boolean;
1098
- showLineHeight: boolean;
1099
1088
  showRadio: any;
1100
1089
  showIndex: any;
1101
1090
  isCellResize: any;
@@ -1120,16 +1109,26 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
1120
1109
  treeNode: any;
1121
1110
  isScrollFetch: boolean;
1122
1111
  showScrollFetchLoading: boolean;
1112
+ tableRowId: string;
1113
+ currentPageField: string;
1114
+ pageSizeField: string;
1115
+ totalField: string;
1116
+ dataField: string;
1123
1117
  showTitle: any;
1124
1118
  autoHeight: any;
1125
1119
  offsetHeight: any;
1120
+ noSearchText: string;
1126
1121
  emptyImageStyle: any;
1127
1122
  emptyImageStatus: "no-data" | "no-search";
1128
1123
  isHanderSubmit: any;
1129
1124
  columnsKey: any;
1125
+ showSetting: boolean;
1130
1126
  showSetColumn: boolean;
1131
1127
  leftSlotWidth: any;
1132
1128
  rightSlotWidth: any;
1129
+ showLineHeight: boolean;
1130
+ showRefresh: boolean;
1131
+ useHttpCache: boolean;
1133
1132
  defaultDisplayFields: string[];
1134
1133
  isI18n: any;
1135
1134
  isDataCloneDeep: any;
@@ -1138,6 +1137,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
1138
1137
  toolTipErrorPlacement: "top" | "bottom" | "left" | "right";
1139
1138
  isAreaCheckData: any;
1140
1139
  api: (...arg: any[]) => Promise<any>;
1140
+ resultCode: string | number;
1141
1141
  afterFetch: ((data: import("vxe-table").VxeTablePropTypes.Row[], res: globalThis.Recordable) => Promise<import("vxe-table").VxeTablePropTypes.Row[]>) | undefined;
1142
1142
  beforeFetch: ((params: globalThis.Recordable) => Promise<globalThis.Recordable>) | undefined;
1143
1143
  disabledTeleport: any;
@@ -816,11 +816,11 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
816
816
  "onOn-columns-setting"?: (() => any) | undefined;
817
817
  }>, {
818
818
  size: import('vxe-pc-ui').VxeComponentSizeType;
819
+ columnsKey: any;
819
820
  showSetting: boolean;
821
+ showSetColumn: boolean;
820
822
  showRefresh: boolean;
821
823
  useCache: boolean;
822
- columnsKey: any;
823
- showSetColumn: boolean;
824
824
  refreshIcon: string;
825
825
  columnIcon: string;
826
826
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
package/dist/index.d.ts CHANGED
@@ -3,6 +3,7 @@ import { BaseFormComponentType } from './components/tt-form';
3
3
  export * from './components/tt-area';
4
4
  export * from './components/tt-button';
5
5
  export * from './components/tt-checkbox';
6
+ export * from './components/tt-drawer';
6
7
  export * from './components/tt-empty';
7
8
  export * from './components/tt-icon';
8
9
  export * from './components/tt-modal';