@useinsider/guido 3.5.1-beta.62862ff → 3.5.1-beta.a51b847

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
- import { ModuleFolderDefaults as p } from "../../enums/defaults.js";
2
- import { object as o, number as n, optional as e, string as t, picklist as l, pipe as S, minLength as f, nullish as k, custom as h, boolean as a, array as c, record as y, literal as i, looseObject as g, variant as R, union as b, unknown as s } from "../../node_modules/valibot/dist/index.js";
1
+ import { ModuleFolderDefaults as S } from "../../enums/defaults.js";
2
+ import { object as o, number as n, optional as e, string as t, picklist as l, pipe as p, minLength as b, custom as h, boolean as a, array as c, record as k, literal as i, looseObject as y, variant as g, union as f, unknown as s } from "../../node_modules/valibot/dist/index.js";
3
3
  const d = {
4
4
  /** Promotional/marketing emails */
5
5
  PROMOTIONAL: 1,
@@ -12,33 +12,29 @@ const d = {
12
12
  ARCHITECT: 49,
13
13
  /** Unsubscribe page builder */
14
14
  UNSUBSCRIBE_PAGES: 97
15
- }, C = o({
16
- /**
17
- * Unique identifier for the template being edited.
18
- *
19
- * Optional: a brand-new newsletter being designed has no saved template yet,
20
- * so hosts may pass `null`/`undefined`. Normalizes to `''` to match the
21
- * library's own internal handling (config getter, state bridge, editor stores
22
- * all default templateId to `''`).
23
- */
24
- templateId: k(t(), ""),
15
+ }, R = o({
16
+ /** Unique identifier for the template being edited */
17
+ templateId: p(
18
+ t(),
19
+ b(1, "templateId is required")
20
+ ),
25
21
  /** Unique identifier for the user editing the template */
26
- userId: S(
22
+ userId: p(
27
23
  t(),
28
- f(1, "userId is required")
24
+ b(1, "userId is required")
29
25
  ),
30
26
  /** Optional variation ID for A/B testing */
31
27
  variationId: e(t())
32
- }), T = o({
28
+ }), C = o({
33
29
  /** Fallback font name (e.g., "Georgia") */
34
30
  name: t(),
35
31
  /** Fallback font family (e.g., "serif" or "sans-serif") */
36
32
  family: t()
37
- }), A = o({
33
+ }), T = o({
38
34
  /** Partner/organization name (required) */
39
- name: S(
35
+ name: p(
40
36
  t(),
41
- f(1, "partner.name is required")
37
+ b(1, "partner.name is required")
42
38
  ),
43
39
  /** Product type identifier */
44
40
  productType: e(
@@ -57,8 +53,8 @@ const d = {
57
53
  /** Display name for the current user */
58
54
  username: e(t(), "Guido User"),
59
55
  /** Fallback font settings from partner settings — used to match backend size calculation */
60
- fallbackFont: e(T)
61
- }), I = o({
56
+ fallbackFont: e(C)
57
+ }), A = o({
62
58
  /** Display text for the dynamic content */
63
59
  text: t(),
64
60
  /** Template variable value (e.g., {{username}}) */
@@ -72,11 +68,11 @@ const d = {
72
68
  value: t()
73
69
  })
74
70
  )
75
- }), E = g({
71
+ }), I = y({
76
72
  /** Block ID (matches the dictionary key and the legacy HTML element id) */
77
73
  id: e(n()),
78
74
  /** Decimal places for price display (legacy data may use string or number) */
79
- decimalCount: e(b([t(), n()])),
75
+ decimalCount: e(f([t(), n()])),
80
76
  /** Pinned product IDs (empty array when filter-driven) */
81
77
  productIds: e(c(s())),
82
78
  /** Whether the block requested live products at send time */
@@ -110,10 +106,10 @@ const d = {
110
106
  /** Block type marker used by some legacy variants */
111
107
  blockType: e(t()),
112
108
  /** Size variant marker (legacy data may use string or number) */
113
- size: e(b([t(), n()])),
109
+ size: e(f([t(), n()])),
114
110
  /** Vertical responsiveness flag (legacy size=1 variants) */
115
111
  verticalResponsiveness: e(a())
116
- }), L = o({
112
+ }), E = o({
117
113
  /**
118
114
  * Legacy recommendation block configs keyed by block ID.
119
115
  * Pass this when loading a template authored with the v1
@@ -121,17 +117,17 @@ const d = {
121
117
  * strategy, currency, locale, and layout data.
122
118
  */
123
119
  recommendationConfigs: e(
124
- y(t(), E),
120
+ k(t(), I),
125
121
  {}
126
122
  )
127
- }), O = o({
123
+ }), L = o({
128
124
  /** Initial HTML content */
129
125
  html: e(t(), ""),
130
126
  /** Initial CSS content */
131
127
  css: e(t(), ""),
132
128
  /** Preselected dynamic content items */
133
129
  preselectedDynamicContent: e(
134
- c(I),
130
+ c(A),
135
131
  []
136
132
  ),
137
133
  /** Valid custom field attribute names from the partner's categorized fields */
@@ -141,13 +137,13 @@ const d = {
141
137
  /** Force recreate template in Stripo storage (use true when updating externally modified templates) */
142
138
  forceRecreate: e(a(), !1),
143
139
  /** Migration-only inputs (legacy block configs) */
144
- migration: e(L, {})
145
- }), v = o({
140
+ migration: e(E, {})
141
+ }), O = o({
146
142
  /** Sender display name */
147
143
  senderName: e(t(), ""),
148
144
  /** Email subject line */
149
145
  subject: e(t(), "")
150
- }), M = o({
146
+ }), v = o({
151
147
  /** Locale for the editor UI */
152
148
  locale: e(t(), "en"),
153
149
  /** Path to translations object */
@@ -155,17 +151,17 @@ const d = {
155
151
  /** Migration date for template compatibility */
156
152
  migrationDate: e(n(), 1759696858),
157
153
  /** Email header settings */
158
- emailHeader: e(v, { senderName: "", subject: "" }),
154
+ emailHeader: e(O, { senderName: "", subject: "" }),
159
155
  /** Folder name for user-saved modules (used by Stripo plugin panel for path construction) */
160
- savedModulesFolderName: e(t(), p.SAVED_MODULES),
156
+ savedModulesFolderName: e(t(), S.SAVED_MODULES),
161
157
  /** Folder name for default/prebuilt modules (used by Stripo plugin panel for path construction) */
162
- defaultModulesFolderName: e(t(), p.DEFAULT_MODULES)
163
- }), P = o({
158
+ defaultModulesFolderName: e(t(), S.DEFAULT_MODULES)
159
+ }), M = o({
164
160
  /** Whether to show the header bar */
165
161
  showHeader: e(a(), !0),
166
162
  /** Custom label for back button (if shown) */
167
163
  backButtonLabel: e(t())
168
- }), N = o({
164
+ }), P = o({
169
165
  /** Enable dynamic content insertion */
170
166
  dynamicContent: e(a(), !0),
171
167
  /** Enable save as template functionality */
@@ -184,7 +180,7 @@ const d = {
184
180
  liquidSyntax: e(a(), !1),
185
181
  /** Enable autosave (3-min interval + tab-hide). User toggles on/off from the header. */
186
182
  autosave: e(a(), !1)
187
- }), D = l([
183
+ }), N = l([
188
184
  "amp-accordion",
189
185
  "amp-carousel",
190
186
  "amp-form-controls",
@@ -198,7 +194,7 @@ const d = {
198
194
  "text-block",
199
195
  "timer-block",
200
196
  "video-block"
201
- ]), x = l([
197
+ ]), D = l([
202
198
  "dynamic-content",
203
199
  "checkbox-block",
204
200
  "radio-button-block",
@@ -206,15 +202,15 @@ const d = {
206
202
  "unsubscribe-block",
207
203
  "coupon-block",
208
204
  "items-block"
209
- ]), F = o({
205
+ ]), x = o({
210
206
  /** Default blocks to exclude from the editor */
211
207
  excludeDefaults: e(
212
- c(D),
208
+ c(N),
213
209
  []
214
210
  ),
215
211
  /** Custom blocks to include in the editor */
216
212
  includeCustoms: e(
217
- c(x),
213
+ c(D),
218
214
  []
219
215
  )
220
216
  }), m = o({
@@ -224,7 +220,7 @@ const d = {
224
220
  description: e(t()),
225
221
  /** Priority for rule ordering (lower = earlier) */
226
222
  priority: n()
227
- }), U = o({
223
+ }), F = o({
228
224
  ...m.entries,
229
225
  type: i("replace"),
230
226
  /** String to search for */
@@ -233,7 +229,7 @@ const d = {
233
229
  replacement: t(),
234
230
  /** Replace all occurrences (default: false) */
235
231
  replaceAll: e(a())
236
- }), B = o({
232
+ }), U = o({
237
233
  ...m.entries,
238
234
  type: i("regex"),
239
235
  /** Regex pattern string */
@@ -242,12 +238,12 @@ const d = {
242
238
  replacement: t(),
243
239
  /** Regex flags (e.g., 'gi') */
244
240
  flags: e(t())
245
- }), w = o({
241
+ }), B = o({
246
242
  ...m.entries,
247
243
  type: i("remove"),
248
244
  /** Strings or patterns to remove */
249
245
  targets: c(t())
250
- }), H = o({
246
+ }), w = o({
251
247
  ...m.entries,
252
248
  type: i("custom"),
253
249
  /** Custom processor function */
@@ -255,17 +251,17 @@ const d = {
255
251
  (u) => typeof u == "function",
256
252
  "processor must be a function"
257
253
  )
258
- }), j = R("type", [
254
+ }), H = g("type", [
255
+ F,
259
256
  U,
260
257
  B,
261
- w,
262
- H
263
- ]), q = o({
258
+ w
259
+ ]), j = o({
264
260
  /** Custom compiler rules to apply */
265
- customRules: e(c(j), []),
261
+ customRules: e(c(H), []),
266
262
  /** Skip default compiler rules */
267
263
  ignoreDefaultRules: e(a(), !1)
268
- }), G = o({
264
+ }), q = o({
269
265
  /**
270
266
  * External validation handler called before save completes.
271
267
  * Return false to cancel the save operation.
@@ -276,51 +272,51 @@ const d = {
276
272
  "externalValidation must be a function"
277
273
  )
278
274
  )
279
- }), z = o({
275
+ }), V = o({
280
276
  // Required sections
281
277
  /** Identity configuration (required) */
282
- identity: C,
278
+ identity: R,
283
279
  /** Partner configuration (required) */
284
- partner: A,
280
+ partner: T,
285
281
  // Optional sections (with defaults)
286
282
  /** Template content and presets */
287
- template: e(O, {}),
283
+ template: e(L, {}),
288
284
  /** Editor settings */
289
- editor: e(M, {}),
285
+ editor: e(v, {}),
290
286
  /** UI configuration */
291
- ui: e(P, {}),
287
+ ui: e(M, {}),
292
288
  /** Feature toggles */
293
- features: e(N, {}),
289
+ features: e(P, {}),
294
290
  /** Block configuration */
295
- blocks: e(F, {}),
291
+ blocks: e(x, {}),
296
292
  /** Compiler configuration */
297
- compiler: e(q, {}),
293
+ compiler: e(j, {}),
298
294
  /** Callbacks and event handlers */
299
- callbacks: e(G, {})
295
+ callbacks: e(q, {})
300
296
  });
301
297
  export {
302
- F as BlocksSchema,
303
- G as CallbacksSchema,
304
- j as CompilerRuleSchema,
305
- q as CompilerSchema,
306
- x as CustomBlockTypeSchema,
307
- H as CustomRuleSchema,
308
- D as DefaultBlockTypeSchema,
309
- I as DynamicContentSchema,
310
- M as EditorSchema,
311
- v as EmailHeaderSchema,
312
- T as FallbackFontSchema,
313
- N as FeaturesSchema,
314
- z as GuidoConfigSchema,
315
- C as IdentitySchema,
316
- E as LegacyRecommendationConfigSchema,
298
+ x as BlocksSchema,
299
+ q as CallbacksSchema,
300
+ H as CompilerRuleSchema,
301
+ j as CompilerSchema,
302
+ D as CustomBlockTypeSchema,
303
+ w as CustomRuleSchema,
304
+ N as DefaultBlockTypeSchema,
305
+ A as DynamicContentSchema,
306
+ v as EditorSchema,
307
+ O as EmailHeaderSchema,
308
+ C as FallbackFontSchema,
309
+ P as FeaturesSchema,
310
+ V as GuidoConfigSchema,
311
+ R as IdentitySchema,
312
+ I as LegacyRecommendationConfigSchema,
317
313
  d as MessageType,
318
- A as PartnerSchema,
314
+ T as PartnerSchema,
319
315
  r as ProductType,
320
- B as RegexRuleSchema,
321
- w as RemoveRuleSchema,
322
- U as ReplaceRuleSchema,
323
- L as TemplateMigrationSchema,
324
- O as TemplateSchema,
325
- P as UISchema
316
+ U as RegexRuleSchema,
317
+ B as RemoveRuleSchema,
318
+ F as ReplaceRuleSchema,
319
+ E as TemplateMigrationSchema,
320
+ L as TemplateSchema,
321
+ M as UISchema
326
322
  };
@@ -5,16 +5,16 @@ import { generateCompleteFilterQuery as h } from "../extensions/Blocks/Recommend
5
5
  import { useConfigStore as x } from "../stores/config.js";
6
6
  const w = () => ({
7
7
  calculateCardWidth: ({
8
- mobileLeftPadding: s,
9
- mobileRightPadding: a,
10
- cardsInRow: c,
8
+ mobileLeftPadding: o,
9
+ mobileRightPadding: s,
10
+ cardsInRow: a,
11
11
  unresponsive: n
12
12
  }) => {
13
- const r = n ? c : 1, e = s + a + (r - 1) * b;
13
+ const r = n ? a : 1, e = o + s + (r - 1) * b;
14
14
  return (R - e) / r;
15
15
  },
16
- getRecommendationCampaignData: (s) => {
17
- const a = m(), c = Number(s), n = a.blockStates[c];
16
+ getRecommendationCampaignData: (o) => {
17
+ const s = m(), a = Number(o), n = s.blockStates[a];
18
18
  if (!n)
19
19
  return {
20
20
  textTrimming: !1,
@@ -42,37 +42,33 @@ const w = () => ({
42
42
  discountAfterTextValue: ""
43
43
  };
44
44
  },
45
- buildCampaignUrl: (s, a) => {
45
+ buildCampaignUrl: (o, s) => {
46
46
  var l;
47
- const c = m(), n = x(), r = Number(s);
47
+ const a = m(), n = x(), r = Number(o);
48
48
  let e;
49
- if (a)
50
- e = a;
49
+ if (s)
50
+ e = s;
51
51
  else {
52
- const i = c.blockStates[r];
53
- if (!i)
52
+ const c = a.blockStates[r];
53
+ if (!c)
54
54
  return "";
55
- const { recommendationConfigs: o } = i;
55
+ const { recommendationConfigs: i } = c;
56
56
  e = {
57
- strategy: o.strategy,
58
- language: o.language,
59
- currencyCode: o.currencySettings.value,
60
- size: o.size,
61
- productIds: o.productIds,
62
- filters: o.filters,
63
- shuffleProducts: o.shuffleProducts
57
+ strategy: i.strategy,
58
+ language: i.language,
59
+ currencyCode: i.currencySettings.value,
60
+ size: i.size,
61
+ productIds: i.productIds,
62
+ filters: i.filters,
63
+ shuffleProducts: i.shuffleProducts
64
64
  };
65
65
  }
66
- const f = ((l = I().find((i) => i.key === e.strategy)) == null ? void 0 : l.path) || "", t = new URLSearchParams();
67
- if (t.set("locale", e.language), t.set("currency", e.currencyCode), t.set("partnerName", n.partnerName), t.set("size", e.size), t.set("details", "true"), t.set("campaignId", n.variationId), e.strategy === "manualMerchandising") {
68
- const i = parseInt(e.size) || 6;
69
- t.set("productId", e.productIds.slice(0, i).join(","));
70
- } else e.strategy === "similarViewed" && t.set("productId", "{itemId}");
71
- e.strategy === "userBased" && t.set("userId", "{user_id}");
72
- const g = e.filters.filter((i) => i.isValid), d = h(g);
66
+ const f = ((l = I().find((c) => c.key === e.strategy)) == null ? void 0 : l.path) || "", t = new URLSearchParams();
67
+ t.set("locale", e.language), t.set("currency", e.currencyCode), t.set("partnerName", n.partnerName), t.set("size", e.size), t.set("details", "true"), t.set("campaignId", n.variationId), e.strategy === "manualMerchandising" ? t.set("productId", e.productIds.join(",")) : e.strategy === "similarViewed" && t.set("productId", "{itemId}"), e.strategy === "userBased" && t.set("userId", "{user_id}");
68
+ const g = e.filters.filter((c) => c.isValid), d = h(g);
73
69
  d && t.set("filter", d), e.shuffleProducts && t.set("shuffle", "true");
74
70
  const p = decodeURIComponent(t.toString()), u = `${C.RECOMMENDATION_API_URL}/v2/${f}?${p}`;
75
- return c.recommendationCampaignUrls[s] = u, u;
71
+ return a.recommendationCampaignUrls[o] = u, u;
76
72
  }
77
73
  });
78
74
  export {
@@ -453,7 +453,7 @@ const N = () => ({
453
453
  details: !0,
454
454
  campaignId: o.variationId
455
455
  };
456
- r.strategy === "manualMerchandising" ? a.productId = r.productIds.slice(0, s).join(",") : r.strategy === "similarViewed" && (a.productId = "{itemId}"), r.strategy === "userBased" && (a.userId = "{user_id}"), c && (a.filter = c), r.shuffleProducts && (a.shuffle = !0);
456
+ r.strategy === "manualMerchandising" ? a.productId = r.productIds.join(",") : r.strategy === "similarViewed" && (a.productId = "{itemId}"), r.strategy === "userBased" && (a.userId = "{user_id}"), c && (a.filter = c), r.shuffleProducts && (a.shuffle = !0);
457
457
  let f;
458
458
  try {
459
459
  f = await h.fetchRecommendationProducts(i, a);
@@ -1,6 +1,6 @@
1
1
  let m;
2
2
  // @__NO_SIDE_EFFECTS__
3
- function _(n) {
3
+ function j(n) {
4
4
  return {
5
5
  lang: (n == null ? void 0 : n.lang) ?? (m == null ? void 0 : m.lang),
6
6
  message: n == null ? void 0 : n.message,
@@ -8,30 +8,30 @@ function _(n) {
8
8
  abortPipeEarly: (n == null ? void 0 : n.abortPipeEarly) ?? (m == null ? void 0 : m.abortPipeEarly)
9
9
  };
10
10
  }
11
- let x;
11
+ let d;
12
12
  // @__NO_SIDE_EFFECTS__
13
13
  function A(n) {
14
- return x == null ? void 0 : x.get(n);
14
+ return d == null ? void 0 : d.get(n);
15
15
  }
16
- let E;
16
+ let x;
17
17
  // @__NO_SIDE_EFFECTS__
18
18
  function q(n) {
19
- return E == null ? void 0 : E.get(n);
19
+ return x == null ? void 0 : x.get(n);
20
20
  }
21
- let j;
21
+ let E;
22
22
  // @__NO_SIDE_EFFECTS__
23
23
  function K(n, s) {
24
24
  var e;
25
- return (e = j == null ? void 0 : j.get(n)) == null ? void 0 : e.get(s);
25
+ return (e = E == null ? void 0 : E.get(n)) == null ? void 0 : e.get(s);
26
26
  }
27
27
  // @__NO_SIDE_EFFECTS__
28
- function D(n) {
29
- var e, r;
28
+ function _(n) {
29
+ var e, t;
30
30
  const s = typeof n;
31
- return s === "string" ? `"${n}"` : s === "number" || s === "bigint" || s === "boolean" ? `${n}` : s === "object" || s === "function" ? (n && ((r = (e = Object.getPrototypeOf(n)) == null ? void 0 : e.constructor) == null ? void 0 : r.name)) ?? "null" : s;
31
+ return s === "string" ? `"${n}"` : s === "number" || s === "bigint" || s === "boolean" ? `${n}` : s === "object" || s === "function" ? (n && ((t = (e = Object.getPrototypeOf(n)) == null ? void 0 : e.constructor) == null ? void 0 : t.name)) ?? "null" : s;
32
32
  }
33
- function f(n, s, e, r, t) {
34
- const l = t && "input" in t ? t.input : e.value, i = (t == null ? void 0 : t.expected) ?? n.expects ?? null, p = (t == null ? void 0 : t.received) ?? /* @__PURE__ */ D(l), u = {
33
+ function y(n, s, e, t, r) {
34
+ const l = r && "input" in r ? r.input : e.value, i = (r == null ? void 0 : r.expected) ?? n.expects ?? null, p = (r == null ? void 0 : r.received) ?? /* @__PURE__ */ _(l), u = {
35
35
  kind: n.kind,
36
36
  type: n.type,
37
37
  input: l,
@@ -39,12 +39,12 @@ function f(n, s, e, r, t) {
39
39
  received: p,
40
40
  message: `Invalid ${s}: ${i ? `Expected ${i} but r` : "R"}eceived ${p}`,
41
41
  requirement: n.requirement,
42
- path: t == null ? void 0 : t.path,
43
- issues: t == null ? void 0 : t.issues,
44
- lang: r.lang,
45
- abortEarly: r.abortEarly,
46
- abortPipeEarly: r.abortPipeEarly
47
- }, a = n.kind === "schema", c = (t == null ? void 0 : t.message) ?? n.message ?? /* @__PURE__ */ K(n.reference, u.lang) ?? (a ? /* @__PURE__ */ q(u.lang) : null) ?? r.message ?? /* @__PURE__ */ A(u.lang);
42
+ path: r == null ? void 0 : r.path,
43
+ issues: r == null ? void 0 : r.issues,
44
+ lang: t.lang,
45
+ abortEarly: t.abortEarly,
46
+ abortPipeEarly: t.abortPipeEarly
47
+ }, a = n.kind === "schema", c = (r == null ? void 0 : r.message) ?? n.message ?? /* @__PURE__ */ K(n.reference, u.lang) ?? (a ? /* @__PURE__ */ q(u.lang) : null) ?? t.message ?? /* @__PURE__ */ A(u.lang);
48
48
  c !== void 0 && (u.message = typeof c == "function" ? c(u) : c), a && (e.typed = !1), e.issues ? e.issues.push(u) : e.issues = [u];
49
49
  }
50
50
  // @__NO_SIDE_EFFECTS__
@@ -53,7 +53,7 @@ function o(n) {
53
53
  version: 1,
54
54
  vendor: "valibot",
55
55
  validate(s) {
56
- return n["~run"]({ value: s }, /* @__PURE__ */ _());
56
+ return n["~run"]({ value: s }, /* @__PURE__ */ j());
57
57
  }
58
58
  };
59
59
  }
@@ -62,7 +62,7 @@ function S(n, s) {
62
62
  return Object.hasOwn(n, s) && s !== "__proto__" && s !== "prototype" && s !== "constructor";
63
63
  }
64
64
  // @__NO_SIDE_EFFECTS__
65
- function P(n, s) {
65
+ function D(n, s) {
66
66
  const e = [...new Set(n)];
67
67
  return e.length > 1 ? `(${e.join(` ${s} `)})` : e[0] ?? "never";
68
68
  }
@@ -76,8 +76,8 @@ function M(n, s) {
76
76
  expects: null,
77
77
  requirement: n,
78
78
  message: s,
79
- async "~run"(e, r) {
80
- return e.typed && !await this.requirement(e.value) && f(this, "input", e, r), e;
79
+ async "~run"(e, t) {
80
+ return e.typed && !await this.requirement(e.value) && y(this, "input", e, t), e;
81
81
  }
82
82
  };
83
83
  }
@@ -91,8 +91,8 @@ function V(n, s) {
91
91
  expects: `<=${n}`,
92
92
  requirement: n,
93
93
  message: s,
94
- "~run"(e, r) {
95
- return e.typed && e.value.length > this.requirement && f(this, "length", e, r, { received: `${e.value.length}` }), e;
94
+ "~run"(e, t) {
95
+ return e.typed && e.value.length > this.requirement && y(this, "length", e, t, { received: `${e.value.length}` }), e;
96
96
  }
97
97
  };
98
98
  }
@@ -106,8 +106,8 @@ function G(n, s) {
106
106
  expects: `>=${n}`,
107
107
  requirement: n,
108
108
  message: s,
109
- "~run"(e, r) {
110
- return e.typed && e.value.length < this.requirement && f(this, "length", e, r, { received: `${e.value.length}` }), e;
109
+ "~run"(e, t) {
110
+ return e.typed && e.value.length < this.requirement && y(this, "length", e, t, { received: `${e.value.length}` }), e;
111
111
  }
112
112
  };
113
113
  }
@@ -121,7 +121,7 @@ function L(n) {
121
121
  expects: "!0",
122
122
  message: n,
123
123
  "~run"(s, e) {
124
- return s.typed && s.value.length === 0 && f(this, "length", s, e, { received: "0" }), s;
124
+ return s.typed && s.value.length === 0 && y(this, "length", s, e, { received: "0" }), s;
125
125
  }
126
126
  };
127
127
  }
@@ -142,7 +142,7 @@ function I(n, s, e) {
142
142
  return typeof n.fallback == "function" ? n.fallback(s, e) : n.fallback;
143
143
  }
144
144
  // @__NO_SIDE_EFFECTS__
145
- function g(n, s, e) {
145
+ function P(n, s, e) {
146
146
  return typeof n.default == "function" ? n.default(s, e) : n.default;
147
147
  }
148
148
  // @__NO_SIDE_EFFECTS__
@@ -158,31 +158,31 @@ function C(n, s) {
158
158
  get "~standard"() {
159
159
  return /* @__PURE__ */ o(this);
160
160
  },
161
- "~run"(e, r) {
161
+ "~run"(e, t) {
162
162
  var l;
163
- const t = e.value;
164
- if (Array.isArray(t)) {
163
+ const r = e.value;
164
+ if (Array.isArray(r)) {
165
165
  e.typed = !0, e.value = [];
166
- for (let i = 0; i < t.length; i++) {
167
- const p = t[i], u = this.item["~run"]({ value: p }, r);
166
+ for (let i = 0; i < r.length; i++) {
167
+ const p = r[i], u = this.item["~run"]({ value: p }, t);
168
168
  if (u.issues) {
169
169
  const a = {
170
170
  type: "array",
171
171
  origin: "value",
172
- input: t,
172
+ input: r,
173
173
  key: i,
174
174
  value: p
175
175
  };
176
176
  for (const c of u.issues)
177
177
  c.path ? c.path.unshift(a) : c.path = [a], (l = e.issues) == null || l.push(c);
178
- if (e.issues || (e.issues = u.issues), r.abortEarly) {
178
+ if (e.issues || (e.issues = u.issues), t.abortEarly) {
179
179
  e.typed = !1;
180
180
  break;
181
181
  }
182
182
  }
183
183
  u.typed || (e.typed = !1), e.value.push(u.value);
184
184
  }
185
- } else f(this, "type", e, r);
185
+ } else y(this, "type", e, t);
186
186
  return e;
187
187
  }
188
188
  };
@@ -200,7 +200,7 @@ function F(n) {
200
200
  return /* @__PURE__ */ o(this);
201
201
  },
202
202
  "~run"(s, e) {
203
- return typeof s.value == "boolean" ? s.typed = !0 : f(this, "type", s, e), s;
203
+ return typeof s.value == "boolean" ? s.typed = !0 : y(this, "type", s, e), s;
204
204
  }
205
205
  };
206
206
  }
@@ -217,8 +217,8 @@ function R(n, s) {
217
217
  get "~standard"() {
218
218
  return /* @__PURE__ */ o(this);
219
219
  },
220
- "~run"(e, r) {
221
- return this.check(e.value) ? e.typed = !0 : f(this, "type", e, r), e;
220
+ "~run"(e, t) {
221
+ return this.check(e.value) ? e.typed = !0 : y(this, "type", e, t), e;
222
222
  }
223
223
  };
224
224
  }
@@ -228,15 +228,15 @@ function z(n, s) {
228
228
  kind: "schema",
229
229
  type: "literal",
230
230
  reference: z,
231
- expects: /* @__PURE__ */ D(n),
231
+ expects: /* @__PURE__ */ _(n),
232
232
  async: !1,
233
233
  literal: n,
234
234
  message: s,
235
235
  get "~standard"() {
236
236
  return /* @__PURE__ */ o(this);
237
237
  },
238
- "~run"(e, r) {
239
- return e.value === this.literal ? e.typed = !0 : f(this, "type", e, r), e;
238
+ "~run"(e, t) {
239
+ return e.value === this.literal ? e.typed = !0 : y(this, "type", e, t), e;
240
240
  }
241
241
  };
242
242
  }
@@ -253,76 +253,58 @@ function B(n, s) {
253
253
  get "~standard"() {
254
254
  return /* @__PURE__ */ o(this);
255
255
  },
256
- "~run"(e, r) {
256
+ "~run"(e, t) {
257
257
  var l;
258
- const t = e.value;
259
- if (t && typeof t == "object") {
258
+ const r = e.value;
259
+ if (r && typeof r == "object") {
260
260
  e.typed = !0, e.value = {};
261
261
  for (const i in this.entries) {
262
262
  const p = this.entries[i];
263
- if (i in t || (p.type === "exact_optional" || p.type === "optional" || p.type === "nullish") && p.default !== void 0) {
264
- const u = i in t ? t[i] : /* @__PURE__ */ g(p), a = p["~run"]({ value: u }, r);
263
+ if (i in r || (p.type === "exact_optional" || p.type === "optional" || p.type === "nullish") && p.default !== void 0) {
264
+ const u = i in r ? r[i] : /* @__PURE__ */ P(p), a = p["~run"]({ value: u }, t);
265
265
  if (a.issues) {
266
266
  const c = {
267
267
  type: "object",
268
268
  origin: "value",
269
- input: t,
269
+ input: r,
270
270
  key: i,
271
271
  value: u
272
272
  };
273
- for (const y of a.issues)
274
- y.path ? y.path.unshift(c) : y.path = [c], (l = e.issues) == null || l.push(y);
275
- if (e.issues || (e.issues = a.issues), r.abortEarly) {
273
+ for (const f of a.issues)
274
+ f.path ? f.path.unshift(c) : f.path = [c], (l = e.issues) == null || l.push(f);
275
+ if (e.issues || (e.issues = a.issues), t.abortEarly) {
276
276
  e.typed = !1;
277
277
  break;
278
278
  }
279
279
  }
280
280
  a.typed || (e.typed = !1), e.value[i] = a.value;
281
281
  } else if (p.fallback !== void 0) e.value[i] = /* @__PURE__ */ I(p);
282
- else if (p.type !== "exact_optional" && p.type !== "optional" && p.type !== "nullish" && (f(this, "key", e, r, {
282
+ else if (p.type !== "exact_optional" && p.type !== "optional" && p.type !== "nullish" && (y(this, "key", e, t, {
283
283
  input: void 0,
284
284
  expected: `"${i}"`,
285
285
  path: [{
286
286
  type: "object",
287
287
  origin: "key",
288
- input: t,
288
+ input: r,
289
289
  key: i,
290
- value: t[i]
290
+ value: r[i]
291
291
  }]
292
- }), r.abortEarly))
292
+ }), t.abortEarly))
293
293
  break;
294
294
  }
295
- if (!e.issues || !r.abortEarly)
296
- for (const i in t) /* @__PURE__ */ S(t, i) && !(i in this.entries) && (e.value[i] = t[i]);
297
- } else f(this, "type", e, r);
295
+ if (!e.issues || !t.abortEarly)
296
+ for (const i in r) /* @__PURE__ */ S(r, i) && !(i in this.entries) && (e.value[i] = r[i]);
297
+ } else y(this, "type", e, t);
298
298
  return e;
299
299
  }
300
300
  };
301
301
  }
302
302
  // @__NO_SIDE_EFFECTS__
303
- function H(n, s) {
304
- return {
305
- kind: "schema",
306
- type: "nullish",
307
- reference: H,
308
- expects: `(${n.expects} | null | undefined)`,
309
- async: !1,
310
- wrapped: n,
311
- default: s,
312
- get "~standard"() {
313
- return /* @__PURE__ */ o(this);
314
- },
315
- "~run"(e, r) {
316
- return (e.value === null || e.value === void 0) && (this.default !== void 0 && (e.value = /* @__PURE__ */ g(this, e, r)), e.value === null || e.value === void 0) ? (e.typed = !0, e) : this.wrapped["~run"](e, r);
317
- }
318
- };
319
- }
320
- // @__NO_SIDE_EFFECTS__
321
- function J(n) {
303
+ function H(n) {
322
304
  return {
323
305
  kind: "schema",
324
306
  type: "number",
325
- reference: J,
307
+ reference: H,
326
308
  expects: "number",
327
309
  async: !1,
328
310
  message: n,
@@ -330,16 +312,16 @@ function J(n) {
330
312
  return /* @__PURE__ */ o(this);
331
313
  },
332
314
  "~run"(s, e) {
333
- return typeof s.value == "number" && !isNaN(s.value) ? s.typed = !0 : f(this, "type", s, e), s;
315
+ return typeof s.value == "number" && !isNaN(s.value) ? s.typed = !0 : y(this, "type", s, e), s;
334
316
  }
335
317
  };
336
318
  }
337
319
  // @__NO_SIDE_EFFECTS__
338
- function Q(n, s) {
320
+ function J(n, s) {
339
321
  return {
340
322
  kind: "schema",
341
323
  type: "object",
342
- reference: Q,
324
+ reference: J,
343
325
  expects: "Object",
344
326
  async: !1,
345
327
  entries: n,
@@ -347,56 +329,56 @@ function Q(n, s) {
347
329
  get "~standard"() {
348
330
  return /* @__PURE__ */ o(this);
349
331
  },
350
- "~run"(e, r) {
332
+ "~run"(e, t) {
351
333
  var l;
352
- const t = e.value;
353
- if (t && typeof t == "object") {
334
+ const r = e.value;
335
+ if (r && typeof r == "object") {
354
336
  e.typed = !0, e.value = {};
355
337
  for (const i in this.entries) {
356
338
  const p = this.entries[i];
357
- if (i in t || (p.type === "exact_optional" || p.type === "optional" || p.type === "nullish") && p.default !== void 0) {
358
- const u = i in t ? t[i] : /* @__PURE__ */ g(p), a = p["~run"]({ value: u }, r);
339
+ if (i in r || (p.type === "exact_optional" || p.type === "optional" || p.type === "nullish") && p.default !== void 0) {
340
+ const u = i in r ? r[i] : /* @__PURE__ */ P(p), a = p["~run"]({ value: u }, t);
359
341
  if (a.issues) {
360
342
  const c = {
361
343
  type: "object",
362
344
  origin: "value",
363
- input: t,
345
+ input: r,
364
346
  key: i,
365
347
  value: u
366
348
  };
367
- for (const y of a.issues)
368
- y.path ? y.path.unshift(c) : y.path = [c], (l = e.issues) == null || l.push(y);
369
- if (e.issues || (e.issues = a.issues), r.abortEarly) {
349
+ for (const f of a.issues)
350
+ f.path ? f.path.unshift(c) : f.path = [c], (l = e.issues) == null || l.push(f);
351
+ if (e.issues || (e.issues = a.issues), t.abortEarly) {
370
352
  e.typed = !1;
371
353
  break;
372
354
  }
373
355
  }
374
356
  a.typed || (e.typed = !1), e.value[i] = a.value;
375
357
  } else if (p.fallback !== void 0) e.value[i] = /* @__PURE__ */ I(p);
376
- else if (p.type !== "exact_optional" && p.type !== "optional" && p.type !== "nullish" && (f(this, "key", e, r, {
358
+ else if (p.type !== "exact_optional" && p.type !== "optional" && p.type !== "nullish" && (y(this, "key", e, t, {
377
359
  input: void 0,
378
360
  expected: `"${i}"`,
379
361
  path: [{
380
362
  type: "object",
381
363
  origin: "key",
382
- input: t,
364
+ input: r,
383
365
  key: i,
384
- value: t[i]
366
+ value: r[i]
385
367
  }]
386
- }), r.abortEarly))
368
+ }), t.abortEarly))
387
369
  break;
388
370
  }
389
- } else f(this, "type", e, r);
371
+ } else y(this, "type", e, t);
390
372
  return e;
391
373
  }
392
374
  };
393
375
  }
394
376
  // @__NO_SIDE_EFFECTS__
395
- function T(n, s) {
377
+ function Q(n, s) {
396
378
  return {
397
379
  kind: "schema",
398
380
  type: "optional",
399
- reference: T,
381
+ reference: Q,
400
382
  expects: `(${n.expects} | undefined)`,
401
383
  async: !1,
402
384
  wrapped: n,
@@ -404,35 +386,35 @@ function T(n, s) {
404
386
  get "~standard"() {
405
387
  return /* @__PURE__ */ o(this);
406
388
  },
407
- "~run"(e, r) {
408
- return e.value === void 0 && (this.default !== void 0 && (e.value = /* @__PURE__ */ g(this, e, r)), e.value === void 0) ? (e.typed = !0, e) : this.wrapped["~run"](e, r);
389
+ "~run"(e, t) {
390
+ return e.value === void 0 && (this.default !== void 0 && (e.value = /* @__PURE__ */ P(this, e, t)), e.value === void 0) ? (e.typed = !0, e) : this.wrapped["~run"](e, t);
409
391
  }
410
392
  };
411
393
  }
412
394
  // @__NO_SIDE_EFFECTS__
413
- function U(n, s) {
395
+ function T(n, s) {
414
396
  return {
415
397
  kind: "schema",
416
398
  type: "picklist",
417
- reference: U,
418
- expects: /* @__PURE__ */ P(n.map(D), "|"),
399
+ reference: T,
400
+ expects: /* @__PURE__ */ D(n.map(_), "|"),
419
401
  async: !1,
420
402
  options: n,
421
403
  message: s,
422
404
  get "~standard"() {
423
405
  return /* @__PURE__ */ o(this);
424
406
  },
425
- "~run"(e, r) {
426
- return this.options.includes(e.value) ? e.typed = !0 : f(this, "type", e, r), e;
407
+ "~run"(e, t) {
408
+ return this.options.includes(e.value) ? e.typed = !0 : y(this, "type", e, t), e;
427
409
  }
428
410
  };
429
411
  }
430
412
  // @__NO_SIDE_EFFECTS__
431
- function W(n, s, e) {
413
+ function U(n, s, e) {
432
414
  return {
433
415
  kind: "schema",
434
416
  type: "record",
435
- reference: W,
417
+ reference: U,
436
418
  expects: "Object",
437
419
  async: !1,
438
420
  key: n,
@@ -441,13 +423,13 @@ function W(n, s, e) {
441
423
  get "~standard"() {
442
424
  return /* @__PURE__ */ o(this);
443
425
  },
444
- "~run"(r, t) {
426
+ "~run"(t, r) {
445
427
  var i, p;
446
- const l = r.value;
428
+ const l = t.value;
447
429
  if (l && typeof l == "object") {
448
- r.typed = !0, r.value = {};
430
+ t.typed = !0, t.value = {};
449
431
  for (const u in l) if (/* @__PURE__ */ S(l, u)) {
450
- const a = l[u], c = this.key["~run"]({ value: u }, t);
432
+ const a = l[u], c = this.key["~run"]({ value: u }, r);
451
433
  if (c.issues) {
452
434
  const b = {
453
435
  type: "object",
@@ -457,14 +439,14 @@ function W(n, s, e) {
457
439
  value: a
458
440
  };
459
441
  for (const h of c.issues)
460
- h.path = [b], (i = r.issues) == null || i.push(h);
461
- if (r.issues || (r.issues = c.issues), t.abortEarly) {
462
- r.typed = !1;
442
+ h.path = [b], (i = t.issues) == null || i.push(h);
443
+ if (t.issues || (t.issues = c.issues), r.abortEarly) {
444
+ t.typed = !1;
463
445
  break;
464
446
  }
465
447
  }
466
- const y = this.value["~run"]({ value: a }, t);
467
- if (y.issues) {
448
+ const f = this.value["~run"]({ value: a }, r);
449
+ if (f.issues) {
468
450
  const b = {
469
451
  type: "object",
470
452
  origin: "value",
@@ -472,26 +454,26 @@ function W(n, s, e) {
472
454
  key: u,
473
455
  value: a
474
456
  };
475
- for (const h of y.issues)
476
- h.path ? h.path.unshift(b) : h.path = [b], (p = r.issues) == null || p.push(h);
477
- if (r.issues || (r.issues = y.issues), t.abortEarly) {
478
- r.typed = !1;
457
+ for (const h of f.issues)
458
+ h.path ? h.path.unshift(b) : h.path = [b], (p = t.issues) == null || p.push(h);
459
+ if (t.issues || (t.issues = f.issues), r.abortEarly) {
460
+ t.typed = !1;
479
461
  break;
480
462
  }
481
463
  }
482
- (!c.typed || !y.typed) && (r.typed = !1), c.typed && (r.value[c.value] = y.value);
464
+ (!c.typed || !f.typed) && (t.typed = !1), c.typed && (t.value[c.value] = f.value);
483
465
  }
484
- } else f(this, "type", r, t);
485
- return r;
466
+ } else y(this, "type", t, r);
467
+ return t;
486
468
  }
487
469
  };
488
470
  }
489
471
  // @__NO_SIDE_EFFECTS__
490
- function X(n) {
472
+ function W(n) {
491
473
  return {
492
474
  kind: "schema",
493
475
  type: "string",
494
- reference: X,
476
+ reference: W,
495
477
  expects: "string",
496
478
  async: !1,
497
479
  message: n,
@@ -499,7 +481,7 @@ function X(n) {
499
481
  return /* @__PURE__ */ o(this);
500
482
  },
501
483
  "~run"(s, e) {
502
- return typeof s.value == "string" ? s.typed = !0 : f(this, "type", s, e), s;
484
+ return typeof s.value == "string" ? s.typed = !0 : y(this, "type", s, e), s;
503
485
  }
504
486
  };
505
487
  }
@@ -510,47 +492,47 @@ function O(n) {
510
492
  return s;
511
493
  }
512
494
  // @__NO_SIDE_EFFECTS__
513
- function Y(n, s) {
495
+ function X(n, s) {
514
496
  return {
515
497
  kind: "schema",
516
498
  type: "union",
517
- reference: Y,
518
- expects: /* @__PURE__ */ P(n.map((e) => e.expects), "|"),
499
+ reference: X,
500
+ expects: /* @__PURE__ */ D(n.map((e) => e.expects), "|"),
519
501
  async: !1,
520
502
  options: n,
521
503
  message: s,
522
504
  get "~standard"() {
523
505
  return /* @__PURE__ */ o(this);
524
506
  },
525
- "~run"(e, r) {
526
- let t, l, i;
507
+ "~run"(e, t) {
508
+ let r, l, i;
527
509
  for (const p of this.options) {
528
- const u = p["~run"]({ value: e.value }, r);
510
+ const u = p["~run"]({ value: e.value }, t);
529
511
  if (u.typed) if (u.issues) l ? l.push(u) : l = [u];
530
512
  else {
531
- t = u;
513
+ r = u;
532
514
  break;
533
515
  }
534
516
  else i ? i.push(u) : i = [u];
535
517
  }
536
- if (t) return t;
518
+ if (r) return r;
537
519
  if (l) {
538
520
  if (l.length === 1) return l[0];
539
- f(this, "type", e, r, { issues: /* @__PURE__ */ O(l) }), e.typed = !0;
521
+ y(this, "type", e, t, { issues: /* @__PURE__ */ O(l) }), e.typed = !0;
540
522
  } else {
541
523
  if ((i == null ? void 0 : i.length) === 1) return i[0];
542
- f(this, "type", e, r, { issues: /* @__PURE__ */ O(i) });
524
+ y(this, "type", e, t, { issues: /* @__PURE__ */ O(i) });
543
525
  }
544
526
  return e;
545
527
  }
546
528
  };
547
529
  }
548
530
  // @__NO_SIDE_EFFECTS__
549
- function Z() {
531
+ function Y() {
550
532
  return {
551
533
  kind: "schema",
552
534
  type: "unknown",
553
- reference: Z,
535
+ reference: Y,
554
536
  expects: "unknown",
555
537
  async: !1,
556
538
  get "~standard"() {
@@ -562,11 +544,11 @@ function Z() {
562
544
  };
563
545
  }
564
546
  // @__NO_SIDE_EFFECTS__
565
- function $(n, s, e) {
547
+ function Z(n, s, e) {
566
548
  return {
567
549
  kind: "schema",
568
550
  type: "variant",
569
- reference: $,
551
+ reference: Z,
570
552
  expects: "Object",
571
553
  async: !1,
572
554
  key: n,
@@ -575,28 +557,28 @@ function $(n, s, e) {
575
557
  get "~standard"() {
576
558
  return /* @__PURE__ */ o(this);
577
559
  },
578
- "~run"(r, t) {
579
- const l = r.value;
560
+ "~run"(t, r) {
561
+ const l = t.value;
580
562
  if (l && typeof l == "object") {
581
563
  let i, p = 0, u = this.key, a = [];
582
- const c = (y, b) => {
583
- for (const h of y.options) {
564
+ const c = (f, b) => {
565
+ for (const h of f.options) {
584
566
  if (h.type === "variant") c(h, new Set(b).add(h.key));
585
567
  else {
586
568
  let w = !0, k = 0;
587
569
  for (const v of b) {
588
- const d = h.entries[v];
589
- if (v in l ? d["~run"]({
570
+ const g = h.entries[v];
571
+ if (v in l ? g["~run"]({
590
572
  typed: !1,
591
573
  value: l[v]
592
- }, { abortEarly: !0 }).issues : d.type !== "exact_optional" && d.type !== "optional" && d.type !== "nullish") {
574
+ }, { abortEarly: !0 }).issues : g.type !== "exact_optional" && g.type !== "optional" && g.type !== "nullish") {
593
575
  w = !1, u !== v && (p < k || p === k && v in l && !(u in l)) && (p = k, u = v, a = []), u === v && a.push(h.entries[v].expects);
594
576
  break;
595
577
  }
596
578
  k++;
597
579
  }
598
580
  if (w) {
599
- const v = h["~run"]({ value: l }, t);
581
+ const v = h["~run"]({ value: l }, r);
600
582
  (!i || !i.typed && v.typed) && (i = v);
601
583
  }
602
584
  }
@@ -604,9 +586,9 @@ function $(n, s, e) {
604
586
  }
605
587
  };
606
588
  if (c(this, /* @__PURE__ */ new Set([this.key])), i) return i;
607
- f(this, "type", r, t, {
589
+ y(this, "type", t, r, {
608
590
  input: l[u],
609
- expected: /* @__PURE__ */ P(a, "|"),
591
+ expected: /* @__PURE__ */ D(a, "|"),
610
592
  path: [{
611
593
  type: "object",
612
594
  origin: "value",
@@ -615,13 +597,13 @@ function $(n, s, e) {
615
597
  value: l[u]
616
598
  }]
617
599
  });
618
- } else f(this, "type", r, t);
619
- return r;
600
+ } else y(this, "type", t, r);
601
+ return t;
620
602
  }
621
603
  };
622
604
  }
623
605
  // @__NO_SIDE_EFFECTS__
624
- function ee(...n) {
606
+ function $(...n) {
625
607
  return {
626
608
  ...n[0],
627
609
  pipe: n,
@@ -629,19 +611,19 @@ function ee(...n) {
629
611
  return /* @__PURE__ */ o(this);
630
612
  },
631
613
  "~run"(s, e) {
632
- for (const r of n) if (r.kind !== "metadata") {
633
- if (s.issues && (r.kind === "schema" || r.kind === "transformation")) {
614
+ for (const t of n) if (t.kind !== "metadata") {
615
+ if (s.issues && (t.kind === "schema" || t.kind === "transformation")) {
634
616
  s.typed = !1;
635
617
  break;
636
618
  }
637
- (!s.issues || !e.abortEarly && !e.abortPipeEarly) && (s = r["~run"](s, e));
619
+ (!s.issues || !e.abortEarly && !e.abortPipeEarly) && (s = t["~run"](s, e));
638
620
  }
639
621
  return s;
640
622
  }
641
623
  };
642
624
  }
643
625
  // @__NO_SIDE_EFFECTS__
644
- function ne(...n) {
626
+ function ee(...n) {
645
627
  return {
646
628
  ...n[0],
647
629
  pipe: n,
@@ -650,50 +632,50 @@ function ne(...n) {
650
632
  return /* @__PURE__ */ o(this);
651
633
  },
652
634
  async "~run"(s, e) {
653
- for (const r of n) if (r.kind !== "metadata") {
654
- if (s.issues && (r.kind === "schema" || r.kind === "transformation")) {
635
+ for (const t of n) if (t.kind !== "metadata") {
636
+ if (s.issues && (t.kind === "schema" || t.kind === "transformation")) {
655
637
  s.typed = !1;
656
638
  break;
657
639
  }
658
- (!s.issues || !e.abortEarly && !e.abortPipeEarly) && (s = await r["~run"](s, e));
640
+ (!s.issues || !e.abortEarly && !e.abortPipeEarly) && (s = await t["~run"](s, e));
659
641
  }
660
642
  return s;
661
643
  }
662
644
  };
663
645
  }
664
646
  // @__NO_SIDE_EFFECTS__
665
- function se(n, s, e) {
666
- const r = n["~run"]({ value: s }, /* @__PURE__ */ _(e));
647
+ function ne(n, s, e) {
648
+ const t = n["~run"]({ value: s }, /* @__PURE__ */ j(e));
667
649
  return {
668
- typed: r.typed,
669
- success: !r.issues,
670
- output: r.value,
671
- issues: r.issues
650
+ typed: t.typed,
651
+ success: !t.issues,
652
+ output: t.value,
653
+ issues: t.issues
672
654
  };
673
655
  }
674
656
  // @__NO_SIDE_EFFECTS__
675
- async function re(n, s, e) {
676
- const r = await n["~run"]({ value: s }, /* @__PURE__ */ _(e));
657
+ async function se(n, s, e) {
658
+ const t = await n["~run"]({ value: s }, /* @__PURE__ */ j(e));
677
659
  return {
678
- typed: r.typed,
679
- success: !r.issues,
680
- output: r.value,
681
- issues: r.issues
660
+ typed: t.typed,
661
+ success: !t.issues,
662
+ output: t.value,
663
+ issues: t.issues
682
664
  };
683
665
  }
684
666
  export {
685
- f as _addIssue,
667
+ y as _addIssue,
686
668
  o as _getStandardProps,
687
669
  S as _isValidObjectKey,
688
- P as _joinExpects,
689
- D as _stringify,
670
+ D as _joinExpects,
671
+ _ as _stringify,
690
672
  C as array,
691
673
  F as boolean,
692
674
  M as checkAsync,
693
675
  R as custom,
694
- g as getDefault,
676
+ P as getDefault,
695
677
  I as getFallback,
696
- _ as getGlobalConfig,
678
+ j as getGlobalConfig,
697
679
  A as getGlobalMessage,
698
680
  q as getSchemaMessage,
699
681
  K as getSpecificMessage,
@@ -702,19 +684,18 @@ export {
702
684
  V as maxLength,
703
685
  G as minLength,
704
686
  L as nonEmpty,
705
- H as nullish,
706
- J as number,
707
- Q as object,
708
- T as optional,
709
- U as picklist,
710
- ee as pipe,
711
- ne as pipeAsync,
712
- W as record,
713
- se as safeParse,
714
- re as safeParseAsync,
715
- X as string,
687
+ H as number,
688
+ J as object,
689
+ Q as optional,
690
+ T as picklist,
691
+ $ as pipe,
692
+ ee as pipeAsync,
693
+ U as record,
694
+ ne as safeParse,
695
+ se as safeParseAsync,
696
+ W as string,
716
697
  N as trim,
717
- Y as union,
718
- Z as unknown,
719
- $ as variant
698
+ X as union,
699
+ Y as unknown,
700
+ Z as variant
720
701
  };
@@ -37,15 +37,8 @@ export declare const ProductType: {
37
37
  * Identity configuration - identifies the template and user
38
38
  */
39
39
  export declare const IdentitySchema: v.ObjectSchema<{
40
- /**
41
- * Unique identifier for the template being edited.
42
- *
43
- * Optional: a brand-new newsletter being designed has no saved template yet,
44
- * so hosts may pass `null`/`undefined`. Normalizes to `''` to match the
45
- * library's own internal handling (config getter, state bridge, editor stores
46
- * all default templateId to `''`).
47
- */
48
- readonly templateId: v.NullishSchema<v.StringSchema<undefined>, "">;
40
+ /** Unique identifier for the template being edited */
41
+ readonly templateId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, "templateId is required">]>;
49
42
  /** Unique identifier for the user editing the template */
50
43
  readonly userId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, "userId is required">]>;
51
44
  /** Optional variation ID for A/B testing */
@@ -572,15 +565,8 @@ export declare const CallbacksSchema: v.ObjectSchema<{
572
565
  export declare const GuidoConfigSchema: v.ObjectSchema<{
573
566
  /** Identity configuration (required) */
574
567
  readonly identity: v.ObjectSchema<{
575
- /**
576
- * Unique identifier for the template being edited.
577
- *
578
- * Optional: a brand-new newsletter being designed has no saved template yet,
579
- * so hosts may pass `null`/`undefined`. Normalizes to `''` to match the
580
- * library's own internal handling (config getter, state bridge, editor stores
581
- * all default templateId to `''`).
582
- */
583
- readonly templateId: v.NullishSchema<v.StringSchema<undefined>, "">;
568
+ /** Unique identifier for the template being edited */
569
+ readonly templateId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, "templateId is required">]>;
584
570
  /** Unique identifier for the user editing the template */
585
571
  readonly userId: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, "userId is required">]>;
586
572
  /** Optional variation ID for A/B testing */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@useinsider/guido",
3
- "version": "3.5.1-beta.62862ff",
3
+ "version": "3.5.1-beta.a51b847",
4
4
  "description": "Guido is a Vue + TypeScript wrapper for Email Plugin. Easily embed the email editor in your Vue applications.",
5
5
  "main": "./dist/guido.umd.cjs",
6
6
  "module": "./dist/library.js",