cnhis-design-vue 3.1.15-beta.7 → 3.1.16-beta.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/es/packages/big-table/src/hooks/useAnnotation.js +1 -2
- package/es/packages/big-table/src/hooks/useColumnConfigAdaptor.js +7 -2
- package/es/packages/big-table/src/hooks/useEdit.js +16 -8
- package/es/packages/fabric-chart/src/hooks/useDraw.js +1 -0
- package/es/packages/fabric-chart/src/hooks/useLeft.js +1 -2
- package/es/packages/form-config/index.d.ts +13854 -0
- package/es/packages/form-config/index.js +10 -0
- package/es/packages/form-config/src/FormConfig.js +113 -0
- package/es/packages/form-config/src/FormConfig.vue.d.ts +13856 -0
- package/es/packages/form-config/src/components/FormConfigCreator.js +97 -0
- package/es/packages/form-config/src/components/FormConfigCreator.vue.d.ts +5094 -0
- package/es/packages/form-config/src/components/FormConfigEdit.js +81 -0
- package/es/packages/form-config/src/components/FormConfigEdit.vue.d.ts +5336 -0
- package/es/packages/form-config/src/constants/index.d.ts +28 -0
- package/es/packages/form-config/src/constants/index.js +28 -0
- package/es/packages/form-config/src/hooks/index.d.ts +2 -0
- package/es/packages/form-config/src/hooks/index.js +2 -0
- package/es/packages/form-config/src/hooks/useConfigurationField.d.ts +6 -0
- package/es/packages/form-config/src/hooks/useConfigurationField.js +103 -0
- package/es/packages/form-config/src/hooks/usePresetRenderer.d.ts +5 -0
- package/es/packages/form-config/src/hooks/usePresetRenderer.js +117 -0
- package/es/packages/form-config/src/hooks/useSortable.d.ts +11 -0
- package/es/packages/form-config/src/hooks/useSortable.js +31 -0
- package/es/packages/form-config/src/types/index.d.ts +18 -0
- package/es/packages/form-config/src/types/index.js +1 -0
- package/es/packages/form-config/style/index.css +108 -0
- package/es/packages/form-render/index.d.ts +3 -3
- package/es/packages/form-render/src/FormRender.vue.d.ts +3 -3
- package/es/packages/form-render/src/components/renderer/combination/index.js +3 -3
- package/es/packages/form-render/src/components/renderer/date.d.ts +2 -2
- package/es/packages/form-render/src/components/renderer/formItem.js +3 -3
- package/es/packages/form-render/src/components/renderer/select.js +16 -9
- package/es/packages/form-render/src/hooks/useAsyncQueue.d.ts +2 -2
- package/es/packages/form-render/src/hooks/useAsyncQueue.js +4 -8
- package/es/packages/form-render/src/hooks/useFieldListAdaptor.js +4 -3
- package/es/packages/form-render/src/hooks/useFormContext.js +10 -4
- package/es/packages/form-render/src/hooks/useFormRenderLifeCycle.d.ts +2 -2
- package/es/packages/form-render/src/types/fieldItem.d.ts +8 -0
- package/es/packages/form-render/src/types/index.d.ts +7 -3
- package/es/packages/form-render/src/utils/index.d.ts +3 -2
- package/es/packages/form-render/src/utils/index.js +30 -7
- package/es/packages/form-table/src/hooks/useNuiThemeOverrides.js +1 -1
- package/es/packages/index.css +108 -0
- package/es/packages/index.d.ts +4 -1
- package/es/packages/index.js +5 -2
- package/es/packages/shortcut-provider/index.d.ts +17 -2
- package/es/packages/shortcut-provider/index.js +1 -1
- package/es/packages/shortcut-provider/src/ShortcutProvider.js +5 -1
- package/es/packages/shortcut-provider/src/ShortcutProvider.vue.d.ts +17 -2
- package/es/packages/shortcut-provider/src/hooks/index.js +1 -1
- package/es/packages/shortcut-provider/src/hooks/useShortcuts.d.ts +10 -10
- package/es/packages/shortcut-provider/src/hooks/useShortcuts.js +45 -38
- package/es/packages/shortcut-provider/src/types/index.d.ts +2 -19
- package/es/packages/shortcut-setter/index.d.ts +2 -6040
- package/es/packages/shortcut-setter/src/ShortcutSetter.js +60 -10
- package/es/packages/shortcut-setter/src/ShortcutSetter.vue.d.ts +1 -6041
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.js +26 -95
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.vue.d.ts +30 -3363
- package/es/packages/shortcut-setter/src/types/index.d.ts +6 -0
- package/es/packages/shortcut-setter/src/types/index.js +1 -0
- package/es/src/utils/state.d.ts +29 -0
- package/es/src/utils/state.js +44 -0
- package/package.json +2 -1
- package/es/packages/shortcut-setter/constant/index.d.ts +0 -4
- package/es/packages/shortcut-setter/constant/index.js +0 -7
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { defineComponent, ref, openBlock, createBlock, unref, withCtx, createVNode, createTextVNode } from 'vue';
|
|
2
|
+
import { NButtonGroup, NPopconfirm, NButton } from 'naive-ui';
|
|
3
|
+
import { EditAbleField } from '../../../../packages/form-config/src/constants';
|
|
4
|
+
import { useConfigurationField } from '../../../../packages/form-config/src/hooks/useConfigurationField';
|
|
5
|
+
import '../../../index.js';
|
|
6
|
+
import _export_sfc from '../../../../_virtual/plugin-vue_export-helper.js';
|
|
7
|
+
import FormRender from '../../../form-render/index.js';
|
|
8
|
+
|
|
9
|
+
const _hoisted_1 = /* @__PURE__ */ createTextVNode("\u65B0\u5EFA\u5206\u884C\u7B26");
|
|
10
|
+
const _hoisted_2 = /* @__PURE__ */ createTextVNode("\u65B0\u5EFA\u5206\u7EBF\u680F");
|
|
11
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
12
|
+
__name: "FormConfigCreator",
|
|
13
|
+
emits: {
|
|
14
|
+
submit: (payload) => payload
|
|
15
|
+
},
|
|
16
|
+
setup(__props, { emit }) {
|
|
17
|
+
const linebarField = useConfigurationField().generateFieldListByKeys([
|
|
18
|
+
EditAbleField.ALIAS,
|
|
19
|
+
EditAbleField.ELEM_WIDTH,
|
|
20
|
+
EditAbleField.IS_SHOW,
|
|
21
|
+
EditAbleField.IS_NOT_FOLD
|
|
22
|
+
]);
|
|
23
|
+
const linebarFormRef = ref();
|
|
24
|
+
const lineBreakFormRef = ref();
|
|
25
|
+
const initialData = { is_show: "1", is_not_fold: "0" };
|
|
26
|
+
async function submit(html_type, formRef) {
|
|
27
|
+
if (!formRef)
|
|
28
|
+
return;
|
|
29
|
+
await formRef.validate();
|
|
30
|
+
const formData = formRef.getFormValues();
|
|
31
|
+
emit("submit", { ...formData, html_type, val_key: formData.alias, elem_width: 12 });
|
|
32
|
+
}
|
|
33
|
+
return (_ctx, _cache) => {
|
|
34
|
+
return openBlock(), createBlock(unref(NButtonGroup), { size: "small" }, {
|
|
35
|
+
default: withCtx(() => [
|
|
36
|
+
createVNode(unref(NPopconfirm), {
|
|
37
|
+
width: "200px",
|
|
38
|
+
"show-icon": false,
|
|
39
|
+
"show-arrow": false,
|
|
40
|
+
onPositiveClick: _cache[0] || (_cache[0] = ($event) => submit("LINE_BREAKS", lineBreakFormRef.value))
|
|
41
|
+
}, {
|
|
42
|
+
trigger: withCtx(() => [
|
|
43
|
+
createVNode(unref(NButton), null, {
|
|
44
|
+
default: withCtx(() => [
|
|
45
|
+
_hoisted_1
|
|
46
|
+
]),
|
|
47
|
+
_: 1
|
|
48
|
+
})
|
|
49
|
+
]),
|
|
50
|
+
default: withCtx(() => [
|
|
51
|
+
createVNode(unref(FormRender), {
|
|
52
|
+
ref_key: "lineBreakFormRef",
|
|
53
|
+
ref: lineBreakFormRef,
|
|
54
|
+
size: "small",
|
|
55
|
+
"label-width": "auto",
|
|
56
|
+
"label-placement": "left",
|
|
57
|
+
fieldList: unref(linebarField).slice(0, 1)
|
|
58
|
+
}, null, 8, ["fieldList"])
|
|
59
|
+
]),
|
|
60
|
+
_: 1
|
|
61
|
+
}),
|
|
62
|
+
createVNode(unref(NPopconfirm), {
|
|
63
|
+
width: "300px",
|
|
64
|
+
"show-icon": false,
|
|
65
|
+
"show-arrow": false,
|
|
66
|
+
onPositiveClick: _cache[1] || (_cache[1] = ($event) => submit("LINEBAR", linebarFormRef.value))
|
|
67
|
+
}, {
|
|
68
|
+
trigger: withCtx(() => [
|
|
69
|
+
createVNode(unref(NButton), null, {
|
|
70
|
+
default: withCtx(() => [
|
|
71
|
+
_hoisted_2
|
|
72
|
+
]),
|
|
73
|
+
_: 1
|
|
74
|
+
})
|
|
75
|
+
]),
|
|
76
|
+
default: withCtx(() => [
|
|
77
|
+
createVNode(unref(FormRender), {
|
|
78
|
+
ref_key: "linebarFormRef",
|
|
79
|
+
ref: linebarFormRef,
|
|
80
|
+
"initial-data": initialData,
|
|
81
|
+
size: "small",
|
|
82
|
+
"label-width": "auto",
|
|
83
|
+
"label-placement": "left",
|
|
84
|
+
fieldList: unref(linebarField)
|
|
85
|
+
}, null, 8, ["fieldList"])
|
|
86
|
+
]),
|
|
87
|
+
_: 1
|
|
88
|
+
})
|
|
89
|
+
]),
|
|
90
|
+
_: 1
|
|
91
|
+
});
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
});
|
|
95
|
+
var FormConfigCreator = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "FormConfigCreator.vue"]]);
|
|
96
|
+
|
|
97
|
+
export { FormConfigCreator as default };
|