@byteluck-fe/model-driven-engine 2.7.0-alpha.3 → 2.7.0-alpha.30a
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/esm/common/ActionManager.js +28 -28
- package/dist/esm/common/DataManager.js +12 -12
- package/dist/esm/common/Engine.js +248 -172
- package/dist/esm/common/OkWorker.js +6 -6
- package/dist/esm/common/Plugin.js +2 -2
- package/dist/esm/common/Runtime.js +98 -55
- package/dist/esm/common/Store.js +26 -29
- package/dist/esm/common/checkerValue.js +87 -80
- package/dist/esm/common/proxyState.js +16 -14
- package/dist/esm/plugins/CalcPlugin.js +26 -26
- package/dist/esm/plugins/ControlsEventPlugin.js +16 -16
- package/dist/esm/plugins/ES6ModulePlugin.js +65 -36
- package/dist/esm/plugins/LifecycleEventPlugin.js +26 -26
- package/dist/esm/plugins/StylePlugin.js +7 -7
- package/dist/esm/utils/runtimeUtils.js +2 -1
- package/dist/index.umd.js +9 -10
- package/dist/types/common/Engine.d.ts +5 -4
- package/dist/types/common/Runtime.d.ts +1 -0
- package/dist/types/plugins/ES6ModulePlugin.d.ts +2 -1
- package/package.json +4 -4
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ControlRuntimeInstance, ControlsInstance, ControlsKeys, DataBind, DeepPartial, LayoutControls, ObjectDataBind, RuntimeControl, RuntimeListControl, Schema } from '@byteluck-fe/model-driven-core';
|
|
1
|
+
import { ControlExport, ControlRuntimeInstance, ControlsInstance, ControlsKeys, DataBind, DeepPartial, LayoutControls, ObjectDataBind, RuntimeControl, RuntimeListControl, Schema } from '@byteluck-fe/model-driven-core';
|
|
2
2
|
import { Callback, Watcher } from '@byteluck-fe/model-driven-shared';
|
|
3
3
|
import { Plugin } from './Plugin';
|
|
4
4
|
import { Runtime, RuntimeProps } from './Runtime';
|
|
@@ -60,8 +60,8 @@ declare class Engine extends Watcher<EventKeys> {
|
|
|
60
60
|
private debugLog;
|
|
61
61
|
use(plugin: Plugin): this;
|
|
62
62
|
registerControl(...arg: Parameters<Runtime['register']>): this;
|
|
63
|
-
static register(
|
|
64
|
-
static judgeControlIsRegistered(control: Parameters<
|
|
63
|
+
static register(control: ControlExport): typeof import("@byteluck-fe/model-driven-core").RegisterControls;
|
|
64
|
+
static judgeControlIsRegistered(control: Parameters<typeof Runtime['register']>[0]): boolean;
|
|
65
65
|
mount(): void;
|
|
66
66
|
destroy(): void;
|
|
67
67
|
private _handlerProxyState;
|
|
@@ -79,6 +79,7 @@ declare class Engine extends Watcher<EventKeys> {
|
|
|
79
79
|
createControlInstance: <T extends never>(type: T, initSchema?: DeepPartial<Schema<T, InstanceType<import("@byteluck-fe/model-driven-core").Controls[T]["Property"]>>> | undefined) => InstanceType<import("@byteluck-fe/model-driven-core").ControlsConstructor<T, "Runtime">> | undefined;
|
|
80
80
|
schemaEvent(eventKey: 'schema-change', payload: SchemaEventPayload): void;
|
|
81
81
|
updateInstanceProps(instance: SchemaEventPayload['instance'] | string, props: string, value: unknown, rowIndex?: number): void;
|
|
82
|
+
getRule(controlType: string, props: any): any[];
|
|
82
83
|
getAllRules(controlId?: string): {
|
|
83
84
|
rules: import("async-validator").Rules | undefined;
|
|
84
85
|
antdRules: import("async-validator").Rules | undefined;
|
|
@@ -105,7 +106,7 @@ declare class Engine extends Watcher<EventKeys> {
|
|
|
105
106
|
* @param rowIndex 行下标 - 如果是明细子表中的控件需要提供
|
|
106
107
|
* */
|
|
107
108
|
getField(dataCode: string, fieldCode?: string, rowIndex?: number): unknown;
|
|
108
|
-
getData(dataCode: string):
|
|
109
|
+
getData(dataCode: string): any;
|
|
109
110
|
/**
|
|
110
111
|
* 通过dataCode和fieldCode来设置控件的值
|
|
111
112
|
* @param dataCode 模型编码 - 如果是主表的话就是主表的模型编码,明细子表的话就是子表的模型编码
|
|
@@ -10,6 +10,7 @@ export declare class Runtime extends RegisterControls<'Runtime'> {
|
|
|
10
10
|
private _instance;
|
|
11
11
|
private _flatInstances;
|
|
12
12
|
private _instanceMap;
|
|
13
|
+
private _controlParentIdMap;
|
|
13
14
|
constructor(props: RuntimeProps);
|
|
14
15
|
getFlatInstances(): ControlRuntimeInstance<ControlsKeys>[];
|
|
15
16
|
get schema(): any;
|
|
@@ -20,7 +20,8 @@ export declare class ES6ModulePlugin implements Plugin {
|
|
|
20
20
|
private config;
|
|
21
21
|
private engine;
|
|
22
22
|
private env;
|
|
23
|
-
|
|
23
|
+
private eventJs;
|
|
24
|
+
constructor(config: ActionConfig, env: any, eventJs: any);
|
|
24
25
|
apply(engine: Engine): void;
|
|
25
26
|
}
|
|
26
27
|
export declare function parseModule(action: ActionConfig, engine: Engine, env: any): Module | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@byteluck-fe/model-driven-engine",
|
|
3
|
-
"version": "2.7.0-alpha.
|
|
3
|
+
"version": "2.7.0-alpha.30a",
|
|
4
4
|
"description": "> TODO: description",
|
|
5
5
|
"author": "郝晨光 <2293885211@qq.com>",
|
|
6
6
|
"homepage": "",
|
|
@@ -26,13 +26,13 @@
|
|
|
26
26
|
"postpublish": "node ../../scripts/postpublish.js"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@byteluck-fe/model-driven-core": "2.7.0-alpha.
|
|
30
|
-
"@byteluck-fe/model-driven-shared": "2.7.0-alpha.
|
|
29
|
+
"@byteluck-fe/model-driven-core": "2.7.0-alpha.28a",
|
|
30
|
+
"@byteluck-fe/model-driven-shared": "2.7.0-alpha.28a",
|
|
31
31
|
"@types/mathjs": "^9.4.2",
|
|
32
32
|
"mathjs": "^11.3.3"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@types/node": "~18.0.6"
|
|
36
36
|
},
|
|
37
|
-
"gitHead": "
|
|
37
|
+
"gitHead": "e391dcad620e5c394659df9c51d47a81c571ede4"
|
|
38
38
|
}
|