@byteluck-fe/model-driven-engine 2.8.0-alpha.1k → 2.8.0-alpha.21

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.
@@ -61,7 +61,7 @@ declare class Engine extends Watcher<EventKeys> {
61
61
  use(plugin: Plugin): this;
62
62
  registerControl(...arg: Parameters<Runtime['register']>): this;
63
63
  static register(control: ControlExport): typeof import("@byteluck-fe/model-driven-core").RegisterControls;
64
- static judgeControlIsRegistered(control: Parameters<typeof Runtime['register']>[0]): boolean;
64
+ static judgeControlIsRegistered(control: Parameters<(typeof Runtime)['register']>[0]): boolean;
65
65
  mount(): void;
66
66
  destroy(): void;
67
67
  private _handlerProxyState;
@@ -86,7 +86,7 @@ declare class Engine extends Watcher<EventKeys> {
86
86
  };
87
87
  getRules(controlId?: string): import("async-validator").Rules | undefined;
88
88
  getAntdRules(controlId?: string): import("async-validator").Rules | undefined;
89
- getState(controlId?: string, rowIndex?: number): unknown;
89
+ getState(controlId?: string, rowIndex?: number): any;
90
90
  getEmptyState(controlId?: string): any;
91
91
  /**
92
92
  * 设置payload的options,提供在不是使用标准api修改state的时候可以传递options,会在本次任务执行完成之后清空
@@ -180,6 +180,7 @@ declare class Engine extends Watcher<EventKeys> {
180
180
  getInstanceInSubtableHeader<T extends ControlsKeys>(instance: ControlRuntimeInstance<T> | RuntimeControl): ControlRuntimeInstance<T> | undefined;
181
181
  setControlConfig(...args: Parameters<Runtime['registerControlConfig']>): Runtime;
182
182
  getControlConfig(control: ControlsKeys): Readonly<Record<string, unknown>> | undefined;
183
- inList(controlId: string): undefined;
183
+ inList(controlId: string): string | undefined;
184
+ findSubtableHeadersControl(controlId: string): undefined;
184
185
  }
185
186
  export { Engine, EventPayload, SchemaEventPayload, EngineProps };
@@ -1,4 +1,4 @@
1
- import { RuntimeControl, DataBind, ObjectDataBind, OptionSetting } from '@byteluck-fe/model-driven-core';
1
+ import { RuntimeControl, DataBind, ObjectDataBind, OptionSetting, ControlRuntimeInstance, ControlsKeys } from '@byteluck-fe/model-driven-core';
2
2
  export type StateType = {
3
3
  [controlId: string]: unknown;
4
4
  };
@@ -27,6 +27,9 @@ export interface DataBindMappingFieldItem {
27
27
  export type dataBindMappingType = {
28
28
  [dataCode: string]: DataBindMappingTypeItem;
29
29
  };
30
+ export type SubtableHeadersControlIdMapping = {
31
+ [controlId: string]: ControlRuntimeInstance<ControlsKeys>;
32
+ };
30
33
  type StoreProps = {
31
34
  instance: RuntimeControl[];
32
35
  };
@@ -35,6 +38,7 @@ declare class Store {
35
38
  state: StatesType;
36
39
  dataBindMapping: dataBindMappingType;
37
40
  controlIdMapping: controlIdMappingType;
41
+ subtableHeadersControlIdMapping: SubtableHeadersControlIdMapping;
38
42
  readonly defaultState: StatesType;
39
43
  constructor(props: StoreProps);
40
44
  /**
@@ -43,7 +47,7 @@ declare class Store {
43
47
  * @param value
44
48
  */
45
49
  setState(controlId: string, value: unknown, rowIndex?: number): void;
46
- getState(controlId: string, rowIndex?: number): unknown;
50
+ getState(controlId: string, rowIndex?: number): any;
47
51
  getEmptyState(controlId: string): Object | undefined;
48
52
  getDataBind(controlId: string): DataBind | ObjectDataBind | undefined;
49
53
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@byteluck-fe/model-driven-engine",
3
- "version": "2.8.0-alpha.1k",
3
+ "version": "2.8.0-alpha.21",
4
4
  "description": "> TODO: description",
5
5
  "author": "郝晨光 <2293885211@qq.com>",
6
6
  "homepage": "",
@@ -26,7 +26,7 @@
26
26
  "postpublish": "node ../../scripts/postpublish.js"
27
27
  },
28
28
  "dependencies": {
29
- "@byteluck-fe/model-driven-core": "2.8.0-alpha.1c",
29
+ "@byteluck-fe/model-driven-core": "2.8.0-alpha.21",
30
30
  "@byteluck-fe/model-driven-shared": "2.7.0-alpha.38a",
31
31
  "@types/mathjs": "^9.4.2",
32
32
  "mathjs": "^11.3.3"
@@ -34,5 +34,5 @@
34
34
  "devDependencies": {
35
35
  "@types/node": "~18.0.6"
36
36
  },
37
- "gitHead": "224ebff50583396c0db31f47deed5fa6701cb779"
37
+ "gitHead": "65649014eaf94cb363539c887325e050819573ef"
38
38
  }