x-runtime-lib 0.8.83 → 0.8.85

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,65 +150,38 @@ export type ZProperty = ({
145
150
  array: true;
146
151
  defaultArray: string[];
147
152
  } & ZPropertySlotSelect);
148
- export type ZProperties = {
149
- [key: string]: ZProperty[];
150
- };
151
153
  export type ZEvent = {
152
154
  key: string;
153
155
  name: string;
154
- params: {
155
- key: string;
156
- name: string;
157
- type: Type;
158
- }[];
156
+ params?: ZField[];
159
157
  };
160
158
  export type ZMethod = {
161
159
  key: string;
162
160
  name: string;
163
- inputs: {
164
- key: string;
165
- name: string;
166
- type: Type;
167
- }[];
168
- outputs: {
169
- key: string;
170
- name: string;
171
- type: Type;
172
- }[];
173
- };
174
- export type ZSlotProp = {
175
- key: string;
176
- name: string;
177
- type: Type;
161
+ inputs?: ZField[];
162
+ outputs?: ZField[];
178
163
  };
179
- export type ZSlotMethod = {
164
+ export type ZSlot = {
180
165
  key: string;
181
166
  name: string;
182
- inputs: {
183
- key: string;
184
- name: string;
185
- type: Type;
186
- }[];
187
- outputs: {
167
+ properties?: {
188
168
  key: string;
189
169
  name: string;
190
170
  type: Type;
191
171
  }[];
192
- };
193
- export type ZSlot = {
194
- key: string;
195
- name: string;
196
- props: ZSlotProp[];
197
- methods: ZSlotMethod[];
172
+ events?: ZEvent[];
173
+ methods?: ZMethod[];
198
174
  };
199
175
  export type ZElement = {
200
176
  key: string;
201
177
  name: string;
202
178
  comp: any;
203
- properties: ZProperties;
204
- events: ZEvent[];
205
- methods: ZMethod[];
206
- slots: ZSlot[];
179
+ properties: {
180
+ [key: string]: ZProperty[];
181
+ };
182
+ events?: ZEvent[];
183
+ methods?: ZMethod[];
184
+ slots?: ZSlot[];
207
185
  leaf?: boolean;
208
186
  internal?: boolean;
209
187
  teleport?: boolean;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "x-runtime-lib",
3
3
  "private": false,
4
- "version": "0.8.83",
4
+ "version": "0.8.85",
5
5
  "type": "module",
6
6
  "module": "dist/index.js",
7
7
  "types": "dist/index.d.ts",