zhihao-ui 1.2.12 → 1.2.13
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.
- package/dist/es/{BaseInfo-CX8jhSiU.js → BaseInfo-7jZU0u6I.js} +1 -1
- package/dist/es/{Button-Dayz-XVx.js → Button-B9P_SsZw.js} +2 -2
- package/dist/es/{DatePicker-vfIj425T.js → DatePicker-Cc2HzfbO.js} +22 -21
- package/dist/es/{DetailHeader-DrlhwY52.js → DetailHeader-DWSW65H4.js} +3 -3
- package/dist/es/{DetailSubTitle-QEEHnjR_.js → DetailSubTitle-BcmMobfK.js} +2 -2
- package/dist/es/{Dialog-CLQwwXs6.js → Dialog-CPGMb7bN.js} +7 -6
- package/dist/es/{DiyDataTable-CjU8lE1d.js → DiyDataTable-Dg2-p40F.js} +44 -40
- package/dist/es/{EditInfoPair-BAkhPrrp.js → EditInfoPair-DK6juMvt.js} +3 -3
- package/dist/es/{FileWrapper-WvZK7e6H.js → FileWrapper-DJK4gH30.js} +4 -4
- package/dist/es/{Grid-B8GjLkPJ.js → Grid-ChfF9Fgz.js} +1 -1
- package/dist/es/{InfoPair-CVRcV6zN.js → InfoPair-Ba3m95Ys.js} +3 -3
- package/dist/es/{Input-D3aG3Fqg.js → Input-nPdfvjre.js} +3 -3
- package/dist/es/{Loading-CJ0YVxxE.js → Loading-5GrMZQAf.js} +2 -2
- package/dist/es/{Map-CjPsc0XI.js → Map-Q8kvdbDZ.js} +3 -3
- package/dist/es/{MessageBox-CMjFYHiw.js → MessageBox-SFDDgn41.js} +2 -2
- package/dist/es/{MoneyInput-Ctz5oyHG.js → MoneyInput-DfIiKsPe.js} +5 -5
- package/dist/es/{PageHeadPanel-B13UDwTh.js → PageHeadPanel-BnA69dS-.js} +2 -2
- package/dist/es/Table-R_03lfSM.js +1111 -0
- package/dist/es/{ToolTips-ZGKTR5KG.js → ToolTips-BHQpNHPT.js} +3 -3
- package/dist/es/index.js +50 -47
- package/dist/es/{utils-DR-4CNcy.js → utils-BbabHGt0.js} +1 -1
- package/dist/es/{vendor-qv9XzgYI.js → vendor-CUDSGmu_.js} +13416 -11462
- package/dist/index.css +1 -1
- package/dist/types/components/DiyDataTable/DiyDataTable.vue.d.ts +12 -1
- package/dist/types/components/DiyDataTable/index.d.ts +9 -1
- package/dist/types/components/DiyDataTable/type.d.ts +2 -0
- package/dist/types/components/Table/components/ColSetting.vue.d.ts +41 -0
- package/dist/types/components/Table/components/SearchForm.vue.d.ts +57 -0
- package/dist/types/components/Table/components/SearchFormItem.vue.d.ts +32 -0
- package/dist/types/components/Table/components/TableColumn.vue.d.ts +17 -0
- package/dist/types/components/Table/components/tablePagination.vue.d.ts +21 -0
- package/dist/types/components/Table/hooks/useSelection.d.ts +17 -0
- package/dist/types/components/Table/hooks/useTable.d.ts +50 -0
- package/dist/types/components/Table/index.d.ts +2946 -0
- package/dist/types/components/Table/index.vue.d.ts +984 -0
- package/dist/types/components/Table/types.d.ts +78 -0
- package/dist/types/components/Table/utils.d.ts +55 -0
- package/dist/types/components/const.d.ts +4 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/umd/index.css +1 -1
- package/dist/umd/index.umd.cjs +33 -28
- package/package.json +1 -1
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import { DiyDataTableColumnItem, DiyDataType, DIY_DATA_TYPE } from './type';
|
|
2
2
|
|
|
3
|
-
declare
|
|
3
|
+
declare function __VLS_template(): Partial<Record<string, (_: {
|
|
4
|
+
row: any;
|
|
5
|
+
$index: any;
|
|
6
|
+
}) => any>>;
|
|
7
|
+
declare const __VLS_component: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
4
8
|
rawData: {
|
|
5
9
|
required: true;
|
|
6
10
|
type: import('vue').PropType<DiyDataType[]>;
|
|
@@ -41,6 +45,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
41
45
|
parser?: ((value: string) => string) | undefined;
|
|
42
46
|
varidate?: ((value: string | number | undefined) => true | string) | undefined;
|
|
43
47
|
fixed?: ("left" | "right") | undefined;
|
|
48
|
+
slot?: string | undefined;
|
|
44
49
|
}[];
|
|
45
50
|
} | undefined>;
|
|
46
51
|
/** 更新列配置数据 */
|
|
@@ -67,4 +72,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
67
72
|
maxRowLength: number;
|
|
68
73
|
maxColLength: number;
|
|
69
74
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
75
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
70
76
|
export default _default;
|
|
77
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
78
|
+
new (): {
|
|
79
|
+
$slots: S;
|
|
80
|
+
};
|
|
81
|
+
};
|
|
@@ -38,6 +38,7 @@ export declare const ZhDiyDataTable: {
|
|
|
38
38
|
parser?: ((value: string) => string) | undefined;
|
|
39
39
|
varidate?: ((value: string | number | undefined) => true | string) | undefined;
|
|
40
40
|
fixed?: ("left" | "right") | undefined;
|
|
41
|
+
slot?: string | undefined;
|
|
41
42
|
}[];
|
|
42
43
|
} | undefined>;
|
|
43
44
|
updateColumn: (index: number, column: import('./type').DiyDataTableColumnItem) => void;
|
|
@@ -91,6 +92,7 @@ export declare const ZhDiyDataTable: {
|
|
|
91
92
|
parser?: ((value: string) => string) | undefined;
|
|
92
93
|
varidate?: ((value: string | number | undefined) => true | string) | undefined;
|
|
93
94
|
fixed?: ("left" | "right") | undefined;
|
|
95
|
+
slot?: string | undefined;
|
|
94
96
|
}[];
|
|
95
97
|
} | undefined>;
|
|
96
98
|
updateColumn: (index: number, column: import('./type').DiyDataTableColumnItem) => void;
|
|
@@ -141,6 +143,7 @@ export declare const ZhDiyDataTable: {
|
|
|
141
143
|
parser?: ((value: string) => string) | undefined;
|
|
142
144
|
varidate?: ((value: string | number | undefined) => true | string) | undefined;
|
|
143
145
|
fixed?: ("left" | "right") | undefined;
|
|
146
|
+
slot?: string | undefined;
|
|
144
147
|
}[];
|
|
145
148
|
} | undefined>;
|
|
146
149
|
updateColumn: (index: number, column: import('./type').DiyDataTableColumnItem) => void;
|
|
@@ -148,5 +151,10 @@ export declare const ZhDiyDataTable: {
|
|
|
148
151
|
isEdit: boolean;
|
|
149
152
|
maxRowLength: number;
|
|
150
153
|
maxColLength: number;
|
|
151
|
-
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps &
|
|
154
|
+
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & (new () => {
|
|
155
|
+
$slots: Partial<Record<string, (_: {
|
|
156
|
+
row: any;
|
|
157
|
+
$index: any;
|
|
158
|
+
}) => any>>;
|
|
159
|
+
}) & import('vue').Plugin;
|
|
152
160
|
export * from './type';
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { ColumnProps } from '../types';
|
|
2
|
+
|
|
3
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
4
|
+
originTableColumns?: ColumnProps[];
|
|
5
|
+
}>, {
|
|
6
|
+
originTableColumns: () => never[];
|
|
7
|
+
}>>, {
|
|
8
|
+
openColSetting: (list: ColumnProps[]) => void;
|
|
9
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
10
|
+
submit: (...args: any[]) => void;
|
|
11
|
+
close: (...args: any[]) => void;
|
|
12
|
+
dragSort: (...args: any[]) => void;
|
|
13
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
14
|
+
originTableColumns?: ColumnProps[];
|
|
15
|
+
}>, {
|
|
16
|
+
originTableColumns: () => never[];
|
|
17
|
+
}>>> & Readonly<{
|
|
18
|
+
onSubmit?: ((...args: any[]) => any) | undefined;
|
|
19
|
+
onClose?: ((...args: any[]) => any) | undefined;
|
|
20
|
+
onDragSort?: ((...args: any[]) => any) | undefined;
|
|
21
|
+
}>, {
|
|
22
|
+
originTableColumns: ColumnProps[];
|
|
23
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
24
|
+
export default _default;
|
|
25
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
26
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
27
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
28
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
29
|
+
} : {
|
|
30
|
+
type: import('vue').PropType<T[K]>;
|
|
31
|
+
required: true;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
type __VLS_WithDefaults<P, D> = {
|
|
35
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
36
|
+
default: D[K];
|
|
37
|
+
}> : P[K];
|
|
38
|
+
};
|
|
39
|
+
type __VLS_Prettify<T> = {
|
|
40
|
+
[K in keyof T]: T[K];
|
|
41
|
+
} & {};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { ColumnProps } from '../types';
|
|
2
|
+
|
|
3
|
+
interface ProTableProps {
|
|
4
|
+
columns?: ColumnProps[];
|
|
5
|
+
searchParam?: {
|
|
6
|
+
[key: string]: any;
|
|
7
|
+
};
|
|
8
|
+
search: (...params: any[]) => void;
|
|
9
|
+
reset: (params: any) => void;
|
|
10
|
+
isShowResetBtn?: boolean;
|
|
11
|
+
isShowSearchBtn?: boolean;
|
|
12
|
+
}
|
|
13
|
+
declare function __VLS_template(): {
|
|
14
|
+
default?(_: {}): any;
|
|
15
|
+
};
|
|
16
|
+
declare const __VLS_component: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ProTableProps>, {
|
|
17
|
+
columns: () => never[];
|
|
18
|
+
searchParam: () => {};
|
|
19
|
+
isShowResetBtn: boolean;
|
|
20
|
+
isShowSearchBtn: boolean;
|
|
21
|
+
}>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ProTableProps>, {
|
|
22
|
+
columns: () => never[];
|
|
23
|
+
searchParam: () => {};
|
|
24
|
+
isShowResetBtn: boolean;
|
|
25
|
+
isShowSearchBtn: boolean;
|
|
26
|
+
}>>> & Readonly<{}>, {
|
|
27
|
+
columns: ColumnProps[];
|
|
28
|
+
searchParam: {
|
|
29
|
+
[key: string]: any;
|
|
30
|
+
};
|
|
31
|
+
isShowSearchBtn: boolean;
|
|
32
|
+
isShowResetBtn: boolean;
|
|
33
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
34
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
35
|
+
export default _default;
|
|
36
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
37
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
38
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
39
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
40
|
+
} : {
|
|
41
|
+
type: import('vue').PropType<T[K]>;
|
|
42
|
+
required: true;
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
type __VLS_WithDefaults<P, D> = {
|
|
46
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
47
|
+
default: D[K];
|
|
48
|
+
}> : P[K];
|
|
49
|
+
};
|
|
50
|
+
type __VLS_Prettify<T> = {
|
|
51
|
+
[K in keyof T]: T[K];
|
|
52
|
+
} & {};
|
|
53
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
54
|
+
new (): {
|
|
55
|
+
$slots: S;
|
|
56
|
+
};
|
|
57
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { ColumnProps } from '../types';
|
|
2
|
+
|
|
3
|
+
interface SearchFormItem {
|
|
4
|
+
column: ColumnProps;
|
|
5
|
+
searchParam: {
|
|
6
|
+
[key: string]: any;
|
|
7
|
+
};
|
|
8
|
+
}
|
|
9
|
+
declare function __VLS_template(): {
|
|
10
|
+
default?(_: {}): any;
|
|
11
|
+
};
|
|
12
|
+
declare const __VLS_component: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<SearchFormItem>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
13
|
+
search: (...args: any[]) => void;
|
|
14
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<SearchFormItem>>> & Readonly<{
|
|
15
|
+
onSearch?: ((...args: any[]) => any) | undefined;
|
|
16
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
17
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
18
|
+
export default _default;
|
|
19
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
20
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
21
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
22
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
23
|
+
} : {
|
|
24
|
+
type: import('vue').PropType<T[K]>;
|
|
25
|
+
required: true;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
29
|
+
new (): {
|
|
30
|
+
$slots: S;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ColumnProps } from '../types';
|
|
2
|
+
|
|
3
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
|
|
4
|
+
column: ColumnProps;
|
|
5
|
+
}>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
|
|
6
|
+
column: ColumnProps;
|
|
7
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
10
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
11
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
12
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
13
|
+
} : {
|
|
14
|
+
type: import('vue').PropType<T[K]>;
|
|
15
|
+
required: true;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
interface Pageable {
|
|
2
|
+
page: number;
|
|
3
|
+
size: number;
|
|
4
|
+
total: number;
|
|
5
|
+
}
|
|
6
|
+
interface PaginationProps {
|
|
7
|
+
pageable: Pageable;
|
|
8
|
+
handleSizeChange: (size: number) => void;
|
|
9
|
+
handleCurrentChange: (currentPage: number) => void;
|
|
10
|
+
}
|
|
11
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<PaginationProps>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<PaginationProps>>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
12
|
+
export default _default;
|
|
13
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
14
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
15
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
16
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
17
|
+
} : {
|
|
18
|
+
type: import('vue').PropType<T[K]>;
|
|
19
|
+
required: true;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description 表格多选数据操作
|
|
3
|
+
* @param {String} rowKey 当表格可以多选时,所指定的 id
|
|
4
|
+
* @param selectChangeCallback
|
|
5
|
+
* */
|
|
6
|
+
export declare const useSelection: (rowKey?: string, selectChangeCallback?: (data: any) => any) => {
|
|
7
|
+
isSelected: import('vue').Ref<boolean, boolean>;
|
|
8
|
+
selectedList: import('vue').Ref<{
|
|
9
|
+
[key: string]: any;
|
|
10
|
+
}[], {
|
|
11
|
+
[key: string]: any;
|
|
12
|
+
}[]>;
|
|
13
|
+
selectedListIds: import('vue').ComputedRef<any[]>;
|
|
14
|
+
selectionChange: (rowArr: {
|
|
15
|
+
[key: string]: any;
|
|
16
|
+
}[]) => void;
|
|
17
|
+
};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @description table 页面操作方法封装
|
|
3
|
+
* @param {Function} api 获取表格数据 api 方法 (必传)
|
|
4
|
+
* @param {Object} initParam 获取数据初始化参数 (非必传,默认为{})
|
|
5
|
+
* @param {Boolean} isPageable 是否有分页 (非必传,默认为true)
|
|
6
|
+
* @param {Function} dataCallBack 对后台返回的数据进行处理的方法 (非必传)
|
|
7
|
+
* @param requestError
|
|
8
|
+
* @param handleParam
|
|
9
|
+
* @param requestError
|
|
10
|
+
* @param handleParam
|
|
11
|
+
* */
|
|
12
|
+
export declare const useTable: (api?: (params: any) => Promise<any>, initParam?: object, isPageable?: boolean, dataCallBack?: (data: any) => any, requestError?: (error: any) => void, handleParam?: (data: any) => any) => {
|
|
13
|
+
getTableList: () => Promise<void>;
|
|
14
|
+
search: () => void;
|
|
15
|
+
reset: () => void;
|
|
16
|
+
handleSizeChange: (val: number) => void;
|
|
17
|
+
handleCurrentChange: (val: number) => void;
|
|
18
|
+
updatedTotalParam: () => void;
|
|
19
|
+
tableData: import('vue').Ref<any[], any[]>;
|
|
20
|
+
pageable: import('vue').Ref<{
|
|
21
|
+
page: number;
|
|
22
|
+
size: number;
|
|
23
|
+
total: number;
|
|
24
|
+
}, {
|
|
25
|
+
page: number;
|
|
26
|
+
size: number;
|
|
27
|
+
total: number;
|
|
28
|
+
}>;
|
|
29
|
+
searchParam: import('vue').Ref<{
|
|
30
|
+
[key: string]: any;
|
|
31
|
+
}, {
|
|
32
|
+
[key: string]: any;
|
|
33
|
+
}>;
|
|
34
|
+
searchInitParam: import('vue').Ref<{
|
|
35
|
+
[key: string]: any;
|
|
36
|
+
}, {
|
|
37
|
+
[key: string]: any;
|
|
38
|
+
}>;
|
|
39
|
+
totalParam: import('vue').Ref<{
|
|
40
|
+
[key: string]: any;
|
|
41
|
+
}, {
|
|
42
|
+
[key: string]: any;
|
|
43
|
+
}>;
|
|
44
|
+
icon?: import('vue').Ref<{
|
|
45
|
+
[key: string]: any;
|
|
46
|
+
} | undefined, {
|
|
47
|
+
[key: string]: any;
|
|
48
|
+
} | undefined> | undefined;
|
|
49
|
+
loading: import('vue').Ref<boolean, boolean>;
|
|
50
|
+
};
|