cnhis-design-vue 3.1.14-beta.14 → 3.1.14-beta.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/es/node_modules/@formily/path/esm/contexts.js +22 -0
- package/es/node_modules/@formily/path/esm/destructor.js +124 -0
- package/es/node_modules/@formily/path/esm/index.js +579 -0
- package/es/node_modules/@formily/path/esm/matcher.js +199 -0
- package/es/node_modules/@formily/path/esm/parser.js +402 -0
- package/es/node_modules/@formily/path/esm/shared.js +73 -0
- package/es/node_modules/@formily/path/esm/tokenizer.js +287 -0
- package/es/node_modules/@formily/path/esm/tokens.js +240 -0
- package/es/node_modules/@formily/path/esm/types.js +17 -0
- package/es/packages/form-render/src/components/renderer/combination.d.ts +6 -0
- package/es/packages/form-render/src/components/renderer/combination.js +53 -16
- package/es/packages/form-render/src/components/renderer/select.js +1 -2
- package/es/packages/form-render/src/components/renderer/simpleComponent.d.ts +1 -0
- package/es/packages/form-render/src/components/renderer/simpleComponent.js +4 -3
- package/es/packages/form-render/src/hooks/useFieldListAdaptor.js +1 -0
- package/es/packages/form-render/src/types/fieldItem.d.ts +1 -0
- package/es/packages/shortcut-provider/src/types/index.d.ts +11 -9
- package/es/packages/shortcut-provider/src/utils/index.js +5 -5
- package/es/packages/shortcut-setter/index.d.ts +3248 -1486
- package/es/packages/shortcut-setter/src/ShortcutSetter.js +9 -5
- package/es/packages/shortcut-setter/src/ShortcutSetter.vue.d.ts +3248 -1486
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.js +24 -11
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.vue.d.ts +1700 -1661
- package/global.d.ts +8 -8
- package/package.json +1 -1
|
@@ -11,12 +11,13 @@ function createPropFor(props) {
|
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
13
|
const textScript = (props) => {
|
|
14
|
-
var _a, _b;
|
|
15
|
-
return createVNode("div", null, [(_b = (_a =
|
|
14
|
+
var _a, _b, _c;
|
|
15
|
+
return createVNode("div", null, [(_c = (_b = createSlot((_a = props.content) != null ? _a : props.value, props)).default) == null ? void 0 : _c.call(_b)]);
|
|
16
16
|
};
|
|
17
17
|
textScript.props = {
|
|
18
18
|
content: {},
|
|
19
|
-
fieldItem: {}
|
|
19
|
+
fieldItem: {},
|
|
20
|
+
value: {}
|
|
20
21
|
};
|
|
21
22
|
const TEXT = connect(textScript, mapProps((props) => {
|
|
22
23
|
var _a;
|
|
@@ -98,6 +98,7 @@ function useFieldListAdaptor(collector, uuid) {
|
|
|
98
98
|
schema["x-decorator-props"].showLabel = false;
|
|
99
99
|
Object.assign(schema["x-component-props"], {
|
|
100
100
|
title: item.alias || item.name,
|
|
101
|
+
maxGroupNum: item.maxGroupNum,
|
|
101
102
|
getProperties: () => item.children || []
|
|
102
103
|
});
|
|
103
104
|
return schema;
|
|
@@ -72,6 +72,7 @@ export declare type FieldItem = {
|
|
|
72
72
|
suffixConfig: FieldItem[] | FieldItem;
|
|
73
73
|
fieldType: 'string' | 'object' | 'array' | 'number' | 'void' | 'boolean' | 'datetime';
|
|
74
74
|
content: string | FormRenderer | Record<string, FormRenderer>;
|
|
75
|
+
maxGroupNum: number;
|
|
75
76
|
properties: FieldItem[];
|
|
76
77
|
children: FieldItem[];
|
|
77
78
|
componentProps: AnyObject;
|
|
@@ -8,19 +8,21 @@ export interface ShortcutSignatureInfo {
|
|
|
8
8
|
alt?: boolean;
|
|
9
9
|
key: string;
|
|
10
10
|
}
|
|
11
|
-
export
|
|
11
|
+
export declare type ShortcutOption = {
|
|
12
12
|
label: string | Render;
|
|
13
|
-
key?: string;
|
|
14
13
|
defaultShortcut: ShortcutSignatureInfo;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
callback(): void;
|
|
15
|
+
} & Partial<{
|
|
16
|
+
placeholder: string;
|
|
17
|
+
editPlaceholder: string;
|
|
18
|
+
key: string;
|
|
19
|
+
order: number;
|
|
20
|
+
debounce: boolean;
|
|
21
|
+
debounceOption: {
|
|
18
22
|
duration?: number;
|
|
19
23
|
};
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
afterTrigger?(): void | Promise<unknown>;
|
|
23
|
-
}
|
|
24
|
+
operation: Array<'disabled' | 'reset'>;
|
|
25
|
+
}>;
|
|
24
26
|
export interface ShortcutItem extends ShortcutOption {
|
|
25
27
|
status: ShortcutStatus;
|
|
26
28
|
currentKeySignature: string;
|
|
@@ -4,7 +4,7 @@ function isKeyboardEvent(event) {
|
|
|
4
4
|
function normalizeSignatureInfo(info) {
|
|
5
5
|
var _a, _b;
|
|
6
6
|
let ctrl, shift, alt;
|
|
7
|
-
const key = (_b = (_a = info.key) == null ? void 0 : _a.
|
|
7
|
+
const key = (_b = (_a = info.key) == null ? void 0 : _a.toUpperCase()) != null ? _b : "";
|
|
8
8
|
if (isKeyboardEvent(info)) {
|
|
9
9
|
ctrl = info.ctrlKey;
|
|
10
10
|
shift = info.shiftKey;
|
|
@@ -18,18 +18,18 @@ function normalizeSignatureInfo(info) {
|
|
|
18
18
|
}
|
|
19
19
|
function getKeySignature(info) {
|
|
20
20
|
const { ctrl, shift, alt, key } = normalizeSignatureInfo(info);
|
|
21
|
-
return `${ctrl ? "
|
|
21
|
+
return `${ctrl ? "Ctrl_" : ""}${shift ? "Shift_" : ""}${alt ? "Alt_" : ""}${key}`;
|
|
22
22
|
}
|
|
23
|
-
const keyBlackList = ["
|
|
23
|
+
const keyBlackList = ["CONTROL", "ALT", "SHIFT"];
|
|
24
24
|
const inBlackList = (key) => {
|
|
25
25
|
return keyBlackList.includes(key);
|
|
26
26
|
};
|
|
27
27
|
function getDisplaySignature(info) {
|
|
28
28
|
const { ctrl, shift, alt, key } = normalizeSignatureInfo(info);
|
|
29
|
-
return `${ctrl ? "
|
|
29
|
+
return `${ctrl ? "Ctrl+ " : ""}${alt ? "Alt + " : ""}${shift ? "Shift + " : ""}${inBlackList(key) ? "" : key}`;
|
|
30
30
|
}
|
|
31
31
|
function transformKey2DisplaySignature(keySignature) {
|
|
32
|
-
return keySignature.
|
|
32
|
+
return keySignature.replace(/_/g, " + ");
|
|
33
33
|
}
|
|
34
34
|
function isShortcutProvider(ele) {
|
|
35
35
|
return ele && ele.getAttribute("is-shortcut-capture") != void 0;
|