keli-ui 0.0.13 → 0.0.15
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/keli-ui.css +1 -1
- package/dist/keli-ui.js +81109 -72032
- package/dist/keli-ui.umd.cjs +1 -1
- package/dist/types/lib/useButtonExec.d.ts +1 -1
- package/dist/types/packages/FormComponents/FormCascaderAsync/FormCascaderAsync.vue.d.ts +42 -0
- package/dist/types/packages/FormComponents/FormCascaderAsync/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormCheckBoxAsync/FormCheckBoxAsync.vue.d.ts +44 -0
- package/dist/types/packages/FormComponents/FormCheckBoxAsync/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormCodeEditor/FormCodeEditor.vue.d.ts +43 -0
- package/dist/types/packages/FormComponents/FormCodeEditor/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormDatePicker/FormDatePickerClient.vue.d.ts +30 -0
- package/dist/types/packages/FormComponents/FormDatePicker/FormDatePickerMobile.vue.d.ts +38 -0
- package/dist/types/packages/FormComponents/FormDatePicker/index.d.ts +62 -0
- package/dist/types/packages/FormComponents/FormDateTimePicker/FormDateTimePickerClient.vue.d.ts +34 -0
- package/dist/types/packages/FormComponents/FormDateTimePicker/FormDateTimePickerMobile.vue.d.ts +38 -0
- package/dist/types/packages/FormComponents/FormDateTimePicker/index.d.ts +66 -0
- package/dist/types/packages/FormComponents/FormDivider/FormDivider.vue.d.ts +30 -0
- package/dist/types/packages/FormComponents/FormDivider/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormDynamicTable/FormDynamicTable.vue.d.ts +36 -0
- package/dist/types/packages/FormComponents/FormDynamicTable/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormInput/FormInput.vue.d.ts +34 -0
- package/dist/types/packages/FormComponents/FormInput/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormInputNumber/FormInputNumber.vue.d.ts +47 -0
- package/dist/types/packages/FormComponents/FormInputNumber/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormRadio/FormRadio.vue.d.ts +28 -0
- package/dist/types/packages/FormComponents/FormRadio/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormRender/FormRenderClient.vue.d.ts +113 -0
- package/dist/types/packages/FormComponents/FormRender/FormRenderMobile.vue.d.ts +108 -0
- package/dist/types/packages/FormComponents/FormRender/hooks/formRender.hook.d.ts +42 -0
- package/dist/types/packages/FormComponents/FormRender/index.d.ts +106 -0
- package/dist/types/packages/FormComponents/FormSelect/FormSelectClient.vue.d.ts +32 -0
- package/dist/types/packages/FormComponents/FormSelect/FormSelectMobile.vue.d.ts +36 -0
- package/dist/types/packages/FormComponents/FormSelect/index.d.ts +62 -0
- package/dist/types/packages/FormComponents/FormSelectAsync/FormSelectAsyncClient.vue.d.ts +55 -0
- package/dist/types/packages/FormComponents/FormSelectAsync/FormSelectAsyncMobile.vue.d.ts +55 -0
- package/dist/types/packages/FormComponents/FormSelectAsync/hooks/selectAsync.hook.d.ts +33 -0
- package/dist/types/packages/FormComponents/FormSelectAsync/index.d.ts +53 -0
- package/dist/types/packages/FormComponents/FormSelectRemote/FormSelectRemote.vue.d.ts +42 -0
- package/dist/types/packages/FormComponents/FormSelectRemote/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormSwitch/FormSwitch.vue.d.ts +34 -0
- package/dist/types/packages/FormComponents/FormSwitch/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormText/FormText.vue.d.ts +39 -0
- package/dist/types/packages/FormComponents/FormText/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/FormTextArea/FormTextArea.vue.d.ts +34 -0
- package/dist/types/packages/FormComponents/FormTextArea/index.d.ts +2 -0
- package/dist/types/packages/FormComponents/hook/useMitt.hook.d.ts +4 -0
- package/dist/types/packages/QueryComponents/QueryBar/QueryBarClient.vue.d.ts +1 -1
- package/dist/types/packages/QueryComponents/QueryBar/QueryBarMobile.vue.d.ts +1 -1
- package/dist/types/packages/QueryComponents/QueryBar/index.d.ts +4 -5
- package/dist/types/packages/QueryComponents/QuerySelect/QuerySelectClient.vue.d.ts +1 -1
- package/dist/types/packages/TableComponents/TableCardRender/TableCardRenderClient.vue.d.ts +6 -6
- package/dist/types/packages/TableComponents/TableCardRender/TableCardRenderMobile.vue.d.ts +4 -6
- package/dist/types/packages/TableComponents/TableCardRender/index.d.ts +20 -21
- package/dist/types/packages/TableComponents/TableCheckBoxAsync/TableCheckBoxAsync.vue.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableCheckBoxAsync/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableInput/TableInput.vue.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableInput/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableInputNumber/TableInputNumber.vue.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableInputNumber/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableRender/TableRenderClient.vue.d.ts +28 -10
- package/dist/types/packages/TableComponents/TableRender/TableRenderMobile.vue.d.ts +6 -8
- package/dist/types/packages/TableComponents/TableRender/hooks/useCopyPaste.hook.d.ts +1 -1
- package/dist/types/packages/TableComponents/TableRender/index.d.ts +20 -21
- package/dist/types/packages/TableComponents/TableSelect/TableSelect.vue.d.ts +1 -1
- package/dist/types/packages/TableComponents/TableSelect/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableSelectAsync/TableSelectAsync.vue.d.ts +1 -1
- package/dist/types/packages/TableComponents/TableSelectAsync/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableSwitch/TableSwitch.vue.d.ts +1 -1
- package/dist/types/packages/TableComponents/TableSwitch/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/TableTreeRender/TableTreeRender.vue.d.ts +6 -8
- package/dist/types/packages/TableComponents/TableTreeRender/index.d.ts +2 -2
- package/dist/types/packages/TableComponents/utils/dataFormatter.d.ts +1 -1
- package/dist/types/packages/ToolBar/ToolBarClient.vue.d.ts +1 -1
- package/dist/types/packages/ToolBar/ToolBarMobile.vue.d.ts +1 -1
- package/dist/types/packages/ToolBar/ToolBarProxy.vue.d.ts +1 -1
- package/dist/types/packages/index.d.ts +21 -20
- package/dist/types/packages/types/componentFrame.d.ts +3 -1
- package/dist/types/packages/types/formFrame.d.ts +86 -0
- package/dist/types/packages/types/queryFrame.d.ts +1 -1
- package/dist/types/packages/types/tableFrame.d.ts +36 -7
- package/dist/types/utils/arrayUtils.d.ts +60 -0
- package/dist/types/utils/dateTime.d.ts +22 -0
- package/dist/types/utils/index.d.ts +3 -0
- package/dist/types/utils/mitt.d.ts +6 -0
- package/dist/types/utils/msgTips.d.ts +1 -1
- package/package.json +24 -5
- package/dist/types/packages/TableComponents/TableRender/hooks/tableRender.hook.d.ts +0 -0
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
declare const KeliTableRender: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
1
|
+
declare const KeTableRender: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
3
2
|
tableId: {
|
|
4
3
|
required: true;
|
|
5
4
|
type: (StringConstructor | NumberConstructor)[];
|
|
6
5
|
};
|
|
7
6
|
tableConfig: {
|
|
8
7
|
required: true;
|
|
9
|
-
type: import("vue").PropType<
|
|
8
|
+
type: import("vue").PropType<import("../../index.js").TableConfigInterface>;
|
|
10
9
|
};
|
|
11
10
|
vxeGridOptions: {
|
|
12
11
|
required: false;
|
|
@@ -18,18 +17,18 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
18
17
|
};
|
|
19
18
|
queryConfig: {
|
|
20
19
|
required: false;
|
|
21
|
-
type: import("vue").PropType<
|
|
20
|
+
type: import("vue").PropType<import("../../index.js").TableQueryFrame[]>;
|
|
22
21
|
default: any[];
|
|
23
22
|
};
|
|
24
23
|
tableToolButtons: {
|
|
25
24
|
required: false;
|
|
26
25
|
default: () => any[];
|
|
27
|
-
type: import("vue").PropType<
|
|
26
|
+
type: import("vue").PropType<import("../../index.js").KeliButton[]>;
|
|
28
27
|
};
|
|
29
28
|
tableRowButtons: {
|
|
30
29
|
required: false;
|
|
31
30
|
default: () => any[];
|
|
32
|
-
type: import("vue").PropType<
|
|
31
|
+
type: import("vue").PropType<import("../../index.js").KeliButton[]>;
|
|
33
32
|
};
|
|
34
33
|
tableData: {
|
|
35
34
|
required: true;
|
|
@@ -38,7 +37,7 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
38
37
|
};
|
|
39
38
|
tablePagination: {
|
|
40
39
|
required: false;
|
|
41
|
-
type: import("vue").PropType<
|
|
40
|
+
type: import("vue").PropType<import("../type.js").Pagination>;
|
|
42
41
|
default: () => {
|
|
43
42
|
currentPage: number;
|
|
44
43
|
pageSize: number;
|
|
@@ -46,12 +45,12 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
46
45
|
};
|
|
47
46
|
};
|
|
48
47
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
49
|
-
btnClick: (...args: any[]) => void;
|
|
50
48
|
queryClick: (...args: any[]) => void;
|
|
49
|
+
btnClick: (...args: any[]) => void;
|
|
51
50
|
valueChange: (...args: any[]) => void;
|
|
52
51
|
treeLazyLoad: (...args: any[]) => void;
|
|
53
52
|
onSelection: (...args: any[]) => void;
|
|
54
|
-
"update:tablePagination": (value:
|
|
53
|
+
"update:tablePagination": (value: import("../type.js").Pagination) => void;
|
|
55
54
|
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
56
55
|
tableId: {
|
|
57
56
|
required: true;
|
|
@@ -59,7 +58,7 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
59
58
|
};
|
|
60
59
|
tableConfig: {
|
|
61
60
|
required: true;
|
|
62
|
-
type: import("vue").PropType<
|
|
61
|
+
type: import("vue").PropType<import("../../index.js").TableConfigInterface>;
|
|
63
62
|
};
|
|
64
63
|
vxeGridOptions: {
|
|
65
64
|
required: false;
|
|
@@ -71,18 +70,18 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
71
70
|
};
|
|
72
71
|
queryConfig: {
|
|
73
72
|
required: false;
|
|
74
|
-
type: import("vue").PropType<
|
|
73
|
+
type: import("vue").PropType<import("../../index.js").TableQueryFrame[]>;
|
|
75
74
|
default: any[];
|
|
76
75
|
};
|
|
77
76
|
tableToolButtons: {
|
|
78
77
|
required: false;
|
|
79
78
|
default: () => any[];
|
|
80
|
-
type: import("vue").PropType<
|
|
79
|
+
type: import("vue").PropType<import("../../index.js").KeliButton[]>;
|
|
81
80
|
};
|
|
82
81
|
tableRowButtons: {
|
|
83
82
|
required: false;
|
|
84
83
|
default: () => any[];
|
|
85
|
-
type: import("vue").PropType<
|
|
84
|
+
type: import("vue").PropType<import("../../index.js").KeliButton[]>;
|
|
86
85
|
};
|
|
87
86
|
tableData: {
|
|
88
87
|
required: true;
|
|
@@ -91,7 +90,7 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
91
90
|
};
|
|
92
91
|
tablePagination: {
|
|
93
92
|
required: false;
|
|
94
|
-
type: import("vue").PropType<
|
|
93
|
+
type: import("vue").PropType<import("../type.js").Pagination>;
|
|
95
94
|
default: () => {
|
|
96
95
|
currentPage: number;
|
|
97
96
|
pageSize: number;
|
|
@@ -99,17 +98,17 @@ declare const KeliTableRender: import("vue").DefineComponent<import("vue").Extra
|
|
|
99
98
|
};
|
|
100
99
|
};
|
|
101
100
|
}>> & Readonly<{
|
|
102
|
-
onBtnClick?: (...args: any[]) => any;
|
|
103
101
|
onQueryClick?: (...args: any[]) => any;
|
|
102
|
+
onBtnClick?: (...args: any[]) => any;
|
|
104
103
|
onValueChange?: (...args: any[]) => any;
|
|
105
104
|
onTreeLazyLoad?: (...args: any[]) => any;
|
|
106
105
|
onOnSelection?: (...args: any[]) => any;
|
|
107
|
-
"onUpdate:tablePagination"?: (value:
|
|
106
|
+
"onUpdate:tablePagination"?: (value: import("../type.js").Pagination) => any;
|
|
108
107
|
}>, {
|
|
109
|
-
queryConfig: TableQueryFrame[];
|
|
110
|
-
tableToolButtons: KeliButton[];
|
|
111
|
-
tableRowButtons: KeliButton[];
|
|
108
|
+
queryConfig: import("../../index.js").TableQueryFrame[];
|
|
109
|
+
tableToolButtons: import("../../index.js").KeliButton[];
|
|
110
|
+
tableRowButtons: import("../../index.js").KeliButton[];
|
|
112
111
|
tableData: any[];
|
|
113
|
-
tablePagination: Pagination;
|
|
112
|
+
tablePagination: import("../type.js").Pagination;
|
|
114
113
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
115
|
-
export default
|
|
114
|
+
export default KeTableRender;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type PropType } from 'vue';
|
|
2
|
-
import type { TableSelector } from '
|
|
2
|
+
import type { TableSelector } from '../../types';
|
|
3
3
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
4
|
value: {
|
|
5
5
|
required: false;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
export default
|
|
1
|
+
import KeTableSelect from './TableSelect.vue';
|
|
2
|
+
export default KeTableSelect;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { PropType } from 'vue';
|
|
2
|
-
import type { TableSelector } from '
|
|
2
|
+
import type { TableSelector } from '../../types';
|
|
3
3
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
4
|
value: {
|
|
5
5
|
required: false;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
export default
|
|
1
|
+
import KeTableSelectAsync from './TableSelectAsync.vue';
|
|
2
|
+
export default KeTableSelectAsync;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { PropType } from 'vue';
|
|
2
|
-
import type { TableComponentFrame } from '
|
|
2
|
+
import type { TableComponentFrame } from '../../types';
|
|
3
3
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
4
|
value: {
|
|
5
5
|
type: BooleanConstructor;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
export default
|
|
1
|
+
import KeTableSwitch from './TableSwitch.vue';
|
|
2
|
+
export default KeTableSwitch;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { type PropType } from 'vue';
|
|
2
|
-
import type { TableConfigInterface } from '@/packages/types/tableFrame';
|
|
3
2
|
import type { VxeGridProps } from 'vxe-table';
|
|
4
|
-
import type { TableQueryFrame } from '
|
|
5
|
-
import type {
|
|
6
|
-
import type { Pagination } from '@/packages/TableComponents/type';
|
|
3
|
+
import type { KeliButton, TableConfigInterface, TableQueryFrame } from '../../types';
|
|
4
|
+
import type { Pagination } from '../type';
|
|
7
5
|
declare var __VLS_13: {};
|
|
8
6
|
type __VLS_Slots = {} & {
|
|
9
7
|
'tool-bar'?: (props: typeof __VLS_13) => any;
|
|
@@ -55,9 +53,9 @@ declare const __VLS_component: import("vue").DefineComponent<import("vue").Extra
|
|
|
55
53
|
};
|
|
56
54
|
};
|
|
57
55
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
58
|
-
getTableConfig: (...args: any[]) => void;
|
|
59
|
-
btnClick: (...args: any[]) => void;
|
|
60
56
|
queryClick: (...args: any[]) => void;
|
|
57
|
+
btnClick: (...args: any[]) => void;
|
|
58
|
+
getTableConfig: (...args: any[]) => void;
|
|
61
59
|
valueChange: (...args: any[]) => void;
|
|
62
60
|
treeLazyLoad: (...args: any[]) => void;
|
|
63
61
|
onSelection: (...args: any[]) => void;
|
|
@@ -108,9 +106,9 @@ declare const __VLS_component: import("vue").DefineComponent<import("vue").Extra
|
|
|
108
106
|
};
|
|
109
107
|
};
|
|
110
108
|
}>> & Readonly<{
|
|
111
|
-
onGetTableConfig?: (...args: any[]) => any;
|
|
112
|
-
onBtnClick?: (...args: any[]) => any;
|
|
113
109
|
onQueryClick?: (...args: any[]) => any;
|
|
110
|
+
onBtnClick?: (...args: any[]) => any;
|
|
111
|
+
onGetTableConfig?: (...args: any[]) => any;
|
|
114
112
|
onValueChange?: (...args: any[]) => any;
|
|
115
113
|
onTreeLazyLoad?: (...args: any[]) => any;
|
|
116
114
|
onOnSelection?: (...args: any[]) => any;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
export default
|
|
1
|
+
import KeTableTreeRender from './TableTreeRender.vue';
|
|
2
|
+
export default KeTableTreeRender;
|
|
@@ -1,25 +1,26 @@
|
|
|
1
1
|
import type { App } from 'vue';
|
|
2
2
|
import "../style.css";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
|
|
19
|
-
export type * from './types';
|
|
20
|
-
export * from 'vxe-table';
|
|
3
|
+
import KeTableRender from "./TableComponents/TableRender";
|
|
4
|
+
import KeTableCardRender from "./TableComponents/TableCardRender";
|
|
5
|
+
import KeTableTreeRender from "./TableComponents/TableTreeRender";
|
|
6
|
+
import KeTableCheckBoxAsync from "./TableComponents/TableCheckBoxAsync";
|
|
7
|
+
import KeTableInput from './TableComponents/TableInput/TableInput.vue';
|
|
8
|
+
import KeTableInputNumber from './TableComponents/TableInputNumber';
|
|
9
|
+
import KeTableSelect from './TableComponents/TableSelect';
|
|
10
|
+
import KeTableSelectAsync from './TableComponents/TableSelectAsync';
|
|
11
|
+
import KeTableSwitch from './TableComponents/TableSwitch';
|
|
12
|
+
import KeQueryBar from './QueryComponents/QueryBar';
|
|
13
|
+
import KeQueryDateTime from './QueryComponents/QueryDateTime';
|
|
14
|
+
import KeQueryInput from './QueryComponents/QueryInput';
|
|
15
|
+
import KeQueryInputLike from './QueryComponents/QueryInputLike';
|
|
16
|
+
import KeQuerySelect from './QueryComponents/QuerySelect';
|
|
17
|
+
import KeToolBar from './ToolBar';
|
|
18
|
+
declare const install: (app: App) => Promise<void>;
|
|
21
19
|
declare const _default: {
|
|
22
|
-
install(app: App)
|
|
20
|
+
install: (app: App) => Promise<void>;
|
|
23
21
|
};
|
|
24
22
|
export default _default;
|
|
25
|
-
export {
|
|
23
|
+
export { install, KeTableRender, KeTableCardRender, KeTableTreeRender, KeTableCheckBoxAsync, KeTableInput, KeTableInputNumber, KeTableSelect, KeTableSelectAsync, KeTableSwitch, KeQueryBar, KeQueryDateTime, KeQueryInput, KeQueryInputLike, KeQuerySelect, KeToolBar };
|
|
24
|
+
export * from '../utils';
|
|
25
|
+
export type * from './types';
|
|
26
|
+
export * from 'vxe-table';
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import type { ComponentFrame, HttpMethod, OptionInterface } from './componentFrame';
|
|
2
|
+
|
|
3
|
+
export interface FormFrame extends ComponentFrame {
|
|
4
|
+
/** 表单编辑器 */
|
|
5
|
+
formEditor: string;
|
|
6
|
+
/** 是否禁止编辑 */
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
/** 组件大小 */
|
|
9
|
+
size?: Size;
|
|
10
|
+
/** 当值发生变化时 通知这些字段的组件 */
|
|
11
|
+
noticeField?: string[];
|
|
12
|
+
/** 接收到字段值发生变化是触发的js函数 */
|
|
13
|
+
noticeReceive?: Function;
|
|
14
|
+
/** 组件其他参数 */
|
|
15
|
+
componentParams?: any;
|
|
16
|
+
/** 格栅占据数 */
|
|
17
|
+
formSpan?: number;
|
|
18
|
+
/** 默认值 */
|
|
19
|
+
defaultValue?: null | string | undefined;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/** 下拉框 */
|
|
23
|
+
export interface KeFormSelect extends FormFrame {
|
|
24
|
+
/** 是否多选 */
|
|
25
|
+
multiple?: boolean;
|
|
26
|
+
/** 下拉框选项 */
|
|
27
|
+
options: OptionInterface[];
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export interface KeFormSelectAsync extends FormFrame {
|
|
31
|
+
/** 是否多选 */
|
|
32
|
+
multiple: boolean;
|
|
33
|
+
/** Http URL */
|
|
34
|
+
optionHttpUrl: string;
|
|
35
|
+
/** http方法 */
|
|
36
|
+
optionHttpMethod: HttpMethod;
|
|
37
|
+
/** http默认参数 */
|
|
38
|
+
optionHttpParams: any;
|
|
39
|
+
/** http其他字段 */
|
|
40
|
+
optionHttpComponentValue: string[];
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface FormCodeEditor extends FormFrame {
|
|
44
|
+
lang: 'java' | 'javascript' | 'json' | 'mysql' | 'postgresql';
|
|
45
|
+
componentParams?: {
|
|
46
|
+
lang: 'java' | 'javascript' | 'json' | 'mysql' | 'postgresql';
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/** 动态表格 */
|
|
51
|
+
export interface FormDynamicTable extends FormFrame {
|
|
52
|
+
width: number;
|
|
53
|
+
column: DynamicTableColumn[];
|
|
54
|
+
}
|
|
55
|
+
interface DynamicTableColumn {
|
|
56
|
+
field: string;
|
|
57
|
+
title: string;
|
|
58
|
+
width: number;
|
|
59
|
+
editor: DynamicComponent;
|
|
60
|
+
[key: string]: any;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export interface KeFormRadio extends FormFrame {
|
|
64
|
+
options: OptionInterface[];
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/** 表单基本配置 */
|
|
68
|
+
export interface KeFormBasicInterface {
|
|
69
|
+
/** 主键的key */
|
|
70
|
+
rowKey: string;
|
|
71
|
+
labelWidth: number;
|
|
72
|
+
span?: number;
|
|
73
|
+
// label对齐方式
|
|
74
|
+
labelPosition?: LabelPosition;
|
|
75
|
+
// 表单布局方式
|
|
76
|
+
layout?: FormLayout;
|
|
77
|
+
formWindowType?: 'default' | 'DialogForm' | 'DrawerForm';
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/** 嵌入表 */
|
|
81
|
+
export interface KeFormEmbeddedTable {
|
|
82
|
+
/** pageEn */
|
|
83
|
+
embeddedId: number;
|
|
84
|
+
/** tab标题 */
|
|
85
|
+
tabTitle: string;
|
|
86
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { translateJSON, translateObj } from '
|
|
2
|
-
import type { ComponentFrame, OptionInterface, Slots } from '
|
|
1
|
+
import type { translateJSON, translateObj } from './translate';
|
|
2
|
+
import type { ComponentFrame, HttpMethod, OptionInterface, Slots } from './componentFrame';
|
|
3
3
|
|
|
4
4
|
/** 表格基础配置 */
|
|
5
5
|
export interface TableConfigInterface {
|
|
@@ -41,16 +41,34 @@ export interface TableConfigInterface {
|
|
|
41
41
|
paste?: boolean;
|
|
42
42
|
}
|
|
43
43
|
|
|
44
|
+
type Fixed = 'left' | 'right';
|
|
45
|
+
|
|
44
46
|
export interface TableComponentFrame extends ComponentFrame {
|
|
45
|
-
|
|
47
|
+
/**
|
|
48
|
+
* 最小宽度
|
|
49
|
+
*/
|
|
50
|
+
minWidth: number;
|
|
51
|
+
/**
|
|
52
|
+
* 固定列位置
|
|
53
|
+
*/
|
|
54
|
+
fixed?: Fixed;
|
|
55
|
+
/**
|
|
56
|
+
* 允许拖拽
|
|
57
|
+
*/
|
|
58
|
+
sortable?: boolean,
|
|
59
|
+
slots?: {
|
|
46
60
|
default: Slots;
|
|
47
61
|
};
|
|
48
|
-
editRender
|
|
62
|
+
editRender?: {
|
|
49
63
|
/**
|
|
50
64
|
* 组件名称
|
|
51
65
|
*/
|
|
52
66
|
name: string;
|
|
53
67
|
props: {
|
|
68
|
+
/**
|
|
69
|
+
* 是否禁止编辑
|
|
70
|
+
*/
|
|
71
|
+
disabled: boolean,
|
|
54
72
|
/** 组件其他参数 可参考element-plus或者vant的组件参数 */
|
|
55
73
|
componentParams?: {
|
|
56
74
|
[propName: string]: any;
|
|
@@ -63,9 +81,20 @@ export interface TableComponentFrame extends ComponentFrame {
|
|
|
63
81
|
}
|
|
64
82
|
|
|
65
83
|
export interface TableSelector extends TableComponentFrame {
|
|
66
|
-
editRender
|
|
84
|
+
editRender?: {
|
|
85
|
+
/**
|
|
86
|
+
* 组件名称
|
|
87
|
+
*/
|
|
67
88
|
name: string;
|
|
68
|
-
props:
|
|
89
|
+
props: {
|
|
90
|
+
/**
|
|
91
|
+
* 是否禁止编辑
|
|
92
|
+
*/
|
|
93
|
+
disabled: boolean,
|
|
94
|
+
/** 组件其他参数 可参考element-plus或者vant的组件参数 */
|
|
95
|
+
componentParams?: {
|
|
96
|
+
[propName: string]: any;
|
|
97
|
+
};
|
|
69
98
|
/** 是否多选 */
|
|
70
99
|
multiple?: boolean;
|
|
71
100
|
/** Http URL */
|
|
@@ -78,6 +107,6 @@ export interface TableSelector extends TableComponentFrame {
|
|
|
78
107
|
optionHttpParamsValue: string[];
|
|
79
108
|
/** 选项默认是空的 需要在render里面进行数据异步获取 不在组件内部进行数据获取 */
|
|
80
109
|
options: OptionInterface[];
|
|
81
|
-
}
|
|
110
|
+
}
|
|
82
111
|
};
|
|
83
112
|
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 判断某个值是否存在与某个数组中
|
|
3
|
+
* 如果key是字符串则直接取array的item[key] 数组则是取array的item[key0][key1][key2]... 留空则直接返回item是否等于value
|
|
4
|
+
* @param value 值
|
|
5
|
+
* @param array 数组
|
|
6
|
+
* @param key 键
|
|
7
|
+
*/
|
|
8
|
+
export declare function isInArray(value: any, array: any[], key?: null | string | string[]): boolean;
|
|
9
|
+
/**
|
|
10
|
+
* 获取valueArray还在array的值
|
|
11
|
+
* @param valueArray
|
|
12
|
+
* @param array
|
|
13
|
+
* @param key
|
|
14
|
+
*/
|
|
15
|
+
export declare function valueArrayInArray(valueArray: any[], array: any[], key?: null | string | string[]): any[];
|
|
16
|
+
/**
|
|
17
|
+
* 入参是一个数组和一个值,如果数组存在这个值,则移除掉里面所有的这个值并返回移除后的数组
|
|
18
|
+
* @param array
|
|
19
|
+
* @param value
|
|
20
|
+
*/
|
|
21
|
+
export declare function removeValueFromArray(array: any[], value: any): any[];
|
|
22
|
+
interface LabelFromArrayByValue {
|
|
23
|
+
/**
|
|
24
|
+
* 选项 类似于下拉框选项格式
|
|
25
|
+
* [
|
|
26
|
+
* {
|
|
27
|
+
* value: 'option1',
|
|
28
|
+
* label: '选项1',
|
|
29
|
+
* },
|
|
30
|
+
* {
|
|
31
|
+
* value: 'option2',
|
|
32
|
+
* label: '选项2',
|
|
33
|
+
* },
|
|
34
|
+
* {
|
|
35
|
+
* value: 'option3',
|
|
36
|
+
* label: '选项3',
|
|
37
|
+
* }
|
|
38
|
+
* ]
|
|
39
|
+
*/
|
|
40
|
+
options: any[];
|
|
41
|
+
/**
|
|
42
|
+
* 查询值
|
|
43
|
+
* 例如option1 或者 ['option1', 'option3']
|
|
44
|
+
*/
|
|
45
|
+
value: number | number[] | string | string[];
|
|
46
|
+
/**
|
|
47
|
+
* value字段 对应例子里面的value
|
|
48
|
+
*/
|
|
49
|
+
valueField: string;
|
|
50
|
+
/**
|
|
51
|
+
* label字段 对应例子里面的label
|
|
52
|
+
*/
|
|
53
|
+
labelField: string;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* 在数组里面查询label
|
|
57
|
+
* @param params
|
|
58
|
+
*/
|
|
59
|
+
export declare function getLabelFromArrayByValue(params: LabelFromArrayByValue): any;
|
|
60
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 获取n天后的时间戳
|
|
3
|
+
* @param n
|
|
4
|
+
*/
|
|
5
|
+
export declare function getTimeStampAfterNDay(n: number): Date;
|
|
6
|
+
/**
|
|
7
|
+
* 获取农历
|
|
8
|
+
* @param date
|
|
9
|
+
*/
|
|
10
|
+
export declare const getLunar: (date: any) => any;
|
|
11
|
+
/**
|
|
12
|
+
* 根据时间戳获取相差时间
|
|
13
|
+
* @param startTimestamp 小的时间
|
|
14
|
+
* @param endTimestamp 大的时间
|
|
15
|
+
*/
|
|
16
|
+
export declare const calculateTimeDifference: (startTimestamp: number, endTimestamp: number) => string;
|
|
17
|
+
/**
|
|
18
|
+
* 获取显示时间
|
|
19
|
+
* @param dateTimeStr
|
|
20
|
+
* @param onlyOne 当非今天时 是否只显示日期
|
|
21
|
+
*/
|
|
22
|
+
export declare function getShowFormatDateTime(dateTimeStr: string, onlyOne?: boolean): string;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "keli-ui",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.15",
|
|
5
5
|
"author": "Luv Letter",
|
|
6
6
|
"description": "配置化组件库",
|
|
7
7
|
"type": "module",
|
|
@@ -31,25 +31,44 @@
|
|
|
31
31
|
"preview": "vite preview"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@
|
|
34
|
+
"@codemirror/lang-java": "^6.0.1",
|
|
35
|
+
"@codemirror/lang-javascript": "^6.2.4",
|
|
36
|
+
"@codemirror/lang-json": "^6.0.1",
|
|
37
|
+
"@codemirror/language": "^6.11.0",
|
|
38
|
+
"@codemirror/theme-one-dark": "^6.1.2",
|
|
35
39
|
"@vueuse/core": "^13.1.0",
|
|
36
|
-
"
|
|
40
|
+
"js-beautify": "^1.15.4",
|
|
41
|
+
"solarday2lunarday": "^1.12.1",
|
|
42
|
+
"sql-formatter": "^15.6.1",
|
|
37
43
|
"vant": "^4.9.19",
|
|
38
44
|
"vue": "^3.5.13",
|
|
39
|
-
"
|
|
45
|
+
"vue-codemirror": "^6.1.1",
|
|
46
|
+
"vue-draggable-plus": "^0.6.0",
|
|
40
47
|
"vxe-table": "^4.13.15"
|
|
41
48
|
},
|
|
49
|
+
"optionalDependencies": {
|
|
50
|
+
"mitt": "^3.0.1",
|
|
51
|
+
"vxe-pc-ui": "^4.5.34"
|
|
52
|
+
},
|
|
53
|
+
"peerDependencies": {
|
|
54
|
+
"@element-plus/icons-vue": "^2.3.1",
|
|
55
|
+
"element-plus": "^2.9.9"
|
|
56
|
+
},
|
|
42
57
|
"devDependencies": {
|
|
58
|
+
"@element-plus/icons-vue": "^2.3.1",
|
|
59
|
+
"@types/js-beautify": "^1.14.3",
|
|
43
60
|
"@types/node": "^22.15.3",
|
|
44
61
|
"@types/web-bluetooth": "^0.0.21",
|
|
45
62
|
"@vitejs/plugin-vue": "^5.2.2",
|
|
46
63
|
"@vue/tsconfig": "^0.7.0",
|
|
47
64
|
"class-variance-authority": "^0.7.1",
|
|
48
65
|
"clsx": "^2.1.1",
|
|
66
|
+
"element-plus": "^2.9.9",
|
|
49
67
|
"sass-embedded": "^1.87.0",
|
|
50
68
|
"terser": "^5.39.0",
|
|
51
69
|
"typescript": "~5.7.2",
|
|
52
70
|
"vite": "^6.3.1",
|
|
53
|
-
"vue-tsc": "^2.2.8"
|
|
71
|
+
"vue-tsc": "^2.2.8",
|
|
72
|
+
"vxe-pc-ui": "^4.5.34"
|
|
54
73
|
}
|
|
55
74
|
}
|
|
File without changes
|