@picked/client 0.0.1-dev.1772493269328 → 0.0.1-dev.1773363643396

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.
Files changed (33) hide show
  1. package/dist/{api-D-NB7WP7.cjs → api-C7ddxkUx.cjs} +1 -1
  2. package/dist/{api-Cn3XwsA6.js → api-CQ_YBH_c.js} +1 -1
  3. package/dist/cjs/index.js +2 -2
  4. package/dist/cjs/plugins/create-experience/index.js +1 -1
  5. package/dist/cjs/plugins/dynamic-experiences/index.js +1 -1
  6. package/dist/cjs/plugins/responses-browser-storage/index.js +1 -1
  7. package/dist/cjs/plugins/responses-indexeddb/index.js +1 -1
  8. package/dist/esm/index.js +504 -490
  9. package/dist/esm/plugins/create-experience/index.js +198 -202
  10. package/dist/esm/plugins/dynamic-experiences/index.js +66 -60
  11. package/dist/esm/plugins/responses-browser-storage/index.js +18 -17
  12. package/dist/esm/plugins/responses-indexeddb/index.js +1 -1
  13. package/dist/to-kebab-case-BPnCZjhB.js +6 -0
  14. package/dist/to-kebab-case-BsOQ8CON.cjs +1 -0
  15. package/dist/types/client.d.ts +13 -0
  16. package/dist/types/client.d.ts.map +1 -1
  17. package/dist/types/entities/experience/experience.d.ts +31 -17
  18. package/dist/types/entities/experience/experience.d.ts.map +1 -1
  19. package/dist/types/entities/field/field.d.ts +8 -2
  20. package/dist/types/entities/field/field.d.ts.map +1 -1
  21. package/dist/types/entities/response/response.d.ts +6 -6
  22. package/dist/types/entities/response/response.d.ts.map +1 -1
  23. package/dist/types/picked.d.ts +14 -11
  24. package/dist/types/picked.d.ts.map +1 -1
  25. package/dist/types/plugins/create-experience/create-experience.d.ts +8 -10
  26. package/dist/types/plugins/create-experience/create-experience.d.ts.map +1 -1
  27. package/dist/types/plugins/dynamic-experiences/plugin.d.ts.map +1 -1
  28. package/dist/types/plugins/dynamic-experiences/types.d.ts +3 -1
  29. package/dist/types/plugins/dynamic-experiences/types.d.ts.map +1 -1
  30. package/dist/types/plugins/responses-browser-storage/plugin.d.ts.map +1 -1
  31. package/dist/types/utils/to-kebab-case.d.ts +9 -0
  32. package/dist/types/utils/to-kebab-case.d.ts.map +1 -0
  33. package/package.json +67 -4
@@ -1,30 +1,30 @@
1
- import { g as f } from "../../../id-BW-g3y32.js";
1
+ import { g as h } from "../../../id-BW-g3y32.js";
2
+ import { t as m } from "../../../to-kebab-case-BPnCZjhB.js";
2
3
  const r = {
3
- serialize(e) {
4
- return JSON.stringify(e);
4
+ serialize(i) {
5
+ return JSON.stringify(i);
5
6
  },
6
- deserialize(e) {
7
- return JSON.parse(e);
7
+ deserialize(i) {
8
+ return JSON.parse(i);
8
9
  }
9
- }, x = (e) => ({
10
+ }, x = (i) => ({
10
11
  name: "create-experience",
11
12
  setup: (o) => {
12
- e.experiences.forEach((s) => {
13
- const n = s.serialize(), d = r.deserialize(n);
14
- d.component = s.component, o.registerExperience(d), d.fields.forEach((N) => {
15
- o.registerField(N);
13
+ i.experiences.forEach((t) => {
14
+ const n = t.serialize(), d = r.deserialize(n);
15
+ d.component = t.component, o.registerExperience(d), d.fields.forEach((f) => {
16
+ o.registerField(f);
16
17
  });
17
18
  });
18
19
  }
19
- }), y = (e, o) => ({
20
- id: f("node"),
21
- position: [0, 0],
20
+ }), y = (i, o) => ({
21
+ id: h("node"),
22
22
  experience: o,
23
23
  type: "action",
24
- action: e.action,
24
+ action: i.action,
25
25
  addNext(n) {
26
26
  if (!n.node) throw new Error("Cannot connect to node");
27
- const d = h(
27
+ const d = c(
28
28
  { sourceNode: this, destinationNode: n.node, sourceNodeHandle: null },
29
29
  o
30
30
  );
@@ -32,7 +32,7 @@ const r = {
32
32
  },
33
33
  onSuccess(n) {
34
34
  if (!n.node) throw new Error("Cannot connect to node");
35
- const d = h(
35
+ const d = c(
36
36
  { sourceNode: this, destinationNode: n.node, sourceNodeHandle: "true" },
37
37
  o
38
38
  );
@@ -40,7 +40,7 @@ const r = {
40
40
  },
41
41
  onFail(n) {
42
42
  if (!n.node) throw new Error("Cannot connect to node");
43
- const d = h(
43
+ const d = c(
44
44
  { sourceNode: this, destinationNode: n.node, sourceNodeHandle: "false" },
45
45
  o
46
46
  );
@@ -50,24 +50,23 @@ const r = {
50
50
  return r.serialize({
51
51
  id: this.id,
52
52
  type: this.type,
53
- action: this.action,
54
- position: this.position
53
+ action: this.action
55
54
  });
56
55
  }
57
- }), V = (e) => ({
58
- id: e.id ?? f("step"),
59
- label: e.label,
60
- fields: e.fields ?? [],
56
+ }), V = (i) => ({
57
+ id: i.id ?? h("step"),
58
+ name: i.name,
59
+ fields: i.fields ?? [],
61
60
  addField(o) {
62
- const s = "serialize" in o ? o : m(o);
63
- return this.fields?.includes(s) || this.fields?.push(s), s;
61
+ const t = "serialize" in o ? o : N(o);
62
+ return this.fields.includes(t) || this.fields.push(t), t;
64
63
  }
65
- }), z = (e, o) => {
66
- const s = {
67
- id: e.id ?? f("step"),
68
- label: e.label,
64
+ }), z = (i, o) => {
65
+ const t = {
66
+ id: i.id ?? h("step"),
67
+ name: i.name,
69
68
  experience: o,
70
- fields: e.fields ?? [],
69
+ fields: i.fields ?? [],
71
70
  node: null,
72
71
  nextStep(n) {
73
72
  return this.experience.addStep(n, this);
@@ -84,79 +83,75 @@ const r = {
84
83
  serialize() {
85
84
  return r.serialize({
86
85
  id: this.id,
87
- label: this.label,
86
+ key: m(this.name),
87
+ name: this.name,
88
88
  fieldIds: this.fields.map((n) => n.id)
89
89
  });
90
90
  }
91
91
  };
92
- return p({ step: s, type: "step" }, o), s;
93
- }, g = () => [0, 0], p = (e, o) => {
94
- const s = {
95
- id: f("node"),
96
- position: g(),
92
+ return p({ step: t, type: "step" }, o), t;
93
+ }, p = (i, o) => {
94
+ const t = {
95
+ id: h("node"),
97
96
  experience: o
98
97
  };
99
- if (e.type === "step") {
98
+ if (i.type === "step") {
100
99
  const d = {
101
- ...s,
100
+ ...t,
102
101
  type: "step",
103
- connectedStep: e.step,
102
+ connectedStep: i.step,
104
103
  serialize() {
105
104
  return r.serialize({
106
105
  id: this.id,
107
106
  type: this.type,
108
107
  stepId: this.connectedStep.id,
109
- position: this.position,
110
- label: this.connectedStep.label
108
+ name: this.connectedStep.name
111
109
  });
112
110
  }
113
111
  };
114
112
  return d.connectedStep.node = d, d;
115
113
  }
116
- if (e.type === "conditional") {
114
+ if (i.type === "conditional") {
117
115
  const d = {
118
- ...s,
116
+ ...t,
119
117
  type: "conditional",
120
- connectedConditional: e.conditional,
118
+ connectedConditional: i.conditional,
121
119
  serialize() {
122
120
  return r.serialize({
123
121
  id: this.id,
124
122
  type: this.type,
125
- conditionalId: this.connectedConditional.id,
126
- position: this.position
123
+ conditionalId: this.connectedConditional.id
127
124
  });
128
125
  }
129
126
  };
130
127
  return d.connectedConditional.node = d, d;
131
128
  }
132
- return e.type === "experience" ? {
133
- ...s,
129
+ return i.type === "experience" ? {
130
+ ...t,
134
131
  type: "experience",
135
- connectedExperience: e.experience,
132
+ connectedExperience: i.experience,
136
133
  serialize() {
137
134
  return r.serialize({
138
135
  id: this.id,
139
136
  type: this.type,
140
- experienceId: this.connectedExperience.id,
141
- position: this.position
137
+ experienceId: this.connectedExperience.id
142
138
  });
143
139
  }
144
140
  } : {
145
- ...s,
141
+ ...t,
146
142
  type: "origin",
147
143
  serialize() {
148
144
  return r.serialize({
149
145
  id: this.id,
150
- type: this.type,
151
- position: this.position
146
+ type: this.type
152
147
  });
153
148
  }
154
149
  };
155
- }, h = (e, o) => ({
156
- id: f("edge"),
157
- sourceNode: e.sourceNode,
158
- sourceNodeHandle: e.sourceNodeHandle,
159
- destinationNode: e.destinationNode,
150
+ }, c = (i, o) => ({
151
+ id: h("edge"),
152
+ sourceNode: i.sourceNode,
153
+ sourceNodeHandle: i.sourceNodeHandle,
154
+ destinationNode: i.destinationNode,
160
155
  experience: o,
161
156
  serialize() {
162
157
  return r.serialize({
@@ -166,17 +161,17 @@ const r = {
166
161
  destinationNodeId: this.destinationNode.id
167
162
  });
168
163
  }
169
- }), b = (e, o) => {
170
- const s = {
171
- id: f("conditional"),
172
- label: e.label,
173
- condition: e.condition,
164
+ }), g = (i, o) => {
165
+ const t = {
166
+ id: h("conditional"),
167
+ label: i.label,
168
+ condition: i.condition,
174
169
  node: null,
175
170
  experience: o,
176
171
  addTrue(n) {
177
172
  if (!this.node || !n.node)
178
173
  throw new Error("todo no node");
179
- const d = h(
174
+ const d = c(
180
175
  { sourceNode: this.node, destinationNode: n.node, sourceNodeHandle: "true" },
181
176
  this.experience
182
177
  );
@@ -185,7 +180,7 @@ const r = {
185
180
  addFalse(n) {
186
181
  if (!this.node || !n.node)
187
182
  throw new Error("todo no node");
188
- const d = h(
183
+ const d = c(
189
184
  { sourceNode: this.node, destinationNode: n.node, sourceNodeHandle: "false" },
190
185
  this.experience
191
186
  );
@@ -199,28 +194,31 @@ const r = {
199
194
  });
200
195
  }
201
196
  };
202
- return p({ conditional: s, type: "conditional" }, o), s;
203
- }, m = (e) => ({
204
- id: e.id,
205
- name: e.name,
206
- type: e.type,
207
- label: e.label,
208
- placeholder: e.placeholder,
209
- description: e.description,
210
- helpText: e.helpText,
211
- defaultValue: e.defaultValue ?? null,
212
- multiple: e.multiple,
213
- validation: e.validation ?? {},
214
- condition: e.condition,
215
- required: e.required,
216
- options: e.options?.map((s) => ({
217
- id: "id" in s ? s.id : f("option"),
218
- ...s
197
+ return p({ conditional: t, type: "conditional" }, o), t;
198
+ }, N = (i) => ({
199
+ id: i.id ?? h("field"),
200
+ key: i.key ?? m(i.name),
201
+ name: i.name,
202
+ type: i.type,
203
+ label: i.label,
204
+ placeholder: i.placeholder,
205
+ description: i.description,
206
+ helpText: i.helpText,
207
+ defaultValue: i.defaultValue ?? null,
208
+ multiple: i.multiple,
209
+ validation: i.validation ?? {},
210
+ condition: i.condition,
211
+ required: i.required,
212
+ options: i.options?.map((t) => ({
213
+ id: "id" in t ? t.id : h("option"),
214
+ ...t
219
215
  })) ?? null,
220
- policies: e.policies,
216
+ policies: i.policies,
217
+ // eslint-disable-next-line sonarjs/cognitive-complexity -- this function handles all field types and subtypes; splitting it would increase indirection without improving clarity. Addressed in PR #1372
221
218
  serialize() {
222
- const s = {
219
+ const t = {
223
220
  id: this.id,
221
+ key: this.key,
224
222
  name: this.name,
225
223
  label: this.label,
226
224
  placeholder: this.placeholder,
@@ -230,219 +228,218 @@ const r = {
230
228
  validation: this.validation,
231
229
  condition: this.condition,
232
230
  policies: this.policies
233
- }, n = typeof this.defaultValue == "string" ? this.defaultValue : void 0, d = typeof this.defaultValue == "number" ? this.defaultValue : void 0, N = typeof this.defaultValue == "boolean" ? this.defaultValue : void 0;
231
+ }, n = typeof this.defaultValue == "string" ? this.defaultValue : void 0, d = typeof this.defaultValue == "number" ? this.defaultValue : void 0, f = typeof this.defaultValue == "boolean" ? this.defaultValue : void 0;
234
232
  switch (this.type) {
235
233
  case "text":
236
234
  if (this.multiple) {
237
- let t;
235
+ let e;
238
236
  if (Array.isArray(this.defaultValue)) {
239
- t = [];
240
- for (const i of this.defaultValue)
241
- typeof i == "string" && t.push(i);
242
- t.length === 0 && (t = void 0);
237
+ e = [];
238
+ for (const s of this.defaultValue)
239
+ typeof s == "string" && e.push(s);
240
+ e.length === 0 && (e = void 0);
243
241
  }
244
242
  return r.serialize({
245
- ...s,
243
+ ...t,
246
244
  type: "text",
247
245
  multiple: !0,
248
- defaultValue: t,
249
- options: this.options ? this.options.map((i) => ({
250
- id: i.id,
251
- label: i.label,
252
- value: `${i.value}`,
253
- condition: i.condition
246
+ defaultValue: e,
247
+ options: this.options ? this.options.map((s) => ({
248
+ id: s.id,
249
+ label: s.label,
250
+ value: `${s.value}`,
251
+ condition: s.condition
254
252
  })) : null
255
253
  });
256
254
  }
257
255
  return r.serialize({
258
- ...s,
256
+ ...t,
259
257
  type: "text",
260
258
  multiple: !1,
261
259
  defaultValue: n,
262
- options: this.options ? this.options.map((t) => ({
263
- id: t.id,
264
- label: t.label,
265
- value: `${t.value}`,
266
- condition: t.condition
260
+ options: this.options ? this.options.map((e) => ({
261
+ id: e.id,
262
+ label: e.label,
263
+ value: `${e.value}`,
264
+ condition: e.condition
267
265
  })) : null
268
266
  });
269
267
  case "number":
270
268
  if (this.multiple) {
271
- let t;
269
+ let e;
272
270
  if (Array.isArray(this.defaultValue)) {
273
- t = [];
274
- for (const i of this.defaultValue)
275
- typeof i == "number" && t.push(i);
276
- t.length === 0 && (t = void 0);
271
+ e = [];
272
+ for (const s of this.defaultValue)
273
+ typeof s == "number" && e.push(s);
274
+ e.length === 0 && (e = void 0);
277
275
  }
278
276
  return r.serialize({
279
- ...s,
277
+ ...t,
280
278
  type: "number",
281
279
  multiple: !0,
282
- defaultValue: t,
283
- options: this.options ? this.options.map((i) => ({
284
- id: i.id,
285
- label: i.label,
286
- value: Number(i.value),
287
- condition: i.condition
280
+ defaultValue: e,
281
+ options: this.options ? this.options.map((s) => ({
282
+ id: s.id,
283
+ label: s.label,
284
+ value: Number(s.value),
285
+ condition: s.condition
288
286
  })) : null
289
287
  });
290
288
  }
291
289
  return r.serialize({
292
- ...s,
290
+ ...t,
293
291
  type: "number",
294
292
  multiple: !1,
295
293
  defaultValue: d,
296
- options: this.options ? this.options.map((t) => ({
297
- id: t.id,
298
- label: t.label,
299
- value: Number(t.value),
300
- condition: t.condition
294
+ options: this.options ? this.options.map((e) => ({
295
+ id: e.id,
296
+ label: e.label,
297
+ value: Number(e.value),
298
+ condition: e.condition
301
299
  })) : null
302
300
  });
303
301
  case "boolean":
304
302
  if (this.multiple) {
305
- let t;
303
+ let e;
306
304
  if (Array.isArray(this.defaultValue)) {
307
- t = [];
308
- for (const i of this.defaultValue)
309
- typeof i == "boolean" && t.push(i);
310
- t.length === 0 && (t = void 0);
305
+ e = [];
306
+ for (const s of this.defaultValue)
307
+ typeof s == "boolean" && e.push(s);
308
+ e.length === 0 && (e = void 0);
311
309
  }
312
310
  return r.serialize({
313
- ...s,
311
+ ...t,
314
312
  type: "boolean",
315
313
  multiple: !0,
316
- defaultValue: t,
317
- options: this.options ? this.options.map((i) => ({
318
- id: i.id,
319
- label: i.label,
320
- value: !!i.value,
321
- condition: i.condition
314
+ defaultValue: e,
315
+ options: this.options ? this.options.map((s) => ({
316
+ id: s.id,
317
+ label: s.label,
318
+ value: !!s.value,
319
+ condition: s.condition
322
320
  })) : null
323
321
  });
324
322
  }
325
323
  return r.serialize({
326
- ...s,
324
+ ...t,
327
325
  type: "boolean",
328
326
  multiple: !1,
329
- defaultValue: N,
330
- options: this.options ? this.options.map((t) => ({
331
- id: t.id,
332
- label: t.label,
333
- value: !!t.value,
334
- condition: t.condition
327
+ defaultValue: f,
328
+ options: this.options ? this.options.map((e) => ({
329
+ id: e.id,
330
+ label: e.label,
331
+ value: !!e.value,
332
+ condition: e.condition
335
333
  })) : null
336
334
  });
337
335
  case "object":
338
336
  return this.multiple ? r.serialize({
339
- ...s,
337
+ ...t,
340
338
  type: "object",
341
339
  multiple: !0,
342
340
  defaultValue: this.defaultValue,
343
- options: this.options ? this.options.map((t) => ({
344
- id: t.id,
345
- label: t.label,
346
- description: t.description,
347
- value: t.value,
348
- condition: t.condition
341
+ options: this.options ? this.options.map((e) => ({
342
+ id: e.id,
343
+ label: e.label,
344
+ description: e.description,
345
+ value: e.value,
346
+ condition: e.condition
349
347
  })) : null
350
348
  }) : r.serialize({
351
- ...s,
349
+ ...t,
352
350
  type: "object",
353
351
  multiple: !1,
354
352
  defaultValue: this.defaultValue,
355
- options: this.options ? this.options.map((t) => ({
356
- id: t.id,
357
- label: t.label,
358
- description: t.description,
359
- value: t.value,
360
- condition: t.condition
353
+ options: this.options ? this.options.map((e) => ({
354
+ id: e.id,
355
+ label: e.label,
356
+ description: e.description,
357
+ value: e.value,
358
+ condition: e.condition
361
359
  })) : null
362
360
  });
363
361
  default:
364
362
  throw new Error("Unsupported field type");
365
363
  }
366
364
  }
367
- }), E = (e) => {
368
- const o = [], s = [], n = [], d = [], N = [], t = e.condition ?? e.decide;
365
+ }), E = (i) => {
366
+ const o = [], t = [], n = [], d = [], f = [];
369
367
  return {
370
- id: e.id,
371
- component: e.component,
372
- name: e.name,
373
- initializeOpen: e.initializeOpen,
374
- condition: t,
375
- decide: e.decide,
376
- targets: e.targets,
368
+ id: i.id,
369
+ component: i.component,
370
+ name: i.name,
371
+ initializeOpen: i.initializeOpen,
372
+ condition: i.condition,
373
+ targets: i.targets,
377
374
  steps: o,
378
- nodes: s,
375
+ nodes: t,
379
376
  edges: n,
380
- fields: N,
377
+ fields: f,
381
378
  conditionals: d,
382
- addStep(i, u) {
383
- let l = u?.node;
379
+ addStep(e, s) {
380
+ let l = s?.node;
384
381
  this.nodes.length === 0 && (l = p({ type: "origin" }, this), this.nodes.push(l));
385
- const a = "serialize" in i ? i : z(i, this);
382
+ const a = "serialize" in e ? e : z(e, this);
386
383
  if (l) {
387
384
  if (!a.node)
388
385
  throw new Error("todo no node");
389
- const c = h(
386
+ const u = c(
390
387
  { sourceNode: l, destinationNode: a.node, sourceNodeHandle: null },
391
388
  this
392
389
  );
393
- this.edges.push(c);
390
+ this.edges.push(u);
394
391
  }
395
- return a.fields.length > 0 && a.fields.forEach((c) => {
396
- this.fields.includes(c) || this.fields.push(c);
392
+ return a.fields.length > 0 && a.fields.forEach((u) => {
393
+ this.fields.includes(u) || this.fields.push(u);
397
394
  }), this.steps.includes(a) || (this.steps.push(a), a.node && this.nodes.push(a.node)), a;
398
395
  },
399
- addAction(i, u) {
400
- let l = u?.node;
396
+ addAction(e, s) {
397
+ let l = s?.node;
401
398
  this.nodes.length === 0 && (l = p({ type: "origin" }, this), this.nodes.push(l));
402
- const a = "serialize" in i ? i : y(i, this);
399
+ const a = "serialize" in e ? e : y(e, this);
403
400
  if (l) {
404
- const c = h(
401
+ const u = c(
405
402
  { sourceNode: l, destinationNode: a, sourceNodeHandle: null },
406
403
  this
407
404
  );
408
- this.edges.push(c);
405
+ this.edges.push(u);
409
406
  }
410
407
  return this.nodes.push(a), a;
411
408
  },
412
- addConditional(i, u) {
413
- let l = u?.node;
409
+ addConditional(e, s) {
410
+ let l = s?.node;
414
411
  this.nodes.length === 0 && (l = p({ type: "origin" }, this), this.nodes.push(l));
415
- const a = "serialize" in i ? i : b(i, this);
412
+ const a = "serialize" in e ? e : g(e, this);
416
413
  if (l) {
417
414
  if (!a.node)
418
415
  throw new Error("todo no node");
419
- const c = h(
416
+ const u = c(
420
417
  { sourceNode: l, destinationNode: a.node, sourceNodeHandle: null },
421
418
  this
422
419
  );
423
- this.edges.push(c);
420
+ this.edges.push(u);
424
421
  }
425
422
  return this.conditionals.includes(a) || (this.conditionals.push(a), a.node && this.nodes.push(a.node)), a;
426
423
  },
427
- addExperience(i, u) {
428
- let l = u?.node;
424
+ addExperience(e, s) {
425
+ let l = s?.node;
429
426
  this.nodes.length === 0 && (l = p({ type: "origin" }, this), this.nodes.push(l));
430
427
  const a = p(
431
- { type: "experience", experience: i },
428
+ { type: "experience", experience: e },
432
429
  this
433
430
  );
434
431
  if (this.nodes.push(a), l) {
435
- const c = h(
432
+ const u = c(
436
433
  { sourceNode: l, destinationNode: a, sourceNodeHandle: null },
437
434
  this
438
435
  );
439
- this.edges.push(c);
436
+ this.edges.push(u);
440
437
  }
441
- return i;
438
+ return e;
442
439
  },
443
- addField(i, u) {
444
- const l = "serialize" in i ? i : m(i);
445
- return u && u.fields.push(l), this.fields.includes(l) || this.fields.push(l), l;
440
+ addField(e, s) {
441
+ const l = "serialize" in e ? e : N(e);
442
+ return s && s.fields.push(l), this.fields.includes(l) || this.fields.push(l), l;
446
443
  },
447
444
  serialize() {
448
445
  return r.serialize({
@@ -450,26 +447,25 @@ const r = {
450
447
  component: this.component,
451
448
  name: this.name,
452
449
  initializeOpen: this.initializeOpen,
453
- condition: this.condition ?? this.decide,
454
- decide: this.decide,
450
+ condition: this.condition,
455
451
  targets: this.targets,
456
- steps: this.steps.map((i) => r.deserialize(i.serialize())),
457
- nodes: this.nodes.map((i) => r.deserialize(i.serialize())),
458
- edges: this.edges.map((i) => r.deserialize(i.serialize())),
452
+ steps: this.steps.map((e) => r.deserialize(e.serialize())),
453
+ nodes: this.nodes.map((e) => r.deserialize(e.serialize())),
454
+ edges: this.edges.map((e) => r.deserialize(e.serialize())),
459
455
  conditionals: this.conditionals.map(
460
- (i) => r.deserialize(i.serialize())
456
+ (e) => r.deserialize(e.serialize())
461
457
  ),
462
- fields: this.fields.map((i) => r.deserialize(i.serialize()))
458
+ fields: this.fields.map((e) => r.deserialize(e.serialize()))
463
459
  });
464
460
  }
465
461
  };
466
462
  };
467
463
  export {
468
- b as createConditional,
469
- h as createEdge,
464
+ g as createConditional,
465
+ c as createEdge,
470
466
  E as createExperience,
471
467
  x as createExperiencePlugin,
472
- m as createField,
468
+ N as createField,
473
469
  p as createNode,
474
470
  V as createStep,
475
471
  r as serialization