@workflow/web 4.1.9 → 4.1.11

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 (22) hide show
  1. package/build/client/assets/{encryption-5eom23r0.js → encryption-Bd25Keng.js} +21 -2
  2. package/build/client/assets/{entry.client-BWsSsWQm.js → entry.client-DtOpLtMQ.js} +1 -1
  3. package/build/client/assets/{highlighted-body-B3W2YXNL-9Gx_xbQ8.js → highlighted-body-B3W2YXNL-BmmQMQWQ.js} +2 -2
  4. package/build/client/assets/{home-D6JmZfUp.js → home-D5gYz0XH.js} +4 -3
  5. package/build/client/assets/index-7hulCzI_.js +275 -0
  6. package/build/client/assets/{index-DQa-BExo.js → index-BsV8i_Jn.js} +20 -20
  7. package/build/client/assets/manifest-a1c479ba.js +1 -0
  8. package/build/client/assets/{mermaid-3ZIDBTTL-CjHrXABH.js → mermaid-3ZIDBTTL-CWOyQBTZ.js} +269 -321
  9. package/build/client/assets/{root--_OYilvb.js → root-axkUVsvL.js} +2 -2
  10. package/build/client/assets/{run-detail-BeA7fQfA.js → run-detail-ldKIjs8Z.js} +18 -16
  11. package/build/client/assets/{workflow-graph-viewer-BNsGQIfR.js → workflow-graph-viewer-CLv3yYv8.js} +3 -3
  12. package/build/server/assets/{app-BEUod6Qu.js → app-BR0o9iNl.js} +2 -2
  13. package/build/server/assets/{highlighted-body-B3W2YXNL-CDACB73g.js → highlighted-body-B3W2YXNL-BeWNj3yf.js} +2 -2
  14. package/build/server/assets/index-B8YoYr9f.js +1117 -0
  15. package/build/server/assets/{index-sVIARIAL.js → index-rguLY73T.js} +12 -9
  16. package/build/server/assets/{mermaid-3ZIDBTTL-jCjKhJD2.js → mermaid-3ZIDBTTL-Akc2Gx2g.js} +2 -2
  17. package/build/server/assets/{server-build-JwomDvSn.js → server-build-dI1gM6-m.js} +3270 -2655
  18. package/build/server/assets/{token-9ZMCuQFa.js → token-D7Mmh4mK.js} +2 -2
  19. package/build/server/assets/{token-util--ZOQJ_0a.js → token-util-DvAHyiW3.js} +2 -2
  20. package/build/server/index.js +1 -1
  21. package/package.json +8 -8
  22. package/build/client/assets/manifest-3243993f.js +0 -1
@@ -1,9 +1,9 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/highlighted-body-B3W2YXNL-9Gx_xbQ8.js","assets/index-DQa-BExo.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/encryption-Bd25Keng.js","assets/index-7hulCzI_.js","assets/index-BsV8i_Jn.js","assets/highlighted-body-B3W2YXNL-BmmQMQWQ.js"])))=>i.map(i=>d[i]);
2
2
  var __defProp = Object.defineProperty;
3
3
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4
4
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
5
- var _a2;
6
- import { r as reactExports, j as jsxRuntimeExports, f as reactDomExports, H as React, R as ReactExports, C as ReactDOM, I as getDefaultExportFromCjs } from "./index-DQa-BExo.js";
5
+ var _a2, _b;
6
+ import { r as reactExports, j as jsxRuntimeExports, f as reactDomExports, I as React, R as ReactExports, D as ReactDOM, g as getDefaultExportFromCjs } from "./index-BsV8i_Jn.js";
7
7
  function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {
8
8
  return function handleEvent(event) {
9
9
  originalEventHandler == null ? void 0 : originalEventHandler(event);
@@ -200,13 +200,13 @@ function mergeProps$1(slotProps, childProps) {
200
200
  return { ...slotProps, ...overrideProps };
201
201
  }
202
202
  function getElementRef$2(element2) {
203
- var _a3, _b;
203
+ var _a3, _b2;
204
204
  let getter = (_a3 = Object.getOwnPropertyDescriptor(element2.props, "ref")) == null ? void 0 : _a3.get;
205
205
  let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
206
206
  if (mayWarn) {
207
207
  return element2.ref;
208
208
  }
209
- getter = (_b = Object.getOwnPropertyDescriptor(element2, "ref")) == null ? void 0 : _b.get;
209
+ getter = (_b2 = Object.getOwnPropertyDescriptor(element2, "ref")) == null ? void 0 : _b2.get;
210
210
  mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
211
211
  if (mayWarn) {
212
212
  return element2.props.ref;
@@ -2443,7 +2443,7 @@ var CONTENT_NAME$1 = "PopperContent";
2443
2443
  var [PopperContentProvider, useContentContext] = createPopperContext(CONTENT_NAME$1);
2444
2444
  var PopperContent = reactExports.forwardRef(
2445
2445
  (props, forwardedRef) => {
2446
- var _a3, _b, _c, _d, _e2, _f;
2446
+ var _a3, _b2, _c, _d, _e2, _f;
2447
2447
  const {
2448
2448
  __scopePopper,
2449
2449
  side = "bottom",
@@ -2523,7 +2523,7 @@ var PopperContent = reactExports.forwardRef(
2523
2523
  }
2524
2524
  }, [isPositioned, handlePlaced]);
2525
2525
  const arrowX = (_a3 = middlewareData.arrow) == null ? void 0 : _a3.x;
2526
- const arrowY = (_b = middlewareData.arrow) == null ? void 0 : _b.y;
2526
+ const arrowY = (_b2 = middlewareData.arrow) == null ? void 0 : _b2.y;
2527
2527
  const cannotCenterArrow = ((_c = middlewareData.arrow) == null ? void 0 : _c.centerOffset) !== 0;
2528
2528
  const [contentZIndex, setContentZIndex] = reactExports.useState();
2529
2529
  useLayoutEffect2(() => {
@@ -2646,7 +2646,7 @@ var transformOrigin = (options) => ({
2646
2646
  name: "transformOrigin",
2647
2647
  options,
2648
2648
  fn(data) {
2649
- var _a3, _b, _c;
2649
+ var _a3, _b2, _c;
2650
2650
  const { placement, rects, middlewareData } = data;
2651
2651
  const cannotCenterArrow = ((_a3 = middlewareData.arrow) == null ? void 0 : _a3.centerOffset) !== 0;
2652
2652
  const isArrowHidden = cannotCenterArrow;
@@ -2654,7 +2654,7 @@ var transformOrigin = (options) => ({
2654
2654
  const arrowHeight = isArrowHidden ? 0 : options.arrowHeight;
2655
2655
  const [placedSide, placedAlign] = getSideAndAlignFromPlacement(placement);
2656
2656
  const noArrowAlign = { start: "0%", center: "50%", end: "100%" }[placedAlign];
2657
- const arrowXCenter = (((_b = middlewareData.arrow) == null ? void 0 : _b.x) ?? 0) + arrowWidth / 2;
2657
+ const arrowXCenter = (((_b2 = middlewareData.arrow) == null ? void 0 : _b2.x) ?? 0) + arrowWidth / 2;
2658
2658
  const arrowYCenter = (((_c = middlewareData.arrow) == null ? void 0 : _c.y) ?? 0) + arrowHeight / 2;
2659
2659
  let x2 = "";
2660
2660
  let y2 = "";
@@ -2792,13 +2792,13 @@ function getAnimationName(styles2) {
2792
2792
  return (styles2 == null ? void 0 : styles2.animationName) || "none";
2793
2793
  }
2794
2794
  function getElementRef$1(element2) {
2795
- var _a3, _b;
2795
+ var _a3, _b2;
2796
2796
  let getter = (_a3 = Object.getOwnPropertyDescriptor(element2.props, "ref")) == null ? void 0 : _a3.get;
2797
2797
  let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
2798
2798
  if (mayWarn) {
2799
2799
  return element2.ref;
2800
2800
  }
2801
- getter = (_b = Object.getOwnPropertyDescriptor(element2, "ref")) == null ? void 0 : _b.get;
2801
+ getter = (_b2 = Object.getOwnPropertyDescriptor(element2, "ref")) == null ? void 0 : _b2.get;
2802
2802
  mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
2803
2803
  if (mayWarn) {
2804
2804
  return element2.props.ref;
@@ -10060,44 +10060,6 @@ const __vitePreload = function preload(baseModule, deps, importerUrl) {
10060
10060
  return baseModule().catch(handlePreloadError);
10061
10061
  });
10062
10062
  };
10063
- function decode64(string2) {
10064
- const binaryString = asciiToBinary(string2);
10065
- const arraybuffer = new ArrayBuffer(binaryString.length);
10066
- const dv = new DataView(arraybuffer);
10067
- for (let i = 0; i < arraybuffer.byteLength; i++) {
10068
- dv.setUint8(i, binaryString.charCodeAt(i));
10069
- }
10070
- return arraybuffer;
10071
- }
10072
- const KEY_STRING = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
10073
- function asciiToBinary(data) {
10074
- if (data.length % 4 === 0) {
10075
- data = data.replace(/==?$/, "");
10076
- }
10077
- let output = "";
10078
- let buffer = 0;
10079
- let accumulatedBits = 0;
10080
- for (let i = 0; i < data.length; i++) {
10081
- buffer <<= 6;
10082
- buffer |= KEY_STRING.indexOf(data[i]);
10083
- accumulatedBits += 6;
10084
- if (accumulatedBits === 24) {
10085
- output += String.fromCharCode((buffer & 16711680) >> 16);
10086
- output += String.fromCharCode((buffer & 65280) >> 8);
10087
- output += String.fromCharCode(buffer & 255);
10088
- buffer = accumulatedBits = 0;
10089
- }
10090
- }
10091
- if (accumulatedBits === 12) {
10092
- buffer >>= 4;
10093
- output += String.fromCharCode(buffer);
10094
- } else if (accumulatedBits === 18) {
10095
- buffer >>= 2;
10096
- output += String.fromCharCode((buffer & 65280) >> 8);
10097
- output += String.fromCharCode(buffer & 255);
10098
- }
10099
- return output;
10100
- }
10101
10063
  const UNDEFINED = -1;
10102
10064
  const HOLE = -2;
10103
10065
  const NAN = -3;
@@ -10105,6 +10067,38 @@ const POSITIVE_INFINITY = -4;
10105
10067
  const NEGATIVE_INFINITY = -5;
10106
10068
  const NEGATIVE_ZERO = -6;
10107
10069
  const SPARSE = -7;
10070
+ const MAX_ARRAY_LEN = 2 ** 32 - 1;
10071
+ const MAX_ARRAY_INDEX = MAX_ARRAY_LEN - 1;
10072
+ function is_valid_array_index(n) {
10073
+ if (!Number.isInteger(n)) return false;
10074
+ if (n < 0) return false;
10075
+ if (n > MAX_ARRAY_INDEX) return false;
10076
+ return true;
10077
+ }
10078
+ function is_valid_array_len(n) {
10079
+ if (!Number.isInteger(n)) return false;
10080
+ if (n < 0) return false;
10081
+ if (n > MAX_ARRAY_LEN) return false;
10082
+ return true;
10083
+ }
10084
+ function decode_native(base642) {
10085
+ return Uint8Array.fromBase64(base642).buffer;
10086
+ }
10087
+ function decode_buffer(base642) {
10088
+ return Uint8Array.from(Buffer.from(base642, "base64")).buffer;
10089
+ }
10090
+ function decode_legacy(base642) {
10091
+ const binary_string = atob(base642);
10092
+ const len = binary_string.length;
10093
+ const array2 = new Uint8Array(len);
10094
+ for (let i = 0; i < len; i++) {
10095
+ array2[i] = binary_string.charCodeAt(i);
10096
+ }
10097
+ return array2.buffer;
10098
+ }
10099
+ const native = typeof Uint8Array.fromBase64 === "function";
10100
+ const buffer = typeof process === "object" && ((_a2 = process.versions) == null ? void 0 : _a2.node) !== void 0;
10101
+ const decode64 = native ? decode_native : buffer ? decode_buffer : decode_legacy;
10108
10102
  function parse$4(serialized, revivers) {
10109
10103
  return unflatten(JSON.parse(serialized), revivers);
10110
10104
  }
@@ -10171,9 +10165,14 @@ function unflatten(parsed, revivers) {
10171
10165
  case "RegExp":
10172
10166
  hydrated[index2] = new RegExp(value[1], value[2]);
10173
10167
  break;
10174
- case "Object":
10175
- hydrated[index2] = Object(value[1]);
10168
+ case "Object": {
10169
+ const wrapped_index = value[1];
10170
+ if (typeof values[wrapped_index] === "object" && values[wrapped_index][0] !== "BigInt") {
10171
+ throw new Error("Invalid input");
10172
+ }
10173
+ hydrated[index2] = Object(hydrate(wrapped_index));
10176
10174
  break;
10175
+ }
10177
10176
  case "BigInt":
10178
10177
  hydrated[index2] = BigInt(value[1]);
10179
10178
  break;
@@ -10181,6 +10180,9 @@ function unflatten(parsed, revivers) {
10181
10180
  const obj = /* @__PURE__ */ Object.create(null);
10182
10181
  hydrated[index2] = obj;
10183
10182
  for (let i = 1; i < value.length; i += 2) {
10183
+ if (value[i] === "__proto__") {
10184
+ throw new Error("Cannot parse an object with a `__proto__` property");
10185
+ }
10184
10186
  obj[value[i]] = hydrate(value[i + 1]);
10185
10187
  }
10186
10188
  break;
@@ -10189,19 +10191,20 @@ function unflatten(parsed, revivers) {
10189
10191
  case "Uint8ClampedArray":
10190
10192
  case "Int16Array":
10191
10193
  case "Uint16Array":
10194
+ case "Float16Array":
10192
10195
  case "Int32Array":
10193
10196
  case "Uint32Array":
10194
10197
  case "Float32Array":
10195
10198
  case "Float64Array":
10196
10199
  case "BigInt64Array":
10197
- case "BigUint64Array": {
10200
+ case "BigUint64Array":
10201
+ case "DataView": {
10198
10202
  if (values[value[1]][0] !== "ArrayBuffer") {
10199
10203
  throw new Error("Invalid data");
10200
10204
  }
10201
10205
  const TypedArrayConstructor = globalThis[type];
10202
- const buffer = hydrate(value[1]);
10203
- const typedArray = new TypedArrayConstructor(buffer);
10204
- hydrated[index2] = value[2] !== void 0 ? typedArray.subarray(value[2], value[3]) : typedArray;
10206
+ const buffer2 = hydrate(value[1]);
10207
+ hydrated[index2] = value[2] !== void 0 ? new TypedArrayConstructor(buffer2, value[2], value[3]) : new TypedArrayConstructor(buffer2);
10205
10208
  break;
10206
10209
  }
10207
10210
  case "ArrayBuffer": {
@@ -10240,12 +10243,21 @@ function unflatten(parsed, revivers) {
10240
10243
  }
10241
10244
  } else if (value[0] === SPARSE) {
10242
10245
  const len = value[1];
10243
- const array2 = new Array(len);
10246
+ if (!is_valid_array_len(len)) {
10247
+ throw new Error("Invalid input");
10248
+ }
10249
+ const array2 = [];
10244
10250
  hydrated[index2] = array2;
10251
+ array2[MAX_ARRAY_INDEX] = void 0;
10252
+ delete array2[MAX_ARRAY_INDEX];
10245
10253
  for (let i = 2; i < value.length; i += 2) {
10246
10254
  const idx = value[i];
10255
+ if (!is_valid_array_index(idx) || idx >= len) {
10256
+ throw new Error("Invalid input");
10257
+ }
10247
10258
  array2[idx] = hydrate(value[i + 1]);
10248
10259
  }
10260
+ array2.length = len;
10249
10261
  } else {
10250
10262
  const array2 = new Array(value.length);
10251
10263
  hydrated[index2] = array2;
@@ -10340,9 +10352,9 @@ function hydrateData(value, revivers) {
10340
10352
  async function hydrateDataWithKey(value, revivers, key) {
10341
10353
  if (value instanceof Uint8Array && isEncryptedData(value) && key) {
10342
10354
  const { decrypt } = await __vitePreload(async () => {
10343
- const { decrypt: decrypt2 } = await import("./encryption-5eom23r0.js");
10355
+ const { decrypt: decrypt2 } = await import("./encryption-Bd25Keng.js");
10344
10356
  return { decrypt: decrypt2 };
10345
- }, true ? [] : void 0);
10357
+ }, true ? __vite__mapDeps([0,1,2]) : void 0);
10346
10358
  const { payload } = decodeFormatPrefix(value);
10347
10359
  const decrypted = await decrypt(key, payload);
10348
10360
  return hydrateData(decrypted, revivers);
@@ -10580,10 +10592,10 @@ function $constructor(name2, initializer2, params) {
10580
10592
  Object.defineProperty(_2, "init", { value: init });
10581
10593
  Object.defineProperty(_2, Symbol.hasInstance, {
10582
10594
  value: (inst) => {
10583
- var _a3, _b;
10595
+ var _a3, _b2;
10584
10596
  if ((params == null ? void 0 : params.Parent) && inst instanceof params.Parent)
10585
10597
  return true;
10586
- return (_b = (_a3 = inst == null ? void 0 : inst._zod) == null ? void 0 : _a3.traits) == null ? void 0 : _b.has(name2);
10598
+ return (_b2 = (_a3 = inst == null ? void 0 : inst._zod) == null ? void 0 : _a3.traits) == null ? void 0 : _b2.has(name2);
10587
10599
  }
10588
10600
  });
10589
10601
  Object.defineProperty(_2, "name", { value: name2 });
@@ -10735,7 +10747,6 @@ function shallowClone(o) {
10735
10747
  return o;
10736
10748
  }
10737
10749
  const propertyKeyTypes = /* @__PURE__ */ new Set(["string", "number", "symbol"]);
10738
- const primitiveTypes = /* @__PURE__ */ new Set(["string", "number", "bigint", "boolean", "symbol", "undefined"]);
10739
10750
  function escapeRegex(str) {
10740
10751
  return str.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
10741
10752
  }
@@ -10966,10 +10977,10 @@ function unwrapMessage(message) {
10966
10977
  return typeof message === "string" ? message : message == null ? void 0 : message.message;
10967
10978
  }
10968
10979
  function finalizeIssue(iss, ctx, config2) {
10969
- var _a3, _b, _c, _d, _e2, _f;
10980
+ var _a3, _b2, _c, _d, _e2, _f;
10970
10981
  const full = { ...iss, path: iss.path ?? [] };
10971
10982
  if (!iss.message) {
10972
- const message = unwrapMessage((_c = (_b = (_a3 = iss.inst) == null ? void 0 : _a3._zod.def) == null ? void 0 : _b.error) == null ? void 0 : _c.call(_b, iss)) ?? unwrapMessage((_d = ctx == null ? void 0 : ctx.error) == null ? void 0 : _d.call(ctx, iss)) ?? unwrapMessage((_e2 = config2.customError) == null ? void 0 : _e2.call(config2, iss)) ?? unwrapMessage((_f = config2.localeError) == null ? void 0 : _f.call(config2, iss)) ?? "Invalid input";
10983
+ const message = unwrapMessage((_c = (_b2 = (_a3 = iss.inst) == null ? void 0 : _a3._zod.def) == null ? void 0 : _b2.error) == null ? void 0 : _c.call(_b2, iss)) ?? unwrapMessage((_d = ctx == null ? void 0 : ctx.error) == null ? void 0 : _d.call(ctx, iss)) ?? unwrapMessage((_e2 = config2.customError) == null ? void 0 : _e2.call(config2, iss)) ?? unwrapMessage((_f = config2.localeError) == null ? void 0 : _f.call(config2, iss)) ?? "Invalid input";
10973
10984
  full.message = message;
10974
10985
  }
10975
10986
  delete full.inst;
@@ -11453,7 +11464,7 @@ const $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEqual
11453
11464
  };
11454
11465
  });
11455
11466
  const $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringFormat", (inst, def) => {
11456
- var _a3, _b;
11467
+ var _a3, _b2;
11457
11468
  $ZodCheck.init(inst, def);
11458
11469
  inst._zod.onattach.push((inst2) => {
11459
11470
  const bag = inst2._zod.bag;
@@ -11479,7 +11490,7 @@ const $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringForma
11479
11490
  });
11480
11491
  });
11481
11492
  else
11482
- (_b = inst._zod).check ?? (_b.check = () => {
11493
+ (_b2 = inst._zod).check ?? (_b2.check = () => {
11483
11494
  });
11484
11495
  });
11485
11496
  const $ZodCheckRegex = /* @__PURE__ */ $constructor("$ZodCheckRegex", (inst, def) => {
@@ -12212,10 +12223,10 @@ function handlePropertyResult(result, final, key, input, isOptionalOut) {
12212
12223
  }
12213
12224
  }
12214
12225
  function normalizeDef(def) {
12215
- var _a3, _b, _c, _d;
12226
+ var _a3, _b2, _c, _d;
12216
12227
  const keys2 = Object.keys(def.shape);
12217
12228
  for (const k2 of keys2) {
12218
- if (!((_d = (_c = (_b = (_a3 = def.shape) == null ? void 0 : _a3[k2]) == null ? void 0 : _b._zod) == null ? void 0 : _c.traits) == null ? void 0 : _d.has("$ZodType"))) {
12229
+ if (!((_d = (_c = (_b2 = (_a3 = def.shape) == null ? void 0 : _a3[k2]) == null ? void 0 : _b2._zod) == null ? void 0 : _c.traits) == null ? void 0 : _d.has("$ZodType"))) {
12219
12230
  throw new Error(`Invalid element at key "${k2}": expected a Zod schema`);
12220
12231
  }
12221
12232
  }
@@ -13019,12 +13030,12 @@ const $ZodReadonly = /* @__PURE__ */ $constructor("$ZodReadonly", (inst, def) =>
13019
13030
  defineLazy(inst._zod, "propValues", () => def.innerType._zod.propValues);
13020
13031
  defineLazy(inst._zod, "values", () => def.innerType._zod.values);
13021
13032
  defineLazy(inst._zod, "optin", () => {
13022
- var _a3, _b;
13023
- return (_b = (_a3 = def.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b.optin;
13033
+ var _a3, _b2;
13034
+ return (_b2 = (_a3 = def.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b2.optin;
13024
13035
  });
13025
13036
  defineLazy(inst._zod, "optout", () => {
13026
- var _a3, _b;
13027
- return (_b = (_a3 = def.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b.optout;
13037
+ var _a3, _b2;
13038
+ return (_b2 = (_a3 = def.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b2.optout;
13028
13039
  });
13029
13040
  inst._zod.parse = (payload, ctx) => {
13030
13041
  if (ctx.direction === "backward") {
@@ -13041,69 +13052,24 @@ function handleReadonlyResult(payload) {
13041
13052
  payload.value = Object.freeze(payload.value);
13042
13053
  return payload;
13043
13054
  }
13044
- const $ZodTemplateLiteral = /* @__PURE__ */ $constructor("$ZodTemplateLiteral", (inst, def) => {
13045
- $ZodType.init(inst, def);
13046
- const regexParts = [];
13047
- for (const part of def.parts) {
13048
- if (typeof part === "object" && part !== null) {
13049
- if (!part._zod.pattern) {
13050
- throw new Error(`Invalid template literal part, no pattern found: ${[...part._zod.traits].shift()}`);
13051
- }
13052
- const source = part._zod.pattern instanceof RegExp ? part._zod.pattern.source : part._zod.pattern;
13053
- if (!source)
13054
- throw new Error(`Invalid template literal part: ${part._zod.traits}`);
13055
- const start = source.startsWith("^") ? 1 : 0;
13056
- const end = source.endsWith("$") ? source.length - 1 : source.length;
13057
- regexParts.push(source.slice(start, end));
13058
- } else if (part === null || primitiveTypes.has(typeof part)) {
13059
- regexParts.push(escapeRegex(`${part}`));
13060
- } else {
13061
- throw new Error(`Invalid template literal part: ${part}`);
13062
- }
13063
- }
13064
- inst._zod.pattern = new RegExp(`^${regexParts.join("")}$`);
13065
- inst._zod.parse = (payload, _ctx) => {
13066
- if (typeof payload.value !== "string") {
13067
- payload.issues.push({
13068
- input: payload.value,
13069
- inst,
13070
- expected: "string",
13071
- code: "invalid_type"
13072
- });
13073
- return payload;
13074
- }
13075
- inst._zod.pattern.lastIndex = 0;
13076
- if (!inst._zod.pattern.test(payload.value)) {
13077
- payload.issues.push({
13078
- input: payload.value,
13079
- inst,
13080
- code: "invalid_format",
13081
- format: def.format ?? "template_literal",
13082
- pattern: inst._zod.pattern.source
13083
- });
13084
- return payload;
13085
- }
13086
- return payload;
13087
- };
13088
- });
13089
13055
  const $ZodLazy = /* @__PURE__ */ $constructor("$ZodLazy", (inst, def) => {
13090
13056
  $ZodType.init(inst, def);
13091
13057
  defineLazy(inst._zod, "innerType", () => def.getter());
13092
13058
  defineLazy(inst._zod, "pattern", () => {
13093
- var _a3, _b;
13094
- return (_b = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b.pattern;
13059
+ var _a3, _b2;
13060
+ return (_b2 = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b2.pattern;
13095
13061
  });
13096
13062
  defineLazy(inst._zod, "propValues", () => {
13097
- var _a3, _b;
13098
- return (_b = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b.propValues;
13063
+ var _a3, _b2;
13064
+ return (_b2 = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b2.propValues;
13099
13065
  });
13100
13066
  defineLazy(inst._zod, "optin", () => {
13101
- var _a3, _b;
13102
- return ((_b = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b.optin) ?? void 0;
13067
+ var _a3, _b2;
13068
+ return ((_b2 = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b2.optin) ?? void 0;
13103
13069
  });
13104
13070
  defineLazy(inst._zod, "optout", () => {
13105
- var _a3, _b;
13106
- return ((_b = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b.optout) ?? void 0;
13071
+ var _a3, _b2;
13072
+ return ((_b2 = (_a3 = inst._zod.innerType) == null ? void 0 : _a3._zod) == null ? void 0 : _b2.optout) ?? void 0;
13107
13073
  });
13108
13074
  inst._zod.parse = (payload, ctx) => {
13109
13075
  const inner = inst._zod.innerType;
@@ -13745,8 +13711,8 @@ function initializeContext(params) {
13745
13711
  external: (params == null ? void 0 : params.external) ?? void 0
13746
13712
  };
13747
13713
  }
13748
- function process(schema, ctx, _params = { path: [], schemaPath: [] }) {
13749
- var _a4, _b;
13714
+ function process$1(schema, ctx, _params = { path: [], schemaPath: [] }) {
13715
+ var _a4, _b2;
13750
13716
  var _a3;
13751
13717
  const def = schema._zod.def;
13752
13718
  const seen2 = ctx.seen.get(schema);
@@ -13760,7 +13726,7 @@ function process(schema, ctx, _params = { path: [], schemaPath: [] }) {
13760
13726
  }
13761
13727
  const result = { schema: {}, count: 1, cycle: void 0, path: _params.path };
13762
13728
  ctx.seen.set(schema, result);
13763
- const overrideSchema = (_b = (_a4 = schema._zod).toJSONSchema) == null ? void 0 : _b.call(_a4);
13729
+ const overrideSchema = (_b2 = (_a4 = schema._zod).toJSONSchema) == null ? void 0 : _b2.call(_a4);
13764
13730
  if (overrideSchema) {
13765
13731
  result.schema = overrideSchema;
13766
13732
  } else {
@@ -13783,7 +13749,7 @@ function process(schema, ctx, _params = { path: [], schemaPath: [] }) {
13783
13749
  if (parent) {
13784
13750
  if (!result.ref)
13785
13751
  result.ref = parent;
13786
- process(parent, ctx, params);
13752
+ process$1(parent, ctx, params);
13787
13753
  ctx.seen.get(parent).isParent = true;
13788
13754
  }
13789
13755
  }
@@ -13801,7 +13767,7 @@ function process(schema, ctx, _params = { path: [], schemaPath: [] }) {
13801
13767
  return _result.schema;
13802
13768
  }
13803
13769
  function extractDefs(ctx, schema) {
13804
- var _a3, _b, _c, _d;
13770
+ var _a3, _b2, _c, _d;
13805
13771
  const root2 = ctx.seen.get(schema);
13806
13772
  if (!root2)
13807
13773
  throw new Error("Unprocessed schema. This is a bug in Zod.");
@@ -13856,7 +13822,7 @@ function extractDefs(ctx, schema) {
13856
13822
  for (const entry of ctx.seen.entries()) {
13857
13823
  const seen2 = entry[1];
13858
13824
  if (seen2.cycle) {
13859
- throw new Error(`Cycle detected: #/${(_b = seen2.cycle) == null ? void 0 : _b.join("/")}/<root>
13825
+ throw new Error(`Cycle detected: #/${(_b2 = seen2.cycle) == null ? void 0 : _b2.join("/")}/<root>
13860
13826
 
13861
13827
  Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`);
13862
13828
  }
@@ -13893,7 +13859,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
13893
13859
  }
13894
13860
  }
13895
13861
  function finalize(ctx, schema) {
13896
- var _a3, _b, _c;
13862
+ var _a3, _b2, _c;
13897
13863
  const root2 = ctx.seen.get(schema);
13898
13864
  if (!root2)
13899
13865
  throw new Error("Unprocessed schema. This is a bug in Zod.");
@@ -13972,7 +13938,7 @@ function finalize(ctx, schema) {
13972
13938
  } else if (ctx.target === "openapi-3.0") ;
13973
13939
  else ;
13974
13940
  if ((_a3 = ctx.external) == null ? void 0 : _a3.uri) {
13975
- const id = (_b = ctx.external.registry.get(schema)) == null ? void 0 : _b.id;
13941
+ const id = (_b2 = ctx.external.registry.get(schema)) == null ? void 0 : _b2.id;
13976
13942
  if (!id)
13977
13943
  throw new Error("Schema is missing an `id` property");
13978
13944
  result.$id = ctx.external.uri(id);
@@ -14066,14 +14032,14 @@ function isTransforming(_schema, _ctx) {
14066
14032
  }
14067
14033
  const createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
14068
14034
  const ctx = initializeContext({ ...params, processors });
14069
- process(schema, ctx);
14035
+ process$1(schema, ctx);
14070
14036
  extractDefs(ctx, schema);
14071
14037
  return finalize(ctx, schema);
14072
14038
  };
14073
14039
  const createStandardJSONSchemaMethod = (schema, io2, processors = {}) => (params) => {
14074
14040
  const { libraryOptions, target: target2 } = params ?? {};
14075
14041
  const ctx = initializeContext({ ...libraryOptions ?? {}, target: target2, io: io2, processors });
14076
- process(schema, ctx);
14042
+ process$1(schema, ctx);
14077
14043
  extractDefs(ctx, schema);
14078
14044
  return finalize(ctx, schema);
14079
14045
  };
@@ -14238,14 +14204,6 @@ const literalProcessor = (schema, ctx, json, _params) => {
14238
14204
  json.enum = vals;
14239
14205
  }
14240
14206
  };
14241
- const templateLiteralProcessor = (schema, _ctx, json, _params) => {
14242
- const _json = json;
14243
- const pattern = schema._zod.pattern;
14244
- if (!pattern)
14245
- throw new Error("Pattern not found in template literal");
14246
- _json.type = "string";
14247
- _json.pattern = pattern.source;
14248
- };
14249
14207
  const customProcessor = (_schema, ctx, _json, _params) => {
14250
14208
  if (ctx.unrepresentable === "throw") {
14251
14209
  throw new Error("Custom types cannot be represented in JSON Schema");
@@ -14265,7 +14223,7 @@ const arrayProcessor = (schema, ctx, _json, params) => {
14265
14223
  if (typeof maximum === "number")
14266
14224
  json.maxItems = maximum;
14267
14225
  json.type = "array";
14268
- json.items = process(def.element, ctx, { ...params, path: [...params.path, "items"] });
14226
+ json.items = process$1(def.element, ctx, { ...params, path: [...params.path, "items"] });
14269
14227
  };
14270
14228
  const objectProcessor = (schema, ctx, _json, params) => {
14271
14229
  var _a3;
@@ -14275,7 +14233,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
14275
14233
  json.properties = {};
14276
14234
  const shape = def.shape;
14277
14235
  for (const key in shape) {
14278
- json.properties[key] = process(shape[key], ctx, {
14236
+ json.properties[key] = process$1(shape[key], ctx, {
14279
14237
  ...params,
14280
14238
  path: [...params.path, "properties", key]
14281
14239
  });
@@ -14298,7 +14256,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
14298
14256
  if (ctx.io === "output")
14299
14257
  json.additionalProperties = false;
14300
14258
  } else if (def.catchall) {
14301
- json.additionalProperties = process(def.catchall, ctx, {
14259
+ json.additionalProperties = process$1(def.catchall, ctx, {
14302
14260
  ...params,
14303
14261
  path: [...params.path, "additionalProperties"]
14304
14262
  });
@@ -14307,7 +14265,7 @@ const objectProcessor = (schema, ctx, _json, params) => {
14307
14265
  const unionProcessor = (schema, ctx, json, params) => {
14308
14266
  const def = schema._zod.def;
14309
14267
  const isExclusive = def.inclusive === false;
14310
- const options = def.options.map((x2, i) => process(x2, ctx, {
14268
+ const options = def.options.map((x2, i) => process$1(x2, ctx, {
14311
14269
  ...params,
14312
14270
  path: [...params.path, isExclusive ? "oneOf" : "anyOf", i]
14313
14271
  }));
@@ -14319,11 +14277,11 @@ const unionProcessor = (schema, ctx, json, params) => {
14319
14277
  };
14320
14278
  const intersectionProcessor = (schema, ctx, json, params) => {
14321
14279
  const def = schema._zod.def;
14322
- const a2 = process(def.left, ctx, {
14280
+ const a2 = process$1(def.left, ctx, {
14323
14281
  ...params,
14324
14282
  path: [...params.path, "allOf", 0]
14325
14283
  });
14326
- const b2 = process(def.right, ctx, {
14284
+ const b2 = process$1(def.right, ctx, {
14327
14285
  ...params,
14328
14286
  path: [...params.path, "allOf", 1]
14329
14287
  });
@@ -14342,7 +14300,7 @@ const recordProcessor = (schema, ctx, _json, params) => {
14342
14300
  const keyBag = keyType._zod.bag;
14343
14301
  const patterns = keyBag == null ? void 0 : keyBag.patterns;
14344
14302
  if (def.mode === "loose" && patterns && patterns.size > 0) {
14345
- const valueSchema = process(def.valueType, ctx, {
14303
+ const valueSchema = process$1(def.valueType, ctx, {
14346
14304
  ...params,
14347
14305
  path: [...params.path, "patternProperties", "*"]
14348
14306
  });
@@ -14352,12 +14310,12 @@ const recordProcessor = (schema, ctx, _json, params) => {
14352
14310
  }
14353
14311
  } else {
14354
14312
  if (ctx.target === "draft-07" || ctx.target === "draft-2020-12") {
14355
- json.propertyNames = process(def.keyType, ctx, {
14313
+ json.propertyNames = process$1(def.keyType, ctx, {
14356
14314
  ...params,
14357
14315
  path: [...params.path, "propertyNames"]
14358
14316
  });
14359
14317
  }
14360
- json.additionalProperties = process(def.valueType, ctx, {
14318
+ json.additionalProperties = process$1(def.valueType, ctx, {
14361
14319
  ...params,
14362
14320
  path: [...params.path, "additionalProperties"]
14363
14321
  });
@@ -14372,7 +14330,7 @@ const recordProcessor = (schema, ctx, _json, params) => {
14372
14330
  };
14373
14331
  const nullableProcessor = (schema, ctx, json, params) => {
14374
14332
  const def = schema._zod.def;
14375
- const inner = process(def.innerType, ctx, params);
14333
+ const inner = process$1(def.innerType, ctx, params);
14376
14334
  const seen2 = ctx.seen.get(schema);
14377
14335
  if (ctx.target === "openapi-3.0") {
14378
14336
  seen2.ref = def.innerType;
@@ -14383,20 +14341,20 @@ const nullableProcessor = (schema, ctx, json, params) => {
14383
14341
  };
14384
14342
  const nonoptionalProcessor = (schema, ctx, _json, params) => {
14385
14343
  const def = schema._zod.def;
14386
- process(def.innerType, ctx, params);
14344
+ process$1(def.innerType, ctx, params);
14387
14345
  const seen2 = ctx.seen.get(schema);
14388
14346
  seen2.ref = def.innerType;
14389
14347
  };
14390
14348
  const defaultProcessor = (schema, ctx, json, params) => {
14391
14349
  const def = schema._zod.def;
14392
- process(def.innerType, ctx, params);
14350
+ process$1(def.innerType, ctx, params);
14393
14351
  const seen2 = ctx.seen.get(schema);
14394
14352
  seen2.ref = def.innerType;
14395
14353
  json.default = JSON.parse(JSON.stringify(def.defaultValue));
14396
14354
  };
14397
14355
  const prefaultProcessor = (schema, ctx, json, params) => {
14398
14356
  const def = schema._zod.def;
14399
- process(def.innerType, ctx, params);
14357
+ process$1(def.innerType, ctx, params);
14400
14358
  const seen2 = ctx.seen.get(schema);
14401
14359
  seen2.ref = def.innerType;
14402
14360
  if (ctx.io === "input")
@@ -14404,7 +14362,7 @@ const prefaultProcessor = (schema, ctx, json, params) => {
14404
14362
  };
14405
14363
  const catchProcessor = (schema, ctx, json, params) => {
14406
14364
  const def = schema._zod.def;
14407
- process(def.innerType, ctx, params);
14365
+ process$1(def.innerType, ctx, params);
14408
14366
  const seen2 = ctx.seen.get(schema);
14409
14367
  seen2.ref = def.innerType;
14410
14368
  let catchValue;
@@ -14418,26 +14376,26 @@ const catchProcessor = (schema, ctx, json, params) => {
14418
14376
  const pipeProcessor = (schema, ctx, _json, params) => {
14419
14377
  const def = schema._zod.def;
14420
14378
  const innerType = ctx.io === "input" ? def.in._zod.def.type === "transform" ? def.out : def.in : def.out;
14421
- process(innerType, ctx, params);
14379
+ process$1(innerType, ctx, params);
14422
14380
  const seen2 = ctx.seen.get(schema);
14423
14381
  seen2.ref = innerType;
14424
14382
  };
14425
14383
  const readonlyProcessor = (schema, ctx, json, params) => {
14426
14384
  const def = schema._zod.def;
14427
- process(def.innerType, ctx, params);
14385
+ process$1(def.innerType, ctx, params);
14428
14386
  const seen2 = ctx.seen.get(schema);
14429
14387
  seen2.ref = def.innerType;
14430
14388
  json.readOnly = true;
14431
14389
  };
14432
14390
  const optionalProcessor = (schema, ctx, _json, params) => {
14433
14391
  const def = schema._zod.def;
14434
- process(def.innerType, ctx, params);
14392
+ process$1(def.innerType, ctx, params);
14435
14393
  const seen2 = ctx.seen.get(schema);
14436
14394
  seen2.ref = def.innerType;
14437
14395
  };
14438
14396
  const lazyProcessor = (schema, ctx, _json, params) => {
14439
14397
  const innerType = schema._zod.innerType;
14440
- process(innerType, ctx, params);
14398
+ process$1(innerType, ctx, params);
14441
14399
  const seen2 = ctx.seen.get(schema);
14442
14400
  seen2.ref = innerType;
14443
14401
  };
@@ -15159,18 +15117,6 @@ function readonly(innerType) {
15159
15117
  innerType
15160
15118
  });
15161
15119
  }
15162
- const ZodTemplateLiteral = /* @__PURE__ */ $constructor("ZodTemplateLiteral", (inst, def) => {
15163
- $ZodTemplateLiteral.init(inst, def);
15164
- ZodType.init(inst, def);
15165
- inst._zod.processJSONSchema = (ctx, json, params) => templateLiteralProcessor(inst, ctx, json);
15166
- });
15167
- function templateLiteral(parts, params) {
15168
- return new ZodTemplateLiteral({
15169
- type: "template_literal",
15170
- parts,
15171
- ...normalizeParams(params)
15172
- });
15173
- }
15174
15120
  const ZodLazy = /* @__PURE__ */ $constructor("ZodLazy", (inst, def) => {
15175
15121
  $ZodLazy.init(inst, def);
15176
15122
  ZodType.init(inst, def);
@@ -15334,7 +15280,10 @@ const HookConflictEventSchema = BaseEventSchema.extend({
15334
15280
  eventType: literal("hook_conflict"),
15335
15281
  correlationId: string$2(),
15336
15282
  eventData: object({
15337
- token: string$2()
15283
+ token: string$2(),
15284
+ // TODO: Make this required once all persisted hook_conflict events and
15285
+ // remote World implementations always include the active hook owner's run ID.
15286
+ conflictingRunId: string$2().optional()
15338
15287
  })
15339
15288
  });
15340
15289
  const WaitCreatedEventSchema = BaseEventSchema.extend({
@@ -15448,11 +15397,9 @@ object({
15448
15397
  specVersion: number$2().optional(),
15449
15398
  isWebhook: boolean$2().optional()
15450
15399
  });
15451
- const QueuePrefix = union([
15452
- literal("__wkf_step_"),
15453
- literal("__wkf_workflow_")
15454
- ]);
15455
- templateLiteral([QueuePrefix, string$2()]);
15400
+ string$2().regex(/^__(?:[a-z][a-z0-9]*_)?wkf_(?:workflow|step)_$/, "Must match __wkf_{workflow|step}_ or __{namespace}_wkf_{workflow|step}_");
15401
+ string$2().regex(/^__(?:[a-z][a-z0-9]*_)?wkf_(?:workflow|step)_.+$/, "Must be a valid queue name with a recognized prefix");
15402
+ string$2().regex(/^[a-z][a-z0-9]*$/, "Must be lowercase alphanumeric, starting with a letter");
15456
15403
  string$2().brand().describe("A stored queue message ID");
15457
15404
  const TraceCarrierSchema = record(string$2(), string$2());
15458
15405
  const RunInputSchema = object({
@@ -15810,9 +15757,9 @@ async function hydrateResourceIOWithKey(resource, key) {
15810
15757
  return { hydrateDataWithKey: hydrateDataWithKey3 };
15811
15758
  }, true ? void 0 : void 0);
15812
15759
  const { importKey } = await __vitePreload(async () => {
15813
- const { importKey: importKey2 } = await import("./encryption-5eom23r0.js");
15760
+ const { importKey: importKey2 } = await import("./encryption-Bd25Keng.js");
15814
15761
  return { importKey: importKey2 };
15815
- }, true ? [] : void 0);
15762
+ }, true ? __vite__mapDeps([0,1,2]) : void 0);
15816
15763
  const cryptoKey = await importKey(key);
15817
15764
  const revivers = getRevivers();
15818
15765
  async function decryptField(value, rev, k2) {
@@ -15864,60 +15811,6 @@ function hasEncryptedFields(resource) {
15864
15811
  }
15865
15812
  return false;
15866
15813
  }
15867
- const KEYFRAMES = `@keyframes wf-spinner-fade{0%{opacity:1}100%{opacity:.15}}`;
15868
- function Spinner({ size: size2 = 14, color: color5 }) {
15869
- const config2 = size2 <= 12 ? {
15870
- angle: 45,
15871
- delays: [-875, -750, -625, -500, -375, -250, -125, 0],
15872
- duration: 1e3,
15873
- lineW: 3,
15874
- lineH: 1.5
15875
- } : size2 <= 16 ? {
15876
- angle: 36,
15877
- delays: [-900, -800, -700, -600, -500, -400, -300, -200, -100, 0],
15878
- duration: 1e3,
15879
- lineW: 4,
15880
- lineH: 1.5
15881
- } : {
15882
- angle: 30,
15883
- delays: [
15884
- -1100,
15885
- -1e3,
15886
- -900,
15887
- -800,
15888
- -700,
15889
- -600,
15890
- -500,
15891
- -400,
15892
- -300,
15893
- -200,
15894
- -100,
15895
- 0
15896
- ],
15897
- duration: 1200,
15898
- lineW: size2 * 0.24,
15899
- lineH: size2 * 0.08
15900
- };
15901
- return jsxRuntimeExports.jsxs("span", { style: {
15902
- display: "inline-flex",
15903
- position: "relative",
15904
- width: size2,
15905
- height: size2
15906
- }, children: [jsxRuntimeExports.jsx("style", { dangerouslySetInnerHTML: { __html: KEYFRAMES } }), config2.delays.map((delay, i) => jsxRuntimeExports.jsx("span", { style: {
15907
- position: "absolute",
15908
- left: "50%",
15909
- top: "50%",
15910
- width: config2.lineW,
15911
- height: config2.lineH,
15912
- marginLeft: -config2.lineW / 2,
15913
- marginTop: -config2.lineH / 2,
15914
- borderRadius: 1,
15915
- backgroundColor: color5 ?? "var(--ds-gray-700)",
15916
- transform: `rotate(${i * config2.angle}deg) translate(${size2 * 0.36}px)`,
15917
- animation: `wf-spinner-fade ${config2.duration}ms linear infinite`,
15918
- animationDelay: `${delay}ms`
15919
- } }, delay))] });
15920
- }
15921
15814
  function __insertCSS(code2) {
15922
15815
  if (typeof document == "undefined") return;
15923
15816
  let head = document.head || document.getElementsByTagName("head")[0];
@@ -17007,6 +16900,60 @@ const ToastContext = reactExports.createContext(defaultAdapter);
17007
16900
  function useToast() {
17008
16901
  return reactExports.useContext(ToastContext);
17009
16902
  }
16903
+ const KEYFRAMES = `@keyframes wf-spinner-fade{0%{opacity:1}100%{opacity:.15}}`;
16904
+ function Spinner({ size: size2 = 14, color: color5 }) {
16905
+ const config2 = size2 <= 12 ? {
16906
+ angle: 45,
16907
+ delays: [-875, -750, -625, -500, -375, -250, -125, 0],
16908
+ duration: 1e3,
16909
+ lineW: 3,
16910
+ lineH: 1.5
16911
+ } : size2 <= 16 ? {
16912
+ angle: 36,
16913
+ delays: [-900, -800, -700, -600, -500, -400, -300, -200, -100, 0],
16914
+ duration: 1e3,
16915
+ lineW: 4,
16916
+ lineH: 1.5
16917
+ } : {
16918
+ angle: 30,
16919
+ delays: [
16920
+ -1100,
16921
+ -1e3,
16922
+ -900,
16923
+ -800,
16924
+ -700,
16925
+ -600,
16926
+ -500,
16927
+ -400,
16928
+ -300,
16929
+ -200,
16930
+ -100,
16931
+ 0
16932
+ ],
16933
+ duration: 1200,
16934
+ lineW: size2 * 0.24,
16935
+ lineH: size2 * 0.08
16936
+ };
16937
+ return jsxRuntimeExports.jsxs("span", { style: {
16938
+ display: "inline-flex",
16939
+ position: "relative",
16940
+ width: size2,
16941
+ height: size2
16942
+ }, children: [jsxRuntimeExports.jsx("style", { dangerouslySetInnerHTML: { __html: KEYFRAMES } }), config2.delays.map((delay, i) => jsxRuntimeExports.jsx("span", { style: {
16943
+ position: "absolute",
16944
+ left: "50%",
16945
+ top: "50%",
16946
+ width: config2.lineW,
16947
+ height: config2.lineH,
16948
+ marginLeft: -config2.lineW / 2,
16949
+ marginTop: -config2.lineH / 2,
16950
+ borderRadius: 1,
16951
+ backgroundColor: color5 ?? "var(--ds-gray-700)",
16952
+ transform: `rotate(${i * config2.angle}deg) translate(${size2 * 0.36}px)`,
16953
+ animation: `wf-spinner-fade ${config2.duration}ms linear infinite`,
16954
+ animationDelay: `${delay}ms`
16955
+ } }, delay))] });
16956
+ }
17010
16957
  var __create = Object.create;
17011
16958
  var __defProp2 = Object.defineProperty;
17012
16959
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -18574,8 +18521,8 @@ const deserializer = ($2, _2) => {
18574
18521
  case "ArrayBuffer":
18575
18522
  return as(new Uint8Array(value).buffer, value);
18576
18523
  case "DataView": {
18577
- const { buffer } = new Uint8Array(value);
18578
- return as(new DataView(buffer), value);
18524
+ const { buffer: buffer2 } = new Uint8Array(value);
18525
+ return as(new DataView(buffer2), value);
18579
18526
  }
18580
18527
  }
18581
18528
  return as(new env[type](value), index2);
@@ -23158,8 +23105,8 @@ class Tokenizer {
23158
23105
  }
23159
23106
  //Errors
23160
23107
  _err(code2, cpOffset = 0) {
23161
- var _a3, _b;
23162
- (_b = (_a3 = this.handler).onParseError) === null || _b === void 0 ? void 0 : _b.call(_a3, this.preprocessor.getError(code2, cpOffset));
23108
+ var _a3, _b2;
23109
+ (_b2 = (_a3 = this.handler).onParseError) === null || _b2 === void 0 ? void 0 : _b2.call(_a3, this.preprocessor.getError(code2, cpOffset));
23163
23110
  }
23164
23111
  // NOTE: `offset` may never run across line boundaries.
23165
23112
  getCurrentLocation(offset2) {
@@ -23302,12 +23249,12 @@ class Tokenizer {
23302
23249
  }
23303
23250
  _leaveAttrName() {
23304
23251
  var _a3;
23305
- var _b;
23252
+ var _b2;
23306
23253
  const token = this.currentToken;
23307
23254
  if (getTokenAttr(token, this.currentAttr.name) === null) {
23308
23255
  token.attrs.push(this.currentAttr);
23309
23256
  if (token.location && this.currentLocation) {
23310
- const attrLocations = (_a3 = (_b = token.location).attrs) !== null && _a3 !== void 0 ? _a3 : _b.attrs = /* @__PURE__ */ Object.create(null);
23257
+ const attrLocations = (_a3 = (_b2 = token.location).attrs) !== null && _a3 !== void 0 ? _a3 : _b2.attrs = /* @__PURE__ */ Object.create(null);
23311
23258
  attrLocations[this.currentAttr.name] = this.currentLocation;
23312
23259
  this._leaveAttrValue();
23313
23260
  }
@@ -26652,18 +26599,18 @@ class Parser {
26652
26599
  //Stack events
26653
26600
  /** @internal */
26654
26601
  onItemPush(node2, tid, isTop) {
26655
- var _a3, _b;
26656
- (_b = (_a3 = this.treeAdapter).onItemPush) === null || _b === void 0 ? void 0 : _b.call(_a3, node2);
26602
+ var _a3, _b2;
26603
+ (_b2 = (_a3 = this.treeAdapter).onItemPush) === null || _b2 === void 0 ? void 0 : _b2.call(_a3, node2);
26657
26604
  if (isTop && this.openElements.stackTop > 0)
26658
26605
  this._setContextModes(node2, tid);
26659
26606
  }
26660
26607
  /** @internal */
26661
26608
  onItemPop(node2, isTop) {
26662
- var _a3, _b;
26609
+ var _a3, _b2;
26663
26610
  if (this.options.sourceCodeLocationInfo) {
26664
26611
  this._setEndLocation(node2, this.currentToken);
26665
26612
  }
26666
- (_b = (_a3 = this.treeAdapter).onItemPop) === null || _b === void 0 ? void 0 : _b.call(_a3, node2, this.openElements.current);
26613
+ (_b2 = (_a3 = this.treeAdapter).onItemPop) === null || _b2 === void 0 ? void 0 : _b2.call(_a3, node2, this.openElements.current);
26667
26614
  if (isTop) {
26668
26615
  let current;
26669
26616
  let currentTagId;
@@ -32366,27 +32313,27 @@ function tokenizeWwwAutolink(effects, ok2, nok) {
32366
32313
  }
32367
32314
  function tokenizeProtocolAutolink(effects, ok2, nok) {
32368
32315
  const self2 = this;
32369
- let buffer = "";
32316
+ let buffer2 = "";
32370
32317
  let seen2 = false;
32371
32318
  return protocolStart;
32372
32319
  function protocolStart(code2) {
32373
32320
  if ((code2 === 72 || code2 === 104) && previousProtocol.call(self2, self2.previous) && !previousUnbalanced(self2.events)) {
32374
32321
  effects.enter("literalAutolink");
32375
32322
  effects.enter("literalAutolinkHttp");
32376
- buffer += String.fromCodePoint(code2);
32323
+ buffer2 += String.fromCodePoint(code2);
32377
32324
  effects.consume(code2);
32378
32325
  return protocolPrefixInside;
32379
32326
  }
32380
32327
  return nok(code2);
32381
32328
  }
32382
32329
  function protocolPrefixInside(code2) {
32383
- if (asciiAlpha(code2) && buffer.length < 5) {
32384
- buffer += String.fromCodePoint(code2);
32330
+ if (asciiAlpha(code2) && buffer2.length < 5) {
32331
+ buffer2 += String.fromCodePoint(code2);
32385
32332
  effects.consume(code2);
32386
32333
  return protocolPrefixInside;
32387
32334
  }
32388
32335
  if (code2 === 58) {
32389
- const protocol = buffer.toLowerCase();
32336
+ const protocol = buffer2.toLowerCase();
32390
32337
  if (protocol === "http" || protocol === "https") {
32391
32338
  effects.consume(code2);
32392
32339
  return protocolSlashesInside;
@@ -34316,7 +34263,7 @@ function tokenizeHtmlFlow(effects, ok2, nok) {
34316
34263
  const self2 = this;
34317
34264
  let marker2;
34318
34265
  let closingTag;
34319
- let buffer;
34266
+ let buffer2;
34320
34267
  let index2;
34321
34268
  let markerB;
34322
34269
  return start;
@@ -34346,7 +34293,7 @@ function tokenizeHtmlFlow(effects, ok2, nok) {
34346
34293
  }
34347
34294
  if (asciiAlpha(code2)) {
34348
34295
  effects.consume(code2);
34349
- buffer = String.fromCharCode(code2);
34296
+ buffer2 = String.fromCharCode(code2);
34350
34297
  return tagName;
34351
34298
  }
34352
34299
  return nok(code2);
@@ -34391,7 +34338,7 @@ function tokenizeHtmlFlow(effects, ok2, nok) {
34391
34338
  function tagCloseStart(code2) {
34392
34339
  if (asciiAlpha(code2)) {
34393
34340
  effects.consume(code2);
34394
- buffer = String.fromCharCode(code2);
34341
+ buffer2 = String.fromCharCode(code2);
34395
34342
  return tagName;
34396
34343
  }
34397
34344
  return nok(code2);
@@ -34399,12 +34346,12 @@ function tokenizeHtmlFlow(effects, ok2, nok) {
34399
34346
  function tagName(code2) {
34400
34347
  if (code2 === null || code2 === 47 || code2 === 62 || markdownLineEndingOrSpace(code2)) {
34401
34348
  const slash = code2 === 47;
34402
- const name2 = buffer.toLowerCase();
34349
+ const name2 = buffer2.toLowerCase();
34403
34350
  if (!slash && !closingTag && htmlRawNames.includes(name2)) {
34404
34351
  marker2 = 1;
34405
34352
  return self2.interrupt ? ok2(code2) : continuation(code2);
34406
34353
  }
34407
- if (htmlBlockNames.includes(buffer.toLowerCase())) {
34354
+ if (htmlBlockNames.includes(buffer2.toLowerCase())) {
34408
34355
  marker2 = 6;
34409
34356
  if (slash) {
34410
34357
  effects.consume(code2);
@@ -34417,7 +34364,7 @@ function tokenizeHtmlFlow(effects, ok2, nok) {
34417
34364
  }
34418
34365
  if (code2 === 45 || asciiAlphanumeric(code2)) {
34419
34366
  effects.consume(code2);
34420
- buffer += String.fromCharCode(code2);
34367
+ buffer2 += String.fromCharCode(code2);
34421
34368
  return tagName;
34422
34369
  }
34423
34370
  return nok(code2);
@@ -34584,23 +34531,23 @@ function tokenizeHtmlFlow(effects, ok2, nok) {
34584
34531
  function continuationRawTagOpen(code2) {
34585
34532
  if (code2 === 47) {
34586
34533
  effects.consume(code2);
34587
- buffer = "";
34534
+ buffer2 = "";
34588
34535
  return continuationRawEndTag;
34589
34536
  }
34590
34537
  return continuation(code2);
34591
34538
  }
34592
34539
  function continuationRawEndTag(code2) {
34593
34540
  if (code2 === 62) {
34594
- const name2 = buffer.toLowerCase();
34541
+ const name2 = buffer2.toLowerCase();
34595
34542
  if (htmlRawNames.includes(name2)) {
34596
34543
  effects.consume(code2);
34597
34544
  return continuationClose;
34598
34545
  }
34599
34546
  return continuation(code2);
34600
34547
  }
34601
- if (asciiAlpha(code2) && buffer.length < 8) {
34548
+ if (asciiAlpha(code2) && buffer2.length < 8) {
34602
34549
  effects.consume(code2);
34603
- buffer += String.fromCharCode(code2);
34550
+ buffer2 += String.fromCharCode(code2);
34604
34551
  return continuationRawEndTag;
34605
34552
  }
34606
34553
  return continuation(code2);
@@ -38470,7 +38417,7 @@ function postprocess(events) {
38470
38417
  const search = /[\0\t\n\r]/g;
38471
38418
  function preprocess() {
38472
38419
  let column = 1;
38473
- let buffer = "";
38420
+ let buffer2 = "";
38474
38421
  let start = true;
38475
38422
  let atCarriageReturn;
38476
38423
  return preprocessor;
@@ -38481,9 +38428,9 @@ function preprocess() {
38481
38428
  let startPosition;
38482
38429
  let endPosition;
38483
38430
  let code2;
38484
- value = buffer + (typeof value === "string" ? value.toString() : new TextDecoder(encoding || void 0).decode(value));
38431
+ value = buffer2 + (typeof value === "string" ? value.toString() : new TextDecoder(encoding || void 0).decode(value));
38485
38432
  startPosition = 0;
38486
- buffer = "";
38433
+ buffer2 = "";
38487
38434
  if (start) {
38488
38435
  if (value.charCodeAt(0) === 65279) {
38489
38436
  startPosition++;
@@ -38496,7 +38443,7 @@ function preprocess() {
38496
38443
  endPosition = match && match.index !== void 0 ? match.index : value.length;
38497
38444
  code2 = value.charCodeAt(endPosition);
38498
38445
  if (!match) {
38499
- buffer = value.slice(startPosition);
38446
+ buffer2 = value.slice(startPosition);
38500
38447
  break;
38501
38448
  }
38502
38449
  if (code2 === 10 && startPosition === endPosition && atCarriageReturn) {
@@ -38538,7 +38485,7 @@ function preprocess() {
38538
38485
  }
38539
38486
  if (end) {
38540
38487
  if (atCarriageReturn) chunks.push(-5);
38541
- if (buffer) chunks.push(buffer);
38488
+ if (buffer2) chunks.push(buffer2);
38542
38489
  chunks.push(null);
38543
38490
  }
38544
38491
  return chunks;
@@ -38565,26 +38512,26 @@ function compiler(options) {
38565
38512
  characterEscape: onenterdata,
38566
38513
  characterReference: onenterdata,
38567
38514
  codeFenced: opener(codeFlow),
38568
- codeFencedFenceInfo: buffer,
38569
- codeFencedFenceMeta: buffer,
38570
- codeIndented: opener(codeFlow, buffer),
38571
- codeText: opener(codeText2, buffer),
38515
+ codeFencedFenceInfo: buffer2,
38516
+ codeFencedFenceMeta: buffer2,
38517
+ codeIndented: opener(codeFlow, buffer2),
38518
+ codeText: opener(codeText2, buffer2),
38572
38519
  codeTextData: onenterdata,
38573
38520
  data: onenterdata,
38574
38521
  codeFlowValue: onenterdata,
38575
38522
  definition: opener(definition2),
38576
- definitionDestinationString: buffer,
38577
- definitionLabelString: buffer,
38578
- definitionTitleString: buffer,
38523
+ definitionDestinationString: buffer2,
38524
+ definitionLabelString: buffer2,
38525
+ definitionTitleString: buffer2,
38579
38526
  emphasis: opener(emphasis2),
38580
38527
  hardBreakEscape: opener(hardBreak2),
38581
38528
  hardBreakTrailing: opener(hardBreak2),
38582
- htmlFlow: opener(html2, buffer),
38529
+ htmlFlow: opener(html2, buffer2),
38583
38530
  htmlFlowData: onenterdata,
38584
- htmlText: opener(html2, buffer),
38531
+ htmlText: opener(html2, buffer2),
38585
38532
  htmlTextData: onenterdata,
38586
38533
  image: opener(image2),
38587
- label: buffer,
38534
+ label: buffer2,
38588
38535
  link: opener(link2),
38589
38536
  listItem: opener(listItem2),
38590
38537
  listItemValue: onenterlistitemvalue,
@@ -38592,9 +38539,9 @@ function compiler(options) {
38592
38539
  listUnordered: opener(list2),
38593
38540
  paragraph: opener(paragraph2),
38594
38541
  reference: onenterreference,
38595
- referenceString: buffer,
38596
- resourceDestinationString: buffer,
38597
- resourceTitleString: buffer,
38542
+ referenceString: buffer2,
38543
+ resourceDestinationString: buffer2,
38544
+ resourceTitleString: buffer2,
38598
38545
  setextHeading: opener(heading2),
38599
38546
  strong: opener(strong2),
38600
38547
  thematicBreak: opener(thematicBreak2)
@@ -38665,7 +38612,7 @@ function compiler(options) {
38665
38612
  config: config2,
38666
38613
  enter,
38667
38614
  exit: exit2,
38668
- buffer,
38615
+ buffer: buffer2,
38669
38616
  resume,
38670
38617
  data
38671
38618
  };
@@ -38809,7 +38756,7 @@ function compiler(options) {
38809
38756
  if (and) and.call(this, token);
38810
38757
  }
38811
38758
  }
38812
- function buffer() {
38759
+ function buffer2() {
38813
38760
  this.stack.push({
38814
38761
  type: "fragment",
38815
38762
  children: []
@@ -39284,8 +39231,9 @@ function hardBreak(state, node2) {
39284
39231
  function code(state, node2) {
39285
39232
  const value = node2.value ? node2.value + "\n" : "";
39286
39233
  const properties2 = {};
39287
- if (node2.lang) {
39288
- properties2.className = ["language-" + node2.lang];
39234
+ const language = node2.lang ? node2.lang.split(/\s+/) : [];
39235
+ if (language.length > 0) {
39236
+ properties2.className = ["language-" + language[0]];
39289
39237
  }
39290
39238
  let result = {
39291
39239
  type: "element",
@@ -41757,7 +41705,7 @@ ${c}` : c;
41757
41705
  }
41758
41706
  }
41759
41707
  list(e) {
41760
- var _a3, _b;
41708
+ var _a3, _b2;
41761
41709
  let t = this.rules.block.list.exec(e);
41762
41710
  if (t) {
41763
41711
  let n = t[1].trim(), r2 = n.length > 1, i = { type: "list", raw: "", ordered: r2, start: r2 ? +n.slice(0, -1) : "", loose: false, items: [] };
@@ -41796,7 +41744,7 @@ ${c}` : c;
41796
41744
  i.raw = i.raw.trimEnd();
41797
41745
  for (let l of i.items) {
41798
41746
  if (this.lexer.state.top = false, l.tokens = this.lexer.blockTokens(l.text, []), l.task) {
41799
- if (l.text = l.text.replace(this.rules.other.listReplaceTask, ""), ((_a3 = l.tokens[0]) == null ? void 0 : _a3.type) === "text" || ((_b = l.tokens[0]) == null ? void 0 : _b.type) === "paragraph") {
41747
+ if (l.text = l.text.replace(this.rules.other.listReplaceTask, ""), ((_a3 = l.tokens[0]) == null ? void 0 : _a3.type) === "text" || ((_b2 = l.tokens[0]) == null ? void 0 : _b2.type) === "paragraph") {
41800
41748
  l.tokens[0].raw = l.tokens[0].raw.replace(this.rules.other.listReplaceTask, ""), l.tokens[0].text = l.tokens[0].text.replace(this.rules.other.listReplaceTask, "");
41801
41749
  for (let c = this.lexer.inlineQueue.length - 1; c >= 0; c--) if (this.rules.other.listIsTask.test(this.lexer.inlineQueue[c].src)) {
41802
41750
  this.lexer.inlineQueue[c].src = this.lexer.inlineQueue[c].src.replace(this.rules.other.listReplaceTask, "");
@@ -42020,10 +41968,10 @@ var x = class u2 {
42020
41968
  return this.inlineQueue = [], this.tokens;
42021
41969
  }
42022
41970
  blockTokens(e, t = [], n = false) {
42023
- var _a3, _b, _c;
41971
+ var _a3, _b2, _c;
42024
41972
  for (this.options.pedantic && (e = e.replace(m.tabCharGlobal, " ").replace(m.spaceLine, "")); e; ) {
42025
41973
  let r2;
42026
- if ((_b = (_a3 = this.options.extensions) == null ? void 0 : _a3.block) == null ? void 0 : _b.some((s2) => (r2 = s2.call({ lexer: this }, e, t)) ? (e = e.substring(r2.raw.length), t.push(r2), true) : false)) continue;
41974
+ if ((_b2 = (_a3 = this.options.extensions) == null ? void 0 : _a3.block) == null ? void 0 : _b2.some((s2) => (r2 = s2.call({ lexer: this }, e, t)) ? (e = e.substring(r2.raw.length), t.push(r2), true) : false)) continue;
42027
41975
  if (r2 = this.tokenizer.space(e)) {
42028
41976
  e = e.substring(r2.raw.length);
42029
41977
  let s2 = t.at(-1);
@@ -42119,7 +42067,7 @@ var x = class u2 {
42119
42067
  return this.inlineQueue.push({ src: e, tokens: t }), t;
42120
42068
  }
42121
42069
  inlineTokens(e, t = []) {
42122
- var _a3, _b, _c, _d, _e2;
42070
+ var _a3, _b2, _c, _d, _e2;
42123
42071
  let n = e, r2 = null;
42124
42072
  if (this.tokens.links) {
42125
42073
  let o = Object.keys(this.tokens.links);
@@ -42128,7 +42076,7 @@ var x = class u2 {
42128
42076
  for (; (r2 = this.tokenizer.rules.inline.anyPunctuation.exec(n)) != null; ) n = n.slice(0, r2.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
42129
42077
  let i;
42130
42078
  for (; (r2 = this.tokenizer.rules.inline.blockSkip.exec(n)) != null; ) i = r2[2] ? r2[2].length : 0, n = n.slice(0, r2.index + i) + "[" + "a".repeat(r2[0].length - i - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
42131
- n = ((_b = (_a3 = this.options.hooks) == null ? void 0 : _a3.emStrongMask) == null ? void 0 : _b.call({ lexer: this }, n)) ?? n;
42079
+ n = ((_b2 = (_a3 = this.options.hooks) == null ? void 0 : _a3.emStrongMask) == null ? void 0 : _b2.call({ lexer: this }, n)) ?? n;
42132
42080
  let s2 = false, a2 = "";
42133
42081
  for (; e; ) {
42134
42082
  s2 || (a2 = ""), s2 = false;
@@ -42365,11 +42313,11 @@ var b = class u3 {
42365
42313
  return new u3(t).parseInline(e);
42366
42314
  }
42367
42315
  parse(e) {
42368
- var _a3, _b;
42316
+ var _a3, _b2;
42369
42317
  let t = "";
42370
42318
  for (let n = 0; n < e.length; n++) {
42371
42319
  let r2 = e[n];
42372
- if ((_b = (_a3 = this.options.extensions) == null ? void 0 : _a3.renderers) == null ? void 0 : _b[r2.type]) {
42320
+ if ((_b2 = (_a3 = this.options.extensions) == null ? void 0 : _a3.renderers) == null ? void 0 : _b2[r2.type]) {
42373
42321
  let s2 = r2, a2 = this.options.extensions.renderers[s2.type].call({ parser: this }, s2);
42374
42322
  if (a2 !== false || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "def", "paragraph", "text"].includes(s2.type)) {
42375
42323
  t += a2 || "";
@@ -42436,11 +42384,11 @@ var b = class u3 {
42436
42384
  return t;
42437
42385
  }
42438
42386
  parseInline(e, t = this.renderer) {
42439
- var _a3, _b;
42387
+ var _a3, _b2;
42440
42388
  let n = "";
42441
42389
  for (let r2 = 0; r2 < e.length; r2++) {
42442
42390
  let i = e[r2];
42443
- if ((_b = (_a3 = this.options.extensions) == null ? void 0 : _a3.renderers) == null ? void 0 : _b[i.type]) {
42391
+ if ((_b2 = (_a3 = this.options.extensions) == null ? void 0 : _a3.renderers) == null ? void 0 : _b2[i.type]) {
42444
42392
  let a2 = this.options.extensions.renderers[i.type].call({ parser: this }, i);
42445
42393
  if (a2 !== false || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(i.type)) {
42446
42394
  n += a2 || "";
@@ -42503,7 +42451,7 @@ var b = class u3 {
42503
42451
  return n;
42504
42452
  }
42505
42453
  };
42506
- var P = (_a2 = class {
42454
+ var P = (_b = class {
42507
42455
  constructor(e) {
42508
42456
  __publicField(this, "options");
42509
42457
  __publicField(this, "block");
@@ -42527,7 +42475,7 @@ var P = (_a2 = class {
42527
42475
  provideParser() {
42528
42476
  return this.block ? b.parse : b.parseInline;
42529
42477
  }
42530
- }, __publicField(_a2, "passThroughHooks", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens", "emStrongMask"])), __publicField(_a2, "passThroughHooksRespectAsync", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens"])), _a2);
42478
+ }, __publicField(_b, "passThroughHooks", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens", "emStrongMask"])), __publicField(_b, "passThroughHooksRespectAsync", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens"])), _b);
42531
42479
  var B = class {
42532
42480
  constructor(...e) {
42533
42481
  __publicField(this, "defaults", M());
@@ -42543,7 +42491,7 @@ var B = class {
42543
42491
  this.use(...e);
42544
42492
  }
42545
42493
  walkTokens(e, t) {
42546
- var _a3, _b;
42494
+ var _a3, _b2;
42547
42495
  let n = [];
42548
42496
  for (let r2 of e) switch (n = n.concat(t.call(this, r2)), r2.type) {
42549
42497
  case "table": {
@@ -42559,7 +42507,7 @@ var B = class {
42559
42507
  }
42560
42508
  default: {
42561
42509
  let i = r2;
42562
- ((_b = (_a3 = this.defaults.extensions) == null ? void 0 : _a3.childTokens) == null ? void 0 : _b[i.type]) ? this.defaults.extensions.childTokens[i.type].forEach((s2) => {
42510
+ ((_b2 = (_a3 = this.defaults.extensions) == null ? void 0 : _a3.childTokens) == null ? void 0 : _b2[i.type]) ? this.defaults.extensions.childTokens[i.type].forEach((s2) => {
42563
42511
  let a2 = i[s2].flat(1 / 0);
42564
42512
  n = n.concat(this.walkTokens(a2, t));
42565
42513
  }) : i.tokens && (n = n.concat(this.walkTokens(i.tokens, t)));
@@ -42823,7 +42771,7 @@ var tn = f("block", "before:content-[counter(line)]", "before:inline-block", "be
42823
42771
  var et = ({ className: e, language: t, style: o, isIncomplete: n, ...s2 }) => jsxRuntimeExports.jsx("div", { className: f("my-4 flex w-full flex-col gap-2 rounded-xl border border-border bg-sidebar p-2", e), "data-incomplete": n || void 0, "data-language": t, "data-streamdown": "code-block", style: { contentVisibility: "auto", containIntrinsicSize: "auto 200px", ...o }, ...s2 });
42824
42772
  var Se = reactExports.createContext({ code: "" }), de = () => reactExports.useContext(Se);
42825
42773
  var ot = ({ language: e }) => jsxRuntimeExports.jsx("div", { className: "flex h-8 items-center text-muted-foreground text-xs", "data-language": e, "data-streamdown": "code-block-header", children: jsxRuntimeExports.jsx("span", { className: "ml-1 font-mono lowercase", children: e }) });
42826
- var cn$1 = /\n+$/, dn = reactExports.lazy(() => __vitePreload(() => import("./highlighted-body-B3W2YXNL-9Gx_xbQ8.js"), true ? __vite__mapDeps([0,1]) : void 0).then((e) => ({ default: e.HighlightedCodeBlockBody }))), rt = ({ code: e, language: t, className: o, children: n, isIncomplete: s2 = false, ...r2 }) => {
42774
+ var cn$1 = /\n+$/, dn = reactExports.lazy(() => __vitePreload(() => import("./highlighted-body-B3W2YXNL-BmmQMQWQ.js"), true ? __vite__mapDeps([3,2]) : void 0).then((e) => ({ default: e.HighlightedCodeBlockBody }))), rt = ({ code: e, language: t, className: o, children: n, isIncomplete: s2 = false, ...r2 }) => {
42827
42775
  let i = reactExports.useMemo(() => e.replace(cn$1, ""), [e]), c = reactExports.useMemo(() => ({ bg: "transparent", fg: "inherit", tokens: i.split(`
42828
42776
  `).map((a2) => [{ content: a2, color: "inherit", bgColor: "transparent", htmlStyle: {}, offset: 0 }]) }), [i]);
42829
42777
  return jsxRuntimeExports.jsx(Se.Provider, { value: { code: e }, children: jsxRuntimeExports.jsxs(et, { isIncomplete: s2, language: t, children: [jsxRuntimeExports.jsx(ot, { language: t }), n ? jsxRuntimeExports.jsx("div", { className: "pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end", children: jsxRuntimeExports.jsx("div", { className: "pointer-events-auto flex shrink-0 items-center gap-2 rounded-md border border-sidebar bg-sidebar/80 px-1.5 py-1 supports-[backdrop-filter]:bg-sidebar/70 supports-[backdrop-filter]:backdrop-blur", "data-streamdown": "code-block-actions", children: n }) }) : null, jsxRuntimeExports.jsx(reactExports.Suspense, { fallback: jsxRuntimeExports.jsx(Qe, { className: o, language: t, result: c, ...r2 }), children: jsxRuntimeExports.jsx(dn, { className: o, code: i, language: t, raw: c, ...r2 }) })] }) });
@@ -45568,13 +45516,13 @@ function mergeProps(slotProps, childProps) {
45568
45516
  return { ...slotProps, ...overrideProps };
45569
45517
  }
45570
45518
  function getElementRef(element2) {
45571
- var _a3, _b;
45519
+ var _a3, _b2;
45572
45520
  let getter = (_a3 = Object.getOwnPropertyDescriptor(element2.props, "ref")) == null ? void 0 : _a3.get;
45573
45521
  let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
45574
45522
  if (mayWarn) {
45575
45523
  return element2.ref;
45576
45524
  }
45577
- getter = (_b = Object.getOwnPropertyDescriptor(element2, "ref")) == null ? void 0 : _b.get;
45525
+ getter = (_b2 = Object.getOwnPropertyDescriptor(element2, "ref")) == null ? void 0 : _b2.get;
45578
45526
  mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
45579
45527
  if (mayWarn) {
45580
45528
  return element2.props.ref;
@@ -46396,15 +46344,15 @@ currentExtensions[0] = (dateString) => {
46396
46344
  currentExtensions[1] = (epochSec) => {
46397
46345
  return new Date(Math.round(epochSec * 1e3));
46398
46346
  };
46399
- currentExtensions[2] = (buffer) => {
46347
+ currentExtensions[2] = (buffer2) => {
46400
46348
  let value = BigInt(0);
46401
- for (let i = 0, l = buffer.byteLength; i < l; i++) {
46402
- value = BigInt(buffer[i]) + (value << BigInt(8));
46349
+ for (let i = 0, l = buffer2.byteLength; i < l; i++) {
46350
+ value = BigInt(buffer2[i]) + (value << BigInt(8));
46403
46351
  }
46404
46352
  return value;
46405
46353
  };
46406
- currentExtensions[3] = (buffer) => {
46407
- return BigInt(-1) - currentExtensions[2](buffer);
46354
+ currentExtensions[3] = (buffer2) => {
46355
+ return BigInt(-1) - currentExtensions[2](buffer2);
46408
46356
  };
46409
46357
  currentExtensions[4] = (fraction) => {
46410
46358
  return +(fraction[1] + "e" + fraction[0]);
@@ -46591,19 +46539,19 @@ function registerTypedArray(TypedArray, tag) {
46591
46539
  if (!littleEndian && bytesPerElement == 1)
46592
46540
  continue;
46593
46541
  let sizeShift = bytesPerElement == 2 ? 1 : bytesPerElement == 4 ? 2 : bytesPerElement == 8 ? 3 : 0;
46594
- currentExtensions[littleEndian ? tag : tag - 4] = bytesPerElement == 1 || littleEndian == isLittleEndianMachine$1 ? (buffer) => {
46542
+ currentExtensions[littleEndian ? tag : tag - 4] = bytesPerElement == 1 || littleEndian == isLittleEndianMachine$1 ? (buffer2) => {
46595
46543
  if (!TypedArray)
46596
46544
  throw new Error("Could not find typed array for code " + tag);
46597
46545
  if (!currentDecoder.copyBuffers) {
46598
- if (bytesPerElement === 1 || bytesPerElement === 2 && !(buffer.byteOffset & 1) || bytesPerElement === 4 && !(buffer.byteOffset & 3) || bytesPerElement === 8 && !(buffer.byteOffset & 7))
46599
- return new TypedArray(buffer.buffer, buffer.byteOffset, buffer.byteLength >> sizeShift);
46546
+ if (bytesPerElement === 1 || bytesPerElement === 2 && !(buffer2.byteOffset & 1) || bytesPerElement === 4 && !(buffer2.byteOffset & 3) || bytesPerElement === 8 && !(buffer2.byteOffset & 7))
46547
+ return new TypedArray(buffer2.buffer, buffer2.byteOffset, buffer2.byteLength >> sizeShift);
46600
46548
  }
46601
- return new TypedArray(Uint8Array.prototype.slice.call(buffer, 0).buffer);
46602
- } : (buffer) => {
46549
+ return new TypedArray(Uint8Array.prototype.slice.call(buffer2, 0).buffer);
46550
+ } : (buffer2) => {
46603
46551
  if (!TypedArray)
46604
46552
  throw new Error("Could not find typed array for code " + tag);
46605
- let dv = new DataView(buffer.buffer, buffer.byteOffset, buffer.byteLength);
46606
- let elements = buffer.length >> sizeShift;
46553
+ let dv = new DataView(buffer2.buffer, buffer2.byteOffset, buffer2.byteLength);
46554
+ let elements = buffer2.length >> sizeShift;
46607
46555
  let ta = new TypedArray(elements);
46608
46556
  let method = dv[dvMethod];
46609
46557
  for (let i = 0; i < elements; i++) {
@@ -47552,8 +47500,8 @@ class Encoder extends Decoder {
47552
47500
  }
47553
47501
  }
47554
47502
  }
47555
- useBuffer(buffer) {
47556
- target = buffer;
47503
+ useBuffer(buffer2) {
47504
+ target = buffer2;
47557
47505
  targetView = new DataView(target.buffer, target.byteOffset, target.byteLength);
47558
47506
  position = 0;
47559
47507
  }
@@ -47819,13 +47767,13 @@ function typedArrayEncoder(tag, size2) {
47819
47767
  encode: function writeExtBuffer(typedArray, encode2) {
47820
47768
  let length = typedArray.byteLength;
47821
47769
  let offset2 = typedArray.byteOffset || 0;
47822
- let buffer = typedArray.buffer || typedArray;
47823
- encode2(hasNodeBuffer ? Buffer$1.from(buffer, offset2, length) : new Uint8Array(buffer, offset2, length));
47770
+ let buffer2 = typedArray.buffer || typedArray;
47771
+ encode2(hasNodeBuffer ? Buffer$1.from(buffer2, offset2, length) : new Uint8Array(buffer2, offset2, length));
47824
47772
  }
47825
47773
  };
47826
47774
  }
47827
- function writeBuffer(buffer, makeRoom) {
47828
- let length = buffer.byteLength;
47775
+ function writeBuffer(buffer2, makeRoom) {
47776
+ let length = buffer2.byteLength;
47829
47777
  if (length < 24) {
47830
47778
  target[position++] = 64 + length;
47831
47779
  } else if (length < 256) {
@@ -47843,7 +47791,7 @@ function writeBuffer(buffer, makeRoom) {
47843
47791
  if (position + length >= target.length) {
47844
47792
  makeRoom(position + length);
47845
47793
  }
47846
- target.set(buffer.buffer ? buffer : new Uint8Array(buffer), position);
47794
+ target.set(buffer2.buffer ? buffer2 : new Uint8Array(buffer2), position);
47847
47795
  position += length;
47848
47796
  }
47849
47797
  function insertIds(serialized, idsToInsert) {
@@ -47896,8 +47844,8 @@ async function rpc(method, params) {
47896
47844
  });
47897
47845
  if (!res.ok) {
47898
47846
  try {
47899
- const buffer2 = await res.arrayBuffer();
47900
- const errorBody = decode(new Uint8Array(buffer2));
47847
+ const buffer22 = await res.arrayBuffer();
47848
+ const errorBody = decode(new Uint8Array(buffer22));
47901
47849
  if ((_a3 = errorBody == null ? void 0 : errorBody.error) == null ? void 0 : _a3.message) {
47902
47850
  throw new Error(errorBody.error.message);
47903
47851
  }
@@ -47910,8 +47858,8 @@ async function rpc(method, params) {
47910
47858
  `RPC call ${method} failed: ${res.status} ${res.statusText}`
47911
47859
  );
47912
47860
  }
47913
- const buffer = await res.arrayBuffer();
47914
- return decode(new Uint8Array(buffer));
47861
+ const buffer2 = await res.arrayBuffer();
47862
+ return decode(new Uint8Array(buffer2));
47915
47863
  }
47916
47864
  async function fetchRuns(worldEnv, params) {
47917
47865
  return rpc("fetchRuns", { worldEnv, params });