es-plus-ui 1.0.3 → 1.1.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.
- package/dist/es-plus.js +1385 -1187
- package/dist/es-plus.js.map +1 -1
- package/dist/es-plus.umd.cjs +1 -1
- package/dist/es-plus.umd.cjs.map +1 -1
- package/dist/src/components/es-crud-page/index.d.ts +4 -0
- package/dist/src/components/es-crud-page/src/es-crud-page.vue.d.ts +68 -0
- package/dist/src/components/es-crud-page/src/types.d.ts +56 -0
- package/dist/src/components/es-dialog/src/component.vue.d.ts +2 -2
- package/dist/src/components/es-form/src/es-form.vue.d.ts +2 -2
- package/dist/src/components/es-table/src/column-item.vue.d.ts +2 -0
- package/dist/src/components/es-table/src/component.vue.d.ts +3 -3
- package/dist/src/composables/use-form-layout.d.ts +2 -1
- package/dist/src/index.d.ts +4 -1
- package/dist/src/types/index.d.ts +9 -0
- package/dist/style.css +1 -1
- package/package.json +83 -74
- package/schemas/form-item.schema.json +4 -0
- package/schemas/table-column.schema.json +8 -1
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { CrudPageSchema } from './types';
|
|
2
|
+
|
|
3
|
+
declare function refresh(): void;
|
|
4
|
+
declare function getSelectedRows(): Record<string, unknown>[];
|
|
5
|
+
declare function __VLS_template(): Partial<Record<NonNullable<string | number>, (_: any) => any>>;
|
|
6
|
+
declare const __VLS_component: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
7
|
+
schema: CrudPageSchema;
|
|
8
|
+
httpRequest?: (params: Record<string, unknown>) => Promise<unknown>;
|
|
9
|
+
autoLoad?: boolean;
|
|
10
|
+
}>, {
|
|
11
|
+
autoLoad: boolean;
|
|
12
|
+
}>>, {
|
|
13
|
+
refresh: typeof refresh;
|
|
14
|
+
getSelectedRows: typeof getSelectedRows;
|
|
15
|
+
tableRef: import('vue').Ref<any, any>;
|
|
16
|
+
formRef: import('vue').Ref<any, any>;
|
|
17
|
+
queryModel: Record<string, unknown>;
|
|
18
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
19
|
+
delete: (row: Record<string, unknown>) => void;
|
|
20
|
+
add: () => void;
|
|
21
|
+
query: (model: Record<string, unknown>) => void;
|
|
22
|
+
view: (row: Record<string, unknown>) => void;
|
|
23
|
+
"row-click": (row: Record<string, unknown>) => void;
|
|
24
|
+
edit: (row: Record<string, unknown>) => void;
|
|
25
|
+
export: (model: Record<string, unknown>) => void;
|
|
26
|
+
"btn-click": (key: string, row?: Record<string, unknown>) => void;
|
|
27
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
28
|
+
schema: CrudPageSchema;
|
|
29
|
+
httpRequest?: (params: Record<string, unknown>) => Promise<unknown>;
|
|
30
|
+
autoLoad?: boolean;
|
|
31
|
+
}>, {
|
|
32
|
+
autoLoad: boolean;
|
|
33
|
+
}>>> & Readonly<{
|
|
34
|
+
onDelete?: (row: Record<string, unknown>) => any;
|
|
35
|
+
onAdd?: () => any;
|
|
36
|
+
onQuery?: (model: Record<string, unknown>) => any;
|
|
37
|
+
onView?: (row: Record<string, unknown>) => any;
|
|
38
|
+
"onRow-click"?: (row: Record<string, unknown>) => any;
|
|
39
|
+
onEdit?: (row: Record<string, unknown>) => any;
|
|
40
|
+
onExport?: (model: Record<string, unknown>) => any;
|
|
41
|
+
"onBtn-click"?: (key: string, row?: Record<string, unknown>) => any;
|
|
42
|
+
}>, {
|
|
43
|
+
autoLoad: boolean;
|
|
44
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
45
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
46
|
+
export default _default;
|
|
47
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
48
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
49
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
50
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
51
|
+
} : {
|
|
52
|
+
type: import('vue').PropType<T[K]>;
|
|
53
|
+
required: true;
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
type __VLS_WithDefaults<P, D> = {
|
|
57
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
58
|
+
default: D[K];
|
|
59
|
+
}> : P[K];
|
|
60
|
+
};
|
|
61
|
+
type __VLS_Prettify<T> = {
|
|
62
|
+
[K in keyof T]: T[K];
|
|
63
|
+
} & {};
|
|
64
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
65
|
+
new (): {
|
|
66
|
+
$slots: S;
|
|
67
|
+
};
|
|
68
|
+
};
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { FormItemOption, BtnConfig, TableColumn, TableOptions, PaginationConfig, DialogOptions } from '../../../types';
|
|
2
|
+
|
|
3
|
+
export interface CrudPageSchema {
|
|
4
|
+
/** 查询表单字段配置 */
|
|
5
|
+
formItems?: FormItemOption[];
|
|
6
|
+
/** 查询按钮配置 */
|
|
7
|
+
queryBtns?: BtnConfig[];
|
|
8
|
+
/** 表格列配置 */
|
|
9
|
+
columns: TableColumn[];
|
|
10
|
+
/** 表格选项配置 */
|
|
11
|
+
tableOptions?: Partial<TableOptions>;
|
|
12
|
+
/** 弹窗表单字段配置(新增/编辑使用) */
|
|
13
|
+
dialogFormItems?: FormItemOption[];
|
|
14
|
+
/** 弹窗选项 */
|
|
15
|
+
dialogOptions?: Partial<DialogOptions>;
|
|
16
|
+
/** 启用的操作类型 */
|
|
17
|
+
actions?: CrudAction[];
|
|
18
|
+
/** 分页配置 */
|
|
19
|
+
pagination?: PaginationConfig;
|
|
20
|
+
/** 表单布局配置 */
|
|
21
|
+
formLayout?: {
|
|
22
|
+
span?: number;
|
|
23
|
+
labelWidth?: string | number;
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
export type CrudAction = 'add' | 'edit' | 'delete' | 'view' | 'export';
|
|
27
|
+
export interface CrudPageProps {
|
|
28
|
+
/** CRUD 页面完整配置 */
|
|
29
|
+
schema: CrudPageSchema;
|
|
30
|
+
/** 自定义 HTTP 请求方法(覆盖 schema.tableOptions.httpRequest) */
|
|
31
|
+
httpRequest?: (params: Record<string, unknown>) => Promise<unknown>;
|
|
32
|
+
/** 是否在挂载时自动请求数据,默认 true */
|
|
33
|
+
autoLoad?: boolean;
|
|
34
|
+
}
|
|
35
|
+
export interface CrudPageEmits {
|
|
36
|
+
(e: 'query', model: Record<string, unknown>): void;
|
|
37
|
+
(e: 'add'): void;
|
|
38
|
+
(e: 'edit', row: Record<string, unknown>): void;
|
|
39
|
+
(e: 'delete', row: Record<string, unknown>): void;
|
|
40
|
+
(e: 'view', row: Record<string, unknown>): void;
|
|
41
|
+
(e: 'export', model: Record<string, unknown>): void;
|
|
42
|
+
(e: 'row-click', row: Record<string, unknown>): void;
|
|
43
|
+
(e: 'btn-click', key: string, row?: Record<string, unknown>): void;
|
|
44
|
+
}
|
|
45
|
+
export interface CrudPageExpose {
|
|
46
|
+
/** 刷新表格数据 */
|
|
47
|
+
refresh: () => void;
|
|
48
|
+
/** 获取选中行 */
|
|
49
|
+
getSelectedRows: () => Record<string, unknown>[];
|
|
50
|
+
/** 表格组件实例 */
|
|
51
|
+
tableRef: any;
|
|
52
|
+
/** 表单组件实例 */
|
|
53
|
+
formRef: any;
|
|
54
|
+
/** 当前查询表单模型 */
|
|
55
|
+
queryModel: Record<string, unknown>;
|
|
56
|
+
}
|
|
@@ -18,8 +18,8 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
18
18
|
render?: Function;
|
|
19
19
|
fullscreen?: boolean;
|
|
20
20
|
}>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
21
|
-
closed: (val: boolean) => void;
|
|
22
21
|
submit: (payload: any) => void;
|
|
22
|
+
closed: (val: boolean) => void;
|
|
23
23
|
"update:visible": (val: boolean) => void;
|
|
24
24
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
|
|
25
25
|
title?: string;
|
|
@@ -38,8 +38,8 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
38
38
|
render?: Function;
|
|
39
39
|
fullscreen?: boolean;
|
|
40
40
|
}>>> & Readonly<{
|
|
41
|
-
onClosed?: (val: boolean) => any;
|
|
42
41
|
onSubmit?: (payload: any) => any;
|
|
42
|
+
onClosed?: (val: boolean) => any;
|
|
43
43
|
"onUpdate:visible"?: (val: boolean) => any;
|
|
44
44
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
45
45
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
@@ -32,8 +32,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
32
32
|
validateField: (props: string | string[]) => Promise<boolean>;
|
|
33
33
|
scrollToField: (prop: string) => void;
|
|
34
34
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
35
|
-
confirm: (formRef: unknown, model: Record<string, unknown>) => void;
|
|
36
35
|
reset: (formRef: unknown, model: Record<string, unknown>) => void;
|
|
36
|
+
confirm: (formRef: unknown, model: Record<string, unknown>) => void;
|
|
37
37
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
38
38
|
model: Record<string, unknown>;
|
|
39
39
|
formItemList: FormItemOption[];
|
|
@@ -52,8 +52,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
52
52
|
btnColSpanRow: boolean;
|
|
53
53
|
rules: () => {};
|
|
54
54
|
}>>> & Readonly<{
|
|
55
|
-
onConfirm?: (formRef: unknown, model: Record<string, unknown>) => any;
|
|
56
55
|
onReset?: (formRef: unknown, model: Record<string, unknown>) => any;
|
|
56
|
+
onConfirm?: (formRef: unknown, model: Record<string, unknown>) => any;
|
|
57
57
|
}>, {
|
|
58
58
|
configBtn: BtnConfig[];
|
|
59
59
|
model: Record<string, unknown>;
|
|
@@ -7,6 +7,7 @@ declare function __VLS_template(): Partial<Record<string, (_: {
|
|
|
7
7
|
prop?: string;
|
|
8
8
|
key?: string;
|
|
9
9
|
label?: string;
|
|
10
|
+
labelKey?: string;
|
|
10
11
|
width?: number | string;
|
|
11
12
|
minWidth?: number | string;
|
|
12
13
|
align?: string;
|
|
@@ -35,6 +36,7 @@ declare function __VLS_template(): Partial<Record<string, (_: {
|
|
|
35
36
|
prop?: string;
|
|
36
37
|
key?: string;
|
|
37
38
|
label?: string;
|
|
39
|
+
labelKey?: string;
|
|
38
40
|
width?: number | string;
|
|
39
41
|
minWidth?: number | string;
|
|
40
42
|
align?: string;
|
|
@@ -29,7 +29,7 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<im
|
|
|
29
29
|
tabHeight?: number | string;
|
|
30
30
|
isInitRun?: boolean;
|
|
31
31
|
actionUrl?: string;
|
|
32
|
-
apiParams?: import('
|
|
32
|
+
apiParams?: import('../../..').ApiParams;
|
|
33
33
|
httpRequest?: (params: Record<string, unknown>) => Promise<unknown>;
|
|
34
34
|
listenToCallBack?: Record<string, (params: unknown) => unknown>;
|
|
35
35
|
configTableOut?: Record<string, string>;
|
|
@@ -78,7 +78,7 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<im
|
|
|
78
78
|
tabHeight?: number | string;
|
|
79
79
|
isInitRun?: boolean;
|
|
80
80
|
actionUrl?: string;
|
|
81
|
-
apiParams?: import('
|
|
81
|
+
apiParams?: import('../../..').ApiParams;
|
|
82
82
|
httpRequest?: (params: Record<string, unknown>) => Promise<unknown>;
|
|
83
83
|
listenToCallBack?: Record<string, (params: unknown) => unknown>;
|
|
84
84
|
configTableOut?: Record<string, string>;
|
|
@@ -93,11 +93,11 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<im
|
|
|
93
93
|
"onSize-change"?: (pagination: PaginationConfig, size: number) => any;
|
|
94
94
|
"onChange-table-sort"?: (column: Record<string, unknown>) => any;
|
|
95
95
|
}>, {
|
|
96
|
+
options: TableOptions;
|
|
96
97
|
initTabHeight: number;
|
|
97
98
|
showHeaderBar: boolean;
|
|
98
99
|
dataSource: Record<string, unknown>[];
|
|
99
100
|
columns: TableColumn[];
|
|
100
|
-
options: TableOptions;
|
|
101
101
|
pagination: PaginationConfig;
|
|
102
102
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>, Readonly<{
|
|
103
103
|
default?: () => any;
|
|
@@ -25,6 +25,7 @@ export declare function useFormLayout(props: {
|
|
|
25
25
|
isFold: boolean;
|
|
26
26
|
prop: string;
|
|
27
27
|
label: string;
|
|
28
|
+
labelKey?: string;
|
|
28
29
|
formtype?: "Input" | "Select" | "datePicker" | "timePicker" | "Slider" | "ColorPicker" | "Transfer" | "Cascader" | "Radio" | "Checkbox" | "Switch" | "Rate" | "Upload";
|
|
29
30
|
span?: number;
|
|
30
31
|
attrs?: Record<string, unknown>;
|
|
@@ -38,7 +39,7 @@ export declare function useFormLayout(props: {
|
|
|
38
39
|
row: FormItemOption;
|
|
39
40
|
index: number;
|
|
40
41
|
}) => import('vue').VNode | string;
|
|
41
|
-
apiParams?: import('
|
|
42
|
+
apiParams?: import('..').ApiParams;
|
|
42
43
|
isInitRun?: boolean;
|
|
43
44
|
callOptionListFormat?: (data: unknown[]) => unknown[];
|
|
44
45
|
httpRequest?: (params: Record<string, unknown>) => Promise<unknown>;
|
package/dist/src/index.d.ts
CHANGED
|
@@ -2,10 +2,13 @@ import { default as EsDialog } from './components/es-dialog';
|
|
|
2
2
|
import { default as useDialog } from './components/es-dialog/src/use-dialog';
|
|
3
3
|
import { default as EsForm } from './components/es-form';
|
|
4
4
|
import { default as EsTable } from './components/es-table';
|
|
5
|
+
import { default as EsCrudPage } from './components/es-crud-page';
|
|
5
6
|
import { default as SvgIcon } from './components/svg-icon';
|
|
6
7
|
|
|
7
8
|
declare const install: (app: any, options?: Record<string, unknown>) => void;
|
|
8
|
-
export { EsDialog, EsForm, EsTable, SvgIcon, useDialog, install };
|
|
9
|
+
export { EsDialog, EsForm, EsTable, EsCrudPage, SvgIcon, useDialog, install };
|
|
10
|
+
export type { CrudPageSchema, CrudAction } from './components/es-crud-page';
|
|
11
|
+
export type { FormItemOption, ApiParams, BtnConfig, LayoutFormProps, TableColumn, TableOptions, PaginationConfig, DialogOptions, EsFormInstance, EsTableInstance, EsPlusOptions } from './types';
|
|
9
12
|
declare const _default: {
|
|
10
13
|
version: string;
|
|
11
14
|
install: (app: any, options?: Record<string, unknown>) => void;
|
|
@@ -4,6 +4,7 @@ import { FormProps, ButtonProps } from 'element-plus';
|
|
|
4
4
|
export interface FormItemOption {
|
|
5
5
|
prop: string;
|
|
6
6
|
label: string;
|
|
7
|
+
labelKey?: string;
|
|
7
8
|
formtype?: 'Input' | 'Select' | 'datePicker' | 'timePicker' | 'Slider' | 'ColorPicker' | 'Transfer' | 'Cascader' | 'Radio' | 'Checkbox' | 'Switch' | 'Rate' | 'Upload';
|
|
8
9
|
span?: number;
|
|
9
10
|
attrs?: Record<string, unknown>;
|
|
@@ -45,6 +46,7 @@ export interface BtnConfig {
|
|
|
45
46
|
direction?: 'left' | 'right';
|
|
46
47
|
loading?: boolean;
|
|
47
48
|
disabled?: boolean | (() => boolean);
|
|
49
|
+
permissionValue?: string;
|
|
48
50
|
click?: (model: Record<string, unknown>, formRef: unknown, httpRequestInstance?: unknown) => void;
|
|
49
51
|
[key: string]: unknown;
|
|
50
52
|
}
|
|
@@ -62,6 +64,7 @@ export interface TableColumn {
|
|
|
62
64
|
prop?: string;
|
|
63
65
|
key?: string;
|
|
64
66
|
label?: string;
|
|
67
|
+
labelKey?: string;
|
|
65
68
|
width?: number | string;
|
|
66
69
|
minWidth?: number | string;
|
|
67
70
|
align?: string;
|
|
@@ -145,3 +148,9 @@ export interface EsTableInstance {
|
|
|
145
148
|
clearAllSelection: () => void;
|
|
146
149
|
refresh: () => void;
|
|
147
150
|
}
|
|
151
|
+
export interface EsPlusOptions {
|
|
152
|
+
permission?: (value: string) => boolean;
|
|
153
|
+
t?: (key: string) => string;
|
|
154
|
+
globalProperties?: boolean;
|
|
155
|
+
[key: string]: unknown;
|
|
156
|
+
}
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@charset "UTF-8";.btns[data-v-
|
|
1
|
+
@charset "UTF-8";.btns[data-v-04347b64]{padding:0 0 5px;display:flex;justify-content:space-between;align-items:center}.left-text[data-v-04347b64]{color:#7d7d7d;font-size:14px}.btn-container_block[data-v-04347b64]{display:flex;justify-content:space-between;align-items:center;flex:1}.btn-container_block .btn-left[data-v-04347b64]{display:flex;justify-content:flex-start;align-items:center;flex-wrap:wrap}.btn-container_block .btn-right[data-v-04347b64]{display:flex;justify-content:flex-end;align-items:center;flex-wrap:wrap}@media (max-width: 768px){.btns[data-v-04347b64]{flex-direction:column;align-items:flex-start}.btn-container_block[data-v-04347b64]{flex-direction:column;align-items:flex-start;gap:10px}.btn-container_block .btn-left[data-v-04347b64],.btn-container_block .btn-right[data-v-04347b64]{width:100%;justify-content:flex-start}}.el-dp_tables[data-v-c84b1d80],.el-dp_tables[data-v-c84b1d80] .el-table__body-wrapper{height:auto}.table_component[data-v-c84b1d80]{width:100%;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;overflow:hidden}.table_containers[data-v-c84b1d80]{flex:1;width:100%;height:100%;display:flex;justify-content:space-between;flex-direction:column;align-items:flex-start;position:relative}.pagination_page[data-v-c84b1d80]{width:100%;display:flex;justify-content:center;align-items:center}.btn-slot[data-v-c84b1d80]{width:100%}.btn-slot .headerBar[data-v-c84b1d80]{box-sizing:border-box;background-color:#fff;border-radius:6px}.btn-slot .headerBar[data-v-c84b1d80] .el-form-item--small .el-form-item__label{box-sizing:border-box}.tableContainer[data-v-c84b1d80]{border-radius:0;transition:all 1.5s;flex:1;width:100%;display:flex;justify-content:space-between;flex-direction:column;align-items:flex-start}.tableContainer .table_inner_containers[data-v-c84b1d80]{width:100%}.tableContainer[data-v-c84b1d80] .el-table__empty-block{width:100%!important;margin:32px 0;font-size:14px;line-height:1.5715}.tableContainer[data-v-c84b1d80] .el-table__empty-block .el-table__empty-text{width:auto!important}.tableContainer[data-v-c84b1d80] .el-table__empty-block .ant-empty-image{height:40px;margin-bottom:8px}.tableContainer[data-v-c84b1d80] .el-table__empty-block .ant-empty-image .ant-empty-img-simple-ellipse{fill:#f5f5f5}.tableContainer[data-v-c84b1d80] .el-table__empty-block .ant-empty-image .ant-empty-img-simple-g{stroke:#d9d9d9}.tableContainer[data-v-c84b1d80] .el-table__empty-block .ant-empty-image .ant-empty-img-simple-path{fill:#fafafa}.tableContainer[data-v-c84b1d80] .el-table__empty-block .ant-empty-description{line-height:1.5715;color:#00000040}.tableContainer[data-v-c84b1d80] .el-tag{height:20px;padding:0 7px;line-height:20px;background:#fafafa;border:none;border-radius:4px}.tableContainer[data-v-c84b1d80] .el-tag.el-tag--info{color:#000000d9}.tableContainer[data-v-c84b1d80] .el-tag.el-tag--success{color:#52c41a;background:#f6ffed;border-color:#b7eb8f}.es-form[data-v-4a516856] .el-form-item{margin-bottom:18px}.es-form[data-v-4a516856] .el-form-item__label{font-weight:500}.es-form .buttonOperate[data-v-4a516856]{display:flex;align-items:center;flex-wrap:wrap;gap:8px}.es-form .leftRightBtn[data-v-4a516856]{display:flex;justify-content:space-between;align-items:center;width:100%}.es-form .leftRightBtn .btn-left[data-v-4a516856],.es-form .leftRightBtn .btn-right[data-v-4a516856]{display:flex;align-items:center}.es-form .btn-formItem[data-v-4a516856]{margin-bottom:0}.es-form .formItemCols[data-v-4a516856]{width:100%}.dp-dialog_wrapper[data-v-cf3f1ce4] .dialogAuto{margin:0!important}.dp-dialog_wrapper[data-v-cf3f1ce4] .el-overlay-dialog{display:flex;justify-content:center;align-items:center}.dp-dialog_wrapper[data-v-cf3f1ce4] .el-dialog{padding:10px}.dp-dialog_wrapper[data-v-cf3f1ce4] .el-dialog .el-dialog__footer{padding-top:0}.dp-dialog_wrapper[data-v-cf3f1ce4] .el-dialog .el-dialog__body{padding:10px 0}.dp-dialog_wrapper[data-v-cf3f1ce4] .el-dialog .el-dialog__header{border-bottom:1px solid #eee;display:flex;padding:0 0 10px;align-items:center;justify-content:space-between;margin:0}.dialog-title[data-v-cf3f1ce4]{line-height:24px;font-size:14px;color:#303133;font-weight:700}.btns[data-v-cf3f1ce4]{display:flex;align-items:center}.btns i[data-v-cf3f1ce4]{margin-right:8px;font-size:14px;cursor:pointer}.btns i[data-v-cf3f1ce4]:last-child{margin-right:0}.dialog_body_layouts[data-v-cf3f1ce4]{overflow-y:auto;overflow-x:hidden;scrollbar-width:thin;scrollbar-color:rgba(135,162,189,.1490196078) rgba(200,213,225,.2784313725)}[data-v-cf3f1ce4]::-webkit-scrollbar{width:14px;height:14px}[data-v-cf3f1ce4]::-webkit-scrollbar-button{width:0;height:0;display:none}[data-v-cf3f1ce4]::-webkit-scrollbar-corner{background-color:transparent}[data-v-cf3f1ce4]::-webkit-scrollbar-thumb{min-height:12px;border:4px solid transparent;background-clip:content-box;border-radius:7px;background-color:#c8d5e1}[data-v-cf3f1ce4]::-webkit-scrollbar-thumb:hover{background-color:#a8bbcf}[data-v-cf3f1ce4]::-webkit-scrollbar-thumb:active{background-color:#87a2bd}[data-v-cf3f1ce4]::-webkit-scrollbar-track{background-color:transparent}[data-v-cf3f1ce4]::-webkit-scrollbar-track-piece{background-color:transparent}.es-crud-page[data-v-7a9de7fc]{width:100%}.svg-icon[data-v-3a11db57]{width:1em;height:1em;vertical-align:-.15em;fill:currentColor;overflow:hidden}.svg-external-icon[data-v-3a11db57]{background-color:currentColor;-webkit-mask-size:cover!important;mask-size:cover!important;display:inline-block}
|
package/package.json
CHANGED
|
@@ -1,74 +1,83 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "es-plus-ui",
|
|
3
|
-
"version": "1.0
|
|
4
|
-
"description": "基于 Vue 3 和 Element Plus 的企业级中后台前端组件库",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"main": "./dist/es-plus.umd.cjs",
|
|
7
|
-
"module": "./dist/es-plus.js",
|
|
8
|
-
"types": "./dist/index.d.ts",
|
|
9
|
-
"exports": {
|
|
10
|
-
".": {
|
|
11
|
-
"import": "./dist/es-plus.js",
|
|
12
|
-
"require": "./dist/es-plus.umd.cjs",
|
|
13
|
-
"types": "./dist/index.d.ts"
|
|
14
|
-
},
|
|
15
|
-
"./dist/style.css": "./dist/style.css",
|
|
16
|
-
"./schemas/*": "./schemas/*"
|
|
17
|
-
},
|
|
18
|
-
"files": [
|
|
19
|
-
"dist",
|
|
20
|
-
"schemas",
|
|
21
|
-
"README.md"
|
|
22
|
-
],
|
|
23
|
-
"sideEffects": [
|
|
24
|
-
"**/*.css"
|
|
25
|
-
],
|
|
26
|
-
"scripts": {
|
|
27
|
-
"build": "vite build",
|
|
28
|
-
"prepublishOnly": "
|
|
29
|
-
"test": "vitest",
|
|
30
|
-
"test:ui": "vitest --ui",
|
|
31
|
-
"test:coverage": "vitest --coverage"
|
|
32
|
-
},
|
|
33
|
-
"keywords": [
|
|
34
|
-
"vue3",
|
|
35
|
-
"vue",
|
|
36
|
-
"element-plus",
|
|
37
|
-
"component-library",
|
|
38
|
-
"form",
|
|
39
|
-
"table",
|
|
40
|
-
"dialog",
|
|
41
|
-
"es-plus",
|
|
42
|
-
"typescript",
|
|
43
|
-
"enterprise",
|
|
44
|
-
"config-driven",
|
|
45
|
-
"crud",
|
|
46
|
-
"json-schema",
|
|
47
|
-
"ai-friendly"
|
|
48
|
-
],
|
|
49
|
-
"author": "",
|
|
50
|
-
"license": "MIT",
|
|
51
|
-
"
|
|
52
|
-
"
|
|
53
|
-
"
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
"
|
|
59
|
-
},
|
|
60
|
-
"
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
"
|
|
66
|
-
"
|
|
67
|
-
"
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
"vue": "^
|
|
71
|
-
"vue-
|
|
72
|
-
"
|
|
73
|
-
|
|
74
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "es-plus-ui",
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "基于 Vue 3 和 Element Plus 的企业级中后台前端组件库",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/es-plus.umd.cjs",
|
|
7
|
+
"module": "./dist/es-plus.js",
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"import": "./dist/es-plus.js",
|
|
12
|
+
"require": "./dist/es-plus.umd.cjs",
|
|
13
|
+
"types": "./dist/index.d.ts"
|
|
14
|
+
},
|
|
15
|
+
"./dist/style.css": "./dist/style.css",
|
|
16
|
+
"./schemas/*": "./schemas/*"
|
|
17
|
+
},
|
|
18
|
+
"files": [
|
|
19
|
+
"dist",
|
|
20
|
+
"schemas",
|
|
21
|
+
"README.md"
|
|
22
|
+
],
|
|
23
|
+
"sideEffects": [
|
|
24
|
+
"**/*.css"
|
|
25
|
+
],
|
|
26
|
+
"scripts": {
|
|
27
|
+
"build": "vite build",
|
|
28
|
+
"prepublishOnly": "npm run build",
|
|
29
|
+
"test": "vitest",
|
|
30
|
+
"test:ui": "vitest --ui",
|
|
31
|
+
"test:coverage": "vitest --coverage"
|
|
32
|
+
},
|
|
33
|
+
"keywords": [
|
|
34
|
+
"vue3",
|
|
35
|
+
"vue",
|
|
36
|
+
"element-plus",
|
|
37
|
+
"component-library",
|
|
38
|
+
"form",
|
|
39
|
+
"table",
|
|
40
|
+
"dialog",
|
|
41
|
+
"es-plus",
|
|
42
|
+
"typescript",
|
|
43
|
+
"enterprise",
|
|
44
|
+
"config-driven",
|
|
45
|
+
"crud",
|
|
46
|
+
"json-schema",
|
|
47
|
+
"ai-friendly"
|
|
48
|
+
],
|
|
49
|
+
"author": "liujiaao <303363554@qq.com>",
|
|
50
|
+
"license": "MIT",
|
|
51
|
+
"repository": {
|
|
52
|
+
"type": "git",
|
|
53
|
+
"url": "https://github.com/liujiaao/es-plus.git",
|
|
54
|
+
"directory": "packages/es-plus"
|
|
55
|
+
},
|
|
56
|
+
"homepage": "https://liujiaao.github.io/es-plus/",
|
|
57
|
+
"bugs": {
|
|
58
|
+
"url": "https://github.com/liujiaao/es-plus/issues"
|
|
59
|
+
},
|
|
60
|
+
"publishConfig": {
|
|
61
|
+
"access": "public",
|
|
62
|
+
"registry": "https://registry.npmjs.org/"
|
|
63
|
+
},
|
|
64
|
+
"peerDependencies": {
|
|
65
|
+
"vue": "^3.2.0",
|
|
66
|
+
"element-plus": "^2.2.0",
|
|
67
|
+
"@element-plus/icons-vue": "^2.1.0"
|
|
68
|
+
},
|
|
69
|
+
"devDependencies": {
|
|
70
|
+
"@vitejs/plugin-vue": "^5.0.0",
|
|
71
|
+
"@vitejs/plugin-vue-jsx": "^4.0.0",
|
|
72
|
+
"@vue/test-utils": "^2.4.0",
|
|
73
|
+
"happy-dom": "^14.0.0",
|
|
74
|
+
"sass": "^1.70.0",
|
|
75
|
+
"typescript": "^5.3.0",
|
|
76
|
+
"vite": "^5.0.0",
|
|
77
|
+
"vite-plugin-dts": "^3.7.0",
|
|
78
|
+
"vitest": "^1.2.0",
|
|
79
|
+
"vue": "^3.4.0",
|
|
80
|
+
"vue-tsc": "^1.8.0",
|
|
81
|
+
"element-plus": "^2.5.0"
|
|
82
|
+
}
|
|
83
|
+
}
|
|
@@ -14,6 +14,10 @@
|
|
|
14
14
|
"type": "string",
|
|
15
15
|
"description": "Display label for the form field"
|
|
16
16
|
},
|
|
17
|
+
"labelKey": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"description": "i18n translation key for the label. When a global t() function is configured via app.use(ESPlus, { t }), the label will be translated using t(labelKey). Falls back to label when t() is not configured"
|
|
20
|
+
},
|
|
17
21
|
"formtype": {
|
|
18
22
|
"type": "string",
|
|
19
23
|
"enum": [
|
|
@@ -17,6 +17,10 @@
|
|
|
17
17
|
"type": "string",
|
|
18
18
|
"description": "Column header text"
|
|
19
19
|
},
|
|
20
|
+
"labelKey": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "i18n translation key for the column header. When a global t() function is configured via app.use(ESPlus, { t }), the header will be translated using t(labelKey). Falls back to label when t() is not configured"
|
|
23
|
+
},
|
|
20
24
|
"width": {
|
|
21
25
|
"oneOf": [
|
|
22
26
|
{ "type": "number" },
|
|
@@ -92,8 +96,11 @@
|
|
|
92
96
|
},
|
|
93
97
|
"clickEvent": {
|
|
94
98
|
"description": "Function (row) => void. Click handler receiving the row data"
|
|
99
|
+
},
|
|
100
|
+
"permissionValue": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"description": "Permission code for button visibility. When a global permission() function is configured, buttons with unmatched permissionValue will be hidden"
|
|
95
103
|
}
|
|
96
|
-
}
|
|
97
104
|
}
|
|
98
105
|
},
|
|
99
106
|
"type": {
|