@sourcegraph/cody-web 0.33.0 → 0.34.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.
package/dist/index.js CHANGED
@@ -3,8 +3,8 @@ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { en
3
3
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
4
4
  var _a;
5
5
  import { jsx, jsxs, Fragment as Fragment$1 } from "react/jsx-runtime";
6
- import { g as getDefaultExportFromCjs, F as FILE_CONTEXT_MENTION_PROVIDER, S as SYMBOL_CONTEXT_MENTION_PROVIDER, R as REMOTE_REPOSITORY_PROVIDER_URI, a as REMOTE_FILE_PROVIDER_URI, b as REMOTE_DIRECTORY_PROVIDER_URI, W as WEB_PROVIDER_URI, d as RULES_PROVIDER_URI, e as displayPath, f as displayLineRange, h as displayPathDirname, i as displayPathBasename, I as IGNORED_FILE_WARNING_LABEL, L as LARGE_FILE_WARNING_LABEL, o as object, l as literal, j as string$2, k as displayPathWithLines, m as URI, n as is$3, q as serializeContextItem, r as CONTEXT_ITEM_MENTION_NODE_TYPE, t as contextItemMentionNodeDisplayText, T as TEMPLATE_INPUT_NODE_TYPE, u as parseMentionQuery, N as NO_SYMBOL_MATCHES_HELP_LABEL, v as FILE_RANGE_TOOLTIP_LABEL, O as Observable, x as createExtensionAPI, y as createMessageAPIForWebview, z as debounce$1, C as ContextItemSource, A as memoizeLastValue, B as toSerializedPromptEditorValue$1, D as isEqual, E as scanForMentionTriggerInUserTextInput, G as getMentionOperations, H as combineLatest, J as map$3, K as forceHydration, M as hydrateAfterPostMessage, P as isDotCom, Q as isWorkspaceInstance, V as isAuthError, X as isAvailabilityError, Y as isSourcegraphToken, Z as trace, _ as context$1, $ as SpanStatusCode, c as commonjsGlobal, a0 as svg, a1 as html$2, a2 as whitespace, a3 as find, a4 as stringify, a5 as stringify$1, a6 as ccount, a7 as isCodyProUser, a8 as CodyIDE, a9 as CodyTaskState, aa as cryptoJsExports, ab as GuardrailsCheckStatus, ac as LRUCache, ad as isError, ae as RateLimitError, af as FeatureFlag, ag as reformatBotMessageForChat, ah as isAbortErrorOrSocketHangUp, ai as ModelTag, aj as DeepCodyAgentID, ak as serializedPromptEditorStateFromChatMessage, al as contextItemsFromPromptEditorValue, am as filterContextItemsFromPromptEditorValue, an as View, ao as isCodyProModel, ap as isMacOS, aq as ToolCodyModelName, ar as CustomCommandType, as as textContentFromSerializedLexicalNode, at as firstValueFrom, au as skipPendingOperation, av as FAST_CHAT_INPUT_TOKEN_BUDGET, aw as webviewOpenURIForContextItem, ax as pluralize, ay as UIToolStatus, az as getFileDiff, aA as diffWithLineNum, aB as UITerminalOutputType, aC as isCodeSearchContextItem, aD as v4, aE as lodashExports, aF as deserializeContextItem, aG as firstResultFromOperation, aH as ChatHistoryType, aI as S2_URL, aJ as ACCOUNT_USAGE_URL, aK as CODY_DOC_QUICKSTART_URL, aL as isPlgEsAccessDisabled, aM as isDefined, aN as browser, aO as CodyAutoSuggestionMode, aP as setDisplayPathEnvInfo, aQ as isErrorLike, aR as PromptString, aS as createGuardrailsImpl, U as Uri } from "./vscode-shim-DCfZW3km.mjs";
7
- import { aU, aT } from "./vscode-shim-DCfZW3km.mjs";
6
+ import { g as getDefaultExportFromCjs, F as FILE_CONTEXT_MENTION_PROVIDER, S as SYMBOL_CONTEXT_MENTION_PROVIDER, R as REMOTE_REPOSITORY_PROVIDER_URI, a as REMOTE_FILE_PROVIDER_URI, b as REMOTE_DIRECTORY_PROVIDER_URI, W as WEB_PROVIDER_URI, d as RULES_PROVIDER_URI, e as displayPath, f as displayLineRange, h as displayPathDirname, i as displayPathBasename, I as IGNORED_FILE_WARNING_LABEL, L as LARGE_FILE_WARNING_LABEL, o as object, l as literal, j as string$2, k as displayPathWithLines, m as URI, n as is$3, q as serializeContextItem, r as CONTEXT_ITEM_MENTION_NODE_TYPE, t as contextItemMentionNodeDisplayText, T as TEMPLATE_INPUT_NODE_TYPE, u as parseMentionQuery, N as NO_SYMBOL_MATCHES_HELP_LABEL, v as FILE_RANGE_TOOLTIP_LABEL, O as Observable, x as createExtensionAPI, y as createMessageAPIForWebview, z as debounce$1, C as ContextItemSource, A as memoizeLastValue, B as toSerializedPromptEditorValue$1, D as isEqual, E as scanForMentionTriggerInUserTextInput, G as getMentionOperations, H as combineLatest, J as map$3, K as forceHydration, M as hydrateAfterPostMessage, P as isDotCom, Q as isWorkspaceInstance, V as isAuthError, X as isAvailabilityError, Y as isSourcegraphToken, Z as trace, _ as context$1, $ as SpanStatusCode, c as commonjsGlobal, a0 as svg, a1 as html$2, a2 as whitespace, a3 as find, a4 as stringify, a5 as stringify$1, a6 as ccount, a7 as isCodyProUser, a8 as CodyIDE, a9 as CodyTaskState, aa as cryptoJsExports, ab as GuardrailsCheckStatus, ac as LRUCache, ad as isError, ae as RateLimitError, af as FeatureFlag, ag as reformatBotMessageForChat, ah as isAbortErrorOrSocketHangUp, ai as ModelTag, aj as DeepCodyAgentID, ak as serializedPromptEditorStateFromChatMessage, al as contextItemsFromPromptEditorValue, am as filterContextItemsFromPromptEditorValue, an as View, ao as isCodyProModel, ap as isMacOS, aq as ToolCodyModelName, ar as CustomCommandType, as as textContentFromSerializedLexicalNode, at as firstValueFrom, au as skipPendingOperation, av as FAST_CHAT_INPUT_TOKEN_BUDGET, aw as webviewOpenURIForContextItem, ax as pluralize, ay as UIToolStatus, az as getFileDiff, aA as diffWithLineNum, aB as UITerminalOutputType, aC as isCodeSearchContextItem, aD as v4, aE as lodashExports, aF as deserializeContextItem, aG as firstResultFromOperation, aH as ChatHistoryType, aI as S2_URL, aJ as ACCOUNT_USAGE_URL, aK as CODY_DOC_QUICKSTART_URL, aL as isPlgEsAccessDisabled, aM as isDefined, aN as browser, aO as CodyAutoSuggestionMode, aP as setDisplayPathEnvInfo, aQ as isErrorLike, aR as PromptString, aS as createGuardrailsImpl, U as Uri } from "./vscode-shim-DpWxvTpJ.mjs";
7
+ import { aU, aT } from "./vscode-shim-DpWxvTpJ.mjs";
8
8
  import * as React$2 from "react";
9
9
  import React__default, { createContext, useContext, useMemo as useMemo$1, useLayoutEffect as useLayoutEffect$1, useEffect as useEffect$2, forwardRef, useState as useState$1, useCallback, useRef as useRef$1, Suspense, createElement, memo as memo$2, useImperativeHandle, Children, isValidElement, cloneElement, Fragment as Fragment$2, useReducer, useId as useId$2, useInsertionEffect as useInsertionEffect$1, Component } from "react";
10
10
  var classnames = { exports: {} };
@@ -82,9 +82,9 @@ function clsx$1() {
82
82
  function t$2(t2) {
83
83
  return {};
84
84
  }
85
- const e$1 = {}, n$1 = {}, r$4 = {}, i$2 = {}, s$3 = {}, o$5 = {}, l$3 = {}, c$4 = {}, a$4 = {}, u$7 = {}, f$3 = {}, d$3 = {}, h$5 = {}, g$5 = {}, _$3 = {}, p$9 = {}, y$4 = {}, m$9 = {}, x$6 = {}, v$5 = {}, S$4 = {}, T$3 = {}, C$3 = {}, k$3 = {}, b$3 = {}, w$4 = {}, N$2 = {}, E$6 = {}, P$3 = {}, D$5 = {}, F$1 = {}, L$3 = {}, O$2 = {}, I$2 = {}, A$3 = {}, M$4 = {}, z$1 = {}, W$2 = {}, B$2 = {}, R$3 = {}, K$2 = {}, J$2 = {}, U$2 = {}, V$2 = {}, $$1 = {}, H$2 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, j = H$2 && "documentMode" in document ? document.documentMode : null, q = H$2 && /Mac|iPod|iPhone|iPad/.test(navigator.platform), Q$3 = H$2 && /^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent), X$4 = !(!H$2 || !("InputEvent" in window) || j) && "getTargetRanges" in new window.InputEvent("input"), Y$3 = H$2 && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), Z$2 = H$2 && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, G$3 = H$2 && /Android/.test(navigator.userAgent), tt = H$2 && /^(?=.*Chrome).*/i.test(navigator.userAgent), et = H$2 && G$3 && tt, nt = H$2 && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !tt, rt = 1, it = 3, st$1 = 0, ot = 1, lt$1 = 2, ct$1 = 0, at$1 = 1, ut$1 = 2, ht = 4, gt$1 = 8, mt$1 = 128, xt = 112 | (3 | ht | gt$1) | mt$1, vt = 1, St = 2, Tt$1 = 3, Ct = 4, kt = 5, bt = 6, wt = Y$3 || Z$2 || nt ? " " : "​", Nt$1 = "\n\n", Et = Q$3 ? " " : wt, Pt = "֑-߿יִ-﷽ﹰ-ﻼ", Dt = "A-Za-zÀ-ÖØ-öø-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-￿", Ft = new RegExp("^[^" + Dt + "]*[" + Pt + "]"), Lt = new RegExp("^[^" + Pt + "]*[" + Dt + "]"), Ot$1 = { bold: 1, code: 16, highlight: mt$1, italic: 2, strikethrough: ht, subscript: 32, superscript: 64, underline: gt$1 }, It$1 = { directionless: 1, unmergeable: 2 }, At = { center: St, end: bt, justify: Ct, left: vt, right: Tt$1, start: kt }, Mt = { [St]: "center", [bt]: "end", [Ct]: "justify", [vt]: "left", [Tt$1]: "right", [kt]: "start" }, zt = { normal: 0, segmented: 2, token: 1 }, Wt = { [ct$1]: "normal", [ut$1]: "segmented", [at$1]: "token" };
85
+ const e = {}, n$1 = {}, r$4 = {}, i$2 = {}, s$2 = {}, o$4 = {}, l$2 = {}, c$3 = {}, a$3 = {}, u$6 = {}, f$2 = {}, d$2 = {}, h$4 = {}, g$5 = {}, _$2 = {}, p$8 = {}, y$3 = {}, m$8 = {}, x$6 = {}, v$4 = {}, S$4 = {}, T$3 = {}, C$3 = {}, k$3 = {}, b$2 = {}, w$3 = {}, N$2 = {}, E$6 = {}, P$2 = {}, D$5 = {}, F$1 = {}, L$3 = {}, O$2 = {}, I$2 = {}, A$3 = {}, M$4 = {}, z$1 = {}, W$2 = {}, B$2 = {}, R$3 = {}, K$2 = {}, J$2 = {}, U$2 = {}, V$2 = {}, $$1 = {}, H$2 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, j = H$2 && "documentMode" in document ? document.documentMode : null, q = H$2 && /Mac|iPod|iPhone|iPad/.test(navigator.platform), Q$3 = H$2 && /^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent), X$4 = !(!H$2 || !("InputEvent" in window) || j) && "getTargetRanges" in new window.InputEvent("input"), Y$3 = H$2 && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), Z$2 = H$2 && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, G$3 = H$2 && /Android/.test(navigator.userAgent), tt = H$2 && /^(?=.*Chrome).*/i.test(navigator.userAgent), et = H$2 && G$3 && tt, nt = H$2 && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !tt, rt = 1, it = 3, st$1 = 0, ot = 1, lt$1 = 2, ct$1 = 0, at$1 = 1, ut$1 = 2, ht = 4, gt$1 = 8, mt$1 = 128, xt = 112 | (3 | ht | gt$1) | mt$1, vt = 1, St = 2, Tt$1 = 3, Ct = 4, kt = 5, bt = 6, wt = Y$3 || Z$2 || nt ? " " : "​", Nt$1 = "\n\n", Et = Q$3 ? " " : wt, Pt = "֑-߿יִ-﷽ﹰ-ﻼ", Dt = "A-Za-zÀ-ÖØ-öø-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-￿", Ft = new RegExp("^[^" + Dt + "]*[" + Pt + "]"), Lt = new RegExp("^[^" + Pt + "]*[" + Dt + "]"), Ot$1 = { bold: 1, code: 16, highlight: mt$1, italic: 2, strikethrough: ht, subscript: 32, superscript: 64, underline: gt$1 }, It$1 = { directionless: 1, unmergeable: 2 }, At = { center: St, end: bt, justify: Ct, left: vt, right: Tt$1, start: kt }, Mt = { [St]: "center", [bt]: "end", [Ct]: "justify", [vt]: "left", [Tt$1]: "right", [kt]: "start" }, zt = { normal: 0, segmented: 2, token: 1 }, Wt = { [ct$1]: "normal", [ut$1]: "segmented", [at$1]: "token" };
86
86
  function Bt(t2) {
87
- return t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
87
+ return t2 && t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
88
88
  }
89
89
  var Rt = Bt(function(t2) {
90
90
  const e2 = new URLSearchParams();
@@ -959,17 +959,17 @@ function ur(t2) {
959
959
  const fr = Object.freeze({}), dr = 30, hr = [["keydown", function(t2, e2) {
960
960
  if (gr = t2.timeStamp, _r = t2.key, e2.isComposing()) return;
961
961
  const { key: n2, shiftKey: r2, ctrlKey: o2, metaKey: l2, altKey: c2 } = t2;
962
- if (Xe$1(e2, _$3, t2)) return;
962
+ if (Xe$1(e2, _$2, t2)) return;
963
963
  if (null == n2) return;
964
964
  if (function(t3, e3, n3, r3) {
965
965
  return ze$1(t3) && !e3 && !r3 && !n3;
966
- }(n2, o2, c2, l2)) Xe$1(e2, p$9, t2);
966
+ }(n2, o2, c2, l2)) Xe$1(e2, p$8, t2);
967
967
  else if (function(t3, e3, n3, r3, i) {
968
968
  return ze$1(t3) && !r3 && !n3 && (e3 || i);
969
- }(n2, o2, r2, c2, l2)) Xe$1(e2, y$4, t2);
969
+ }(n2, o2, r2, c2, l2)) Xe$1(e2, y$3, t2);
970
970
  else if (function(t3, e3, n3, r3) {
971
971
  return Me$2(t3) && !e3 && !r3 && !n3;
972
- }(n2, o2, c2, l2)) Xe$1(e2, m$9, t2);
972
+ }(n2, o2, c2, l2)) Xe$1(e2, m$8, t2);
973
973
  else if (function(t3, e3, n3, r3, i) {
974
974
  return Me$2(t3) && !r3 && !n3 && (e3 || i);
975
975
  }(n2, o2, r2, c2, l2)) Xe$1(e2, x$6, t2);
@@ -977,7 +977,7 @@ const fr = Object.freeze({}), dr = 30, hr = [["keydown", function(t2, e2) {
977
977
  return /* @__PURE__ */ function(t4) {
978
978
  return "ArrowUp" === t4;
979
979
  }(t3) && !e3 && !n3;
980
- }(n2, o2, l2)) Xe$1(e2, v$5, t2);
980
+ }(n2, o2, l2)) Xe$1(e2, v$4, t2);
981
981
  else if (/* @__PURE__ */ function(t3, e3, n3) {
982
982
  return /* @__PURE__ */ function(t4) {
983
983
  return "ArrowDown" === t4;
@@ -991,7 +991,7 @@ const fr = Object.freeze({}), dr = 30, hr = [["keydown", function(t2, e2) {
991
991
  }(n2)) Xe$1(e2, C$3, t2);
992
992
  else if (function(t3, e3) {
993
993
  return q && e3 && "o" === t3.toLowerCase();
994
- }(n2, o2)) t2.preventDefault(), Sr = true, Xe$1(e2, s$3, true);
994
+ }(n2, o2)) t2.preventDefault(), Sr = true, Xe$1(e2, s$2, true);
995
995
  else if (function(t3, e3) {
996
996
  return Be$1(t3) && !e3;
997
997
  }(n2, r2)) Sr = false, Xe$1(e2, T$3, t2);
@@ -1000,37 +1000,37 @@ const fr = Object.freeze({}), dr = 30, hr = [["keydown", function(t2, e2) {
1000
1000
  }(n2, c2, l2, o2)) Re$2(n2) ? Xe$1(e2, k$3, t2) : (t2.preventDefault(), Xe$1(e2, i$2, true));
1001
1001
  else if (/* @__PURE__ */ function(t3) {
1002
1002
  return "Escape" === t3;
1003
- }(n2)) Xe$1(e2, b$3, t2);
1003
+ }(n2)) Xe$1(e2, b$2, t2);
1004
1004
  else if (function(t3, e3, n3, r3, i) {
1005
1005
  return q ? !(n3 || r3 || i) && (Ke$1(t3) || "d" === t3.toLowerCase() && e3) : !(e3 || r3 || i) && Ke$1(t3);
1006
- }(n2, o2, r2, c2, l2)) Ke$1(n2) ? Xe$1(e2, w$4, t2) : (t2.preventDefault(), Xe$1(e2, i$2, false));
1006
+ }(n2, o2, r2, c2, l2)) Ke$1(n2) ? Xe$1(e2, w$3, t2) : (t2.preventDefault(), Xe$1(e2, i$2, false));
1007
1007
  else if (function(t3, e3, n3) {
1008
1008
  return Re$2(t3) && (q ? e3 : n3);
1009
- }(n2, c2, o2)) t2.preventDefault(), Xe$1(e2, u$7, true);
1009
+ }(n2, c2, o2)) t2.preventDefault(), Xe$1(e2, u$6, true);
1010
1010
  else if (function(t3, e3, n3) {
1011
1011
  return Ke$1(t3) && (q ? e3 : n3);
1012
- }(n2, c2, o2)) t2.preventDefault(), Xe$1(e2, u$7, false);
1012
+ }(n2, c2, o2)) t2.preventDefault(), Xe$1(e2, u$6, false);
1013
1013
  else if (function(t3, e3) {
1014
1014
  return q && e3 && Re$2(t3);
1015
- }(n2, l2)) t2.preventDefault(), Xe$1(e2, f$3, true);
1015
+ }(n2, l2)) t2.preventDefault(), Xe$1(e2, f$2, true);
1016
1016
  else if (function(t3, e3) {
1017
1017
  return q && e3 && Ke$1(t3);
1018
- }(n2, l2)) t2.preventDefault(), Xe$1(e2, f$3, false);
1018
+ }(n2, l2)) t2.preventDefault(), Xe$1(e2, f$2, false);
1019
1019
  else if (function(t3, e3, n3, r3) {
1020
1020
  return "b" === t3.toLowerCase() && !e3 && We$1(n3, r3);
1021
- }(n2, c2, l2, o2)) t2.preventDefault(), Xe$1(e2, d$3, "bold");
1021
+ }(n2, c2, l2, o2)) t2.preventDefault(), Xe$1(e2, d$2, "bold");
1022
1022
  else if (function(t3, e3, n3, r3) {
1023
1023
  return "u" === t3.toLowerCase() && !e3 && We$1(n3, r3);
1024
- }(n2, c2, l2, o2)) t2.preventDefault(), Xe$1(e2, d$3, "underline");
1024
+ }(n2, c2, l2, o2)) t2.preventDefault(), Xe$1(e2, d$2, "underline");
1025
1025
  else if (function(t3, e3, n3, r3) {
1026
1026
  return "i" === t3.toLowerCase() && !e3 && We$1(n3, r3);
1027
- }(n2, c2, l2, o2)) t2.preventDefault(), Xe$1(e2, d$3, "italic");
1027
+ }(n2, c2, l2, o2)) t2.preventDefault(), Xe$1(e2, d$2, "italic");
1028
1028
  else if (/* @__PURE__ */ function(t3, e3, n3, r3) {
1029
1029
  return "Tab" === t3 && !e3 && !n3 && !r3;
1030
1030
  }(n2, c2, o2, l2)) Xe$1(e2, N$2, t2);
1031
1031
  else if (function(t3, e3, n3, r3) {
1032
1032
  return "z" === t3.toLowerCase() && !e3 && We$1(n3, r3);
1033
- }(n2, r2, l2, o2)) t2.preventDefault(), Xe$1(e2, h$5, void 0);
1033
+ }(n2, r2, l2, o2)) t2.preventDefault(), Xe$1(e2, h$4, void 0);
1034
1034
  else if (function(t3, e3, n3, r3) {
1035
1035
  return q ? "z" === t3.toLowerCase() && n3 && e3 : "y" === t3.toLowerCase() && r3 || "z" === t3.toLowerCase() && r3 && e3;
1036
1036
  }(n2, r2, l2, o2)) t2.preventDefault(), Xe$1(e2, g$5, void 0);
@@ -1054,7 +1054,7 @@ const fr = Object.freeze({}), dr = 30, hr = [["keydown", function(t2, e2) {
1054
1054
  const n2 = Fi$1();
1055
1055
  if (_i(n2) && !e2.isComposing()) {
1056
1056
  const r2 = n2.anchor, i = n2.anchor.getNode();
1057
- ye$2(r2.key), (t2.timeStamp < gr + dr || "element" === r2.type || !n2.isCollapsed() || i.getFormat() !== n2.format || ii$1(i) && i.getStyle() !== n2.style) && Xe$1(e2, l$3, Et);
1057
+ ye$2(r2.key), (t2.timeStamp < gr + dr || "element" === r2.type || !n2.isCollapsed() || i.getFormat() !== n2.format || ii$1(i) && i.getStyle() !== n2.style) && Xe$1(e2, l$2, Et);
1058
1058
  }
1059
1059
  });
1060
1060
  }], ["compositionend", function(t2, e2) {
@@ -1069,7 +1069,7 @@ const fr = Object.freeze({}), dr = 30, hr = [["keydown", function(t2, e2) {
1069
1069
  const i2 = n2.anchor.getNode(), s2 = _n(e2._window);
1070
1070
  if (null === s2) return;
1071
1071
  const o2 = n2.isBackward(), c2 = o2 ? n2.anchor.offset : n2.focus.offset, a2 = o2 ? n2.focus.offset : n2.anchor.offset;
1072
- X$4 && !n2.isCollapsed() && ii$1(i2) && null !== s2.anchorNode && i2.getTextContent().slice(0, c2) + r2 + i2.getTextContent().slice(c2 + a2) === Le$1(s2.anchorNode) || Xe$1(e2, l$3, r2);
1072
+ X$4 && !n2.isCollapsed() && ii$1(i2) && null !== s2.anchorNode && i2.getTextContent().slice(0, c2) + r2 + i2.getTextContent().slice(c2 + a2) === Le$1(s2.anchorNode) || Xe$1(e2, l$2, r2);
1073
1073
  const u2 = r2.length;
1074
1074
  Q$3 && u2 > 1 && "insertCompositionText" === t2.inputType && !e2.isComposing() && (n2.anchor.offset -= u2), Y$3 || Z$2 || nt || !e2.isComposing() || (gr = 0, ye$2(null));
1075
1075
  } else {
@@ -1140,73 +1140,73 @@ X$4 && hr.push(["beforeinput", (t2, e2) => function(t3, e3) {
1140
1140
  case "insertFromYank":
1141
1141
  case "insertFromDrop":
1142
1142
  case "insertReplacementText":
1143
- Xe$1(e3, l$3, t3);
1143
+ Xe$1(e3, l$2, t3);
1144
1144
  break;
1145
1145
  case "insertFromComposition":
1146
- ye$2(null), Xe$1(e3, l$3, t3);
1146
+ ye$2(null), Xe$1(e3, l$2, t3);
1147
1147
  break;
1148
1148
  case "insertLineBreak":
1149
- ye$2(null), Xe$1(e3, s$3, false);
1149
+ ye$2(null), Xe$1(e3, s$2, false);
1150
1150
  break;
1151
1151
  case "insertParagraph":
1152
- ye$2(null), Sr && !Z$2 ? (Sr = false, Xe$1(e3, s$3, false)) : Xe$1(e3, o$5, void 0);
1152
+ ye$2(null), Sr && !Z$2 ? (Sr = false, Xe$1(e3, s$2, false)) : Xe$1(e3, o$4, void 0);
1153
1153
  break;
1154
1154
  case "insertFromPaste":
1155
1155
  case "insertFromPasteAsQuotation":
1156
- Xe$1(e3, c$4, t3);
1156
+ Xe$1(e3, c$3, t3);
1157
1157
  break;
1158
1158
  case "deleteByComposition":
1159
1159
  (function(t4, e4) {
1160
1160
  return t4 !== e4 || ds(t4) || ds(e4) || !t4.isToken() || !e4.isToken();
1161
- })(v2, S2) && Xe$1(e3, a$4, t3);
1161
+ })(v2, S2) && Xe$1(e3, a$3, t3);
1162
1162
  break;
1163
1163
  case "deleteByDrag":
1164
1164
  case "deleteByCut":
1165
- Xe$1(e3, a$4, t3);
1165
+ Xe$1(e3, a$3, t3);
1166
1166
  break;
1167
1167
  case "deleteContent":
1168
1168
  Xe$1(e3, i$2, false);
1169
1169
  break;
1170
1170
  case "deleteWordBackward":
1171
- Xe$1(e3, u$7, true);
1171
+ Xe$1(e3, u$6, true);
1172
1172
  break;
1173
1173
  case "deleteWordForward":
1174
- Xe$1(e3, u$7, false);
1174
+ Xe$1(e3, u$6, false);
1175
1175
  break;
1176
1176
  case "deleteHardLineBackward":
1177
1177
  case "deleteSoftLineBackward":
1178
- Xe$1(e3, f$3, true);
1178
+ Xe$1(e3, f$2, true);
1179
1179
  break;
1180
1180
  case "deleteContentForward":
1181
1181
  case "deleteHardLineForward":
1182
1182
  case "deleteSoftLineForward":
1183
- Xe$1(e3, f$3, false);
1183
+ Xe$1(e3, f$2, false);
1184
1184
  break;
1185
1185
  case "formatStrikeThrough":
1186
- Xe$1(e3, d$3, "strikethrough");
1186
+ Xe$1(e3, d$2, "strikethrough");
1187
1187
  break;
1188
1188
  case "formatBold":
1189
- Xe$1(e3, d$3, "bold");
1189
+ Xe$1(e3, d$2, "bold");
1190
1190
  break;
1191
1191
  case "formatItalic":
1192
- Xe$1(e3, d$3, "italic");
1192
+ Xe$1(e3, d$2, "italic");
1193
1193
  break;
1194
1194
  case "formatUnderline":
1195
- Xe$1(e3, d$3, "underline");
1195
+ Xe$1(e3, d$2, "underline");
1196
1196
  break;
1197
1197
  case "historyUndo":
1198
- Xe$1(e3, h$5, void 0);
1198
+ Xe$1(e3, h$4, void 0);
1199
1199
  break;
1200
1200
  case "historyRedo":
1201
1201
  Xe$1(e3, g$5, void 0);
1202
1202
  }
1203
1203
  else {
1204
- if ("\n" === y2) t3.preventDefault(), Xe$1(e3, s$3, false);
1205
- else if (y2 === Nt$1) t3.preventDefault(), Xe$1(e3, o$5, void 0);
1204
+ if ("\n" === y2) t3.preventDefault(), Xe$1(e3, s$2, false);
1205
+ else if (y2 === Nt$1) t3.preventDefault(), Xe$1(e3, o$4, void 0);
1206
1206
  else if (null == y2 && t3.dataTransfer) {
1207
1207
  const e4 = t3.dataTransfer.getData("text/plain");
1208
1208
  t3.preventDefault(), _2.insertRawText(e4);
1209
- } else null != y2 && kr(_2, r2, y2, t3.timeStamp, true) ? (t3.preventDefault(), Xe$1(e3, l$3, y2)) : yr = y2;
1209
+ } else null != y2 && kr(_2, r2, y2, t3.timeStamp, true) ? (t3.preventDefault(), Xe$1(e3, l$2, y2)) : yr = y2;
1210
1210
  pr = t3.timeStamp;
1211
1211
  }
1212
1212
  });
@@ -1248,7 +1248,7 @@ function wr(t2, n2, r2) {
1248
1248
  c2.format = g2 ? h2 : 0;
1249
1249
  }
1250
1250
  }
1251
- Xe$1(n2, e$1, void 0);
1251
+ Xe$1(n2, e, void 0);
1252
1252
  });
1253
1253
  }
1254
1254
  function Nr(t2) {
@@ -2627,7 +2627,7 @@ let pi$1 = class pi {
2627
2627
  t3.add(s2.__key), we$2(t3);
2628
2628
  } else {
2629
2629
  s2.remove();
2630
- Zi$1().dispatchCommand(e$1, void 0);
2630
+ Zi$1().dispatchCommand(e, void 0);
2631
2631
  }
2632
2632
  return;
2633
2633
  }
@@ -3073,7 +3073,7 @@ function ss(t2, n2) {
3073
3073
  const [o4, l3] = s3[t4], c3 = e2.get(l3);
3074
3074
  void 0 !== c3 && o4(c3, { dirtyLeaves: r3, prevEditorState: i2, updateTags: n3 });
3075
3075
  }
3076
- }(t2, _2, x2, p2, o2), _i(c2) || null === c2 || null !== l2 && l2.is(c2) || t2.dispatchCommand(e$1, void 0);
3076
+ }(t2, _2, x2, p2, o2), _i(c2) || null === c2 || null !== l2 && l2.is(c2) || t2.dispatchCommand(e, void 0);
3077
3077
  const T2 = t2._pendingDecorators;
3078
3078
  null !== T2 && (t2._decorators = T2, t2._pendingDecorators = null, os$1("decorator", t2, true, T2)), function(t3, e2, n3) {
3079
3079
  const r3 = Ce$2(e2), i2 = Ce$2(n3);
@@ -3749,7 +3749,7 @@ function Fs(t2, e2, n2, r2) {
3749
3749
  null !== s2 && (s2.disconnect(), t2._observer = null), null !== e2 && (e2.textContent = ""), null !== n2 && (n2.textContent = "", i.set("root", n2));
3750
3750
  }
3751
3751
  function Ls(t2) {
3752
- const e2 = t2, n2 = Gi$1(), r2 = e2.theme || {}, i = void 0 === t2 ? n2 : e2.parentEditor || null, s2 = e2.disableEvents || false, o2 = ms(), l2 = e2.namespace || (null !== i ? i._config.namespace : Fe$1()), c2 = e2.editorState, a2 = [ps, qr, zr, oi$1, Ts, Ss, ...e2.nodes || []], { onError: u2, html: f2 } = e2, d2 = void 0 === e2.editable || e2.editable;
3752
+ const e2 = t2 || {}, n2 = Gi$1(), r2 = e2.theme || {}, i = void 0 === t2 ? n2 : e2.parentEditor || null, s2 = e2.disableEvents || false, o2 = ms(), l2 = e2.namespace || (null !== i ? i._config.namespace : Fe$1()), c2 = e2.editorState, a2 = [ps, qr, zr, oi$1, Ts, Ss, ...e2.nodes || []], { onError: u2, html: f2 } = e2, d2 = void 0 === e2.editable || e2.editable;
3753
3753
  let h2;
3754
3754
  if (void 0 === t2 && null !== n2) h2 = n2._nodes;
3755
3755
  else {
@@ -3917,7 +3917,7 @@ class Os {
3917
3917
  case "copy":
3918
3918
  return Xe$1(e4, M$4, t4);
3919
3919
  case "paste":
3920
- return n5 && Xe$1(e4, c$4, t4);
3920
+ return n5 && Xe$1(e4, c$3, t4);
3921
3921
  case "dragstart":
3922
3922
  return n5 && Xe$1(e4, O$2, t4);
3923
3923
  case "dragover":
@@ -3999,7 +3999,7 @@ class Os {
3999
3999
  }
4000
4000
  }
4001
4001
  function r$3(e2) {
4002
- return e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
4002
+ return e2 && e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
4003
4003
  }
4004
4004
  var t$1 = r$3(function(e2) {
4005
4005
  const n2 = new URLSearchParams();
@@ -4007,20 +4007,20 @@ var t$1 = r$3(function(e2) {
4007
4007
  for (let e3 = 1; e3 < arguments.length; e3++) n2.append("v", arguments[e3]);
4008
4008
  throw Error(`Minified Lexical error #${e2}; visit https://lexical.dev/docs/error?${n2} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
4009
4009
  });
4010
- const l$2 = createContext(null);
4011
- function o$4(e2, n2) {
4010
+ const l$1 = createContext(null);
4011
+ function o$3(e2, n2) {
4012
4012
  return { getTheme: function() {
4013
4013
  return null != n2 ? n2 : null;
4014
4014
  } };
4015
4015
  }
4016
- function u$6() {
4017
- const e2 = useContext(l$2);
4016
+ function u$5() {
4017
+ const e2 = useContext(l$1);
4018
4018
  return null == e2 && t$1(8), e2;
4019
4019
  }
4020
- const s$2 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, m$8 = s$2 ? useLayoutEffect$1 : useEffect$2, u$5 = { tag: "history-merge" };
4021
- function p$8({ initialConfig: a2, children: c2 }) {
4020
+ const s$1 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, m$7 = s$1 ? useLayoutEffect$1 : useEffect$2, u$4 = { tag: "history-merge" };
4021
+ function p$7({ initialConfig: a2, children: c2 }) {
4022
4022
  const p2 = useMemo$1(() => {
4023
- const { theme: t2, namespace: c3, nodes: l2, onError: d2, editorState: m2, html: p3 } = a2, f2 = o$4(null, t2), E2 = Ls({ editable: a2.editable, html: p3, namespace: c3, nodes: l2, onError: (e2) => d2(e2, E2), theme: t2 });
4023
+ const { theme: t2, namespace: c3, nodes: l2, onError: d2, editorState: m2, html: p3 } = a2, f2 = o$3(null, t2), E2 = Ls({ editable: a2.editable, html: p3, namespace: c3, nodes: l2, onError: (e2) => d2(e2, E2), theme: t2 });
4024
4024
  return function(e2, t3) {
4025
4025
  if (null === t3) return;
4026
4026
  if (void 0 === t3) e2.update(() => {
@@ -4028,41 +4028,41 @@ function p$8({ initialConfig: a2, children: c2 }) {
4028
4028
  if (t4.isEmpty()) {
4029
4029
  const o2 = ks();
4030
4030
  t4.append(o2);
4031
- const n2 = s$2 ? document.activeElement : null;
4031
+ const n2 = s$1 ? document.activeElement : null;
4032
4032
  (null !== Fi$1() || null !== n2 && n2 === e2.getRootElement()) && o2.select();
4033
4033
  }
4034
- }, u$5);
4034
+ }, u$4);
4035
4035
  else if (null !== t3) switch (typeof t3) {
4036
4036
  case "string": {
4037
4037
  const o2 = e2.parseEditorState(t3);
4038
- e2.setEditorState(o2, u$5);
4038
+ e2.setEditorState(o2, u$4);
4039
4039
  break;
4040
4040
  }
4041
4041
  case "object":
4042
- e2.setEditorState(t3, u$5);
4042
+ e2.setEditorState(t3, u$4);
4043
4043
  break;
4044
4044
  case "function":
4045
4045
  e2.update(() => {
4046
4046
  ke$1().isEmpty() && t3(e2);
4047
- }, u$5);
4047
+ }, u$4);
4048
4048
  }
4049
4049
  }(E2, m2), [E2, f2];
4050
4050
  }, []);
4051
- return m$8(() => {
4051
+ return m$7(() => {
4052
4052
  const e2 = a2.editable, [t2] = p2;
4053
4053
  t2.setEditable(void 0 === e2 || e2);
4054
- }, []), jsx(l$2.Provider, { value: p2, children: c2 });
4054
+ }, []), jsx(l$1.Provider, { value: p2, children: c2 });
4055
4055
  }
4056
- function s$1() {
4056
+ function s() {
4057
4057
  return ke$1().getTextContent();
4058
4058
  }
4059
- function u$4(t2, e2 = true) {
4059
+ function u$3(t2, e2 = true) {
4060
4060
  if (t2) return false;
4061
- let n2 = s$1();
4061
+ let n2 = s();
4062
4062
  return e2 && (n2 = n2.trim()), "" === n2;
4063
4063
  }
4064
- function c$3(o2) {
4065
- if (!u$4(o2, false)) return false;
4064
+ function c$2(o2) {
4065
+ if (!u$3(o2, false)) return false;
4066
4066
  const l2 = ke$1().getChildren(), s2 = l2.length;
4067
4067
  if (s2 > 1) return false;
4068
4068
  for (let t2 = 0; t2 < s2; t2++) {
@@ -4081,28 +4081,28 @@ function c$3(o2) {
4081
4081
  return true;
4082
4082
  }
4083
4083
  function g$4(t2) {
4084
- return () => c$3(t2);
4084
+ return () => c$2(t2);
4085
4085
  }
4086
- function d$2(t2) {
4087
- return t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
4086
+ function d$1(t2) {
4087
+ return t2 && t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
4088
4088
  }
4089
- d$2(function(t2) {
4089
+ d$1(function(t2) {
4090
4090
  const e2 = new URLSearchParams();
4091
4091
  e2.append("code", t2);
4092
4092
  for (let t3 = 1; t3 < arguments.length; t3++) e2.append("v", arguments[t3]);
4093
4093
  throw Error(`Minified Lexical error #${t2}; visit https://lexical.dev/docs/error?${e2} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
4094
4094
  });
4095
- function m$7(e2) {
4096
- return e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
4095
+ function m$6(e2) {
4096
+ return e2 && e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
4097
4097
  }
4098
- m$7(function(e2) {
4098
+ m$6(function(e2) {
4099
4099
  const t2 = new URLSearchParams();
4100
4100
  t2.append("code", e2);
4101
4101
  for (let e3 = 1; e3 < arguments.length; e3++) t2.append("v", arguments[e3]);
4102
4102
  throw Error(`Minified Lexical error #${e2}; visit https://lexical.dev/docs/error?${t2} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
4103
4103
  });
4104
4104
  const x$5 = /* @__PURE__ */ new Map();
4105
- function w$3(e2) {
4105
+ function w$2(e2) {
4106
4106
  const t2 = {}, n2 = e2.split(";");
4107
4107
  for (const e3 of n2) if ("" !== e3) {
4108
4108
  const [n3, l2] = e3.split(/:([^]+)/);
@@ -4129,7 +4129,7 @@ function E$5(e2, n2) {
4129
4129
  return n2;
4130
4130
  }
4131
4131
  function I$1(e2) {
4132
- const t2 = e2.getStyle(), n2 = w$3(t2);
4132
+ const t2 = e2.getStyle(), n2 = w$2(t2);
4133
4133
  x$5.set(t2, n2);
4134
4134
  }
4135
4135
  function A$2(e2, t2) {
@@ -4148,17 +4148,17 @@ function M$3(e2, t2, n2) {
4148
4148
  L$2(e2, t2, n2 ? !l2 : l2, "character");
4149
4149
  }
4150
4150
  function g$3(e2) {
4151
- return e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
4151
+ return e2 && e2.__esModule && Object.prototype.hasOwnProperty.call(e2, "default") ? e2.default : e2;
4152
4152
  }
4153
- var p$7 = g$3(function(e2) {
4153
+ var p$6 = g$3(function(e2) {
4154
4154
  const t2 = new URLSearchParams();
4155
4155
  t2.append("code", e2);
4156
4156
  for (let e3 = 1; e3 < arguments.length; e3++) t2.append("v", arguments[e3]);
4157
4157
  throw Error(`Minified Lexical error #${e2}; visit https://lexical.dev/docs/error?${t2} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
4158
4158
  });
4159
- const h$4 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, m$6 = h$4 && "documentMode" in document ? document.documentMode : null;
4160
- !(!h$4 || !("InputEvent" in window) || m$6) && "getTargetRanges" in new window.InputEvent("input");
4161
- function b$2(...e2) {
4159
+ const h$3 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, m$5 = h$3 && "documentMode" in document ? document.documentMode : null;
4160
+ !(!h$3 || !("InputEvent" in window) || m$5) && "getTargetRanges" in new window.InputEvent("input");
4161
+ function b$1(...e2) {
4162
4162
  return () => {
4163
4163
  for (let t2 = e2.length - 1; t2 >= 0; t2--) e2[t2]();
4164
4164
  e2.length = 0;
@@ -4166,7 +4166,7 @@ function b$2(...e2) {
4166
4166
  }
4167
4167
  function J$1(e2) {
4168
4168
  const t2 = Q$2(e2, (e3) => ds(e3) && !e3.isInline());
4169
- return ds(t2) || p$7(4, e2.__key), t2;
4169
+ return ds(t2) || p$6(4, e2.__key), t2;
4170
4170
  }
4171
4171
  const Q$2 = (e2, t2) => {
4172
4172
  let n2 = e2;
@@ -4183,8 +4183,8 @@ function oe$1(e2, t2) {
4183
4183
  const n2 = e2.getFirstChild();
4184
4184
  null !== n2 ? n2.insertBefore(t2) : e2.append(t2);
4185
4185
  }
4186
- const m$5 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement ? useLayoutEffect$1 : useEffect$2;
4187
- function f$2({ editor: e2, ariaActiveDescendant: t2, ariaAutoComplete: i, ariaControls: a2, ariaDescribedBy: d2, ariaExpanded: c2, ariaLabel: s2, ariaLabelledBy: u2, ariaMultiline: f2, ariaOwns: b2, ariaRequired: p2, autoCapitalize: x2, className: E2, id: v2, role: w2 = "textbox", spellCheck: y2 = true, style: C2, tabIndex: h2, "data-testid": L2, ...g2 }, D2) {
4186
+ const m$4 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement ? useLayoutEffect$1 : useEffect$2;
4187
+ function f$1({ editor: e2, ariaActiveDescendant: t2, ariaAutoComplete: i, ariaControls: a2, ariaDescribedBy: d2, ariaExpanded: c2, ariaLabel: s2, ariaLabelledBy: u2, ariaMultiline: f2, ariaOwns: b2, ariaRequired: p2, autoCapitalize: x2, className: E2, id: v2, role: w2 = "textbox", spellCheck: y2 = true, style: C2, tabIndex: h2, "data-testid": L2, ...g2 }, D2) {
4188
4188
  const [R2, k2] = useState$1(e2.isEditable()), q2 = useCallback((t3) => {
4189
4189
  t3 && t3.ownerDocument && t3.ownerDocument.defaultView ? e2.setRootElement(t3) : e2.setRootElement(null);
4190
4190
  }, [e2]), z2 = useMemo$1(() => /* @__PURE__ */ function(...e3) {
@@ -4194,28 +4194,28 @@ function f$2({ editor: e2, ariaActiveDescendant: t2, ariaAutoComplete: i, ariaCo
4194
4194
  });
4195
4195
  };
4196
4196
  }(D2, q2), [q2, D2]);
4197
- return m$5(() => (k2(e2.isEditable()), e2.registerEditableListener((e3) => {
4197
+ return m$4(() => (k2(e2.isEditable()), e2.registerEditableListener((e3) => {
4198
4198
  k2(e3);
4199
4199
  })), [e2]), jsx("div", { ...g2, "aria-activedescendant": R2 ? t2 : void 0, "aria-autocomplete": R2 ? i : "none", "aria-controls": R2 ? a2 : void 0, "aria-describedby": d2, "aria-expanded": R2 && "combobox" === w2 ? !!c2 : void 0, "aria-label": s2, "aria-labelledby": u2, "aria-multiline": f2, "aria-owns": R2 ? b2 : void 0, "aria-readonly": !R2 || void 0, "aria-required": p2, autoCapitalize: x2, className: E2, contentEditable: R2, "data-testid": L2, id: v2, ref: z2, role: R2 ? w2 : void 0, spellCheck: y2, style: C2, tabIndex: h2 });
4200
4200
  }
4201
- const b$1 = forwardRef(f$2);
4202
- function p$6(e2) {
4201
+ const b = forwardRef(f$1);
4202
+ function p$5(e2) {
4203
4203
  return e2.getEditorState().read(g$4(e2.isComposing()));
4204
4204
  }
4205
4205
  const x$4 = forwardRef(E$4);
4206
4206
  function E$4(t2, i) {
4207
- const { placeholder: a2, ...r2 } = t2, [n2] = u$6();
4208
- return jsxs(Fragment$1, { children: [jsx(b$1, { editor: n2, ...r2, ref: i }), null != a2 && jsx(v$4, { editor: n2, content: a2 })] });
4207
+ const { placeholder: a2, ...r2 } = t2, [n2] = u$5();
4208
+ return jsxs(Fragment$1, { children: [jsx(b, { editor: n2, ...r2, ref: i }), null != a2 && jsx(v$3, { editor: n2, content: a2 })] });
4209
4209
  }
4210
- function v$4({ content: e2, editor: i }) {
4210
+ function v$3({ content: e2, editor: i }) {
4211
4211
  const a2 = function(e3) {
4212
- const [t2, i2] = useState$1(() => p$6(e3));
4213
- return m$5(() => {
4212
+ const [t2, i2] = useState$1(() => p$5(e3));
4213
+ return m$4(() => {
4214
4214
  function t3() {
4215
- const t4 = p$6(e3);
4215
+ const t4 = p$5(e3);
4216
4216
  i2(t4);
4217
4217
  }
4218
- return t3(), b$2(e3.registerUpdateListener(() => {
4218
+ return t3(), b$1(e3.registerUpdateListener(() => {
4219
4219
  t3();
4220
4220
  }), e3.registerEditableListener(() => {
4221
4221
  t3();
@@ -4228,8 +4228,8 @@ function v$4({ content: e2, editor: i }) {
4228
4228
  let d2 = null;
4229
4229
  return "function" == typeof e2 ? d2 = e2(n2) : null !== e2 && (d2 = e2), null === d2 ? null : jsx("div", { "aria-hidden": true, children: d2 });
4230
4230
  }
4231
- function o$3({ editorRef: o2 }) {
4232
- const [r2] = u$6();
4231
+ function o$2({ editorRef: o2 }) {
4232
+ const [r2] = u$5();
4233
4233
  return React$2.useEffect(() => {
4234
4234
  "function" == typeof o2 ? o2(r2) : "object" == typeof o2 && (o2.current = r2);
4235
4235
  }, [r2]), null;
@@ -4239,11 +4239,11 @@ function t(r2, e2) {
4239
4239
  return r3.__proto__ = e3, r3;
4240
4240
  }, t(r2, e2);
4241
4241
  }
4242
- var o$2 = { error: null }, n = function(e2) {
4242
+ var o$1 = { error: null }, n = function(e2) {
4243
4243
  var n2, a2;
4244
4244
  function s2() {
4245
4245
  for (var r2, t2 = arguments.length, n3 = new Array(t2), a3 = 0; a3 < t2; a3++) n3[a3] = arguments[a3];
4246
- return (r2 = e2.call.apply(e2, [this].concat(n3)) || this).state = o$2, r2.resetErrorBoundary = function() {
4246
+ return (r2 = e2.call.apply(e2, [this].concat(n3)) || this).state = o$1, r2.resetErrorBoundary = function() {
4247
4247
  for (var e3, t3 = arguments.length, o2 = new Array(t3), n4 = 0; n4 < t3; n4++) o2[n4] = arguments[n4];
4248
4248
  null == r2.props.onReset || (e3 = r2.props).onReset.apply(e3, o2), r2.reset();
4249
4249
  }, r2;
@@ -4253,7 +4253,7 @@ var o$2 = { error: null }, n = function(e2) {
4253
4253
  };
4254
4254
  var l2 = s2.prototype;
4255
4255
  return l2.reset = function() {
4256
- this.setState(o$2);
4256
+ this.setState(o$1);
4257
4257
  }, l2.componentDidCatch = function(r2, e3) {
4258
4258
  var t2, o2;
4259
4259
  null == (t2 = (o2 = this.props).onError) || t2.call(o2, r2, e3);
@@ -4274,15 +4274,15 @@ var o$2 = { error: null }, n = function(e2) {
4274
4274
  return this.props.children;
4275
4275
  }, s2;
4276
4276
  }(React$2.Component);
4277
- function a$3({ children: r2, onError: t2 }) {
4277
+ function a$2({ children: r2, onError: t2 }) {
4278
4278
  return jsx(n, { fallback: jsx("div", { style: { border: "1px solid #f00", color: "#f00", padding: "8px" }, children: "An error was thrown." }), onError: t2, children: r2 });
4279
4279
  }
4280
- const l$1 = 0, f$1 = 1, p$5 = 2, h$3 = 0, m$4 = 1, g$2 = 2, _$2 = 3, S$3 = 4;
4281
- function y$3(t2, e2, n2, r2, o2) {
4282
- if (null === t2 || 0 === n2.size && 0 === r2.size && !o2) return h$3;
4280
+ const l = 0, f = 1, p$4 = 2, h$2 = 0, m$3 = 1, g$2 = 2, _$1 = 3, S$3 = 4;
4281
+ function y$2(t2, e2, n2, r2, o2) {
4282
+ if (null === t2 || 0 === n2.size && 0 === r2.size && !o2) return h$2;
4283
4283
  const i = e2._selection, s2 = t2._selection;
4284
- if (o2) return m$4;
4285
- if (!(_i(i) && _i(s2) && s2.isCollapsed() && i.isCollapsed())) return h$3;
4284
+ if (o2) return m$3;
4285
+ if (!(_i(i) && _i(s2) && s2.isCollapsed() && i.isCollapsed())) return h$2;
4286
4286
  const c2 = function(t3, e3, n3) {
4287
4287
  const r3 = t3._nodeMap, o3 = [];
4288
4288
  for (const t4 of e3) {
@@ -4296,39 +4296,39 @@ function y$3(t2, e2, n2, r2, o2) {
4296
4296
  }
4297
4297
  return o3;
4298
4298
  }(e2, n2, r2);
4299
- if (0 === c2.length) return h$3;
4299
+ if (0 === c2.length) return h$2;
4300
4300
  if (c2.length > 1) {
4301
4301
  const n3 = e2._nodeMap, r3 = n3.get(i.anchor.key), o3 = n3.get(s2.anchor.key);
4302
- return r3 && o3 && !t2._nodeMap.has(r3.__key) && ii$1(r3) && 1 === r3.__text.length && 1 === i.anchor.offset ? g$2 : h$3;
4302
+ return r3 && o3 && !t2._nodeMap.has(r3.__key) && ii$1(r3) && 1 === r3.__text.length && 1 === i.anchor.offset ? g$2 : h$2;
4303
4303
  }
4304
4304
  const l2 = c2[0], f2 = t2._nodeMap.get(l2.__key);
4305
- if (!ii$1(f2) || !ii$1(l2) || f2.__mode !== l2.__mode) return h$3;
4305
+ if (!ii$1(f2) || !ii$1(l2) || f2.__mode !== l2.__mode) return h$2;
4306
4306
  const p2 = f2.__text, y2 = l2.__text;
4307
- if (p2 === y2) return h$3;
4307
+ if (p2 === y2) return h$2;
4308
4308
  const k2 = i.anchor, C2 = s2.anchor;
4309
- if (k2.key !== C2.key || "text" !== k2.type) return h$3;
4309
+ if (k2.key !== C2.key || "text" !== k2.type) return h$2;
4310
4310
  const x2 = k2.offset, M2 = C2.offset, z2 = y2.length - p2.length;
4311
- return 1 === z2 && M2 === x2 - 1 ? g$2 : -1 === z2 && M2 === x2 + 1 ? _$2 : -1 === z2 && M2 === x2 ? S$3 : h$3;
4311
+ return 1 === z2 && M2 === x2 - 1 ? g$2 : -1 === z2 && M2 === x2 + 1 ? _$1 : -1 === z2 && M2 === x2 ? S$3 : h$2;
4312
4312
  }
4313
4313
  function k$2(t2, e2) {
4314
- let n2 = Date.now(), r2 = h$3;
4314
+ let n2 = Date.now(), r2 = h$2;
4315
4315
  return (o2, i, s2, c2, d2, m2) => {
4316
4316
  const g2 = Date.now();
4317
- if (m2.has("historic")) return r2 = h$3, n2 = g2, p$5;
4318
- const _2 = y$3(o2, i, c2, d2, t2.isComposing()), S2 = (() => {
4317
+ if (m2.has("historic")) return r2 = h$2, n2 = g2, p$4;
4318
+ const _2 = y$2(o2, i, c2, d2, t2.isComposing()), S2 = (() => {
4319
4319
  const S3 = null === s2 || s2.editor === t2, y2 = m2.has("history-push");
4320
- if (!y2 && S3 && m2.has("history-merge")) return l$1;
4321
- if (null === o2) return f$1;
4320
+ if (!y2 && S3 && m2.has("history-merge")) return l;
4321
+ if (null === o2) return f;
4322
4322
  const k2 = i._selection;
4323
- if (!(c2.size > 0 || d2.size > 0)) return null !== k2 ? l$1 : p$5;
4324
- if (false === y2 && _2 !== h$3 && _2 === r2 && g2 < n2 + e2 && S3) return l$1;
4323
+ if (!(c2.size > 0 || d2.size > 0)) return null !== k2 ? l : p$4;
4324
+ if (false === y2 && _2 !== h$2 && _2 === r2 && g2 < n2 + e2 && S3) return l;
4325
4325
  if (1 === c2.size) {
4326
4326
  if (function(t3, e3, n3) {
4327
4327
  const r3 = e3._nodeMap.get(t3), o3 = n3._nodeMap.get(t3), i2 = e3._selection, s3 = n3._selection;
4328
4328
  return !(_i(i2) && _i(s3) && "element" === i2.anchor.type && "element" === i2.focus.type && "text" === s3.anchor.type && "text" === s3.focus.type || !ii$1(r3) || !ii$1(o3) || r3.__parent !== o3.__parent) && JSON.stringify(e3.read(() => r3.exportJSON())) === JSON.stringify(n3.read(() => o3.exportJSON()));
4329
- }(Array.from(c2)[0], o2, i)) return l$1;
4329
+ }(Array.from(c2)[0], o2, i)) return l;
4330
4330
  }
4331
- return f$1;
4331
+ return f;
4332
4332
  })();
4333
4333
  return n2 = g2, r2 = _2, S2;
4334
4334
  };
@@ -4337,7 +4337,7 @@ function C$2(t2) {
4337
4337
  t2.undoStack = [], t2.redoStack = [], t2.current = null;
4338
4338
  }
4339
4339
  function x$3(a2, u2, d2) {
4340
- const l2 = k$2(a2, d2), h2 = b$2(a2.registerCommand(h$5, () => (function(t2, e2) {
4340
+ const l2 = k$2(a2, d2), h2 = b$1(a2.registerCommand(h$4, () => (function(t2, e2) {
4341
4341
  const n2 = e2.redoStack, r2 = e2.undoStack;
4342
4342
  if (0 !== r2.length) {
4343
4343
  const o2 = e2.current, i = r2.pop();
@@ -4355,8 +4355,8 @@ function x$3(a2, u2, d2) {
4355
4355
  const i = u2.current, d3 = u2.redoStack, h3 = u2.undoStack, m2 = null === i ? null : i.editorState;
4356
4356
  if (null !== i && t2 === m2) return;
4357
4357
  const g2 = l2(e2, t2, i, n2, r2, o2);
4358
- if (g2 === f$1) 0 !== d3.length && (u2.redoStack = [], a2.dispatchCommand(K$2, false)), null !== i && (h3.push({ ...i }), a2.dispatchCommand(J$2, true));
4359
- else if (g2 === p$5) return;
4358
+ if (g2 === f) 0 !== d3.length && (u2.redoStack = [], a2.dispatchCommand(K$2, false)), null !== i && (h3.push({ ...i }), a2.dispatchCommand(J$2, true));
4359
+ else if (g2 === p$4) return;
4360
4360
  u2.current = { editor: a2, editorState: t2 };
4361
4361
  }));
4362
4362
  return h2;
@@ -4364,8 +4364,8 @@ function x$3(a2, u2, d2) {
4364
4364
  function M$2() {
4365
4365
  return { current: null, redoStack: [], undoStack: [] };
4366
4366
  }
4367
- function a$2({ delay: a2, externalHistoryState: c2 }) {
4368
- const [l2] = u$6();
4367
+ function a$1({ delay: a2, externalHistoryState: c2 }) {
4368
+ const [l2] = u$5();
4369
4369
  return function(t2, a3, c3 = 1e3) {
4370
4370
  const l3 = useMemo$1(() => a3 || M$2(), [a3]);
4371
4371
  useEffect$2(() => x$3(t2, l3, c3), [c3, t2, l3]);
@@ -4373,27 +4373,27 @@ function a$2({ delay: a2, externalHistoryState: c2 }) {
4373
4373
  }
4374
4374
  const r$2 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement ? useLayoutEffect$1 : useEffect$2;
4375
4375
  function i$1({ ignoreHistoryMergeTagChange: t2 = true, ignoreSelectionChange: o2 = false, onChange: i }) {
4376
- const [n2] = u$6();
4376
+ const [n2] = u$5();
4377
4377
  return r$2(() => {
4378
4378
  if (i) return n2.registerUpdateListener(({ editorState: e2, dirtyElements: r2, dirtyLeaves: a2, prevEditorState: d2, tags: s2 }) => {
4379
4379
  o2 && 0 === r2.size && 0 === a2.size || t2 && s2.has("history-merge") || d2.isEmpty() || i(e2, n2, s2);
4380
4380
  });
4381
4381
  }, [n2, t2, o2, i]), null;
4382
4382
  }
4383
- const u$3 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement ? useLayoutEffect$1 : useEffect$2;
4384
- function c$2(e2) {
4383
+ const u$2 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement ? useLayoutEffect$1 : useEffect$2;
4384
+ function c$1(e2) {
4385
4385
  return { initialValueFn: () => e2.isEditable(), subscribe: (t2) => e2.registerEditableListener(t2) };
4386
4386
  }
4387
- function a$1() {
4387
+ function a() {
4388
4388
  return function(t2) {
4389
- const [n2] = u$6(), c2 = useMemo$1(() => t2(n2), [n2, t2]), a2 = useRef$1(c2.initialValueFn()), [l2, d2] = useState$1(a2.current);
4390
- return u$3(() => {
4389
+ const [n2] = u$5(), c2 = useMemo$1(() => t2(n2), [n2, t2]), a2 = useRef$1(c2.initialValueFn()), [l2, d2] = useState$1(a2.current);
4390
+ return u$2(() => {
4391
4391
  const { initialValueFn: e2, subscribe: t3 } = c2, n3 = e2();
4392
4392
  return a2.current !== n3 && (a2.current = n3, d2(n3)), t3((e3) => {
4393
4393
  a2.current = e3, d2(e3);
4394
4394
  });
4395
4395
  }, [c2, t2]), l2;
4396
- }(c$2);
4396
+ }(c$1);
4397
4397
  }
4398
4398
  var reactDom = { exports: {} };
4399
4399
  var reactDom_production_min = {};
@@ -4651,7 +4651,7 @@ var schedulerExports = scheduler.exports;
4651
4651
  * LICENSE file in the root directory of this source tree.
4652
4652
  */
4653
4653
  var aa = React__default, ca = schedulerExports;
4654
- function p$4(a2) {
4654
+ function p$3(a2) {
4655
4655
  for (var b2 = "https://reactjs.org/docs/error-decoder.html?invariant=" + a2, c2 = 1; c2 < arguments.length; c2++) b2 += "&args[]=" + encodeURIComponent(arguments[c2]);
4656
4656
  return "Minified React error #" + a2 + "; visit " + b2 + " for the full message or use the non-minified dev environment for full errors and additional helpful warnings.";
4657
4657
  }
@@ -4702,7 +4702,7 @@ function qa(a2, b2, c2, d2) {
4702
4702
  }
4703
4703
  return false;
4704
4704
  }
4705
- function v$3(a2, b2, c2, d2, e2, f2, g2) {
4705
+ function v$2(a2, b2, c2, d2, e2, f2, g2) {
4706
4706
  this.acceptsBooleans = 2 === b2 || 3 === b2 || 4 === b2;
4707
4707
  this.attributeName = d2;
4708
4708
  this.attributeNamespace = e2;
@@ -4714,32 +4714,32 @@ function v$3(a2, b2, c2, d2, e2, f2, g2) {
4714
4714
  }
4715
4715
  var z = {};
4716
4716
  "children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(a2) {
4717
- z[a2] = new v$3(a2, 0, false, a2, null, false, false);
4717
+ z[a2] = new v$2(a2, 0, false, a2, null, false, false);
4718
4718
  });
4719
4719
  [["acceptCharset", "accept-charset"], ["className", "class"], ["htmlFor", "for"], ["httpEquiv", "http-equiv"]].forEach(function(a2) {
4720
4720
  var b2 = a2[0];
4721
- z[b2] = new v$3(b2, 1, false, a2[1], null, false, false);
4721
+ z[b2] = new v$2(b2, 1, false, a2[1], null, false, false);
4722
4722
  });
4723
4723
  ["contentEditable", "draggable", "spellCheck", "value"].forEach(function(a2) {
4724
- z[a2] = new v$3(a2, 2, false, a2.toLowerCase(), null, false, false);
4724
+ z[a2] = new v$2(a2, 2, false, a2.toLowerCase(), null, false, false);
4725
4725
  });
4726
4726
  ["autoReverse", "externalResourcesRequired", "focusable", "preserveAlpha"].forEach(function(a2) {
4727
- z[a2] = new v$3(a2, 2, false, a2, null, false, false);
4727
+ z[a2] = new v$2(a2, 2, false, a2, null, false, false);
4728
4728
  });
4729
4729
  "allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(a2) {
4730
- z[a2] = new v$3(a2, 3, false, a2.toLowerCase(), null, false, false);
4730
+ z[a2] = new v$2(a2, 3, false, a2.toLowerCase(), null, false, false);
4731
4731
  });
4732
4732
  ["checked", "multiple", "muted", "selected"].forEach(function(a2) {
4733
- z[a2] = new v$3(a2, 3, true, a2, null, false, false);
4733
+ z[a2] = new v$2(a2, 3, true, a2, null, false, false);
4734
4734
  });
4735
4735
  ["capture", "download"].forEach(function(a2) {
4736
- z[a2] = new v$3(a2, 4, false, a2, null, false, false);
4736
+ z[a2] = new v$2(a2, 4, false, a2, null, false, false);
4737
4737
  });
4738
4738
  ["cols", "rows", "size", "span"].forEach(function(a2) {
4739
- z[a2] = new v$3(a2, 6, false, a2, null, false, false);
4739
+ z[a2] = new v$2(a2, 6, false, a2, null, false, false);
4740
4740
  });
4741
4741
  ["rowSpan", "start"].forEach(function(a2) {
4742
- z[a2] = new v$3(a2, 5, false, a2.toLowerCase(), null, false, false);
4742
+ z[a2] = new v$2(a2, 5, false, a2.toLowerCase(), null, false, false);
4743
4743
  });
4744
4744
  var ra = /[\-:]([a-z])/g;
4745
4745
  function sa(a2) {
@@ -4750,22 +4750,22 @@ function sa(a2) {
4750
4750
  ra,
4751
4751
  sa
4752
4752
  );
4753
- z[b2] = new v$3(b2, 1, false, a2, null, false, false);
4753
+ z[b2] = new v$2(b2, 1, false, a2, null, false, false);
4754
4754
  });
4755
4755
  "xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(a2) {
4756
4756
  var b2 = a2.replace(ra, sa);
4757
- z[b2] = new v$3(b2, 1, false, a2, "http://www.w3.org/1999/xlink", false, false);
4757
+ z[b2] = new v$2(b2, 1, false, a2, "http://www.w3.org/1999/xlink", false, false);
4758
4758
  });
4759
4759
  ["xml:base", "xml:lang", "xml:space"].forEach(function(a2) {
4760
4760
  var b2 = a2.replace(ra, sa);
4761
- z[b2] = new v$3(b2, 1, false, a2, "http://www.w3.org/XML/1998/namespace", false, false);
4761
+ z[b2] = new v$2(b2, 1, false, a2, "http://www.w3.org/XML/1998/namespace", false, false);
4762
4762
  });
4763
4763
  ["tabIndex", "crossOrigin"].forEach(function(a2) {
4764
- z[a2] = new v$3(a2, 1, false, a2.toLowerCase(), null, false, false);
4764
+ z[a2] = new v$2(a2, 1, false, a2.toLowerCase(), null, false, false);
4765
4765
  });
4766
- z.xlinkHref = new v$3("xlinkHref", 1, false, "xlink:href", "http://www.w3.org/1999/xlink", true, false);
4766
+ z.xlinkHref = new v$2("xlinkHref", 1, false, "xlink:href", "http://www.w3.org/1999/xlink", true, false);
4767
4767
  ["src", "href", "action", "formAction"].forEach(function(a2) {
4768
- z[a2] = new v$3(a2, 1, false, a2.toLowerCase(), null, true, true);
4768
+ z[a2] = new v$2(a2, 1, false, a2.toLowerCase(), null, true, true);
4769
4769
  });
4770
4770
  function ta(a2, b2, c2, d2) {
4771
4771
  var e2 = z.hasOwnProperty(b2) ? z[b2] : null;
@@ -5080,7 +5080,7 @@ function fb(a2, b2, c2, d2) {
5080
5080
  }
5081
5081
  }
5082
5082
  function gb(a2, b2) {
5083
- if (null != b2.dangerouslySetInnerHTML) throw Error(p$4(91));
5083
+ if (null != b2.dangerouslySetInnerHTML) throw Error(p$3(91));
5084
5084
  return A$1({}, b2, { value: void 0, defaultValue: void 0, children: "" + a2._wrapperState.initialValue });
5085
5085
  }
5086
5086
  function hb(a2, b2) {
@@ -5089,9 +5089,9 @@ function hb(a2, b2) {
5089
5089
  c2 = b2.children;
5090
5090
  b2 = b2.defaultValue;
5091
5091
  if (null != c2) {
5092
- if (null != b2) throw Error(p$4(92));
5092
+ if (null != b2) throw Error(p$3(92));
5093
5093
  if (eb(c2)) {
5094
- if (1 < c2.length) throw Error(p$4(93));
5094
+ if (1 < c2.length) throw Error(p$3(93));
5095
5095
  c2 = c2[0];
5096
5096
  }
5097
5097
  b2 = c2;
@@ -5213,12 +5213,12 @@ function sb(a2, b2) {
5213
5213
  var tb = A$1({ menuitem: true }, { area: true, base: true, br: true, col: true, embed: true, hr: true, img: true, input: true, keygen: true, link: true, meta: true, param: true, source: true, track: true, wbr: true });
5214
5214
  function ub(a2, b2) {
5215
5215
  if (b2) {
5216
- if (tb[a2] && (null != b2.children || null != b2.dangerouslySetInnerHTML)) throw Error(p$4(137, a2));
5216
+ if (tb[a2] && (null != b2.children || null != b2.dangerouslySetInnerHTML)) throw Error(p$3(137, a2));
5217
5217
  if (null != b2.dangerouslySetInnerHTML) {
5218
- if (null != b2.children) throw Error(p$4(60));
5219
- if ("object" !== typeof b2.dangerouslySetInnerHTML || !("__html" in b2.dangerouslySetInnerHTML)) throw Error(p$4(61));
5218
+ if (null != b2.children) throw Error(p$3(60));
5219
+ if ("object" !== typeof b2.dangerouslySetInnerHTML || !("__html" in b2.dangerouslySetInnerHTML)) throw Error(p$3(61));
5220
5220
  }
5221
- if (null != b2.style && "object" !== typeof b2.style) throw Error(p$4(62));
5221
+ if (null != b2.style && "object" !== typeof b2.style) throw Error(p$3(62));
5222
5222
  }
5223
5223
  }
5224
5224
  function vb(a2, b2) {
@@ -5246,7 +5246,7 @@ function xb(a2) {
5246
5246
  var yb = null, zb = null, Ab = null;
5247
5247
  function Bb(a2) {
5248
5248
  if (a2 = Cb(a2)) {
5249
- if ("function" !== typeof yb) throw Error(p$4(280));
5249
+ if ("function" !== typeof yb) throw Error(p$3(280));
5250
5250
  var b2 = a2.stateNode;
5251
5251
  b2 && (b2 = Db(b2), yb(a2.stateNode, a2.type, b2));
5252
5252
  }
@@ -5302,7 +5302,7 @@ function Kb(a2, b2) {
5302
5302
  a2 = false;
5303
5303
  }
5304
5304
  if (a2) return null;
5305
- if (c2 && "function" !== typeof c2) throw Error(p$4(231, b2, typeof c2));
5305
+ if (c2 && "function" !== typeof c2) throw Error(p$3(231, b2, typeof c2));
5306
5306
  return c2;
5307
5307
  }
5308
5308
  var Lb = false;
@@ -5340,7 +5340,7 @@ function Ub(a2, b2, c2, d2, e2, f2, g2, h2, k2) {
5340
5340
  var l2 = Pb;
5341
5341
  Ob = false;
5342
5342
  Pb = null;
5343
- } else throw Error(p$4(198));
5343
+ } else throw Error(p$3(198));
5344
5344
  Qb || (Qb = true, Rb = l2);
5345
5345
  }
5346
5346
  }
@@ -5364,13 +5364,13 @@ function Wb(a2) {
5364
5364
  return null;
5365
5365
  }
5366
5366
  function Xb(a2) {
5367
- if (Vb(a2) !== a2) throw Error(p$4(188));
5367
+ if (Vb(a2) !== a2) throw Error(p$3(188));
5368
5368
  }
5369
5369
  function Yb(a2) {
5370
5370
  var b2 = a2.alternate;
5371
5371
  if (!b2) {
5372
5372
  b2 = Vb(a2);
5373
- if (null === b2) throw Error(p$4(188));
5373
+ if (null === b2) throw Error(p$3(188));
5374
5374
  return b2 !== a2 ? null : a2;
5375
5375
  }
5376
5376
  for (var c2 = a2, d2 = b2; ; ) {
@@ -5391,7 +5391,7 @@ function Yb(a2) {
5391
5391
  if (f2 === d2) return Xb(e2), b2;
5392
5392
  f2 = f2.sibling;
5393
5393
  }
5394
- throw Error(p$4(188));
5394
+ throw Error(p$3(188));
5395
5395
  }
5396
5396
  if (c2.return !== d2.return) c2 = e2, d2 = f2;
5397
5397
  else {
@@ -5426,12 +5426,12 @@ function Yb(a2) {
5426
5426
  }
5427
5427
  h2 = h2.sibling;
5428
5428
  }
5429
- if (!g2) throw Error(p$4(189));
5429
+ if (!g2) throw Error(p$3(189));
5430
5430
  }
5431
5431
  }
5432
- if (c2.alternate !== d2) throw Error(p$4(190));
5432
+ if (c2.alternate !== d2) throw Error(p$3(190));
5433
5433
  }
5434
- if (3 !== c2.tag) throw Error(p$4(188));
5434
+ if (3 !== c2.tag) throw Error(p$3(188));
5435
5435
  return c2.stateNode.current === c2 ? a2 : b2;
5436
5436
  }
5437
5437
  function Zb(a2) {
@@ -6602,7 +6602,7 @@ function zf(a2) {
6602
6602
  }
6603
6603
  function Af(a2, b2, c2) {
6604
6604
  b2 = zf(b2);
6605
- if (zf(a2) !== b2 && c2) throw Error(p$4(425));
6605
+ if (zf(a2) !== b2 && c2) throw Error(p$3(425));
6606
6606
  }
6607
6607
  function Bf() {
6608
6608
  }
@@ -6685,7 +6685,7 @@ function Cb(a2) {
6685
6685
  }
6686
6686
  function ue$1(a2) {
6687
6687
  if (5 === a2.tag || 6 === a2.tag) return a2.stateNode;
6688
- throw Error(p$4(33));
6688
+ throw Error(p$3(33));
6689
6689
  }
6690
6690
  function Db(a2) {
6691
6691
  return a2[Pf] || null;
@@ -6722,7 +6722,7 @@ function $f() {
6722
6722
  E$3(H$1);
6723
6723
  }
6724
6724
  function ag(a2, b2, c2) {
6725
- if (H$1.current !== Vf) throw Error(p$4(168));
6725
+ if (H$1.current !== Vf) throw Error(p$3(168));
6726
6726
  G$2(H$1, b2);
6727
6727
  G$2(Wf, c2);
6728
6728
  }
@@ -6731,7 +6731,7 @@ function bg(a2, b2, c2) {
6731
6731
  b2 = b2.childContextTypes;
6732
6732
  if ("function" !== typeof d2.getChildContext) return c2;
6733
6733
  d2 = d2.getChildContext();
6734
- for (var e2 in d2) if (!(e2 in b2)) throw Error(p$4(108, Ra(a2) || "Unknown", e2));
6734
+ for (var e2 in d2) if (!(e2 in b2)) throw Error(p$3(108, Ra(a2) || "Unknown", e2));
6735
6735
  return A$1({}, c2, d2);
6736
6736
  }
6737
6737
  function cg(a2) {
@@ -6743,7 +6743,7 @@ function cg(a2) {
6743
6743
  }
6744
6744
  function dg(a2, b2, c2) {
6745
6745
  var d2 = a2.stateNode;
6746
- if (!d2) throw Error(p$4(169));
6746
+ if (!d2) throw Error(p$3(169));
6747
6747
  c2 ? (a2 = bg(a2, b2, Xf), d2.__reactInternalMemoizedMergedChildContext = a2, E$3(Wf), E$3(H$1), G$2(H$1, a2)) : E$3(Wf);
6748
6748
  G$2(Wf, c2);
6749
6749
  }
@@ -6843,13 +6843,13 @@ function Eg(a2) {
6843
6843
  if (b2) {
6844
6844
  var c2 = b2;
6845
6845
  if (!Cg(a2, b2)) {
6846
- if (Dg(a2)) throw Error(p$4(418));
6846
+ if (Dg(a2)) throw Error(p$3(418));
6847
6847
  b2 = Lf(c2.nextSibling);
6848
6848
  var d2 = xg;
6849
6849
  b2 && Cg(a2, b2) ? Ag(d2, c2) : (a2.flags = a2.flags & -4097 | 2, I = false, xg = a2);
6850
6850
  }
6851
6851
  } else {
6852
- if (Dg(a2)) throw Error(p$4(418));
6852
+ if (Dg(a2)) throw Error(p$3(418));
6853
6853
  a2.flags = a2.flags & -4097 | 2;
6854
6854
  I = false;
6855
6855
  xg = a2;
@@ -6866,14 +6866,14 @@ function Gg(a2) {
6866
6866
  var b2;
6867
6867
  (b2 = 3 !== a2.tag) && !(b2 = 5 !== a2.tag) && (b2 = a2.type, b2 = "head" !== b2 && "body" !== b2 && !Ef(a2.type, a2.memoizedProps));
6868
6868
  if (b2 && (b2 = yg)) {
6869
- if (Dg(a2)) throw Hg(), Error(p$4(418));
6869
+ if (Dg(a2)) throw Hg(), Error(p$3(418));
6870
6870
  for (; b2; ) Ag(a2, b2), b2 = Lf(b2.nextSibling);
6871
6871
  }
6872
6872
  Fg(a2);
6873
6873
  if (13 === a2.tag) {
6874
6874
  a2 = a2.memoizedState;
6875
6875
  a2 = null !== a2 ? a2.dehydrated : null;
6876
- if (!a2) throw Error(p$4(317));
6876
+ if (!a2) throw Error(p$3(317));
6877
6877
  a: {
6878
6878
  a2 = a2.nextSibling;
6879
6879
  for (b2 = 0; a2; ) {
@@ -6940,7 +6940,7 @@ function Tg(a2, b2) {
6940
6940
  function Vg(a2) {
6941
6941
  var b2 = a2._currentValue;
6942
6942
  if (Pg !== a2) if (a2 = { context: a2, memoizedValue: b2, next: null }, null === Og) {
6943
- if (null === Ng) throw Error(p$4(308));
6943
+ if (null === Ng) throw Error(p$3(308));
6944
6944
  Og = a2;
6945
6945
  Ng.dependencies = { lanes: 0, firstContext: a2 };
6946
6946
  } else Og = Og.next = a2;
@@ -7105,7 +7105,7 @@ function ih(a2, b2, c2) {
7105
7105
  if (null !== e2) {
7106
7106
  d2.callback = null;
7107
7107
  d2 = c2;
7108
- if ("function" !== typeof e2) throw Error(p$4(191, e2));
7108
+ if ("function" !== typeof e2) throw Error(p$3(191, e2));
7109
7109
  e2.call(d2);
7110
7110
  }
7111
7111
  }
@@ -7185,10 +7185,10 @@ function sh(a2, b2, c2) {
7185
7185
  if (c2._owner) {
7186
7186
  c2 = c2._owner;
7187
7187
  if (c2) {
7188
- if (1 !== c2.tag) throw Error(p$4(309));
7188
+ if (1 !== c2.tag) throw Error(p$3(309));
7189
7189
  var d2 = c2.stateNode;
7190
7190
  }
7191
- if (!d2) throw Error(p$4(147, a2));
7191
+ if (!d2) throw Error(p$3(147, a2));
7192
7192
  var e2 = d2, f2 = "" + a2;
7193
7193
  if (null !== b2 && null !== b2.ref && "function" === typeof b2.ref && b2.ref._stringRef === f2) return b2.ref;
7194
7194
  b2 = function(a3) {
@@ -7199,14 +7199,14 @@ function sh(a2, b2, c2) {
7199
7199
  b2._stringRef = f2;
7200
7200
  return b2;
7201
7201
  }
7202
- if ("string" !== typeof a2) throw Error(p$4(284));
7203
- if (!c2._owner) throw Error(p$4(290, a2));
7202
+ if ("string" !== typeof a2) throw Error(p$3(284));
7203
+ if (!c2._owner) throw Error(p$3(290, a2));
7204
7204
  }
7205
7205
  return a2;
7206
7206
  }
7207
7207
  function th(a2, b2) {
7208
7208
  a2 = Object.prototype.toString.call(b2);
7209
- throw Error(p$4(31, "[object Object]" === a2 ? "object with keys {" + Object.keys(b2).join(", ") + "}" : a2));
7209
+ throw Error(p$3(31, "[object Object]" === a2 ? "object with keys {" + Object.keys(b2).join(", ") + "}" : a2));
7210
7210
  }
7211
7211
  function uh(a2) {
7212
7212
  var b2 = a2._init;
@@ -7358,9 +7358,9 @@ function vh$1(a2) {
7358
7358
  }
7359
7359
  function t2(e3, g3, h3, k3) {
7360
7360
  var l3 = Ka(h3);
7361
- if ("function" !== typeof l3) throw Error(p$4(150));
7361
+ if ("function" !== typeof l3) throw Error(p$3(150));
7362
7362
  h3 = l3.call(h3);
7363
- if (null == h3) throw Error(p$4(151));
7363
+ if (null == h3) throw Error(p$3(151));
7364
7364
  for (var u2 = l3 = null, m3 = g3, w2 = g3 = 0, x2 = null, n3 = h3.next(); null !== m3 && !n3.done; w2++, n3 = h3.next()) {
7365
7365
  m3.index > w2 ? (x2 = m3, m3 = null) : x2 = m3.sibling;
7366
7366
  var t3 = r2(e3, m3, n3.value, k3);
@@ -7457,7 +7457,7 @@ function vh$1(a2) {
7457
7457
  }
7458
7458
  var Bh = vh$1(true), Ch = vh$1(false), Dh = {}, Eh = Uf(Dh), Fh = Uf(Dh), Gh = Uf(Dh);
7459
7459
  function Hh(a2) {
7460
- if (a2 === Dh) throw Error(p$4(174));
7460
+ if (a2 === Dh) throw Error(p$3(174));
7461
7461
  return a2;
7462
7462
  }
7463
7463
  function Ih(a2, b2) {
@@ -7518,9 +7518,9 @@ function Oh() {
7518
7518
  for (var a2 = 0; a2 < Nh.length; a2++) Nh[a2]._workInProgressVersionPrimary = null;
7519
7519
  Nh.length = 0;
7520
7520
  }
7521
- var Ph = ua.ReactCurrentDispatcher, Qh = ua.ReactCurrentBatchConfig, Rh = 0, N$1 = null, O$1 = null, P$2 = null, Sh = false, Th = false, Uh = 0, Vh = 0;
7521
+ var Ph = ua.ReactCurrentDispatcher, Qh = ua.ReactCurrentBatchConfig, Rh = 0, N$1 = null, O$1 = null, P$1 = null, Sh = false, Th = false, Uh = 0, Vh = 0;
7522
7522
  function Q$1() {
7523
- throw Error(p$4(321));
7523
+ throw Error(p$3(321));
7524
7524
  }
7525
7525
  function Wh(a2, b2) {
7526
7526
  if (null === b2) return false;
@@ -7540,9 +7540,9 @@ function Xh(a2, b2, c2, d2, e2, f2) {
7540
7540
  do {
7541
7541
  Th = false;
7542
7542
  Uh = 0;
7543
- if (25 <= f2) throw Error(p$4(301));
7543
+ if (25 <= f2) throw Error(p$3(301));
7544
7544
  f2 += 1;
7545
- P$2 = O$1 = null;
7545
+ P$1 = O$1 = null;
7546
7546
  b2.updateQueue = null;
7547
7547
  Ph.current = $h;
7548
7548
  a2 = c2(d2, e2);
@@ -7551,9 +7551,9 @@ function Xh(a2, b2, c2, d2, e2, f2) {
7551
7551
  Ph.current = ai2;
7552
7552
  b2 = null !== O$1 && null !== O$1.next;
7553
7553
  Rh = 0;
7554
- P$2 = O$1 = N$1 = null;
7554
+ P$1 = O$1 = N$1 = null;
7555
7555
  Sh = false;
7556
- if (b2) throw Error(p$4(300));
7556
+ if (b2) throw Error(p$3(300));
7557
7557
  return a2;
7558
7558
  }
7559
7559
  function bi() {
@@ -7563,30 +7563,30 @@ function bi() {
7563
7563
  }
7564
7564
  function ci() {
7565
7565
  var a2 = { memoizedState: null, baseState: null, baseQueue: null, queue: null, next: null };
7566
- null === P$2 ? N$1.memoizedState = P$2 = a2 : P$2 = P$2.next = a2;
7567
- return P$2;
7566
+ null === P$1 ? N$1.memoizedState = P$1 = a2 : P$1 = P$1.next = a2;
7567
+ return P$1;
7568
7568
  }
7569
7569
  function di() {
7570
7570
  if (null === O$1) {
7571
7571
  var a2 = N$1.alternate;
7572
7572
  a2 = null !== a2 ? a2.memoizedState : null;
7573
7573
  } else a2 = O$1.next;
7574
- var b2 = null === P$2 ? N$1.memoizedState : P$2.next;
7575
- if (null !== b2) P$2 = b2, O$1 = a2;
7574
+ var b2 = null === P$1 ? N$1.memoizedState : P$1.next;
7575
+ if (null !== b2) P$1 = b2, O$1 = a2;
7576
7576
  else {
7577
- if (null === a2) throw Error(p$4(310));
7577
+ if (null === a2) throw Error(p$3(310));
7578
7578
  O$1 = a2;
7579
7579
  a2 = { memoizedState: O$1.memoizedState, baseState: O$1.baseState, baseQueue: O$1.baseQueue, queue: O$1.queue, next: null };
7580
- null === P$2 ? N$1.memoizedState = P$2 = a2 : P$2 = P$2.next = a2;
7580
+ null === P$1 ? N$1.memoizedState = P$1 = a2 : P$1 = P$1.next = a2;
7581
7581
  }
7582
- return P$2;
7582
+ return P$1;
7583
7583
  }
7584
7584
  function ei(a2, b2) {
7585
7585
  return "function" === typeof b2 ? b2(a2) : b2;
7586
7586
  }
7587
7587
  function fi(a2) {
7588
7588
  var b2 = di(), c2 = b2.queue;
7589
- if (null === c2) throw Error(p$4(311));
7589
+ if (null === c2) throw Error(p$3(311));
7590
7590
  c2.lastRenderedReducer = a2;
7591
7591
  var d2 = O$1, e2 = d2.baseQueue, f2 = c2.pending;
7592
7592
  if (null !== f2) {
@@ -7637,7 +7637,7 @@ function fi(a2) {
7637
7637
  }
7638
7638
  function gi2(a2) {
7639
7639
  var b2 = di(), c2 = b2.queue;
7640
- if (null === c2) throw Error(p$4(311));
7640
+ if (null === c2) throw Error(p$3(311));
7641
7641
  c2.lastRenderedReducer = a2;
7642
7642
  var d2 = c2.dispatch, e2 = c2.pending, f2 = b2.memoizedState;
7643
7643
  if (null !== e2) {
@@ -7660,10 +7660,10 @@ function ii(a2, b2) {
7660
7660
  f2 && (d2.memoizedState = e2, Ug = true);
7661
7661
  d2 = d2.queue;
7662
7662
  ji(ki.bind(null, c2, d2, a2), [a2]);
7663
- if (d2.getSnapshot !== b2 || f2 || null !== P$2 && P$2.memoizedState.tag & 1) {
7663
+ if (d2.getSnapshot !== b2 || f2 || null !== P$1 && P$1.memoizedState.tag & 1) {
7664
7664
  c2.flags |= 2048;
7665
7665
  li(9, mi.bind(null, c2, d2, e2, b2), void 0, null);
7666
- if (null === R$2) throw Error(p$4(349));
7666
+ if (null === R$2) throw Error(p$3(349));
7667
7667
  0 !== (Rh & 30) || ni(c2, b2, e2);
7668
7668
  }
7669
7669
  return e2;
@@ -7894,11 +7894,11 @@ var ai2 = { readContext: Vg, useCallback: Q$1, useContext: Q$1, useEffect: Q$1,
7894
7894
  }, useSyncExternalStore: function(a2, b2, c2) {
7895
7895
  var d2 = N$1, e2 = ci();
7896
7896
  if (I) {
7897
- if (void 0 === c2) throw Error(p$4(407));
7897
+ if (void 0 === c2) throw Error(p$3(407));
7898
7898
  c2 = c2();
7899
7899
  } else {
7900
7900
  c2 = b2();
7901
- if (null === R$2) throw Error(p$4(349));
7901
+ if (null === R$2) throw Error(p$3(349));
7902
7902
  0 !== (Rh & 30) || ni(d2, b2, c2);
7903
7903
  }
7904
7904
  e2.memoizedState = c2;
@@ -8252,7 +8252,7 @@ function tj(a2, b2, c2, d2) {
8252
8252
  }
8253
8253
  function sj(a2, b2, c2, d2, e2, f2, g2) {
8254
8254
  if (c2) {
8255
- if (b2.flags & 256) return b2.flags &= -257, d2 = Li(Error(p$4(422))), tj(a2, b2, g2, d2);
8255
+ if (b2.flags & 256) return b2.flags &= -257, d2 = Li(Error(p$3(422))), tj(a2, b2, g2, d2);
8256
8256
  if (null !== b2.memoizedState) return b2.child = a2.child, b2.flags |= 128, null;
8257
8257
  f2 = d2.fallback;
8258
8258
  e2 = b2.mode;
@@ -8273,7 +8273,7 @@ function sj(a2, b2, c2, d2, e2, f2, g2) {
8273
8273
  d2 = e2.nextSibling && e2.nextSibling.dataset;
8274
8274
  if (d2) var h2 = d2.dgst;
8275
8275
  d2 = h2;
8276
- f2 = Error(p$4(419));
8276
+ f2 = Error(p$3(419));
8277
8277
  d2 = Li(f2, d2, void 0);
8278
8278
  return tj(a2, b2, g2, d2);
8279
8279
  }
@@ -8321,7 +8321,7 @@ function sj(a2, b2, c2, d2, e2, f2, g2) {
8321
8321
  0 !== e2 && e2 !== f2.retryLane && (f2.retryLane = e2, Zg(a2, e2), mh(d2, a2, e2, -1));
8322
8322
  }
8323
8323
  uj();
8324
- d2 = Li(Error(p$4(421)));
8324
+ d2 = Li(Error(p$3(421)));
8325
8325
  return tj(a2, b2, g2, d2);
8326
8326
  }
8327
8327
  if ("$?" === e2.data) return b2.flags |= 128, b2.child = a2.child, b2 = vj.bind(null, a2), e2._reactRetry = b2, null;
@@ -8410,7 +8410,7 @@ function $i(a2, b2, c2) {
8410
8410
  null !== a2 && (b2.dependencies = a2.dependencies);
8411
8411
  hh |= b2.lanes;
8412
8412
  if (0 === (c2 & b2.childLanes)) return null;
8413
- if (null !== a2 && b2.child !== a2.child) throw Error(p$4(153));
8413
+ if (null !== a2 && b2.child !== a2.child) throw Error(p$3(153));
8414
8414
  if (null !== b2.child) {
8415
8415
  a2 = b2.child;
8416
8416
  c2 = wh(a2, a2.pendingProps);
@@ -8596,7 +8596,7 @@ function Fj(a2, b2, c2) {
8596
8596
  if (null !== a2 && null != b2.stateNode) Cj(a2, b2, c2, d2, e2), a2.ref !== b2.ref && (b2.flags |= 512, b2.flags |= 2097152);
8597
8597
  else {
8598
8598
  if (!d2) {
8599
- if (null === b2.stateNode) throw Error(p$4(166));
8599
+ if (null === b2.stateNode) throw Error(p$3(166));
8600
8600
  S$2(b2);
8601
8601
  return null;
8602
8602
  }
@@ -8796,7 +8796,7 @@ function Fj(a2, b2, c2) {
8796
8796
  case 6:
8797
8797
  if (a2 && null != b2.stateNode) Dj(a2, b2, a2.memoizedProps, d2);
8798
8798
  else {
8799
- if ("string" !== typeof d2 && null === b2.stateNode) throw Error(p$4(166));
8799
+ if ("string" !== typeof d2 && null === b2.stateNode) throw Error(p$3(166));
8800
8800
  c2 = Hh(Gh.current);
8801
8801
  Hh(Eh.current);
8802
8802
  if (Gg(b2)) {
@@ -8824,10 +8824,10 @@ function Fj(a2, b2, c2) {
8824
8824
  if (I && null !== yg && 0 !== (b2.mode & 1) && 0 === (b2.flags & 128)) Hg(), Ig(), b2.flags |= 98560, f2 = false;
8825
8825
  else if (f2 = Gg(b2), null !== d2 && null !== d2.dehydrated) {
8826
8826
  if (null === a2) {
8827
- if (!f2) throw Error(p$4(318));
8827
+ if (!f2) throw Error(p$3(318));
8828
8828
  f2 = b2.memoizedState;
8829
8829
  f2 = null !== f2 ? f2.dehydrated : null;
8830
- if (!f2) throw Error(p$4(317));
8830
+ if (!f2) throw Error(p$3(317));
8831
8831
  f2[Of] = b2;
8832
8832
  } else Ig(), 0 === (b2.flags & 128) && (b2.memoizedState = null), b2.flags |= 4;
8833
8833
  S$2(b2);
@@ -8889,7 +8889,7 @@ function Fj(a2, b2, c2) {
8889
8889
  case 25:
8890
8890
  return null;
8891
8891
  }
8892
- throw Error(p$4(156, b2.tag));
8892
+ throw Error(p$3(156, b2.tag));
8893
8893
  }
8894
8894
  function Jj(a2, b2) {
8895
8895
  wg(b2);
@@ -8904,7 +8904,7 @@ function Jj(a2, b2) {
8904
8904
  E$3(M$1);
8905
8905
  a2 = b2.memoizedState;
8906
8906
  if (null !== a2 && null !== a2.dehydrated) {
8907
- if (null === b2.alternate) throw Error(p$4(340));
8907
+ if (null === b2.alternate) throw Error(p$3(340));
8908
8908
  Ig();
8909
8909
  }
8910
8910
  a2 = b2.flags;
@@ -9013,7 +9013,7 @@ function Pj(a2, b2) {
9013
9013
  case 17:
9014
9014
  break;
9015
9015
  default:
9016
- throw Error(p$4(163));
9016
+ throw Error(p$3(163));
9017
9017
  }
9018
9018
  } catch (F2) {
9019
9019
  W$1(b2, b2.return, F2);
@@ -9217,7 +9217,7 @@ function dk(a2, b2) {
9217
9217
  }
9218
9218
  h2 = h2.return;
9219
9219
  }
9220
- if (null === X$3) throw Error(p$4(160));
9220
+ if (null === X$3) throw Error(p$3(160));
9221
9221
  ak(f2, g2, e2);
9222
9222
  X$3 = null;
9223
9223
  Yj = false;
@@ -9308,7 +9308,7 @@ function ek(a2, b2) {
9308
9308
  dk(b2, a2);
9309
9309
  fk(a2);
9310
9310
  if (d2 & 4) {
9311
- if (null === a2.stateNode) throw Error(p$4(162));
9311
+ if (null === a2.stateNode) throw Error(p$3(162));
9312
9312
  e2 = a2.stateNode;
9313
9313
  f2 = a2.memoizedProps;
9314
9314
  try {
@@ -9440,7 +9440,7 @@ function fk(a2) {
9440
9440
  }
9441
9441
  c2 = c2.return;
9442
9442
  }
9443
- throw Error(p$4(160));
9443
+ throw Error(p$3(160));
9444
9444
  }
9445
9445
  switch (d2.tag) {
9446
9446
  case 5:
@@ -9455,7 +9455,7 @@ function fk(a2) {
9455
9455
  Wj(a2, h2, g2);
9456
9456
  break;
9457
9457
  default:
9458
- throw Error(p$4(161));
9458
+ throw Error(p$3(161));
9459
9459
  }
9460
9460
  } catch (k2) {
9461
9461
  W$1(a2, a2.return, k2);
@@ -9567,7 +9567,7 @@ function lk(a2) {
9567
9567
  case 25:
9568
9568
  break;
9569
9569
  default:
9570
- throw Error(p$4(163));
9570
+ throw Error(p$3(163));
9571
9571
  }
9572
9572
  U$1 || b2.flags & 512 && Sj(b2);
9573
9573
  } catch (r2) {
@@ -9674,7 +9674,7 @@ function lh(a2) {
9674
9674
  return a2;
9675
9675
  }
9676
9676
  function mh(a2, b2, c2, d2) {
9677
- if (50 < zk) throw zk = 0, Ak = null, Error(p$4(185));
9677
+ if (50 < zk) throw zk = 0, Ak = null, Error(p$3(185));
9678
9678
  Ac(a2, c2, d2);
9679
9679
  if (0 === (K$1 & 2) || a2 !== R$2) a2 === R$2 && (0 === (K$1 & 2) && (rk |= c2), 4 === T$2 && Dk(a2, Z$1)), Ek(a2, d2), 1 === c2 && 0 === K$1 && 0 === (b2.mode & 1) && (Hj = B$1() + 500, fg && jg());
9680
9680
  }
@@ -9714,7 +9714,7 @@ function Ek(a2, b2) {
9714
9714
  function Hk(a2, b2) {
9715
9715
  Bk = -1;
9716
9716
  Ck = 0;
9717
- if (0 !== (K$1 & 6)) throw Error(p$4(327));
9717
+ if (0 !== (K$1 & 6)) throw Error(p$3(327));
9718
9718
  var c2 = a2.callbackNode;
9719
9719
  if (Ik() && a2.callbackNode !== c2) return null;
9720
9720
  var d2 = uc(a2, a2 === R$2 ? Z$1 : 0);
@@ -9751,7 +9751,7 @@ function Hk(a2, b2) {
9751
9751
  switch (b2) {
9752
9752
  case 0:
9753
9753
  case 1:
9754
- throw Error(p$4(345));
9754
+ throw Error(p$3(345));
9755
9755
  case 2:
9756
9756
  Qk(a2, uk, vk);
9757
9757
  break;
@@ -9794,7 +9794,7 @@ function Hk(a2, b2) {
9794
9794
  Qk(a2, uk, vk);
9795
9795
  break;
9796
9796
  default:
9797
- throw Error(p$4(329));
9797
+ throw Error(p$3(329));
9798
9798
  }
9799
9799
  }
9800
9800
  }
@@ -9851,7 +9851,7 @@ function Dk(a2, b2) {
9851
9851
  }
9852
9852
  }
9853
9853
  function Fk(a2) {
9854
- if (0 !== (K$1 & 6)) throw Error(p$4(327));
9854
+ if (0 !== (K$1 & 6)) throw Error(p$3(327));
9855
9855
  Ik();
9856
9856
  var b2 = uc(a2, 0);
9857
9857
  if (0 === (b2 & 1)) return Ek(a2, B$1()), null;
@@ -9861,7 +9861,7 @@ function Fk(a2) {
9861
9861
  0 !== d2 && (b2 = d2, c2 = Ok(a2, d2));
9862
9862
  }
9863
9863
  if (1 === c2) throw c2 = qk, Lk(a2, 0), Dk(a2, b2), Ek(a2, B$1()), c2;
9864
- if (6 === c2) throw Error(p$4(345));
9864
+ if (6 === c2) throw Error(p$3(345));
9865
9865
  a2.finishedWork = a2.current.alternate;
9866
9866
  a2.finishedLanes = b2;
9867
9867
  Qk(a2, uk, vk);
@@ -9969,7 +9969,7 @@ function Nk(a2, b2) {
9969
9969
  Sh = false;
9970
9970
  }
9971
9971
  Rh = 0;
9972
- P$2 = O$1 = N$1 = null;
9972
+ P$1 = O$1 = N$1 = null;
9973
9973
  Th = false;
9974
9974
  Uh = 0;
9975
9975
  ok$3.current = null;
@@ -10009,7 +10009,7 @@ function Nk(a2, b2) {
10009
10009
  uj();
10010
10010
  break a;
10011
10011
  }
10012
- k2 = Error(p$4(426));
10012
+ k2 = Error(p$3(426));
10013
10013
  }
10014
10014
  } else if (I && h2.mode & 1) {
10015
10015
  var J2 = Vi(g2);
@@ -10082,7 +10082,7 @@ function Jk(a2, b2) {
10082
10082
  Qg();
10083
10083
  K$1 = c2;
10084
10084
  nk.current = d2;
10085
- if (null !== Y$2) throw Error(p$4(261));
10085
+ if (null !== Y$2) throw Error(p$3(261));
10086
10086
  R$2 = null;
10087
10087
  Z$1 = 0;
10088
10088
  return T$2;
@@ -10145,13 +10145,13 @@ function Xk(a2, b2, c2, d2) {
10145
10145
  do
10146
10146
  Ik();
10147
10147
  while (null !== xk);
10148
- if (0 !== (K$1 & 6)) throw Error(p$4(327));
10148
+ if (0 !== (K$1 & 6)) throw Error(p$3(327));
10149
10149
  c2 = a2.finishedWork;
10150
10150
  var e2 = a2.finishedLanes;
10151
10151
  if (null === c2) return null;
10152
10152
  a2.finishedWork = null;
10153
10153
  a2.finishedLanes = 0;
10154
- if (c2 === a2.current) throw Error(p$4(177));
10154
+ if (c2 === a2.current) throw Error(p$3(177));
10155
10155
  a2.callbackNode = null;
10156
10156
  a2.callbackPriority = 0;
10157
10157
  var f2 = c2.lanes | c2.childLanes;
@@ -10206,7 +10206,7 @@ function Ik() {
10206
10206
  a2 = xk;
10207
10207
  xk = null;
10208
10208
  yk = 0;
10209
- if (0 !== (K$1 & 6)) throw Error(p$4(331));
10209
+ if (0 !== (K$1 & 6)) throw Error(p$3(331));
10210
10210
  var e2 = K$1;
10211
10211
  K$1 |= 4;
10212
10212
  for (V$1 = a2.current; null !== V$1; ) {
@@ -10379,7 +10379,7 @@ function ck(a2, b2) {
10379
10379
  d2 = a2.stateNode;
10380
10380
  break;
10381
10381
  default:
10382
- throw Error(p$4(314));
10382
+ throw Error(p$3(314));
10383
10383
  }
10384
10384
  null !== d2 && d2.delete(b2);
10385
10385
  Zk(a2, c2);
@@ -10429,7 +10429,7 @@ Wk = function(a2, b2, c2) {
10429
10429
  b2 = aj(null, b2, d2, Lg(d2.type, a2), c2);
10430
10430
  break a;
10431
10431
  }
10432
- throw Error(p$4(
10432
+ throw Error(p$3(
10433
10433
  306,
10434
10434
  d2,
10435
10435
  ""
@@ -10443,7 +10443,7 @@ Wk = function(a2, b2, c2) {
10443
10443
  case 3:
10444
10444
  a: {
10445
10445
  lj(b2);
10446
- if (null === a2) throw Error(p$4(387));
10446
+ if (null === a2) throw Error(p$3(387));
10447
10447
  d2 = b2.pendingProps;
10448
10448
  f2 = b2.memoizedState;
10449
10449
  e2 = f2.element;
@@ -10452,11 +10452,11 @@ Wk = function(a2, b2, c2) {
10452
10452
  var g2 = b2.memoizedState;
10453
10453
  d2 = g2.element;
10454
10454
  if (f2.isDehydrated) if (f2 = { element: d2, isDehydrated: false, cache: g2.cache, pendingSuspenseBoundaries: g2.pendingSuspenseBoundaries, transitions: g2.transitions }, b2.updateQueue.baseState = f2, b2.memoizedState = f2, b2.flags & 256) {
10455
- e2 = Ki(Error(p$4(423)), b2);
10455
+ e2 = Ki(Error(p$3(423)), b2);
10456
10456
  b2 = mj(a2, b2, d2, c2, e2);
10457
10457
  break a;
10458
10458
  } else if (d2 !== e2) {
10459
- e2 = Ki(Error(p$4(424)), b2);
10459
+ e2 = Ki(Error(p$3(424)), b2);
10460
10460
  b2 = mj(a2, b2, d2, c2, e2);
10461
10461
  break a;
10462
10462
  } else for (yg = Lf(b2.stateNode.containerInfo.firstChild), xg = b2, I = true, zg = null, c2 = Ch(b2, null, d2, c2), b2.child = c2; c2; ) c2.flags = c2.flags & -3 | 4096, c2 = c2.sibling;
@@ -10533,7 +10533,7 @@ Wk = function(a2, b2, c2) {
10533
10533
  } else if (10 === f2.tag) g2 = f2.type === b2.type ? null : f2.child;
10534
10534
  else if (18 === f2.tag) {
10535
10535
  g2 = f2.return;
10536
- if (null === g2) throw Error(p$4(341));
10536
+ if (null === g2) throw Error(p$3(341));
10537
10537
  g2.lanes |= c2;
10538
10538
  h2 = g2.alternate;
10539
10539
  null !== h2 && (h2.lanes |= c2);
@@ -10573,7 +10573,7 @@ Wk = function(a2, b2, c2) {
10573
10573
  case 22:
10574
10574
  return ej(a2, b2, c2);
10575
10575
  }
10576
- throw Error(p$4(156, b2.tag));
10576
+ throw Error(p$3(156, b2.tag));
10577
10577
  };
10578
10578
  function Gk(a2, b2) {
10579
10579
  return ac(a2, b2);
@@ -10664,7 +10664,7 @@ function yh(a2, b2, c2, d2, e2, f2) {
10664
10664
  d2 = null;
10665
10665
  break a;
10666
10666
  }
10667
- throw Error(p$4(130, null == a2 ? a2 : typeof a2, ""));
10667
+ throw Error(p$3(130, null == a2 ? a2 : typeof a2, ""));
10668
10668
  }
10669
10669
  b2 = Bg(g2, c2, b2, e2);
10670
10670
  b2.elementType = a2;
@@ -10728,7 +10728,7 @@ function el(a2) {
10728
10728
  if (!a2) return Vf;
10729
10729
  a2 = a2._reactInternals;
10730
10730
  a: {
10731
- if (Vb(a2) !== a2 || 1 !== a2.tag) throw Error(p$4(170));
10731
+ if (Vb(a2) !== a2 || 1 !== a2.tag) throw Error(p$3(170));
10732
10732
  var b2 = a2;
10733
10733
  do {
10734
10734
  switch (b2.tag) {
@@ -10743,7 +10743,7 @@ function el(a2) {
10743
10743
  }
10744
10744
  b2 = b2.return;
10745
10745
  } while (null !== b2);
10746
- throw Error(p$4(171));
10746
+ throw Error(p$3(171));
10747
10747
  }
10748
10748
  if (1 === a2.tag) {
10749
10749
  var c2 = a2.type;
@@ -10798,6 +10798,9 @@ function jl(a2, b2) {
10798
10798
  il(a2, b2);
10799
10799
  (a2 = a2.alternate) && il(a2, b2);
10800
10800
  }
10801
+ function kl() {
10802
+ return null;
10803
+ }
10801
10804
  var ll = "function" === typeof reportError ? reportError : function(a2) {
10802
10805
  console.error(a2);
10803
10806
  };
@@ -10806,7 +10809,7 @@ function ml(a2) {
10806
10809
  }
10807
10810
  nl.prototype.render = ml.prototype.render = function(a2) {
10808
10811
  var b2 = this._internalRoot;
10809
- if (null === b2) throw Error(p$4(409));
10812
+ if (null === b2) throw Error(p$3(409));
10810
10813
  gl(a2, b2, null, null);
10811
10814
  };
10812
10815
  nl.prototype.unmount = ml.prototype.unmount = function() {
@@ -10950,7 +10953,7 @@ yb = function(a2, b2, c2) {
10950
10953
  var d2 = c2[b2];
10951
10954
  if (d2 !== a2 && d2.form === a2.form) {
10952
10955
  var e2 = Db(d2);
10953
- if (!e2) throw Error(p$4(90));
10956
+ if (!e2) throw Error(p$3(90));
10954
10957
  Wa(d2);
10955
10958
  bb(d2, e2);
10956
10959
  }
@@ -10970,7 +10973,7 @@ var tl = { usingClientEntryPoint: false, Events: [Cb, ue$1, Db, Eb, Fb, Rk] }, u
10970
10973
  var vl = { bundleType: ul.bundleType, version: ul.version, rendererPackageName: ul.rendererPackageName, rendererConfig: ul.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, overrideProps: null, overridePropsDeletePath: null, overridePropsRenamePath: null, setErrorHandler: null, setSuspenseHandler: null, scheduleUpdate: null, currentDispatcherRef: ua.ReactCurrentDispatcher, findHostInstanceByFiber: function(a2) {
10971
10974
  a2 = Zb(a2);
10972
10975
  return null === a2 ? null : a2.stateNode;
10973
- }, findFiberByHostInstance: ul.findFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, reconcilerVersion: "18.2.0-next-9e3b772b8-20220608" };
10976
+ }, findFiberByHostInstance: ul.findFiberByHostInstance || kl, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, reconcilerVersion: "18.2.0-next-9e3b772b8-20220608" };
10974
10977
  if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
10975
10978
  var wl = __REACT_DEVTOOLS_GLOBAL_HOOK__;
10976
10979
  if (!wl.isDisabled && wl.supportsFiber) try {
@@ -10981,11 +10984,11 @@ if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
10981
10984
  reactDom_production_min.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = tl;
10982
10985
  reactDom_production_min.createPortal = function(a2, b2) {
10983
10986
  var c2 = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;
10984
- if (!ol(b2)) throw Error(p$4(200));
10987
+ if (!ol(b2)) throw Error(p$3(200));
10985
10988
  return dl(a2, b2, null, c2);
10986
10989
  };
10987
10990
  reactDom_production_min.createRoot = function(a2, b2) {
10988
- if (!ol(a2)) throw Error(p$4(299));
10991
+ if (!ol(a2)) throw Error(p$3(299));
10989
10992
  var c2 = false, d2 = "", e2 = ll;
10990
10993
  null !== b2 && void 0 !== b2 && (true === b2.unstable_strictMode && (c2 = true), void 0 !== b2.identifierPrefix && (d2 = b2.identifierPrefix), void 0 !== b2.onRecoverableError && (e2 = b2.onRecoverableError));
10991
10994
  b2 = cl(a2, 1, false, null, null, c2, false, d2, e2);
@@ -10998,9 +11001,9 @@ reactDom_production_min.findDOMNode = function(a2) {
10998
11001
  if (1 === a2.nodeType) return a2;
10999
11002
  var b2 = a2._reactInternals;
11000
11003
  if (void 0 === b2) {
11001
- if ("function" === typeof a2.render) throw Error(p$4(188));
11004
+ if ("function" === typeof a2.render) throw Error(p$3(188));
11002
11005
  a2 = Object.keys(a2).join(",");
11003
- throw Error(p$4(268, a2));
11006
+ throw Error(p$3(268, a2));
11004
11007
  }
11005
11008
  a2 = Zb(b2);
11006
11009
  a2 = null === a2 ? null : a2.stateNode;
@@ -11010,11 +11013,11 @@ reactDom_production_min.flushSync = function(a2) {
11010
11013
  return Sk(a2);
11011
11014
  };
11012
11015
  reactDom_production_min.hydrate = function(a2, b2, c2) {
11013
- if (!pl(b2)) throw Error(p$4(200));
11016
+ if (!pl(b2)) throw Error(p$3(200));
11014
11017
  return sl(null, a2, b2, true, c2);
11015
11018
  };
11016
11019
  reactDom_production_min.hydrateRoot = function(a2, b2, c2) {
11017
- if (!ol(a2)) throw Error(p$4(405));
11020
+ if (!ol(a2)) throw Error(p$3(405));
11018
11021
  var d2 = null != c2 && c2.hydratedSources || null, e2 = false, f2 = "", g2 = ll;
11019
11022
  null !== c2 && void 0 !== c2 && (true === c2.unstable_strictMode && (e2 = true), void 0 !== c2.identifierPrefix && (f2 = c2.identifierPrefix), void 0 !== c2.onRecoverableError && (g2 = c2.onRecoverableError));
11020
11023
  b2 = fl(b2, null, a2, 1, null != c2 ? c2 : null, e2, false, f2, g2);
@@ -11027,11 +11030,11 @@ reactDom_production_min.hydrateRoot = function(a2, b2, c2) {
11027
11030
  return new nl(b2);
11028
11031
  };
11029
11032
  reactDom_production_min.render = function(a2, b2, c2) {
11030
- if (!pl(b2)) throw Error(p$4(200));
11033
+ if (!pl(b2)) throw Error(p$3(200));
11031
11034
  return sl(null, a2, b2, false, c2);
11032
11035
  };
11033
11036
  reactDom_production_min.unmountComponentAtNode = function(a2) {
11034
- if (!pl(a2)) throw Error(p$4(40));
11037
+ if (!pl(a2)) throw Error(p$3(40));
11035
11038
  return a2._reactRootContainer ? (Sk(function() {
11036
11039
  sl(null, null, a2, false, function() {
11037
11040
  a2._reactRootContainer = null;
@@ -11041,8 +11044,8 @@ reactDom_production_min.unmountComponentAtNode = function(a2) {
11041
11044
  };
11042
11045
  reactDom_production_min.unstable_batchedUpdates = Rk;
11043
11046
  reactDom_production_min.unstable_renderSubtreeIntoContainer = function(a2, b2, c2, d2) {
11044
- if (!pl(c2)) throw Error(p$4(200));
11045
- if (null == a2 || void 0 === a2._reactInternals) throw Error(p$4(38));
11047
+ if (!pl(c2)) throw Error(p$3(200));
11048
+ if (null == a2 || void 0 === a2._reactInternals) throw Error(p$3(38));
11046
11049
  return sl(a2, b2, c2, false, d2);
11047
11050
  };
11048
11051
  reactDom_production_min.version = "18.2.0-next-9e3b772b8-20220608";
@@ -11062,7 +11065,7 @@ function checkDCE() {
11062
11065
  }
11063
11066
  var reactDomExports = reactDom.exports;
11064
11067
  const $7SXl2$reactdom = /* @__PURE__ */ getDefaultExportFromCjs(reactDomExports);
11065
- function o$1(o2) {
11068
+ function o(o2) {
11066
11069
  const i = window.location.origin, a2 = (a3) => {
11067
11070
  if (a3.origin !== i) return;
11068
11071
  const r2 = o2.getRootElement();
@@ -11103,7 +11106,7 @@ function o$1(o2) {
11103
11106
  window.removeEventListener("message", a2, true);
11104
11107
  };
11105
11108
  }
11106
- function p$3(e2, n2) {
11109
+ function p$2(e2, n2) {
11107
11110
  const t2 = n2.body ? n2.body.childNodes : [];
11108
11111
  let o2 = [];
11109
11112
  const l2 = [];
@@ -11123,15 +11126,15 @@ function p$3(e2, n2) {
11123
11126
  }
11124
11127
  }(l2), o2;
11125
11128
  }
11126
- function h$2(e2, n2) {
11129
+ function h$1(e2, n2) {
11127
11130
  if ("undefined" == typeof document || "undefined" == typeof window && void 0 === global.window) throw new Error("To use $generateHtmlFromNodes in headless mode please initialize a headless browser implementation such as JSDom before calling this function.");
11128
11131
  const t2 = document.createElement("div"), l2 = ke$1().getChildren();
11129
11132
  for (let o2 = 0; o2 < l2.length; o2++) {
11130
- m$3(e2, l2[o2], t2, n2);
11133
+ m$2(e2, l2[o2], t2, n2);
11131
11134
  }
11132
11135
  return t2.innerHTML;
11133
11136
  }
11134
- function m$3(t2, o2, s2, c2 = null) {
11137
+ function m$2(t2, o2, s2, c2 = null) {
11135
11138
  let u2 = null === c2 || o2.isSelected(c2);
11136
11139
  const f2 = ds(o2) && o2.excludeFromCopy("html");
11137
11140
  let a2 = o2;
@@ -11146,7 +11149,7 @@ function m$3(t2, o2, s2, c2 = null) {
11146
11149
  if (!g2) return false;
11147
11150
  const y2 = document.createDocumentFragment();
11148
11151
  for (let e2 = 0; e2 < d2.length; e2++) {
11149
- const n2 = d2[e2], r2 = m$3(t2, n2, y2, c2);
11152
+ const n2 = d2[e2], r2 = m$2(t2, n2, y2, c2);
11150
11153
  !u2 && ds(o2) && r2 && o2.extractWithChild(n2, c2, "html") && (u2 = true);
11151
11154
  }
11152
11155
  if (u2 && !f2) {
@@ -11185,7 +11188,7 @@ function x$2(e2, n2, o2, r2, i = /* @__PURE__ */ new Map(), p2) {
11185
11188
  let v2 = [];
11186
11189
  const N2 = (null == m2 || !ln(m2)) && (null != m2 && bi$1(m2) || r2);
11187
11190
  for (let e3 = 0; e3 < S2.length; e3++) v2.push(...x$2(S2[e3], n2, o2, N2, new Map(i), m2));
11188
- return null != C2 && (v2 = C2(v2)), vn(e2) && (v2 = y$2(e2, v2, N2 ? () => {
11191
+ return null != C2 && (v2 = C2(v2)), vn(e2) && (v2 = y$1(e2, v2, N2 ? () => {
11189
11192
  const e3 = new Ss();
11190
11193
  return o2.push(e3), e3;
11191
11194
  } : ks)), null == m2 ? v2.length > 0 ? h2 = h2.concat(v2) : vn(e2) && function(e3) {
@@ -11193,7 +11196,7 @@ function x$2(e2, n2, o2, r2, i = /* @__PURE__ */ new Map(), p2) {
11193
11196
  return xn(e3.nextSibling) && xn(e3.previousSibling);
11194
11197
  }(e2) && (h2 = h2.concat(Br())) : ds(m2) && m2.append(...v2), h2;
11195
11198
  }
11196
- function y$2(e2, n2, t2) {
11199
+ function y$1(e2, n2, t2) {
11197
11200
  const o2 = e2.style.textAlign, l2 = [];
11198
11201
  let r2 = [];
11199
11202
  for (let e3 = 0; e3 < n2.length; e3++) {
@@ -11207,24 +11210,24 @@ function y$2(e2, n2, t2) {
11207
11210
  return l2;
11208
11211
  }
11209
11212
  function x$1(t2) {
11210
- return t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
11213
+ return t2 && t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
11211
11214
  }
11212
- var w$2 = x$1(function(t2) {
11215
+ var w$1 = x$1(function(t2) {
11213
11216
  const e2 = new URLSearchParams();
11214
11217
  e2.append("code", t2);
11215
11218
  for (let t3 = 1; t3 < arguments.length; t3++) e2.append("v", arguments[t3]);
11216
11219
  throw Error(`Minified Lexical error #${t2}; visit https://lexical.dev/docs/error?${e2} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
11217
11220
  });
11218
- const y$1 = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, v$2 = (t2) => y$1 ? (t2 || window).getSelection() : null;
11221
+ const y = "undefined" != typeof window && void 0 !== window.document && void 0 !== window.document.createElement, v$1 = (t2) => y ? (t2 || window).getSelection() : null;
11219
11222
  function D$2(e2) {
11220
11223
  const n2 = Fi$1();
11221
- return null == n2 && w$2(166), _i(n2) && n2.isCollapsed() || 0 === n2.getNodes().length ? "" : h$2(e2, n2);
11224
+ return null == n2 && w$1(166), _i(n2) && n2.isCollapsed() || 0 === n2.getNodes().length ? "" : h$1(e2, n2);
11222
11225
  }
11223
11226
  function C(t2) {
11224
11227
  const e2 = Fi$1();
11225
- return null == e2 && w$2(166), _i(e2) && e2.isCollapsed() || 0 === e2.getNodes().length ? null : JSON.stringify(A(t2, e2));
11228
+ return null == e2 && w$1(166), _i(e2) && e2.isCollapsed() || 0 === e2.getNodes().length ? null : JSON.stringify(A(t2, e2));
11226
11229
  }
11227
- function _$1(t2, n2, o2) {
11230
+ function _(t2, n2, o2) {
11228
11231
  const l2 = t2.getData("application/x-lexical-editor");
11229
11232
  if (l2) try {
11230
11233
  const t3 = JSON.parse(l2);
@@ -11236,7 +11239,7 @@ function _$1(t2, n2, o2) {
11236
11239
  const a2 = t2.getData("text/html");
11237
11240
  if (a2) try {
11238
11241
  const t3 = new DOMParser().parseFromString(a2, "text/html");
11239
- return T$1(o2, p$3(o2, t3), n2);
11242
+ return T$1(o2, p$2(o2, t3), n2);
11240
11243
  } catch (t3) {
11241
11244
  }
11242
11245
  const c2 = t2.getData("text/plain") || t2.getData("text/uri-list");
@@ -11265,9 +11268,9 @@ function S$1(t2, e2, n2, l2 = []) {
11265
11268
  }
11266
11269
  const a2 = ds(s2) ? s2.getChildren() : [], c2 = function(t3) {
11267
11270
  const e3 = t3.exportJSON(), n3 = t3.constructor;
11268
- if (e3.type !== n3.getType() && w$2(58, n3.name), ds(t3)) {
11271
+ if (e3.type !== n3.getType() && w$1(58, n3.name), ds(t3)) {
11269
11272
  const t4 = e3.children;
11270
- Array.isArray(t4) || w$2(59, n3.name);
11273
+ Array.isArray(t4) || w$1(59, n3.name);
11271
11274
  }
11272
11275
  return e3;
11273
11276
  }(s2);
@@ -11306,23 +11309,23 @@ async function O(t2, e2) {
11306
11309
  if (null !== E$2) return false;
11307
11310
  if (null !== e2) return new Promise((n3, o3) => {
11308
11311
  t2.update(() => {
11309
- n3(P$1(t2, e2));
11312
+ n3(P(t2, e2));
11310
11313
  });
11311
11314
  });
11312
- const n2 = t2.getRootElement(), o2 = null == t2._window ? window.document : t2._window.document, r2 = v$2(t2._window);
11315
+ const n2 = t2.getRootElement(), o2 = null == t2._window ? window.document : t2._window.document, r2 = v$1(t2._window);
11313
11316
  if (null === n2 || null === r2) return false;
11314
11317
  const i = o2.createElement("span");
11315
11318
  i.style.cssText = "position: fixed; top: -1000px;", i.append(o2.createTextNode("#")), n2.append(i);
11316
11319
  const s2 = new Range();
11317
11320
  return s2.setStart(i, 0), s2.setEnd(i, 1), r2.removeAllRanges(), r2.addRange(s2), new Promise((e3, n3) => {
11318
- const r3 = t2.registerCommand(M$4, (n4) => (te$1(n4, ClipboardEvent) && (r3(), null !== E$2 && (window.clearTimeout(E$2), E$2 = null), e3(P$1(t2, n4))), true), Ds);
11321
+ const r3 = t2.registerCommand(M$4, (n4) => (te$1(n4, ClipboardEvent) && (r3(), null !== E$2 && (window.clearTimeout(E$2), E$2 = null), e3(P(t2, n4))), true), Ds);
11319
11322
  E$2 = window.setTimeout(() => {
11320
11323
  r3(), E$2 = null, e3(false);
11321
11324
  }, 50), o2.execCommand("copy"), i.remove();
11322
11325
  });
11323
11326
  }
11324
- function P$1(t2, e2) {
11325
- const n2 = v$2(t2._window);
11327
+ function P(t2, e2) {
11328
+ const n2 = v$1(t2._window);
11326
11329
  if (!n2) return false;
11327
11330
  const o2 = n2.anchorNode, l2 = n2.focusNode;
11328
11331
  if (null !== o2 && null !== l2 && !le$2(t2, o2, l2)) return false;
@@ -11370,35 +11373,35 @@ function Ot(t2) {
11370
11373
  return _s(e2);
11371
11374
  }
11372
11375
  function Tt(o2) {
11373
- return b$2(o2.registerCommand(r$4, (t2) => {
11376
+ return b$1(o2.registerCommand(r$4, (t2) => {
11374
11377
  const e2 = Fi$1();
11375
11378
  return !!yi$1(e2) && (e2.clear(), true);
11376
11379
  }, 0), o2.registerCommand(i$2, (t2) => {
11377
11380
  const e2 = Fi$1();
11378
11381
  return !!_i(e2) && (e2.deleteCharacter(t2), true);
11379
- }, ws), o2.registerCommand(u$7, (t2) => {
11382
+ }, ws), o2.registerCommand(u$6, (t2) => {
11380
11383
  const e2 = Fi$1();
11381
11384
  return !!_i(e2) && (e2.deleteWord(t2), true);
11382
- }, ws), o2.registerCommand(f$3, (t2) => {
11385
+ }, ws), o2.registerCommand(f$2, (t2) => {
11383
11386
  const e2 = Fi$1();
11384
11387
  return !!_i(e2) && (e2.deleteLine(t2), true);
11385
- }, ws), o2.registerCommand(l$3, (e2) => {
11388
+ }, ws), o2.registerCommand(l$2, (e2) => {
11386
11389
  const n2 = Fi$1();
11387
11390
  if ("string" == typeof e2) null !== n2 && n2.insertText(e2);
11388
11391
  else {
11389
11392
  if (null === n2) return false;
11390
11393
  const r2 = e2.dataTransfer;
11391
- if (null != r2) _$1(r2, n2, o2);
11394
+ if (null != r2) _(r2, n2, o2);
11392
11395
  else if (_i(n2)) {
11393
11396
  const t2 = e2.data;
11394
11397
  return t2 && n2.insertText(t2), true;
11395
11398
  }
11396
11399
  }
11397
11400
  return true;
11398
- }, ws), o2.registerCommand(a$4, () => {
11401
+ }, ws), o2.registerCommand(a$3, () => {
11399
11402
  const t2 = Fi$1();
11400
11403
  return !!_i(t2) && (t2.removeText(), true);
11401
- }, ws), o2.registerCommand(d$3, (t2) => {
11404
+ }, ws), o2.registerCommand(d$2, (t2) => {
11402
11405
  const e2 = Fi$1();
11403
11406
  return !!_i(e2) && (e2.formatText(t2), true);
11404
11407
  }, ws), o2.registerCommand(L$3, (t2) => {
@@ -11410,19 +11413,19 @@ function Tt(o2) {
11410
11413
  null !== n3 && n3.setFormat(t2);
11411
11414
  }
11412
11415
  return true;
11413
- }, ws), o2.registerCommand(s$3, (t2) => {
11416
+ }, ws), o2.registerCommand(s$2, (t2) => {
11414
11417
  const e2 = Fi$1();
11415
11418
  return !!_i(e2) && (e2.insertLineBreak(t2), true);
11416
- }, ws), o2.registerCommand(o$5, () => {
11419
+ }, ws), o2.registerCommand(o$4, () => {
11417
11420
  const t2 = Fi$1();
11418
11421
  return !!_i(t2) && (t2.insertParagraph(), true);
11419
- }, ws), o2.registerCommand(E$6, () => (Wi$1([li$1()]), true), ws), o2.registerCommand(P$3, () => It((t2) => {
11422
+ }, ws), o2.registerCommand(E$6, () => (Wi$1([li$1()]), true), ws), o2.registerCommand(P$2, () => It((t2) => {
11420
11423
  const e2 = t2.getIndent();
11421
11424
  t2.setIndent(e2 + 1);
11422
11425
  }), ws), o2.registerCommand(D$5, () => It((t2) => {
11423
11426
  const e2 = t2.getIndent();
11424
11427
  e2 > 0 && t2.setIndent(e2 - 1);
11425
- }), ws), o2.registerCommand(v$5, (t2) => {
11428
+ }), ws), o2.registerCommand(v$4, (t2) => {
11426
11429
  const e2 = Fi$1();
11427
11430
  if (yi$1(e2) && !Ot(t2.target)) {
11428
11431
  const t3 = e2.getNodes();
@@ -11446,7 +11449,7 @@ function Tt(o2) {
11446
11449
  if (!t2.shiftKey && _s(n2) && !n2.isIsolated() && !n2.isInline()) return n2.selectNext(), t2.preventDefault(), true;
11447
11450
  }
11448
11451
  return false;
11449
- }, ws), o2.registerCommand(m$9, (t2) => {
11452
+ }, ws), o2.registerCommand(m$8, (t2) => {
11450
11453
  const e2 = Fi$1();
11451
11454
  if (yi$1(e2)) {
11452
11455
  const n2 = e2.getNodes();
@@ -11458,7 +11461,7 @@ function Tt(o2) {
11458
11461
  return t2.preventDefault(), M$3(e2, n2, true), true;
11459
11462
  }
11460
11463
  return false;
11461
- }, ws), o2.registerCommand(p$9, (t2) => {
11464
+ }, ws), o2.registerCommand(p$8, (t2) => {
11462
11465
  const e2 = Fi$1();
11463
11466
  if (yi$1(e2) && !Ot(t2.target)) {
11464
11467
  const n2 = e2.getNodes();
@@ -11477,7 +11480,7 @@ function Tt(o2) {
11477
11480
  if (J$1(r2).getIndent() > 0) return o2.dispatchCommand(D$5, void 0);
11478
11481
  }
11479
11482
  return o2.dispatchCommand(i$2, true);
11480
- }, ws), o2.registerCommand(w$4, (t2) => {
11483
+ }, ws), o2.registerCommand(w$3, (t2) => {
11481
11484
  if (Ot(t2.target)) return false;
11482
11485
  const e2 = Fi$1();
11483
11486
  return !!_i(e2) && (t2.preventDefault(), o2.dispatchCommand(i$2, false));
@@ -11486,10 +11489,10 @@ function Tt(o2) {
11486
11489
  if (!_i(e2)) return false;
11487
11490
  if (null !== t2) {
11488
11491
  if ((dt || lt || ft) && ut) return false;
11489
- if (t2.preventDefault(), t2.shiftKey) return o2.dispatchCommand(s$3, false);
11492
+ if (t2.preventDefault(), t2.shiftKey) return o2.dispatchCommand(s$2, false);
11490
11493
  }
11491
- return o2.dispatchCommand(o$5, void 0);
11492
- }, ws), o2.registerCommand(b$3, () => {
11494
+ return o2.dispatchCommand(o$4, void 0);
11495
+ }, ws), o2.registerCommand(b$2, () => {
11493
11496
  const t2 = Fi$1();
11494
11497
  return !!_i(t2) && (o2.blur(), true);
11495
11498
  }, ws), o2.registerCommand(F$1, (t2) => {
@@ -11531,14 +11534,14 @@ function Tt(o2) {
11531
11534
  const t4 = Fi$1();
11532
11535
  _i(t4) ? t4.removeText() : yi$1(t4) && t4.getNodes().forEach((t5) => t5.remove());
11533
11536
  });
11534
- }(t2, o2), true), ws), o2.registerCommand(c$4, (e2) => {
11537
+ }(t2, o2), true), ws), o2.registerCommand(c$3, (e2) => {
11535
11538
  const [, n2, r2] = Nt(e2);
11536
11539
  if (n2.length > 0 && !r2) return o2.dispatchCommand(gt, n2), true;
11537
11540
  if (oe$2(e2.target)) return false;
11538
11541
  return null !== Fi$1() && (function(e3, n3) {
11539
11542
  e3.preventDefault(), n3.update(() => {
11540
11543
  const r3 = Fi$1(), o3 = te$1(e3, InputEvent) || te$1(e3, KeyboardEvent) ? null : e3.clipboardData;
11541
- null != o3 && null !== r3 && _$1(o3, r3, n3);
11544
+ null != o3 && null !== r3 && _(o3, r3, n3);
11542
11545
  }, { tag: "paste" });
11543
11546
  }(e2, o2), true);
11544
11547
  }, ws));
@@ -11547,8 +11550,8 @@ const g = "undefined" != typeof window && void 0 !== window.document && void 0 !
11547
11550
  function E$1(t2) {
11548
11551
  return t2.getEditorState().read(g$4(t2.isComposing()));
11549
11552
  }
11550
- function h$1({ contentEditable: e2, placeholder: r2 = null, ErrorBoundary: n2 }) {
11551
- const [E2] = u$6(), h2 = function(t2, e3) {
11553
+ function h({ contentEditable: e2, placeholder: r2 = null, ErrorBoundary: n2 }) {
11554
+ const [E2] = u$5(), h2 = function(t2, e3) {
11552
11555
  const [r3, o2] = useState$1(() => t2.getDecorators());
11553
11556
  return g(() => t2.registerDecoratorListener((t3) => {
11554
11557
  reactDomExports.flushSync(() => {
@@ -11566,24 +11569,24 @@ function h$1({ contentEditable: e2, placeholder: r2 = null, ErrorBoundary: n2 })
11566
11569
  }, [e3, r3, t2]);
11567
11570
  }(E2, n2);
11568
11571
  return function(t2) {
11569
- g(() => b$2(Tt(t2), o$1(t2)), [t2]);
11570
- }(E2), jsxs(Fragment$1, { children: [e2, jsx(w$1, { content: r2 }), h2] });
11572
+ g(() => b$1(Tt(t2), o(t2)), [t2]);
11573
+ }(E2), jsxs(Fragment$1, { children: [e2, jsx(w, { content: r2 }), h2] });
11571
11574
  }
11572
- function w$1({ content: r2 }) {
11573
- const [n2] = u$6(), i = function(t2) {
11575
+ function w({ content: r2 }) {
11576
+ const [n2] = u$5(), i = function(t2) {
11574
11577
  const [e2, r3] = useState$1(() => E$1(t2));
11575
11578
  return g(() => {
11576
11579
  function e3() {
11577
11580
  const e4 = E$1(t2);
11578
11581
  r3(e4);
11579
11582
  }
11580
- return e3(), b$2(t2.registerUpdateListener(() => {
11583
+ return e3(), b$1(t2.registerUpdateListener(() => {
11581
11584
  e3();
11582
11585
  }), t2.registerEditableListener(() => {
11583
11586
  e3();
11584
11587
  }));
11585
11588
  }, [t2]), e2;
11586
- }(n2), l2 = a$1();
11589
+ }(n2), l2 = a();
11587
11590
  return i ? "function" == typeof r2 ? r2(l2) : r2 : null;
11588
11591
  }
11589
11592
  const editor$4 = "_editor_s4gjm_1";
@@ -12853,18 +12856,18 @@ const styles$u = {
12853
12856
  contextItemMentionChipNodeFocused,
12854
12857
  isTooLargeOrIgnored: isTooLargeOrIgnored$1
12855
12858
  };
12856
- function d$1(e2, t2) {
12859
+ function d(e2, t2) {
12857
12860
  return e2.getEditorState().read(() => {
12858
12861
  const e3 = xe$2(t2);
12859
12862
  return null !== e3 && e3.isSelected();
12860
12863
  });
12861
12864
  }
12862
- function u$2(c2) {
12863
- const [u2] = u$6(), [p2, s2] = useState$1(() => d$1(u2, c2));
12865
+ function u$1(c2) {
12866
+ const [u2] = u$5(), [p2, s2] = useState$1(() => d(u2, c2));
12864
12867
  useEffect$2(() => {
12865
12868
  let e2 = true;
12866
12869
  const t2 = u2.registerUpdateListener(() => {
12867
- e2 && s2(d$1(u2, c2));
12870
+ e2 && s2(d(u2, c2));
12868
12871
  });
12869
12872
  return () => {
12870
12873
  e2 = false, t2();
@@ -12913,12 +12916,12 @@ const IS_IOS = CAN_USE_DOM && /iPad|iPhone|iPod/.test(navigator.userAgent) && //
12913
12916
  !window.MSStream;
12914
12917
  const useLayoutEffectImpl = CAN_USE_DOM ? useLayoutEffect$1 : useEffect$2;
12915
12918
  const useIsFocused = () => {
12916
- const [editor2] = u$6();
12919
+ const [editor2] = u$5();
12917
12920
  const [hasFocus, setHasFocus] = useState$1(
12918
12921
  () => CAN_USE_DOM ? editor2.getRootElement() === document.activeElement : false
12919
12922
  );
12920
12923
  useLayoutEffectImpl(() => {
12921
- return b$2(
12924
+ return b$1(
12922
12925
  editor2.registerCommand(
12923
12926
  U$2,
12924
12927
  () => {
@@ -12941,9 +12944,9 @@ const useIsFocused = () => {
12941
12944
  };
12942
12945
  const MentionComponent = ({ nodeKey, node: node2, tooltip, icon: Icon2, className, focusedClassName, iconClassName }) => {
12943
12946
  const { tooltipComponents, onContextItemMentionNodeMetaClick } = getGlobalPromptEditorConfig();
12944
- const [editor2] = u$6();
12947
+ const [editor2] = u$5();
12945
12948
  const isEditorFocused = useIsFocused();
12946
- const [isSelected, setSelected, clearSelection] = u$2(nodeKey);
12949
+ const [isSelected, setSelected, clearSelection] = u$1(nodeKey);
12947
12950
  const ref = useRef$1(null);
12948
12951
  const text2 = node2.getTextContent();
12949
12952
  const composedClassNames = useMemo$1(() => {
@@ -13068,14 +13071,14 @@ const MentionComponent = ({ nodeKey, node: node2, tooltip, icon: Icon2, classNam
13068
13071
  return false;
13069
13072
  }, [isSelected, setSelected]);
13070
13073
  useEffect$2(() => {
13071
- const unregister = b$2(
13074
+ const unregister = b$1(
13072
13075
  editor2.registerCommand(r$4, onClick, Ns),
13073
- editor2.registerCommand(w$4, onDelete, Ns),
13076
+ editor2.registerCommand(w$3, onDelete, Ns),
13074
13077
  editor2.registerCommand(k$3, onDelete, Ns),
13075
- editor2.registerCommand(m$9, onArrowLeftPress, Ns),
13076
- editor2.registerCommand(p$9, onArrowRightPress, Ns),
13078
+ editor2.registerCommand(m$8, onArrowLeftPress, Ns),
13079
+ editor2.registerCommand(p$8, onArrowRightPress, Ns),
13077
13080
  editor2.registerCommand(V$2, onBlur, Ns),
13078
- editor2.registerCommand(e$1, onSelectionChange, Ns)
13081
+ editor2.registerCommand(e, onSelectionChange, Ns)
13079
13082
  );
13080
13083
  return () => {
13081
13084
  unregister();
@@ -13247,7 +13250,7 @@ function $createContextItemTextNode(contextItem2) {
13247
13250
  const TemplateInputComponent = ({ editor: editor2, nodeKey, node: node2, className, focusedClassName }) => {
13248
13251
  const { tooltipComponents } = getGlobalPromptEditorConfig();
13249
13252
  const isEditorFocused = useIsFocused();
13250
- const [isSelected, setSelected, clearSelection] = u$2(nodeKey);
13253
+ const [isSelected, setSelected, clearSelection] = u$1(nodeKey);
13251
13254
  const ref = useRef$1(null);
13252
13255
  const composedClassNames = useMemo$1(() => {
13253
13256
  const classes = [className];
@@ -13288,9 +13291,9 @@ const TemplateInputComponent = ({ editor: editor2, nodeKey, node: node2, classNa
13288
13291
  [nodeKey, editor2, isSelected]
13289
13292
  );
13290
13293
  useEffect$2(() => {
13291
- return b$2(
13294
+ return b$1(
13292
13295
  editor2.registerCommand(r$4, onClick, Ns),
13293
- editor2.registerCommand(_$3, onKeyDown, Ns)
13296
+ editor2.registerCommand(_$2, onKeyDown, Ns)
13294
13297
  );
13295
13298
  }, [editor2, onClick, onKeyDown]);
13296
13299
  const tooltip = "replaces template placeholder on keypress";
@@ -13363,7 +13366,7 @@ function $isTemplateInputNode(node2) {
13363
13366
  return node2 instanceof TemplateInputNode;
13364
13367
  }
13365
13368
  const RICH_EDITOR_NODES = [ContextItemMentionNode, TemplateInputNode];
13366
- const v$1 = (t2) => {
13369
+ const v = (t2) => {
13367
13370
  const e2 = document.getElementById("typeahead-menu");
13368
13371
  if (!e2) return;
13369
13372
  const n2 = e2.getBoundingClientRect();
@@ -13374,7 +13377,7 @@ function x(t2, e2) {
13374
13377
  return n2.top > o2.top && n2.top < o2.bottom;
13375
13378
  }
13376
13379
  function E(e2, n2, o2, r2) {
13377
- const [l2] = u$6();
13380
+ const [l2] = u$5();
13378
13381
  useEffect$2(() => {
13379
13382
  if (null != n2 && null != e2) {
13380
13383
  const t2 = l2.getRootElement(), e3 = null != t2 ? function(t3, e4) {
@@ -13434,7 +13437,7 @@ function R({ close: t2, editor: e2, anchorElementRef: a2, resolution: d2, option
13434
13437
  null !== t3 && t3.removeAttribute("aria-activedescendant");
13435
13438
  }, [e2]), useLayoutEffect$1(() => {
13436
13439
  null === w2 ? O2(null) : null === R2 && A2(0);
13437
- }, [w2, R2, A2]), useEffect$2(() => b$2(e2.registerCommand(S, ({ option: t3 }) => !(!t3.ref || null == t3.ref.current) && (v$1(t3.ref.current), true), E2)), [e2, A2, E2]), useEffect$2(() => b$2(e2.registerCommand(S$4, (t3) => {
13440
+ }, [w2, R2, A2]), useEffect$2(() => b$1(e2.registerCommand(S, ({ option: t3 }) => !(!t3.ref || null == t3.ref.current) && (v(t3.ref.current), true), E2)), [e2, A2, E2]), useEffect$2(() => b$1(e2.registerCommand(S$4, (t3) => {
13438
13441
  const n2 = t3;
13439
13442
  if (null !== w2 && w2.length && null !== R2) {
13440
13443
  const t4 = R2 !== w2.length - 1 ? R2 + 1 : 0;
@@ -13443,16 +13446,16 @@ function R({ close: t2, editor: e2, anchorElementRef: a2, resolution: d2, option
13443
13446
  null != o2.ref && o2.ref.current && e2.dispatchCommand(S, { index: t4, option: o2 }), n2.preventDefault(), n2.stopImmediatePropagation();
13444
13447
  }
13445
13448
  return true;
13446
- }, E2), e2.registerCommand(v$5, (t3) => {
13449
+ }, E2), e2.registerCommand(v$4, (t3) => {
13447
13450
  const e3 = t3;
13448
13451
  if (null !== w2 && w2.length && null !== R2) {
13449
13452
  const t4 = 0 !== R2 ? R2 - 1 : w2.length - 1;
13450
13453
  A2(t4);
13451
13454
  const n2 = w2[t4];
13452
- null != n2.ref && n2.ref.current && v$1(n2.ref.current), e3.preventDefault(), e3.stopImmediatePropagation();
13455
+ null != n2.ref && n2.ref.current && v(n2.ref.current), e3.preventDefault(), e3.stopImmediatePropagation();
13453
13456
  }
13454
13457
  return true;
13455
- }, E2), e2.registerCommand(b$3, (e3) => {
13458
+ }, E2), e2.registerCommand(b$2, (e3) => {
13456
13459
  const n2 = e3;
13457
13460
  return n2.preventDefault(), n2.stopImmediatePropagation(), t2(), true;
13458
13461
  }, E2), e2.registerCommand(N$2, (t3) => {
@@ -13462,8 +13465,8 @@ function R({ close: t2, editor: e2, anchorElementRef: a2, resolution: d2, option
13462
13465
  return C2(a2, useMemo$1(() => ({ options: w2, selectOptionAndCleanUp: T2, selectedIndex: R2, setHighlightedIndex: O2 }), [T2, R2, w2]), d2.match ? d2.match.matchingString : "");
13463
13466
  }
13464
13467
  function L({ options: e2, onQueryChange: n2, onSelectOption: o2, onOpen: r2, onClose: l2, menuRenderFn: i, triggerFn: g2, anchorClassName: h2, commandPriority: y2 = Ns, parent: b2 }) {
13465
- const [v2] = u$6(), [x2, S2] = useState$1(null), O2 = function(e3, n3, o3, r3 = document.body) {
13466
- const [l3] = u$6(), i2 = useRef$1(document.createElement("div")), s2 = useCallback(() => {
13468
+ const [v2] = u$5(), [x2, S2] = useState$1(null), O2 = function(e3, n3, o3, r3 = document.body) {
13469
+ const [l3] = u$5(), i2 = useRef$1(document.createElement("div")), s2 = useCallback(() => {
13467
13470
  const t2 = l3.getRootElement(), n4 = i2.current, s3 = n4.firstChild;
13468
13471
  if (null !== t2 && null !== e3) {
13469
13472
  const { left: l4, top: u3, width: c2, height: a2 } = e3.getRect();
@@ -14050,7 +14053,7 @@ function scanForMentionTriggerInLexicalInput(text2) {
14050
14053
  return scanForMentionTriggerInUserTextInput({ textBeforeCursor: text2, includeWhitespace: true });
14051
14054
  }
14052
14055
  const MentionsPlugin = memo$2(({ contextWindowSizeInTokens, openExternalLink }) => {
14053
- const [editor2] = u$6();
14056
+ const [editor2] = u$5();
14054
14057
  const [tokenAdded, setTokenAdded] = useState$1(0);
14055
14058
  const { params, updateQuery, updateMentionMenuParams } = useMentionMenuParams();
14056
14059
  const setEditorQuery = useCallback(
@@ -14136,7 +14139,7 @@ const MentionsPlugin = memo$2(({ contextWindowSizeInTokens, openExternalLink })
14136
14139
  return true;
14137
14140
  }
14138
14141
  editor2.dispatchCommand(
14139
- b$3,
14142
+ b$2,
14140
14143
  new KeyboardEvent("keydown", { key: "Escape" })
14141
14144
  );
14142
14145
  return true;
@@ -14199,9 +14202,9 @@ function sharedPrefixLength(s1, s2) {
14199
14202
  }
14200
14203
  const DUMMY_OPTIONS = [];
14201
14204
  const DisableEscapeKeyBlursPlugin = () => {
14202
- const [editor2] = u$6();
14205
+ const [editor2] = u$5();
14203
14206
  useEffect$2(() => {
14204
- const escListeners = editor2._commands.get(b$3);
14207
+ const escListeners = editor2._commands.get(b$2);
14205
14208
  if (!escListeners) {
14206
14209
  console.log("DisableEscapeKeyBlursPlugin: no listeners registered for Escape key.");
14207
14210
  return;
@@ -14224,7 +14227,7 @@ const DisableEscapeKeyBlursPlugin = () => {
14224
14227
  return null;
14225
14228
  };
14226
14229
  const KeyboardEventPlugin = ({ onEnterKey }) => {
14227
- const [editor2] = u$6();
14230
+ const [editor2] = u$5();
14228
14231
  useEffect$2(() => {
14229
14232
  return onEnterKey ? editor2.registerCommand(
14230
14233
  T$3,
@@ -14238,10 +14241,10 @@ const KeyboardEventPlugin = ({ onEnterKey }) => {
14238
14241
  return null;
14239
14242
  };
14240
14243
  const NoRichTextFormatShortcutsPlugin = () => {
14241
- const [editor2] = u$6();
14244
+ const [editor2] = u$5();
14242
14245
  useEffect$2(() => {
14243
14246
  return editor2.registerCommand(
14244
- d$3,
14247
+ d$2,
14245
14248
  () => {
14246
14249
  return true;
14247
14250
  },
@@ -14253,7 +14256,7 @@ const NoRichTextFormatShortcutsPlugin = () => {
14253
14256
  const OnFocusChangePlugin = ({
14254
14257
  onFocusChange
14255
14258
  }) => {
14256
- const [editor2] = u$6();
14259
+ const [editor2] = u$5();
14257
14260
  useLayoutEffect$1(() => {
14258
14261
  onFocusChange(editor2.getRootElement() === document.activeElement);
14259
14262
  const disposables = [];
@@ -14310,9 +14313,9 @@ const BaseEditor = ({
14310
14313
  }),
14311
14314
  []
14312
14315
  );
14313
- return /* @__PURE__ */ jsx("div", { className, children: /* @__PURE__ */ jsx("div", { className: styles$w.editor, children: /* @__PURE__ */ jsxs(p$8, { initialConfig, children: [
14316
+ return /* @__PURE__ */ jsx("div", { className, children: /* @__PURE__ */ jsx("div", { className: styles$w.editor, children: /* @__PURE__ */ jsxs(p$7, { initialConfig, children: [
14314
14317
  /* @__PURE__ */ jsx(
14315
- h$1,
14318
+ h,
14316
14319
  {
14317
14320
  contentEditable: /* @__PURE__ */ jsx(
14318
14321
  x$4,
@@ -14322,11 +14325,11 @@ const BaseEditor = ({
14322
14325
  }
14323
14326
  ),
14324
14327
  placeholder: /* @__PURE__ */ jsx("div", { className: styles$w.placeholder, children: placeholder2 }),
14325
- ErrorBoundary: a$3
14328
+ ErrorBoundary: a$2
14326
14329
  }
14327
14330
  ),
14328
14331
  /* @__PURE__ */ jsx(NoRichTextFormatShortcutsPlugin, {}),
14329
- /* @__PURE__ */ jsx(a$2, {}),
14332
+ /* @__PURE__ */ jsx(a$1, {}),
14330
14333
  /* @__PURE__ */ jsx(
14331
14334
  i$1,
14332
14335
  {
@@ -14342,7 +14345,7 @@ const BaseEditor = ({
14342
14345
  }
14343
14346
  ),
14344
14347
  onFocusChange && /* @__PURE__ */ jsx(OnFocusChangePlugin, { onFocusChange }),
14345
- editorRef && /* @__PURE__ */ jsx(o$3, { editorRef }),
14348
+ editorRef && /* @__PURE__ */ jsx(o$2, { editorRef }),
14346
14349
  /* @__PURE__ */ jsx(KeyboardEventPlugin, { onEnterKey }),
14347
14350
  /* @__PURE__ */ jsx(DisableEscapeKeyBlursPlugin, {})
14348
14351
  ] }) }) });
@@ -17603,17 +17606,17 @@ class ParseContext {
17603
17606
  }
17604
17607
  addTextNode(dom, marks) {
17605
17608
  let value = dom.nodeValue;
17606
- let top2 = this.top;
17607
- if (top2.options & OPT_PRESERVE_WS_FULL || top2.inlineContext(dom) || /[^ \t\r\n\u000c]/.test(value)) {
17608
- if (!(top2.options & OPT_PRESERVE_WS)) {
17609
+ let top = this.top;
17610
+ if (top.options & OPT_PRESERVE_WS_FULL || top.inlineContext(dom) || /[^ \t\r\n\u000c]/.test(value)) {
17611
+ if (!(top.options & OPT_PRESERVE_WS)) {
17609
17612
  value = value.replace(/[ \t\r\n\u000c]+/g, " ");
17610
17613
  if (/^[ \t\r\n\u000c]/.test(value) && this.open == this.nodes.length - 1) {
17611
- let nodeBefore = top2.content[top2.content.length - 1];
17614
+ let nodeBefore = top.content[top.content.length - 1];
17612
17615
  let domNodeBefore = dom.previousSibling;
17613
17616
  if (!nodeBefore || domNodeBefore && domNodeBefore.nodeName == "BR" || nodeBefore.isText && /[ \t\r\n\u000c]$/.test(nodeBefore.text))
17614
17617
  value = value.slice(1);
17615
17618
  }
17616
- } else if (!(top2.options & OPT_PRESERVE_WS_FULL)) {
17619
+ } else if (!(top.options & OPT_PRESERVE_WS_FULL)) {
17617
17620
  value = value.replace(/\r?\n|\r/g, " ");
17618
17621
  } else {
17619
17622
  value = value.replace(/\r\n?/g, "\n");
@@ -17640,14 +17643,14 @@ class ParseContext {
17640
17643
  this.open = Math.max(0, this.open - 1);
17641
17644
  else if (rule && rule.skip.nodeType)
17642
17645
  dom = rule.skip;
17643
- let sync, top2 = this.top, oldNeedsBlock = this.needsBlock;
17646
+ let sync, top = this.top, oldNeedsBlock = this.needsBlock;
17644
17647
  if (blockTags.hasOwnProperty(name2)) {
17645
- if (top2.content.length && top2.content[0].isInline && this.open) {
17648
+ if (top.content.length && top.content[0].isInline && this.open) {
17646
17649
  this.open--;
17647
- top2 = this.top;
17650
+ top = this.top;
17648
17651
  }
17649
17652
  sync = true;
17650
- if (!top2.type)
17653
+ if (!top.type)
17651
17654
  this.needsBlock = true;
17652
17655
  } else if (!dom.firstChild) {
17653
17656
  this.leafFallback(dom, marks);
@@ -17657,7 +17660,7 @@ class ParseContext {
17657
17660
  if (innerMarks)
17658
17661
  this.addAll(dom, innerMarks);
17659
17662
  if (sync)
17660
- this.sync(top2);
17663
+ this.sync(top);
17661
17664
  this.needsBlock = oldNeedsBlock;
17662
17665
  } else {
17663
17666
  let innerMarks = this.readStyles(dom, marks);
@@ -17790,14 +17793,14 @@ class ParseContext {
17790
17793
  let innerMarks = this.findPlace(node2, marks);
17791
17794
  if (innerMarks) {
17792
17795
  this.closeExtra();
17793
- let top2 = this.top;
17794
- if (top2.match)
17795
- top2.match = top2.match.matchType(node2.type);
17796
+ let top = this.top;
17797
+ if (top.match)
17798
+ top.match = top.match.matchType(node2.type);
17796
17799
  let nodeMarks = Mark.none;
17797
17800
  for (let m2 of innerMarks.concat(node2.marks))
17798
- if (top2.type ? top2.type.allowsMarkType(m2.type) : markMayApply(m2.type, node2.type))
17801
+ if (top.type ? top.type.allowsMarkType(m2.type) : markMayApply(m2.type, node2.type))
17799
17802
  nodeMarks = m2.addToSet(nodeMarks);
17800
- top2.content.push(node2.mark(nodeMarks));
17803
+ top.content.push(node2.mark(nodeMarks));
17801
17804
  return true;
17802
17805
  }
17803
17806
  return false;
@@ -17813,14 +17816,14 @@ class ParseContext {
17813
17816
  // Open a node of the given type
17814
17817
  enterInner(type, attrs, marks, solid = false, preserveWS) {
17815
17818
  this.closeExtra();
17816
- let top2 = this.top;
17817
- top2.match = top2.match && top2.match.matchType(type);
17818
- let options = wsOptionsFor(type, preserveWS, top2.options);
17819
- if (top2.options & OPT_OPEN_LEFT && top2.content.length == 0)
17819
+ let top = this.top;
17820
+ top.match = top.match && top.match.matchType(type);
17821
+ let options = wsOptionsFor(type, preserveWS, top.options);
17822
+ if (top.options & OPT_OPEN_LEFT && top.content.length == 0)
17820
17823
  options |= OPT_OPEN_LEFT;
17821
17824
  let applyMarks = Mark.none;
17822
17825
  marks = marks.filter((m2) => {
17823
- if (top2.type ? top2.type.allowsMarkType(m2.type) : markMayApply(m2.type, type)) {
17826
+ if (top.type ? top.type.allowsMarkType(m2.type) : markMayApply(m2.type, type)) {
17824
17827
  applyMarks = m2.addToSet(applyMarks);
17825
17828
  return false;
17826
17829
  }
@@ -18005,7 +18008,7 @@ class DOMSerializer {
18005
18008
  serializeFragment(fragment, options = {}, target) {
18006
18009
  if (!target)
18007
18010
  target = doc$1(options).createDocumentFragment();
18008
- let top2 = target, active = [];
18011
+ let top = target, active = [];
18009
18012
  fragment.forEach((node2) => {
18010
18013
  if (active.length || node2.marks.length) {
18011
18014
  let keep = 0, rendered = 0;
@@ -18021,18 +18024,18 @@ class DOMSerializer {
18021
18024
  rendered++;
18022
18025
  }
18023
18026
  while (keep < active.length)
18024
- top2 = active.pop()[1];
18027
+ top = active.pop()[1];
18025
18028
  while (rendered < node2.marks.length) {
18026
18029
  let add = node2.marks[rendered++];
18027
18030
  let markDOM = this.serializeMark(add, node2.isInline, options);
18028
18031
  if (markDOM) {
18029
- active.push([add, top2]);
18030
- top2.appendChild(markDOM.dom);
18031
- top2 = markDOM.contentDOM || markDOM.dom;
18032
+ active.push([add, top]);
18033
+ top.appendChild(markDOM.dom);
18034
+ top = markDOM.contentDOM || markDOM.dom;
18032
18035
  }
18033
18036
  }
18034
18037
  }
18035
- top2.appendChild(this.serializeNodeInner(node2, options));
18038
+ top.appendChild(this.serializeNodeInner(node2, options));
18036
18039
  });
18037
18040
  return target;
18038
18041
  }
@@ -19393,8 +19396,8 @@ class Fitter {
19393
19396
  mustMoveInline() {
19394
19397
  if (!this.$to.parent.isTextblock)
19395
19398
  return -1;
19396
- let top2 = this.frontier[this.depth], level;
19397
- if (!top2.type.isTextblock || !contentAfterFits(this.$to, this.$to.depth, top2.type, top2.match, false) || this.$to.depth == this.depth && (level = this.findCloseLevel(this.$to)) && level.depth == this.depth)
19399
+ let top = this.frontier[this.depth], level;
19400
+ if (!top.type.isTextblock || !contentAfterFits(this.$to, this.$to.depth, top.type, top.match, false) || this.$to.depth == this.depth && (level = this.findCloseLevel(this.$to)) && level.depth == this.depth)
19398
19401
  return -1;
19399
19402
  let { depth } = this.$to, after = this.$to.after(depth);
19400
19403
  while (depth > 1 && after == this.$to.end(--depth))
@@ -19433,8 +19436,8 @@ class Fitter {
19433
19436
  return $to;
19434
19437
  }
19435
19438
  openFrontierNode(type, attrs = null, content2) {
19436
- let top2 = this.frontier[this.depth];
19437
- top2.match = top2.match.matchType(type);
19439
+ let top = this.frontier[this.depth];
19440
+ top.match = top.match.matchType(type);
19438
19441
  this.placed = addToFragment(this.placed, this.depth, Fragment.from(type.create(attrs, content2)));
19439
19442
  this.frontier.push({ type, match: type.contentMatch });
19440
19443
  }
@@ -21303,8 +21306,8 @@ var Leaf = /* @__PURE__ */ function(RopeSequence3) {
21303
21306
  RopeSequence3.call(this);
21304
21307
  this.values = values;
21305
21308
  }
21306
- Leaf2.__proto__ = RopeSequence3;
21307
- Leaf2.prototype = Object.create(RopeSequence3.prototype);
21309
+ if (RopeSequence3) Leaf2.__proto__ = RopeSequence3;
21310
+ Leaf2.prototype = Object.create(RopeSequence3 && RopeSequence3.prototype);
21308
21311
  Leaf2.prototype.constructor = Leaf2;
21309
21312
  var prototypeAccessors = { length: { configurable: true }, depth: { configurable: true } };
21310
21313
  Leaf2.prototype.flatten = function flatten() {
@@ -21361,8 +21364,8 @@ var Append = /* @__PURE__ */ function(RopeSequence3) {
21361
21364
  this.length = left.length + right.length;
21362
21365
  this.depth = Math.max(left.depth, right.depth) + 1;
21363
21366
  }
21364
- Append2.__proto__ = RopeSequence3;
21365
- Append2.prototype = Object.create(RopeSequence3.prototype);
21367
+ if (RopeSequence3) Append2.__proto__ = RopeSequence3;
21368
+ Append2.prototype = Object.create(RopeSequence3 && RopeSequence3.prototype);
21366
21369
  Append2.prototype.constructor = Append2;
21367
21370
  Append2.prototype.flatten = function flatten() {
21368
21371
  return this.left.flatten().concat(this.right.flatten());
@@ -22194,9 +22197,9 @@ function resetScrollPos({ refDOM, refTop, stack }) {
22194
22197
  }
22195
22198
  function restoreScrollStack(stack, dTop) {
22196
22199
  for (let i = 0; i < stack.length; i++) {
22197
- let { dom, top: top2, left } = stack[i];
22198
- if (dom.scrollTop != top2 + dTop)
22199
- dom.scrollTop = top2 + dTop;
22200
+ let { dom, top, left } = stack[i];
22201
+ if (dom.scrollTop != top + dTop)
22202
+ dom.scrollTop = top + dTop;
22200
22203
  if (dom.scrollLeft != left)
22201
22204
  dom.scrollLeft = left;
22202
22205
  }
@@ -22466,10 +22469,10 @@ function flattenV(rect, left) {
22466
22469
  let x2 = left ? rect.left : rect.right;
22467
22470
  return { top: rect.top, bottom: rect.bottom, left: x2, right: x2 };
22468
22471
  }
22469
- function flattenH(rect, top2) {
22472
+ function flattenH(rect, top) {
22470
22473
  if (rect.height == 0)
22471
22474
  return rect;
22472
- let y2 = top2 ? rect.top : rect.bottom;
22475
+ let y2 = top ? rect.top : rect.bottom;
22473
22476
  return { top: y2, bottom: y2, left: rect.left, right: rect.right };
22474
22477
  }
22475
22478
  function withFlushedState(view, state, f2) {
@@ -23411,25 +23414,25 @@ const noDeco = [new OuterDecoLevel()];
23411
23414
  function computeOuterDeco(outerDeco, node2, needsWrap) {
23412
23415
  if (outerDeco.length == 0)
23413
23416
  return noDeco;
23414
- let top2 = needsWrap ? noDeco[0] : new OuterDecoLevel(), result = [top2];
23417
+ let top = needsWrap ? noDeco[0] : new OuterDecoLevel(), result = [top];
23415
23418
  for (let i = 0; i < outerDeco.length; i++) {
23416
23419
  let attrs = outerDeco[i].type.attrs;
23417
23420
  if (!attrs)
23418
23421
  continue;
23419
23422
  if (attrs.nodeName)
23420
- result.push(top2 = new OuterDecoLevel(attrs.nodeName));
23423
+ result.push(top = new OuterDecoLevel(attrs.nodeName));
23421
23424
  for (let name2 in attrs) {
23422
23425
  let val = attrs[name2];
23423
23426
  if (val == null)
23424
23427
  continue;
23425
23428
  if (needsWrap && result.length == 1)
23426
- result.push(top2 = new OuterDecoLevel(node2.isInline ? "span" : "div"));
23429
+ result.push(top = new OuterDecoLevel(node2.isInline ? "span" : "div"));
23427
23430
  if (name2 == "class")
23428
- top2.class = (top2.class ? top2.class + " " : "") + val;
23431
+ top.class = (top.class ? top.class + " " : "") + val;
23429
23432
  else if (name2 == "style")
23430
- top2.style = (top2.style ? top2.style + ";" : "") + val;
23433
+ top.style = (top.style ? top.style + ";" : "") + val;
23431
23434
  else if (name2 != "nodeName")
23432
- top2[name2] = val;
23435
+ top[name2] = val;
23433
23436
  }
23434
23437
  }
23435
23438
  return result;
@@ -23502,14 +23505,14 @@ function rm(dom) {
23502
23505
  return next;
23503
23506
  }
23504
23507
  class ViewTreeUpdater {
23505
- constructor(top2, lock, view) {
23508
+ constructor(top, lock, view) {
23506
23509
  this.lock = lock;
23507
23510
  this.view = view;
23508
23511
  this.index = 0;
23509
23512
  this.stack = [];
23510
23513
  this.changed = false;
23511
- this.top = top2;
23512
- this.preMatch = preMatch(top2.node.content, top2);
23514
+ this.top = top;
23515
+ this.preMatch = preMatch(top.node.content, top);
23513
23516
  }
23514
23517
  // Destroy and remove the children between the given indices in
23515
23518
  // `this.top`.
@@ -32197,13 +32200,13 @@ function getBoundingClientRect(element2, includeScale, isFixedStrategy, offsetPa
32197
32200
  const iframeRect = currentIFrame.getBoundingClientRect();
32198
32201
  const css2 = getComputedStyle$2(currentIFrame);
32199
32202
  const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css2.paddingLeft)) * iframeScale.x;
32200
- const top2 = iframeRect.top + (currentIFrame.clientTop + parseFloat(css2.paddingTop)) * iframeScale.y;
32203
+ const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css2.paddingTop)) * iframeScale.y;
32201
32204
  x2 *= iframeScale.x;
32202
32205
  y2 *= iframeScale.y;
32203
32206
  width *= iframeScale.x;
32204
32207
  height *= iframeScale.y;
32205
32208
  x2 += left;
32206
- y2 += top2;
32209
+ y2 += top;
32207
32210
  currentWin = getWindow(currentIFrame);
32208
32211
  currentIFrame = currentWin.frameElement;
32209
32212
  }
@@ -32313,13 +32316,13 @@ function getViewportRect(element2, strategy) {
32313
32316
  }
32314
32317
  function getInnerBoundingClientRect(element2, strategy) {
32315
32318
  const clientRect2 = getBoundingClientRect(element2, true, strategy === "fixed");
32316
- const top2 = clientRect2.top + element2.clientTop;
32319
+ const top = clientRect2.top + element2.clientTop;
32317
32320
  const left = clientRect2.left + element2.clientLeft;
32318
32321
  const scale2 = isHTMLElement$1(element2) ? getScale(element2) : createCoords(1);
32319
32322
  const width = element2.clientWidth * scale2.x;
32320
32323
  const height = element2.clientHeight * scale2.y;
32321
32324
  const x2 = left * scale2.x;
32322
- const y2 = top2 * scale2.y;
32325
+ const y2 = top * scale2.y;
32323
32326
  return {
32324
32327
  width,
32325
32328
  height,
@@ -32516,7 +32519,7 @@ function observeMove(element2, onMove) {
32516
32519
  cleanup();
32517
32520
  const {
32518
32521
  left,
32519
- top: top2,
32522
+ top,
32520
32523
  width,
32521
32524
  height
32522
32525
  } = element2.getBoundingClientRect();
@@ -32526,9 +32529,9 @@ function observeMove(element2, onMove) {
32526
32529
  if (!width || !height) {
32527
32530
  return;
32528
32531
  }
32529
- const insetTop = floor(top2);
32532
+ const insetTop = floor(top);
32530
32533
  const insetRight = floor(root2.clientWidth - (left + width));
32531
- const insetBottom = floor(root2.clientHeight - (top2 + height));
32534
+ const insetBottom = floor(root2.clientHeight - (top + height));
32532
32535
  const insetLeft = floor(left);
32533
32536
  const rootMargin = -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px";
32534
32537
  const options = {
@@ -34076,10 +34079,10 @@ function useSelector(actor, selector, compare = defaultCompare) {
34076
34079
  return selectedSnapshot;
34077
34080
  }
34078
34081
  var createRoot;
34079
- var m$2 = reactDomExports;
34082
+ var m$1 = reactDomExports;
34080
34083
  {
34081
- createRoot = m$2.createRoot;
34082
- m$2.hydrateRoot;
34084
+ createRoot = m$1.createRoot;
34085
+ m$1.hydrateRoot;
34083
34086
  }
34084
34087
  const mention = "_mention_1l0qj_1";
34085
34088
  const mentionFocused = "_mention--focused_1l0qj_1";
@@ -36350,16 +36353,16 @@ const $a093c7e1ec25a057$var$TooltipContentImpl = /* @__PURE__ */ forwardRef((pro
36350
36353
  }, ariaLabel || children2))));
36351
36354
  });
36352
36355
  function $a093c7e1ec25a057$var$getExitSideFromRect(point2, rect) {
36353
- const top2 = Math.abs(rect.top - point2.y);
36356
+ const top = Math.abs(rect.top - point2.y);
36354
36357
  const bottom = Math.abs(rect.bottom - point2.y);
36355
36358
  const right = Math.abs(rect.right - point2.x);
36356
36359
  const left = Math.abs(rect.left - point2.x);
36357
- switch (Math.min(top2, bottom, right, left)) {
36360
+ switch (Math.min(top, bottom, right, left)) {
36358
36361
  case left:
36359
36362
  return "left";
36360
36363
  case right:
36361
36364
  return "right";
36362
- case top2:
36365
+ case top:
36363
36366
  return "top";
36364
36367
  case bottom:
36365
36368
  return "bottom";
@@ -36410,15 +36413,15 @@ function $a093c7e1ec25a057$var$getPaddedExitPoints(exitPoint, exitSide, padding
36410
36413
  return paddedExitPoints;
36411
36414
  }
36412
36415
  function $a093c7e1ec25a057$var$getPointsFromRect(rect) {
36413
- const { top: top2, right, bottom, left } = rect;
36416
+ const { top, right, bottom, left } = rect;
36414
36417
  return [
36415
36418
  {
36416
36419
  x: left,
36417
- y: top2
36420
+ y: top
36418
36421
  },
36419
36422
  {
36420
36423
  x: right,
36421
- y: top2
36424
+ y: top
36422
36425
  },
36423
36426
  {
36424
36427
  x: right,
@@ -39070,13 +39073,13 @@ const badgeVariants = cva(
39070
39073
  function Badge({ className, variant, ...props }) {
39071
39074
  return /* @__PURE__ */ jsx("div", { className: cn(badgeVariants({ variant }), className), ...props });
39072
39075
  }
39073
- var U = 1, Y$1 = 0.9, H = 0.8, J = 0.17, p$2 = 0.1, u$1 = 0.999, $ = 0.9999;
39074
- var k$1 = 0.99, m$1 = /[\\\/_+.#"@\[\(\{&]/, B = /[\\\/_+.#"@\[\(\{&]/g, K = /[\s-]/, X$1 = /[\s-]/g;
39076
+ var U = 1, Y$1 = 0.9, H = 0.8, J = 0.17, p$1 = 0.1, u = 0.999, $ = 0.9999;
39077
+ var k$1 = 0.99, m = /[\\\/_+.#"@\[\(\{&]/, B = /[\\\/_+.#"@\[\(\{&]/g, K = /[\s-]/, X$1 = /[\s-]/g;
39075
39078
  function G$1(_2, C2, h2, P2, A2, f2, O2) {
39076
39079
  if (f2 === C2.length) return A2 === _2.length ? U : k$1;
39077
39080
  var T2 = `${A2},${f2}`;
39078
39081
  if (O2[T2] !== void 0) return O2[T2];
39079
- for (var L2 = P2.charAt(f2), c2 = h2.indexOf(L2, A2), S2 = 0, E2, N2, R2, M2; c2 >= 0; ) E2 = G$1(_2, C2, h2, P2, c2 + 1, f2 + 1, O2), E2 > S2 && (c2 === A2 ? E2 *= U : m$1.test(_2.charAt(c2 - 1)) ? (E2 *= H, R2 = _2.slice(A2, c2 - 1).match(B), R2 && A2 > 0 && (E2 *= Math.pow(u$1, R2.length))) : K.test(_2.charAt(c2 - 1)) ? (E2 *= Y$1, M2 = _2.slice(A2, c2 - 1).match(X$1), M2 && A2 > 0 && (E2 *= Math.pow(u$1, M2.length))) : (E2 *= J, A2 > 0 && (E2 *= Math.pow(u$1, c2 - A2))), _2.charAt(c2) !== C2.charAt(f2) && (E2 *= $)), (E2 < p$2 && h2.charAt(c2 - 1) === P2.charAt(f2 + 1) || P2.charAt(f2 + 1) === P2.charAt(f2) && h2.charAt(c2 - 1) !== P2.charAt(f2)) && (N2 = G$1(_2, C2, h2, P2, c2 + 1, f2 + 2, O2), N2 * p$2 > E2 && (E2 = N2 * p$2)), E2 > S2 && (S2 = E2), c2 = h2.indexOf(L2, c2 + 1);
39082
+ for (var L2 = P2.charAt(f2), c2 = h2.indexOf(L2, A2), S2 = 0, E2, N2, R2, M2; c2 >= 0; ) E2 = G$1(_2, C2, h2, P2, c2 + 1, f2 + 1, O2), E2 > S2 && (c2 === A2 ? E2 *= U : m.test(_2.charAt(c2 - 1)) ? (E2 *= H, R2 = _2.slice(A2, c2 - 1).match(B), R2 && A2 > 0 && (E2 *= Math.pow(u, R2.length))) : K.test(_2.charAt(c2 - 1)) ? (E2 *= Y$1, M2 = _2.slice(A2, c2 - 1).match(X$1), M2 && A2 > 0 && (E2 *= Math.pow(u, M2.length))) : (E2 *= J, A2 > 0 && (E2 *= Math.pow(u, c2 - A2))), _2.charAt(c2) !== C2.charAt(f2) && (E2 *= $)), (E2 < p$1 && h2.charAt(c2 - 1) === P2.charAt(f2 + 1) || P2.charAt(f2 + 1) === P2.charAt(f2) && h2.charAt(c2 - 1) !== P2.charAt(f2)) && (N2 = G$1(_2, C2, h2, P2, c2 + 1, f2 + 2, O2), N2 * p$1 > E2 && (E2 = N2 * p$1)), E2 > S2 && (S2 = E2), c2 = h2.indexOf(L2, c2 + 1);
39080
39083
  return O2[T2] = S2, S2;
39081
39084
  }
39082
39085
  function D$1(_2) {
@@ -39652,9 +39655,9 @@ var parse$1 = function(x2) {
39652
39655
  var getOffset = function(gapMode) {
39653
39656
  var cs2 = window.getComputedStyle(document.body);
39654
39657
  var left = cs2[gapMode === "padding" ? "paddingLeft" : "marginLeft"];
39655
- var top2 = cs2[gapMode === "padding" ? "paddingTop" : "marginTop"];
39658
+ var top = cs2[gapMode === "padding" ? "paddingTop" : "marginTop"];
39656
39659
  var right = cs2[gapMode === "padding" ? "paddingRight" : "marginRight"];
39657
- return [parse$1(left), parse$1(top2), parse$1(right)];
39660
+ return [parse$1(left), parse$1(top), parse$1(right)];
39658
39661
  };
39659
39662
  var getGapWidth = function(gapMode) {
39660
39663
  if (gapMode === void 0) {
@@ -39676,13 +39679,13 @@ var getGapWidth = function(gapMode) {
39676
39679
  var Style = styleSingleton();
39677
39680
  var lockAttribute = "data-scroll-locked";
39678
39681
  var getStyles = function(_a2, allowRelative, gapMode, important) {
39679
- var left = _a2.left, top2 = _a2.top, right = _a2.right, gap = _a2.gap;
39682
+ var left = _a2.left, top = _a2.top, right = _a2.right, gap = _a2.gap;
39680
39683
  if (gapMode === void 0) {
39681
39684
  gapMode = "margin";
39682
39685
  }
39683
39686
  return "\n .".concat(noScrollbarsClassName, " {\n overflow: hidden ").concat(important, ";\n padding-right: ").concat(gap, "px ").concat(important, ";\n }\n body[").concat(lockAttribute, "] {\n overflow: hidden ").concat(important, ";\n overscroll-behavior: contain;\n ").concat([
39684
39687
  allowRelative && "position: relative ".concat(important, ";"),
39685
- gapMode === "margin" && "\n padding-left: ".concat(left, "px;\n padding-top: ").concat(top2, "px;\n padding-right: ").concat(right, "px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(gap, "px ").concat(important, ";\n "),
39688
+ gapMode === "margin" && "\n padding-left: ".concat(left, "px;\n padding-top: ").concat(top, "px;\n padding-right: ").concat(right, "px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(gap, "px ").concat(important, ";\n "),
39686
39689
  gapMode === "padding" && "padding-right: ".concat(gap, "px ").concat(important, ";")
39687
39690
  ].filter(Boolean).join(""), "\n }\n \n .").concat(zeroRightClassName, " {\n right: ").concat(gap, "px ").concat(important, ";\n }\n \n .").concat(fullWidthClassName, " {\n margin-right: ").concat(gap, "px ").concat(important, ";\n }\n \n .").concat(zeroRightClassName, " .").concat(zeroRightClassName, " {\n right: 0 ").concat(important, ";\n }\n \n .").concat(fullWidthClassName, " .").concat(fullWidthClassName, " {\n margin-right: 0 ").concat(important, ";\n }\n \n body[").concat(lockAttribute, "] {\n ").concat(removedBarSizeVariable, ": ").concat(gap, "px;\n }\n");
39688
39691
  };
@@ -51476,7 +51479,7 @@ function bash(hljs) {
51476
51479
  ]
51477
51480
  };
51478
51481
  }
51479
- function c$1(hljs) {
51482
+ function c(hljs) {
51480
51483
  const regex = hljs.regex;
51481
51484
  const C_LINE_COMMENT_MODE2 = hljs.COMMENT("//", "$", { contains: [{ begin: /\\\n/ }] });
51482
51485
  const DECLTYPE_AUTO_RE = "decltype\\(auto\\)";
@@ -62436,7 +62439,7 @@ function deepFreeze(obj) {
62436
62439
  });
62437
62440
  return obj;
62438
62441
  }
62439
- let Response$1 = class Response2 {
62442
+ class Response {
62440
62443
  /**
62441
62444
  * @param {CompiledMode} mode
62442
62445
  */
@@ -62448,7 +62451,7 @@ let Response$1 = class Response2 {
62448
62451
  ignoreMatch() {
62449
62452
  this.isMatchIgnored = true;
62450
62453
  }
62451
- };
62454
+ }
62452
62455
  function escapeHTML(value) {
62453
62456
  return value.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#x27;");
62454
62457
  }
@@ -63391,18 +63394,18 @@ const HLJS = function(hljs) {
63391
63394
  return mode.keywords[matchText];
63392
63395
  }
63393
63396
  function processKeywords() {
63394
- if (!top2.keywords) {
63397
+ if (!top.keywords) {
63395
63398
  emitter.addText(modeBuffer);
63396
63399
  return;
63397
63400
  }
63398
63401
  let lastIndex = 0;
63399
- top2.keywordPatternRe.lastIndex = 0;
63400
- let match = top2.keywordPatternRe.exec(modeBuffer);
63402
+ top.keywordPatternRe.lastIndex = 0;
63403
+ let match = top.keywordPatternRe.exec(modeBuffer);
63401
63404
  let buf = "";
63402
63405
  while (match) {
63403
63406
  buf += modeBuffer.substring(lastIndex, match.index);
63404
63407
  const word = language2.case_insensitive ? match[0].toLowerCase() : match[0];
63405
- const data = keywordData(top2, word);
63408
+ const data = keywordData(top, word);
63406
63409
  if (data) {
63407
63410
  const [kind, keywordRelevance] = data;
63408
63411
  emitter.addText(buf);
@@ -63418,8 +63421,8 @@ const HLJS = function(hljs) {
63418
63421
  } else {
63419
63422
  buf += match[0];
63420
63423
  }
63421
- lastIndex = top2.keywordPatternRe.lastIndex;
63422
- match = top2.keywordPatternRe.exec(modeBuffer);
63424
+ lastIndex = top.keywordPatternRe.lastIndex;
63425
+ match = top.keywordPatternRe.exec(modeBuffer);
63423
63426
  }
63424
63427
  buf += modeBuffer.substring(lastIndex);
63425
63428
  emitter.addText(buf);
@@ -63427,24 +63430,24 @@ const HLJS = function(hljs) {
63427
63430
  function processSubLanguage() {
63428
63431
  if (modeBuffer === "") return;
63429
63432
  let result2 = null;
63430
- if (typeof top2.subLanguage === "string") {
63431
- if (!languages[top2.subLanguage]) {
63433
+ if (typeof top.subLanguage === "string") {
63434
+ if (!languages[top.subLanguage]) {
63432
63435
  emitter.addText(modeBuffer);
63433
63436
  return;
63434
63437
  }
63435
- result2 = _highlight(top2.subLanguage, modeBuffer, true, continuations[top2.subLanguage]);
63436
- continuations[top2.subLanguage] = /** @type {CompiledMode} */
63438
+ result2 = _highlight(top.subLanguage, modeBuffer, true, continuations[top.subLanguage]);
63439
+ continuations[top.subLanguage] = /** @type {CompiledMode} */
63437
63440
  result2._top;
63438
63441
  } else {
63439
- result2 = highlightAuto2(modeBuffer, top2.subLanguage.length ? top2.subLanguage : null);
63442
+ result2 = highlightAuto2(modeBuffer, top.subLanguage.length ? top.subLanguage : null);
63440
63443
  }
63441
- if (top2.relevance > 0) {
63444
+ if (top.relevance > 0) {
63442
63445
  relevance += result2.relevance;
63443
63446
  }
63444
63447
  emitter.__addSublanguage(result2._emitter, result2.language);
63445
63448
  }
63446
63449
  function processBuffer() {
63447
- if (top2.subLanguage != null) {
63450
+ if (top.subLanguage != null) {
63448
63451
  processSubLanguage();
63449
63452
  } else {
63450
63453
  processKeywords();
@@ -63490,14 +63493,14 @@ const HLJS = function(hljs) {
63490
63493
  modeBuffer = "";
63491
63494
  }
63492
63495
  }
63493
- top2 = Object.create(mode, { parent: { value: top2 } });
63494
- return top2;
63496
+ top = Object.create(mode, { parent: { value: top } });
63497
+ return top;
63495
63498
  }
63496
63499
  function endOfMode(mode, match, matchPlusRemainder) {
63497
63500
  let matched = startsWith(mode.endRe, matchPlusRemainder);
63498
63501
  if (matched) {
63499
63502
  if (mode["on:end"]) {
63500
- const resp = new Response$1(mode);
63503
+ const resp = new Response(mode);
63501
63504
  mode["on:end"](match, resp);
63502
63505
  if (resp.isMatchIgnored) matched = false;
63503
63506
  }
@@ -63513,7 +63516,7 @@ const HLJS = function(hljs) {
63513
63516
  }
63514
63517
  }
63515
63518
  function doIgnore(lexeme) {
63516
- if (top2.matcher.regexIndex === 0) {
63519
+ if (top.matcher.regexIndex === 0) {
63517
63520
  modeBuffer += lexeme[0];
63518
63521
  return 1;
63519
63522
  } else {
@@ -63524,7 +63527,7 @@ const HLJS = function(hljs) {
63524
63527
  function doBeginMatch(match) {
63525
63528
  const lexeme = match[0];
63526
63529
  const newMode = match.rule;
63527
- const resp = new Response$1(newMode);
63530
+ const resp = new Response(newMode);
63528
63531
  const beforeCallbacks = [newMode.__beforeBegin, newMode["on:begin"]];
63529
63532
  for (const cb2 of beforeCallbacks) {
63530
63533
  if (!cb2) continue;
@@ -63548,17 +63551,17 @@ const HLJS = function(hljs) {
63548
63551
  function doEndMatch(match) {
63549
63552
  const lexeme = match[0];
63550
63553
  const matchPlusRemainder = codeToHighlight.substring(match.index);
63551
- const endMode = endOfMode(top2, match, matchPlusRemainder);
63554
+ const endMode = endOfMode(top, match, matchPlusRemainder);
63552
63555
  if (!endMode) {
63553
63556
  return NO_MATCH;
63554
63557
  }
63555
- const origin = top2;
63556
- if (top2.endScope && top2.endScope._wrap) {
63558
+ const origin = top;
63559
+ if (top.endScope && top.endScope._wrap) {
63557
63560
  processBuffer();
63558
- emitKeyword(lexeme, top2.endScope._wrap);
63559
- } else if (top2.endScope && top2.endScope._multi) {
63561
+ emitKeyword(lexeme, top.endScope._wrap);
63562
+ } else if (top.endScope && top.endScope._multi) {
63560
63563
  processBuffer();
63561
- emitMultiClass(top2.endScope, match);
63564
+ emitMultiClass(top.endScope, match);
63562
63565
  } else if (origin.skip) {
63563
63566
  modeBuffer += lexeme;
63564
63567
  } else {
@@ -63571,14 +63574,14 @@ const HLJS = function(hljs) {
63571
63574
  }
63572
63575
  }
63573
63576
  do {
63574
- if (top2.scope) {
63577
+ if (top.scope) {
63575
63578
  emitter.closeNode();
63576
63579
  }
63577
- if (!top2.skip && !top2.subLanguage) {
63578
- relevance += top2.relevance;
63580
+ if (!top.skip && !top.subLanguage) {
63581
+ relevance += top.relevance;
63579
63582
  }
63580
- top2 = top2.parent;
63581
- } while (top2 !== endMode.parent);
63583
+ top = top.parent;
63584
+ } while (top !== endMode.parent);
63582
63585
  if (endMode.starts) {
63583
63586
  startNewMode(endMode.starts, match);
63584
63587
  }
@@ -63586,7 +63589,7 @@ const HLJS = function(hljs) {
63586
63589
  }
63587
63590
  function processContinuations() {
63588
63591
  const list2 = [];
63589
- for (let current = top2; current !== language2; current = current.parent) {
63592
+ for (let current = top; current !== language2; current = current.parent) {
63590
63593
  if (current.scope) {
63591
63594
  list2.unshift(current.scope);
63592
63595
  }
@@ -63615,8 +63618,8 @@ const HLJS = function(hljs) {
63615
63618
  if (match.type === "begin") {
63616
63619
  return doBeginMatch(match);
63617
63620
  } else if (match.type === "illegal" && !ignoreIllegals) {
63618
- const err = new Error('Illegal lexeme "' + lexeme + '" for mode "' + (top2.scope || "<unnamed>") + '"');
63619
- err.mode = top2;
63621
+ const err = new Error('Illegal lexeme "' + lexeme + '" for mode "' + (top.scope || "<unnamed>") + '"');
63622
+ err.mode = top;
63620
63623
  throw err;
63621
63624
  } else if (match.type === "end") {
63622
63625
  const processed = doEndMatch(match);
@@ -63641,7 +63644,7 @@ const HLJS = function(hljs) {
63641
63644
  }
63642
63645
  const md2 = compileLanguage(language2);
63643
63646
  let result = "";
63644
- let top2 = continuation || md2;
63647
+ let top = continuation || md2;
63645
63648
  const continuations = {};
63646
63649
  const emitter = new options.__emitter(options);
63647
63650
  processContinuations();
@@ -63652,16 +63655,16 @@ const HLJS = function(hljs) {
63652
63655
  let resumeScanAtSamePosition = false;
63653
63656
  try {
63654
63657
  if (!language2.__emitTokens) {
63655
- top2.matcher.considerAll();
63658
+ top.matcher.considerAll();
63656
63659
  for (; ; ) {
63657
63660
  iterations++;
63658
63661
  if (resumeScanAtSamePosition) {
63659
63662
  resumeScanAtSamePosition = false;
63660
63663
  } else {
63661
- top2.matcher.considerAll();
63664
+ top.matcher.considerAll();
63662
63665
  }
63663
- top2.matcher.lastIndex = index2;
63664
- const match = top2.matcher.exec(codeToHighlight);
63666
+ top.matcher.lastIndex = index2;
63667
+ const match = top.matcher.exec(codeToHighlight);
63665
63668
  if (!match) break;
63666
63669
  const beforeMatch = codeToHighlight.substring(index2, match.index);
63667
63670
  const processedCount = processLexeme(beforeMatch, match);
@@ -63679,7 +63682,7 @@ const HLJS = function(hljs) {
63679
63682
  relevance,
63680
63683
  illegal: false,
63681
63684
  _emitter: emitter,
63682
- _top: top2
63685
+ _top: top
63683
63686
  };
63684
63687
  } catch (err) {
63685
63688
  if (err.message && err.message.includes("Illegal")) {
@@ -63705,7 +63708,7 @@ const HLJS = function(hljs) {
63705
63708
  relevance: 0,
63706
63709
  errorRaised: err,
63707
63710
  _emitter: emitter,
63708
- _top: top2
63711
+ _top: top
63709
63712
  };
63710
63713
  } else {
63711
63714
  throw err;
@@ -64241,7 +64244,7 @@ const lowlight = {
64241
64244
  };
64242
64245
  lowlight.registerLanguage("arduino", arduino);
64243
64246
  lowlight.registerLanguage("bash", bash);
64244
- lowlight.registerLanguage("c", c$1);
64247
+ lowlight.registerLanguage("c", c);
64245
64248
  lowlight.registerLanguage("cpp", cpp);
64246
64249
  lowlight.registerLanguage("csharp", csharp);
64247
64250
  lowlight.registerLanguage("css", css);
@@ -64448,7 +64451,7 @@ const findAfter = (
64448
64451
  const searchLineFeeds = /\n/g;
64449
64452
  const searchTabOrSpaces = /[\t ]+/g;
64450
64453
  const br = convertElement("br");
64451
- const p$1 = convertElement("p");
64454
+ const p = convertElement("p");
64452
64455
  const cell = convertElement(["th", "td"]);
64453
64456
  const row = convertElement("tr");
64454
64457
  const notRendered = convertElement([
@@ -64617,7 +64620,7 @@ function collectElement(node2, parent, info) {
64617
64620
  suffix = "\n";
64618
64621
  } else if (row(node2) && findAfter(parent, node2, row)) {
64619
64622
  suffix = "\n";
64620
- } else if (p$1(node2)) {
64623
+ } else if (p(node2)) {
64621
64624
  prefix = 2;
64622
64625
  suffix = 2;
64623
64626
  } else if (blockOrCaption(node2)) {
@@ -65391,7 +65394,7 @@ function escapeStringRegexp(string2) {
65391
65394
  return string2.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
65392
65395
  }
65393
65396
  function findAndReplace(tree, list2, options) {
65394
- const settings = options;
65397
+ const settings = options || {};
65395
65398
  const ignored = convert$1(settings.ignore || []);
65396
65399
  const pairs = toPairs(list2);
65397
65400
  let pairIndex = -1;
@@ -66756,7 +66759,7 @@ function replace($0, $1) {
66756
66759
  return $1 === "|" ? $1 : $0;
66757
66760
  }
66758
66761
  function gfmTableToMarkdown(options) {
66759
- const settings = options;
66762
+ const settings = options || {};
66760
66763
  const padding = settings.tableCellPadding;
66761
66764
  const alignDelimiters = settings.tablePipeAlign;
66762
66765
  const stringLength = settings.stringLength;
@@ -67565,7 +67568,7 @@ function tokenizeIndent(effects, ok2, nok) {
67565
67568
  }
67566
67569
  }
67567
67570
  function gfmStrikethrough(options) {
67568
- const options_ = options;
67571
+ const options_ = options || {};
67569
67572
  let single = options_.singleTilde;
67570
67573
  const tokenizer = {
67571
67574
  tokenize: tokenizeStrikethrough,
@@ -71347,7 +71350,7 @@ function vhdl(hljs) {
71347
71350
  const SYNTAX_HIGHLIGHTING_LANGUAGES = {
71348
71351
  arduino,
71349
71352
  bash,
71350
- c: c$1,
71353
+ c,
71351
71354
  clojure,
71352
71355
  cpp,
71353
71356
  csharp,
@@ -72668,7 +72671,7 @@ function PopChild({ children: children2, isPresent, anchorX }) {
72668
72671
  });
72669
72672
  const { nonce } = useContext(MotionConfigContext);
72670
72673
  useInsertionEffect$1(() => {
72671
- const { width, height, top: top2, left, right } = size2.current;
72674
+ const { width, height, top, left, right } = size2.current;
72672
72675
  if (isPresent || !ref.current || !width || !height)
72673
72676
  return;
72674
72677
  const x2 = anchorX === "left" ? `left: ${left}` : `right: ${right}`;
@@ -72684,7 +72687,7 @@ function PopChild({ children: children2, isPresent, anchorX }) {
72684
72687
  width: ${width}px !important;
72685
72688
  height: ${height}px !important;
72686
72689
  ${x2}px !important;
72687
- top: ${top2}px !important;
72690
+ top: ${top}px !important;
72688
72691
  }
72689
72692
  `);
72690
72693
  }
@@ -73059,6 +73062,10 @@ const stepsOrder = [
73059
73062
  "postRender"
73060
73063
  // Compute
73061
73064
  ];
73065
+ const statsBuffer = {
73066
+ value: null,
73067
+ addProjectionMetrics: null
73068
+ };
73062
73069
  function createRenderStep(runNextFrame, stepName) {
73063
73070
  let thisFrame = /* @__PURE__ */ new Set();
73064
73071
  let nextFrame = /* @__PURE__ */ new Set();
@@ -73070,11 +73077,13 @@ function createRenderStep(runNextFrame, stepName) {
73070
73077
  timestamp: 0,
73071
73078
  isProcessing: false
73072
73079
  };
73080
+ let numCalls = 0;
73073
73081
  function triggerCallback(callback) {
73074
73082
  if (toKeepAlive.has(callback)) {
73075
73083
  step.schedule(callback);
73076
73084
  runNextFrame();
73077
73085
  }
73086
+ numCalls++;
73078
73087
  callback(latestFrameData);
73079
73088
  }
73080
73089
  const step = {
@@ -73109,6 +73118,10 @@ function createRenderStep(runNextFrame, stepName) {
73109
73118
  isProcessing = true;
73110
73119
  [thisFrame, nextFrame] = [nextFrame, thisFrame];
73111
73120
  thisFrame.forEach(triggerCallback);
73121
+ if (stepName && statsBuffer.value) {
73122
+ statsBuffer.value.frameloop[stepName].push(numCalls);
73123
+ }
73124
+ numCalls = 0;
73112
73125
  thisFrame.clear();
73113
73126
  isProcessing = false;
73114
73127
  if (flushNextFrame) {
@@ -73130,7 +73143,7 @@ function createRenderBatcher(scheduleNextBatch, allowKeepAlive) {
73130
73143
  };
73131
73144
  const flagRunNextFrame = () => runNextFrame = true;
73132
73145
  const steps = stepsOrder.reduce((acc, key) => {
73133
- acc[key] = createRenderStep(flagRunNextFrame);
73146
+ acc[key] = createRenderStep(flagRunNextFrame, allowKeepAlive ? key : void 0);
73134
73147
  return acc;
73135
73148
  }, {});
73136
73149
  const { read, resolveKeyframes, update: update2, preRender, render, postRender } = steps;
@@ -75027,9 +75040,9 @@ const positionalValues = {
75027
75040
  // Dimensions
75028
75041
  width: ({ x: x2 }, { paddingLeft = "0", paddingRight = "0" }) => x2.max - x2.min - parseFloat(paddingLeft) - parseFloat(paddingRight),
75029
75042
  height: ({ y: y2 }, { paddingTop = "0", paddingBottom = "0" }) => y2.max - y2.min - parseFloat(paddingTop) - parseFloat(paddingBottom),
75030
- top: (_bbox, { top: top2 }) => parseFloat(top2),
75043
+ top: (_bbox, { top }) => parseFloat(top),
75031
75044
  left: (_bbox, { left }) => parseFloat(left),
75032
- bottom: ({ y: y2 }, { top: top2 }) => parseFloat(top2) + (y2.max - y2.min),
75045
+ bottom: ({ y: y2 }, { top }) => parseFloat(top) + (y2.max - y2.min),
75033
75046
  right: ({ x: x2 }, { left }) => parseFloat(left) + (x2.max - x2.min),
75034
75047
  // Transform
75035
75048
  x: (_bbox, { transform: transform2 }) => parseValueFromTransform(transform2, "x"),
@@ -77004,10 +77017,10 @@ const addPointerInfo = (handler) => {
77004
77017
  function addPointerEvent(target, eventName, handler, options) {
77005
77018
  return addDomEvent(target, eventName, addPointerInfo(handler), options);
77006
77019
  }
77007
- function convertBoundingBoxToBox({ top: top2, left, right, bottom }) {
77020
+ function convertBoundingBoxToBox({ top, left, right, bottom }) {
77008
77021
  return {
77009
77022
  x: { min: left, max: right },
77010
- y: { min: top2, max: bottom }
77023
+ y: { min: top, max: bottom }
77011
77024
  };
77012
77025
  }
77013
77026
  function convertBoxToBoundingBox({ x: x2, y: y2 }) {
@@ -77325,10 +77338,10 @@ function calcRelativeAxisConstraints(axis, min2, max2) {
77325
77338
  max: max2 !== void 0 ? axis.max + max2 - (axis.max - axis.min) : void 0
77326
77339
  };
77327
77340
  }
77328
- function calcRelativeConstraints(layoutBox, { top: top2, left, bottom, right }) {
77341
+ function calcRelativeConstraints(layoutBox, { top, left, bottom, right }) {
77329
77342
  return {
77330
77343
  x: calcRelativeAxisConstraints(layoutBox.x, left, right),
77331
- y: calcRelativeAxisConstraints(layoutBox.y, top2, bottom)
77344
+ y: calcRelativeAxisConstraints(layoutBox.y, top, bottom)
77332
77345
  };
77333
77346
  }
77334
77347
  function calcViewportAxisConstraints(layoutAxis, constraintsAxis) {
@@ -77571,7 +77584,7 @@ class VisualElementDragControls {
77571
77584
  if (!shouldDrag(axis, drag2, this.currentDirection)) {
77572
77585
  return;
77573
77586
  }
77574
- let transition = constraints[axis] || {};
77587
+ let transition = constraints && constraints[axis] || {};
77575
77588
  if (dragSnapToOrigin)
77576
77589
  transition = { min: 0, max: 0 };
77577
77590
  const bounceStiffness = dragElastic ? 200 : 1e6;
@@ -83248,12 +83261,11 @@ const INTENT_MAPPING = {
83248
83261
  };
83249
83262
  const ModeSelectorField = ({ className, _intent = "chat", manuallySelectIntent }) => {
83250
83263
  const {
83251
- clientCapabilities: { edit },
83252
- config
83264
+ clientCapabilities: { edit }
83253
83265
  } = useConfig();
83266
+ const agenticChatEnabled = useFeatureFlag(FeatureFlag.NextAgenticChatInternal);
83254
83267
  const intentOptions = useMemo$1(() => {
83255
83268
  const isEditEnabled = edit !== "none";
83256
- const agenticChatEnabled = !!(config == null ? void 0 : config.experimentalAgenticChatEnabled);
83257
83269
  return [
83258
83270
  {
83259
83271
  title: "Chat",
@@ -83283,21 +83295,32 @@ const ModeSelectorField = ({ className, _intent = "chat", manuallySelectIntent }
83283
83295
  /* Agentic */
83284
83296
  }
83285
83297
  ].filter((option) => !option.hidden);
83286
- }, [edit, config == null ? void 0 : config.experimentalAgenticChatEnabled]);
83298
+ }, [edit, agenticChatEnabled]);
83287
83299
  const availableOptions = useMemo$1(
83288
83300
  () => intentOptions.filter((option) => !option.disabled),
83289
83301
  [intentOptions]
83290
83302
  );
83291
- const [currentSelectedIntent, setCurrentSelectedIntent] = useState$1(() => {
83303
+ const [currentSelectedIntent, setCurrentSelectedIntent] = useState$1(
83304
+ "Chat"
83305
+ /* Chat */
83306
+ );
83307
+ useEffect$2(() => {
83292
83308
  const mappedIntent = INTENT_MAPPING[_intent || "chat"];
83293
- if (_intent === "agentic" && !(config == null ? void 0 : config.experimentalAgenticChatEnabled)) {
83294
- return "Chat";
83309
+ if (_intent === "agentic" && !agenticChatEnabled) {
83310
+ setCurrentSelectedIntent(
83311
+ "Chat"
83312
+ /* Chat */
83313
+ );
83314
+ return;
83295
83315
  }
83296
83316
  const isValidIntent = intentOptions.some(
83297
83317
  (option) => option.value === mappedIntent && !option.disabled
83298
83318
  );
83299
- return isValidIntent ? mappedIntent : "Chat";
83300
- });
83319
+ setCurrentSelectedIntent(
83320
+ isValidIntent ? mappedIntent : "Chat"
83321
+ /* Chat */
83322
+ );
83323
+ }, [_intent, agenticChatEnabled, intentOptions]);
83301
83324
  const handleSelectIntent = useCallback(
83302
83325
  (intent, close2) => {
83303
83326
  manuallySelectIntent(intent);
@@ -83311,21 +83334,6 @@ const ModeSelectorField = ({ className, _intent = "chat", manuallySelectIntent }
83311
83334
  );
83312
83335
  useEffect$2(() => {
83313
83336
  if (availableOptions.length <= 1) return;
83314
- if (_intent === "agentic" && !(config == null ? void 0 : config.experimentalAgenticChatEnabled)) {
83315
- if (currentSelectedIntent !== "Chat") {
83316
- setCurrentSelectedIntent(
83317
- "Chat"
83318
- /* Chat */
83319
- );
83320
- }
83321
- return;
83322
- }
83323
- if (INTENT_MAPPING[_intent || "chat"] !== currentSelectedIntent) {
83324
- setCurrentSelectedIntent(
83325
- INTENT_MAPPING[_intent || "chat"] || "Chat"
83326
- /* Chat */
83327
- );
83328
- }
83329
83337
  const handleKeyDown = (event) => {
83330
83338
  if ((isMac ? event.metaKey : event.ctrlKey) && event.key === ".") {
83331
83339
  event.preventDefault();
@@ -83338,13 +83346,7 @@ const ModeSelectorField = ({ className, _intent = "chat", manuallySelectIntent }
83338
83346
  };
83339
83347
  document.addEventListener("keydown", handleKeyDown);
83340
83348
  return () => document.removeEventListener("keydown", handleKeyDown);
83341
- }, [
83342
- availableOptions,
83343
- currentSelectedIntent,
83344
- handleSelectIntent,
83345
- _intent,
83346
- config == null ? void 0 : config.experimentalAgenticChatEnabled
83347
- ]);
83349
+ }, [availableOptions, currentSelectedIntent, handleSelectIntent]);
83348
83350
  return /* @__PURE__ */ jsx(
83349
83351
  ToolbarPopoverItem,
83350
83352
  {
@@ -83642,9 +83644,6 @@ const HumanMessageEditor = ({
83642
83644
  },
83643
83645
  [submitState, parentOnSubmit, onStop, telemetryRecorder.recordEvent, isFirstMessage, isSent]
83644
83646
  );
83645
- const {
83646
- config: { experimentalPromptEditorEnabled }
83647
- } = useConfig();
83648
83647
  const onEditorEnterKey = useCallback(
83649
83648
  (event) => {
83650
83649
  if (!event || event.isComposing || isEmptyEditorValue || event.shiftKey) {
@@ -83797,7 +83796,7 @@ const HumanMessageEditor = ({
83797
83796
  const defaultContext = useDefaultContextForChat();
83798
83797
  useEffect$2(() => {
83799
83798
  var _a3;
83800
- if (isSent || !isFirstMessage || !(editorRef == null ? void 0 : editorRef.current) || selectedIntent === "agentic") {
83799
+ if (isSent || !isFirstMessage || !(editorRef == null ? void 0 : editorRef.current)) {
83801
83800
  return;
83802
83801
  }
83803
83802
  const editor2 = editorRef.current;
@@ -83808,7 +83807,7 @@ const HumanMessageEditor = ({
83808
83807
  const filteredItems = defaultContext == null ? void 0 : defaultContext.initialContext.filter(
83809
83808
  (item2) => !excludedTypes.has(item2.type)
83810
83809
  );
83811
- void editor2.setInitialContextMentions(filteredItems);
83810
+ void editor2.setInitialContextMentions(selectedIntent === "agentic" ? [] : filteredItems);
83812
83811
  }, [defaultContext == null ? void 0 : defaultContext.initialContext, isSent, isFirstMessage, currentChatModel, selectedIntent]);
83813
83812
  const focusEditor = useCallback(() => {
83814
83813
  var _a3;
@@ -83826,7 +83825,7 @@ const HumanMessageEditor = ({
83826
83825
  (uri) => linkOpener == null ? void 0 : linkOpener.openExternalLink(uri),
83827
83826
  [linkOpener]
83828
83827
  );
83829
- const Editor = experimentalPromptEditorEnabled ? PromptEditor : PromptEditor$1;
83828
+ const Editor = useFeatureFlag(FeatureFlag.CodyExperimentalPromptEditor) ? PromptEditor : PromptEditor$1;
83830
83829
  const onMediaUpload = useCallback(
83831
83830
  (media) => {
83832
83831
  const editor2 = editorRef == null ? void 0 : editorRef.current;
@@ -86628,44 +86627,50 @@ const TranscriptInteraction = memo$2((props) => {
86628
86627
  const onUserAction = useCallback(
86629
86628
  (action, manuallySelectedIntent) => {
86630
86629
  var _a2, _b;
86631
- const startMark = performance.mark("startSubmit");
86632
- const spanManager2 = new SpanManager("cody-webview");
86633
- const span = spanManager2.startSpan("chat-interaction", {
86634
- attributes: {
86635
- sampled: true,
86636
- "render.state": "started",
86637
- "startSubmit.mark": startMark.startTime
86630
+ try {
86631
+ const startMark = performance.mark("startSubmit");
86632
+ const spanManager2 = new SpanManager("cody-webview");
86633
+ const span = spanManager2.startSpan("chat-interaction", {
86634
+ attributes: {
86635
+ sampled: true,
86636
+ "render.state": "started",
86637
+ "startSubmit.mark": startMark.startTime
86638
+ }
86639
+ });
86640
+ if (!span) {
86641
+ throw new Error("Failed to start span for chat interaction");
86642
+ }
86643
+ const spanContext = trace.setSpan(context$1.active(), span);
86644
+ setActiveChatContext(spanContext);
86645
+ const currentSpanContext = span.spanContext();
86646
+ const traceparent = getTraceparentFromSpanContext(currentSpanContext);
86647
+ const editorValue = (_a2 = humanEditorRef.current) == null ? void 0 : _a2.getSerializedValue();
86648
+ if (!editorValue) {
86649
+ console.error("Failed to serialize editor value");
86650
+ return;
86638
86651
  }
86639
- });
86640
- if (!span) {
86641
- throw new Error("Failed to start span for chat interaction");
86642
- }
86643
- const spanContext = trace.setSpan(context$1.active(), span);
86644
- setActiveChatContext(spanContext);
86645
- const currentSpanContext = span.spanContext();
86646
- const traceparent = getTraceparentFromSpanContext(currentSpanContext);
86647
- const editorValue = (_a2 = humanEditorRef.current) == null ? void 0 : _a2.getSerializedValue();
86648
- if (!editorValue) {
86649
- console.error("Failed to serialize editor value");
86650
- return;
86651
- }
86652
- const commonProps = {
86653
- editorValue,
86654
- traceparent,
86655
- manuallySelectedIntent
86656
- };
86657
- if (action === "edit") {
86658
- if (isLastSentInteraction) {
86659
- (_b = lastEditorRef.current) == null ? void 0 : _b.filterMentions((item2) => !isCodeSearchContextItem(item2));
86652
+ const commonProps = {
86653
+ editorValue,
86654
+ traceparent,
86655
+ manuallySelectedIntent
86656
+ };
86657
+ if (action === "edit") {
86658
+ if (isLastSentInteraction) {
86659
+ (_b = lastEditorRef.current) == null ? void 0 : _b.filterMentions((item2) => !isCodeSearchContextItem(item2));
86660
+ }
86661
+ console.log("[Cody] editHumanMessage call");
86662
+ editHumanMessage({
86663
+ messageIndexInTranscript: humanMessage.index,
86664
+ ...commonProps
86665
+ });
86666
+ } else {
86667
+ console.log("[Cody] submitHumanMessage call");
86668
+ submitHumanMessage({
86669
+ ...commonProps
86670
+ });
86660
86671
  }
86661
- editHumanMessage({
86662
- messageIndexInTranscript: humanMessage.index,
86663
- ...commonProps
86664
- });
86665
- } else {
86666
- submitHumanMessage({
86667
- ...commonProps
86668
- });
86672
+ } catch (error2) {
86673
+ console.log("[Cody] onUserAction error", error2);
86669
86674
  }
86670
86675
  },
86671
86676
  [humanMessage, setActiveChatContext, isLastSentInteraction, lastEditorRef]
@@ -87129,158 +87134,6 @@ const Chat = ({
87129
87134
  )
87130
87135
  ] });
87131
87136
  };
87132
- const e = (() => {
87133
- if ("undefined" == typeof self) return false;
87134
- if ("top" in self && self !== top) try {
87135
- top.window.document._ = 0;
87136
- } catch (e2) {
87137
- return false;
87138
- }
87139
- return "showOpenFilePicker" in self;
87140
- })();
87141
- e ? Promise.resolve().then(function() {
87142
- return c;
87143
- }) : Promise.resolve().then(function() {
87144
- return h;
87145
- });
87146
- e ? Promise.resolve().then(function() {
87147
- return y;
87148
- }) : Promise.resolve().then(function() {
87149
- return b;
87150
- });
87151
- const a = e ? Promise.resolve().then(function() {
87152
- return m;
87153
- }) : Promise.resolve().then(function() {
87154
- return _;
87155
- });
87156
- async function o(...e2) {
87157
- return (await a).default(...e2);
87158
- }
87159
- const s = async (e2) => {
87160
- const t2 = await e2.getFile();
87161
- return t2.handle = e2, t2;
87162
- };
87163
- var l = async (e2 = [{}]) => {
87164
- Array.isArray(e2) || (e2 = [e2]);
87165
- const t2 = [];
87166
- e2.forEach((e3, n3) => {
87167
- t2[n3] = { description: e3.description || "Files", accept: {} }, e3.mimeTypes ? e3.mimeTypes.map((r3) => {
87168
- t2[n3].accept[r3] = e3.extensions || [];
87169
- }) : t2[n3].accept["*/*"] = e3.extensions || [];
87170
- });
87171
- const n2 = await window.showOpenFilePicker({ id: e2[0].id, startIn: e2[0].startIn, types: t2, multiple: e2[0].multiple || false, excludeAcceptAllOption: e2[0].excludeAcceptAllOption || false }), r2 = await Promise.all(n2.map(s));
87172
- return e2[0].multiple ? r2 : r2[0];
87173
- }, c = { __proto__: null, default: l };
87174
- function u(e2) {
87175
- function t2(e3) {
87176
- if (Object(e3) !== e3) return Promise.reject(new TypeError(e3 + " is not an object."));
87177
- var t3 = e3.done;
87178
- return Promise.resolve(e3.value).then(function(e4) {
87179
- return { value: e4, done: t3 };
87180
- });
87181
- }
87182
- return u = function(e3) {
87183
- this.s = e3, this.n = e3.next;
87184
- }, u.prototype = { s: null, n: null, next: function() {
87185
- return t2(this.n.apply(this.s, arguments));
87186
- }, return: function(e3) {
87187
- var n2 = this.s.return;
87188
- return void 0 === n2 ? Promise.resolve({ value: e3, done: true }) : t2(n2.apply(this.s, arguments));
87189
- }, throw: function(e3) {
87190
- var n2 = this.s.return;
87191
- return void 0 === n2 ? Promise.reject(e3) : t2(n2.apply(this.s, arguments));
87192
- } }, new u(e2);
87193
- }
87194
- const p = async (e2, t2, n2 = e2.name, r2) => {
87195
- const i = [], a2 = [];
87196
- var o2, s2 = false, l2 = false;
87197
- try {
87198
- for (var c2, d2 = function(e3) {
87199
- var t3, n3, r3, i2 = 2;
87200
- for ("undefined" != typeof Symbol && (n3 = Symbol.asyncIterator, r3 = Symbol.iterator); i2--; ) {
87201
- if (n3 && null != (t3 = e3[n3])) return t3.call(e3);
87202
- if (r3 && null != (t3 = e3[r3])) return new u(t3.call(e3));
87203
- n3 = "@@asyncIterator", r3 = "@@iterator";
87204
- }
87205
- throw new TypeError("Object is not async iterable");
87206
- }(e2.values()); s2 = !(c2 = await d2.next()).done; s2 = false) {
87207
- const o3 = c2.value, s3 = `${n2}/${o3.name}`;
87208
- "file" === o3.kind ? a2.push(o3.getFile().then((t3) => (t3.directoryHandle = e2, t3.handle = o3, Object.defineProperty(t3, "webkitRelativePath", { configurable: true, enumerable: true, get: () => s3 })))) : "directory" !== o3.kind || !t2 || r2 && r2(o3) || i.push(p(o3, t2, s3, r2));
87209
- }
87210
- } catch (e3) {
87211
- l2 = true, o2 = e3;
87212
- } finally {
87213
- try {
87214
- s2 && null != d2.return && await d2.return();
87215
- } finally {
87216
- if (l2) throw o2;
87217
- }
87218
- }
87219
- return [...(await Promise.all(i)).flat(), ...await Promise.all(a2)];
87220
- };
87221
- var d = async (e2 = {}) => {
87222
- e2.recursive = e2.recursive || false, e2.mode = e2.mode || "read";
87223
- const t2 = await window.showDirectoryPicker({ id: e2.id, startIn: e2.startIn, mode: e2.mode });
87224
- return (await (await t2.values()).next()).done ? [t2] : p(t2, e2.recursive, void 0, e2.skipDirectory);
87225
- }, y = { __proto__: null, default: d }, f = async (e2, t2 = [{}], n2 = null, r2 = false, i = null) => {
87226
- Array.isArray(t2) || (t2 = [t2]), t2[0].fileName = t2[0].fileName || "Untitled";
87227
- const a2 = [];
87228
- let o2 = null;
87229
- if (e2 instanceof Blob && e2.type ? o2 = e2.type : e2.headers && e2.headers.get("content-type") && (o2 = e2.headers.get("content-type")), t2.forEach((e3, t3) => {
87230
- a2[t3] = { description: e3.description || "Files", accept: {} }, e3.mimeTypes ? (0 === t3 && o2 && e3.mimeTypes.push(o2), e3.mimeTypes.map((n3) => {
87231
- a2[t3].accept[n3] = e3.extensions || [];
87232
- })) : o2 ? a2[t3].accept[o2] = e3.extensions || [] : a2[t3].accept["*/*"] = e3.extensions || [];
87233
- }), n2) try {
87234
- await n2.getFile();
87235
- } catch (e3) {
87236
- if (n2 = null, r2) throw e3;
87237
- }
87238
- const s2 = n2 || await window.showSaveFilePicker({ suggestedName: t2[0].fileName, id: t2[0].id, startIn: t2[0].startIn, types: a2, excludeAcceptAllOption: t2[0].excludeAcceptAllOption || false });
87239
- !n2 && i && i(s2);
87240
- const l2 = await s2.createWritable();
87241
- if ("stream" in e2) {
87242
- const t3 = e2.stream();
87243
- return await t3.pipeTo(l2), s2;
87244
- }
87245
- return "body" in e2 ? (await e2.body.pipeTo(l2), s2) : (await l2.write(await e2), await l2.close(), s2);
87246
- }, m = { __proto__: null, default: f }, w = async (e2 = [{}]) => (Array.isArray(e2) || (e2 = [e2]), new Promise((t2, n2) => {
87247
- const r2 = document.createElement("input");
87248
- r2.type = "file";
87249
- const i = [...e2.map((e3) => e3.mimeTypes || []), ...e2.map((e3) => e3.extensions || [])].join();
87250
- r2.multiple = e2[0].multiple || false, r2.accept = i || "", r2.style.display = "none", document.body.append(r2), r2.addEventListener("cancel", () => {
87251
- r2.remove(), n2(new DOMException("The user aborted a request.", "AbortError"));
87252
- }), r2.addEventListener("change", () => {
87253
- r2.remove(), t2(r2.multiple ? Array.from(r2.files) : r2.files[0]);
87254
- }), "showPicker" in HTMLInputElement.prototype ? r2.showPicker() : r2.click();
87255
- })), h = { __proto__: null, default: w }, v = async (e2 = [{}]) => (Array.isArray(e2) || (e2 = [e2]), e2[0].recursive = e2[0].recursive || false, new Promise((t2, n2) => {
87256
- const r2 = document.createElement("input");
87257
- r2.type = "file", r2.webkitdirectory = true, r2.style.display = "none", document.body.append(r2), r2.addEventListener("cancel", () => {
87258
- r2.remove(), n2(new DOMException("The user aborted a request.", "AbortError"));
87259
- }), r2.addEventListener("change", () => {
87260
- r2.remove();
87261
- let n3 = Array.from(r2.files);
87262
- e2[0].recursive ? e2[0].recursive && e2[0].skipDirectory && (n3 = n3.filter((t3) => t3.webkitRelativePath.split("/").every((t4) => !e2[0].skipDirectory({ name: t4, kind: "directory" })))) : n3 = n3.filter((e3) => 2 === e3.webkitRelativePath.split("/").length), t2(n3);
87263
- }), "showPicker" in HTMLInputElement.prototype ? r2.showPicker() : r2.click();
87264
- })), b = { __proto__: null, default: v }, P = async (e2, t2 = {}) => {
87265
- Array.isArray(t2) && (t2 = t2[0]);
87266
- const n2 = document.createElement("a");
87267
- let r2 = e2;
87268
- "body" in e2 && (r2 = await async function(e3, t3) {
87269
- const n3 = e3.getReader(), r3 = new ReadableStream({ start: (e4) => async function t4() {
87270
- return n3.read().then(({ done: n4, value: r4 }) => {
87271
- if (!n4) return e4.enqueue(r4), t4();
87272
- e4.close();
87273
- });
87274
- }() }), i2 = new Response(r3), a3 = await i2.blob();
87275
- return n3.releaseLock(), new Blob([a3], { type: t3 });
87276
- }(e2.body, e2.headers.get("content-type"))), n2.download = t2.fileName || "Untitled", n2.href = URL.createObjectURL(await r2);
87277
- const i = () => {
87278
- "function" == typeof a2 && a2();
87279
- }, a2 = t2.legacySetup && t2.legacySetup(i, () => a2(), n2);
87280
- return n2.addEventListener("click", () => {
87281
- setTimeout(() => URL.revokeObjectURL(n2.href), 3e4), i();
87282
- }), n2.click(), null;
87283
- }, _ = { __proto__: null, default: P };
87284
87137
  async function downloadChatHistory(extensionAPI) {
87285
87138
  const userHistory = await firstResultFromOperation(extensionAPI.userHistory(ChatHistoryType.Full));
87286
87139
  const chatHistory = (userHistory == null ? void 0 : userHistory.chat) ? Object.values(userHistory.chat) : null;
@@ -87289,11 +87142,13 @@ async function downloadChatHistory(extensionAPI) {
87289
87142
  }
87290
87143
  const json2 = JSON.stringify(chatHistory, null, 2);
87291
87144
  const blob = new Blob([json2], { type: "application/json" });
87145
+ const url = URL.createObjectURL(blob);
87292
87146
  const timestamp = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-").slice(0, -5);
87293
- await o(blob, {
87294
- fileName: `cody-chat-history-${timestamp}.json`,
87295
- extensions: [".json"]
87296
- });
87147
+ const a2 = document.createElement("a");
87148
+ a2.href = url;
87149
+ a2.download = `cody-chat-history-${timestamp}.json`;
87150
+ a2.target = "_blank";
87151
+ a2.click();
87297
87152
  }
87298
87153
  const StorageWarningBanner = ({ extensionAPI, vscodeAPI }) => {
87299
87154
  const onExport = useCallback(() => downloadChatHistory(extensionAPI), [extensionAPI]);
@@ -90261,18 +90116,22 @@ async function createAgentClient({
90261
90116
  debug = true,
90262
90117
  trace: trace2 = false
90263
90118
  }) {
90119
+ console.log("[Cody] Creating agent worker");
90264
90120
  const worker = createAgentWorker();
90265
90121
  const rpc = browser.createMessageConnection(
90266
90122
  new browser.BrowserMessageReader(worker),
90267
90123
  new browser.BrowserMessageWriter(worker),
90268
90124
  console
90269
90125
  );
90126
+ console.log("[Cody] Agent worker is created");
90270
90127
  if (trace2) {
90271
90128
  rpc.trace(browser.Trace.Verbose, { log: (...args) => console.debug("agent: debug:", ...args) });
90272
90129
  }
90273
90130
  rpc.onClose(() => {
90131
+ console.log("[Cody] connection closed");
90274
90132
  console.error("agent: connection closed");
90275
90133
  });
90134
+ console.log("[Cody] Listen for rpc from the agent");
90276
90135
  rpc.listen();
90277
90136
  rpc.onNotification("debug/message", (message2) => {
90278
90137
  if (debug) {
@@ -90284,10 +90143,11 @@ async function createAgentClient({
90284
90143
  console.debug("agent: debug:", message2);
90285
90144
  }
90286
90145
  });
90146
+ console.log("[Cody] Send init agent worker command");
90287
90147
  const serverInfo = await rpc.sendRequest("initialize", {
90288
90148
  name: "web",
90289
90149
  version: "0.0.1",
90290
- // This is not used in cody web. Instead we trigger `workspaceFolder/didChange` to notify
90150
+ // This is not used in cody web. Instead, we trigger `workspaceFolder/didChange` to notify
90291
90151
  // the agent about the current workspace.
90292
90152
  workspaceRootUri: "",
90293
90153
  capabilities: {
@@ -90314,17 +90174,19 @@ async function createAgentClient({
90314
90174
  }
90315
90175
  }
90316
90176
  });
90177
+ console.log("[Cody] Send success init agent worker command");
90317
90178
  await rpc.sendNotification("initialized", null);
90318
90179
  return {
90319
90180
  rpc,
90320
90181
  serverInfo,
90321
90182
  dispose() {
90183
+ console.log("[Cody] Worker dispose call");
90322
90184
  rpc.end();
90323
90185
  worker.terminate();
90324
90186
  }
90325
90187
  };
90326
90188
  }
90327
- const GLOBAL_MESSAGE_TYPES = ["rpc/response"];
90189
+ const GLOBAL_MESSAGE_TYPES = ["rpc/response", "clientConfig"];
90328
90190
  const GLOBAL_AGENT_SHUTDOWN_TIMER = 10 * 60 * 1e3;
90329
90191
  let globalAgentRefCounter = 0;
90330
90192
  let globalAgentShutdownTimer;