@ddd-tool/domain-designer-generator 0.1.0-beta.2 → 0.1.0-beta.4

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/index.js CHANGED
@@ -5,161 +5,161 @@
5
5
  **/
6
6
  /*! #__NO_SIDE_EFFECTS__ */
7
7
  // @__NO_SIDE_EFFECTS__
8
- function Kn(e) {
8
+ function Gn(e) {
9
9
  const n = /* @__PURE__ */ Object.create(null);
10
10
  for (const t of e.split(",")) n[t] = 1;
11
11
  return (t) => t in n;
12
12
  }
13
13
  process.env.NODE_ENV !== "production" && Object.freeze({});
14
14
  process.env.NODE_ENV !== "production" && Object.freeze([]);
15
- const Fe = Object.assign, zn = Object.prototype.hasOwnProperty, Ve = (e, n) => zn.call(e, n), J = Array.isArray, ne = (e) => pn(e) === "[object Map]", Bn = (e) => typeof e == "function", Un = (e) => typeof e == "string", ce = (e) => typeof e == "symbol", ye = (e) => e !== null && typeof e == "object", Gn = Object.prototype.toString, pn = (e) => Gn.call(e), dn = (e) => pn(e).slice(8, -1), Je = (e) => Un(e) && e !== "NaN" && e[0] !== "-" && "" + parseInt(e, 10) === e, Wn = (e) => {
15
+ const Ve = Object.assign, Un = Object.prototype.hasOwnProperty, Re = (e, n) => Un.call(e, n), Y = Array.isArray, oe = (e) => mn(e) === "[object Map]", zn = (e) => typeof e == "function", Jn = (e) => typeof e == "string", le = (e) => typeof e == "symbol", je = (e) => e !== null && typeof e == "object", Wn = Object.prototype.toString, mn = (e) => Wn.call(e), fn = (e) => mn(e).slice(8, -1), Ye = (e) => Jn(e) && e !== "NaN" && e[0] !== "-" && "" + parseInt(e, 10) === e, qn = (e) => {
16
16
  const n = /* @__PURE__ */ Object.create(null);
17
17
  return (t) => n[t] || (n[t] = e(t));
18
- }, Jn = Wn((e) => e.charAt(0).toUpperCase() + e.slice(1)), Y = (e, n) => !Object.is(e, n);
18
+ }, Yn = qn((e) => e.charAt(0).toUpperCase() + e.slice(1)), Z = (e, n) => !Object.is(e, n);
19
19
  /**
20
20
  * @vue/reactivity v3.5.13
21
21
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
22
22
  * @license MIT
23
23
  **/
24
- function X(e, ...n) {
24
+ function ee(e, ...n) {
25
25
  }
26
- let S, fn = 0, te, oe;
27
- function Yn(e, n = !1) {
26
+ let A, hn = 0, se, re;
27
+ function Zn(e, n = !1) {
28
28
  if (e.flags |= 8, n) {
29
- e.next = oe, oe = e;
29
+ e.next = re, re = e;
30
30
  return;
31
31
  }
32
- e.next = te, te = e;
33
- }
34
- function Ye() {
35
- fn++;
32
+ e.next = se, se = e;
36
33
  }
37
34
  function Ze() {
38
- if (--fn > 0)
35
+ hn++;
36
+ }
37
+ function Xe() {
38
+ if (--hn > 0)
39
39
  return;
40
- if (oe) {
41
- let n = oe;
42
- for (oe = void 0; n; ) {
40
+ if (re) {
41
+ let n = re;
42
+ for (re = void 0; n; ) {
43
43
  const t = n.next;
44
44
  n.next = void 0, n.flags &= -9, n = t;
45
45
  }
46
46
  }
47
47
  let e;
48
- for (; te; ) {
49
- let n = te;
50
- for (te = void 0; n; ) {
48
+ for (; se; ) {
49
+ let n = se;
50
+ for (se = void 0; n; ) {
51
51
  const t = n.next;
52
52
  if (n.next = void 0, n.flags &= -9, n.flags & 1)
53
53
  try {
54
54
  n.trigger();
55
- } catch (o) {
56
- e || (e = o);
55
+ } catch (s) {
56
+ e || (e = s);
57
57
  }
58
58
  n = t;
59
59
  }
60
60
  }
61
61
  if (e) throw e;
62
62
  }
63
- function Zn(e) {
63
+ function Xn(e) {
64
64
  for (let n = e.deps; n; n = n.nextDep)
65
65
  n.version = -1, n.prevActiveLink = n.dep.activeLink, n.dep.activeLink = n;
66
66
  }
67
- function qn(e) {
68
- let n, t = e.depsTail, o = t;
69
- for (; o; ) {
70
- const s = o.prevDep;
71
- o.version === -1 ? (o === t && (t = s), hn(o), Qn(o)) : n = o, o.dep.activeLink = o.prevActiveLink, o.prevActiveLink = void 0, o = s;
67
+ function Qn(e) {
68
+ let n, t = e.depsTail, s = t;
69
+ for (; s; ) {
70
+ const o = s.prevDep;
71
+ s.version === -1 ? (s === t && (t = o), gn(s), nt(s)) : n = s, s.dep.activeLink = s.prevActiveLink, s.prevActiveLink = void 0, s = o;
72
72
  }
73
73
  e.deps = n, e.depsTail = t;
74
74
  }
75
- function Xn(e) {
75
+ function et(e) {
76
76
  for (let n = e.deps; n; n = n.nextDep)
77
- if (n.dep.version !== n.version || n.dep.computed && (mn(n.dep.computed) || n.dep.version !== n.version))
77
+ if (n.dep.version !== n.version || n.dep.computed && (vn(n.dep.computed) || n.dep.version !== n.version))
78
78
  return !0;
79
79
  return !!e._dirty;
80
80
  }
81
- function mn(e) {
82
- if (e.flags & 4 && !(e.flags & 16) || (e.flags &= -17, e.globalVersion === se))
81
+ function vn(e) {
82
+ if (e.flags & 4 && !(e.flags & 16) || (e.flags &= -17, e.globalVersion === ae))
83
83
  return;
84
- e.globalVersion = se;
84
+ e.globalVersion = ae;
85
85
  const n = e.dep;
86
- if (e.flags |= 2, n.version > 0 && !e.isSSR && e.deps && !Xn(e)) {
86
+ if (e.flags |= 2, n.version > 0 && !e.isSSR && e.deps && !et(e)) {
87
87
  e.flags &= -3;
88
88
  return;
89
89
  }
90
- const t = S, o = R;
91
- S = e, R = !0;
90
+ const t = A, s = H;
91
+ A = e, H = !0;
92
92
  try {
93
- Zn(e);
94
- const s = e.fn(e._value);
95
- (n.version === 0 || Y(s, e._value)) && (e._value = s, n.version++);
96
- } catch (s) {
97
- throw n.version++, s;
93
+ Xn(e);
94
+ const o = e.fn(e._value);
95
+ (n.version === 0 || Z(o, e._value)) && (e._value = o, n.version++);
96
+ } catch (o) {
97
+ throw n.version++, o;
98
98
  } finally {
99
- S = t, R = o, qn(e), e.flags &= -3;
99
+ A = t, H = s, Qn(e), e.flags &= -3;
100
100
  }
101
101
  }
102
- function hn(e, n = !1) {
103
- const { dep: t, prevSub: o, nextSub: s } = e;
104
- if (o && (o.nextSub = s, e.prevSub = void 0), s && (s.prevSub = o, e.nextSub = void 0), process.env.NODE_ENV !== "production" && t.subsHead === e && (t.subsHead = s), t.subs === e && (t.subs = o, !o && t.computed)) {
102
+ function gn(e, n = !1) {
103
+ const { dep: t, prevSub: s, nextSub: o } = e;
104
+ if (s && (s.nextSub = o, e.prevSub = void 0), o && (o.prevSub = s, e.nextSub = void 0), process.env.NODE_ENV !== "production" && t.subsHead === e && (t.subsHead = o), t.subs === e && (t.subs = s, !s && t.computed)) {
105
105
  t.computed.flags &= -5;
106
- for (let a = t.computed.deps; a; a = a.nextDep)
107
- hn(a, !0);
106
+ for (let r = t.computed.deps; r; r = r.nextDep)
107
+ gn(r, !0);
108
108
  }
109
109
  !n && !--t.sc && t.map && t.map.delete(t.key);
110
110
  }
111
- function Qn(e) {
111
+ function nt(e) {
112
112
  const { prevDep: n, nextDep: t } = e;
113
113
  n && (n.nextDep = t, e.prevDep = void 0), t && (t.prevDep = n, e.nextDep = void 0);
114
114
  }
115
- let R = !0;
116
- const gn = [];
117
- function et() {
118
- gn.push(R), R = !1;
115
+ let H = !0;
116
+ const _n = [];
117
+ function tt() {
118
+ _n.push(H), H = !1;
119
119
  }
120
- function nt() {
121
- const e = gn.pop();
122
- R = e === void 0 ? !0 : e;
120
+ function ot() {
121
+ const e = _n.pop();
122
+ H = e === void 0 ? !0 : e;
123
123
  }
124
- let se = 0;
125
- class tt {
124
+ let ae = 0;
125
+ class st {
126
126
  constructor(n, t) {
127
127
  this.sub = n, this.dep = t, this.version = t.version, this.nextDep = this.prevDep = this.nextSub = this.prevSub = this.prevActiveLink = void 0;
128
128
  }
129
129
  }
130
- class qe {
130
+ class Qe {
131
131
  constructor(n) {
132
132
  this.computed = n, this.version = 0, this.activeLink = void 0, this.subs = void 0, this.map = void 0, this.key = void 0, this.sc = 0, process.env.NODE_ENV !== "production" && (this.subsHead = void 0);
133
133
  }
134
134
  track(n) {
135
- if (!S || !R || S === this.computed)
135
+ if (!A || !H || A === this.computed)
136
136
  return;
137
137
  let t = this.activeLink;
138
- if (t === void 0 || t.sub !== S)
139
- t = this.activeLink = new tt(S, this), S.deps ? (t.prevDep = S.depsTail, S.depsTail.nextDep = t, S.depsTail = t) : S.deps = S.depsTail = t, vn(t);
138
+ if (t === void 0 || t.sub !== A)
139
+ t = this.activeLink = new st(A, this), A.deps ? (t.prevDep = A.depsTail, A.depsTail.nextDep = t, A.depsTail = t) : A.deps = A.depsTail = t, Cn(t);
140
140
  else if (t.version === -1 && (t.version = this.version, t.nextDep)) {
141
- const o = t.nextDep;
142
- o.prevDep = t.prevDep, t.prevDep && (t.prevDep.nextDep = o), t.prevDep = S.depsTail, t.nextDep = void 0, S.depsTail.nextDep = t, S.depsTail = t, S.deps === t && (S.deps = o);
141
+ const s = t.nextDep;
142
+ s.prevDep = t.prevDep, t.prevDep && (t.prevDep.nextDep = s), t.prevDep = A.depsTail, t.nextDep = void 0, A.depsTail.nextDep = t, A.depsTail = t, A.deps === t && (A.deps = s);
143
143
  }
144
- return process.env.NODE_ENV !== "production" && S.onTrack && S.onTrack(
145
- Fe(
144
+ return process.env.NODE_ENV !== "production" && A.onTrack && A.onTrack(
145
+ Ve(
146
146
  {
147
- effect: S
147
+ effect: A
148
148
  },
149
149
  n
150
150
  )
151
151
  ), t;
152
152
  }
153
153
  trigger(n) {
154
- this.version++, se++, this.notify(n);
154
+ this.version++, ae++, this.notify(n);
155
155
  }
156
156
  notify(n) {
157
- Ye();
157
+ Ze();
158
158
  try {
159
159
  if (process.env.NODE_ENV !== "production")
160
160
  for (let t = this.subsHead; t; t = t.nextSub)
161
161
  t.sub.onTrigger && !(t.sub.flags & 8) && t.sub.onTrigger(
162
- Fe(
162
+ Ve(
163
163
  {
164
164
  effect: t.sub
165
165
  },
@@ -169,252 +169,252 @@ class qe {
169
169
  for (let t = this.subs; t; t = t.prevSub)
170
170
  t.sub.notify() && t.sub.dep.notify();
171
171
  } finally {
172
- Ze();
172
+ Xe();
173
173
  }
174
174
  }
175
175
  }
176
- function vn(e) {
176
+ function Cn(e) {
177
177
  if (e.dep.sc++, e.sub.flags & 4) {
178
178
  const n = e.dep.computed;
179
179
  if (n && !e.dep.subs) {
180
180
  n.flags |= 20;
181
- for (let o = n.deps; o; o = o.nextDep)
182
- vn(o);
181
+ for (let s = n.deps; s; s = s.nextDep)
182
+ Cn(s);
183
183
  }
184
184
  const t = e.dep.subs;
185
185
  t !== e && (e.prevSub = t, t && (t.nextSub = e)), process.env.NODE_ENV !== "production" && e.dep.subsHead === void 0 && (e.dep.subsHead = e), e.dep.subs = e;
186
186
  }
187
187
  }
188
- const Re = /* @__PURE__ */ new WeakMap(), M = Symbol(
188
+ const He = /* @__PURE__ */ new WeakMap(), B = Symbol(
189
189
  process.env.NODE_ENV !== "production" ? "Object iterate" : ""
190
- ), ke = Symbol(
190
+ ), Le = Symbol(
191
191
  process.env.NODE_ENV !== "production" ? "Map keys iterate" : ""
192
- ), re = Symbol(
192
+ ), ie = Symbol(
193
193
  process.env.NODE_ENV !== "production" ? "Array iterate" : ""
194
194
  );
195
- function I(e, n, t) {
196
- if (R && S) {
197
- let o = Re.get(e);
198
- o || Re.set(e, o = /* @__PURE__ */ new Map());
199
- let s = o.get(t);
200
- s || (o.set(t, s = new qe()), s.map = o, s.key = t), process.env.NODE_ENV !== "production" ? s.track({
195
+ function T(e, n, t) {
196
+ if (H && A) {
197
+ let s = He.get(e);
198
+ s || He.set(e, s = /* @__PURE__ */ new Map());
199
+ let o = s.get(t);
200
+ o || (s.set(t, o = new Qe()), o.map = s, o.key = t), process.env.NODE_ENV !== "production" ? o.track({
201
201
  target: e,
202
202
  type: n,
203
203
  key: t
204
- }) : s.track();
204
+ }) : o.track();
205
205
  }
206
206
  }
207
- function V(e, n, t, o, s, a) {
208
- const c = Re.get(e);
207
+ function R(e, n, t, s, o, r) {
208
+ const c = He.get(e);
209
209
  if (!c) {
210
- se++;
210
+ ae++;
211
211
  return;
212
212
  }
213
- const g = (v) => {
214
- v && (process.env.NODE_ENV !== "production" ? v.trigger({
213
+ const g = (_) => {
214
+ _ && (process.env.NODE_ENV !== "production" ? _.trigger({
215
215
  target: e,
216
216
  type: n,
217
217
  key: t,
218
- newValue: o,
219
- oldValue: s,
220
- oldTarget: a
221
- }) : v.trigger());
218
+ newValue: s,
219
+ oldValue: o,
220
+ oldTarget: r
221
+ }) : _.trigger());
222
222
  };
223
- if (Ye(), n === "clear")
223
+ if (Ze(), n === "clear")
224
224
  c.forEach(g);
225
225
  else {
226
- const v = J(e), d = v && Je(t);
227
- if (v && t === "length") {
228
- const r = Number(o);
229
- c.forEach((i, l) => {
230
- (l === "length" || l === re || !ce(l) && l >= r) && g(i);
226
+ const _ = Y(e), m = _ && Ye(t);
227
+ if (_ && t === "length") {
228
+ const a = Number(s);
229
+ c.forEach((u, i) => {
230
+ (i === "length" || i === ie || !le(i) && i >= a) && g(u);
231
231
  });
232
232
  } else
233
- switch ((t !== void 0 || c.has(void 0)) && g(c.get(t)), d && g(c.get(re)), n) {
233
+ switch ((t !== void 0 || c.has(void 0)) && g(c.get(t)), m && g(c.get(ie)), n) {
234
234
  case "add":
235
- v ? d && g(c.get("length")) : (g(c.get(M)), ne(e) && g(c.get(ke)));
235
+ _ ? m && g(c.get("length")) : (g(c.get(B)), oe(e) && g(c.get(Le)));
236
236
  break;
237
237
  case "delete":
238
- v || (g(c.get(M)), ne(e) && g(c.get(ke)));
238
+ _ || (g(c.get(B)), oe(e) && g(c.get(Le)));
239
239
  break;
240
240
  case "set":
241
- ne(e) && g(c.get(M));
241
+ oe(e) && g(c.get(B));
242
242
  break;
243
243
  }
244
244
  }
245
- Ze();
245
+ Xe();
246
246
  }
247
- function U(e) {
248
- const n = E(e);
249
- return n === e ? n : (I(n, "iterate", re), k(e) ? n : n.map(A));
247
+ function W(e) {
248
+ const n = S(e);
249
+ return n === e ? n : (T(n, "iterate", ie), L(e) ? n : n.map(x));
250
250
  }
251
- function Xe(e) {
252
- return I(e = E(e), "iterate", re), e;
251
+ function en(e) {
252
+ return T(e = S(e), "iterate", ie), e;
253
253
  }
254
- const ot = {
254
+ const rt = {
255
255
  __proto__: null,
256
256
  [Symbol.iterator]() {
257
- return Oe(this, Symbol.iterator, A);
257
+ return Oe(this, Symbol.iterator, x);
258
258
  },
259
259
  concat(...e) {
260
- return U(this).concat(
261
- ...e.map((n) => J(n) ? U(n) : n)
260
+ return W(this).concat(
261
+ ...e.map((n) => Y(n) ? W(n) : n)
262
262
  );
263
263
  },
264
264
  entries() {
265
- return Oe(this, "entries", (e) => (e[1] = A(e[1]), e));
265
+ return Oe(this, "entries", (e) => (e[1] = x(e[1]), e));
266
266
  },
267
267
  every(e, n) {
268
- return P(this, "every", e, n, void 0, arguments);
268
+ return D(this, "every", e, n, void 0, arguments);
269
269
  },
270
270
  filter(e, n) {
271
- return P(this, "filter", e, n, (t) => t.map(A), arguments);
271
+ return D(this, "filter", e, n, (t) => t.map(x), arguments);
272
272
  },
273
273
  find(e, n) {
274
- return P(this, "find", e, n, A, arguments);
274
+ return D(this, "find", e, n, x, arguments);
275
275
  },
276
276
  findIndex(e, n) {
277
- return P(this, "findIndex", e, n, void 0, arguments);
277
+ return D(this, "findIndex", e, n, void 0, arguments);
278
278
  },
279
279
  findLast(e, n) {
280
- return P(this, "findLast", e, n, A, arguments);
280
+ return D(this, "findLast", e, n, x, arguments);
281
281
  },
282
282
  findLastIndex(e, n) {
283
- return P(this, "findLastIndex", e, n, void 0, arguments);
283
+ return D(this, "findLastIndex", e, n, void 0, arguments);
284
284
  },
285
285
  // flat, flatMap could benefit from ARRAY_ITERATE but are not straight-forward to implement
286
286
  forEach(e, n) {
287
- return P(this, "forEach", e, n, void 0, arguments);
287
+ return D(this, "forEach", e, n, void 0, arguments);
288
288
  },
289
289
  includes(...e) {
290
- return Ae(this, "includes", e);
290
+ return xe(this, "includes", e);
291
291
  },
292
292
  indexOf(...e) {
293
- return Ae(this, "indexOf", e);
293
+ return xe(this, "indexOf", e);
294
294
  },
295
295
  join(e) {
296
- return U(this).join(e);
296
+ return W(this).join(e);
297
297
  },
298
298
  // keys() iterator only reads `length`, no optimisation required
299
299
  lastIndexOf(...e) {
300
- return Ae(this, "lastIndexOf", e);
300
+ return xe(this, "lastIndexOf", e);
301
301
  },
302
302
  map(e, n) {
303
- return P(this, "map", e, n, void 0, arguments);
303
+ return D(this, "map", e, n, void 0, arguments);
304
304
  },
305
305
  pop() {
306
- return ee(this, "pop");
306
+ return te(this, "pop");
307
307
  },
308
308
  push(...e) {
309
- return ee(this, "push", e);
309
+ return te(this, "push", e);
310
310
  },
311
311
  reduce(e, ...n) {
312
- return an(this, "reduce", e, n);
312
+ return un(this, "reduce", e, n);
313
313
  },
314
314
  reduceRight(e, ...n) {
315
- return an(this, "reduceRight", e, n);
315
+ return un(this, "reduceRight", e, n);
316
316
  },
317
317
  shift() {
318
- return ee(this, "shift");
318
+ return te(this, "shift");
319
319
  },
320
320
  // slice could use ARRAY_ITERATE but also seems to beg for range tracking
321
321
  some(e, n) {
322
- return P(this, "some", e, n, void 0, arguments);
322
+ return D(this, "some", e, n, void 0, arguments);
323
323
  },
324
324
  splice(...e) {
325
- return ee(this, "splice", e);
325
+ return te(this, "splice", e);
326
326
  },
327
327
  toReversed() {
328
- return U(this).toReversed();
328
+ return W(this).toReversed();
329
329
  },
330
330
  toSorted(e) {
331
- return U(this).toSorted(e);
331
+ return W(this).toSorted(e);
332
332
  },
333
333
  toSpliced(...e) {
334
- return U(this).toSpliced(...e);
334
+ return W(this).toSpliced(...e);
335
335
  },
336
336
  unshift(...e) {
337
- return ee(this, "unshift", e);
337
+ return te(this, "unshift", e);
338
338
  },
339
339
  values() {
340
- return Oe(this, "values", A);
340
+ return Oe(this, "values", x);
341
341
  }
342
342
  };
343
343
  function Oe(e, n, t) {
344
- const o = Xe(e), s = o[n]();
345
- return o !== e && !k(e) && (s._next = s.next, s.next = () => {
346
- const a = s._next();
347
- return a.value && (a.value = t(a.value)), a;
348
- }), s;
349
- }
350
- const st = Array.prototype;
351
- function P(e, n, t, o, s, a) {
352
- const c = Xe(e), g = c !== e && !k(e), v = c[n];
353
- if (v !== st[n]) {
354
- const i = v.apply(e, a);
355
- return g ? A(i) : i;
356
- }
357
- let d = t;
358
- c !== e && (g ? d = function(i, l) {
359
- return t.call(this, A(i), l, e);
360
- } : t.length > 2 && (d = function(i, l) {
361
- return t.call(this, i, l, e);
344
+ const s = en(e), o = s[n]();
345
+ return s !== e && !L(e) && (o._next = o.next, o.next = () => {
346
+ const r = o._next();
347
+ return r.value && (r.value = t(r.value)), r;
348
+ }), o;
349
+ }
350
+ const at = Array.prototype;
351
+ function D(e, n, t, s, o, r) {
352
+ const c = en(e), g = c !== e && !L(e), _ = c[n];
353
+ if (_ !== at[n]) {
354
+ const u = _.apply(e, r);
355
+ return g ? x(u) : u;
356
+ }
357
+ let m = t;
358
+ c !== e && (g ? m = function(u, i) {
359
+ return t.call(this, x(u), i, e);
360
+ } : t.length > 2 && (m = function(u, i) {
361
+ return t.call(this, u, i, e);
362
362
  }));
363
- const r = v.call(c, d, o);
364
- return g && s ? s(r) : r;
365
- }
366
- function an(e, n, t, o) {
367
- const s = Xe(e);
368
- let a = t;
369
- return s !== e && (k(e) ? t.length > 3 && (a = function(c, g, v) {
370
- return t.call(this, c, g, v, e);
371
- }) : a = function(c, g, v) {
372
- return t.call(this, c, A(g), v, e);
373
- }), s[n](a, ...o);
374
- }
375
- function Ae(e, n, t) {
376
- const o = E(e);
377
- I(o, "iterate", re);
378
- const s = o[n](...t);
379
- return (s === -1 || s === !1) && Ct(t[0]) ? (t[0] = E(t[0]), o[n](...t)) : s;
380
- }
381
- function ee(e, n, t = []) {
382
- et(), Ye();
383
- const o = E(e)[n].apply(e, t);
384
- return Ze(), nt(), o;
385
- }
386
- const rt = /* @__PURE__ */ Kn("__proto__,__v_isRef,__isVue"), _n = new Set(
387
- /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(ce)
363
+ const a = _.call(c, m, s);
364
+ return g && o ? o(a) : a;
365
+ }
366
+ function un(e, n, t, s) {
367
+ const o = en(e);
368
+ let r = t;
369
+ return o !== e && (L(e) ? t.length > 3 && (r = function(c, g, _) {
370
+ return t.call(this, c, g, _, e);
371
+ }) : r = function(c, g, _) {
372
+ return t.call(this, c, x(g), _, e);
373
+ }), o[n](r, ...s);
374
+ }
375
+ function xe(e, n, t) {
376
+ const s = S(e);
377
+ T(s, "iterate", ie);
378
+ const o = s[n](...t);
379
+ return (o === -1 || o === !1) && bt(t[0]) ? (t[0] = S(t[0]), s[n](...t)) : o;
380
+ }
381
+ function te(e, n, t = []) {
382
+ tt(), Ze();
383
+ const s = S(e)[n].apply(e, t);
384
+ return Xe(), ot(), s;
385
+ }
386
+ const it = /* @__PURE__ */ Gn("__proto__,__v_isRef,__isVue"), $n = new Set(
387
+ /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(le)
388
388
  );
389
- function at(e) {
390
- ce(e) || (e = String(e));
391
- const n = E(this);
392
- return I(n, "has", e), n.hasOwnProperty(e);
389
+ function ct(e) {
390
+ le(e) || (e = String(e));
391
+ const n = S(this);
392
+ return T(n, "has", e), n.hasOwnProperty(e);
393
393
  }
394
- class Cn {
394
+ class bn {
395
395
  constructor(n = !1, t = !1) {
396
396
  this._isReadonly = n, this._isShallow = t;
397
397
  }
398
- get(n, t, o) {
398
+ get(n, t, s) {
399
399
  if (t === "__v_skip") return n.__v_skip;
400
- const s = this._isReadonly, a = this._isShallow;
400
+ const o = this._isReadonly, r = this._isShallow;
401
401
  if (t === "__v_isReactive")
402
- return !s;
402
+ return !o;
403
403
  if (t === "__v_isReadonly")
404
- return s;
404
+ return o;
405
405
  if (t === "__v_isShallow")
406
- return a;
406
+ return r;
407
407
  if (t === "__v_raw")
408
- return o === (s ? a ? Nn : wn : a ? gt : bn).get(n) || // receiver is not the reactive proxy, but has the same prototype
408
+ return s === (o ? r ? En : yn : r ? _t : Nn).get(n) || // receiver is not the reactive proxy, but has the same prototype
409
409
  // this means the receiver is a user proxy of the reactive proxy
410
- Object.getPrototypeOf(n) === Object.getPrototypeOf(o) ? n : void 0;
411
- const c = J(n);
412
- if (!s) {
413
- let v;
414
- if (c && (v = ot[t]))
415
- return v;
410
+ Object.getPrototypeOf(n) === Object.getPrototypeOf(s) ? n : void 0;
411
+ const c = Y(n);
412
+ if (!o) {
413
+ let _;
414
+ if (c && (_ = rt[t]))
415
+ return _;
416
416
  if (t === "hasOwnProperty")
417
- return at;
417
+ return ct;
418
418
  }
419
419
  const g = Reflect.get(
420
420
  n,
@@ -422,78 +422,78 @@ class Cn {
422
422
  // if this is a proxy wrapping a ref, return methods using the raw ref
423
423
  // as receiver so that we don't have to call `toRaw` on the ref in all
424
424
  // its class methods
425
- Z(n) ? n : o
425
+ X(n) ? n : s
426
426
  );
427
- return (ce(t) ? _n.has(t) : rt(t)) || (s || I(n, "get", t), a) ? g : Z(g) ? c && Je(t) ? g : g.value : ye(g) ? s ? he(g) : yn(g) : g;
427
+ return (le(t) ? $n.has(t) : it(t)) || (o || T(n, "get", t), r) ? g : X(g) ? c && Ye(t) ? g : g.value : je(g) ? o ? ge(g) : jn(g) : g;
428
428
  }
429
429
  }
430
- class it extends Cn {
430
+ class ut extends bn {
431
431
  constructor(n = !1) {
432
432
  super(!1, n);
433
433
  }
434
- set(n, t, o, s) {
435
- let a = n[t];
434
+ set(n, t, s, o) {
435
+ let r = n[t];
436
436
  if (!this._isShallow) {
437
- const v = Q(a);
438
- if (!k(o) && !Q(o) && (a = E(a), o = E(o)), !J(n) && Z(a) && !Z(o))
439
- return v ? !1 : (a.value = o, !0);
437
+ const _ = ne(r);
438
+ if (!L(s) && !ne(s) && (r = S(r), s = S(s)), !Y(n) && X(r) && !X(s))
439
+ return _ ? !1 : (r.value = s, !0);
440
440
  }
441
- const c = J(n) && Je(t) ? Number(t) < n.length : Ve(n, t), g = Reflect.set(
441
+ const c = Y(n) && Ye(t) ? Number(t) < n.length : Re(n, t), g = Reflect.set(
442
442
  n,
443
443
  t,
444
- o,
445
- Z(n) ? n : s
444
+ s,
445
+ X(n) ? n : o
446
446
  );
447
- return n === E(s) && (c ? Y(o, a) && V(n, "set", t, o, a) : V(n, "add", t, o)), g;
447
+ return n === S(o) && (c ? Z(s, r) && R(n, "set", t, s, r) : R(n, "add", t, s)), g;
448
448
  }
449
449
  deleteProperty(n, t) {
450
- const o = Ve(n, t), s = n[t], a = Reflect.deleteProperty(n, t);
451
- return a && o && V(n, "delete", t, void 0, s), a;
450
+ const s = Re(n, t), o = n[t], r = Reflect.deleteProperty(n, t);
451
+ return r && s && R(n, "delete", t, void 0, o), r;
452
452
  }
453
453
  has(n, t) {
454
- const o = Reflect.has(n, t);
455
- return (!ce(t) || !_n.has(t)) && I(n, "has", t), o;
454
+ const s = Reflect.has(n, t);
455
+ return (!le(t) || !$n.has(t)) && T(n, "has", t), s;
456
456
  }
457
457
  ownKeys(n) {
458
- return I(
458
+ return T(
459
459
  n,
460
460
  "iterate",
461
- J(n) ? "length" : M
461
+ Y(n) ? "length" : B
462
462
  ), Reflect.ownKeys(n);
463
463
  }
464
464
  }
465
- class $n extends Cn {
465
+ class wn extends bn {
466
466
  constructor(n = !1) {
467
467
  super(!0, n);
468
468
  }
469
469
  set(n, t) {
470
- return process.env.NODE_ENV !== "production" && X(
470
+ return process.env.NODE_ENV !== "production" && ee(
471
471
  `Set operation on key "${String(t)}" failed: target is readonly.`,
472
472
  n
473
473
  ), !0;
474
474
  }
475
475
  deleteProperty(n, t) {
476
- return process.env.NODE_ENV !== "production" && X(
476
+ return process.env.NODE_ENV !== "production" && ee(
477
477
  `Delete operation on key "${String(t)}" failed: target is readonly.`,
478
478
  n
479
479
  ), !0;
480
480
  }
481
481
  }
482
- const ct = /* @__PURE__ */ new it(), ut = /* @__PURE__ */ new $n(), lt = /* @__PURE__ */ new $n(!0), He = (e) => e, le = (e) => Reflect.getPrototypeOf(e);
483
- function pt(e, n, t) {
484
- return function(...o) {
485
- const s = this.__v_raw, a = E(s), c = ne(a), g = e === "entries" || e === Symbol.iterator && c, v = e === "keys" && c, d = s[e](...o), r = t ? He : n ? Me : A;
486
- return !n && I(
487
- a,
482
+ const lt = /* @__PURE__ */ new ut(), pt = /* @__PURE__ */ new wn(), dt = /* @__PURE__ */ new wn(!0), Me = (e) => e, de = (e) => Reflect.getPrototypeOf(e);
483
+ function mt(e, n, t) {
484
+ return function(...s) {
485
+ const o = this.__v_raw, r = S(o), c = oe(r), g = e === "entries" || e === Symbol.iterator && c, _ = e === "keys" && c, m = o[e](...s), a = t ? Me : n ? Ke : x;
486
+ return !n && T(
487
+ r,
488
488
  "iterate",
489
- v ? ke : M
489
+ _ ? Le : B
490
490
  ), {
491
491
  // iterator protocol
492
492
  next() {
493
- const { value: i, done: l } = d.next();
494
- return l ? { value: i, done: l } : {
495
- value: g ? [r(i[0]), r(i[1])] : r(i),
496
- done: l
493
+ const { value: u, done: i } = m.next();
494
+ return i ? { value: u, done: i } : {
495
+ value: g ? [a(u[0]), a(u[1])] : a(u),
496
+ done: i
497
497
  };
498
498
  },
499
499
  // iterable protocol
@@ -503,75 +503,75 @@ function pt(e, n, t) {
503
503
  };
504
504
  };
505
505
  }
506
- function pe(e) {
506
+ function me(e) {
507
507
  return function(...n) {
508
508
  if (process.env.NODE_ENV !== "production") {
509
509
  const t = n[0] ? `on key "${n[0]}" ` : "";
510
- X(
511
- `${Jn(e)} operation ${t}failed: target is readonly.`,
512
- E(this)
510
+ ee(
511
+ `${Yn(e)} operation ${t}failed: target is readonly.`,
512
+ S(this)
513
513
  );
514
514
  }
515
515
  return e === "delete" ? !1 : e === "clear" ? void 0 : this;
516
516
  };
517
517
  }
518
- function dt(e, n) {
518
+ function ft(e, n) {
519
519
  const t = {
520
- get(s) {
521
- const a = this.__v_raw, c = E(a), g = E(s);
522
- e || (Y(s, g) && I(c, "get", s), I(c, "get", g));
523
- const { has: v } = le(c), d = n ? He : e ? Me : A;
524
- if (v.call(c, s))
525
- return d(a.get(s));
526
- if (v.call(c, g))
527
- return d(a.get(g));
528
- a !== c && a.get(s);
520
+ get(o) {
521
+ const r = this.__v_raw, c = S(r), g = S(o);
522
+ e || (Z(o, g) && T(c, "get", o), T(c, "get", g));
523
+ const { has: _ } = de(c), m = n ? Me : e ? Ke : x;
524
+ if (_.call(c, o))
525
+ return m(r.get(o));
526
+ if (_.call(c, g))
527
+ return m(r.get(g));
528
+ r !== c && r.get(o);
529
529
  },
530
530
  get size() {
531
- const s = this.__v_raw;
532
- return !e && I(E(s), "iterate", M), Reflect.get(s, "size", s);
531
+ const o = this.__v_raw;
532
+ return !e && T(S(o), "iterate", B), Reflect.get(o, "size", o);
533
533
  },
534
- has(s) {
535
- const a = this.__v_raw, c = E(a), g = E(s);
536
- return e || (Y(s, g) && I(c, "has", s), I(c, "has", g)), s === g ? a.has(s) : a.has(s) || a.has(g);
534
+ has(o) {
535
+ const r = this.__v_raw, c = S(r), g = S(o);
536
+ return e || (Z(o, g) && T(c, "has", o), T(c, "has", g)), o === g ? r.has(o) : r.has(o) || r.has(g);
537
537
  },
538
- forEach(s, a) {
539
- const c = this, g = c.__v_raw, v = E(g), d = n ? He : e ? Me : A;
540
- return !e && I(v, "iterate", M), g.forEach((r, i) => s.call(a, d(r), d(i), c));
538
+ forEach(o, r) {
539
+ const c = this, g = c.__v_raw, _ = S(g), m = n ? Me : e ? Ke : x;
540
+ return !e && T(_, "iterate", B), g.forEach((a, u) => o.call(r, m(a), m(u), c));
541
541
  }
542
542
  };
543
- return Fe(
543
+ return Ve(
544
544
  t,
545
545
  e ? {
546
- add: pe("add"),
547
- set: pe("set"),
548
- delete: pe("delete"),
549
- clear: pe("clear")
546
+ add: me("add"),
547
+ set: me("set"),
548
+ delete: me("delete"),
549
+ clear: me("clear")
550
550
  } : {
551
- add(s) {
552
- !n && !k(s) && !Q(s) && (s = E(s));
553
- const a = E(this);
554
- return le(a).has.call(a, s) || (a.add(s), V(a, "add", s, s)), this;
551
+ add(o) {
552
+ !n && !L(o) && !ne(o) && (o = S(o));
553
+ const r = S(this);
554
+ return de(r).has.call(r, o) || (r.add(o), R(r, "add", o, o)), this;
555
555
  },
556
- set(s, a) {
557
- !n && !k(a) && !Q(a) && (a = E(a));
558
- const c = E(this), { has: g, get: v } = le(c);
559
- let d = g.call(c, s);
560
- d ? process.env.NODE_ENV !== "production" && cn(c, g, s) : (s = E(s), d = g.call(c, s));
561
- const r = v.call(c, s);
562
- return c.set(s, a), d ? Y(a, r) && V(c, "set", s, a, r) : V(c, "add", s, a), this;
556
+ set(o, r) {
557
+ !n && !L(r) && !ne(r) && (r = S(r));
558
+ const c = S(this), { has: g, get: _ } = de(c);
559
+ let m = g.call(c, o);
560
+ m ? process.env.NODE_ENV !== "production" && ln(c, g, o) : (o = S(o), m = g.call(c, o));
561
+ const a = _.call(c, o);
562
+ return c.set(o, r), m ? Z(r, a) && R(c, "set", o, r, a) : R(c, "add", o, r), this;
563
563
  },
564
- delete(s) {
565
- const a = E(this), { has: c, get: g } = le(a);
566
- let v = c.call(a, s);
567
- v ? process.env.NODE_ENV !== "production" && cn(a, c, s) : (s = E(s), v = c.call(a, s));
568
- const d = g ? g.call(a, s) : void 0, r = a.delete(s);
569
- return v && V(a, "delete", s, void 0, d), r;
564
+ delete(o) {
565
+ const r = S(this), { has: c, get: g } = de(r);
566
+ let _ = c.call(r, o);
567
+ _ ? process.env.NODE_ENV !== "production" && ln(r, c, o) : (o = S(o), _ = c.call(r, o));
568
+ const m = g ? g.call(r, o) : void 0, a = r.delete(o);
569
+ return _ && R(r, "delete", o, void 0, m), a;
570
570
  },
571
571
  clear() {
572
- const s = E(this), a = s.size !== 0, c = process.env.NODE_ENV !== "production" ? ne(s) ? new Map(s) : new Set(s) : void 0, g = s.clear();
573
- return a && V(
574
- s,
572
+ const o = S(this), r = o.size !== 0, c = process.env.NODE_ENV !== "production" ? oe(o) ? new Map(o) : new Set(o) : void 0, g = o.clear();
573
+ return r && R(
574
+ o,
575
575
  "clear",
576
576
  void 0,
577
577
  void 0,
@@ -584,36 +584,36 @@ function dt(e, n) {
584
584
  "values",
585
585
  "entries",
586
586
  Symbol.iterator
587
- ].forEach((s) => {
588
- t[s] = pt(s, e, n);
587
+ ].forEach((o) => {
588
+ t[o] = mt(o, e, n);
589
589
  }), t;
590
590
  }
591
- function Qe(e, n) {
592
- const t = dt(e, n);
593
- return (o, s, a) => s === "__v_isReactive" ? !e : s === "__v_isReadonly" ? e : s === "__v_raw" ? o : Reflect.get(
594
- Ve(t, s) && s in o ? t : o,
595
- s,
596
- a
591
+ function nn(e, n) {
592
+ const t = ft(e, n);
593
+ return (s, o, r) => o === "__v_isReactive" ? !e : o === "__v_isReadonly" ? e : o === "__v_raw" ? s : Reflect.get(
594
+ Re(t, o) && o in s ? t : s,
595
+ o,
596
+ r
597
597
  );
598
598
  }
599
- const ft = {
600
- get: /* @__PURE__ */ Qe(!1, !1)
601
- }, mt = {
602
- get: /* @__PURE__ */ Qe(!0, !1)
603
- }, ht = {
604
- get: /* @__PURE__ */ Qe(!0, !0)
599
+ const ht = {
600
+ get: /* @__PURE__ */ nn(!1, !1)
601
+ }, vt = {
602
+ get: /* @__PURE__ */ nn(!0, !1)
603
+ }, gt = {
604
+ get: /* @__PURE__ */ nn(!0, !0)
605
605
  };
606
- function cn(e, n, t) {
607
- const o = E(t);
608
- if (o !== t && n.call(e, o)) {
609
- const s = dn(e);
610
- X(
611
- `Reactive ${s} contains both the raw and reactive versions of the same object${s === "Map" ? " as keys" : ""}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`
606
+ function ln(e, n, t) {
607
+ const s = S(t);
608
+ if (s !== t && n.call(e, s)) {
609
+ const o = fn(e);
610
+ ee(
611
+ `Reactive ${o} contains both the raw and reactive versions of the same object${o === "Map" ? " as keys" : ""}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`
612
612
  );
613
613
  }
614
614
  }
615
- const bn = /* @__PURE__ */ new WeakMap(), gt = /* @__PURE__ */ new WeakMap(), wn = /* @__PURE__ */ new WeakMap(), Nn = /* @__PURE__ */ new WeakMap();
616
- function vt(e) {
615
+ const Nn = /* @__PURE__ */ new WeakMap(), _t = /* @__PURE__ */ new WeakMap(), yn = /* @__PURE__ */ new WeakMap(), En = /* @__PURE__ */ new WeakMap();
616
+ function Ct(e) {
617
617
  switch (e) {
618
618
  case "Object":
619
619
  case "Array":
@@ -627,83 +627,83 @@ function vt(e) {
627
627
  return 0;
628
628
  }
629
629
  }
630
- function _t(e) {
631
- return e.__v_skip || !Object.isExtensible(e) ? 0 : vt(dn(e));
630
+ function $t(e) {
631
+ return e.__v_skip || !Object.isExtensible(e) ? 0 : Ct(fn(e));
632
632
  }
633
- function yn(e) {
634
- return Q(e) ? e : en(
633
+ function jn(e) {
634
+ return ne(e) ? e : tn(
635
635
  e,
636
636
  !1,
637
- ct,
638
- ft,
639
- bn
637
+ lt,
638
+ ht,
639
+ Nn
640
640
  );
641
641
  }
642
- function he(e) {
643
- return en(
642
+ function ge(e) {
643
+ return tn(
644
644
  e,
645
645
  !0,
646
- ut,
647
- mt,
648
- wn
646
+ pt,
647
+ vt,
648
+ yn
649
649
  );
650
650
  }
651
- function fe(e) {
652
- return en(
651
+ function he(e) {
652
+ return tn(
653
653
  e,
654
654
  !0,
655
- lt,
656
- ht,
657
- Nn
655
+ dt,
656
+ gt,
657
+ En
658
658
  );
659
659
  }
660
- function en(e, n, t, o, s) {
661
- if (!ye(e))
662
- return process.env.NODE_ENV !== "production" && X(
660
+ function tn(e, n, t, s, o) {
661
+ if (!je(e))
662
+ return process.env.NODE_ENV !== "production" && ee(
663
663
  `value cannot be made ${n ? "readonly" : "reactive"}: ${String(
664
664
  e
665
665
  )}`
666
666
  ), e;
667
667
  if (e.__v_raw && !(n && e.__v_isReactive))
668
668
  return e;
669
- const a = s.get(e);
670
- if (a)
671
- return a;
672
- const c = _t(e);
669
+ const r = o.get(e);
670
+ if (r)
671
+ return r;
672
+ const c = $t(e);
673
673
  if (c === 0)
674
674
  return e;
675
675
  const g = new Proxy(
676
676
  e,
677
- c === 2 ? o : t
677
+ c === 2 ? s : t
678
678
  );
679
- return s.set(e, g), g;
679
+ return o.set(e, g), g;
680
680
  }
681
- function Q(e) {
681
+ function ne(e) {
682
682
  return !!(e && e.__v_isReadonly);
683
683
  }
684
- function k(e) {
684
+ function L(e) {
685
685
  return !!(e && e.__v_isShallow);
686
686
  }
687
- function Ct(e) {
687
+ function bt(e) {
688
688
  return e ? !!e.__v_raw : !1;
689
689
  }
690
- function E(e) {
690
+ function S(e) {
691
691
  const n = e && e.__v_raw;
692
- return n ? E(n) : e;
692
+ return n ? S(n) : e;
693
693
  }
694
- const A = (e) => ye(e) ? yn(e) : e, Me = (e) => ye(e) ? he(e) : e;
695
- function Z(e) {
694
+ const x = (e) => je(e) ? jn(e) : e, Ke = (e) => je(e) ? ge(e) : e;
695
+ function X(e) {
696
696
  return e ? e.__v_isRef === !0 : !1;
697
697
  }
698
- function ge(e) {
699
- return $t(e, !1);
698
+ function _e(e) {
699
+ return wt(e, !1);
700
700
  }
701
- function $t(e, n) {
702
- return Z(e) ? e : new bt(e, n);
701
+ function wt(e, n) {
702
+ return X(e) ? e : new Nt(e, n);
703
703
  }
704
- class bt {
704
+ class Nt {
705
705
  constructor(n, t) {
706
- this.dep = new qe(), this.__v_isRef = !0, this.__v_isShallow = !1, this._rawValue = t ? n : E(n), this._value = t ? n : A(n), this.__v_isShallow = t;
706
+ this.dep = new Qe(), this.__v_isRef = !0, this.__v_isShallow = !1, this._rawValue = t ? n : S(n), this._value = t ? n : x(n), this.__v_isShallow = t;
707
707
  }
708
708
  get value() {
709
709
  return process.env.NODE_ENV !== "production" ? this.dep.track({
@@ -713,8 +713,8 @@ class bt {
713
713
  }) : this.dep.track(), this._value;
714
714
  }
715
715
  set value(n) {
716
- const t = this._rawValue, o = this.__v_isShallow || k(n) || Q(n);
717
- n = o ? n : E(n), Y(n, t) && (this._rawValue = n, this._value = o ? n : A(n), process.env.NODE_ENV !== "production" ? this.dep.trigger({
716
+ const t = this._rawValue, s = this.__v_isShallow || L(n) || ne(n);
717
+ n = s ? n : S(n), Z(n, t) && (this._rawValue = n, this._value = s ? n : x(n), process.env.NODE_ENV !== "production" ? this.dep.trigger({
718
718
  target: this,
719
719
  type: "set",
720
720
  key: "value",
@@ -723,17 +723,17 @@ class bt {
723
723
  }) : this.dep.trigger());
724
724
  }
725
725
  }
726
- class wt {
727
- constructor(n, t, o) {
728
- this.fn = n, this.setter = t, this._value = void 0, this.dep = new qe(this), this.__v_isRef = !0, this.deps = void 0, this.depsTail = void 0, this.flags = 16, this.globalVersion = se - 1, this.next = void 0, this.effect = this, this.__v_isReadonly = !t, this.isSSR = o;
726
+ class yt {
727
+ constructor(n, t, s) {
728
+ this.fn = n, this.setter = t, this._value = void 0, this.dep = new Qe(this), this.__v_isRef = !0, this.deps = void 0, this.depsTail = void 0, this.flags = 16, this.globalVersion = ae - 1, this.next = void 0, this.effect = this, this.__v_isReadonly = !t, this.isSSR = s;
729
729
  }
730
730
  /**
731
731
  * @internal
732
732
  */
733
733
  notify() {
734
734
  if (this.flags |= 16, !(this.flags & 8) && // avoid infinite self recursion
735
- S !== this)
736
- return Yn(this, !0), !0;
735
+ A !== this)
736
+ return Zn(this, !0), !0;
737
737
  process.env.NODE_ENV;
738
738
  }
739
739
  get value() {
@@ -742,230 +742,230 @@ class wt {
742
742
  type: "get",
743
743
  key: "value"
744
744
  }) : this.dep.track();
745
- return mn(this), n && (n.version = this.dep.version), this._value;
745
+ return vn(this), n && (n.version = this.dep.version), this._value;
746
746
  }
747
747
  set value(n) {
748
- this.setter ? this.setter(n) : process.env.NODE_ENV !== "production" && X("Write operation failed: computed value is readonly");
748
+ this.setter ? this.setter(n) : process.env.NODE_ENV !== "production" && ee("Write operation failed: computed value is readonly");
749
749
  }
750
750
  }
751
- function Le(e, n, t = !1) {
752
- let o, s;
753
- Bn(e) ? o = e : (o = e.get, s = e.set);
754
- const a = new wt(o, s, t);
755
- return process.env.NODE_ENV, a;
751
+ function Be(e, n, t = !1) {
752
+ let s, o;
753
+ zn(e) ? s = e : (s = e.get, o = e.set);
754
+ const r = new yt(s, o, t);
755
+ return process.env.NODE_ENV, r;
756
756
  }
757
- const Nt = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
758
- let yt = (e = 21) => {
757
+ const Et = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
758
+ let jt = (e = 21) => {
759
759
  let n = "", t = crypto.getRandomValues(new Uint8Array(e |= 0));
760
760
  for (; e--; )
761
- n += Nt[t[e] & 63];
761
+ n += Et[t[e] & 63];
762
762
  return n;
763
763
  };
764
- function Et(e, n = !0, t = !1) {
765
- const o = ge();
766
- let s;
767
- const a = ge(!1);
764
+ function St(e, n = !0, t = !1) {
765
+ const s = _e();
766
+ let o;
767
+ const r = _e(!1);
768
768
  let c = () => {
769
769
  };
770
770
  const g = new Proxy(e, {
771
- apply: function(r, i, l) {
772
- let m;
771
+ apply: function(a, u, i) {
772
+ let p;
773
773
  try {
774
- m = r(...l);
775
- } catch (C) {
776
- m = C;
774
+ p = a(...i);
775
+ } catch (b) {
776
+ p = b;
777
777
  }
778
- if (m instanceof Error) {
779
- if (o.value = m, s = m, n)
780
- throw c(), m;
778
+ if (p instanceof Error) {
779
+ if (s.value = p, o = p, n)
780
+ throw c(), p;
781
781
  } else
782
- a.value = !0, o.value = void 0, s = !0, c();
782
+ r.value = !0, s.value = void 0, o = !0, c();
783
783
  }
784
- }), v = () => {
785
- }, d = new Proxy(
786
- (r) => {
787
- o.value = r;
784
+ }), _ = () => {
785
+ }, m = new Proxy(
786
+ (a) => {
787
+ s.value = a;
788
788
  },
789
789
  {
790
- apply: function(r, i, l) {
791
- r(...l), v(...l);
790
+ apply: function(a, u, i) {
791
+ a(...i), _(...i);
792
792
  }
793
793
  }
794
794
  );
795
795
  return {
796
- promise: new Promise((r, i) => {
797
- if (n && s instanceof Error) {
798
- i(s);
796
+ promise: new Promise((a, u) => {
797
+ if (n && o instanceof Error) {
798
+ u(o);
799
799
  return;
800
- } else if (s === !0) {
801
- r();
800
+ } else if (o === !0) {
801
+ a();
802
802
  return;
803
803
  }
804
- let l;
805
- t && (l = setTimeout(() => {
806
- const m = new Error("timeout!");
807
- o.value = m, n && i(m);
804
+ let i;
805
+ t && (i = setTimeout(() => {
806
+ const p = new Error("timeout!");
807
+ s.value = p, n && u(p);
808
808
  }, t)), c = () => {
809
- l && (clearTimeout(l), l = void 0), r();
809
+ i && (clearTimeout(i), i = void 0), a();
810
810
  };
811
811
  }),
812
812
  callback: g,
813
- onError: d,
814
- resolved: Le(() => a.value),
815
- error: Le(() => o.value)
813
+ onError: m,
814
+ resolved: Be(() => r.value),
815
+ error: Be(() => s.value)
816
816
  };
817
817
  }
818
- function Ke() {
819
- return yt();
818
+ function Ge() {
819
+ return jt();
820
820
  }
821
- function St() {
822
- const e = {}, n = {}, t = /* @__PURE__ */ new WeakMap(), o = {};
821
+ function At() {
822
+ const e = {}, n = {}, t = /* @__PURE__ */ new WeakMap(), s = {};
823
823
  return Object.freeze({
824
- registerAgg(s) {
825
- if (s.isInitialized.value)
824
+ registerAgg(o) {
825
+ if (o.isInitialized.value)
826
826
  throw new Error("Agg must register before initialized");
827
- if (o[s.__id])
827
+ if (s[o.__id])
828
828
  throw new Error("Agg already registered");
829
- s.type === "MultiInstance" && s.api.events.destroyed.watchPublish(() => {
830
- delete o[s.__id];
831
- }), o[s.__id] = s;
832
- const a = [];
829
+ o.type === "MultiInstance" && o.api.events.destroyed.watchPublish(() => {
830
+ delete s[o.__id];
831
+ }), s[o.__id] = o;
832
+ const r = [];
833
833
  for (const c of Object.values(e))
834
- c.mount({ api: s.api, __aggId: s.__id, isInitialized: s.isInitialized });
834
+ c.mount({ api: o.api, __aggId: o.__id, isInitialized: o.isInitialized });
835
835
  for (const c of Object.values(n))
836
- c.mount({ api: s.api, __aggId: s.__id }), a.push(c.__id);
837
- t.set(s, a);
836
+ c.mount({ api: o.api, __aggId: o.__id }), r.push(c.__id);
837
+ t.set(o, r);
838
838
  },
839
- createSetupPlugin(s) {
840
- let a;
841
- return s instanceof Function ? a = s() : a = s, Object.freeze({
842
- __id: Ke(),
839
+ createSetupPlugin(o) {
840
+ let r;
841
+ return o instanceof Function ? r = o() : r = o, Object.freeze({
842
+ __id: Ge(),
843
843
  type: "Setup",
844
844
  mount(c) {
845
845
  if (c.isInitialized.value)
846
846
  throw new Error("Can not setup after initialized");
847
- a.mount({ api: c.api, __aggId: c.__aggId });
847
+ r.mount({ api: c.api, __aggId: c.__aggId });
848
848
  }
849
849
  });
850
850
  },
851
- createHotSwapPlugin(s) {
852
- let a;
853
- return s instanceof Function ? a = s() : a = s, Object.freeze({
854
- __id: Ke(),
851
+ createHotSwapPlugin(o) {
852
+ let r;
853
+ return o instanceof Function ? r = o() : r = o, Object.freeze({
854
+ __id: Ge(),
855
855
  type: "HotSwap",
856
- mount: a.mount,
857
- unmount: a.unmount
856
+ mount: r.mount,
857
+ unmount: r.unmount
858
858
  });
859
859
  },
860
- registerPlugin(s) {
861
- if (s.type === "Setup") {
862
- if (e[s.__id])
860
+ registerPlugin(o) {
861
+ if (o.type === "Setup") {
862
+ if (e[o.__id])
863
863
  throw new Error("Plugin already registered");
864
- e[s.__id] = s;
865
- for (const a in o)
866
- s.mount({
867
- api: o[a].api,
868
- __aggId: o[a].__id,
869
- isInitialized: o[a].isInitialized
864
+ e[o.__id] = o;
865
+ for (const r in s)
866
+ o.mount({
867
+ api: s[r].api,
868
+ __aggId: s[r].__id,
869
+ isInitialized: s[r].isInitialized
870
870
  });
871
- } else if (s.type === "HotSwap") {
872
- n[s.__id] = s;
873
- for (const a in o)
874
- t.has(o[a]) && !t.get(o[a]).includes(s.__id) && (s.mount({ api: o[a].api, __aggId: o[a].__id }), t.get(o[a]).push(s.__id));
871
+ } else if (o.type === "HotSwap") {
872
+ n[o.__id] = o;
873
+ for (const r in s)
874
+ t.has(s[r]) && !t.get(s[r]).includes(o.__id) && (o.mount({ api: s[r].api, __aggId: s[r].__id }), t.get(s[r]).push(o.__id));
875
875
  } else
876
- isNever(s);
876
+ isNever(o);
877
877
  },
878
- unregisterPlugin(s) {
879
- if (s.type === "Setup")
878
+ unregisterPlugin(o) {
879
+ if (o.type === "Setup")
880
880
  throw new Error("Can not unregister setup plugin");
881
- if (s.type === "HotSwap") {
882
- for (const a in o)
883
- t.has(o[a]) && t.get(o[a]).includes(s.__id) && s.unmount({ api: o[a].api, __aggId: o[a].__id });
884
- delete n[s.__id];
881
+ if (o.type === "HotSwap") {
882
+ for (const r in s)
883
+ t.has(s[r]) && t.get(s[r]).includes(o.__id) && o.unmount({ api: s[r].api, __aggId: s[r].__id });
884
+ delete n[o.__id];
885
885
  } else
886
- isNever(s);
886
+ isNever(o);
887
887
  }
888
888
  });
889
889
  }
890
- function jt(e) {
891
- return St();
890
+ function It(e) {
891
+ return At();
892
892
  }
893
893
  function Ot(e) {
894
- const n = At(e);
895
- return fe({
894
+ const n = xt(e);
895
+ return he({
896
896
  states: n.states,
897
897
  commands: n.commands,
898
898
  events: n.events
899
899
  });
900
900
  }
901
- function At(e) {
901
+ function xt(e) {
902
902
  const n = e.states;
903
903
  for (const c of Object.keys(e.states))
904
- n[c] = he(n[c]);
905
- const t = fe(e.states), o = he(e.commands), s = {}, a = e.events;
904
+ n[c] = ge(n[c]);
905
+ const t = he(e.states), s = ge(e.commands), o = {}, r = e.events;
906
906
  for (const c in e.events)
907
- s[c] = a[c].api;
908
- return fe({
907
+ o[c] = r[c].api;
908
+ return he({
909
909
  states: t,
910
- commands: o,
911
- events: fe(s),
910
+ commands: s,
911
+ events: he(o),
912
912
  destroy: e.destroy
913
913
  });
914
914
  }
915
- function It(e) {
915
+ function Tt(e) {
916
916
  const {
917
917
  callback: n,
918
918
  onError: t,
919
- promise: o,
920
- resolved: s
921
- } = Et(() => {
919
+ promise: s,
920
+ resolved: o
921
+ } = St(() => {
922
922
  }, !1, 5e3);
923
- function a(i) {
924
- if (s.value === !0)
923
+ function r(u) {
924
+ if (o.value === !0)
925
925
  throw new Error("Agg already initialized");
926
- c.push(i());
926
+ c.push(u());
927
927
  }
928
928
  const c = [], g = e({
929
- onCreated(i) {
930
- Promise.resolve().then(i);
929
+ onCreated(u) {
930
+ Promise.resolve().then(u);
931
931
  },
932
- onBeforeInitialize: a,
933
- isInitialized: Le(() => s.value),
934
- untilInitialized: o
932
+ onBeforeInitialize: r,
933
+ isInitialized: Be(() => o.value),
934
+ untilInitialized: s
935
935
  });
936
936
  setTimeout(
937
937
  () => Promise.all(c).then(() => {
938
938
  n();
939
- }).catch((i) => {
940
- t(i);
939
+ }).catch((u) => {
940
+ t(u);
941
941
  }),
942
942
  0
943
943
  );
944
- const v = g.states || {}, d = g.commands || {}, r = g.events || {};
944
+ const _ = g.states || {}, m = g.commands || {}, a = g.events || {};
945
945
  return {
946
- __id: Ke(),
946
+ __id: Ge(),
947
947
  type: "Singleton",
948
948
  api: Ot({
949
- states: v,
950
- commands: d,
951
- events: r,
949
+ states: _,
950
+ commands: m,
951
+ events: a,
952
952
  destroy: () => {
953
953
  }
954
954
  }),
955
- isInitialized: s,
955
+ isInitialized: o,
956
956
  async untilInitialized() {
957
- return await o.catch((i) => {
958
- throw new Error(`Failed to initialize Agg: ${i.message}
959
- Stack : ${i.stack || "unkown"}`);
957
+ return await s.catch((u) => {
958
+ throw new Error(`Failed to initialize Agg: ${u.message}
959
+ Stack : ${u.stack || "unkown"}`);
960
960
  });
961
961
  }
962
962
  };
963
963
  }
964
- let de;
965
- function xt(e) {
966
- return It(() => {
967
- const n = ge(e), t = ge({});
968
- let o = () => [], s = () => [], a = () => [], c = () => [], g = () => [], v = () => [], d = () => [];
964
+ let fe;
965
+ function Pt(e) {
966
+ return Tt(() => {
967
+ const n = _e(e), t = _e({});
968
+ let s = () => [], o = () => [], r = () => [], c = () => [], g = () => [], _ = () => [], m = () => [];
969
969
  return {
970
970
  states: {
971
971
  designer: n,
@@ -973,126 +973,126 @@ function xt(e) {
973
973
  },
974
974
  commands: {
975
975
  genCodeFiles() {
976
- return d();
976
+ return m();
977
977
  },
978
978
  clearCaches() {
979
979
  },
980
- setContext(r) {
981
- t.value = r;
980
+ setContext(a) {
981
+ t.value = a;
982
982
  },
983
- setDomainDesigner(r) {
984
- this.clearCaches(), n.value = r;
983
+ setDomainDesigner(a) {
984
+ this.clearCaches(), n.value = a;
985
985
  },
986
- _genInfoCode(...r) {
987
- return o(...r);
986
+ _genInfoCode(...a) {
987
+ return s(...a);
988
988
  },
989
- _setInfoCodeProvider(r) {
990
- o = r;
989
+ _setInfoCodeProvider(a) {
990
+ s = a;
991
991
  },
992
- _genCommandCode(...r) {
993
- return s(...r);
992
+ _genCommandCode(...a) {
993
+ return o(...a);
994
994
  },
995
- _setCommandCodeProvider(r) {
996
- s = r;
995
+ _setCommandCodeProvider(a) {
996
+ o = a;
997
997
  },
998
- _genFacadeCommandCode(...r) {
999
- return a(...r);
998
+ _genFacadeCommandCode(...a) {
999
+ return r(...a);
1000
1000
  },
1001
- _setFacadeCommandCodeProvider(r) {
1002
- a = r;
1001
+ _setFacadeCommandCodeProvider(a) {
1002
+ r = a;
1003
1003
  },
1004
- _genAggCode(...r) {
1005
- return c(...r);
1004
+ _genAggCode(...a) {
1005
+ return c(...a);
1006
1006
  },
1007
- _setAggCodeProvider(r) {
1008
- c = r;
1007
+ _setAggCodeProvider(a) {
1008
+ c = a;
1009
1009
  },
1010
- _genEventCode(...r) {
1011
- return g(...r);
1010
+ _genEventCode(...a) {
1011
+ return g(...a);
1012
1012
  },
1013
- _setEventCodeProvider(r) {
1014
- g = r;
1013
+ _setEventCodeProvider(a) {
1014
+ g = a;
1015
1015
  },
1016
- _genReadModelCode(...r) {
1017
- return v(...r);
1016
+ _genReadModelCode(...a) {
1017
+ return _(...a);
1018
1018
  },
1019
- _setReadModelCodeProvider(r) {
1020
- v = r;
1019
+ _setReadModelCodeProvider(a) {
1020
+ _ = a;
1021
1021
  },
1022
- _setCodeFileProvider(r) {
1023
- d = r;
1022
+ _setCodeFileProvider(a) {
1023
+ m = a;
1024
1024
  }
1025
1025
  }
1026
1026
  };
1027
1027
  });
1028
1028
  }
1029
- const ue = jt();
1030
- function So(e) {
1031
- if (!de) {
1029
+ const pe = It();
1030
+ function Ao(e) {
1031
+ if (!fe) {
1032
1032
  if (!e)
1033
1033
  throw new Error("designer is required");
1034
- de = xt(e), ue.registerAgg(de);
1034
+ fe = Pt(e), pe.registerAgg(fe);
1035
1035
  }
1036
- return de.api;
1036
+ return fe.api;
1037
1037
  }
1038
- function Ee(e) {
1038
+ function Se(e) {
1039
1039
  return e && e._attributes && e._attributes.rule === "Info";
1040
1040
  }
1041
- function Dt(e) {
1041
+ function Ft(e) {
1042
1042
  return e && e._attributes && e._attributes.rule === "Agg";
1043
1043
  }
1044
- function Pt(e) {
1044
+ function Dt(e) {
1045
1045
  return e && e._attributes && e._attributes.rule === "Command";
1046
1046
  }
1047
- function Tt(e) {
1047
+ function kt(e) {
1048
1048
  return e && e._attributes && e._attributes.rule === "FacadeCommand";
1049
1049
  }
1050
- function Ft(e) {
1050
+ function Vt(e) {
1051
1051
  return e && e._attributes && e._attributes.rule === "Event";
1052
1052
  }
1053
- function Vt(e) {
1053
+ function Rt(e) {
1054
1054
  return e && e._attributes && e._attributes.rule === "ReadModel";
1055
1055
  }
1056
- const ze = process.env.NODE_ENV !== "production" ? Object.freeze({}) : {};
1056
+ const Ue = process.env.NODE_ENV !== "production" ? Object.freeze({}) : {};
1057
1057
  process.env.NODE_ENV !== "production" && Object.freeze([]);
1058
- const Rt = () => {
1059
- }, kt = (e) => e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && // uppercase letter
1060
- (e.charCodeAt(2) > 122 || e.charCodeAt(2) < 97), Se = Object.assign, D = Array.isArray, B = (e) => typeof e == "function", H = (e) => typeof e == "string", Ht = (e) => typeof e == "symbol", L = (e) => e !== null && typeof e == "object";
1061
- let un;
1062
- const je = () => un || (un = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {});
1063
- function nn(e) {
1064
- if (D(e)) {
1058
+ const Ht = () => {
1059
+ }, Lt = (e) => e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && // uppercase letter
1060
+ (e.charCodeAt(2) > 122 || e.charCodeAt(2) < 97), Ae = Object.assign, F = Array.isArray, J = (e) => typeof e == "function", M = (e) => typeof e == "string", Mt = (e) => typeof e == "symbol", G = (e) => e !== null && typeof e == "object";
1061
+ let pn;
1062
+ const Ie = () => pn || (pn = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {});
1063
+ function on(e) {
1064
+ if (F(e)) {
1065
1065
  const n = {};
1066
1066
  for (let t = 0; t < e.length; t++) {
1067
- const o = e[t], s = H(o) ? zt(o) : nn(o);
1068
- if (s)
1069
- for (const a in s)
1070
- n[a] = s[a];
1067
+ const s = e[t], o = M(s) ? Ut(s) : on(s);
1068
+ if (o)
1069
+ for (const r in o)
1070
+ n[r] = o[r];
1071
1071
  }
1072
1072
  return n;
1073
- } else if (H(e) || L(e))
1073
+ } else if (M(e) || G(e))
1074
1074
  return e;
1075
1075
  }
1076
- const Mt = /;(?![^(]*\))/g, Lt = /:([^]+)/, Kt = /\/\*[^]*?\*\//g;
1077
- function zt(e) {
1076
+ const Kt = /;(?![^(]*\))/g, Bt = /:([^]+)/, Gt = /\/\*[^]*?\*\//g;
1077
+ function Ut(e) {
1078
1078
  const n = {};
1079
- return e.replace(Kt, "").split(Mt).forEach((t) => {
1079
+ return e.replace(Gt, "").split(Kt).forEach((t) => {
1080
1080
  if (t) {
1081
- const o = t.split(Lt);
1082
- o.length > 1 && (n[o[0].trim()] = o[1].trim());
1081
+ const s = t.split(Bt);
1082
+ s.length > 1 && (n[s[0].trim()] = s[1].trim());
1083
1083
  }
1084
1084
  }), n;
1085
1085
  }
1086
- function tn(e) {
1086
+ function sn(e) {
1087
1087
  let n = "";
1088
- if (H(e))
1088
+ if (M(e))
1089
1089
  n = e;
1090
- else if (D(e))
1090
+ else if (F(e))
1091
1091
  for (let t = 0; t < e.length; t++) {
1092
- const o = tn(e[t]);
1093
- o && (n += o + " ");
1092
+ const s = sn(e[t]);
1093
+ s && (n += s + " ");
1094
1094
  }
1095
- else if (L(e))
1095
+ else if (G(e))
1096
1096
  for (const t in e)
1097
1097
  e[t] && (n += t + " ");
1098
1098
  return n.trim();
@@ -1107,25 +1107,25 @@ Symbol(
1107
1107
  process.env.NODE_ENV !== "production" ? "Array iterate" : ""
1108
1108
  );
1109
1109
  new Set(
1110
- /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(Ht)
1110
+ /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(Mt)
1111
1111
  );
1112
- function En(e) {
1113
- return Be(e) ? En(e.__v_raw) : !!(e && e.__v_isReactive);
1112
+ function Sn(e) {
1113
+ return ze(e) ? Sn(e.__v_raw) : !!(e && e.__v_isReactive);
1114
1114
  }
1115
- function Be(e) {
1115
+ function ze(e) {
1116
1116
  return !!(e && e.__v_isReadonly);
1117
1117
  }
1118
- function Ie(e) {
1118
+ function Te(e) {
1119
1119
  return !!(e && e.__v_isShallow);
1120
1120
  }
1121
- function Ue(e) {
1121
+ function Je(e) {
1122
1122
  return e ? !!e.__v_raw : !1;
1123
1123
  }
1124
- function K(e) {
1124
+ function U(e) {
1125
1125
  const n = e && e.__v_raw;
1126
- return n ? K(n) : e;
1126
+ return n ? U(n) : e;
1127
1127
  }
1128
- function on(e) {
1128
+ function rn(e) {
1129
1129
  return e ? e.__v_isRef === !0 : !1;
1130
1130
  }
1131
1131
  /**
@@ -1134,44 +1134,44 @@ function on(e) {
1134
1134
  * @license MIT
1135
1135
  **/
1136
1136
  const z = [];
1137
- function Bt(e) {
1137
+ function zt(e) {
1138
1138
  z.push(e);
1139
1139
  }
1140
- function Ut() {
1140
+ function Jt() {
1141
1141
  z.pop();
1142
1142
  }
1143
- let xe = !1;
1144
- function ae(e, ...n) {
1145
- if (xe) return;
1146
- xe = !0;
1147
- const t = z.length ? z[z.length - 1].component : null, o = t && t.appContext.config.warnHandler, s = Gt();
1148
- if (o)
1149
- sn(
1150
- o,
1143
+ let Pe = !1;
1144
+ function ce(e, ...n) {
1145
+ if (Pe) return;
1146
+ Pe = !0;
1147
+ const t = z.length ? z[z.length - 1].component : null, s = t && t.appContext.config.warnHandler, o = Wt();
1148
+ if (s)
1149
+ an(
1150
+ s,
1151
1151
  t,
1152
1152
  11,
1153
1153
  [
1154
1154
  // eslint-disable-next-line no-restricted-syntax
1155
- e + n.map((a) => {
1155
+ e + n.map((r) => {
1156
1156
  var c, g;
1157
- return (g = (c = a.toString) == null ? void 0 : c.call(a)) != null ? g : JSON.stringify(a);
1157
+ return (g = (c = r.toString) == null ? void 0 : c.call(r)) != null ? g : JSON.stringify(r);
1158
1158
  }).join(""),
1159
1159
  t && t.proxy,
1160
- s.map(
1161
- ({ vnode: a }) => `at <${Hn(t, a.type)}>`
1160
+ o.map(
1161
+ ({ vnode: r }) => `at <${Mn(t, r.type)}>`
1162
1162
  ).join(`
1163
1163
  `),
1164
- s
1164
+ o
1165
1165
  ]
1166
1166
  );
1167
1167
  else {
1168
- const a = [`[Vue warn]: ${e}`, ...n];
1169
- s.length && a.push(`
1170
- `, ...Wt(s));
1168
+ const r = [`[Vue warn]: ${e}`, ...n];
1169
+ o.length && r.push(`
1170
+ `, ...qt(o));
1171
1171
  }
1172
- xe = !1;
1172
+ Pe = !1;
1173
1173
  }
1174
- function Gt() {
1174
+ function Wt() {
1175
1175
  let e = z[z.length - 1];
1176
1176
  if (!e)
1177
1177
  return [];
@@ -1182,36 +1182,36 @@ function Gt() {
1182
1182
  vnode: e,
1183
1183
  recurseCount: 0
1184
1184
  });
1185
- const o = e.component && e.component.parent;
1186
- e = o && o.vnode;
1185
+ const s = e.component && e.component.parent;
1186
+ e = s && s.vnode;
1187
1187
  }
1188
1188
  return n;
1189
1189
  }
1190
- function Wt(e) {
1190
+ function qt(e) {
1191
1191
  const n = [];
1192
- return e.forEach((t, o) => {
1193
- n.push(...o === 0 ? [] : [`
1194
- `], ...Jt(t));
1192
+ return e.forEach((t, s) => {
1193
+ n.push(...s === 0 ? [] : [`
1194
+ `], ...Yt(t));
1195
1195
  }), n;
1196
1196
  }
1197
- function Jt({ vnode: e, recurseCount: n }) {
1198
- const t = n > 0 ? `... (${n} recursive calls)` : "", o = e.component ? e.component.parent == null : !1, s = ` at <${Hn(
1197
+ function Yt({ vnode: e, recurseCount: n }) {
1198
+ const t = n > 0 ? `... (${n} recursive calls)` : "", s = e.component ? e.component.parent == null : !1, o = ` at <${Mn(
1199
1199
  e.component,
1200
1200
  e.type,
1201
- o
1202
- )}`, a = ">" + t;
1203
- return e.props ? [s, ...Yt(e.props), a] : [s + a];
1201
+ s
1202
+ )}`, r = ">" + t;
1203
+ return e.props ? [o, ...Zt(e.props), r] : [o + r];
1204
1204
  }
1205
- function Yt(e) {
1205
+ function Zt(e) {
1206
1206
  const n = [], t = Object.keys(e);
1207
- return t.slice(0, 3).forEach((o) => {
1208
- n.push(...Sn(o, e[o]));
1207
+ return t.slice(0, 3).forEach((s) => {
1208
+ n.push(...An(s, e[s]));
1209
1209
  }), t.length > 3 && n.push(" ..."), n;
1210
1210
  }
1211
- function Sn(e, n, t) {
1212
- return H(n) ? (n = JSON.stringify(n), t ? n : [`${e}=${n}`]) : typeof n == "number" || typeof n == "boolean" || n == null ? t ? n : [`${e}=${n}`] : on(n) ? (n = Sn(e, K(n.value), !0), t ? n : [`${e}=Ref<`, n, ">"]) : B(n) ? [`${e}=fn${n.name ? `<${n.name}>` : ""}`] : (n = K(n), t ? n : [`${e}=`, n]);
1211
+ function An(e, n, t) {
1212
+ return M(n) ? (n = JSON.stringify(n), t ? n : [`${e}=${n}`]) : typeof n == "number" || typeof n == "boolean" || n == null ? t ? n : [`${e}=${n}`] : rn(n) ? (n = An(e, U(n.value), !0), t ? n : [`${e}=Ref<`, n, ">"]) : J(n) ? [`${e}=fn${n.name ? `<${n.name}>` : ""}`] : (n = U(n), t ? n : [`${e}=`, n]);
1213
1213
  }
1214
- const jn = {
1214
+ const In = {
1215
1215
  sp: "serverPrefetch hook",
1216
1216
  bc: "beforeCreate hook",
1217
1217
  c: "created hook",
@@ -1244,101 +1244,101 @@ const jn = {
1244
1244
  15: "component update",
1245
1245
  16: "app unmount cleanup function"
1246
1246
  };
1247
- function sn(e, n, t, o) {
1247
+ function an(e, n, t, s) {
1248
1248
  try {
1249
- return o ? e(...o) : e();
1250
- } catch (s) {
1251
- On(s, n, t);
1249
+ return s ? e(...s) : e();
1250
+ } catch (o) {
1251
+ On(o, n, t);
1252
1252
  }
1253
1253
  }
1254
- function On(e, n, t, o = !0) {
1255
- const s = n ? n.vnode : null, { errorHandler: a, throwUnhandledErrorInProduction: c } = n && n.appContext.config || ze;
1254
+ function On(e, n, t, s = !0) {
1255
+ const o = n ? n.vnode : null, { errorHandler: r, throwUnhandledErrorInProduction: c } = n && n.appContext.config || Ue;
1256
1256
  if (n) {
1257
1257
  let g = n.parent;
1258
- const v = n.proxy, d = process.env.NODE_ENV !== "production" ? jn[t] : `https://vuejs.org/error-reference/#runtime-${t}`;
1258
+ const _ = n.proxy, m = process.env.NODE_ENV !== "production" ? In[t] : `https://vuejs.org/error-reference/#runtime-${t}`;
1259
1259
  for (; g; ) {
1260
- const r = g.ec;
1261
- if (r) {
1262
- for (let i = 0; i < r.length; i++)
1263
- if (r[i](e, v, d) === !1)
1260
+ const a = g.ec;
1261
+ if (a) {
1262
+ for (let u = 0; u < a.length; u++)
1263
+ if (a[u](e, _, m) === !1)
1264
1264
  return;
1265
1265
  }
1266
1266
  g = g.parent;
1267
1267
  }
1268
- if (a) {
1269
- sn(a, null, 10, [
1268
+ if (r) {
1269
+ an(r, null, 10, [
1270
1270
  e,
1271
- v,
1272
- d
1271
+ _,
1272
+ m
1273
1273
  ]);
1274
1274
  return;
1275
1275
  }
1276
1276
  }
1277
- Zt(e, t, s, o, c);
1277
+ Xt(e, t, o, s, c);
1278
1278
  }
1279
- function Zt(e, n, t, o = !0, s = !1) {
1279
+ function Xt(e, n, t, s = !0, o = !1) {
1280
1280
  if (process.env.NODE_ENV !== "production") {
1281
- const a = jn[n];
1282
- if (t && Bt(t), ae(`Unhandled error${a ? ` during execution of ${a}` : ""}`), t && Ut(), o)
1281
+ const r = In[n];
1282
+ if (t && zt(t), ce(`Unhandled error${r ? ` during execution of ${r}` : ""}`), t && Jt(), s)
1283
1283
  throw e;
1284
- } else if (s)
1284
+ } else if (o)
1285
1285
  throw e;
1286
1286
  }
1287
- const x = [];
1288
- let T = -1;
1289
- const q = [];
1290
- let F = null, W = 0;
1291
- const qt = /* @__PURE__ */ Promise.resolve();
1292
- let Ge = null;
1293
- const Xt = 100;
1294
- function Qt(e) {
1295
- let n = T + 1, t = x.length;
1287
+ const P = [];
1288
+ let k = -1;
1289
+ const Q = [];
1290
+ let V = null, q = 0;
1291
+ const Qt = /* @__PURE__ */ Promise.resolve();
1292
+ let We = null;
1293
+ const eo = 100;
1294
+ function no(e) {
1295
+ let n = k + 1, t = P.length;
1296
1296
  for (; n < t; ) {
1297
- const o = n + t >>> 1, s = x[o], a = ie(s);
1298
- a < e || a === e && s.flags & 2 ? n = o + 1 : t = o;
1297
+ const s = n + t >>> 1, o = P[s], r = ue(o);
1298
+ r < e || r === e && o.flags & 2 ? n = s + 1 : t = s;
1299
1299
  }
1300
1300
  return n;
1301
1301
  }
1302
- function eo(e) {
1302
+ function to(e) {
1303
1303
  if (!(e.flags & 1)) {
1304
- const n = ie(e), t = x[x.length - 1];
1304
+ const n = ue(e), t = P[P.length - 1];
1305
1305
  !t || // fast path when the job id is larger than the tail
1306
- !(e.flags & 2) && n >= ie(t) ? x.push(e) : x.splice(Qt(n), 0, e), e.flags |= 1, An();
1306
+ !(e.flags & 2) && n >= ue(t) ? P.push(e) : P.splice(no(n), 0, e), e.flags |= 1, xn();
1307
1307
  }
1308
1308
  }
1309
- function An() {
1310
- Ge || (Ge = qt.then(In));
1309
+ function xn() {
1310
+ We || (We = Qt.then(Tn));
1311
1311
  }
1312
- function no(e) {
1313
- D(e) ? q.push(...e) : F && e.id === -1 ? F.splice(W + 1, 0, e) : e.flags & 1 || (q.push(e), e.flags |= 1), An();
1312
+ function oo(e) {
1313
+ F(e) ? Q.push(...e) : V && e.id === -1 ? V.splice(q + 1, 0, e) : e.flags & 1 || (Q.push(e), e.flags |= 1), xn();
1314
1314
  }
1315
- function to(e) {
1316
- if (q.length) {
1317
- const n = [...new Set(q)].sort(
1318
- (t, o) => ie(t) - ie(o)
1315
+ function so(e) {
1316
+ if (Q.length) {
1317
+ const n = [...new Set(Q)].sort(
1318
+ (t, s) => ue(t) - ue(s)
1319
1319
  );
1320
- if (q.length = 0, F) {
1321
- F.push(...n);
1320
+ if (Q.length = 0, V) {
1321
+ V.push(...n);
1322
1322
  return;
1323
1323
  }
1324
- for (F = n, process.env.NODE_ENV !== "production" && (e = e || /* @__PURE__ */ new Map()), W = 0; W < F.length; W++) {
1325
- const t = F[W];
1326
- process.env.NODE_ENV !== "production" && xn(e, t) || (t.flags & 4 && (t.flags &= -2), t.flags & 8 || t(), t.flags &= -2);
1324
+ for (V = n, process.env.NODE_ENV !== "production" && (e = e || /* @__PURE__ */ new Map()), q = 0; q < V.length; q++) {
1325
+ const t = V[q];
1326
+ process.env.NODE_ENV !== "production" && Pn(e, t) || (t.flags & 4 && (t.flags &= -2), t.flags & 8 || t(), t.flags &= -2);
1327
1327
  }
1328
- F = null, W = 0;
1328
+ V = null, q = 0;
1329
1329
  }
1330
1330
  }
1331
- const ie = (e) => e.id == null ? e.flags & 2 ? -1 : 1 / 0 : e.id;
1332
- function In(e) {
1331
+ const ue = (e) => e.id == null ? e.flags & 2 ? -1 : 1 / 0 : e.id;
1332
+ function Tn(e) {
1333
1333
  process.env.NODE_ENV !== "production" && (e = e || /* @__PURE__ */ new Map());
1334
- const n = process.env.NODE_ENV !== "production" ? (t) => xn(e, t) : Rt;
1334
+ const n = process.env.NODE_ENV !== "production" ? (t) => Pn(e, t) : Ht;
1335
1335
  try {
1336
- for (T = 0; T < x.length; T++) {
1337
- const t = x[T];
1336
+ for (k = 0; k < P.length; k++) {
1337
+ const t = P[k];
1338
1338
  if (t && !(t.flags & 8)) {
1339
1339
  if (process.env.NODE_ENV !== "production" && n(t))
1340
1340
  continue;
1341
- t.flags & 4 && (t.flags &= -2), sn(
1341
+ t.flags & 4 && (t.flags &= -2), an(
1342
1342
  t,
1343
1343
  t.i,
1344
1344
  t.i ? 15 : 14
@@ -1346,69 +1346,69 @@ function In(e) {
1346
1346
  }
1347
1347
  }
1348
1348
  } finally {
1349
- for (; T < x.length; T++) {
1350
- const t = x[T];
1349
+ for (; k < P.length; k++) {
1350
+ const t = P[k];
1351
1351
  t && (t.flags &= -2);
1352
1352
  }
1353
- T = -1, x.length = 0, to(e), Ge = null, (x.length || q.length) && In(e);
1353
+ k = -1, P.length = 0, so(e), We = null, (P.length || Q.length) && Tn(e);
1354
1354
  }
1355
1355
  }
1356
- function xn(e, n) {
1356
+ function Pn(e, n) {
1357
1357
  const t = e.get(n) || 0;
1358
- if (t > Xt) {
1359
- const o = n.i, s = o && kn(o.type);
1358
+ if (t > eo) {
1359
+ const s = n.i, o = s && Ln(s.type);
1360
1360
  return On(
1361
- `Maximum recursive updates exceeded${s ? ` in component <${s}>` : ""}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
1361
+ `Maximum recursive updates exceeded${o ? ` in component <${o}>` : ""}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
1362
1362
  null,
1363
1363
  10
1364
1364
  ), !0;
1365
1365
  }
1366
1366
  return e.set(n, t + 1), !1;
1367
1367
  }
1368
- const De = /* @__PURE__ */ new Map();
1369
- process.env.NODE_ENV !== "production" && (je().__VUE_HMR_RUNTIME__ = {
1370
- createRecord: Pe(oo),
1371
- rerender: Pe(so),
1372
- reload: Pe(ro)
1368
+ const Fe = /* @__PURE__ */ new Map();
1369
+ process.env.NODE_ENV !== "production" && (Ie().__VUE_HMR_RUNTIME__ = {
1370
+ createRecord: De(ro),
1371
+ rerender: De(ao),
1372
+ reload: De(io)
1373
1373
  });
1374
- const ve = /* @__PURE__ */ new Map();
1375
- function oo(e, n) {
1376
- return ve.has(e) ? !1 : (ve.set(e, {
1377
- initialDef: _e(n),
1374
+ const Ce = /* @__PURE__ */ new Map();
1375
+ function ro(e, n) {
1376
+ return Ce.has(e) ? !1 : (Ce.set(e, {
1377
+ initialDef: $e(n),
1378
1378
  instances: /* @__PURE__ */ new Set()
1379
1379
  }), !0);
1380
1380
  }
1381
- function _e(e) {
1382
- return Mn(e) ? e.__vccOpts : e;
1381
+ function $e(e) {
1382
+ return Kn(e) ? e.__vccOpts : e;
1383
1383
  }
1384
- function so(e, n) {
1385
- const t = ve.get(e);
1386
- t && (t.initialDef.render = n, [...t.instances].forEach((o) => {
1387
- n && (o.render = n, _e(o.type).render = n), o.renderCache = [], o.update();
1384
+ function ao(e, n) {
1385
+ const t = Ce.get(e);
1386
+ t && (t.initialDef.render = n, [...t.instances].forEach((s) => {
1387
+ n && (s.render = n, $e(s.type).render = n), s.renderCache = [], s.update();
1388
1388
  }));
1389
1389
  }
1390
- function ro(e, n) {
1391
- const t = ve.get(e);
1390
+ function io(e, n) {
1391
+ const t = Ce.get(e);
1392
1392
  if (!t) return;
1393
- n = _e(n), ln(t.initialDef, n);
1394
- const o = [...t.instances];
1395
- for (let s = 0; s < o.length; s++) {
1396
- const a = o[s], c = _e(a.type);
1397
- let g = De.get(c);
1398
- g || (c !== t.initialDef && ln(c, n), De.set(c, g = /* @__PURE__ */ new Set())), g.add(a), a.appContext.propsCache.delete(a.type), a.appContext.emitsCache.delete(a.type), a.appContext.optionsCache.delete(a.type), a.ceReload ? (g.add(a), a.ceReload(n.styles), g.delete(a)) : a.parent ? eo(() => {
1399
- a.parent.update(), g.delete(a);
1400
- }) : a.appContext.reload ? a.appContext.reload() : typeof window < "u" && window.location.reload(), a.root.ce && a !== a.root && a.root.ce._removeChildStyle(c);
1401
- }
1402
- no(() => {
1403
- De.clear();
1393
+ n = $e(n), dn(t.initialDef, n);
1394
+ const s = [...t.instances];
1395
+ for (let o = 0; o < s.length; o++) {
1396
+ const r = s[o], c = $e(r.type);
1397
+ let g = Fe.get(c);
1398
+ g || (c !== t.initialDef && dn(c, n), Fe.set(c, g = /* @__PURE__ */ new Set())), g.add(r), r.appContext.propsCache.delete(r.type), r.appContext.emitsCache.delete(r.type), r.appContext.optionsCache.delete(r.type), r.ceReload ? (g.add(r), r.ceReload(n.styles), g.delete(r)) : r.parent ? to(() => {
1399
+ r.parent.update(), g.delete(r);
1400
+ }) : r.appContext.reload ? r.appContext.reload() : typeof window < "u" && window.location.reload(), r.root.ce && r !== r.root && r.root.ce._removeChildStyle(c);
1401
+ }
1402
+ oo(() => {
1403
+ Fe.clear();
1404
1404
  });
1405
1405
  }
1406
- function ln(e, n) {
1407
- Se(e, n);
1406
+ function dn(e, n) {
1407
+ Ae(e, n);
1408
1408
  for (const t in e)
1409
1409
  t !== "__file" && !(t in n) && delete e[t];
1410
1410
  }
1411
- function Pe(e) {
1411
+ function De(e) {
1412
1412
  return (n, t) => {
1413
1413
  try {
1414
1414
  return e(n, t);
@@ -1416,35 +1416,35 @@ function Pe(e) {
1416
1416
  }
1417
1417
  };
1418
1418
  }
1419
- let Ce = null, ao = null;
1420
- const io = (e) => e.__isTeleport;
1421
- function Dn(e, n) {
1422
- e.shapeFlag & 6 && e.component ? (e.transition = n, Dn(e.component.subTree, n)) : e.shapeFlag & 128 ? (e.ssContent.transition = n.clone(e.ssContent), e.ssFallback.transition = n.clone(e.ssFallback)) : e.transition = n;
1419
+ let be = null, co = null;
1420
+ const uo = (e) => e.__isTeleport;
1421
+ function Fn(e, n) {
1422
+ e.shapeFlag & 6 && e.component ? (e.transition = n, Fn(e.component.subTree, n)) : e.shapeFlag & 128 ? (e.ssContent.transition = n.clone(e.ssContent), e.ssFallback.transition = n.clone(e.ssFallback)) : e.transition = n;
1423
1423
  }
1424
- je().requestIdleCallback;
1425
- je().cancelIdleCallback;
1426
- const co = Symbol.for("v-ndc");
1424
+ Ie().requestIdleCallback;
1425
+ Ie().cancelIdleCallback;
1426
+ const lo = Symbol.for("v-ndc");
1427
1427
  process.env.NODE_ENV;
1428
- const uo = {}, Pn = (e) => Object.getPrototypeOf(e) === uo, lo = (e) => e.__isSuspense, Tn = Symbol.for("v-fgt"), po = Symbol.for("v-txt"), fo = Symbol.for("v-cmt");
1429
- function mo(e) {
1428
+ const po = {}, Dn = (e) => Object.getPrototypeOf(e) === po, mo = (e) => e.__isSuspense, kn = Symbol.for("v-fgt"), fo = Symbol.for("v-txt"), ho = Symbol.for("v-cmt");
1429
+ function vo(e) {
1430
1430
  return e ? e.__v_isVNode === !0 : !1;
1431
1431
  }
1432
- const ho = (...e) => Vn(
1432
+ const go = (...e) => Rn(
1433
1433
  ...e
1434
- ), Fn = ({ key: e }) => e ?? null, me = ({
1434
+ ), Vn = ({ key: e }) => e ?? null, ve = ({
1435
1435
  ref: e,
1436
1436
  ref_key: n,
1437
1437
  ref_for: t
1438
- }) => (typeof e == "number" && (e = "" + e), e != null ? H(e) || on(e) || B(e) ? { i: Ce, r: e, k: n, f: !!t } : e : null);
1439
- function go(e, n = null, t = null, o = 0, s = null, a = e === Tn ? 0 : 1, c = !1, g = !1) {
1440
- const v = {
1438
+ }) => (typeof e == "number" && (e = "" + e), e != null ? M(e) || rn(e) || J(e) ? { i: be, r: e, k: n, f: !!t } : e : null);
1439
+ function _o(e, n = null, t = null, s = 0, o = null, r = e === kn ? 0 : 1, c = !1, g = !1) {
1440
+ const _ = {
1441
1441
  __v_isVNode: !0,
1442
1442
  __v_skip: !0,
1443
1443
  type: e,
1444
1444
  props: n,
1445
- key: n && Fn(n),
1446
- ref: n && me(n),
1447
- scopeId: ao,
1445
+ key: n && Vn(n),
1446
+ ref: n && ve(n),
1447
+ scopeId: co,
1448
1448
  slotScopeIds: null,
1449
1449
  children: t,
1450
1450
  component: null,
@@ -1459,67 +1459,67 @@ function go(e, n = null, t = null, o = 0, s = null, a = e === Tn ? 0 : 1, c = !1
1459
1459
  targetStart: null,
1460
1460
  targetAnchor: null,
1461
1461
  staticCount: 0,
1462
- shapeFlag: a,
1463
- patchFlag: o,
1464
- dynamicProps: s,
1462
+ shapeFlag: r,
1463
+ patchFlag: s,
1464
+ dynamicProps: o,
1465
1465
  dynamicChildren: null,
1466
1466
  appContext: null,
1467
- ctx: Ce
1467
+ ctx: be
1468
1468
  };
1469
- return g ? (rn(v, t), a & 128 && e.normalize(v)) : t && (v.shapeFlag |= H(t) ? 8 : 16), process.env.NODE_ENV !== "production" && v.key !== v.key && ae("VNode created with invalid key (NaN). VNode type:", v.type), v;
1469
+ return g ? (cn(_, t), r & 128 && e.normalize(_)) : t && (_.shapeFlag |= M(t) ? 8 : 16), process.env.NODE_ENV !== "production" && _.key !== _.key && ce("VNode created with invalid key (NaN). VNode type:", _.type), _;
1470
1470
  }
1471
- const vo = process.env.NODE_ENV !== "production" ? ho : Vn;
1472
- function Vn(e, n = null, t = null, o = 0, s = null, a = !1) {
1473
- if ((!e || e === co) && (process.env.NODE_ENV !== "production" && !e && ae(`Invalid vnode type when creating vnode: ${e}.`), e = fo), mo(e)) {
1474
- const g = $e(
1471
+ const Co = process.env.NODE_ENV !== "production" ? go : Rn;
1472
+ function Rn(e, n = null, t = null, s = 0, o = null, r = !1) {
1473
+ if ((!e || e === lo) && (process.env.NODE_ENV !== "production" && !e && ce(`Invalid vnode type when creating vnode: ${e}.`), e = ho), vo(e)) {
1474
+ const g = we(
1475
1475
  e,
1476
1476
  n,
1477
1477
  !0
1478
1478
  /* mergeRef: true */
1479
1479
  );
1480
- return t && rn(g, t), g.patchFlag = -2, g;
1480
+ return t && cn(g, t), g.patchFlag = -2, g;
1481
1481
  }
1482
- if (Mn(e) && (e = e.__vccOpts), n) {
1483
- n = _o(n);
1484
- let { class: g, style: v } = n;
1485
- g && !H(g) && (n.class = tn(g)), L(v) && (Ue(v) && !D(v) && (v = Se({}, v)), n.style = nn(v));
1482
+ if (Kn(e) && (e = e.__vccOpts), n) {
1483
+ n = $o(n);
1484
+ let { class: g, style: _ } = n;
1485
+ g && !M(g) && (n.class = sn(g)), G(_) && (Je(_) && !F(_) && (_ = Ae({}, _)), n.style = on(_));
1486
1486
  }
1487
- const c = H(e) ? 1 : lo(e) ? 128 : io(e) ? 64 : L(e) ? 4 : B(e) ? 2 : 0;
1488
- return process.env.NODE_ENV !== "production" && c & 4 && Ue(e) && (e = K(e), ae(
1487
+ const c = M(e) ? 1 : mo(e) ? 128 : uo(e) ? 64 : G(e) ? 4 : J(e) ? 2 : 0;
1488
+ return process.env.NODE_ENV !== "production" && c & 4 && Je(e) && (e = U(e), ce(
1489
1489
  "Vue received a Component that was made a reactive object. This can lead to unnecessary performance overhead and should be avoided by marking the component with `markRaw` or using `shallowRef` instead of `ref`.",
1490
1490
  `
1491
1491
  Component that was made reactive: `,
1492
1492
  e
1493
- )), go(
1493
+ )), _o(
1494
1494
  e,
1495
1495
  n,
1496
1496
  t,
1497
- o,
1498
1497
  s,
1498
+ o,
1499
1499
  c,
1500
- a,
1500
+ r,
1501
1501
  !0
1502
1502
  );
1503
1503
  }
1504
- function _o(e) {
1505
- return e ? Ue(e) || Pn(e) ? Se({}, e) : e : null;
1504
+ function $o(e) {
1505
+ return e ? Je(e) || Dn(e) ? Ae({}, e) : e : null;
1506
1506
  }
1507
- function $e(e, n, t = !1, o = !1) {
1508
- const { props: s, ref: a, patchFlag: c, children: g, transition: v } = e, d = n ? $o(s || {}, n) : s, r = {
1507
+ function we(e, n, t = !1, s = !1) {
1508
+ const { props: o, ref: r, patchFlag: c, children: g, transition: _ } = e, m = n ? wo(o || {}, n) : o, a = {
1509
1509
  __v_isVNode: !0,
1510
1510
  __v_skip: !0,
1511
1511
  type: e.type,
1512
- props: d,
1513
- key: d && Fn(d),
1512
+ props: m,
1513
+ key: m && Vn(m),
1514
1514
  ref: n && n.ref ? (
1515
1515
  // #2078 in the case of <component :is="vnode" ref="extra"/>
1516
1516
  // if the vnode itself already has a ref, cloneVNode will need to merge
1517
1517
  // the refs so the single vnode can be set on multiple refs
1518
- t && a ? D(a) ? a.concat(me(n)) : [a, me(n)] : me(n)
1519
- ) : a,
1518
+ t && r ? F(r) ? r.concat(ve(n)) : [r, ve(n)] : ve(n)
1519
+ ) : r,
1520
1520
  scopeId: e.scopeId,
1521
1521
  slotScopeIds: e.slotScopeIds,
1522
- children: process.env.NODE_ENV !== "production" && c === -1 && D(g) ? g.map(Rn) : g,
1522
+ children: process.env.NODE_ENV !== "production" && c === -1 && F(g) ? g.map(Hn) : g,
1523
1523
  target: e.target,
1524
1524
  targetStart: e.targetStart,
1525
1525
  targetAnchor: e.targetAnchor,
@@ -1529,75 +1529,75 @@ function $e(e, n, t = !1, o = !1) {
1529
1529
  // existing patch flag to be reliable and need to add the FULL_PROPS flag.
1530
1530
  // note: preserve flag for fragments since they use the flag for children
1531
1531
  // fast paths only.
1532
- patchFlag: n && e.type !== Tn ? c === -1 ? 16 : c | 16 : c,
1532
+ patchFlag: n && e.type !== kn ? c === -1 ? 16 : c | 16 : c,
1533
1533
  dynamicProps: e.dynamicProps,
1534
1534
  dynamicChildren: e.dynamicChildren,
1535
1535
  appContext: e.appContext,
1536
1536
  dirs: e.dirs,
1537
- transition: v,
1537
+ transition: _,
1538
1538
  // These should technically only be non-null on mounted VNodes. However,
1539
1539
  // they *should* be copied for kept-alive vnodes. So we just always copy
1540
1540
  // them since them being non-null during a mount doesn't affect the logic as
1541
1541
  // they will simply be overwritten.
1542
1542
  component: e.component,
1543
1543
  suspense: e.suspense,
1544
- ssContent: e.ssContent && $e(e.ssContent),
1545
- ssFallback: e.ssFallback && $e(e.ssFallback),
1544
+ ssContent: e.ssContent && we(e.ssContent),
1545
+ ssFallback: e.ssFallback && we(e.ssFallback),
1546
1546
  el: e.el,
1547
1547
  anchor: e.anchor,
1548
1548
  ctx: e.ctx,
1549
1549
  ce: e.ce
1550
1550
  };
1551
- return v && o && Dn(
1552
- r,
1553
- v.clone(r)
1554
- ), r;
1551
+ return _ && s && Fn(
1552
+ a,
1553
+ _.clone(a)
1554
+ ), a;
1555
1555
  }
1556
- function Rn(e) {
1557
- const n = $e(e);
1558
- return D(e.children) && (n.children = e.children.map(Rn)), n;
1556
+ function Hn(e) {
1557
+ const n = we(e);
1558
+ return F(e.children) && (n.children = e.children.map(Hn)), n;
1559
1559
  }
1560
- function Co(e = " ", n = 0) {
1561
- return vo(po, null, e, n);
1560
+ function bo(e = " ", n = 0) {
1561
+ return Co(fo, null, e, n);
1562
1562
  }
1563
- function rn(e, n) {
1563
+ function cn(e, n) {
1564
1564
  let t = 0;
1565
- const { shapeFlag: o } = e;
1565
+ const { shapeFlag: s } = e;
1566
1566
  if (n == null)
1567
1567
  n = null;
1568
- else if (D(n))
1568
+ else if (F(n))
1569
1569
  t = 16;
1570
1570
  else if (typeof n == "object")
1571
- if (o & 65) {
1572
- const s = n.default;
1573
- s && (s._c && (s._d = !1), rn(e, s()), s._c && (s._d = !0));
1571
+ if (s & 65) {
1572
+ const o = n.default;
1573
+ o && (o._c && (o._d = !1), cn(e, o()), o._c && (o._d = !0));
1574
1574
  return;
1575
1575
  } else
1576
- t = 32, !n._ && !Pn(n) && (n._ctx = Ce);
1577
- else B(n) ? (n = { default: n, _ctx: Ce }, t = 32) : (n = String(n), o & 64 ? (t = 16, n = [Co(n)]) : t = 8);
1576
+ t = 32, !n._ && !Dn(n) && (n._ctx = be);
1577
+ else J(n) ? (n = { default: n, _ctx: be }, t = 32) : (n = String(n), s & 64 ? (t = 16, n = [bo(n)]) : t = 8);
1578
1578
  e.children = n, e.shapeFlag |= t;
1579
1579
  }
1580
- function $o(...e) {
1580
+ function wo(...e) {
1581
1581
  const n = {};
1582
1582
  for (let t = 0; t < e.length; t++) {
1583
- const o = e[t];
1584
- for (const s in o)
1585
- if (s === "class")
1586
- n.class !== o.class && (n.class = tn([n.class, o.class]));
1587
- else if (s === "style")
1588
- n.style = nn([n.style, o.style]);
1589
- else if (kt(s)) {
1590
- const a = n[s], c = o[s];
1591
- c && a !== c && !(D(a) && a.includes(c)) && (n[s] = a ? [].concat(a, c) : c);
1592
- } else s !== "" && (n[s] = o[s]);
1583
+ const s = e[t];
1584
+ for (const o in s)
1585
+ if (o === "class")
1586
+ n.class !== s.class && (n.class = sn([n.class, s.class]));
1587
+ else if (o === "style")
1588
+ n.style = on([n.style, s.style]);
1589
+ else if (Lt(o)) {
1590
+ const r = n[o], c = s[o];
1591
+ c && r !== c && !(F(r) && r.includes(c)) && (n[o] = r ? [].concat(r, c) : c);
1592
+ } else o !== "" && (n[o] = s[o]);
1593
1593
  }
1594
1594
  return n;
1595
1595
  }
1596
1596
  {
1597
- const e = je(), n = (t, o) => {
1598
- let s;
1599
- return (s = e[t]) || (s = e[t] = []), s.push(o), (a) => {
1600
- s.length > 1 ? s.forEach((c) => c(a)) : s[0](a);
1597
+ const e = Ie(), n = (t, s) => {
1598
+ let o;
1599
+ return (o = e[t]) || (o = e[t] = []), o.push(s), (r) => {
1600
+ o.length > 1 ? o.forEach((c) => c(r)) : o[0](r);
1601
1601
  };
1602
1602
  };
1603
1603
  n(
@@ -1609,94 +1609,94 @@ function $o(...e) {
1609
1609
  );
1610
1610
  }
1611
1611
  process.env.NODE_ENV;
1612
- const bo = /(?:^|[-_])(\w)/g, wo = (e) => e.replace(bo, (n) => n.toUpperCase()).replace(/[-_]/g, "");
1613
- function kn(e, n = !0) {
1614
- return B(e) ? e.displayName || e.name : e.name || n && e.__name;
1615
- }
1616
- function Hn(e, n, t = !1) {
1617
- let o = kn(n);
1618
- if (!o && n.__file) {
1619
- const s = n.__file.match(/([^/\\]+)\.\w+$/);
1620
- s && (o = s[1]);
1621
- }
1622
- if (!o && e && e.parent) {
1623
- const s = (a) => {
1624
- for (const c in a)
1625
- if (a[c] === n)
1612
+ const No = /(?:^|[-_])(\w)/g, yo = (e) => e.replace(No, (n) => n.toUpperCase()).replace(/[-_]/g, "");
1613
+ function Ln(e, n = !0) {
1614
+ return J(e) ? e.displayName || e.name : e.name || n && e.__name;
1615
+ }
1616
+ function Mn(e, n, t = !1) {
1617
+ let s = Ln(n);
1618
+ if (!s && n.__file) {
1619
+ const o = n.__file.match(/([^/\\]+)\.\w+$/);
1620
+ o && (s = o[1]);
1621
+ }
1622
+ if (!s && e && e.parent) {
1623
+ const o = (r) => {
1624
+ for (const c in r)
1625
+ if (r[c] === n)
1626
1626
  return c;
1627
1627
  };
1628
- o = s(
1628
+ s = o(
1629
1629
  e.components || e.parent.type.components
1630
- ) || s(e.appContext.components);
1630
+ ) || o(e.appContext.components);
1631
1631
  }
1632
- return o ? wo(o) : t ? "App" : "Anonymous";
1632
+ return s ? yo(s) : t ? "App" : "Anonymous";
1633
1633
  }
1634
- function Mn(e) {
1635
- return B(e) && "__vccOpts" in e;
1634
+ function Kn(e) {
1635
+ return J(e) && "__vccOpts" in e;
1636
1636
  }
1637
- function No() {
1637
+ function Eo() {
1638
1638
  if (process.env.NODE_ENV === "production" || typeof window > "u")
1639
1639
  return;
1640
- const e = { style: "color:#3ba776" }, n = { style: "color:#1677ff" }, t = { style: "color:#f5222d" }, o = { style: "color:#eb2f96" }, s = {
1640
+ const e = { style: "color:#3ba776" }, n = { style: "color:#1677ff" }, t = { style: "color:#f5222d" }, s = { style: "color:#eb2f96" }, o = {
1641
1641
  __vue_custom_formatter: !0,
1642
- header(i) {
1643
- return L(i) ? i.__isVue ? ["div", e, "VueInstance"] : on(i) ? [
1642
+ header(u) {
1643
+ return G(u) ? u.__isVue ? ["div", e, "VueInstance"] : rn(u) ? [
1644
1644
  "div",
1645
1645
  {},
1646
- ["span", e, r(i)],
1646
+ ["span", e, a(u)],
1647
1647
  "<",
1648
1648
  // avoid debugger accessing value affecting behavior
1649
- g("_value" in i ? i._value : i),
1649
+ g("_value" in u ? u._value : u),
1650
1650
  ">"
1651
- ] : En(i) ? [
1651
+ ] : Sn(u) ? [
1652
1652
  "div",
1653
1653
  {},
1654
- ["span", e, Ie(i) ? "ShallowReactive" : "Reactive"],
1654
+ ["span", e, Te(u) ? "ShallowReactive" : "Reactive"],
1655
1655
  "<",
1656
- g(i),
1657
- `>${Be(i) ? " (readonly)" : ""}`
1658
- ] : Be(i) ? [
1656
+ g(u),
1657
+ `>${ze(u) ? " (readonly)" : ""}`
1658
+ ] : ze(u) ? [
1659
1659
  "div",
1660
1660
  {},
1661
- ["span", e, Ie(i) ? "ShallowReadonly" : "Readonly"],
1661
+ ["span", e, Te(u) ? "ShallowReadonly" : "Readonly"],
1662
1662
  "<",
1663
- g(i),
1663
+ g(u),
1664
1664
  ">"
1665
1665
  ] : null : null;
1666
1666
  },
1667
- hasBody(i) {
1668
- return i && i.__isVue;
1667
+ hasBody(u) {
1668
+ return u && u.__isVue;
1669
1669
  },
1670
- body(i) {
1671
- if (i && i.__isVue)
1670
+ body(u) {
1671
+ if (u && u.__isVue)
1672
1672
  return [
1673
1673
  "div",
1674
1674
  {},
1675
- ...a(i.$)
1675
+ ...r(u.$)
1676
1676
  ];
1677
1677
  }
1678
1678
  };
1679
- function a(i) {
1680
- const l = [];
1681
- i.type.props && i.props && l.push(c("props", K(i.props))), i.setupState !== ze && l.push(c("setup", i.setupState)), i.data !== ze && l.push(c("data", K(i.data)));
1682
- const m = v(i, "computed");
1683
- m && l.push(c("computed", m));
1684
- const C = v(i, "inject");
1685
- return C && l.push(c("injected", C)), l.push([
1679
+ function r(u) {
1680
+ const i = [];
1681
+ u.type.props && u.props && i.push(c("props", U(u.props))), u.setupState !== Ue && i.push(c("setup", u.setupState)), u.data !== Ue && i.push(c("data", U(u.data)));
1682
+ const p = _(u, "computed");
1683
+ p && i.push(c("computed", p));
1684
+ const b = _(u, "inject");
1685
+ return b && i.push(c("injected", b)), i.push([
1686
1686
  "div",
1687
1687
  {},
1688
1688
  [
1689
1689
  "span",
1690
1690
  {
1691
- style: o.style + ";opacity:0.66"
1691
+ style: s.style + ";opacity:0.66"
1692
1692
  },
1693
1693
  "$ (internal): "
1694
1694
  ],
1695
- ["object", { object: i }]
1696
- ]), l;
1695
+ ["object", { object: u }]
1696
+ ]), i;
1697
1697
  }
1698
- function c(i, l) {
1699
- return l = Se({}, l), Object.keys(l).length ? [
1698
+ function c(u, i) {
1699
+ return i = Ae({}, i), Object.keys(i).length ? [
1700
1700
  "div",
1701
1701
  { style: "line-height:1.25em;margin-bottom:0.6em" },
1702
1702
  [
@@ -1704,43 +1704,43 @@ function No() {
1704
1704
  {
1705
1705
  style: "color:#476582"
1706
1706
  },
1707
- i
1707
+ u
1708
1708
  ],
1709
1709
  [
1710
1710
  "div",
1711
1711
  {
1712
1712
  style: "padding-left:1.25em"
1713
1713
  },
1714
- ...Object.keys(l).map((m) => [
1714
+ ...Object.keys(i).map((p) => [
1715
1715
  "div",
1716
1716
  {},
1717
- ["span", o, m + ": "],
1718
- g(l[m], !1)
1717
+ ["span", s, p + ": "],
1718
+ g(i[p], !1)
1719
1719
  ])
1720
1720
  ]
1721
1721
  ] : ["span", {}];
1722
1722
  }
1723
- function g(i, l = !0) {
1724
- return typeof i == "number" ? ["span", n, i] : typeof i == "string" ? ["span", t, JSON.stringify(i)] : typeof i == "boolean" ? ["span", o, i] : L(i) ? ["object", { object: l ? K(i) : i }] : ["span", t, String(i)];
1723
+ function g(u, i = !0) {
1724
+ return typeof u == "number" ? ["span", n, u] : typeof u == "string" ? ["span", t, JSON.stringify(u)] : typeof u == "boolean" ? ["span", s, u] : G(u) ? ["object", { object: i ? U(u) : u }] : ["span", t, String(u)];
1725
1725
  }
1726
- function v(i, l) {
1727
- const m = i.type;
1728
- if (B(m))
1726
+ function _(u, i) {
1727
+ const p = u.type;
1728
+ if (J(p))
1729
1729
  return;
1730
- const C = {};
1731
- for (const p in i.ctx)
1732
- d(m, p, l) && (C[p] = i.ctx[p]);
1733
- return C;
1734
- }
1735
- function d(i, l, m) {
1736
- const C = i[m];
1737
- if (D(C) && C.includes(l) || L(C) && l in C || i.extends && d(i.extends, l, m) || i.mixins && i.mixins.some((p) => d(p, l, m)))
1730
+ const b = {};
1731
+ for (const C in u.ctx)
1732
+ m(p, C, i) && (b[C] = u.ctx[C]);
1733
+ return b;
1734
+ }
1735
+ function m(u, i, p) {
1736
+ const b = u[p];
1737
+ if (F(b) && b.includes(i) || G(b) && i in b || u.extends && m(u.extends, i, p) || u.mixins && u.mixins.some((C) => m(C, i, p)))
1738
1738
  return !0;
1739
1739
  }
1740
- function r(i) {
1741
- return Ie(i) ? "ShallowRef" : i.effect ? "ComputedRef" : "Ref";
1740
+ function a(u) {
1741
+ return Te(u) ? "ShallowRef" : u.effect ? "ComputedRef" : "Ref";
1742
1742
  }
1743
- window.devtoolsFormatters ? window.devtoolsFormatters.push(s) : window.devtoolsFormatters = [s];
1743
+ window.devtoolsFormatters ? window.devtoolsFormatters.push(o) : window.devtoolsFormatters = [o];
1744
1744
  }
1745
1745
  process.env.NODE_ENV;
1746
1746
  process.env.NODE_ENV;
@@ -1750,15 +1750,15 @@ process.env.NODE_ENV;
1750
1750
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
1751
1751
  * @license MIT
1752
1752
  **/
1753
- function yo() {
1754
- No();
1753
+ function jo() {
1754
+ Eo();
1755
1755
  }
1756
- process.env.NODE_ENV !== "production" && yo();
1757
- function Eo(e) {
1758
- return Pt(e) || Tt(e) || Dt(e) || Ft(e) || Vt(e);
1756
+ process.env.NODE_ENV !== "production" && jo();
1757
+ function So(e) {
1758
+ return Dt(e) || kt(e) || Ft(e) || Vt(e) || Rt(e);
1759
1759
  }
1760
- var Ln = /* @__PURE__ */ ((e) => (e.Java = "java", e.Kotlin = "kotlin", e.CSharp = "csharp", e.Go = "go", e))(Ln || {});
1761
- class j {
1760
+ var Bn = /* @__PURE__ */ ((e) => (e.Java = "java", e.Kotlin = "kotlin", e.CSharp = "csharp", e.Go = "go", e))(Bn || {});
1761
+ class I {
1762
1762
  imports = /* @__PURE__ */ new Set();
1763
1763
  parentDir;
1764
1764
  name;
@@ -1799,869 +1799,967 @@ class j {
1799
1799
  this.parentDir = n;
1800
1800
  }
1801
1801
  }
1802
- var be;
1802
+ var Ne;
1803
1803
  ((e) => {
1804
1804
  ((n) => {
1805
- n.Lombok = "Lombok", n.LombokBuilder = "LombokBuilder", n.RecordVakueObject = "RecordVakueObject", n.CommandHandler = "CommandHandler", n.Jpa = "Jpa", n.Timezone = "Timezone", n.SpringFramework = "SpringFramework";
1805
+ n.Lombok = "Lombok", n.LombokBuilder = "LombokBuilder", n.RecordValueObject = "RecordValueObject", n.CommandHandler = "CommandHandler", n.Jpa = "Jpa", n.Timezone = "Timezone", n.SpringFramework = "SpringFramework";
1806
1806
  })(e.JavaGeneratorAddition || (e.JavaGeneratorAddition = {}));
1807
- })(be || (be = {}));
1808
- var we;
1807
+ })(Ne || (Ne = {}));
1808
+ var ye;
1809
1809
  ((e) => {
1810
1810
  ((n) => {
1811
1811
  n.ValueClass = "ValueClass", n.CommandHandler = "CommandHandler", n.Timezone = "Timezone";
1812
1812
  })(e.KotlinGeneratorAddition || (e.KotlinGeneratorAddition = {}));
1813
- })(we || (we = {}));
1814
- var Ne;
1813
+ })(ye || (ye = {}));
1814
+ var Ee;
1815
1815
  ((e) => {
1816
1816
  ((n) => {
1817
1817
  n.Timezone = "Timezone", n.RecordStruct = "RecordStruct", n.PrimaryConstructor = "PrimaryConstructor", n.CommandHandlerInterface = "CommandHandlerInterface", n.AggInterface = "AggInterface";
1818
1818
  })(e.CSharpGeneratorAddition || (e.CSharpGeneratorAddition = {}));
1819
- })(Ne || (Ne = {}));
1820
- var We;
1819
+ })(Ee || (Ee = {}));
1820
+ var qe;
1821
1821
  ((e) => {
1822
1822
  ((n) => {
1823
1823
  n.SinglePackageEachDesigner = "SinglePackageEachDesigner";
1824
1824
  })(e.GoGeneratorAddition || (e.GoGeneratorAddition = {}));
1825
- })(We || (We = {}));
1826
- const jo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1825
+ })(qe || (qe = {}));
1826
+ const Io = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1827
1827
  __proto__: null,
1828
- CodeFile: j,
1829
- Language: Ln,
1828
+ CodeFile: I,
1829
+ Language: Bn,
1830
1830
  get csharp() {
1831
- return Ne;
1831
+ return Ee;
1832
1832
  },
1833
1833
  get go() {
1834
- return We;
1834
+ return qe;
1835
1835
  },
1836
- isStruct: Eo,
1836
+ isStruct: So,
1837
1837
  get java() {
1838
- return be;
1838
+ return Ne;
1839
1839
  },
1840
1840
  get kotlin() {
1841
- return we;
1841
+ return ye;
1842
1842
  }
1843
1843
  }, Symbol.toStringTag, { value: "Module" }));
1844
- var N;
1844
+ var y;
1845
1845
  ((e) => {
1846
- function n(d) {
1847
- return d.trim().split(d.includes("_") ? /_|\s/ : /(?=[A-Z])/g).map((r) => r.charAt(0).toUpperCase() + r.toLowerCase().slice(1)).join("");
1846
+ function n(m) {
1847
+ return m.trim().split(m.includes("_") || m.includes("-") || m.includes(" ") ? /_|\s|-/ : /(?=[A-Z])/g).map((a) => a.charAt(0).toUpperCase() + a.toLowerCase().slice(1)).join("");
1848
1848
  }
1849
1849
  e.stringToUpperCamel = n;
1850
- function t(d) {
1851
- let r = !0;
1852
- return d.trim().split(d.includes("_") ? /_|\s/ : /(?=[A-Z])/g).map((i) => r ? (r = !1, i.toLowerCase()) : i.charAt(0).toUpperCase() + i.toLowerCase().slice(1)).join("");
1850
+ function t(m) {
1851
+ let a = !0;
1852
+ return m.trim().split(m.includes("_") || m.includes("-") || m.includes(" ") ? /_|\s|-/ : /(?=[A-Z])/g).map((u) => a ? (a = !1, u.toLowerCase()) : u.charAt(0).toUpperCase() + u.toLowerCase().slice(1)).join("");
1853
1853
  }
1854
1854
  e.stringToLowerCamel = t;
1855
- function o(d) {
1856
- return d.includes("_") ? d.toLowerCase() : a(d);
1855
+ function s(m) {
1856
+ return m = m.trim(), m.includes("_") ? m.toLowerCase() : m.includes(" ") || m.includes("-") ? m.split(/\s|-/).join("_").toLowerCase() : r(m);
1857
1857
  }
1858
- e.stringToLowerSnake = o;
1859
- function s(d) {
1860
- return d.trim().split(/(?=[A-Z])/g).join("_").toUpperCase();
1858
+ e.stringToLowerSnake = s;
1859
+ function o(m) {
1860
+ return m.trim().split(/(?=[A-Z])/g).join("_").toUpperCase();
1861
1861
  }
1862
- e.camelToUpperSnake = s;
1863
- function a(d) {
1864
- return d.trim().split(/(?=[A-Z])/g).join("_").toLowerCase();
1862
+ e.camelToUpperSnake = o;
1863
+ function r(m) {
1864
+ return m.trim().split(/(?=[A-Z])/g).join("_").toLowerCase();
1865
1865
  }
1866
- e.camelToLowerSnake = a;
1867
- function c(d) {
1868
- return d.trim().split("_").map((r) => r.charAt(0).toUpperCase() + r.slice(1)).join("");
1866
+ e.camelToLowerSnake = r;
1867
+ function c(m) {
1868
+ return m.trim().split("_").map((a) => a.charAt(0).toUpperCase() + a.slice(1)).join("");
1869
1869
  }
1870
1870
  e.snakeToUpperCamel = c;
1871
- function g(d) {
1872
- return d.trim().charAt(0).toLowerCase() + d.slice(1);
1871
+ function g(m) {
1872
+ return m.trim().charAt(0).toLowerCase() + m.slice(1);
1873
1873
  }
1874
1874
  e.lowerFirst = g;
1875
- function v(d) {
1876
- return d.trim().charAt(0).toUpperCase() + d.slice(1);
1875
+ function _(m) {
1876
+ return m.trim().charAt(0).toUpperCase() + m.slice(1);
1877
1877
  }
1878
- e.upperFirst = v;
1879
- })(N || (N = {}));
1880
- const O = be.JavaGeneratorAddition, Oo = ue.createHotSwapPlugin(() => {
1881
- const e = "value";
1882
- function n(t) {
1883
- return N.stringToUpperCamel(t._attributes.name);
1878
+ e.upperFirst = _;
1879
+ })(y || (y = {}));
1880
+ const j = Ne.JavaGeneratorAddition, Oo = pe.createHotSwapPlugin(() => {
1881
+ const e = "value", n = "command", t = "event";
1882
+ function s(o) {
1883
+ return y.stringToUpperCamel(o._attributes.name);
1884
1884
  }
1885
1885
  return {
1886
- unmount({ api: t }) {
1887
- t.commands.clearCaches(), t.commands._setCommandCodeProvider(() => []), t.commands._setFacadeCommandCodeProvider(() => []), t.commands._setAggCodeProvider(() => []), t.commands._setEventCodeProvider(() => []), t.commands._setReadModelCodeProvider(() => []), t.commands._setCodeFileProvider(() => []), t.commands.setContext({});
1886
+ unmount({ api: o }) {
1887
+ o.commands.clearCaches(), o.commands._setCommandCodeProvider(() => []), o.commands._setFacadeCommandCodeProvider(() => []), o.commands._setAggCodeProvider(() => []), o.commands._setEventCodeProvider(() => []), o.commands._setReadModelCodeProvider(() => []), o.commands._setCodeFileProvider(() => []), o.commands.setContext({});
1888
1888
  },
1889
- mount({ api: t }) {
1890
- const o = t.states.context, s = t.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((r) => N.stringToLowerCamel(r));
1891
- function a(r) {
1892
- return !s.includes(N.stringToLowerCamel(r._attributes.name));
1889
+ mount({ api: o }) {
1890
+ const r = o.states.context, c = o.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((i) => y.stringToLowerCamel(i));
1891
+ function g(i) {
1892
+ return !c.includes(y.stringToLowerCamel(i._attributes.name));
1893
1893
  }
1894
- function c(r, i) {
1895
- return a(i) ? N.stringToUpperCamel(i._attributes.name) : v(r, i);
1894
+ function _(i, p) {
1895
+ return g(p) ? y.stringToUpperCamel(p._attributes.name) : a(i, p);
1896
1896
  }
1897
- function g(r, i) {
1898
- for (const l of i) {
1899
- if (!a(l)) {
1900
- v(r, l);
1897
+ function m(i, p) {
1898
+ for (const b of p) {
1899
+ if (!g(b)) {
1900
+ a(i, b);
1901
1901
  continue;
1902
1902
  }
1903
- r.add(
1904
- `${o.value.namespace}.${o.value.moduleName}.${e}.${n(l)}`
1903
+ i.add(
1904
+ `${r.value.namespace}.${r.value.moduleName}.${e}.${s(b)}`
1905
1905
  );
1906
1906
  }
1907
1907
  }
1908
- function v(r, i) {
1909
- const l = o.value.additions, m = N.stringToLowerSnake(i._attributes.name).replace(/_/, " ");
1910
- return /\b(time|timestamp|date|deadline|expire)\b/.test(m) ? l.has(O.Timezone) ? (r.add("java.time.OffsetDateTime"), "OffsetDateTime") : (r.add("java.time.LocalDateTime"), "LocalDateTime") : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(m) ? "Integer" : /\b(price)$/.test(m) ? (r.add("java.math.BigDecimal"), "BigDecimal") : /^(if|is)\b/.test(m) ? "Boolean" : Ee(i) && (i._attributes.type === "Id" || i._attributes.type === "Version") ? "Long" : "String";
1908
+ function a(i, p) {
1909
+ const b = r.value.additions, C = y.stringToLowerSnake(p._attributes.name).replace(/_/, " ");
1910
+ return /\b(time|timestamp|date|deadline|expire)\b/.test(C) ? b.has(j.Timezone) ? (i.add("java.time.OffsetDateTime"), "OffsetDateTime") : (i.add("java.time.LocalDateTime"), "LocalDateTime") : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(C) ? "Integer" : /\b(price)$/.test(C) ? (i.add("java.math.BigDecimal"), "BigDecimal") : /^(if|is)\b/.test(C) ? "Boolean" : Se(p) && (p._attributes.type === "Id" || p._attributes.type === "Version" || /\b(id|identifier|ver|version)$/.test(C)) ? "Long" : "String";
1911
1911
  }
1912
- t.commands._setInfoCodeProvider(
1913
- (r) => {
1914
- const i = /* @__PURE__ */ new Set();
1915
- i.add(o.value.nonNullAnnotation);
1916
- const l = o.value.nonNullAnnotation.split(".").pop(), m = n(r), C = o.value.additions, p = [];
1917
- return C.has(O.RecordVakueObject) ? (p.push(`public record ${m}(@${l} ${v(i, r)} value) {`), p.push(` public ${m} {`), p.push(" // HACK check value"), p.push(" }"), p.push("}")) : C.has(O.Lombok) ? (p.push("@lombok.Getter"), p.push(`public class ${m} {`), p.push(` private final ${v(i, r)} value;`), p.push(""), p.push(` public ${m} (@${l} ${v(i, r)} value) {`), p.push(" // HACK check value"), p.push(" this.value = value;"), p.push(" }"), p.push("}")) : (p.push(`public class ${n(r)} {`), p.push(` private final ${v(i, r)} value;`), p.push(""), p.push(` public ${m} (@${l} ${v(i, r)} value) {`), p.push(" // HACK check value"), p.push(" this.value = value;"), p.push(" }"), p.push(""), p.push(` public ${v(i, r)} getValue() {`), p.push(" return this.value;"), p.push(" }"), p.push("}")), [
1912
+ o.commands._setInfoCodeProvider(
1913
+ (i) => {
1914
+ const p = /* @__PURE__ */ new Set();
1915
+ p.add(r.value.nonNullAnnotation);
1916
+ const b = r.value.nonNullAnnotation.split(".").pop(), C = s(i), h = r.value.additions, $ = [];
1917
+ return h.has(j.RecordValueObject) ? (h.has(j.Jpa) && (p.add("javax.persistence.Embeddable"), $.push("@Embeddable")), $.push(`public record ${C}(@${b} ${a(p, i)} value) {`), $.push(` public ${C} {`), $.push(" // HACK check value"), $.push(" }"), $.push("}")) : h.has(j.Lombok) ? ($.push("@lombok.Getter"), h.has(j.Jpa) && (p.add("javax.persistence.Embeddable"), $.push("@Embeddable")), $.push(`public class ${C} {`), $.push(` private final ${a(p, i)} value;`), $.push(""), $.push(` public ${C} (@${b} ${a(p, i)} value) {`), $.push(" // HACK check value"), $.push(" this.value = value;"), $.push(" }"), $.push("}")) : (h.has(j.Jpa) && (p.add("javax.persistence.Embeddable"), $.push("@Embeddable")), $.push(`public class ${s(i)} {`), $.push(` private final ${a(p, i)} value;`), $.push(""), $.push(` public ${C} (@${b} ${a(p, i)} value) {`), $.push(" // HACK check value"), $.push(" this.value = value;"), $.push(" }"), $.push(""), $.push(` public ${a(p, i)} getValue() {`), $.push(" return this.value;"), $.push(" }"), $.push("}")), [
1918
1918
  {
1919
1919
  type: "Info",
1920
- imports: i,
1921
- content: p.join(`
1920
+ imports: p,
1921
+ content: $.join(`
1922
1922
  `)
1923
1923
  }
1924
1924
  ];
1925
1925
  }
1926
1926
  );
1927
- function d(r) {
1928
- const i = [], l = o.value.additions, m = o.value.nonNullAnnotation.split(".").pop();
1927
+ function u(i) {
1928
+ const p = [], b = r.value.additions, C = r.value.nonNullAnnotation.split(".").pop();
1929
1929
  {
1930
- const C = /* @__PURE__ */ new Set();
1931
- C.add(o.value.nonNullAnnotation);
1932
- const p = n(r), f = [], $ = Object.values(r.inner);
1933
- if (g(C, $), l.has(O.RecordVakueObject)) {
1934
- l.has(O.LombokBuilder) && f.push("@lombok.Builder(toBuilder = true)"), f.push(`public record ${p}(`);
1935
- const _ = [];
1936
- for (const b of $) {
1937
- const h = n(b);
1938
- _.push(
1939
- ` @${m}
1940
- ${c(
1941
- C,
1942
- b
1943
- )} ${N.lowerFirst(h)}`
1930
+ const h = /* @__PURE__ */ new Set();
1931
+ h.add(r.value.nonNullAnnotation);
1932
+ const $ = s(i), l = [], d = Object.values(i.inner);
1933
+ if (m(h, d), b.has(j.RecordValueObject)) {
1934
+ b.has(j.LombokBuilder) && l.push("@lombok.Builder(toBuilder = true)"), l.push(`public record ${$}(`);
1935
+ const w = [];
1936
+ for (const f of d) {
1937
+ const v = s(f);
1938
+ w.push(
1939
+ ` @${C}
1940
+ ${_(
1941
+ h,
1942
+ f
1943
+ )} ${y.lowerFirst(v)}`
1944
1944
  );
1945
1945
  }
1946
- f.push(_.join(`,
1947
- `)), f.push(") {"), f.push(` public ${p} {`), f.push(" // HACK check value"), f.push(" }"), f.push("}");
1948
- } else if (l.has(O.Lombok)) {
1949
- f.push("@lombok.AllArgsConstructor"), f.push("@lombok.Getter"), l.has(O.LombokBuilder) && f.push("@lombok.Builder(toBuilder = true)"), f.push(`public class ${p} {`);
1950
- for (const _ of $) {
1951
- const b = n(_);
1952
- f.push(` @${m}`), f.push(
1953
- ` private final ${c(C, _)} ${N.lowerFirst(b)};`
1946
+ l.push(w.join(`,
1947
+ `)), l.push(") {"), l.push(` public ${$} {`), l.push(" // HACK check value"), l.push(" }"), l.push("}");
1948
+ } else if (b.has(j.Lombok)) {
1949
+ l.push("@lombok.AllArgsConstructor"), l.push("@lombok.Getter"), b.has(j.LombokBuilder) && l.push("@lombok.Builder(toBuilder = true)"), l.push(`public class ${$} {`);
1950
+ for (const w of d) {
1951
+ const f = s(w);
1952
+ l.push(` @${C}`), l.push(
1953
+ ` private final ${_(h, w)} ${y.lowerFirst(f)};`
1954
1954
  );
1955
1955
  }
1956
- f.push("}");
1956
+ l.push("}");
1957
1957
  } else {
1958
- f.push(`public class ${p} {`);
1959
- for (const h of $) {
1960
- const u = n(h);
1961
- f.push(` @${m}`), f.push(
1962
- ` private final ${c(C, h)} ${N.lowerFirst(u)};`
1958
+ l.push(`public class ${$} {`);
1959
+ for (const v of d) {
1960
+ const N = s(v);
1961
+ l.push(` @${C}`), l.push(
1962
+ ` private final ${_(h, v)} ${y.lowerFirst(N)};`
1963
1963
  );
1964
1964
  }
1965
- f.push("");
1966
- const _ = [], b = [];
1967
- for (const h of $) {
1968
- const u = n(h);
1969
- _.push(
1970
- `@${m} ${v(C, h)} ${N.lowerFirst(u)}`
1971
- ), b.push(`this.${N.lowerFirst(u)} = ${N.lowerFirst(u)};`);
1965
+ l.push("");
1966
+ const w = [], f = [];
1967
+ for (const v of d) {
1968
+ const N = s(v);
1969
+ w.push(
1970
+ `@${C} ${a(h, v)} ${y.lowerFirst(N)}`
1971
+ ), f.push(`this.${y.lowerFirst(N)} = ${y.lowerFirst(N)};`);
1972
1972
  }
1973
- f.push(` public ${p}(${_.join(", ")}) {`), f.push(` ${b.join(`
1974
- `)}`), f.push(" }");
1975
- for (const h of $) {
1976
- const u = n(h);
1977
- f.push(""), f.push(` public ${c(C, h)} get${u} () {`), f.push(` return this.${N.lowerFirst(u)};`), f.push(" }");
1973
+ l.push(` public ${$}(${w.join(", ")}) {`), l.push(` ${f.join(`
1974
+ `)}`), l.push(" }");
1975
+ for (const v of d) {
1976
+ const N = s(v);
1977
+ l.push(""), l.push(` public ${_(h, v)} get${N} () {`), l.push(` return this.${y.lowerFirst(N)};`), l.push(" }");
1978
1978
  }
1979
- f.push("}");
1979
+ l.push("}");
1980
1980
  }
1981
- i.push({
1981
+ p.push({
1982
1982
  type: "Command",
1983
- imports: C,
1984
- content: f.join(`
1983
+ imports: h,
1984
+ content: l.join(`
1985
1985
  `)
1986
1986
  });
1987
1987
  }
1988
- if (!l.has(O.CommandHandler))
1989
- return i;
1988
+ if (!b.has(j.CommandHandler))
1989
+ return p;
1990
1990
  {
1991
- const C = /* @__PURE__ */ new Set();
1992
- C.add(o.value.nonNullAnnotation);
1993
- const p = n(r), f = [];
1994
- l.has(O.SpringFramework) && (C.add("org.springframework.stereotype.Component"), f.push("@Component")), l.has(O.Lombok) && f.push("@lombok.RequiredArgsConstructor"), f.push(`public class ${p}Handler {`);
1995
- const $ = [...t.states.designer.value._getContext().getAssociationMap()[r._attributes.__id]].filter(
1996
- (_) => _._attributes.rule === "Agg"
1991
+ const h = /* @__PURE__ */ new Set();
1992
+ h.add(r.value.nonNullAnnotation);
1993
+ const $ = s(i), l = [];
1994
+ b.has(j.SpringFramework) && (h.add("org.springframework.stereotype.Component"), l.push("@Component")), b.has(j.Lombok) && l.push("@lombok.RequiredArgsConstructor"), l.push(`public class ${$}Handler {`);
1995
+ const d = [...o.states.designer.value._getContext().getAssociationMap()[i._attributes.__id]].filter(
1996
+ (w) => w._attributes.rule === "Agg"
1997
1997
  );
1998
- for (const _ of $)
1999
- C.add(`${o.value.namespace}.${o.value.moduleName}.${n(_)}`), f.push(` public ${n(_)} handle(@${m} ${p} command) {`), f.push(" // HACK Implement"), f.push(" }");
2000
- f.push("}"), i.push({
1998
+ for (const w of d)
1999
+ h.add(`${r.value.namespace}.${r.value.moduleName}.${s(w)}`), l.push(` public ${s(w)} handle(@${C} ${$} command) {`), l.push(" // HACK Implement"), l.push(" }");
2000
+ l.push("}"), p.push({
2001
2001
  type: "CommandHandler",
2002
- imports: C,
2003
- content: f.join(`
2002
+ imports: h,
2003
+ content: l.join(`
2004
2004
  `)
2005
2005
  });
2006
2006
  }
2007
- return i;
2007
+ return p;
2008
2008
  }
2009
- t.commands._setCommandCodeProvider(d), t.commands._setFacadeCommandCodeProvider(d), t.commands._setAggCodeProvider(
2010
- (r) => {
2011
- const i = o.value.additions, l = t.states.designer.value, m = o.value.nonNullAnnotation.split(".").pop(), C = n(r), p = [];
2009
+ o.commands._setCommandCodeProvider(u), o.commands._setFacadeCommandCodeProvider((i) => {
2010
+ const p = [], b = r.value.additions, C = r.value.nonNullAnnotation.split(".").pop();
2011
+ {
2012
+ const h = /* @__PURE__ */ new Set();
2013
+ h.add(r.value.nonNullAnnotation);
2014
+ const $ = s(i), l = [], d = Object.values(i.inner);
2015
+ if (m(h, d), b.has(j.RecordValueObject)) {
2016
+ b.has(j.LombokBuilder) && l.push("@lombok.Builder(toBuilder = true)"), l.push(`public record ${$}(`);
2017
+ const w = [];
2018
+ for (const f of d) {
2019
+ const v = s(f);
2020
+ w.push(
2021
+ ` @${C}
2022
+ ${_(
2023
+ h,
2024
+ f
2025
+ )} ${y.lowerFirst(v)}`
2026
+ );
2027
+ }
2028
+ l.push(w.join(`,
2029
+ `)), l.push(") {"), l.push(` public ${$} {`), l.push(" // HACK check value"), l.push(" }"), l.push("}");
2030
+ } else if (b.has(j.Lombok)) {
2031
+ l.push("@lombok.AllArgsConstructor"), l.push("@lombok.Getter"), b.has(j.LombokBuilder) && l.push("@lombok.Builder(toBuilder = true)"), l.push(`public class ${$} {`);
2032
+ for (const w of d) {
2033
+ const f = s(w);
2034
+ l.push(` @${C}`), l.push(
2035
+ ` private final ${_(h, w)} ${y.lowerFirst(f)};`
2036
+ );
2037
+ }
2038
+ l.push("}");
2039
+ } else {
2040
+ l.push(`public class ${$} {`);
2041
+ for (const v of d) {
2042
+ const N = s(v);
2043
+ l.push(` @${C}`), l.push(
2044
+ ` private final ${_(h, v)} ${y.lowerFirst(N)};`
2045
+ );
2046
+ }
2047
+ l.push("");
2048
+ const w = [], f = [];
2049
+ for (const v of d) {
2050
+ const N = s(v);
2051
+ w.push(
2052
+ `@${C} ${a(h, v)} ${y.lowerFirst(N)}`
2053
+ ), f.push(`this.${y.lowerFirst(N)} = ${y.lowerFirst(N)};`);
2054
+ }
2055
+ l.push(` public ${$}(${w.join(", ")}) {`), l.push(` ${f.join(`
2056
+ `)}`), l.push(" }");
2057
+ for (const v of d) {
2058
+ const N = s(v);
2059
+ l.push(""), l.push(` public ${_(h, v)} get${N} () {`), l.push(` return this.${y.lowerFirst(N)};`), l.push(" }");
2060
+ }
2061
+ l.push("}");
2062
+ }
2063
+ p.push({
2064
+ type: "FacadeCommand",
2065
+ imports: h,
2066
+ content: l.join(`
2067
+ `)
2068
+ });
2069
+ }
2070
+ if (!b.has(j.CommandHandler))
2071
+ return p;
2072
+ {
2073
+ const h = /* @__PURE__ */ new Set();
2074
+ h.add(r.value.nonNullAnnotation);
2075
+ const $ = s(i), l = [];
2076
+ b.has(j.SpringFramework) && (h.add("org.springframework.stereotype.Component"), l.push("@Component")), b.has(j.Lombok) && l.push("@lombok.RequiredArgsConstructor"), l.push(`public class ${$}Handler {`);
2077
+ const d = [...o.states.designer.value._getContext().getAssociationMap()[i._attributes.__id]].filter(
2078
+ (w) => w._attributes.rule === "Agg"
2079
+ );
2080
+ for (const w of d)
2081
+ h.add(`${r.value.namespace}.${r.value.moduleName}.${s(w)}`), l.push(` public ${s(w)} handle(@${C} ${$} command) {`), l.push(" // HACK Implement"), l.push(" }");
2082
+ l.push("}"), p.push({
2083
+ type: "FacadeCommandHandler",
2084
+ imports: h,
2085
+ content: l.join(`
2086
+ `)
2087
+ });
2088
+ }
2089
+ return p;
2090
+ }), o.commands._setAggCodeProvider(
2091
+ (i) => {
2092
+ const p = r.value.additions, b = o.states.designer.value, C = r.value.nonNullAnnotation.split(".").pop(), h = s(i), $ = [];
2012
2093
  {
2013
- const f = /* @__PURE__ */ new Set();
2014
- f.add(o.value.nonNullAnnotation);
2015
- const $ = [], _ = [], b = [...l._getContext().getAssociationMap()[r._attributes.__id]].filter((h) => h._attributes.rule === "Command" || h._attributes.rule === "FacadeCommand");
2016
- for (const h of b) {
2017
- const u = n(h);
2018
- _.push(`public void handle${u}(@${m} ${u} command);`);
2094
+ const l = /* @__PURE__ */ new Set();
2095
+ l.add(r.value.nonNullAnnotation);
2096
+ const d = [], w = [], f = [...b._getContext().getAssociationMap()[i._attributes.__id]].filter((v) => v._attributes.rule === "Command" || v._attributes.rule === "FacadeCommand");
2097
+ for (const v of f) {
2098
+ const N = s(v);
2099
+ w.push(`public void handle${N}(@${C} ${N} command);`);
2019
2100
  }
2020
- $.push(`public interface ${C} {`), $.push(` ${_.join(`
2101
+ d.push(`public interface ${h} {`), d.push(` ${w.join(`
2021
2102
 
2022
- `)}`), $.push("}"), p.push({
2103
+ `)}`), d.push("}"), $.push({
2023
2104
  type: "Agg",
2024
- imports: f,
2025
- content: $.join(`
2105
+ imports: l,
2106
+ content: d.join(`
2026
2107
  `)
2027
2108
  });
2028
2109
  }
2029
2110
  {
2030
- const f = /* @__PURE__ */ new Set();
2031
- f.add(o.value.nonNullAnnotation);
2032
- const $ = [], _ = Object.values(r.inner);
2033
- if (g(f, _), i.has(O.Lombok)) {
2034
- $.push("@lombok.AllArgsConstructor"), $.push("@lombok.Getter"), $.push(`public class ${C}Impl implements ${C} {`);
2035
- for (const h of _) {
2036
- const u = n(h);
2037
- $.push(` @${m}`), $.push(` private ${c(f, h)} ${N.lowerFirst(u)};`);
2111
+ const l = /* @__PURE__ */ new Set();
2112
+ l.add(r.value.nonNullAnnotation);
2113
+ const d = [], w = Object.values(i.inner);
2114
+ if (m(l, w), p.has(j.Lombok)) {
2115
+ d.push(
2116
+ p.has(j.Jpa) ? "@lombok.NoArgsConstructor" : "@lombok.AllArgsConstructor"
2117
+ ), d.push("@lombok.Getter"), p.has(j.Jpa) && (l.add("javax.persistence.Entity"), d.push("@Entity"), l.add("javax.persistence.Table"), d.push(`@Table(name = "${y.camelToLowerSnake(h)}")`)), d.push(`public class ${h}Impl implements ${h} {`);
2118
+ for (const v of w) {
2119
+ const N = s(v);
2120
+ d.push(` @${C}`), p.has(j.Jpa) && (v._attributes.type === "Id" && (l.add("javax.persistence.Id"), d.push(` @GeneratedValue(strategy = GenerationType.${r.value.idGenStrategy})`), d.push(" @Id")), l.add("javax.persistence.AttributeOverride"), l.add("javax.persistence.Column"), d.push(
2121
+ ` @AttributeOverride(name = "value", column = @Column(name = "${y.camelToUpperSnake(
2122
+ N
2123
+ )}", unique = true))`
2124
+ )), d.push(` private ${_(l, v)} ${y.lowerFirst(N)};`);
2038
2125
  }
2039
- const b = [...l._getContext().getAssociationMap()[r._attributes.__id]].filter((h) => h._attributes.rule === "Command" || h._attributes.rule === "FacadeCommand");
2040
- for (const h of b) {
2041
- const u = n(h);
2042
- $.push(""), $.push(
2043
- ` public void handle${u}(@${m} ${u} ${N.lowerFirst(
2044
- u
2126
+ const f = [...b._getContext().getAssociationMap()[i._attributes.__id]].filter((v) => v._attributes.rule === "Command" || v._attributes.rule === "FacadeCommand");
2127
+ for (const v of f) {
2128
+ const N = s(v);
2129
+ d.push(""), d.push(
2130
+ ` public void handle${N}(@${C} ${N} ${y.lowerFirst(
2131
+ N
2045
2132
  )}) {`
2046
- ), $.push(" // HACK need implement"), $.push(" }");
2133
+ ), d.push(" // HACK need implement"), d.push(" }");
2047
2134
  }
2048
- $.push("}");
2135
+ d.push("}");
2049
2136
  } else {
2050
- $.push(`public class ${C}Impl implements ${C} {`);
2051
- for (const w of _) {
2052
- const y = n(w);
2053
- $.push(` @${m}`), $.push(` private ${c(f, w)} ${N.lowerFirst(y)};`);
2137
+ p.has(j.Jpa) && (l.add("javax.persistence.Entity"), d.push("@Entity"), l.add("javax.persistence.Table"), d.push(`@Table(name = "${y.camelToLowerSnake(h)}")`)), d.push(`public class ${h}Impl implements ${h} {`);
2138
+ for (const E of w) {
2139
+ const O = s(E);
2140
+ d.push(` @${C}`), p.has(j.Jpa) && (E._attributes.type === "Id" && (l.add("javax.persistence.Id"), d.push(` @GeneratedValue(strategy = GenerationType.${r.value.idGenStrategy})`), d.push(" @Id")), l.add("javax.persistence.AttributeOverride"), l.add("javax.persistence.Column"), d.push(
2141
+ ` @AttributeOverride(name = "value", column = @Column(name = "${y.camelToUpperSnake(
2142
+ O
2143
+ )}"))`
2144
+ )), d.push(` private ${_(l, E)} ${y.lowerFirst(O)};`);
2054
2145
  }
2055
- $.push("");
2056
- const b = [], h = [];
2057
- for (const w of _) {
2058
- const y = n(w);
2059
- b.push(
2060
- `@${m} ${c(f, w)} ${N.lowerFirst(y)}`
2061
- ), h.push(`this.${N.lowerFirst(y)} = ${N.lowerFirst(y)};`);
2146
+ d.push("");
2147
+ const f = [], v = [];
2148
+ for (const E of w) {
2149
+ if (p.has(j.Jpa))
2150
+ break;
2151
+ const O = s(E);
2152
+ f.push(
2153
+ `@${C} ${_(l, E)} ${y.lowerFirst(O)}`
2154
+ ), v.push(`this.${y.lowerFirst(O)} = ${y.lowerFirst(O)};`);
2062
2155
  }
2063
- $.push(` public ${C}(${b.join(", ")}) {`), $.push(` ${h.join(`
2064
- `)}`), $.push(" }");
2065
- for (const w of _) {
2066
- const y = n(w);
2067
- $.push(""), $.push(` @${m}`), $.push(` public ${c(f, w)} get${y}() {`), $.push(` return this.${N.lowerFirst(y)};`), $.push(" }");
2156
+ d.push(` public ${h}Impl(${f.join(", ")}) {`), d.push(` ${v.join(`
2157
+ `)}`), d.push(" }");
2158
+ for (const E of w) {
2159
+ const O = s(E);
2160
+ d.push(""), d.push(` @${C}`), d.push(` public ${_(l, E)} get${O}() {`), d.push(` return this.${y.lowerFirst(O)};`), d.push(" }");
2068
2161
  }
2069
- const u = [...l._getContext().getAssociationMap()[r._attributes.__id]].filter(
2070
- (w) => w._attributes.rule === "Command" || w._attributes.rule === "FacadeCommand"
2162
+ const N = [...b._getContext().getAssociationMap()[i._attributes.__id]].filter(
2163
+ (E) => E._attributes.rule === "Command" || E._attributes.rule === "FacadeCommand"
2071
2164
  );
2072
- for (const w of u) {
2073
- const y = n(w);
2074
- $.push(""), $.push(
2075
- ` public void handle${y}(@${m} ${y} ${N.lowerFirst(
2076
- y
2165
+ for (const E of N) {
2166
+ const O = s(E);
2167
+ d.push(""), d.push(
2168
+ ` public void handle${O}(@${C} ${O} ${y.lowerFirst(
2169
+ O
2077
2170
  )}) {`
2078
- ), $.push(" // HACK need implement"), $.push(" }");
2171
+ ), d.push(" // HACK need implement"), d.push(" }");
2079
2172
  }
2080
- $.push("}");
2173
+ d.push("}");
2081
2174
  }
2082
- p.push({
2175
+ $.push({
2083
2176
  type: "AggImpl",
2084
- imports: f,
2085
- content: $.join(`
2177
+ imports: l,
2178
+ content: d.join(`
2086
2179
  `)
2087
2180
  });
2088
2181
  }
2089
- return p;
2182
+ return $;
2090
2183
  }
2091
- ), t.commands._setEventCodeProvider(
2092
- (r) => {
2093
- const i = /* @__PURE__ */ new Set();
2094
- i.add(o.value.nonNullAnnotation);
2095
- const l = o.value.nonNullAnnotation.split(".").pop(), m = o.value.additions, C = n(r), p = [], f = Object.values(r.inner);
2096
- if (g(i, f), m.has(O.RecordVakueObject)) {
2097
- m.has(O.LombokBuilder) && p.push("@lombok.Builder(toBuilder = true)"), p.push(`public record ${C}(`);
2098
- const $ = [];
2099
- for (const _ of f) {
2100
- const b = n(_);
2101
- $.push(
2102
- ` @${l}
2103
- ${c(
2104
- i,
2105
- _
2106
- )} ${N.lowerFirst(b)}`
2184
+ ), o.commands._setEventCodeProvider(
2185
+ (i) => {
2186
+ const p = /* @__PURE__ */ new Set();
2187
+ p.add(r.value.nonNullAnnotation);
2188
+ const b = r.value.nonNullAnnotation.split(".").pop(), C = r.value.additions, h = s(i), $ = [], l = Object.values(i.inner);
2189
+ if (m(p, l), C.has(j.RecordValueObject)) {
2190
+ C.has(j.LombokBuilder) && $.push("@lombok.Builder(toBuilder = true)"), $.push(`public record ${h}(`);
2191
+ const d = [];
2192
+ for (const w of l) {
2193
+ const f = s(w);
2194
+ d.push(
2195
+ ` @${b}
2196
+ ${_(
2197
+ p,
2198
+ w
2199
+ )} ${y.lowerFirst(f)}`
2107
2200
  );
2108
2201
  }
2109
- p.push($.join(`,
2110
- `)), p.push(") {"), p.push(` public ${C} {`), p.push(" // HACK check value"), p.push(" }"), p.push("}");
2111
- } else if (m.has(O.Lombok)) {
2112
- p.push("@lombok.AllArgsConstructor"), p.push("@lombok.Getter"), m.has(O.LombokBuilder) && p.push("@lombok.Builder(toBuilder = true)"), p.push(`public class ${C} {`);
2113
- for (const $ of f) {
2114
- const _ = n($);
2115
- p.push(` @${l}`), p.push(
2116
- ` private final ${c(i, $)} ${N.lowerFirst(_)};`
2202
+ $.push(d.join(`,
2203
+ `)), $.push(") {"), $.push(` public ${h} {`), $.push(" // HACK check value"), $.push(" }"), $.push("}");
2204
+ } else if (C.has(j.Lombok)) {
2205
+ $.push("@lombok.AllArgsConstructor"), $.push("@lombok.Getter"), C.has(j.LombokBuilder) && $.push("@lombok.Builder(toBuilder = true)"), $.push(`public class ${h} {`);
2206
+ for (const d of l) {
2207
+ const w = s(d);
2208
+ $.push(` @${b}`), $.push(
2209
+ ` private final ${_(p, d)} ${y.lowerFirst(w)};`
2117
2210
  );
2118
2211
  }
2119
- p.push("}");
2212
+ $.push("}");
2120
2213
  } else {
2121
- p.push(`public class ${C} {`);
2122
- for (const b of f) {
2123
- const h = n(b);
2124
- p.push(` @${l}`), p.push(` private final ${h} ${N.lowerFirst(h)};`);
2214
+ $.push(`public class ${h} {`);
2215
+ for (const f of l) {
2216
+ const v = s(f);
2217
+ $.push(` @${b}`), $.push(` private final ${v} ${y.lowerFirst(v)};`);
2125
2218
  }
2126
- p.push("");
2127
- const $ = [], _ = [];
2128
- for (const b of f) {
2129
- const h = n(b);
2130
- $.push(
2131
- `@${l} ${v(i, b)} ${N.lowerFirst(h)}`
2132
- ), _.push(`this.${N.lowerFirst(h)} = ${N.lowerFirst(h)};`);
2219
+ $.push("");
2220
+ const d = [], w = [];
2221
+ for (const f of l) {
2222
+ const v = s(f);
2223
+ d.push(
2224
+ `@${b} ${a(p, f)} ${y.lowerFirst(v)}`
2225
+ ), w.push(`this.${y.lowerFirst(v)} = ${y.lowerFirst(v)};`);
2133
2226
  }
2134
- p.push(` public ${C}(${$.join(", ")}) {`), p.push(` ${_.join(`
2135
- `)}`), p.push(" }");
2136
- for (const b of f) {
2137
- const h = n(b);
2138
- p.push(""), p.push(` public ${h} get${h} () {`), p.push(` return this.${N.lowerFirst(h)};`), p.push(" }");
2227
+ $.push(` public ${h}(${d.join(", ")}) {`), $.push(` ${w.join(`
2228
+ `)}`), $.push(" }");
2229
+ for (const f of l) {
2230
+ const v = s(f);
2231
+ $.push(""), $.push(` public ${v} get${v} () {`), $.push(` return this.${y.lowerFirst(v)};`), $.push(" }");
2139
2232
  }
2140
- p.push("}");
2233
+ $.push("}");
2141
2234
  }
2142
2235
  return [
2143
2236
  {
2144
2237
  type: "Event",
2145
- imports: i,
2146
- content: p.join(`
2238
+ imports: p,
2239
+ content: $.join(`
2147
2240
  `)
2148
2241
  }
2149
2242
  ];
2150
2243
  }
2151
- ), t.commands._setReadModelCodeProvider(() => []), t.commands._setCodeFileProvider(() => {
2152
- const r = [], i = {};
2153
- function l($) {
2154
- for (const _ of Object.values($)) {
2155
- if (!a(_))
2244
+ ), o.commands._setReadModelCodeProvider(() => []), o.commands._setCodeFileProvider(() => {
2245
+ const i = [], p = {};
2246
+ function b(d) {
2247
+ for (const w of Object.values(d)) {
2248
+ if (!g(w))
2156
2249
  continue;
2157
- const b = [...o.value.namespace.split(/\./), o.value.moduleName, e], h = n(_) + ".java";
2158
- if (i[`${b.join("/")}/${h}`] === !0)
2250
+ const f = [...r.value.namespace.split(/\./), r.value.moduleName, e], v = s(w) + ".java";
2251
+ if (p[`${f.join("/")}/${v}`] === !0)
2159
2252
  continue;
2160
- const u = t.commands._genInfoCode(_);
2161
- if (u.length === 0)
2253
+ const N = o.commands._genInfoCode(w);
2254
+ if (N.length === 0)
2162
2255
  continue;
2163
- const w = new j(b, h);
2164
- w.appendContentln(`package ${o.value.namespace}.${o.value.moduleName}.${e};`), w.appendContentln("");
2165
- for (const y of u[0].imports)
2166
- w.appendContentln(`import ${y};`);
2167
- w.appendContentln(""), w.appendContentln(u[0].content), r.push(w), i[`${b.join("/")}/${h}`] = !0;
2256
+ const E = new I(f, v);
2257
+ E.appendContentln(`package ${r.value.namespace}.${r.value.moduleName}.${e};`), E.appendContentln("");
2258
+ for (const O of N[0].imports)
2259
+ E.appendContentln(`import ${O};`);
2260
+ E.appendContentln(""), E.appendContentln(N[0].content), i.push(E), p[`${f.join("/")}/${v}`] = !0;
2168
2261
  }
2169
2262
  }
2170
- const m = t.states.designer.value._getContext().getCommands();
2171
- for (const $ of m) {
2172
- l($.inner);
2173
- const _ = t.commands._genCommandCode($), b = [...o.value.namespace.split(/\./), o.value.moduleName];
2174
- _.forEach((h) => {
2175
- if (h.type === "Command") {
2176
- const u = new j(b, n($) + ".java");
2177
- u.appendContentln(`package ${o.value.namespace}.${o.value.moduleName};`), u.appendContentln(""), u.addImports(h.imports);
2178
- for (const w of h.imports)
2179
- u.appendContentln(`import ${w};`);
2180
- u.appendContentln(""), u.appendContentln(h.content), r.push(u);
2181
- } else if (h.type === "CommandHandler") {
2182
- const u = new j(b, n($) + "Handler.java");
2183
- u.appendContentln(`package ${o.value.namespace}.${o.value.moduleName};`), u.appendContentln(""), u.addImports(h.imports);
2184
- for (const w of h.imports)
2185
- u.appendContentln(`import ${w};`);
2186
- u.appendContentln(""), u.appendContentln(h.content), r.push(u);
2263
+ const C = o.states.designer.value._getContext().getCommands();
2264
+ for (const d of C) {
2265
+ b(d.inner);
2266
+ const w = o.commands._genCommandCode(d), f = [...r.value.namespace.split(/\./), r.value.moduleName, n];
2267
+ w.forEach((v) => {
2268
+ if (v.type === "Command") {
2269
+ const N = new I(f, s(d) + ".java");
2270
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName}.${n};`), N.appendContentln(""), N.addImports(v.imports);
2271
+ for (const E of v.imports)
2272
+ N.appendContentln(`import ${E};`);
2273
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2274
+ } else if (v.type === "CommandHandler") {
2275
+ const N = new I(f, s(d) + "Handler.java");
2276
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName}.${n};`), N.appendContentln(""), N.addImports(v.imports);
2277
+ for (const E of v.imports)
2278
+ N.appendContentln(`import ${E};`);
2279
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2187
2280
  } else
2188
- isNever(h.type);
2281
+ isNever(v.type);
2189
2282
  });
2190
2283
  }
2191
- const C = t.states.designer.value._getContext().getFacadeCommands();
2192
- for (const $ of C) {
2193
- l($.inner);
2194
- const _ = t.commands._genFacadeCommandCode($), b = [...o.value.namespace.split(/\./), o.value.moduleName];
2195
- _.forEach((h) => {
2196
- if (h.type === "FacadeCommand") {
2197
- const u = new j(b, n($) + ".java");
2198
- u.appendContentln(`package ${o.value.namespace}.${o.value.moduleName};`), u.appendContentln(""), u.addImports(h.imports);
2199
- for (const w of h.imports)
2200
- u.appendContentln(`import ${w};`);
2201
- u.appendContentln(""), u.appendContentln(h.content), r.push(u);
2284
+ const h = o.states.designer.value._getContext().getFacadeCommands();
2285
+ for (const d of h) {
2286
+ b(d.inner);
2287
+ const w = o.commands._genFacadeCommandCode(d), f = [...r.value.namespace.split(/\./), r.value.moduleName, n];
2288
+ w.forEach((v) => {
2289
+ if (v.type === "FacadeCommand") {
2290
+ const N = new I(f, s(d) + ".java");
2291
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName}.${n};`), N.appendContentln(""), N.addImports(v.imports);
2292
+ for (const E of v.imports)
2293
+ N.appendContentln(`import ${E};`);
2294
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2295
+ } else if (v.type === "FacadeCommandHandler") {
2296
+ const N = new I(f, s(d) + "Handler.java");
2297
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName}.${n};`), N.appendContentln(""), N.addImports(v.imports);
2298
+ for (const E of v.imports)
2299
+ N.appendContentln(`import ${E};`);
2300
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2202
2301
  } else
2203
- isNever(h.type);
2302
+ isNever(v.type);
2204
2303
  });
2205
2304
  }
2206
- const p = t.states.designer.value._getContext().getAggs();
2207
- for (const $ of p) {
2208
- l($.inner);
2209
- const _ = t.commands._genAggCode($), b = [...o.value.namespace.split(/\./), o.value.moduleName];
2210
- _.forEach((h) => {
2211
- if (h.type === "Agg") {
2212
- const u = new j(b, n($) + ".java");
2213
- u.appendContentln(`package ${o.value.namespace}.${o.value.moduleName};`), u.appendContentln(""), u.addImports(h.imports);
2214
- for (const w of h.imports)
2215
- u.appendContentln(`import ${w};`);
2216
- u.appendContentln(""), u.appendContentln(h.content), r.push(u);
2217
- } else if (h.type === "AggImpl") {
2218
- const u = new j(b, n($) + "Impl.java");
2219
- u.appendContentln(`package ${o.value.namespace}.${o.value.moduleName};`), u.appendContentln(""), u.addImports(h.imports);
2220
- for (const w of h.imports)
2221
- u.appendContentln(`import ${w};`);
2222
- u.appendContentln(""), u.appendContentln(h.content), r.push(u);
2305
+ const $ = o.states.designer.value._getContext().getAggs();
2306
+ for (const d of $) {
2307
+ b(d.inner);
2308
+ const w = o.commands._genAggCode(d), f = [...r.value.namespace.split(/\./), r.value.moduleName];
2309
+ w.forEach((v) => {
2310
+ if (v.type === "Agg") {
2311
+ const N = new I(f, s(d) + ".java");
2312
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName};`), N.appendContentln(""), N.addImports(v.imports);
2313
+ for (const E of v.imports)
2314
+ N.appendContentln(`import ${E};`);
2315
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2316
+ } else if (v.type === "AggImpl") {
2317
+ const N = new I(f, s(d) + "Impl.java");
2318
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName};`), N.appendContentln(""), N.addImports(v.imports);
2319
+ for (const E of v.imports)
2320
+ N.appendContentln(`import ${E};`);
2321
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2223
2322
  } else
2224
- isNever(h.type);
2323
+ isNever(v.type);
2225
2324
  });
2226
2325
  }
2227
- const f = t.states.designer.value._getContext().getEvents();
2228
- for (const $ of f) {
2229
- l($.inner);
2230
- const _ = t.commands._genEventCode($), b = [...o.value.namespace.split(/\./), o.value.moduleName];
2231
- _.forEach((h) => {
2232
- const u = new j(b, n($) + ".java");
2233
- u.appendContentln(`package ${o.value.namespace}.${o.value.moduleName};`), u.appendContentln(""), u.addImports(h.imports);
2234
- for (const w of h.imports)
2235
- u.appendContentln(`import ${w};`);
2236
- u.appendContentln(""), u.appendContentln(h.content), r.push(u);
2326
+ const l = o.states.designer.value._getContext().getEvents();
2327
+ for (const d of l) {
2328
+ b(d.inner);
2329
+ const w = o.commands._genEventCode(d), f = [...r.value.namespace.split(/\./), r.value.moduleName, t];
2330
+ w.forEach((v) => {
2331
+ const N = new I(f, s(d) + ".java");
2332
+ N.appendContentln(`package ${r.value.namespace}.${r.value.moduleName}.${t};`), N.appendContentln(""), N.addImports(v.imports);
2333
+ for (const E of v.imports)
2334
+ N.appendContentln(`import ${E};`);
2335
+ N.appendContentln(""), N.appendContentln(v.content), i.push(N);
2237
2336
  });
2238
2337
  }
2239
- return r;
2338
+ return i;
2240
2339
  });
2241
2340
  }
2242
2341
  };
2243
- }), Te = we.KotlinGeneratorAddition, Ao = ue.createHotSwapPlugin(() => ({
2342
+ }), ke = ye.KotlinGeneratorAddition, xo = pe.createHotSwapPlugin(() => ({
2244
2343
  unmount({ api: e }) {
2245
2344
  e.commands.clearCaches(), e.commands._setCommandCodeProvider(() => []), e.commands._setFacadeCommandCodeProvider(() => []), e.commands._setAggCodeProvider(() => []), e.commands._setEventCodeProvider(() => []), e.commands._setReadModelCodeProvider(() => []), e.commands._setCodeFileProvider(() => []), e.commands.setContext({});
2246
2345
  },
2247
2346
  mount({ api: e }) {
2248
- const n = "value", t = e.states.context, o = e.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((d) => N.stringToLowerCamel(d));
2249
- function s(d) {
2250
- return !o.includes(N.stringToLowerCamel(d._attributes.name));
2347
+ const n = "value", t = e.states.context, s = e.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((m) => y.stringToLowerCamel(m));
2348
+ function o(m) {
2349
+ return !s.includes(y.stringToLowerCamel(m._attributes.name));
2251
2350
  }
2252
- function a(d, r) {
2253
- return s(r) ? N.stringToUpperCamel(r._attributes.name) : v(d, r);
2351
+ function r(m, a) {
2352
+ return o(a) ? y.stringToUpperCamel(a._attributes.name) : _(m, a);
2254
2353
  }
2255
- function c(d) {
2256
- return N.stringToUpperCamel(d._attributes.name);
2354
+ function c(m) {
2355
+ return y.stringToUpperCamel(m._attributes.name);
2257
2356
  }
2258
- function g(d, r) {
2259
- for (const i of r) {
2260
- if (!s(i)) {
2261
- v(d, i);
2357
+ function g(m, a) {
2358
+ for (const u of a) {
2359
+ if (!o(u)) {
2360
+ _(m, u);
2262
2361
  continue;
2263
2362
  }
2264
- d.add(
2265
- `${t.value.namespace}.${t.value.moduleName}.${n}.${c(i)}`
2363
+ m.add(
2364
+ `${t.value.namespace}.${t.value.moduleName}.${n}.${c(u)}`
2266
2365
  );
2267
2366
  }
2268
2367
  }
2269
- function v(d, r) {
2270
- const i = t.value.additions, l = N.stringToLowerSnake(r._attributes.name).replace(/_/, " ");
2271
- return /\b(time|timestamp|date|deadline|expire)\b/.test(l) ? i.has(Te.Timezone) ? (d.add("java.time.OffsetDateTime"), "OffsetDateTime") : (d.add("java.time.LocalDateTime"), "LocalDateTime") : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(l) ? "Integer" : /\b(price)$/.test(l) ? (d.add("java.math.BigDecimal"), "BigDecimal") : /^(if|is)\b/.test(l) ? "Boolean" : Ee(r) && (r._attributes.type === "Id" || r._attributes.type === "Version") ? "Long" : "String";
2368
+ function _(m, a) {
2369
+ const u = t.value.additions, i = y.stringToLowerSnake(a._attributes.name).replace(/_/, " ");
2370
+ return /\b(time|timestamp|date|deadline|expire)\b/.test(i) ? u.has(ke.Timezone) ? (m.add("java.time.OffsetDateTime"), "OffsetDateTime") : (m.add("java.time.LocalDateTime"), "LocalDateTime") : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(i) ? "Integer" : /\b(price)$/.test(i) ? (m.add("java.math.BigDecimal"), "BigDecimal") : /^(if|is)\b/.test(i) ? "Boolean" : Se(a) && (a._attributes.type === "Id" || a._attributes.type === "Version") || /\b(id|identifier|ver|version)$/.test(i) ? "Long" : "String";
2272
2371
  }
2273
2372
  e.commands._setInfoCodeProvider(
2274
- (d) => {
2275
- const r = /* @__PURE__ */ new Set(), i = c(d), l = t.value.additions, m = [];
2276
- return l.has(Te.ValueClass) ? (r.add("kotlin.jvm.JvmInline"), m.push("@JvmInline"), m.push(`value class ${i}(val value: ${v(r, d)})`)) : m.push(`data class ${i}(val value: ${v(r, d)})`), [
2373
+ (m) => {
2374
+ const a = /* @__PURE__ */ new Set(), u = c(m), i = t.value.additions, p = [];
2375
+ return i.has(ke.ValueClass) ? (a.add("kotlin.jvm.JvmInline"), p.push("@JvmInline"), p.push(`value class ${u}(val value: ${_(a, m)})`)) : p.push(`data class ${u}(val value: ${_(a, m)})`), [
2277
2376
  {
2278
2377
  type: "Info",
2279
- imports: r,
2280
- content: m.join(`
2378
+ imports: a,
2379
+ content: p.join(`
2281
2380
  `)
2282
2381
  }
2283
2382
  ];
2284
2383
  }
2285
2384
  ), e.commands._setCommandCodeProvider(
2286
- (d) => {
2287
- const r = [], i = t.value.additions;
2385
+ (m) => {
2386
+ const a = [], u = t.value.additions;
2288
2387
  {
2289
- const l = /* @__PURE__ */ new Set(), m = c(d), C = [], p = Object.values(d.inner);
2290
- g(l, p);
2291
- const f = [];
2292
- for (const $ of p) {
2293
- const _ = c($);
2294
- f.push(`val ${N.lowerFirst(_)}: ${a(l, $)}`);
2388
+ const i = /* @__PURE__ */ new Set(), p = c(m), b = [], C = Object.values(m.inner);
2389
+ g(i, C);
2390
+ const h = [];
2391
+ for (const $ of C) {
2392
+ const l = c($);
2393
+ h.push(`val ${y.lowerFirst(l)}: ${r(i, $)}`);
2295
2394
  }
2296
- C.push(`data class ${m}(${f.join(", ")})`), r.push({
2395
+ b.push(`data class ${p}(${h.join(", ")})`), a.push({
2297
2396
  type: "Command",
2298
- imports: l,
2299
- content: C.join(`
2397
+ imports: i,
2398
+ content: b.join(`
2300
2399
  `)
2301
2400
  });
2302
2401
  }
2303
- if (!i.has(Te.CommandHandler))
2304
- return r;
2402
+ if (!u.has(ke.CommandHandler))
2403
+ return a;
2305
2404
  {
2306
- const l = /* @__PURE__ */ new Set(), m = c(d), C = [];
2307
- C.push(`class ${m}Handler {`);
2308
- const p = [...e.states.designer.value._getContext().getAssociationMap()[d._attributes.__id]].filter(
2309
- (f) => f._attributes.rule === "Agg"
2405
+ const i = /* @__PURE__ */ new Set(), p = c(m), b = [];
2406
+ b.push(`class ${p}Handler {`);
2407
+ const C = [...e.states.designer.value._getContext().getAssociationMap()[m._attributes.__id]].filter(
2408
+ (h) => h._attributes.rule === "Agg"
2310
2409
  );
2311
- for (const f of p)
2312
- l.add(`${t.value.namespace}.${t.value.moduleName}.${c(f)}`), C.push(` fun handle(command: ${m}): ${c(f)} {`), C.push(" // HACK Implement"), C.push(" }");
2313
- C.push("}"), r.push({
2410
+ for (const h of C)
2411
+ i.add(`${t.value.namespace}.${t.value.moduleName}.${c(h)}`), b.push(` fun handle(command: ${p}): ${c(h)} {`), b.push(" // HACK Implement"), b.push(" }");
2412
+ b.push("}"), a.push({
2314
2413
  type: "CommandHandler",
2315
- imports: l,
2316
- content: C.join(`
2414
+ imports: i,
2415
+ content: b.join(`
2317
2416
  `)
2318
2417
  });
2319
2418
  }
2320
- return r;
2419
+ return a;
2321
2420
  }
2322
2421
  ), e.commands._setFacadeCommandCodeProvider(
2323
- (d) => {
2324
- const r = /* @__PURE__ */ new Set(), i = c(d), l = [], m = Object.values(d.inner);
2325
- g(r, m);
2326
- const C = [];
2327
- for (const p of m) {
2328
- const f = c(p);
2329
- C.push(`val ${N.lowerFirst(f)}: ${a(r, p)}`);
2422
+ (m) => {
2423
+ const a = /* @__PURE__ */ new Set(), u = c(m), i = [], p = Object.values(m.inner);
2424
+ g(a, p);
2425
+ const b = [];
2426
+ for (const C of p) {
2427
+ const h = c(C);
2428
+ b.push(`val ${y.lowerFirst(h)}: ${r(a, C)}`);
2330
2429
  }
2331
- return l.push(`data class ${i}(${C.join(", ")})`), [
2430
+ return i.push(`data class ${u}(${b.join(", ")})`), [
2332
2431
  {
2333
2432
  type: "FacadeCommand",
2334
- imports: r,
2335
- content: l.join(`
2433
+ imports: a,
2434
+ content: i.join(`
2336
2435
  `)
2337
2436
  }
2338
2437
  ];
2339
2438
  }
2340
- ), e.commands._setAggCodeProvider((d) => {
2341
- const r = /* @__PURE__ */ new Set(), i = e.states.designer.value, l = c(d), m = [], C = Object.values(d.inner);
2342
- g(r, C);
2343
- const p = [], f = [...i._getContext().getAssociationMap()[d._attributes.__id]].filter((_) => _._attributes.rule === "Command" || _._attributes.rule === "FacadeCommand");
2344
- for (const _ of f) {
2345
- const b = c(_);
2346
- p.push(`fun handle(command: ${b})`);
2439
+ ), e.commands._setAggCodeProvider((m) => {
2440
+ const a = /* @__PURE__ */ new Set(), u = e.states.designer.value, i = c(m), p = [], b = Object.values(m.inner);
2441
+ g(a, b);
2442
+ const C = [], h = [...u._getContext().getAssociationMap()[m._attributes.__id]].filter((l) => l._attributes.rule === "Command" || l._attributes.rule === "FacadeCommand");
2443
+ for (const l of h) {
2444
+ const d = c(l);
2445
+ C.push(`fun handle(command: ${d})`);
2347
2446
  }
2348
- m.push(`interface ${l} {`), m.push(` ${p.join(`
2349
- `)}`), m.push("}"), m.push(""), m.push(`class ${l}Impl(`);
2447
+ p.push(`interface ${i} {`), p.push(` ${C.join(`
2448
+ `)}`), p.push("}"), p.push(""), p.push(`class ${i}Impl(`);
2350
2449
  const $ = [];
2351
- for (const _ of C) {
2352
- const b = c(_);
2353
- $.push(`val ${N.lowerFirst(b)}: ${a(r, _)}`);
2450
+ for (const l of b) {
2451
+ const d = c(l);
2452
+ $.push(`val ${y.lowerFirst(d)}: ${r(a, l)}`);
2354
2453
  }
2355
- m.push(` ${$.join(`,
2356
- `)}`), m.push(`): ${l} {`);
2357
- for (const _ of f) {
2358
- const b = c(_);
2359
- m.push(` override fun handle(command: ${b}) {`), m.push(" // HACK Implement"), m.push(" }");
2454
+ p.push(` ${$.join(`,
2455
+ `)}`), p.push(`): ${i} {`);
2456
+ for (const l of h) {
2457
+ const d = c(l);
2458
+ p.push(` override fun handle(command: ${d}) {`), p.push(" // HACK Implement"), p.push(" }");
2360
2459
  }
2361
- return m.push("}"), [
2460
+ return p.push("}"), [
2362
2461
  {
2363
2462
  type: "Agg",
2364
- imports: r,
2365
- content: m.join(`
2463
+ imports: a,
2464
+ content: p.join(`
2366
2465
  `)
2367
2466
  }
2368
2467
  ];
2369
2468
  }), e.commands._setEventCodeProvider(
2370
- (d) => {
2371
- const r = /* @__PURE__ */ new Set(), i = c(d), l = [], m = Object.values(d.inner);
2372
- g(r, m);
2373
- const C = [];
2374
- for (const p of m) {
2375
- const f = c(p);
2376
- C.push(`val ${N.lowerFirst(f)}: ${a(r, p)}`);
2469
+ (m) => {
2470
+ const a = /* @__PURE__ */ new Set(), u = c(m), i = [], p = Object.values(m.inner);
2471
+ g(a, p);
2472
+ const b = [];
2473
+ for (const C of p) {
2474
+ const h = c(C);
2475
+ b.push(`val ${y.lowerFirst(h)}: ${r(a, C)}`);
2377
2476
  }
2378
- return l.push(`data class ${i}(${C.join(", ")})`), [
2477
+ return i.push(`data class ${u}(${b.join(", ")})`), [
2379
2478
  {
2380
2479
  type: "Event",
2381
- imports: r,
2382
- content: l.join(`
2480
+ imports: a,
2481
+ content: i.join(`
2383
2482
  `)
2384
2483
  }
2385
2484
  ];
2386
2485
  }
2387
2486
  ), e.commands._setReadModelCodeProvider(() => []), e.commands._setCodeFileProvider(() => {
2388
- const d = [], r = {};
2389
- function i(f) {
2390
- for (const $ of Object.values(f)) {
2391
- if (!s($))
2487
+ const m = [], a = {};
2488
+ function u(h) {
2489
+ for (const $ of Object.values(h)) {
2490
+ if (!o($))
2392
2491
  continue;
2393
- const _ = [...t.value.namespace.split(/\./), t.value.moduleName, n], b = c($) + ".kt";
2394
- if (r[`${_.join("/")}/${b}`] === !0)
2492
+ const l = [...t.value.namespace.split(/\./), t.value.moduleName, n], d = c($) + ".kt";
2493
+ if (a[`${l.join("/")}/${d}`] === !0)
2395
2494
  continue;
2396
- const h = e.commands._genInfoCode($);
2397
- if (h.length === 0)
2495
+ const w = e.commands._genInfoCode($);
2496
+ if (w.length === 0)
2398
2497
  continue;
2399
- const u = new j(_, b);
2400
- u.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}.${n}`), u.appendContentln("");
2401
- for (const w of h[0].imports)
2402
- u.appendContentln(`import ${w}`);
2403
- u.appendContentln(""), u.appendContentln(h[0].content), d.push(u), r[`${_.join("/")}/${b}`] = !0;
2498
+ const f = new I(l, d);
2499
+ f.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}.${n}`), f.appendContentln("");
2500
+ for (const v of w[0].imports)
2501
+ f.appendContentln(`import ${v}`);
2502
+ f.appendContentln(""), f.appendContentln(w[0].content), m.push(f), a[`${l.join("/")}/${d}`] = !0;
2404
2503
  }
2405
2504
  }
2406
- const l = e.states.designer.value._getContext().getCommands();
2407
- for (const f of l) {
2408
- i(f.inner);
2409
- const $ = e.commands._genCommandCode(f), _ = [...t.value.namespace.split(/\./), t.value.moduleName], b = new j(_, c(f) + ".kt"), h = [];
2410
- b.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), b.appendContentln(""), $.forEach((u) => {
2411
- u.type === "Command" || u.type === "CommandHandler" ? (b.addImports(u.imports), h.push(u.content)) : isNever(u.type);
2505
+ const i = e.states.designer.value._getContext().getCommands();
2506
+ for (const h of i) {
2507
+ u(h.inner);
2508
+ const $ = e.commands._genCommandCode(h), l = [...t.value.namespace.split(/\./), t.value.moduleName], d = new I(l, c(h) + ".kt"), w = [];
2509
+ d.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), d.appendContentln(""), $.forEach((f) => {
2510
+ f.type === "Command" || f.type === "CommandHandler" ? (d.addImports(f.imports), w.push(f.content)) : isNever(f.type);
2412
2511
  });
2413
- for (const u of b.getImports())
2414
- b.appendContentln(`import ${u}`);
2415
- b.appendContentln("");
2416
- for (const u of h)
2417
- b.appendContentln(u);
2418
- d.push(b);
2512
+ for (const f of d.getImports())
2513
+ d.appendContentln(`import ${f}`);
2514
+ d.appendContentln("");
2515
+ for (const f of w)
2516
+ d.appendContentln(f);
2517
+ m.push(d);
2419
2518
  }
2420
- const m = e.states.designer.value._getContext().getFacadeCommands();
2421
- for (const f of m) {
2422
- i(f.inner);
2423
- const $ = e.commands._genFacadeCommandCode(f), _ = [...t.value.namespace.split(/\./), t.value.moduleName];
2424
- $.forEach((b) => {
2425
- if (b.type === "FacadeCommand") {
2426
- const h = new j(_, c(f) + ".kt");
2427
- h.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), h.appendContentln(""), h.addImports(b.imports);
2428
- for (const u of b.imports)
2429
- h.appendContentln(`import ${u}`);
2430
- h.appendContentln(""), h.appendContentln(b.content), d.push(h);
2431
- } else
2432
- isNever(b.type);
2519
+ const p = e.states.designer.value._getContext().getFacadeCommands();
2520
+ for (const h of p) {
2521
+ u(h.inner);
2522
+ const $ = e.commands._genFacadeCommandCode(h), l = [...t.value.namespace.split(/\./), t.value.moduleName], d = new I(l, c(h) + ".kt"), w = [];
2523
+ d.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), d.appendContentln(""), $.forEach((f) => {
2524
+ f.type === "FacadeCommand" || f.type === "FacadeCommandHandler" ? (d.addImports(f.imports), w.push(f.content)) : isNever(f.type);
2433
2525
  });
2526
+ for (const f of d.getImports())
2527
+ d.appendContentln(`import ${f}`);
2528
+ d.appendContentln("");
2529
+ for (const f of w)
2530
+ d.appendContentln(f);
2531
+ m.push(d);
2434
2532
  }
2435
- const C = e.states.designer.value._getContext().getAggs();
2436
- for (const f of C) {
2437
- i(f.inner);
2438
- const $ = e.commands._genAggCode(f), _ = [...t.value.namespace.split(/\./), t.value.moduleName], b = new j(_, c(f) + ".kt"), h = [];
2439
- b.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), b.appendContentln(""), $.forEach((u) => {
2440
- u.type === "Agg" || u.type === "AggImpl" ? (b.addImports(u.imports), h.push(u.content)) : isNever(u.type);
2533
+ const b = e.states.designer.value._getContext().getAggs();
2534
+ for (const h of b) {
2535
+ u(h.inner);
2536
+ const $ = e.commands._genAggCode(h), l = [...t.value.namespace.split(/\./), t.value.moduleName], d = new I(l, c(h) + ".kt"), w = [];
2537
+ d.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), d.appendContentln(""), $.forEach((f) => {
2538
+ f.type === "Agg" || f.type === "AggImpl" ? (d.addImports(f.imports), w.push(f.content)) : isNever(f.type);
2441
2539
  });
2442
- for (const u of b.getImports())
2443
- b.appendContentln(`import ${u}`);
2444
- b.appendContentln("");
2445
- for (const u of h)
2446
- b.appendContentln(u);
2447
- d.push(b);
2540
+ for (const f of d.getImports())
2541
+ d.appendContentln(`import ${f}`);
2542
+ d.appendContentln("");
2543
+ for (const f of w)
2544
+ d.appendContentln(f);
2545
+ m.push(d);
2448
2546
  }
2449
- const p = e.states.designer.value._getContext().getEvents();
2450
- for (const f of p) {
2451
- i(f.inner);
2452
- const $ = e.commands._genEventCode(f), _ = [...t.value.namespace.split(/\./), t.value.moduleName];
2453
- $.forEach((b) => {
2454
- if (b.type === "Event") {
2455
- const h = new j(_, c(f) + ".kt");
2456
- h.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), h.appendContentln(""), h.addImports(b.imports);
2457
- for (const u of b.imports)
2458
- h.appendContentln(`import ${u}`);
2459
- h.appendContentln(""), h.appendContentln(b.content), d.push(h);
2547
+ const C = e.states.designer.value._getContext().getEvents();
2548
+ for (const h of C) {
2549
+ u(h.inner);
2550
+ const $ = e.commands._genEventCode(h), l = [...t.value.namespace.split(/\./), t.value.moduleName];
2551
+ $.forEach((d) => {
2552
+ if (d.type === "Event") {
2553
+ const w = new I(l, c(h) + ".kt");
2554
+ w.appendContentln(`package ${t.value.namespace}.${t.value.moduleName}`), w.appendContentln(""), w.addImports(d.imports);
2555
+ for (const f of d.imports)
2556
+ w.appendContentln(`import ${f}`);
2557
+ w.appendContentln(""), w.appendContentln(d.content), m.push(w);
2460
2558
  } else
2461
- isNever(b.type);
2559
+ isNever(d.type);
2462
2560
  });
2463
2561
  }
2464
- return d;
2562
+ return m;
2465
2563
  });
2466
2564
  }
2467
- })), Io = ue.createHotSwapPlugin(() => ({
2565
+ })), To = pe.createHotSwapPlugin(() => ({
2468
2566
  unmount({ api: e }) {
2469
2567
  e.commands.clearCaches(), e.commands._setCommandCodeProvider(() => []), e.commands._setFacadeCommandCodeProvider(() => []), e.commands._setAggCodeProvider(() => []), e.commands._setEventCodeProvider(() => []), e.commands._setReadModelCodeProvider(() => []), e.commands._setCodeFileProvider(() => []), e.commands.setContext({});
2470
2568
  },
2471
2569
  mount({ api: e }) {
2472
- const n = e.states.context, t = e.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((v) => N.stringToLowerCamel(v));
2473
- function o(v) {
2474
- return !t.includes(N.stringToLowerCamel(v._attributes.name));
2570
+ const n = e.states.context, t = e.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((_) => y.stringToLowerCamel(_));
2571
+ function s(_) {
2572
+ return !t.includes(y.stringToLowerCamel(_._attributes.name));
2475
2573
  }
2476
- function s(v, d) {
2477
- return o(d) ? N.stringToUpperCamel(d._attributes.name) : g(v, d);
2574
+ function o(_, m) {
2575
+ return s(m) ? y.stringToUpperCamel(m._attributes.name) : g(_, m);
2478
2576
  }
2479
- function a(v) {
2480
- return N.stringToUpperCamel(v._attributes.name);
2577
+ function r(_) {
2578
+ return y.stringToUpperCamel(_._attributes.name);
2481
2579
  }
2482
- function c(v) {
2483
- return N.stringToLowerCamel(v._attributes.name);
2580
+ function c(_) {
2581
+ return y.stringToLowerCamel(_._attributes.name);
2484
2582
  }
2485
- function g(v, d) {
2486
- const r = N.stringToLowerSnake(d._attributes.name).replace(/_/, " ");
2487
- return /\b(time|timestamp|date|deadline|expire)\b/.test(r) ? (v.add("time"), "time.Time") : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(r) ? "int" : /\b(price)$/.test(r) ? "string" : /^(if|is)\b/.test(r) ? "bool" : Ee(d) && (d._attributes.type === "Id" || d._attributes.type === "Version") ? "int64" : "string";
2583
+ function g(_, m) {
2584
+ const a = y.stringToLowerSnake(m._attributes.name).replace(/_/, " ");
2585
+ return /\b(time|timestamp|date|deadline|expire)\b/.test(a) ? (_.add("time"), "time.Time") : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(a) ? "int" : /\b(price)$/.test(a) ? "string" : /^(if|is)\b/.test(a) ? "bool" : Se(m) && (m._attributes.type === "Id" || m._attributes.type === "Version" || /\b(id|identifier|ver|version)$/.test(a)) ? "int64" : "string";
2488
2586
  }
2489
2587
  e.commands._setInfoCodeProvider(
2490
- (v) => {
2491
- const d = /* @__PURE__ */ new Set(), r = [];
2492
- return r.push(`type ${a(v)} struct {`), r.push(` value ${g(d, v)}`), r.push("}"), r.push(""), r.push(
2493
- `func New${a(v)}(value ${g(
2494
- d,
2495
- v
2496
- )}) ${a(v)} {`
2497
- ), r.push(" // HACK check value"), r.push(` return ${a(v)}{value}`), r.push("}"), r.push(
2498
- `func (${c(v)} ${a(v)}) GetValue() ${g(
2499
- d,
2500
- v
2588
+ (_) => {
2589
+ const m = /* @__PURE__ */ new Set(), a = [];
2590
+ return a.push(`type ${r(_)} struct {`), a.push(` value ${g(m, _)}`), a.push("}"), a.push(""), a.push(
2591
+ `func New${r(_)}(value ${g(
2592
+ m,
2593
+ _
2594
+ )}) ${r(_)} {`
2595
+ ), a.push(" // HACK check value"), a.push(` return ${r(_)}{value}`), a.push("}"), a.push(
2596
+ `func (${c(_)} ${r(_)}) GetValue() ${g(
2597
+ m,
2598
+ _
2501
2599
  )} {`
2502
- ), r.push(` return ${c(v)}.value`), r.push("}"), [{ type: "Info", imports: d, content: r.join(`
2600
+ ), a.push(` return ${c(_)}.value`), a.push("}"), [{ type: "Info", imports: m, content: a.join(`
2503
2601
  `) }];
2504
2602
  }
2505
2603
  ), e.commands._setCommandCodeProvider(
2506
- (v) => {
2507
- const d = a(v), r = c(v), i = /* @__PURE__ */ new Set(), l = [];
2508
- l.push(`type ${d} struct {`);
2509
- const m = Object.values(v.inner);
2510
- for (const f of m)
2511
- l.push(` ${c(f)} ${s(i, f)}`);
2512
- l.push("}");
2513
- for (const f of m)
2514
- l.push(
2515
- `func (${r} ${d}) Get${a(f)} () ${s(
2516
- i,
2517
- f
2604
+ (_) => {
2605
+ const m = r(_), a = c(_), u = /* @__PURE__ */ new Set(), i = [];
2606
+ i.push(`type ${m} struct {`);
2607
+ const p = Object.values(_.inner);
2608
+ for (const h of p)
2609
+ i.push(` ${c(h)} ${o(u, h)}`);
2610
+ i.push("}");
2611
+ for (const h of p)
2612
+ i.push(
2613
+ `func (${a} ${m}) Get${r(h)} () ${o(
2614
+ u,
2615
+ h
2518
2616
  )} {`
2519
- ), l.push(` return ${r}.${c(f)}`), l.push("}");
2520
- const C = [], p = [];
2521
- for (const f of m)
2522
- C.push(`${c(f)} ${s(i, f)}`), p.push(c(f));
2523
- return l.push(`func New${d}(${C.join(", ")}) ${d} {`), l.push(" // HACK check value"), l.push(` return ${d}{`), l.push(` ${p.join(`,
2524
- `)},`), l.push(" }"), l.push("}"), [{ type: "Command", imports: i, content: l.join(`
2617
+ ), i.push(` return ${a}.${c(h)}`), i.push("}");
2618
+ const b = [], C = [];
2619
+ for (const h of p)
2620
+ b.push(`${c(h)} ${o(u, h)}`), C.push(c(h));
2621
+ return i.push(`func New${m}(${b.join(", ")}) ${m} {`), i.push(" // HACK check value"), i.push(` return ${m}{`), i.push(` ${C.join(`,
2622
+ `)},`), i.push(" }"), i.push("}"), [{ type: "Command", imports: u, content: i.join(`
2525
2623
  `) }];
2526
2624
  }
2527
2625
  ), e.commands._setFacadeCommandCodeProvider(
2528
- (v) => {
2529
- const d = a(v), r = c(v), i = Object.values(v.inner), l = /* @__PURE__ */ new Set(), m = [];
2530
- m.push(`type ${d} struct {`);
2531
- for (const f of i)
2532
- m.push(` ${c(f)} ${s(l, f)}`);
2533
- m.push("}");
2534
- for (const f of i)
2535
- m.push(
2536
- `func (${r} ${d}) Get${a(f)} () ${s(
2537
- l,
2538
- f
2626
+ (_) => {
2627
+ const m = r(_), a = c(_), u = Object.values(_.inner), i = /* @__PURE__ */ new Set(), p = [];
2628
+ p.push(`type ${m} struct {`);
2629
+ for (const h of u)
2630
+ p.push(` ${c(h)} ${o(i, h)}`);
2631
+ p.push("}");
2632
+ for (const h of u)
2633
+ p.push(
2634
+ `func (${a} ${m}) Get${r(h)} () ${o(
2635
+ i,
2636
+ h
2539
2637
  )} {`
2540
- ), m.push(` return ${r}.${c(f)}`), m.push("}");
2541
- const C = [], p = [];
2542
- for (const f of i)
2543
- C.push(`${c(f)} ${s(l, f)}`), p.push(c(f));
2544
- return m.push(`func New${d}(${C.join(", ")}) ${d} {`), m.push(" // HACK check value"), m.push(` return ${d}{`), m.push(` ${p.join(`,
2545
- `)},`), m.push(" }"), m.push("}"), [
2638
+ ), p.push(` return ${a}.${c(h)}`), p.push("}");
2639
+ const b = [], C = [];
2640
+ for (const h of u)
2641
+ b.push(`${c(h)} ${o(i, h)}`), C.push(c(h));
2642
+ return p.push(`func New${m}(${b.join(", ")}) ${m} {`), p.push(" // HACK check value"), p.push(` return ${m}{`), p.push(` ${C.join(`,
2643
+ `)},`), p.push(" }"), p.push("}"), [
2546
2644
  {
2547
2645
  type: "FacadeCommand",
2548
- imports: l,
2549
- content: m.join(`
2646
+ imports: i,
2647
+ content: p.join(`
2550
2648
  `)
2551
2649
  }
2552
2650
  ];
2553
2651
  }
2554
- ), e.commands._setAggCodeProvider((v) => {
2555
- const d = e.states.designer.value, r = a(v), i = c(v), l = Object.values(v.inner), m = /* @__PURE__ */ new Set(), C = [];
2556
- C.push(`type ${r} struct {`);
2557
- for (const _ of l)
2558
- C.push(` ${c(_)} ${s(m, _)}`);
2559
- C.push("}");
2560
- for (const _ of l)
2561
- C.push(
2562
- `func (${i} ${r}) Get${a(_)} () ${s(
2563
- m,
2564
- _
2652
+ ), e.commands._setAggCodeProvider((_) => {
2653
+ const m = e.states.designer.value, a = r(_), u = c(_), i = Object.values(_.inner), p = /* @__PURE__ */ new Set(), b = [];
2654
+ b.push(`type ${a} struct {`);
2655
+ for (const l of i)
2656
+ b.push(` ${c(l)} ${o(p, l)}`);
2657
+ b.push("}");
2658
+ for (const l of i)
2659
+ b.push(
2660
+ `func (${u} ${a}) Get${r(l)} () ${o(
2661
+ p,
2662
+ l
2565
2663
  )} {`
2566
- ), C.push(` return ${i}.${c(_)}`), C.push("}");
2567
- const p = [], f = [];
2568
- for (const _ of l)
2569
- p.push(`${c(_)} ${s(m, _)}`), f.push(c(_));
2570
- C.push(`func New${r}(${p.join(", ")}) ${r} {`), C.push(" // HACK check value"), C.push(` return ${r}{`), C.push(` ${f.join(`,
2571
- `)},`), C.push(" }"), C.push("}"), C.push("");
2572
- const $ = [...d._getContext().getAssociationMap()[v._attributes.__id]].filter((_) => _._attributes.rule === "Command" || _._attributes.rule === "FacadeCommand");
2573
- for (const _ of $) {
2574
- const b = a(_), h = c(_);
2575
- C.push(`func (${i} ${r}) Handle${b} (${h} ${b}) {`), C.push(" // HACK implement"), C.push("}");
2664
+ ), b.push(` return ${u}.${c(l)}`), b.push("}");
2665
+ const C = [], h = [];
2666
+ for (const l of i)
2667
+ C.push(`${c(l)} ${o(p, l)}`), h.push(c(l));
2668
+ b.push(`func New${a}(${C.join(", ")}) ${a} {`), b.push(" // HACK check value"), b.push(` return ${a}{`), b.push(` ${h.join(`,
2669
+ `)},`), b.push(" }"), b.push("}"), b.push("");
2670
+ const $ = [...m._getContext().getAssociationMap()[_._attributes.__id]].filter((l) => l._attributes.rule === "Command" || l._attributes.rule === "FacadeCommand");
2671
+ for (const l of $) {
2672
+ const d = r(l), w = c(l);
2673
+ b.push(`func (${u} ${a}) Handle${d} (${w} ${d}) {`), b.push(" // HACK implement"), b.push("}");
2576
2674
  }
2577
2675
  return [
2578
2676
  {
2579
2677
  type: "Agg",
2580
- imports: m,
2581
- content: C.join(`
2678
+ imports: p,
2679
+ content: b.join(`
2582
2680
  `)
2583
2681
  }
2584
2682
  ];
2585
2683
  }), e.commands._setEventCodeProvider(
2586
- (v) => {
2587
- const d = [], r = /* @__PURE__ */ new Set(), i = Object.values(v.inner), l = a(v), m = c(v);
2588
- d.push(`type ${l} struct {`);
2589
- for (const f of i)
2590
- d.push(` ${c(f)} ${s(r, f)}`);
2591
- d.push("}");
2592
- for (const f of i)
2593
- d.push(
2594
- `func (${m} ${l}) Get${a(f)} () ${s(
2595
- r,
2596
- f
2684
+ (_) => {
2685
+ const m = [], a = /* @__PURE__ */ new Set(), u = Object.values(_.inner), i = r(_), p = c(_);
2686
+ m.push(`type ${i} struct {`);
2687
+ for (const h of u)
2688
+ m.push(` ${c(h)} ${o(a, h)}`);
2689
+ m.push("}");
2690
+ for (const h of u)
2691
+ m.push(
2692
+ `func (${p} ${i}) Get${r(h)} () ${o(
2693
+ a,
2694
+ h
2597
2695
  )} {`
2598
- ), d.push(` return ${m}.${c(f)}`), d.push("}");
2599
- const C = [], p = [];
2600
- for (const f of i)
2601
- C.push(`${c(f)} ${s(r, f)}`), p.push(c(f));
2602
- return d.push(`func New${l}(${C.join(", ")}) ${l} {`), d.push(" // HACK check value"), d.push(` return ${l}{`), d.push(` ${p.join(`,
2603
- `)},`), d.push(" }"), d.push("}"), [
2696
+ ), m.push(` return ${p}.${c(h)}`), m.push("}");
2697
+ const b = [], C = [];
2698
+ for (const h of u)
2699
+ b.push(`${c(h)} ${o(a, h)}`), C.push(c(h));
2700
+ return m.push(`func New${i}(${b.join(", ")}) ${i} {`), m.push(" // HACK check value"), m.push(` return ${i}{`), m.push(` ${C.join(`,
2701
+ `)},`), m.push(" }"), m.push("}"), [
2604
2702
  {
2605
2703
  type: "Event",
2606
- imports: r,
2607
- content: d.join(`
2704
+ imports: a,
2705
+ content: m.join(`
2608
2706
  `)
2609
2707
  }
2610
2708
  ];
2611
2709
  }
2612
2710
  ), e.commands._setCodeFileProvider(() => {
2613
- const v = [], d = {}, r = [...n.value.namespace.split(/\./), n.value.moduleName], i = new j(r, `${n.value.moduleName}.go`), l = [], m = new j(r, `${n.value.moduleName}_value_object.go`), C = [];
2614
- function p(h) {
2615
- for (const u of Object.values(h)) {
2616
- if (!o(u))
2711
+ const _ = [], m = {}, a = [...n.value.namespace.split(/\./), n.value.moduleName], u = new I(a, `${n.value.moduleName}.go`), i = [], p = new I(a, `${n.value.moduleName}_value_object.go`), b = [];
2712
+ function C(w) {
2713
+ for (const f of Object.values(w)) {
2714
+ if (!s(f))
2617
2715
  continue;
2618
- const w = a(u);
2619
- if (d[`${r.join("/")}/${w}`] === !0)
2716
+ const v = r(f);
2717
+ if (m[`${a.join("/")}/${v}`] === !0)
2620
2718
  continue;
2621
- const y = e.commands._genInfoCode(u);
2622
- y.length !== 0 && (m.addImports(y[0].imports), C.push(y[0].content), C.push(""), d[`${r.join("/")}/${w}`] = !0);
2719
+ const N = e.commands._genInfoCode(f);
2720
+ N.length !== 0 && (p.addImports(N[0].imports), b.push(N[0].content), b.push(""), m[`${a.join("/")}/${v}`] = !0);
2623
2721
  }
2624
2722
  }
2625
- const f = e.states.designer.value._getContext().getCommands();
2626
- for (const h of f) {
2627
- p(h.inner);
2628
- const u = e.commands._genCommandCode(h);
2629
- for (const w of u)
2630
- d[w.content] !== !0 && (i.addImports(w.imports), l.push(w.content));
2723
+ const h = e.states.designer.value._getContext().getCommands();
2724
+ for (const w of h) {
2725
+ C(w.inner);
2726
+ const f = e.commands._genCommandCode(w);
2727
+ for (const v of f)
2728
+ m[v.content] !== !0 && (u.addImports(v.imports), i.push(v.content));
2631
2729
  }
2632
2730
  const $ = e.states.designer.value._getContext().getFacadeCommands();
2633
- for (const h of $) {
2634
- p(h.inner);
2635
- const u = e.commands._genFacadeCommandCode(h);
2636
- for (const w of u)
2637
- d[w.content] !== !0 && (i.addImports(w.imports), l.push(w.content));
2731
+ for (const w of $) {
2732
+ C(w.inner);
2733
+ const f = e.commands._genFacadeCommandCode(w);
2734
+ for (const v of f)
2735
+ m[v.content] !== !0 && (u.addImports(v.imports), i.push(v.content));
2638
2736
  }
2639
- const _ = e.states.designer.value._getContext().getAggs();
2640
- for (const h of _) {
2641
- p(h.inner);
2642
- const u = e.commands._genAggCode(h);
2643
- for (const w of u)
2644
- d[w.content] !== !0 && (i.addImports(w.imports), l.push(w.content));
2737
+ const l = e.states.designer.value._getContext().getAggs();
2738
+ for (const w of l) {
2739
+ C(w.inner);
2740
+ const f = e.commands._genAggCode(w);
2741
+ for (const v of f)
2742
+ m[v.content] !== !0 && (u.addImports(v.imports), i.push(v.content));
2645
2743
  }
2646
- const b = e.states.designer.value._getContext().getEvents();
2647
- for (const h of b) {
2648
- p(h.inner);
2649
- const u = e.commands._genEventCode(h);
2650
- for (const w of u)
2651
- d[w.content] !== !0 && (i.addImports(w.imports), l.push(w.content));
2744
+ const d = e.states.designer.value._getContext().getEvents();
2745
+ for (const w of d) {
2746
+ C(w.inner);
2747
+ const f = e.commands._genEventCode(w);
2748
+ for (const v of f)
2749
+ m[v.content] !== !0 && (u.addImports(v.imports), i.push(v.content));
2652
2750
  }
2653
- return i.appendContentln(`package ${n.value.moduleName}`), i.appendContentln(""), i.getImports().length > 0 && (i.appendContentln("import ("), i.appendContentln(` ${[...i.getImports()].join(`
2654
- `)}`), i.appendContentln(")")), i.appendContentln(l.join(`
2655
- `)), m.appendContentln(`package ${n.value.moduleName}`), m.appendContentln(""), m.getImports().length > 0 && (m.appendContentln("import ("), m.appendContentln(` ${[...m.getImports()].map((h) => `"${h}"`).join(`
2656
- `)}`), m.appendContentln(")"), m.appendContentln("")), m.appendContentln(C.join(`
2657
- `)), v.push(i), v.push(m), v;
2751
+ return u.appendContentln(`package ${n.value.moduleName}`), u.appendContentln(""), u.getImports().length > 0 && (u.appendContentln("import ("), u.appendContentln(` ${[...u.getImports()].join(`
2752
+ `)}`), u.appendContentln(")")), u.appendContentln(i.join(`
2753
+ `)), p.appendContentln(`package ${n.value.moduleName}`), p.appendContentln(""), p.getImports().length > 0 && (p.appendContentln("import ("), p.appendContentln(` ${[...p.getImports()].map((w) => `"${w}"`).join(`
2754
+ `)}`), p.appendContentln(")"), p.appendContentln("")), p.appendContentln(b.join(`
2755
+ `)), _.push(u), _.push(p), _;
2658
2756
  });
2659
2757
  }
2660
- })), G = Ne.CSharpGeneratorAddition, xo = ue.createHotSwapPlugin(() => {
2758
+ })), K = Ee.CSharpGeneratorAddition, Po = pe.createHotSwapPlugin(() => {
2661
2759
  const e = " ";
2662
- function n(t, o = 1) {
2760
+ function n(t, s = 1) {
2663
2761
  return t.split(`
2664
- `).map((s) => e.repeat(o) + s).join(`
2762
+ `).map((o) => e.repeat(s) + o).join(`
2665
2763
  `);
2666
2764
  }
2667
2765
  return {
@@ -2669,259 +2767,289 @@ const O = be.JavaGeneratorAddition, Oo = ue.createHotSwapPlugin(() => {
2669
2767
  t.commands.clearCaches(), t.commands._setCommandCodeProvider(() => []), t.commands._setFacadeCommandCodeProvider(() => []), t.commands._setAggCodeProvider(() => []), t.commands._setEventCodeProvider(() => []), t.commands._setReadModelCodeProvider(() => []), t.commands._setCodeFileProvider(() => []), t.commands.setContext({});
2670
2768
  },
2671
2769
  mount({ api: t }) {
2672
- const o = t.states.context, s = t.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((r) => N.stringToLowerCamel(r));
2673
- function a(r) {
2674
- return !s.includes(N.stringToLowerCamel(r._attributes.name));
2770
+ const s = t.states.context, o = t.states.designer.value._getContext().getDesignerOptions().ignoreValueObjects.map((a) => y.stringToLowerCamel(a));
2771
+ function r(a) {
2772
+ return !o.includes(y.stringToLowerCamel(a._attributes.name));
2675
2773
  }
2676
- function c(r, i) {
2677
- return a(i) ? N.stringToUpperCamel(i._attributes.name) : d(r, i);
2774
+ function c(a, u) {
2775
+ return r(u) ? y.stringToUpperCamel(u._attributes.name) : m(a, u);
2678
2776
  }
2679
- function g(r) {
2680
- return N.stringToUpperCamel(r._attributes.name);
2777
+ function g(a) {
2778
+ return y.stringToUpperCamel(a._attributes.name);
2681
2779
  }
2682
- function v(r) {
2683
- return r.has(G.RecordStruct) ? " struct" : "";
2780
+ function _(a) {
2781
+ return a.has(K.RecordStruct) ? " struct" : "";
2684
2782
  }
2685
- function d(r, i) {
2686
- const l = o.value.additions, m = N.stringToLowerSnake(i._attributes.name).replace(/_/, " ");
2687
- return /\b(time|timestamp|date|deadline|expire)\b/.test(m) ? l.has(G.Timezone) ? "System.DateTimeOffset" : "System.DateTime" : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(m) ? "int" : /\b(price)$/.test(m) ? "decimal" : /^(if|is)\b/.test(m) ? "bool" : Ee(i) && (i._attributes.type === "Id" || i._attributes.type === "Version") ? "long" : "string";
2783
+ function m(a, u) {
2784
+ const i = s.value.additions, p = y.stringToLowerSnake(u._attributes.name).replace(/_/, " ");
2785
+ return /\b(time|timestamp|date|deadline|expire)\b/.test(p) ? i.has(K.Timezone) ? "System.DateTimeOffset" : "System.DateTime" : /\b(enum|gender|sex|count|amount|num|number|flag|times)\b/.test(p) ? "int" : /\b(price)$/.test(p) ? "decimal" : /^(if|is)\b/.test(p) ? "bool" : Se(u) && (u._attributes.type === "Id" || u._attributes.type === "Version" || /\b(id|identifier|ver|version)$/.test(p)) ? "long" : "string";
2688
2786
  }
2689
2787
  t.commands._setInfoCodeProvider(
2690
- (r) => {
2691
- const i = o.value.additions, l = /* @__PURE__ */ new Set(), m = [];
2692
- return m.push(
2693
- `public record${v(i)} ${g(r)}(${d(
2694
- l,
2695
- r
2788
+ (a) => {
2789
+ const u = s.value.additions, i = /* @__PURE__ */ new Set(), p = [];
2790
+ return p.push(
2791
+ `public record${_(u)} ${g(a)}(${m(
2792
+ i,
2793
+ a
2696
2794
  )} value);`
2697
2795
  ), [
2698
2796
  {
2699
2797
  type: "Info",
2700
- content: m.join(`
2798
+ content: p.join(`
2701
2799
  `),
2702
- imports: l
2800
+ imports: i
2703
2801
  }
2704
2802
  ];
2705
2803
  }
2706
2804
  ), t.commands._setCommandCodeProvider(
2707
- (r) => {
2708
- const i = [], l = o.value.additions, m = /* @__PURE__ */ new Set(), C = g(r);
2805
+ (a) => {
2806
+ const u = [], i = s.value.additions, p = /* @__PURE__ */ new Set(), b = g(a);
2709
2807
  {
2710
- const p = [], f = Object.values(r.inner);
2711
- p.push(`public record${v(l)} ${C}`), p.push("(");
2808
+ const C = [], h = Object.values(a.inner);
2809
+ C.push(`public record${_(i)} ${b}`), C.push("(");
2712
2810
  const $ = [];
2713
- for (const _ of f) {
2714
- const b = g(_);
2715
- $.push(`${c(m, _)} ${N.upperFirst(b)}`);
2811
+ for (const l of h) {
2812
+ const d = g(l);
2813
+ $.push(`${c(p, l)} ${y.upperFirst(d)}`);
2716
2814
  }
2717
- p.push(` ${$.join(`,
2718
- `)}`), p.push(")"), p.push("{"), p.push("}"), i.push({
2815
+ C.push(` ${$.join(`,
2816
+ `)}`), C.push(")"), C.push("{"), C.push("}"), u.push({
2719
2817
  type: "Command",
2720
- content: p.join(`
2818
+ content: C.join(`
2721
2819
  `),
2722
- imports: m
2820
+ imports: p
2723
2821
  });
2724
2822
  }
2725
2823
  {
2726
- const p = l.has(G.CommandHandlerInterface) ? ` : ${o.value.commandHandlerInterface}` : "", f = [];
2727
- f.push(`public class ${C}Handler${p}`), f.push("{"), f.push(` public void Handle(${C} command)`), f.push(" {"), f.push(" // HACK implement"), f.push(" }"), f.push("}"), i.push({
2824
+ const C = i.has(K.CommandHandlerInterface) ? ` : ${s.value.commandHandlerInterface}` : "", h = [];
2825
+ h.push(`public class ${b}Handler${C}`), h.push("{"), h.push(` public void Handle(${b} command)`), h.push(" {"), h.push(" // HACK implement"), h.push(" }"), h.push("}"), u.push({
2728
2826
  type: "CommandHandler",
2729
- content: f.join(`
2827
+ content: h.join(`
2730
2828
  `),
2731
- imports: m
2829
+ imports: p
2732
2830
  });
2733
2831
  }
2734
- return i;
2832
+ return u;
2833
+ }
2834
+ ), t.commands._setFacadeCommandCodeProvider(
2835
+ (a) => {
2836
+ const u = [], i = s.value.additions, p = /* @__PURE__ */ new Set(), b = g(a);
2837
+ {
2838
+ const C = [], h = Object.values(a.inner);
2839
+ C.push(`public record${_(i)} ${b}`), C.push("(");
2840
+ const $ = [];
2841
+ for (const l of h) {
2842
+ const d = g(l);
2843
+ $.push(`${c(p, l)} ${y.upperFirst(d)}`);
2844
+ }
2845
+ C.push(` ${$.join(`,
2846
+ `)}`), C.push(")"), C.push("{"), C.push("}"), u.push({
2847
+ type: "FacadeCommand",
2848
+ content: C.join(`
2849
+ `),
2850
+ imports: p
2851
+ });
2852
+ }
2853
+ {
2854
+ const C = i.has(K.CommandHandlerInterface) ? ` : ${s.value.commandHandlerInterface}` : "", h = [];
2855
+ h.push(`public class ${b}Handler${C}`), h.push("{"), h.push(` public void Handle(${b} command)`), h.push(" {"), h.push(" // HACK implement"), h.push(" }"), h.push("}"), u.push({
2856
+ type: "FacadeCommandHandler",
2857
+ content: h.join(`
2858
+ `),
2859
+ imports: p
2860
+ });
2861
+ }
2862
+ return u;
2735
2863
  }
2736
2864
  ), t.commands._setAggCodeProvider(
2737
- (r) => {
2738
- const i = [], l = t.states.designer.value, m = o.value.additions;
2865
+ (a) => {
2866
+ const u = [], i = t.states.designer.value, p = s.value.additions;
2739
2867
  {
2740
- const C = /* @__PURE__ */ new Set(), p = [], f = m.has(G.AggInterface) ? ` : ${o.value.aggInterface}` : "";
2741
- p.push(`public interface I${g(r)}${f}`), p.push("{");
2742
- const $ = [], _ = [...l._getContext().getAssociationMap()[r._attributes.__id]].filter((b) => b._attributes.rule === "Command" || b._attributes.rule === "FacadeCommand");
2743
- for (const b of _) {
2744
- const h = g(b);
2745
- $.push(`void Handle${h}(${h} command);`);
2868
+ const b = /* @__PURE__ */ new Set(), C = [], h = p.has(K.AggInterface) ? ` : ${s.value.aggInterface}` : "";
2869
+ C.push(`public interface I${g(a)}${h}`), C.push("{");
2870
+ const $ = [], l = [...i._getContext().getAssociationMap()[a._attributes.__id]].filter((d) => d._attributes.rule === "Command" || d._attributes.rule === "FacadeCommand");
2871
+ for (const d of l) {
2872
+ const w = g(d);
2873
+ $.push(`void Handle${w}(${w} command);`);
2746
2874
  }
2747
- p.push(` ${$.join(`
2875
+ C.push(` ${$.join(`
2748
2876
 
2749
- `)}`), p.push("}"), p.push(""), i.push({
2877
+ `)}`), C.push("}"), C.push(""), u.push({
2750
2878
  type: "Agg",
2751
- content: p.join(`
2879
+ content: C.join(`
2752
2880
  `),
2753
- imports: C
2881
+ imports: b
2754
2882
  });
2755
2883
  }
2756
2884
  {
2757
- const C = /* @__PURE__ */ new Set(), p = [], f = g(r), $ = Object.values(r.inner), _ = m.has(G.AggInterface) ? `, ${o.value.aggInterface}` : "";
2758
- if (m.has(G.PrimaryConstructor)) {
2759
- const b = [...l._getContext().getAssociationMap()[r._attributes.__id]].filter((w) => w._attributes.rule === "Command" || w._attributes.rule === "FacadeCommand"), h = [];
2760
- for (const w of $) {
2761
- const y = g(w);
2762
- h.push(`${c(C, w)} ${N.lowerFirst(y)}`);
2885
+ const b = /* @__PURE__ */ new Set(), C = [], h = g(a), $ = Object.values(a.inner), l = p.has(K.AggInterface) ? `, ${s.value.aggInterface}` : "";
2886
+ if (p.has(K.PrimaryConstructor)) {
2887
+ const d = [...i._getContext().getAssociationMap()[a._attributes.__id]].filter((v) => v._attributes.rule === "Command" || v._attributes.rule === "FacadeCommand"), w = [];
2888
+ for (const v of $) {
2889
+ const N = g(v);
2890
+ w.push(`${c(b, v)} ${y.lowerFirst(N)}`);
2763
2891
  }
2764
- p.push(`public class ${f}`), p.push("("), p.push(` ${h.join(`,
2765
- `)}`), p.push(`): I${f}${_}`), p.push("{");
2766
- for (const w of $) {
2767
- const y = g(w);
2768
- p.push(
2769
- ` public ${c(C, w)} ${N.upperFirst(
2770
- y
2771
- )} { get; private set; } = ${N.lowerFirst(y)};`
2772
- ), p.push("");
2892
+ C.push(`public class ${h}`), C.push("("), C.push(` ${w.join(`,
2893
+ `)}`), C.push(`): I${h}${l}`), C.push("{");
2894
+ for (const v of $) {
2895
+ const N = g(v);
2896
+ C.push(
2897
+ ` public ${c(b, v)} ${y.upperFirst(
2898
+ N
2899
+ )} { get; private set; } = ${y.lowerFirst(N)};`
2900
+ ), C.push("");
2773
2901
  }
2774
- const u = [];
2775
- for (const w of b) {
2776
- const y = g(w);
2777
- u.push(`public void Handle${y}(${y} command)`), u.push("{"), u.push(" // HACK implement"), u.push("}"), u.push("");
2902
+ const f = [];
2903
+ for (const v of d) {
2904
+ const N = g(v);
2905
+ f.push(`public void Handle${N}(${N} command)`), f.push("{"), f.push(" // HACK implement"), f.push("}"), f.push("");
2778
2906
  }
2779
- p.push(` ${u.join(`
2780
- `)}`), p.push("}");
2907
+ C.push(` ${f.join(`
2908
+ `)}`), C.push("}");
2781
2909
  } else {
2782
- const b = [...l._getContext().getAssociationMap()[r._attributes.__id]].filter((w) => w._attributes.rule === "Command" || w._attributes.rule === "FacadeCommand");
2783
- p.push(`public class ${f} : I${f}${_}`), p.push("{");
2784
- for (const w of $) {
2785
- const y = g(w);
2786
- p.push(
2787
- ` public ${c(C, w)} ${N.lowerFirst(
2788
- y
2910
+ const d = [...i._getContext().getAssociationMap()[a._attributes.__id]].filter((v) => v._attributes.rule === "Command" || v._attributes.rule === "FacadeCommand");
2911
+ C.push(`public class ${h} : I${h}${l}`), C.push("{");
2912
+ for (const v of $) {
2913
+ const N = g(v);
2914
+ C.push(
2915
+ ` public ${c(b, v)} ${y.lowerFirst(
2916
+ N
2789
2917
  )} { get; private set; }`
2790
2918
  );
2791
2919
  }
2792
- p.push("");
2793
- const h = [];
2794
- for (const w of $) {
2795
- const y = g(w);
2796
- h.push(`${c(C, w)} ${y}`);
2920
+ C.push("");
2921
+ const w = [];
2922
+ for (const v of $) {
2923
+ const N = g(v);
2924
+ w.push(`${c(b, v)} ${N}`);
2797
2925
  }
2798
- p.push(` public ${f}(${h.join(", ")})`), p.push(" {");
2799
- for (const w of $) {
2800
- const y = g(w);
2801
- p.push(` ${y} = ${N.lowerFirst(y)};`);
2926
+ C.push(` public ${h}(${w.join(", ")})`), C.push(" {");
2927
+ for (const v of $) {
2928
+ const N = g(v);
2929
+ C.push(` ${N} = ${y.lowerFirst(N)};`);
2802
2930
  }
2803
- p.push(" }");
2804
- const u = [];
2805
- for (const w of b) {
2806
- const y = g(w);
2807
- u.push(`public void Handle${y}(${y} command)`), u.push("{"), u.push(" // HACK implement"), u.push("}"), u.push("");
2931
+ C.push(" }");
2932
+ const f = [];
2933
+ for (const v of d) {
2934
+ const N = g(v);
2935
+ f.push(`public void Handle${N}(${N} command)`), f.push("{"), f.push(" // HACK implement"), f.push("}"), f.push("");
2808
2936
  }
2809
- p.push(` ${u.join(`
2810
- `)}`), p.push("}");
2937
+ C.push(` ${f.join(`
2938
+ `)}`), C.push("}");
2811
2939
  }
2812
- i.push({
2940
+ u.push({
2813
2941
  type: "AggImpl",
2814
- content: p.join(`
2942
+ content: C.join(`
2815
2943
  `),
2816
- imports: C
2944
+ imports: b
2817
2945
  });
2818
2946
  }
2819
- return i;
2947
+ return u;
2820
2948
  }
2821
2949
  ), t.commands._setEventCodeProvider(
2822
- (r) => {
2823
- const i = o.value.additions, l = g(r), m = /* @__PURE__ */ new Set(), C = Object.values(r.inner), p = [];
2824
- p.push(`public record${v(i)} ${l}`), p.push("(");
2825
- const f = [];
2826
- for (const $ of C) {
2827
- const _ = g($);
2828
- f.push(`${c(m, $)} ${N.upperFirst(_)}`);
2950
+ (a) => {
2951
+ const u = s.value.additions, i = g(a), p = /* @__PURE__ */ new Set(), b = Object.values(a.inner), C = [];
2952
+ C.push(`public record${_(u)} ${i}`), C.push("(");
2953
+ const h = [];
2954
+ for (const $ of b) {
2955
+ const l = g($);
2956
+ h.push(`${c(p, $)} ${y.upperFirst(l)}`);
2829
2957
  }
2830
- return p.push(` ${f.join(`,
2831
- `)}`), p.push(")"), p.push("{"), p.push("}"), [
2958
+ return C.push(` ${h.join(`,
2959
+ `)}`), C.push(")"), C.push("{"), C.push("}"), [
2832
2960
  {
2833
2961
  type: "Event",
2834
- content: p.join(`
2962
+ content: C.join(`
2835
2963
  `),
2836
- imports: m
2964
+ imports: p
2837
2965
  }
2838
2966
  ];
2839
2967
  }
2840
2968
  ), t.commands._setReadModelCodeProvider(() => []), t.commands._setCodeFileProvider(() => {
2841
- const r = [], i = {}, l = [...o.value.namespace.split(/\./), N.stringToUpperCamel(o.value.moduleName)];
2842
- function m(_) {
2843
- for (const b of Object.values(_)) {
2844
- if (!a(b))
2969
+ const a = [], u = {}, i = [...s.value.namespace.split(/\./), y.stringToUpperCamel(s.value.moduleName)];
2970
+ function p(l) {
2971
+ for (const d of Object.values(l)) {
2972
+ if (!r(d))
2845
2973
  continue;
2846
- const h = g(b) + ".cs";
2847
- if (i[`${l.join("/")}/${h}`] === !0)
2974
+ const w = g(d) + ".cs";
2975
+ if (u[`${i.join("/")}/${w}`] === !0)
2848
2976
  continue;
2849
- const u = t.commands._genInfoCode(b);
2850
- if (u.length === 0)
2977
+ const f = t.commands._genInfoCode(d);
2978
+ if (f.length === 0)
2851
2979
  continue;
2852
- const w = new j(l, h);
2853
- for (const y of u[0].imports)
2854
- w.appendContentln(`using ${y};`);
2855
- w.appendContentln(""), w.appendContentln(
2856
- `namespace ${o.value.namespace}.${N.stringToUpperCamel(o.value.moduleName)}`
2857
- ), w.appendContentln("{"), w.appendContentln(n(u[0].content)), w.appendContentln("}"), r.push(w), i[`${l.join("/")}/${h}`] = !0;
2980
+ const v = new I(i, w);
2981
+ for (const N of f[0].imports)
2982
+ v.appendContentln(`using ${N};`);
2983
+ v.appendContentln(""), v.appendContentln(
2984
+ `namespace ${s.value.namespace}.${y.stringToUpperCamel(s.value.moduleName)}`
2985
+ ), v.appendContentln("{"), v.appendContentln(n(f[0].content)), v.appendContentln("}"), a.push(v), u[`${i.join("/")}/${w}`] = !0;
2858
2986
  }
2859
2987
  }
2860
- const C = t.states.designer.value._getContext().getCommands();
2861
- for (const _ of C) {
2862
- m(_.inner);
2863
- const b = g(_) + ".cs", h = t.commands._genCommandCode(_), u = new j(l, b);
2864
- for (const w of h)
2865
- if (w.type === "Command") {
2866
- u.addImports(w.imports);
2867
- for (const y of w.imports)
2868
- u.appendContentln(`using ${y};`);
2869
- u.appendContentln(""), u.appendContentln(
2870
- `namespace ${o.value.namespace}.${N.stringToUpperCamel(o.value.moduleName)}`
2871
- ), u.appendContentln("{"), u.appendContentln(n(w.content)), u.appendContentln("}");
2988
+ const b = t.states.designer.value._getContext().getCommands();
2989
+ for (const l of b) {
2990
+ p(l.inner);
2991
+ const d = g(l) + ".cs", w = t.commands._genCommandCode(l), f = new I(i, d);
2992
+ for (const v of w)
2993
+ if (v.type === "Command") {
2994
+ f.addImports(v.imports);
2995
+ for (const N of v.imports)
2996
+ f.appendContentln(`using ${N};`);
2997
+ f.appendContentln(""), f.appendContentln(
2998
+ `namespace ${s.value.namespace}.${y.stringToUpperCamel(s.value.moduleName)}`
2999
+ ), f.appendContentln("{"), f.appendContentln(n(v.content)), f.appendContentln("}");
2872
3000
  }
2873
- r.push(u);
3001
+ a.push(f);
2874
3002
  }
2875
- const p = t.states.designer.value._getContext().getFacadeCommands();
2876
- for (const _ of p) {
2877
- m(_.inner);
2878
- const b = g(_) + ".cs", h = t.commands._genFacadeCommandCode(_), u = new j(l, b);
2879
- u.addImports(h[0].imports);
2880
- for (const w of h[0].imports)
2881
- u.appendContentln(`using ${w};`);
2882
- u.appendContentln(""), u.appendContentln(
2883
- `namespace ${o.value.namespace}.${N.stringToUpperCamel(o.value.moduleName)}`
2884
- ), u.appendContentln("{"), u.appendContentln(n(h[0].content)), u.appendContentln("}"), r.push(u);
3003
+ const C = t.states.designer.value._getContext().getFacadeCommands();
3004
+ for (const l of C) {
3005
+ p(l.inner);
3006
+ const d = g(l) + ".cs", w = t.commands._genFacadeCommandCode(l), f = new I(i, d);
3007
+ f.addImports(w[0].imports);
3008
+ for (const v of w[0].imports)
3009
+ f.appendContentln(`using ${v};`);
3010
+ f.appendContentln(""), f.appendContentln(
3011
+ `namespace ${s.value.namespace}.${y.stringToUpperCamel(s.value.moduleName)}`
3012
+ ), f.appendContentln("{"), f.appendContentln(n(w[0].content)), f.appendContentln("}"), a.push(f);
2885
3013
  }
2886
- const f = t.states.designer.value._getContext().getAggs();
2887
- for (const _ of f) {
2888
- m(_.inner);
2889
- const b = t.commands._genAggCode(_), h = g(_) + ".cs", u = new j(l, h);
2890
- for (const w of b) {
2891
- u.addImports(w.imports);
2892
- for (const y of w.imports)
2893
- u.appendContentln(`using ${y};`);
2894
- u.appendContentln("");
3014
+ const h = t.states.designer.value._getContext().getAggs();
3015
+ for (const l of h) {
3016
+ p(l.inner);
3017
+ const d = t.commands._genAggCode(l), w = g(l) + ".cs", f = new I(i, w);
3018
+ for (const v of d) {
3019
+ f.addImports(v.imports);
3020
+ for (const N of v.imports)
3021
+ f.appendContentln(`using ${N};`);
3022
+ f.appendContentln("");
2895
3023
  }
2896
- u.appendContentln(
2897
- `namespace ${o.value.namespace}.${N.stringToUpperCamel(o.value.moduleName)}`
2898
- ), u.appendContentln("{");
2899
- for (const w of b)
2900
- u.appendContentln(n(w.content));
2901
- u.appendContentln("}"), r.push(u);
3024
+ f.appendContentln(
3025
+ `namespace ${s.value.namespace}.${y.stringToUpperCamel(s.value.moduleName)}`
3026
+ ), f.appendContentln("{");
3027
+ for (const v of d)
3028
+ f.appendContentln(n(v.content));
3029
+ f.appendContentln("}"), a.push(f);
2902
3030
  }
2903
3031
  const $ = t.states.designer.value._getContext().getEvents();
2904
- for (const _ of $) {
2905
- m(_.inner);
2906
- const b = g(_) + ".cs", h = t.commands._genEventCode(_), u = new j(l, b);
2907
- u.addImports(h[0].imports);
2908
- for (const w of h[0].imports)
2909
- u.appendContentln(`using ${w};`);
2910
- u.appendContentln(""), u.appendContentln(
2911
- `namespace ${o.value.namespace}.${N.stringToUpperCamel(o.value.moduleName)}`
2912
- ), u.appendContentln("{"), u.appendContentln(n(h[0].content)), u.appendContentln("}"), r.push(u);
3032
+ for (const l of $) {
3033
+ p(l.inner);
3034
+ const d = g(l) + ".cs", w = t.commands._genEventCode(l), f = new I(i, d);
3035
+ f.addImports(w[0].imports);
3036
+ for (const v of w[0].imports)
3037
+ f.appendContentln(`using ${v};`);
3038
+ f.appendContentln(""), f.appendContentln(
3039
+ `namespace ${s.value.namespace}.${y.stringToUpperCamel(s.value.moduleName)}`
3040
+ ), f.appendContentln("{"), f.appendContentln(n(w[0].content)), f.appendContentln("}"), a.push(f);
2913
3041
  }
2914
- return r;
3042
+ return a;
2915
3043
  });
2916
3044
  }
2917
3045
  };
2918
3046
  });
2919
3047
  export {
2920
- xo as GENERATOR_CSHARP_PLUGIN,
2921
- Io as GENERATOR_GO_PLUGIN,
3048
+ Po as GENERATOR_CSHARP_PLUGIN,
3049
+ To as GENERATOR_GO_PLUGIN,
2922
3050
  Oo as GENERATOR_JAVA_PLUGIN,
2923
- Ao as GENERATOR_KOTLIN_PLUGIN,
2924
- ue as GeneratorPliginHelper,
2925
- jo as define,
2926
- So as useGeneratorAgg
3051
+ xo as GENERATOR_KOTLIN_PLUGIN,
3052
+ pe as GeneratorPliginHelper,
3053
+ Io as define,
3054
+ Ao as useGeneratorAgg
2927
3055
  };