@riverbankcms/sdk 0.92.0 → 0.94.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/dist/{PreviewEditorSidebar-3CI5MKV3.mjs → PreviewEditorSidebar-D3PAF7NW.mjs} +3 -3
  2. package/dist/{PreviewEditorUI-DKEP636I.mjs → PreviewEditorUI-G5JVJEIJ.mjs} +3 -3
  3. package/dist/SdkPreviewModeRuntime-NHTLRNQD.mjs +8 -0
  4. package/dist/_dts/api/src/common/envelope.d.ts +10 -0
  5. package/dist/_dts/api/src/index.d.ts +2 -2
  6. package/dist/_dts/api/src/request.d.ts +1 -1
  7. package/dist/_dts/blocks/src/system/manifest/fieldValidation/index.d.ts +1 -0
  8. package/dist/_dts/content-editor/src/controller/EntryControllerProvider.d.ts +14 -14
  9. package/dist/_dts/content-editor/src/controller/useEntrySyncHelpers.d.ts +1 -1
  10. package/dist/_dts/content-editor/src/hooks/useEntryActions.d.ts +5 -15
  11. package/dist/_dts/content-editor/src/ui/editorSnapshot.d.ts +46 -0
  12. package/dist/_dts/content-editor/src/ui/editorUiStore.d.ts +43 -36
  13. package/dist/_dts/media-core/src/fileUploadFinalization.d.ts +29 -1
  14. package/dist/_dts/media-core/src/index.d.ts +1 -0
  15. package/dist/_dts/media-core/src/legacyMediaValue.d.ts +11 -0
  16. package/dist/_dts/media-react/src/hooks/useApiMediaUploader.d.ts +2 -1
  17. package/dist/_dts/sdk/src/version.d.ts +1 -1
  18. package/dist/{chunk-UOMTCHZD.mjs → chunk-A63UXN3P.mjs} +21 -19
  19. package/dist/{chunk-U5YM4AWE.mjs → chunk-AJZGT6YG.mjs} +1 -1
  20. package/dist/{chunk-6D7PLF4M.mjs → chunk-AQ6RT6LZ.mjs} +2 -2
  21. package/dist/{chunk-ZA2S7H34.mjs → chunk-NT76QGIJ.mjs} +98 -1
  22. package/dist/{chunk-I6EOKV6B.mjs → chunk-PCNCETBI.mjs} +676 -386
  23. package/dist/{chunk-LERKJM3E.mjs → chunk-XIK2HYI3.mjs} +7 -7
  24. package/dist/cli/index.mjs +198 -87
  25. package/dist/client/{accordion-BUDH2G3S.mjs → accordion-RNQIPG55.mjs} +2 -2
  26. package/dist/client/{bookingForm-NQMCELVB.mjs → bookingForm-HYEEVRLP.mjs} +5 -5
  27. package/dist/client/{carousel-ONCEW6IJ.mjs → carousel-W7DQ3YPU.mjs} +3 -3
  28. package/dist/client/{cart-V2TCK2GI.mjs → cart-PXJ3SXXO.mjs} +6 -6
  29. package/dist/client/{checkout-ZI7SWNCS.mjs → checkout-X3JYSOXI.mjs} +6 -6
  30. package/dist/client/{chunk-R3CZQLXF.mjs → chunk-6SYGVVWA.mjs} +1 -1
  31. package/dist/client/{chunk-N2WJPTF7.mjs → chunk-DUOHLWLF.mjs} +3 -3
  32. package/dist/client/{chunk-KXYEKEV6.mjs → chunk-IXDSXF2D.mjs} +7 -7
  33. package/dist/client/{chunk-ZJDBOLX7.mjs → chunk-J6TMMMXW.mjs} +2 -2
  34. package/dist/client/{chunk-B5UC2D6X.mjs → chunk-JNE6UI6U.mjs} +1 -1
  35. package/dist/client/{chunk-QQNVQ62W.mjs → chunk-OLAOAZEO.mjs} +1 -1
  36. package/dist/client/{chunk-AUMRQ242.mjs → chunk-PICR3NTQ.mjs} +2 -2
  37. package/dist/client/{chunk-ERQDHUS2.mjs → chunk-Q47XGAGS.mjs} +1 -1
  38. package/dist/client/{chunk-HQWIJLYN.mjs → chunk-WERRJXNJ.mjs} +1 -1
  39. package/dist/client/{chunk-JXY6NHG6.mjs → chunk-YYVGSYBO.mjs} +5 -5
  40. package/dist/client/client.mjs +127 -17
  41. package/dist/client/{courseRegistration-JPWAQ6KM.mjs → courseRegistration-QZ67PVHO.mjs} +5 -5
  42. package/dist/client/{eventCalendar-QDOCHBBV.mjs → eventCalendar-V3BDHQNT.mjs} +8 -8
  43. package/dist/client/{eventCombined-ZS2CXSIE.mjs → eventCombined-XYFRN2RG.mjs} +8 -8
  44. package/dist/client/{eventDetails-5LOBMPLN.mjs → eventDetails-TFE5TWKV.mjs} +8 -8
  45. package/dist/client/{eventListing-SBGY4I3L.mjs → eventListing-IQ6AGWZ6.mjs} +8 -8
  46. package/dist/client/{eventRegistration-XGPIU3Z2.mjs → eventRegistration-WGJVFKQJ.mjs} +8 -8
  47. package/dist/client/{form-R7D4LZWW.mjs → form-6UZY6RUA.mjs} +2 -2
  48. package/dist/client/{headerSection-RRLYUCGC.mjs → headerSection-RSFXY6V3.mjs} +3 -3
  49. package/dist/client/hooks.mjs +35 -3
  50. package/dist/client/{locationMap-35ZJMRBZ.mjs → locationMap-24FH67I4.mjs} +3 -3
  51. package/dist/client/{newsletterForm-MJ2VCFUT.mjs → newsletterForm-QVL3MLTN.mjs} +2 -2
  52. package/dist/client/{productDetail-2O7YQNBX.mjs → productDetail-ZDYN3G4T.mjs} +6 -6
  53. package/dist/client/{productList-FDP5BH7W.mjs → productList-4BMJLQHZ.mjs} +6 -6
  54. package/dist/client/rendering/client.mjs +8 -0
  55. package/dist/client/rendering/islands.mjs +19 -19
  56. package/dist/client/rendering.mjs +69 -2
  57. package/dist/client/{shop-BGYJ3LDT.mjs → shop-U5C634FF.mjs} +6 -6
  58. package/dist/preview-next/client/runtime.mjs +5 -5
  59. package/dist/{sdk-runtime-B3TFXRXZ.mjs → sdk-runtime-VGV46WVB.mjs} +6 -6
  60. package/dist/server/components.mjs +121 -61
  61. package/dist/server/config-validation.mjs +35 -3
  62. package/dist/server/config.mjs +35 -3
  63. package/dist/server/data.mjs +35 -3
  64. package/dist/server/index.mjs +104 -29
  65. package/dist/server/next.mjs +183 -80
  66. package/dist/server/page-converter.mjs +3 -3
  67. package/dist/server/prebuild.mjs +1 -1
  68. package/dist/server/rendering/server.mjs +121 -61
  69. package/dist/server/rendering.mjs +121 -61
  70. package/dist/server/routing.mjs +102 -62
  71. package/dist/server/server.mjs +167 -92
  72. package/package.json +1 -1
  73. package/dist/SdkPreviewModeRuntime-BRGRDQFH.mjs +0 -8
  74. /package/dist/client/{chunk-GH6IIOOE.mjs → chunk-PCHACQEB.mjs} +0 -0
@@ -1178,6 +1178,27 @@ var init_renderableMediaAsset = __esm({
1178
1178
  }
1179
1179
  });
1180
1180
 
1181
+ // ../media-core/src/legacyMediaValue.ts
1182
+ function legacyStringMediaTypeForField(field) {
1183
+ if (field.type === "file") {
1184
+ return field.fileKinds?.[0] ?? "document";
1185
+ }
1186
+ return field.mediaKinds?.[0] ?? "image";
1187
+ }
1188
+ function normalizeLegacyStringMediaValueForField(value, field) {
1189
+ if (typeof value !== "string") return value;
1190
+ const src = value.trim();
1191
+ if (!src) return value;
1192
+ return {
1193
+ type: legacyStringMediaTypeForField(field),
1194
+ src
1195
+ };
1196
+ }
1197
+ var init_legacyMediaValue = __esm({
1198
+ "../media-core/src/legacyMediaValue.ts"() {
1199
+ }
1200
+ });
1201
+
1181
1202
  // ../media-core/src/index.ts
1182
1203
  var init_src2 = __esm({
1183
1204
  "../media-core/src/index.ts"() {
@@ -1217,6 +1238,7 @@ var init_src2 = __esm({
1217
1238
  init_mediaUsageProjection();
1218
1239
  init_portableMediaReferences();
1219
1240
  init_renderableMediaAsset();
1241
+ init_legacyMediaValue();
1220
1242
  }
1221
1243
  });
1222
1244
  var transformStepSchema, bindingPathSchema, bindingSchema, repeatSchema, conditionSchema, dataScopeSchema, nodePropsSchema, nodeSchema, nodeTreeSchema, NodeSchema, NodeTreeSchema;
@@ -28640,6 +28662,9 @@ function internalNavigationLinkToLocalLink(item) {
28640
28662
  }
28641
28663
  return void 0;
28642
28664
  }
28665
+
28666
+ // ../blocks/src/system/manifest/fieldValidation/index.ts
28667
+ init_src2();
28643
28668
  var nullableString = z.union([z.string().min(1), z.null()]);
28644
28669
  var resolvedInternalLinkKeys = ["entityId", "entityType", "href", "title", "typeLabel"];
28645
28670
  var internalRouteOnlyLinkSchema = z.object({
@@ -29214,7 +29239,10 @@ function deriveFieldValidationPlan(field, path28 = [field.id]) {
29214
29239
  return makePlan("richText", "object", field, path28, required, commonConstraints(required, { kind: "richTextDoc" }));
29215
29240
  case "media":
29216
29241
  case "file":
29217
- return makePlan("media", "object", field, path28, required, commonConstraints(required, { kind: "mediaObject" }));
29242
+ return {
29243
+ ...makePlan("media", "object", field, path28, required, commonConstraints(required, { kind: "mediaObject" })),
29244
+ legacyStringType: legacyStringMediaTypeForField(field)
29245
+ };
29218
29246
  case "link":
29219
29247
  return makePlan("link", "object", field, path28, required, commonConstraints(required, { kind: "linkObject" }));
29220
29248
  case "boolean":
@@ -29339,15 +29367,23 @@ function normalizeFieldValue(plan, value, ctx) {
29339
29367
  return normalizeRepeaterItems(plan, value, ctx);
29340
29368
  case "boolean":
29341
29369
  case "richText":
29342
- case "media":
29343
29370
  case "link":
29344
29371
  case "select":
29345
29372
  case "passthrough":
29346
29373
  return value;
29374
+ case "media":
29375
+ return normalizeMediaInput(plan, value);
29347
29376
  default:
29348
29377
  return assertNever2(plan);
29349
29378
  }
29350
29379
  }
29380
+ function normalizeMediaInput(plan, value) {
29381
+ return normalizeLegacyStringMediaValueForField(value, {
29382
+ type: plan.fieldType,
29383
+ mediaKinds: plan.fieldType === "media" ? [plan.legacyStringType] : void 0,
29384
+ fileKinds: plan.fieldType === "file" ? [plan.legacyStringType] : void 0
29385
+ });
29386
+ }
29351
29387
  function normalizeObjectChildren(children, value, ctx) {
29352
29388
  if (!value || typeof value !== "object" || Array.isArray(value)) return value;
29353
29389
  const normalized = {
@@ -42636,12 +42672,85 @@ function resolveApiBaseUrl() {
42636
42672
  }
42637
42673
 
42638
42674
  // ../api/src/common/envelope.ts
42675
+ var API_ERROR_CODES = [
42676
+ "auth:unauthenticated",
42677
+ "auth:token_expired",
42678
+ "auth:token_invalid",
42679
+ "auth:forbidden",
42680
+ "auth:mfa_required",
42681
+ "auth:sudo_required",
42682
+ "auth:insufficient_permissions",
42683
+ "auth:impersonation_restricted",
42684
+ "validation:invalid_input",
42685
+ "validation:missing_field",
42686
+ "validation:invalid_format",
42687
+ "validation:payload_too_large",
42688
+ "resource:not_found",
42689
+ "resource:already_exists",
42690
+ "resource:conflict",
42691
+ "resource:gone",
42692
+ "rate_limit:exceeded",
42693
+ "billing:payment_required",
42694
+ "billing:plan_limit_exceeded",
42695
+ "billing:pass_redemption_failed",
42696
+ "server:internal_error",
42697
+ "server:unavailable",
42698
+ "external:service_error",
42699
+ "external:registrar_orphaned_contact_profile",
42700
+ "network:connection_error",
42701
+ "network:timeout",
42702
+ "network:dns_error"
42703
+ ];
42704
+ var API_ERROR_CODE_SET = new Set(API_ERROR_CODES);
42705
+ function isApiErrorCode(value) {
42706
+ return typeof value === "string" && API_ERROR_CODE_SET.has(value);
42707
+ }
42639
42708
  function isApiError(result) {
42640
42709
  return result.success === false;
42641
42710
  }
42642
42711
  function isApiSuccess(result) {
42643
42712
  return result.success === true;
42644
42713
  }
42714
+ function isRecord9(value) {
42715
+ return typeof value === "object" && value !== null && !Array.isArray(value);
42716
+ }
42717
+ function isFieldError(value) {
42718
+ return isRecord9(value) && typeof value.field === "string" && typeof value.code === "string" && typeof value.message === "string";
42719
+ }
42720
+ function fieldErrorsFromUnknown(value) {
42721
+ if (!Array.isArray(value)) return null;
42722
+ return value.every(isFieldError) ? value : null;
42723
+ }
42724
+ function extractEnvelopeErrorObject(body) {
42725
+ if (!isRecord9(body)) return null;
42726
+ const error = body.error;
42727
+ if (!isRecord9(error)) return null;
42728
+ if ("success" in body && body.success !== false) {
42729
+ return null;
42730
+ }
42731
+ return error;
42732
+ }
42733
+ function extractApiEnvelopeErrorDetails(body) {
42734
+ const error = extractEnvelopeErrorObject(body);
42735
+ if (!error) {
42736
+ return {
42737
+ rawCode: null,
42738
+ code: null,
42739
+ message: null,
42740
+ status: null,
42741
+ fieldErrors: null
42742
+ };
42743
+ }
42744
+ const rawCode = typeof error.code === "string" ? error.code : null;
42745
+ const message = typeof error.message === "string" && error.message.trim().length > 0 ? error.message : null;
42746
+ return {
42747
+ rawCode,
42748
+ code: isApiErrorCode(rawCode) ? rawCode : null,
42749
+ message,
42750
+ status: typeof error.status === "number" && Number.isFinite(error.status) ? error.status : null,
42751
+ fieldErrors: fieldErrorsFromUnknown(error.fieldErrors)
42752
+ };
42753
+ }
42645
42754
  var ApiEnvelopeError = class extends Error {
42646
42755
  constructor(error) {
42647
42756
  super(error.message);
@@ -43038,6 +43147,7 @@ function createParsedClient(rawClient) {
43038
43147
  const auth = config2.auth ?? "user";
43039
43148
  if (!response.ok) {
43040
43149
  const body = await parseErrorBody(response);
43150
+ const envelopeError = extractApiEnvelopeErrorDetails(body);
43041
43151
  const requestId = response.headers.get("x-request-id") ?? void 0;
43042
43152
  const retryAfterMs = parseRetryAfterHeader(response.headers.get("retry-after"));
43043
43153
  throw new ApiRequestError(
@@ -43049,6 +43159,7 @@ function createParsedClient(rawClient) {
43049
43159
  auth,
43050
43160
  requestId,
43051
43161
  body,
43162
+ errorCode: envelopeError.code ?? void 0,
43052
43163
  retryAfterMs
43053
43164
  }
43054
43165
  );
@@ -43286,7 +43397,7 @@ function preset(id, verticalId, canonicalBehaviour, label, pluralLabel, descript
43286
43397
  }
43287
43398
 
43288
43399
  // ../api/src/utils/isRecord.ts
43289
- function isRecord9(value) {
43400
+ function isRecord10(value) {
43290
43401
  return typeof value === "object" && value !== null && !Array.isArray(value);
43291
43402
  }
43292
43403
  var APPOINTMENT_SETUP_MAX_MINUTES = 1440;
@@ -43559,7 +43670,7 @@ function sanitizeMarks(marks) {
43559
43670
  if (mark.type === "bold" || mark.type === "strong" || mark.type === "italic" || mark.type === "em") {
43560
43671
  return [{ type: mark.type }];
43561
43672
  }
43562
- if (mark.type === "link" && isRecord9(mark.attrs) && typeof mark.attrs.href === "string") {
43673
+ if (mark.type === "link" && isRecord10(mark.attrs) && typeof mark.attrs.href === "string") {
43563
43674
  const attrs = { href: mark.attrs.href };
43564
43675
  if (typeof mark.attrs.target === "string" && mark.attrs.target.trim().length > 0) {
43565
43676
  attrs.target = mark.attrs.target;
@@ -43574,10 +43685,10 @@ function sanitizeMarks(marks) {
43574
43685
  return sanitized.length > 0 ? sanitized : void 0;
43575
43686
  }
43576
43687
  function unwrapRichTextValue(value) {
43577
- if (isRecord9(value) && isRecord9(value.doc)) {
43688
+ if (isRecord10(value) && isRecord10(value.doc)) {
43578
43689
  return unwrapRichTextValue(value.doc);
43579
43690
  }
43580
- if (isRecord9(value) && value.type === "doc") {
43691
+ if (isRecord10(value) && value.type === "doc") {
43581
43692
  return {
43582
43693
  type: "doc",
43583
43694
  content: Array.isArray(value.content) ? value.content.filter(isTipTapNodeLike).map(coerceTipTapNode) : []
@@ -43586,7 +43697,7 @@ function unwrapRichTextValue(value) {
43586
43697
  return EMPTY_SITE_BANNER_BODY;
43587
43698
  }
43588
43699
  function isTipTapNodeLike(value) {
43589
- return isRecord9(value) && typeof value.type === "string";
43700
+ return isRecord10(value) && typeof value.type === "string";
43590
43701
  }
43591
43702
  function coerceTipTapNode(value) {
43592
43703
  return {
@@ -43594,9 +43705,9 @@ function coerceTipTapNode(value) {
43594
43705
  ...Array.isArray(value.content) ? { content: value.content.filter(isTipTapNodeLike).map(coerceTipTapNode) } : {},
43595
43706
  ...typeof value.text === "string" ? { text: value.text } : {},
43596
43707
  ...Array.isArray(value.marks) ? {
43597
- marks: value.marks.filter((mark) => isRecord9(mark) && typeof mark.type === "string").map((mark) => ({
43708
+ marks: value.marks.filter((mark) => isRecord10(mark) && typeof mark.type === "string").map((mark) => ({
43598
43709
  type: mark.type,
43599
- ...isRecord9(mark.attrs) ? { attrs: mark.attrs } : {}
43710
+ ...isRecord10(mark.attrs) ? { attrs: mark.attrs } : {}
43600
43711
  }))
43601
43712
  } : {}
43602
43713
  };
@@ -43712,7 +43823,7 @@ function collectCartLinkStats(items, depth = 0) {
43712
43823
  return result;
43713
43824
  }
43714
43825
  function isNavigationMenuValidationItem(value) {
43715
- if (!isRecord9(value)) return false;
43826
+ if (!isRecord10(value)) return false;
43716
43827
  return typeof value.label === "string";
43717
43828
  }
43718
43829
 
@@ -44965,24 +45076,24 @@ var ManagementApiError = class extends Error {
44965
45076
  function is404Error(error) {
44966
45077
  return error instanceof ManagementApiError && error.statusCode === 404;
44967
45078
  }
44968
- function isRecord10(value) {
45079
+ function isRecord11(value) {
44969
45080
  return Boolean(value && typeof value === "object" && !Array.isArray(value));
44970
45081
  }
44971
- function isFieldError(value) {
44972
- return isRecord10(value) && typeof value.field === "string" && typeof value.code === "string" && typeof value.message === "string";
45082
+ function isFieldError2(value) {
45083
+ return isRecord11(value) && typeof value.field === "string" && typeof value.code === "string" && typeof value.message === "string";
44973
45084
  }
44974
45085
  function parseApiResponse(value) {
44975
- if (!isRecord10(value)) return null;
45086
+ if (!isRecord11(value)) return null;
44976
45087
  if (value.success === true) {
44977
45088
  return { success: true, data: value.data };
44978
45089
  }
44979
45090
  if (value.success === false) {
44980
45091
  const error = value.error;
44981
- if (!isRecord10(error) || typeof error.code !== "string" || typeof error.message !== "string") {
45092
+ if (!isRecord11(error) || typeof error.code !== "string" || typeof error.message !== "string") {
44982
45093
  return { success: false, error: { code: "sdk:http-error", message: "Request failed", details: error } };
44983
45094
  }
44984
45095
  const fieldErrorsRaw = error.fieldErrors;
44985
- const fieldErrors = Array.isArray(fieldErrorsRaw) ? fieldErrorsRaw.filter(isFieldError) : void 0;
45096
+ const fieldErrors = Array.isArray(fieldErrorsRaw) ? fieldErrorsRaw.filter(isFieldError2) : void 0;
44986
45097
  return {
44987
45098
  success: false,
44988
45099
  error: {
@@ -46512,7 +46623,7 @@ function createListCommand(config2) {
46512
46623
 
46513
46624
  // src/cli/push-config.ts
46514
46625
  var DEFAULT_CONFIG_PATH = "./riverbank.config.ts";
46515
- function isRecord11(value) {
46626
+ function isRecord12(value) {
46516
46627
  return typeof value === "object" && value !== null;
46517
46628
  }
46518
46629
  function parseErrorDetails(value) {
@@ -46520,10 +46631,10 @@ function parseErrorDetails(value) {
46520
46631
  if (typeof value === "string") {
46521
46632
  return { message: value };
46522
46633
  }
46523
- if (!isRecord11(value)) return {};
46634
+ if (!isRecord12(value)) return {};
46524
46635
  const message = typeof value.message === "string" ? value.message : void 0;
46525
46636
  const fieldErrorsRaw = value.fieldErrors;
46526
- const fieldErrors = Array.isArray(fieldErrorsRaw) ? fieldErrorsRaw.filter(isRecord11).map((d) => ({
46637
+ const fieldErrors = Array.isArray(fieldErrorsRaw) ? fieldErrorsRaw.filter(isRecord12).map((d) => ({
46527
46638
  field: typeof d.field === "string" ? d.field : "",
46528
46639
  message: typeof d.message === "string" ? d.message : ""
46529
46640
  })).filter((d) => d.field.length > 0 && d.message.length > 0) : void 0;
@@ -46535,12 +46646,12 @@ function formatFieldErrors(fieldErrors) {
46535
46646
  }
46536
46647
  function getDashboardErrorMessage(responseJson, fallback) {
46537
46648
  if (!responseJson) return fallback;
46538
- if (isRecord11(responseJson) && responseJson.success === false && "error" in responseJson) {
46649
+ if (isRecord12(responseJson) && responseJson.success === false && "error" in responseJson) {
46539
46650
  const parsed = parseErrorDetails(responseJson.error);
46540
46651
  const msg = parsed.message ?? fallback;
46541
46652
  return msg + formatFieldErrors(parsed.fieldErrors);
46542
46653
  }
46543
- if (isRecord11(responseJson) && "error" in responseJson) {
46654
+ if (isRecord12(responseJson) && "error" in responseJson) {
46544
46655
  const parsed = parseErrorDetails(responseJson.error);
46545
46656
  const msg = parsed.message ?? fallback;
46546
46657
  return msg + formatFieldErrors(parsed.fieldErrors);
@@ -46865,7 +46976,7 @@ function duplicateNavigationIdentityMessage(error) {
46865
46976
 
46866
46977
  // src/cli/media/portable.ts
46867
46978
  var ENV_SPECIFIC_MEDIA_KEYS = ["assetId", "storagePath", "storageBucket"];
46868
- var isRecord12 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
46979
+ var isRecord13 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
46869
46980
  var isMediaObject = (value) => value.type === "image" || value.type === "video";
46870
46981
  function stripEnvSpecificMediaFieldsInPlace(value) {
46871
46982
  if (value === null || value === void 0) return;
@@ -46875,7 +46986,7 @@ function stripEnvSpecificMediaFieldsInPlace(value) {
46875
46986
  }
46876
46987
  return;
46877
46988
  }
46878
- if (!isRecord12(value)) return;
46989
+ if (!isRecord13(value)) return;
46879
46990
  if (isMediaObject(value)) {
46880
46991
  const hasCmsRef = typeof value.identifier === "string" || typeof value.assetId === "string" || typeof value.storagePath === "string" || typeof value.storageBucket === "string";
46881
46992
  for (const key of ENV_SPECIFIC_MEDIA_KEYS) {
@@ -46886,7 +46997,7 @@ function stripEnvSpecificMediaFieldsInPlace(value) {
46886
46997
  }
46887
46998
  delete value.mimeType;
46888
46999
  }
46889
- if (value.type === "image" && isRecord12(value.attrs)) {
47000
+ if (value.type === "image" && isRecord13(value.attrs)) {
46890
47001
  const attrs = value.attrs;
46891
47002
  const hasIdentifier = typeof attrs.identifier === "string" && attrs.identifier.trim().length > 0;
46892
47003
  if (hasIdentifier) {
@@ -47058,11 +47169,11 @@ function entryFilePath(input) {
47058
47169
  }
47059
47170
 
47060
47171
  // src/cli/content/writer.ts
47061
- function isRecord13(value) {
47172
+ function isRecord14(value) {
47062
47173
  return typeof value === "object" && value !== null && !Array.isArray(value);
47063
47174
  }
47064
47175
  function parseThemeMeta(value) {
47065
- if (!isRecord13(value) || typeof value.pulledAt !== "string" || !isRecord13(value.themes)) {
47176
+ if (!isRecord14(value) || typeof value.pulledAt !== "string" || !isRecord14(value.themes)) {
47066
47177
  return null;
47067
47178
  }
47068
47179
  return { pulledAt: value.pulledAt, themes: value.themes };
@@ -48497,9 +48608,9 @@ async function localMediaFileExists(filePath) {
48497
48608
  }
48498
48609
 
48499
48610
  // src/cli/media/identifiers.ts
48500
- var isRecord14 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
48611
+ var isRecord15 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
48501
48612
  var isMediaValue = (value) => {
48502
- if (!isRecord14(value)) return false;
48613
+ if (!isRecord15(value)) return false;
48503
48614
  const type = value.type;
48504
48615
  if (type !== "image" && type !== "video" && type !== "audio" && type !== "document" && type !== "spreadsheet" && type !== "archive") return false;
48505
48616
  return typeof value.identifier === "string" || typeof value.assetId === "string" || typeof value.storagePath === "string" || typeof value.src === "string";
@@ -48514,7 +48625,7 @@ var walkMediaValues = (value, location2, handler) => {
48514
48625
  });
48515
48626
  return;
48516
48627
  }
48517
- if (isRecord14(value)) {
48628
+ if (isRecord15(value)) {
48518
48629
  Object.entries(value).forEach(([key, entry]) => {
48519
48630
  walkMediaValues(entry, location2 ? `${location2}.${key}` : key, handler);
48520
48631
  });
@@ -48640,7 +48751,7 @@ var normalizeMediaValueToIdentifierOnly = (value, identifier, asset) => {
48640
48751
  };
48641
48752
 
48642
48753
  // src/cli/media/rich-text.ts
48643
- var isRecord15 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
48754
+ var isRecord16 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
48644
48755
  function collectRichTextImageAttrs(value, out = [], location2 = "") {
48645
48756
  if (Array.isArray(value)) {
48646
48757
  value.forEach(
@@ -48648,8 +48759,8 @@ function collectRichTextImageAttrs(value, out = [], location2 = "") {
48648
48759
  );
48649
48760
  return out;
48650
48761
  }
48651
- if (!isRecord15(value)) return out;
48652
- if (value.type === "image" && isRecord15(value.attrs)) {
48762
+ if (!isRecord16(value)) return out;
48763
+ if (value.type === "image" && isRecord16(value.attrs)) {
48653
48764
  out.push({ attrs: value.attrs, location: location2 ? `${location2}.attrs` : "attrs" });
48654
48765
  }
48655
48766
  for (const [key, child] of Object.entries(value)) {
@@ -52975,7 +53086,7 @@ var isoDateTimeRegex = /^\d{4}-\d{2}-\d{2}T.+/;
52975
53086
  function issue2(path28, message) {
52976
53087
  return { path: path28, message };
52977
53088
  }
52978
- function isRecord16(value) {
53089
+ function isRecord17(value) {
52979
53090
  return typeof value === "object" && value !== null && !Array.isArray(value);
52980
53091
  }
52981
53092
  function isCurrency(value) {
@@ -52991,7 +53102,7 @@ function isWholeMinuteIsoDateTime(value) {
52991
53102
  }
52992
53103
  function validateTicketType(raw, index, currency) {
52993
53104
  const path28 = ["ticketTypes", String(index)];
52994
- if (!isRecord16(raw)) return [issue2(path28, "Ticket type must be an object")];
53105
+ if (!isRecord17(raw)) return [issue2(path28, "Ticket type must be an object")];
52995
53106
  const issues = [];
52996
53107
  const identifier = raw.identifier;
52997
53108
  if (typeof identifier !== "string" || !identifierRegex.test(identifier)) {
@@ -53114,7 +53225,7 @@ function validateTicketTypes(rawTicketTypes, currency) {
53114
53225
  const ticketTypes = [];
53115
53226
  const seenIdentifiers = /* @__PURE__ */ new Set();
53116
53227
  rawTicketTypes.forEach((rawTicketType, index) => {
53117
- const rawIdentifier = isRecord16(rawTicketType) ? rawTicketType.identifier : void 0;
53228
+ const rawIdentifier = isRecord17(rawTicketType) ? rawTicketType.identifier : void 0;
53118
53229
  const hasValidIdentifier = typeof rawIdentifier === "string" && identifierRegex.test(rawIdentifier);
53119
53230
  const isDuplicateIdentifier = hasValidIdentifier && seenIdentifiers.has(rawIdentifier);
53120
53231
  if (isDuplicateIdentifier) {
@@ -53158,7 +53269,7 @@ function classifySdkEventPricing(rawInput) {
53158
53269
  if (rawInput === void 0 || rawInput === null) {
53159
53270
  return { ok: true, pricing: { kind: "free" } };
53160
53271
  }
53161
- if (!isRecord16(rawInput)) {
53272
+ if (!isRecord17(rawInput)) {
53162
53273
  return { ok: false, issues: [issue2([], "Pricing must be an object")] };
53163
53274
  }
53164
53275
  const record = rawInput;
@@ -53268,7 +53379,7 @@ var supportedKinds = /* @__PURE__ */ new Set([
53268
53379
  function issue3(path28, message) {
53269
53380
  return { path: path28, message };
53270
53381
  }
53271
- function isRecord17(value) {
53382
+ function isRecord18(value) {
53272
53383
  return typeof value === "object" && value !== null && !Array.isArray(value);
53273
53384
  }
53274
53385
  function isWholeNumber2(value) {
@@ -53284,7 +53395,7 @@ function isSupportedOptionKind(value) {
53284
53395
  return typeof value === "string" && supportedKinds.has(value);
53285
53396
  }
53286
53397
  function validateFlexibleBalanceDueDateRule(raw, path28) {
53287
- if (!isRecord17(raw)) {
53398
+ if (!isRecord18(raw)) {
53288
53399
  return [issue3(path28, "Flexible balance dueDateRule must be an object")];
53289
53400
  }
53290
53401
  if (raw.kind === "relative_to_start_date") {
@@ -53323,7 +53434,7 @@ function validateFlexibleBalanceDueDateRule(raw, path28) {
53323
53434
  ];
53324
53435
  }
53325
53436
  function validateFlexibleBalanceConfig(raw, path28) {
53326
- if (!isRecord17(raw)) {
53437
+ if (!isRecord18(raw)) {
53327
53438
  return [issue3(path28, "Flexible balance config must be an object")];
53328
53439
  }
53329
53440
  const issues = [];
@@ -53369,7 +53480,7 @@ function validateFlexibleBalanceConfig(raw, path28) {
53369
53480
  }
53370
53481
  function validateCollectionOption(raw, index) {
53371
53482
  const path28 = ["allowedOptions", String(index)];
53372
- if (!isRecord17(raw)) {
53483
+ if (!isRecord18(raw)) {
53373
53484
  return [issue3(path28, "Payment option must be an object")];
53374
53485
  }
53375
53486
  if (raw.kind === "instalment_plan") {
@@ -53440,7 +53551,7 @@ function classifySdkEventPaymentTerms(rawInput) {
53440
53551
  if (rawInput === void 0 || rawInput === null) {
53441
53552
  return { ok: true, paymentTerms: void 0 };
53442
53553
  }
53443
- if (!isRecord17(rawInput)) {
53554
+ if (!isRecord18(rawInput)) {
53444
53555
  return {
53445
53556
  ok: false,
53446
53557
  issues: [issue3([], "Event paymentTerms must be an object")]
@@ -53491,7 +53602,7 @@ function classifySdkEventPaymentTerms(rawInput) {
53491
53602
  function nullishToNull(value) {
53492
53603
  return value == null ? null : value;
53493
53604
  }
53494
- function isRecord18(value) {
53605
+ function isRecord19(value) {
53495
53606
  return typeof value === "object" && value !== null && !Array.isArray(value);
53496
53607
  }
53497
53608
  function stringValue(value, fallback) {
@@ -53512,7 +53623,7 @@ function normalizeEventPaymentTermsForCompare(paymentTerms) {
53512
53623
  return void 0;
53513
53624
  }
53514
53625
  function normalizeVenueAddress(value) {
53515
- const obj = isRecord18(value) ? value : {};
53626
+ const obj = isRecord19(value) ? value : {};
53516
53627
  return {
53517
53628
  line1: nullishToNull(typeof obj.line1 === "string" ? obj.line1 : void 0),
53518
53629
  line2: nullishToNull(typeof obj.line2 === "string" ? obj.line2 : void 0),
@@ -53529,7 +53640,7 @@ function normalizeVenueAddress(value) {
53529
53640
  };
53530
53641
  }
53531
53642
  function normalizeVenueLocation(value) {
53532
- if (!isRecord18(value)) return null;
53643
+ if (!isRecord19(value)) return null;
53533
53644
  const obj = value;
53534
53645
  const lat = typeof obj.lat === "number" ? obj.lat : null;
53535
53646
  const lng = typeof obj.lng === "number" ? obj.lng : null;
@@ -53537,7 +53648,7 @@ function normalizeVenueLocation(value) {
53537
53648
  return { lat, lng };
53538
53649
  }
53539
53650
  function normalizeVenueForCompare(venue) {
53540
- const obj = isRecord18(venue) ? venue : {};
53651
+ const obj = isRecord19(venue) ? venue : {};
53541
53652
  return {
53542
53653
  slug: String(obj.slug),
53543
53654
  title: String(obj.title),
@@ -53558,7 +53669,7 @@ function normalizeVenueForCompare(venue) {
53558
53669
  };
53559
53670
  }
53560
53671
  function normalizeEventCategoryForCompare(category) {
53561
- const obj = isRecord18(category) ? category : {};
53672
+ const obj = isRecord19(category) ? category : {};
53562
53673
  return {
53563
53674
  identifier: String(obj.identifier),
53564
53675
  name: String(obj.name),
@@ -53570,8 +53681,8 @@ function normalizeEventCategoryForCompare(category) {
53570
53681
  };
53571
53682
  }
53572
53683
  function normalizeRemoteEventForCompare(event) {
53573
- const obj = isRecord18(event) ? event : {};
53574
- const schedule = isRecord18(obj.schedule) ? obj.schedule : {};
53684
+ const obj = isRecord19(event) ? event : {};
53685
+ const schedule = isRecord19(obj.schedule) ? obj.schedule : {};
53575
53686
  return {
53576
53687
  identifier: String(obj.identifier),
53577
53688
  title: String(obj.title),
@@ -53600,14 +53711,14 @@ function normalizeRemoteEventForCompare(event) {
53600
53711
  formRef: nullishToNull(
53601
53712
  typeof obj.formRef === "string" ? obj.formRef : void 0
53602
53713
  ),
53603
- content: isRecord18(obj.content) ? obj.content : {},
53604
- settings: isRecord18(obj.settings) ? obj.settings : {},
53605
- presentation: isRecord18(obj.presentation) ? obj.presentation : null,
53714
+ content: isRecord19(obj.content) ? obj.content : {},
53715
+ settings: isRecord19(obj.settings) ? obj.settings : {},
53716
+ presentation: isRecord19(obj.presentation) ? obj.presentation : null,
53606
53717
  tags: Array.isArray(obj.tags) ? obj.tags : []
53607
53718
  };
53608
53719
  }
53609
53720
  function normalizeLocalEventAgainstRemoteForCompare(localEvent, remoteEvent) {
53610
- const local = isRecord18(localEvent) ? localEvent : {};
53721
+ const local = isRecord19(localEvent) ? localEvent : {};
53611
53722
  const base = remoteEvent ? normalizeRemoteEventForCompare(remoteEvent) : normalizeRemoteEventForCompare({
53612
53723
  identifier: local.identifier,
53613
53724
  title: local.title,
@@ -53626,7 +53737,7 @@ function normalizeLocalEventAgainstRemoteForCompare(localEvent, remoteEvent) {
53626
53737
  presentation: local.presentation ?? null,
53627
53738
  tags: local.tags ?? []
53628
53739
  });
53629
- const schedule = isRecord18(local.schedule) ? local.schedule : {};
53740
+ const schedule = isRecord19(local.schedule) ? local.schedule : {};
53630
53741
  return {
53631
53742
  ...base,
53632
53743
  identifier: stringValue(local.identifier, base.identifier),
@@ -53657,9 +53768,9 @@ function normalizeLocalEventAgainstRemoteForCompare(localEvent, remoteEvent) {
53657
53768
  formRef: local.formRef === void 0 ? base.formRef : nullishToNull(
53658
53769
  typeof local.formRef === "string" ? local.formRef : void 0
53659
53770
  ),
53660
- content: local.content === void 0 ? base.content : isRecord18(local.content) ? local.content : {},
53661
- settings: local.settings === void 0 ? base.settings : isRecord18(local.settings) ? local.settings : {},
53662
- presentation: local.presentation === void 0 ? base.presentation : isRecord18(local.presentation) ? local.presentation : null,
53771
+ content: local.content === void 0 ? base.content : isRecord19(local.content) ? local.content : {},
53772
+ settings: local.settings === void 0 ? base.settings : isRecord19(local.settings) ? local.settings : {},
53773
+ presentation: local.presentation === void 0 ? base.presentation : isRecord19(local.presentation) ? local.presentation : null,
53663
53774
  tags: local.tags === void 0 ? base.tags : Array.isArray(local.tags) ? local.tags : []
53664
53775
  };
53665
53776
  }
@@ -53671,7 +53782,7 @@ function toIsoStringOrOriginal(value) {
53671
53782
  function normalizeCourseSessions(value) {
53672
53783
  if (!Array.isArray(value)) return [];
53673
53784
  return value.map((session) => {
53674
- const obj = isRecord18(session) ? session : {};
53785
+ const obj = isRecord19(session) ? session : {};
53675
53786
  return {
53676
53787
  startsAt: toIsoStringOrOriginal(obj.startsAt),
53677
53788
  endsAt: toIsoStringOrOriginal(obj.endsAt)
@@ -53683,18 +53794,18 @@ function normalizeCourseSessions(value) {
53683
53794
  }
53684
53795
  function normalizeCourseProgram(value) {
53685
53796
  if (value == null) return null;
53686
- if (!isRecord18(value)) {
53797
+ if (!isRecord19(value)) {
53687
53798
  return { identifier: null, data: {} };
53688
53799
  }
53689
53800
  return {
53690
53801
  identifier: nullishToNull(
53691
53802
  typeof value.identifier === "string" ? value.identifier : void 0
53692
53803
  ),
53693
- data: isRecord18(value.data) ? value.data : {}
53804
+ data: isRecord19(value.data) ? value.data : {}
53694
53805
  };
53695
53806
  }
53696
53807
  function normalizeRemoteCourseForCompare(course) {
53697
- const obj = isRecord18(course) ? course : {};
53808
+ const obj = isRecord19(course) ? course : {};
53698
53809
  return {
53699
53810
  identifier: String(obj.identifier),
53700
53811
  title: String(obj.title),
@@ -53729,7 +53840,7 @@ function normalizeRemoteCourseForCompare(course) {
53729
53840
  };
53730
53841
  }
53731
53842
  function normalizeLocalCourseAgainstRemoteForCompare(localCourse, remoteCourse) {
53732
- const local = isRecord18(localCourse) ? localCourse : {};
53843
+ const local = isRecord19(localCourse) ? localCourse : {};
53733
53844
  const base = remoteCourse ? normalizeRemoteCourseForCompare(remoteCourse) : normalizeRemoteCourseForCompare({
53734
53845
  identifier: local.identifier,
53735
53846
  title: local.title,
@@ -53750,11 +53861,11 @@ function normalizeLocalCourseAgainstRemoteForCompare(localCourse, remoteCourse)
53750
53861
  });
53751
53862
  const status = local.status === void 0 ? base.status : local.status === "active" || local.status === "cancelled" || local.status === "completed" ? local.status : "draft";
53752
53863
  const visibility = local.visibility === void 0 ? base.visibility : local.visibility === "public" || local.visibility === "private" || local.visibility === "unlisted" ? local.visibility : "public";
53753
- const program2 = local.program === void 0 ? base.program : local.program === null ? null : isRecord18(local.program) ? {
53864
+ const program2 = local.program === void 0 ? base.program : local.program === null ? null : isRecord19(local.program) ? {
53754
53865
  identifier: local.program.identifier === void 0 ? base.program?.identifier ?? null : nullishToNull(
53755
53866
  typeof local.program.identifier === "string" ? local.program.identifier : void 0
53756
53867
  ),
53757
- data: isRecord18(local.program.data) ? local.program.data : base.program?.data ?? {}
53868
+ data: isRecord19(local.program.data) ? local.program.data : base.program?.data ?? {}
53758
53869
  } : base.program;
53759
53870
  return {
53760
53871
  ...base,
@@ -56012,7 +56123,7 @@ function getSiteCommandLifecycleIntent(command) {
56012
56123
  init_src();
56013
56124
 
56014
56125
  // ../site-commands/src/guards.ts
56015
- function isRecord19(value) {
56126
+ function isRecord20(value) {
56016
56127
  return typeof value === "object" && value !== null;
56017
56128
  }
56018
56129
 
@@ -56277,7 +56388,7 @@ function collectVenueRefsFromIntervals(intervals, path28) {
56277
56388
  }
56278
56389
  function collectNavigationRefs(items, path28) {
56279
56390
  return items.flatMap((item, index) => {
56280
- if (!isRecord19(item)) return [];
56391
+ if (!isRecord20(item)) return [];
56281
56392
  const itemPath = `${path28}[${index}]`;
56282
56393
  const refs = [];
56283
56394
  if (typeof item.pageRef === "string") {
@@ -56294,7 +56405,7 @@ function collectNavigationRefs(items, path28) {
56294
56405
  }
56295
56406
  function collectBlockRefs(blocks, path28) {
56296
56407
  return blocks.flatMap((block, index) => {
56297
- if (!isRecord19(block)) return [];
56408
+ if (!isRecord20(block)) return [];
56298
56409
  const blockPath = `${path28}[${index}]`;
56299
56410
  return [
56300
56411
  ...collectNestedRefs(block.props, `${blockPath}.props`),
@@ -56310,7 +56421,7 @@ function collectNestedRefs(value, path28) {
56310
56421
  if (Array.isArray(value)) {
56311
56422
  return value.flatMap((item, index) => collectNestedRefs(item, `${path28}[${index}]`));
56312
56423
  }
56313
- if (!isRecord19(value)) return [];
56424
+ if (!isRecord20(value)) return [];
56314
56425
  return Object.entries(value).flatMap(([key, child]) => collectNestedRefs(child, `${path28}.${key}`));
56315
56426
  }
56316
56427
 
@@ -56566,9 +56677,9 @@ function deriveIdempotencyKey(input) {
56566
56677
  ].join("|"));
56567
56678
  }
56568
56679
  function findUnknownCommandTypes(input) {
56569
- if (!isRecord19(input) || !Array.isArray(input.commands)) return [];
56680
+ if (!isRecord20(input) || !Array.isArray(input.commands)) return [];
56570
56681
  return input.commands.flatMap((command, commandIndex) => {
56571
- if (!isRecord19(command) || typeof command.type !== "string") return [];
56682
+ if (!isRecord20(command) || typeof command.type !== "string") return [];
56572
56683
  if (commandTypeSet.has(command.type)) return [];
56573
56684
  return [{
56574
56685
  code: "unknown_command_type",
@@ -56594,9 +56705,9 @@ function commandIndexForIssuePath(path28) {
56594
56705
  return path28[0] === "commands" && typeof path28[1] === "number" ? path28[1] : -1;
56595
56706
  }
56596
56707
  function commandTypeForIssue(input, commandIndex) {
56597
- if (!isRecord19(input) || !isUnknownArray3(input.commands)) return null;
56708
+ if (!isRecord20(input) || !isUnknownArray3(input.commands)) return null;
56598
56709
  const command = input.commands[commandIndex];
56599
- return isRecord19(command) && typeof command.type === "string" ? command.type : null;
56710
+ return isRecord20(command) && typeof command.type === "string" ? command.type : null;
56600
56711
  }
56601
56712
  function isUnknownArray3(value) {
56602
56713
  return Array.isArray(value);
@@ -57911,8 +58022,8 @@ function eventContentInput(content) {
57911
58022
  if (!content) return void 0;
57912
58023
  return {
57913
58024
  ...content.summary ? { summary: content.summary } : {},
57914
- ...typeof content.body === "string" || isRecord20(content.body) ? { body: content.body } : {},
57915
- ...typeof content.image === "string" || isRecord20(content.image) ? { image: content.image } : {}
58025
+ ...typeof content.body === "string" || isRecord21(content.body) ? { body: content.body } : {},
58026
+ ...typeof content.image === "string" || isRecord21(content.image) ? { image: content.image } : {}
57916
58027
  };
57917
58028
  }
57918
58029
  function courseUpsertInput(command) {
@@ -58093,7 +58204,7 @@ function toUtcIso(date, time) {
58093
58204
  const normalizedTime = time.length === 5 ? `${time}:00` : time;
58094
58205
  return (/* @__PURE__ */ new Date(`${date}T${normalizedTime}Z`)).toISOString();
58095
58206
  }
58096
- function isRecord20(value) {
58207
+ function isRecord21(value) {
58097
58208
  return Boolean(value && typeof value === "object" && !Array.isArray(value));
58098
58209
  }
58099
58210
  function unsupported(identifier, message) {
@@ -64505,7 +64616,7 @@ var THEME_FIELD_CATEGORY_MAP = {
64505
64616
  };
64506
64617
 
64507
64618
  // src/cli/init-docs/zod-to-markdown.ts
64508
- function isRecord21(value) {
64619
+ function isRecord22(value) {
64509
64620
  return typeof value === "object" && value !== null && !Array.isArray(value);
64510
64621
  }
64511
64622
  function isZodTypeAny(value) {
@@ -64633,7 +64744,7 @@ function extractLiteralValue(schema) {
64633
64744
  const typeName = getTypeName(schema);
64634
64745
  if (typeName !== ZodTypeName.ZodLiteral) return void 0;
64635
64746
  const def = schema._def;
64636
- if (!isRecord21(def)) return void 0;
64747
+ if (!isRecord22(def)) return void 0;
64637
64748
  return String(def.value);
64638
64749
  }
64639
64750
  function extractSchemaInfo(schema, skipFields = []) {
@@ -64703,7 +64814,7 @@ function extractFieldInfo(name, schema) {
64703
64814
  }
64704
64815
  if (typeName === ZodTypeName.ZodRecord) {
64705
64816
  const def = inner._def;
64706
- const valueSchema = isRecord21(def) ? def.valueType : void 0;
64817
+ const valueSchema = isRecord22(def) ? def.valueType : void 0;
64707
64818
  if (!isZodTypeAny(valueSchema)) {
64708
64819
  info.recordValueType = "unknown";
64709
64820
  return info;
@@ -64718,7 +64829,7 @@ function extractFieldInfo(name, schema) {
64718
64829
  }
64719
64830
  } else if (getTypeName(valueInner) === ZodTypeName.ZodRecord) {
64720
64831
  const nestedDef = valueInner._def;
64721
- const nestedValueSchema = isRecord21(nestedDef) ? nestedDef.valueType : void 0;
64832
+ const nestedValueSchema = isRecord22(nestedDef) ? nestedDef.valueType : void 0;
64722
64833
  if (!isZodTypeAny(nestedValueSchema)) {
64723
64834
  info.recordValueType = "record<string, unknown>";
64724
64835
  return info;
@@ -64729,7 +64840,7 @@ function extractFieldInfo(name, schema) {
64729
64840
  }
64730
64841
  if (typeName === ZodTypeName.ZodUnion || typeName === ZodTypeName.ZodDiscriminatedUnion) {
64731
64842
  const def = inner._def;
64732
- const optionsValue = isRecord21(def) ? def.options : void 0;
64843
+ const optionsValue = isRecord22(def) ? def.options : void 0;
64733
64844
  const options = Array.isArray(optionsValue) ? optionsValue.filter(isZodTypeAny) : [];
64734
64845
  const optionTypes = options.map((opt) => {
64735
64846
  const { inner: optInner } = unwrapSchema(opt);
@@ -65906,7 +66017,7 @@ var SimpleCache = class {
65906
66017
  };
65907
66018
 
65908
66019
  // src/version.ts
65909
- var SDK_VERSION = "0.92.0";
66020
+ var SDK_VERSION = "0.94.0";
65910
66021
 
65911
66022
  // src/client/error.ts
65912
66023
  var RiverbankApiError = class _RiverbankApiError extends Error {
@@ -73617,20 +73728,20 @@ var LEGACY_DATA_FIELDS = /* @__PURE__ */ new Set([
73617
73728
  "cardTitleOverride",
73618
73729
  "presentation"
73619
73730
  ]);
73620
- function isRecord22(value) {
73731
+ function isRecord23(value) {
73621
73732
  return typeof value === "object" && value !== null && !Array.isArray(value);
73622
73733
  }
73623
73734
  function hasMeaningfulValue(value) {
73624
73735
  if (value === void 0 || value === null) return false;
73625
73736
  if (typeof value === "string") return value.trim().length > 0;
73626
73737
  if (Array.isArray(value)) return value.length > 0;
73627
- if (isRecord22(value)) return Object.keys(value).length > 0;
73738
+ if (isRecord23(value)) return Object.keys(value).length > 0;
73628
73739
  return true;
73629
73740
  }
73630
73741
  function normalizeComparable(value) {
73631
73742
  if (value === void 0 || value === null) return null;
73632
73743
  if (Array.isArray(value)) return value.map(normalizeComparable);
73633
- if (!isRecord22(value)) return value;
73744
+ if (!isRecord23(value)) return value;
73634
73745
  const normalized = {};
73635
73746
  for (const key of Object.keys(value).sort()) {
73636
73747
  const normalizedValue = normalizeComparable(value[key]);
@@ -73650,7 +73761,7 @@ function slugFromPath(value) {
73650
73761
  }
73651
73762
  function legacySlugCandidates(legacy) {
73652
73763
  const candidates = /* @__PURE__ */ new Set();
73653
- const data = isRecord22(legacy.entry.data) ? legacy.entry.data : {};
73764
+ const data = isRecord23(legacy.entry.data) ? legacy.entry.data : {};
73654
73765
  for (const value of [
73655
73766
  legacy.entry.slug,
73656
73767
  data.slug,
@@ -73671,7 +73782,7 @@ async function readLegacyEventEntries(contentDir) {
73671
73782
  const entries = [];
73672
73783
  for (const filePath of files) {
73673
73784
  const raw = await readJsonFile(filePath);
73674
- if (!isRecord22(raw)) {
73785
+ if (!isRecord23(raw)) {
73675
73786
  entries.push({
73676
73787
  tag: "invalid",
73677
73788
  filePath,
@@ -73679,7 +73790,7 @@ async function readLegacyEventEntries(contentDir) {
73679
73790
  });
73680
73791
  continue;
73681
73792
  }
73682
- if (!isRecord22(raw.data)) {
73793
+ if (!isRecord23(raw.data)) {
73683
73794
  entries.push({
73684
73795
  tag: "invalid",
73685
73796
  filePath,
@@ -73817,7 +73928,7 @@ function mergeLegacyEventIntoCanonical(legacy, event) {
73817
73928
  conflicts.push(...blocksResult.fields);
73818
73929
  }
73819
73930
  if (hasMeaningfulValue(data.presentation)) {
73820
- if (!isRecord22(data.presentation)) {
73931
+ if (!isRecord23(data.presentation)) {
73821
73932
  return { tag: "unmappable", fields: ["data.presentation"] };
73822
73933
  }
73823
73934
  for (const [key, value] of Object.entries(data.presentation)) {