x-runtime-lib 0.8.84 → 0.8.86

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.
@@ -1,5 +1,10 @@
1
1
  import { Type } from './basic';
2
2
  import { Node } from './data';
3
+ export type ZField = {
4
+ key: string;
5
+ name: string;
6
+ type: Type;
7
+ };
3
8
  export type ZItem = {
4
9
  title: string;
5
10
  value: string;
@@ -145,39 +150,23 @@ export type ZProperty = ({
145
150
  array: true;
146
151
  defaultArray: string[];
147
152
  } & ZPropertySlotSelect);
148
- export type ZEvent = {
153
+ export type ZMethod = {
149
154
  key: string;
150
155
  name: string;
151
- params?: {
152
- key: string;
153
- name: string;
154
- type: Type;
155
- }[];
156
+ inputs?: ZField[];
157
+ outputs?: ZField[];
156
158
  };
157
- export type ZMethod = {
159
+ export type ZEvent = {
158
160
  key: string;
159
161
  name: string;
160
- inputs?: {
161
- key: string;
162
- name: string;
163
- type: Type;
164
- }[];
165
- outputs?: {
166
- key: string;
167
- name: string;
168
- type: Type;
169
- }[];
162
+ params?: ZField[];
170
163
  };
171
164
  export type ZSlot = {
172
165
  key: string;
173
166
  name: string;
174
- properties?: {
175
- key: string;
176
- name: string;
177
- type: Type;
178
- }[];
179
- events?: ZEvent[];
167
+ properties?: ZField[];
180
168
  methods?: ZMethod[];
169
+ events?: ZEvent[];
181
170
  };
182
171
  export type ZElement = {
183
172
  key: string;
@@ -186,8 +175,8 @@ export type ZElement = {
186
175
  properties: {
187
176
  [key: string]: ZProperty[];
188
177
  };
189
- events?: ZEvent[];
190
178
  methods?: ZMethod[];
179
+ events?: ZEvent[];
191
180
  slots?: ZSlot[];
192
181
  leaf?: boolean;
193
182
  internal?: boolean;
@@ -3,48 +3,35 @@ export type Field = {
3
3
  id: string;
4
4
  name: string;
5
5
  type: Type;
6
- desc: string;
6
+ desc?: string;
7
7
  };
8
- export type State = {
8
+ export type Method = {
9
9
  id: string;
10
10
  name: string;
11
- type: Type;
12
- desc: string;
11
+ inputs?: Field[];
12
+ outputs?: Field[];
13
+ desc?: string;
13
14
  };
14
- export type Argument = {
15
+ export type Event = {
15
16
  id: string;
16
17
  name: string;
17
- type: Type;
18
- desc: string;
18
+ params?: Field[];
19
+ desc?: string;
19
20
  };
20
21
  export type PageMeta = {
21
22
  version: string;
22
- arguments: Argument[];
23
- states: State[];
24
- };
25
- export type Property = {
26
- id: string;
27
- name: string;
28
- type: Type;
29
- desc: string;
30
- };
31
- export type Method = {
32
- id: string;
33
- name: string;
34
- inputs: Field[];
35
- outputs: Field[];
36
- desc: string;
37
- };
38
- export type Event = {
39
- id: string;
40
- name: string;
41
- params: Field[];
42
- desc: string;
23
+ arguments?: Field[];
24
+ states?: Field[];
43
25
  };
44
26
  export type CompMeta = {
45
27
  version: string;
46
- properties: Property[];
47
- methods: Method[];
48
- events: Event[];
49
- states: State[];
28
+ properties?: Field[];
29
+ methods?: Method[];
30
+ events?: Event[];
31
+ states?: Field[];
32
+ slots: {
33
+ properties?: Field[];
34
+ methods?: Method[];
35
+ events?: Event[];
36
+ }[];
50
37
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "x-runtime-lib",
3
3
  "private": false,
4
- "version": "0.8.84",
4
+ "version": "0.8.86",
5
5
  "type": "module",
6
6
  "module": "dist/index.js",
7
7
  "types": "dist/index.d.ts",