@vrojs/element-plus 0.0.7 → 0.0.8
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/index.d.ts +5 -0
- package/dist/index.js +125 -83
- package/dist/locale/index.js +6 -7
- package/dist/locale/lang/en.d.ts +8 -0
- package/dist/locale/lang/en.js +8 -0
- package/dist/locale/lang/zh-cn.d.ts +8 -0
- package/dist/locale/lang/zh-cn.js +8 -0
- package/dist/locale/useLocale.d.ts +1 -48
- package/dist/locale/useLocale.js +16 -17
- package/dist/style/deps.js +7 -0
- package/dist/style/index.css +1 -1
- package/dist/style/index.js +7 -0
- package/dist/utils/elTableColumnProps.d.ts +149 -0
- package/dist/utils/elTableColumnProps.js +152 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/index.js +4 -2
- package/dist/vro-el-checkbox-group/index.d.ts +1 -1
- package/dist/vro-el-checkbox-group/vro-el-checkbox-group.vue.d.ts +1 -1
- package/dist/vro-el-checkbox-group/vro-el-checkbox-group.vue.js +10 -10
- package/dist/vro-el-config-provider/config.d.ts +14 -0
- package/dist/vro-el-config-provider/config.js +36 -0
- package/dist/vro-el-config-provider/index.d.ts +16 -0
- package/dist/vro-el-config-provider/index.js +8 -2
- package/dist/vro-el-config-provider/types.d.ts +7 -0
- package/dist/vro-el-config-provider/types.js +7 -0
- package/dist/vro-el-config-provider/vro-el-config-provider.vue.d.ts +9 -0
- package/dist/vro-el-config-provider/vro-el-config-provider.vue.js +11 -11
- package/dist/vro-el-file-upload/index.d.ts +6 -6
- package/dist/vro-el-file-upload/style/index.css +1 -1
- package/dist/vro-el-file-upload/types.d.ts +9 -2
- package/dist/vro-el-file-upload/vro-el-file-upload.vue.d.ts +7 -6
- package/dist/vro-el-file-upload/vro-el-file-upload.vue.js +55 -51
- package/dist/vro-el-icon/index.d.ts +28 -40
- package/dist/vro-el-icon/style/css.js +1 -0
- package/dist/vro-el-icon/style/deps.js +1 -1
- package/dist/vro-el-icon/style/index.js +1 -1
- package/dist/vro-el-icon/types.d.ts +16 -13
- package/dist/vro-el-icon/types.js +8 -1
- package/dist/vro-el-icon/vro-el-icon.vue.d.ts +18 -27
- package/dist/vro-el-icon/vro-el-icon.vue.js +27 -23
- package/dist/vro-el-image/index.d.ts +10 -4
- package/dist/vro-el-image/style/css.js +4 -0
- package/dist/vro-el-image/style/index.css +1 -0
- package/dist/vro-el-image/style/index.js +4 -0
- package/dist/vro-el-image/types.d.ts +35 -0
- package/dist/vro-el-image/types.js +24 -1
- package/dist/vro-el-image/utils.d.ts +1 -1
- package/dist/vro-el-image/vro-el-image.vue.d.ts +7 -2
- package/dist/vro-el-image/vro-el-image.vue.js +55 -24
- package/dist/vro-el-image-upload/index.d.ts +1 -1
- package/dist/vro-el-image-upload/style/css.js +4 -0
- package/dist/vro-el-image-upload/style/index.css +1 -1
- package/dist/vro-el-image-upload/style/index.js +4 -0
- package/dist/vro-el-image-upload/types.d.ts +24 -7
- package/dist/vro-el-image-upload/types.js +21 -7
- package/dist/vro-el-image-upload/vro-el-image-upload.vue.d.ts +1 -1
- package/dist/vro-el-image-upload/vro-el-image-upload.vue.js +82 -68
- package/dist/vro-el-radio-group/index.d.ts +1 -1
- package/dist/vro-el-radio-group/vro-el-radio-group.vue.d.ts +1 -1
- package/dist/vro-el-radio-group/vro-el-radio-group.vue.js +12 -12
- package/dist/vro-el-schema-filter/index.d.ts +27 -31
- package/dist/vro-el-schema-filter/style/css.js +5 -0
- package/dist/vro-el-schema-filter/style/index.css +1 -1
- package/dist/vro-el-schema-filter/style/index.js +5 -0
- package/dist/vro-el-schema-filter/types.d.ts +17 -0
- package/dist/vro-el-schema-filter/vro-el-schema-filter.vue.d.ts +38 -43
- package/dist/vro-el-schema-filter/vro-el-schema-filter.vue.js +63 -44
- package/dist/vro-el-schema-form/index.d.ts +16 -18
- package/dist/vro-el-schema-form/style/css.js +5 -0
- package/dist/vro-el-schema-form/style/index.css +1 -1
- package/dist/vro-el-schema-form/style/index.js +5 -0
- package/dist/vro-el-schema-form/types.d.ts +65 -7
- package/dist/vro-el-schema-form/useVroElSchemaForm.d.ts +33 -37
- package/dist/vro-el-schema-form/useVroElSchemaForm.js +13 -13
- package/dist/vro-el-schema-form/vro-el-schema-form.vue.d.ts +11 -13
- package/dist/vro-el-schema-form/vro-el-schema-form.vue.js +79 -79
- package/dist/vro-el-schema-form-dialog/function-call.js +10 -7
- package/dist/vro-el-schema-form-dialog/index.d.ts +111 -142
- package/dist/vro-el-schema-form-dialog/style/css.js +5 -0
- package/dist/vro-el-schema-form-dialog/style/index.css +1 -1
- package/dist/vro-el-schema-form-dialog/style/index.js +5 -0
- package/dist/vro-el-schema-form-dialog/types.d.ts +25 -16
- package/dist/vro-el-schema-form-dialog/types.js +6 -11
- package/dist/vro-el-schema-form-dialog/vro-el-schema-form-dialog.vue.d.ts +92 -113
- package/dist/vro-el-schema-form-dialog/vro-el-schema-form-dialog.vue.js +83 -87
- package/dist/vro-el-schema-form-drawer/function-call.d.ts +4 -0
- package/dist/vro-el-schema-form-drawer/function-call.js +20 -0
- package/dist/vro-el-schema-form-drawer/index.d.ts +2207 -0
- package/dist/vro-el-schema-form-drawer/index.js +16 -0
- package/dist/vro-el-schema-form-drawer/injection.d.ts +9 -0
- package/dist/vro-el-schema-form-drawer/injection.js +9 -0
- package/dist/vro-el-schema-form-drawer/style/css.d.ts +0 -0
- package/dist/vro-el-schema-form-drawer/style/css.js +24 -0
- package/dist/vro-el-schema-form-drawer/style/deps.d.ts +0 -0
- package/dist/vro-el-schema-form-drawer/style/deps.js +24 -0
- package/dist/vro-el-schema-form-drawer/style/index.css +1 -0
- package/dist/vro-el-schema-form-drawer/style/index.d.ts +0 -0
- package/dist/vro-el-schema-form-drawer/style/index.js +48 -0
- package/dist/vro-el-schema-form-drawer/types.d.ts +110 -0
- package/dist/vro-el-schema-form-drawer/types.js +75 -0
- package/dist/vro-el-schema-form-drawer/useVroElSchemaFormDrawer.d.ts +14 -0
- package/dist/vro-el-schema-form-drawer/useVroElSchemaFormDrawer.js +18 -0
- package/dist/vro-el-schema-form-drawer/vro-el-schema-form-drawer.vue.d.ts +1832 -0
- package/dist/vro-el-schema-form-drawer/vro-el-schema-form-drawer.vue.js +134 -0
- package/dist/vro-el-schema-form-drawer/vro-el-schema-form-drawer.vue2.js +4 -0
- package/dist/vro-el-select/index.d.ts +11 -11
- package/dist/vro-el-select/vro-el-select.vue.d.ts +11 -11
- package/dist/vro-el-select/vro-el-select.vue.js +11 -11
- package/dist/vro-el-skeleton/index.d.ts +9 -73
- package/dist/vro-el-skeleton/style/index.css +1 -1
- package/dist/vro-el-skeleton/types.d.ts +32 -24
- package/dist/vro-el-skeleton/types.js +3 -23
- package/dist/vro-el-skeleton/vro-el-skeleton.vue.d.ts +7 -48
- package/dist/vro-el-skeleton/vro-el-skeleton.vue.js +48 -46
- package/dist/vro-el-table/createUseVroElTable.d.ts +9 -0
- package/dist/vro-el-table/createUseVroElTable.js +7 -0
- package/dist/vro-el-table/index.js +13 -0
- package/dist/vro-el-table/style/css.d.ts +0 -0
- package/dist/vro-el-table/style/css.js +29 -0
- package/dist/vro-el-table/style/deps.d.ts +0 -0
- package/dist/vro-el-table/style/deps.js +28 -0
- package/dist/vro-el-table/style/index.css +1 -0
- package/dist/vro-el-table/style/index.d.ts +0 -0
- package/dist/vro-el-table/style/index.js +57 -0
- package/dist/vro-el-table/types.d.ts +97 -0
- package/dist/vro-el-table/types.js +66 -0
- package/dist/vro-el-table/useVroElTable.d.ts +43 -0
- package/dist/vro-el-table/useVroElTable.js +47 -0
- package/dist/vro-el-table/vro-el-table.vue.js +94 -0
- package/dist/vro-el-table/vro-el-table.vue2.js +4 -0
- package/dist/vro-el-table-actions-column/index.d.ts +269 -0
- package/dist/vro-el-table-actions-column/index.js +9 -0
- package/dist/vro-el-table-actions-column/style/css.d.ts +0 -0
- package/dist/vro-el-table-actions-column/style/css.js +4 -0
- package/dist/vro-el-table-actions-column/style/deps.d.ts +0 -0
- package/dist/vro-el-table-actions-column/style/deps.js +5 -0
- package/dist/vro-el-table-actions-column/style/index.css +1 -0
- package/dist/vro-el-table-actions-column/style/index.d.ts +0 -0
- package/dist/vro-el-table-actions-column/style/index.js +9 -0
- package/dist/vro-el-table-actions-column/types.d.ts +139 -0
- package/dist/vro-el-table-actions-column/types.js +37 -0
- package/dist/vro-el-table-actions-column/vro-el-table-actions-column.vue.d.ts +167 -0
- package/dist/vro-el-table-actions-column/vro-el-table-actions-column.vue.js +101 -0
- package/dist/vro-el-table-actions-column/vro-el-table-actions-column.vue2.js +4 -0
- package/dist/vro-el-table-column/index.d.ts +257 -0
- package/dist/vro-el-table-column/index.js +9 -0
- package/dist/vro-el-table-column/style/css.d.ts +0 -0
- package/dist/vro-el-table-column/style/css.js +6 -0
- package/dist/vro-el-table-column/style/deps.d.ts +0 -0
- package/dist/vro-el-table-column/style/deps.js +1 -0
- package/dist/vro-el-table-column/style/index.css +1 -0
- package/dist/vro-el-table-column/style/index.d.ts +0 -0
- package/dist/vro-el-table-column/style/index.js +7 -0
- package/dist/vro-el-table-column/types.d.ts +141 -0
- package/dist/vro-el-table-column/types.js +43 -0
- package/dist/vro-el-table-column/vro-el-table-column.vue.d.ts +161 -0
- package/dist/vro-el-table-column/vro-el-table-column.vue.js +66 -0
- package/dist/vro-el-table-column/vro-el-table-column.vue2.js +4 -0
- package/dist/vro-el-table-column-group/index.d.ts +23 -0
- package/dist/vro-el-table-column-group/index.js +13 -0
- package/dist/vro-el-table-column-group/style/css.d.ts +0 -0
- package/dist/vro-el-table-column-group/style/css.js +9 -0
- package/dist/vro-el-table-column-group/style/deps.d.ts +0 -0
- package/dist/vro-el-table-column-group/style/deps.js +5 -0
- package/dist/vro-el-table-column-group/style/index.d.ts +0 -0
- package/dist/vro-el-table-column-group/style/index.js +14 -0
- package/dist/vro-el-table-column-group/types.d.ts +87 -0
- package/dist/vro-el-table-column-group/types.js +12 -0
- package/dist/vro-el-table-column-group/useVroElTableColumnGroup.d.ts +2 -0
- package/dist/vro-el-table-column-group/useVroElTableColumnGroup.js +10 -0
- package/dist/vro-el-table-column-group/vro-el-table-column-group.vue.d.ts +14 -0
- package/dist/vro-el-table-column-group/vro-el-table-column-group.vue.js +29 -0
- package/dist/vro-el-table-column-group/vro-el-table-column-group.vue2.js +4 -0
- package/dist/vro-el-table-column-group/vroElTableColumnGroupColumnManager.d.ts +2 -0
- package/dist/vro-el-table-column-group/vroElTableColumnGroupColumnManager.js +9 -0
- package/dist/vro-el-tags/index.d.ts +234 -187
- package/dist/vro-el-tags/style/css.js +1 -0
- package/dist/vro-el-tags/style/index.css +1 -0
- package/dist/vro-el-tags/style/index.js +1 -0
- package/dist/vro-el-tags/types.d.ts +37 -1
- package/dist/vro-el-tags/types.js +17 -1
- package/dist/vro-el-tags/vro-el-tags.vue.d.ts +219 -8
- package/dist/vro-el-tags/vro-el-tags.vue.js +55 -45
- package/dist/vro-el-tree/index.d.ts +3235 -32
- package/dist/vro-el-tree/style/index.css +1 -1
- package/dist/vro-el-tree/types.d.ts +124 -5
- package/dist/vro-el-tree/types.js +12 -6
- package/dist/vro-el-tree/vro-el-tree.vue.d.ts +6020 -20
- package/dist/vro-el-tree/vro-el-tree.vue.js +54 -36
- package/package.json +6 -6
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { withInstall as r } from "@vrojs/base";
|
|
2
|
+
import o from "./vro-el-schema-form-drawer.vue.js";
|
|
3
|
+
import { showVroElSchemaFormDrawer as l } from "./function-call.js";
|
|
4
|
+
import { useVroElSchemaFormDrawerInstance as f, vroElSchemaFormDrawerInjectionKey as h } from "./injection.js";
|
|
5
|
+
import { vroElSchemaFormDrawerProps as w } from "./types.js";
|
|
6
|
+
import { useVroElSchemaFormDrawer as D } from "./useVroElSchemaFormDrawer.js";
|
|
7
|
+
const a = r(o);
|
|
8
|
+
export {
|
|
9
|
+
a as VroElSchemaFormDrawer,
|
|
10
|
+
a as default,
|
|
11
|
+
l as showVroElSchemaFormDrawer,
|
|
12
|
+
D as useVroElSchemaFormDrawer,
|
|
13
|
+
f as useVroElSchemaFormDrawerInstance,
|
|
14
|
+
h as vroElSchemaFormDrawerInjectionKey,
|
|
15
|
+
w as vroElSchemaFormDrawerProps
|
|
16
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { InjectionKey } from 'vue';
|
|
2
|
+
export declare const vroElSchemaFormDrawerInjectionKey: InjectionKey<{
|
|
3
|
+
confirm: (...args: any[]) => Promise<void>;
|
|
4
|
+
hide: (reason?: any) => Promise<void>;
|
|
5
|
+
}>;
|
|
6
|
+
export declare function useVroElSchemaFormDrawerInstance(): {
|
|
7
|
+
confirm: (...args: any[]) => Promise<void>;
|
|
8
|
+
hide: (reason?: any) => Promise<void>;
|
|
9
|
+
} | null;
|
|
File without changes
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import '../../style/base.css';
|
|
2
|
+
import '../../vro-el-file-upload/style/index.css';
|
|
3
|
+
import '../../vro-el-image-upload/style/index.css';
|
|
4
|
+
import '../../vro-el-image/style/index.css';
|
|
5
|
+
import './index.css';
|
|
6
|
+
import '../../vro-el-schema-form/style/index.css';
|
|
7
|
+
import '../../vro-el-tags/style/index.css';
|
|
8
|
+
import '../../vro-el-tree/style/index.css';
|
|
9
|
+
/* empty css */
|
|
10
|
+
/* empty css */
|
|
11
|
+
/* empty css */
|
|
12
|
+
import "@vrojs/base/src/vro-loading/style/css";
|
|
13
|
+
import "@vrojs/base/src/vro-icon/style/css";
|
|
14
|
+
/* empty css */
|
|
15
|
+
/* empty css */
|
|
16
|
+
/* empty css */
|
|
17
|
+
/* empty css */
|
|
18
|
+
/* empty css */
|
|
19
|
+
/* empty css */
|
|
20
|
+
/* empty css */
|
|
21
|
+
/* empty css */
|
|
22
|
+
/* empty css */
|
|
23
|
+
/* empty css */
|
|
24
|
+
/* empty css */
|
|
File without changes
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import "element-plus/es/components/checkbox-group/style/css";
|
|
2
|
+
import "element-plus/es/components/checkbox/style/css";
|
|
3
|
+
import "element-plus/es/components/button/style/css";
|
|
4
|
+
import "element-plus/es/components/icon/style/css";
|
|
5
|
+
import "element-plus/es/components/image/style/css";
|
|
6
|
+
import "element-plus/es/components/loading/style/css";
|
|
7
|
+
import "element-plus/es/components/radio-group/style/css";
|
|
8
|
+
import "element-plus/es/components/radio/style/css";
|
|
9
|
+
import "element-plus/es/components/option/style/css";
|
|
10
|
+
import "element-plus/es/components/select/style/css";
|
|
11
|
+
import "element-plus/es/components/input/style/css";
|
|
12
|
+
import "element-plus/es/components/tag/style/css";
|
|
13
|
+
import "element-plus/es/components/tree/style/css";
|
|
14
|
+
import "element-plus/es/components/cascader/style/css";
|
|
15
|
+
import "element-plus/es/components/col/style/css";
|
|
16
|
+
import "element-plus/es/components/date-picker/style/css";
|
|
17
|
+
import "element-plus/es/components/divider/style/css";
|
|
18
|
+
import "element-plus/es/components/form-item/style/css";
|
|
19
|
+
import "element-plus/es/components/form/style/css";
|
|
20
|
+
import "element-plus/es/components/input-number/style/css";
|
|
21
|
+
import "element-plus/es/components/row/style/css";
|
|
22
|
+
import "element-plus/es/components/tree-select/style/css";
|
|
23
|
+
import "element-plus/es/components/config-provider/style/css";
|
|
24
|
+
import "element-plus/es/components/drawer/style/css";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
:root,:host{--vro-el-schema-form-drawer-padding: 20px;--vro-el-schema-form-drawer-border-color: var(--el-border-color);--vro-el-schema-form-drawer-size: 520px}.vro-el-schema-form-drawer .el-drawer__header{margin-bottom:0;border-bottom:1px solid var(--vro-el-schema-form-drawer-border-color);padding:var(--vro-el-schema-form-drawer-padding)}.vro-el-schema-form-drawer .el-drawer__body{min-width:0;overflow-y:auto}.vro-el-schema-form-drawer .el-drawer__footer{padding:var(--vro-el-schema-form-drawer-padding);border-top:1px solid var(--vro-el-schema-form-drawer-border-color)}.vro-el-schema-form-drawer-footer{display:flex;justify-content:flex-end}
|
|
File without changes
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import '../../style/base.css';
|
|
2
|
+
import '../../vro-el-file-upload/style/index.css';
|
|
3
|
+
import '../../vro-el-image-upload/style/index.css';
|
|
4
|
+
import '../../vro-el-image/style/index.css';
|
|
5
|
+
import './index.css';
|
|
6
|
+
import '../../vro-el-schema-form/style/index.css';
|
|
7
|
+
import '../../vro-el-tags/style/index.css';
|
|
8
|
+
import '../../vro-el-tree/style/index.css';
|
|
9
|
+
import "element-plus/es/components/checkbox-group/style/css";
|
|
10
|
+
import "element-plus/es/components/checkbox/style/css";
|
|
11
|
+
import "element-plus/es/components/button/style/css";
|
|
12
|
+
import "element-plus/es/components/icon/style/css";
|
|
13
|
+
import "element-plus/es/components/image/style/css";
|
|
14
|
+
import "element-plus/es/components/loading/style/css";
|
|
15
|
+
import "element-plus/es/components/radio-group/style/css";
|
|
16
|
+
import "element-plus/es/components/radio/style/css";
|
|
17
|
+
import "element-plus/es/components/option/style/css";
|
|
18
|
+
import "element-plus/es/components/select/style/css";
|
|
19
|
+
import "element-plus/es/components/input/style/css";
|
|
20
|
+
import "element-plus/es/components/tag/style/css";
|
|
21
|
+
import "element-plus/es/components/tree/style/css";
|
|
22
|
+
import "element-plus/es/components/cascader/style/css";
|
|
23
|
+
import "element-plus/es/components/col/style/css";
|
|
24
|
+
import "element-plus/es/components/date-picker/style/css";
|
|
25
|
+
import "element-plus/es/components/divider/style/css";
|
|
26
|
+
import "element-plus/es/components/form-item/style/css";
|
|
27
|
+
import "element-plus/es/components/form/style/css";
|
|
28
|
+
import "element-plus/es/components/input-number/style/css";
|
|
29
|
+
import "element-plus/es/components/row/style/css";
|
|
30
|
+
import "element-plus/es/components/tree-select/style/css";
|
|
31
|
+
import "element-plus/es/components/config-provider/style/css";
|
|
32
|
+
import "element-plus/es/components/drawer/style/css";
|
|
33
|
+
/* empty css */
|
|
34
|
+
/* empty css */
|
|
35
|
+
/* empty css */
|
|
36
|
+
import "@vrojs/base/src/vro-loading/style/css";
|
|
37
|
+
import "@vrojs/base/src/vro-icon/style/css";
|
|
38
|
+
/* empty css */
|
|
39
|
+
/* empty css */
|
|
40
|
+
/* empty css */
|
|
41
|
+
/* empty css */
|
|
42
|
+
/* empty css */
|
|
43
|
+
/* empty css */
|
|
44
|
+
/* empty css */
|
|
45
|
+
/* empty css */
|
|
46
|
+
/* empty css */
|
|
47
|
+
/* empty css */
|
|
48
|
+
/* empty css */
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { VroSlot } from '@vrojs/base';
|
|
2
|
+
import { DrawerProps } from 'element-plus';
|
|
3
|
+
import { CSSProperties, ExtractPropTypes, PropType } from 'vue';
|
|
4
|
+
import { VroElSchemaFormFieldEvent, VroElSchemaFormFormProps, VroElSchemaFormSchema, VroElSchemaFormSlotProps } from '../vro-el-schema-form';
|
|
5
|
+
export interface VroElSchemaFormDrawerRequest {
|
|
6
|
+
(data: any, schema: VroElSchemaFormSchema): Promise<any>;
|
|
7
|
+
}
|
|
8
|
+
export interface VroElSchemaFormDrawerEmits {
|
|
9
|
+
'change-field': [payload: VroElSchemaFormFieldEvent];
|
|
10
|
+
'input-field': [payload: VroElSchemaFormFieldEvent];
|
|
11
|
+
cancel: [reason?: any];
|
|
12
|
+
confirm: [data: any];
|
|
13
|
+
closed: [];
|
|
14
|
+
}
|
|
15
|
+
export declare const vroElSchemaFormDrawerProps: {
|
|
16
|
+
/**
|
|
17
|
+
* 抽屉标题。
|
|
18
|
+
*/
|
|
19
|
+
title: StringConstructor;
|
|
20
|
+
/**
|
|
21
|
+
* 抽屉弹出方向。
|
|
22
|
+
*/
|
|
23
|
+
direction: {
|
|
24
|
+
type: PropType<DrawerProps["direction"]>;
|
|
25
|
+
default: string;
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* 抽屉尺寸。
|
|
29
|
+
*/
|
|
30
|
+
size: {
|
|
31
|
+
type: PropType<DrawerProps["size"]>;
|
|
32
|
+
default: string;
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* 是否显示抽屉头部。
|
|
36
|
+
*/
|
|
37
|
+
withHeader: {
|
|
38
|
+
type: BooleanConstructor;
|
|
39
|
+
default: boolean;
|
|
40
|
+
};
|
|
41
|
+
/**
|
|
42
|
+
* 抽屉样式。
|
|
43
|
+
*/
|
|
44
|
+
style: {
|
|
45
|
+
type: PropType<CSSProperties>;
|
|
46
|
+
default: () => {};
|
|
47
|
+
};
|
|
48
|
+
/**
|
|
49
|
+
* 确认前的提交请求,返回值会作为 confirm 事件参数。
|
|
50
|
+
*/
|
|
51
|
+
request: PropType<VroElSchemaFormDrawerRequest>;
|
|
52
|
+
/**
|
|
53
|
+
* 透传给 ElForm 的属性,不包含 model 和 rules。
|
|
54
|
+
*/
|
|
55
|
+
formProps: {
|
|
56
|
+
type: PropType<VroElSchemaFormFormProps>;
|
|
57
|
+
default: () => {
|
|
58
|
+
labelPosition: string;
|
|
59
|
+
};
|
|
60
|
+
};
|
|
61
|
+
/**
|
|
62
|
+
* 是否显示取消按钮。
|
|
63
|
+
*/
|
|
64
|
+
showCancelButton: {
|
|
65
|
+
type: BooleanConstructor;
|
|
66
|
+
default: boolean;
|
|
67
|
+
};
|
|
68
|
+
/**
|
|
69
|
+
* 是否显示确认按钮。
|
|
70
|
+
*/
|
|
71
|
+
showConfirmButton: {
|
|
72
|
+
type: BooleanConstructor;
|
|
73
|
+
default: boolean;
|
|
74
|
+
};
|
|
75
|
+
/**
|
|
76
|
+
* 取消按钮文本。
|
|
77
|
+
*/
|
|
78
|
+
cancelButtonText: StringConstructor;
|
|
79
|
+
/**
|
|
80
|
+
* 确认按钮文本。
|
|
81
|
+
*/
|
|
82
|
+
confirmButtonText: StringConstructor;
|
|
83
|
+
rowProps: {
|
|
84
|
+
type: PropType<Partial<import('element-plus').RowProps>>;
|
|
85
|
+
default: () => {};
|
|
86
|
+
};
|
|
87
|
+
colProps: {
|
|
88
|
+
type: PropType<Partial<import('element-plus').ColProps>>;
|
|
89
|
+
default: () => {};
|
|
90
|
+
};
|
|
91
|
+
formItemProps: {
|
|
92
|
+
type: PropType<Partial<import('element-plus').FormItemProps>>;
|
|
93
|
+
default: () => {};
|
|
94
|
+
};
|
|
95
|
+
schema: {
|
|
96
|
+
type: PropType<VroElSchemaFormSchema>;
|
|
97
|
+
default: () => {};
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
export type VroElSchemaFormDrawerProps = ExtractPropTypes<typeof vroElSchemaFormDrawerProps>;
|
|
101
|
+
export interface VroElSchemaFormDrawerSlots {
|
|
102
|
+
/**
|
|
103
|
+
* 透传给内部 VroElSchemaForm 的默认插槽。
|
|
104
|
+
*/
|
|
105
|
+
default?: VroSlot;
|
|
106
|
+
/**
|
|
107
|
+
* 转发给内部 VroElSchemaForm 的字段插槽。
|
|
108
|
+
*/
|
|
109
|
+
[key: string]: ((props: VroElSchemaFormSlotProps) => any) | VroSlot | undefined;
|
|
110
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import "../vro-el-schema-form/index.js";
|
|
2
|
+
import { vroElSchemaFormProps as t } from "../vro-el-schema-form/types.js";
|
|
3
|
+
const r = {
|
|
4
|
+
...t,
|
|
5
|
+
/**
|
|
6
|
+
* 抽屉标题。
|
|
7
|
+
*/
|
|
8
|
+
title: String,
|
|
9
|
+
/**
|
|
10
|
+
* 抽屉弹出方向。
|
|
11
|
+
*/
|
|
12
|
+
direction: {
|
|
13
|
+
type: String,
|
|
14
|
+
default: "rtl"
|
|
15
|
+
},
|
|
16
|
+
/**
|
|
17
|
+
* 抽屉尺寸。
|
|
18
|
+
*/
|
|
19
|
+
size: {
|
|
20
|
+
type: [String, Number],
|
|
21
|
+
default: "var(--vro-el-schema-form-drawer-size)"
|
|
22
|
+
},
|
|
23
|
+
/**
|
|
24
|
+
* 是否显示抽屉头部。
|
|
25
|
+
*/
|
|
26
|
+
withHeader: {
|
|
27
|
+
type: Boolean,
|
|
28
|
+
default: !0
|
|
29
|
+
},
|
|
30
|
+
/**
|
|
31
|
+
* 抽屉样式。
|
|
32
|
+
*/
|
|
33
|
+
style: {
|
|
34
|
+
type: Object,
|
|
35
|
+
default: () => ({})
|
|
36
|
+
},
|
|
37
|
+
/**
|
|
38
|
+
* 确认前的提交请求,返回值会作为 confirm 事件参数。
|
|
39
|
+
*/
|
|
40
|
+
request: Function,
|
|
41
|
+
/**
|
|
42
|
+
* 透传给 ElForm 的属性,不包含 model 和 rules。
|
|
43
|
+
*/
|
|
44
|
+
formProps: {
|
|
45
|
+
type: Object,
|
|
46
|
+
default: () => ({
|
|
47
|
+
labelPosition: "top"
|
|
48
|
+
})
|
|
49
|
+
},
|
|
50
|
+
/**
|
|
51
|
+
* 是否显示取消按钮。
|
|
52
|
+
*/
|
|
53
|
+
showCancelButton: {
|
|
54
|
+
type: Boolean,
|
|
55
|
+
default: !0
|
|
56
|
+
},
|
|
57
|
+
/**
|
|
58
|
+
* 是否显示确认按钮。
|
|
59
|
+
*/
|
|
60
|
+
showConfirmButton: {
|
|
61
|
+
type: Boolean,
|
|
62
|
+
default: !0
|
|
63
|
+
},
|
|
64
|
+
/**
|
|
65
|
+
* 取消按钮文本。
|
|
66
|
+
*/
|
|
67
|
+
cancelButtonText: String,
|
|
68
|
+
/**
|
|
69
|
+
* 确认按钮文本。
|
|
70
|
+
*/
|
|
71
|
+
confirmButtonText: String
|
|
72
|
+
};
|
|
73
|
+
export {
|
|
74
|
+
r as vroElSchemaFormDrawerProps
|
|
75
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { VroElSchemaFormSchema, VroElSchemaFormSchemaField } from '../vro-el-schema-form';
|
|
3
|
+
import { showVroElSchemaFormDrawer } from './function-call';
|
|
4
|
+
export interface UseVroElSchemaFormDrawerOptions<S extends VroElSchemaFormSchema> {
|
|
5
|
+
instanceRef?: Ref<any>;
|
|
6
|
+
onGenerate?: (schema: S, ...args: any[]) => void;
|
|
7
|
+
onSuccess?: (schema: S, ...args: any[]) => void;
|
|
8
|
+
}
|
|
9
|
+
export interface UseVroElSchemaFormDrawerInstance {
|
|
10
|
+
show: typeof showVroElSchemaFormDrawer;
|
|
11
|
+
}
|
|
12
|
+
export declare function useVroElSchemaFormDrawer<T extends VroElSchemaFormSchema, S extends VroElSchemaFormSchema = {
|
|
13
|
+
[P in keyof T]: VroElSchemaFormSchemaField;
|
|
14
|
+
}>(generator: () => T | Promise<T>, task: (schema: S, instance: UseVroElSchemaFormDrawerInstance, ...args: any[]) => Promise<any>, options?: UseVroElSchemaFormDrawerOptions<S>): readonly [Ref<S | undefined, S | undefined>, (...args: any[]) => Promise<void>];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import l from "@daysnap/banana";
|
|
2
|
+
import { ref as f, getCurrentInstance as p } from "vue";
|
|
3
|
+
import { showVroElSchemaFormDrawer as v } from "./function-call.js";
|
|
4
|
+
function x(t, a, o = {}) {
|
|
5
|
+
const { onGenerate: r, onSuccess: c, instanceRef: i } = o, e = f(), m = p();
|
|
6
|
+
return [e, async (...n) => {
|
|
7
|
+
e.value = await t(), n[0] && l.assignment(n[0], e.value), r?.(e.value, ...n), await a(
|
|
8
|
+
e.value,
|
|
9
|
+
i?.value ?? {
|
|
10
|
+
show: (s, u) => v(s, u ?? m?.appContext)
|
|
11
|
+
},
|
|
12
|
+
...n
|
|
13
|
+
), c?.(e.value, ...n);
|
|
14
|
+
}];
|
|
15
|
+
}
|
|
16
|
+
export {
|
|
17
|
+
x as useVroElSchemaFormDrawer
|
|
18
|
+
};
|