@carlonicora/nextjs-jsonapi 6.23.0 → 6.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/{BlockNoteEditor-UO4ZRCUM.mjs → BlockNoteEditor-ENDOVTAW.mjs} +2 -2
  2. package/dist/{BlockNoteEditor-PPRML5CO.js → BlockNoteEditor-MONT74RQ.js} +9 -9
  3. package/dist/{BlockNoteEditor-PPRML5CO.js.map → BlockNoteEditor-MONT74RQ.js.map} +1 -1
  4. package/dist/billing/index.js +378 -378
  5. package/dist/billing/index.mjs +1 -1
  6. package/dist/{chunk-R5722NLL.js → chunk-BDWV4KYR.js} +312 -309
  7. package/dist/chunk-BDWV4KYR.js.map +1 -0
  8. package/dist/{chunk-HP6DT6K3.mjs → chunk-OZADFYE7.mjs} +5 -2
  9. package/dist/chunk-OZADFYE7.mjs.map +1 -0
  10. package/dist/client/index.js +2 -2
  11. package/dist/client/index.mjs +1 -1
  12. package/dist/components/forms/EditorSheet.d.ts +6 -1
  13. package/dist/components/forms/EditorSheet.d.ts.map +1 -1
  14. package/dist/components/index.js +2 -2
  15. package/dist/components/index.mjs +1 -1
  16. package/dist/contexts/index.js +2 -2
  17. package/dist/contexts/index.mjs +1 -1
  18. package/dist/email-automations/index.js +78 -78
  19. package/dist/email-automations/index.mjs +1 -1
  20. package/dist/features/analytics/index.js +107 -107
  21. package/dist/features/analytics/index.mjs +1 -1
  22. package/dist/features/blog/index.js +93 -93
  23. package/dist/features/blog/index.mjs +1 -1
  24. package/dist/features/help/index.js +31 -31
  25. package/dist/features/help/index.mjs +1 -1
  26. package/dist/features/tokenusage/index.js +102 -102
  27. package/dist/features/tokenusage/index.mjs +1 -1
  28. package/package.json +1 -1
  29. package/src/components/forms/EditorSheet.tsx +8 -0
  30. package/src/components/forms/__tests__/EditorSheet.spec.tsx +30 -0
  31. package/dist/chunk-HP6DT6K3.mjs.map +0 -1
  32. package/dist/chunk-R5722NLL.js.map +0 -1
  33. /package/dist/{BlockNoteEditor-UO4ZRCUM.mjs.map → BlockNoteEditor-ENDOVTAW.mjs.map} +0 -0
@@ -10149,6 +10149,7 @@ function EditorSheet({
10149
10149
  form,
10150
10150
  onSubmit,
10151
10151
  onBeforeSubmit,
10152
+ onSubmitError,
10152
10153
  onReset,
10153
10154
  isFormDirty: isFormDirtyProp,
10154
10155
  entityType,
@@ -10224,6 +10225,7 @@ function EditorSheet({
10224
10225
  }
10225
10226
  }
10226
10227
  } catch (error) {
10228
+ if (_optionalChain([onSubmitError, 'optionalCall', _281 => _281(error)])) return;
10227
10229
  errorToast({
10228
10230
  title: isEdit ? t("generic.errors.update") : t("generic.errors.create"),
10229
10231
  error
@@ -10233,6 +10235,7 @@ function EditorSheet({
10233
10235
  [
10234
10236
  onSubmit,
10235
10237
  onBeforeSubmit,
10238
+ onSubmitError,
10236
10239
  setOpen,
10237
10240
  onSuccess,
10238
10241
  onSaved,
@@ -10456,7 +10459,7 @@ function EntitySelector({
10456
10459
  {
10457
10460
  className: `bg-input/20 dark:bg-input/30 border-input focus-visible:border-ring focus-visible:ring-ring/30 focus-visible:ring-[2px] flex min-h-7 max-md:min-h-10 w-full items-center gap-2 rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed ${hasValue(effectiveValue) ? "" : "text-muted-foreground"} ${disabled ? "cursor-not-allowed opacity-50" : ""}`,
10458
10461
  children: [
10459
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "min-w-0 flex-1 truncate text-start", children: hasValue(effectiveValue) ? getSelectedItemDisplay ? getSelectedItemDisplay(effectiveValue) : _nullishCoalesce(_optionalChain([effectiveValue, 'optionalAccess', _281 => _281.name]), () => ( "")) : placeholder }),
10462
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "min-w-0 flex-1 truncate text-start", children: hasValue(effectiveValue) ? getSelectedItemDisplay ? getSelectedItemDisplay(effectiveValue) : _nullishCoalesce(_optionalChain([effectiveValue, 'optionalAccess', _282 => _282.name]), () => ( "")) : placeholder }),
10460
10463
  hasValue(effectiveValue) && !disabled && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
10461
10464
  _lucidereact.CircleX,
10462
10465
  {
@@ -10617,7 +10620,7 @@ var FileUploader = _react.forwardRef.call(void 0,
10617
10620
  movePrev();
10618
10621
  } else if (e.key === "Enter" || e.key === "Space") {
10619
10622
  if (activeIndex === -1) {
10620
- _optionalChain([dropzoneState, 'access', _282 => _282.inputRef, 'access', _283 => _283.current, 'optionalAccess', _284 => _284.click, 'call', _285 => _285()]);
10623
+ _optionalChain([dropzoneState, 'access', _283 => _283.inputRef, 'access', _284 => _284.current, 'optionalAccess', _285 => _285.click, 'call', _286 => _286()]);
10621
10624
  }
10622
10625
  } else if (e.key === "Delete" || e.key === "Backspace") {
10623
10626
  if (activeIndex !== -1) {
@@ -10663,13 +10666,13 @@ var FileUploader = _react.forwardRef.call(void 0,
10663
10666
  }
10664
10667
  if (rejectedFiles.length > 0) {
10665
10668
  for (let i = 0; i < rejectedFiles.length; i++) {
10666
- if (_optionalChain([rejectedFiles, 'access', _286 => _286[i], 'access', _287 => _287.errors, 'access', _288 => _288[0], 'optionalAccess', _289 => _289.code]) === "file-too-large") {
10669
+ if (_optionalChain([rejectedFiles, 'access', _287 => _287[i], 'access', _288 => _288.errors, 'access', _289 => _289[0], 'optionalAccess', _290 => _290.code]) === "file-too-large") {
10667
10670
  _chunkHN7L6RRWjs.showError.call(void 0, t("common.errors.file"), {
10668
10671
  description: t(`common.errors.file_max`, { size: maxSize / 1024 / 1024 })
10669
10672
  });
10670
10673
  break;
10671
10674
  }
10672
- if (_optionalChain([rejectedFiles, 'access', _290 => _290[i], 'access', _291 => _291.errors, 'access', _292 => _292[0], 'optionalAccess', _293 => _293.message])) {
10675
+ if (_optionalChain([rejectedFiles, 'access', _291 => _291[i], 'access', _292 => _292.errors, 'access', _293 => _293[0], 'optionalAccess', _294 => _294.message])) {
10673
10676
  _chunkHN7L6RRWjs.showError.call(void 0, t(`common.errors.file`), {
10674
10677
  description: rejectedFiles[i].errors[0].message
10675
10678
  });
@@ -10868,7 +10871,7 @@ FileInput.displayName = "FileInput";
10868
10871
  var _dynamic = require('next/dynamic'); var _dynamic2 = _interopRequireDefault(_dynamic);
10869
10872
 
10870
10873
 
10871
- var BlockNoteEditor = _dynamic2.default.call(void 0, () => Promise.resolve().then(() => _interopRequireWildcard(require("./BlockNoteEditor-PPRML5CO.js"))), {
10874
+ var BlockNoteEditor = _dynamic2.default.call(void 0, () => Promise.resolve().then(() => _interopRequireWildcard(require("./BlockNoteEditor-MONT74RQ.js"))), {
10872
10875
  ssr: false
10873
10876
  });
10874
10877
  var BlockNoteEditorContainer = React2.default.memo(/* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, function EditorContainer(props) {
@@ -10953,7 +10956,7 @@ function FormBlockNote({
10953
10956
  } else {
10954
10957
  field.onChange(content);
10955
10958
  }
10956
- _optionalChain([onEmptyChange, 'optionalCall', _294 => _294(isEmpty)]);
10959
+ _optionalChain([onEmptyChange, 'optionalCall', _295 => _295(isEmpty)]);
10957
10960
  },
10958
10961
  placeholder,
10959
10962
  bordered: true,
@@ -11180,7 +11183,7 @@ function FormDateTime({
11180
11183
  const dateFnsLocale = _chunkP7L6OFX5js.useI18nDateFnsLocale.call(void 0, );
11181
11184
  const [displayMonth, setDisplayMonth] = _react.useState.call(void 0, () => {
11182
11185
  const currentValue = form.getValues(id);
11183
- return currentValue || defaultMonth || _optionalChain([reference, 'optionalAccess', _295 => _295.date]) || /* @__PURE__ */ new Date();
11186
+ return currentValue || defaultMonth || _optionalChain([reference, 'optionalAccess', _296 => _296.date]) || /* @__PURE__ */ new Date();
11184
11187
  });
11185
11188
  const dateTimeFormatter = _react.useMemo.call(void 0,
11186
11189
  () => new Intl.DateTimeFormat(locale, {
@@ -11307,7 +11310,7 @@ function FormDateTime({
11307
11310
  modifiersClassNames: dayModifiersClassNames
11308
11311
  }
11309
11312
  ),
11310
- _optionalChain([reference, 'optionalAccess', _296 => _296.label]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-row items-center justify-between gap-x-4 border-t pt-4", children: [
11313
+ _optionalChain([reference, 'optionalAccess', _297 => _297.label]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-row items-center justify-between gap-x-4 border-t pt-4", children: [
11311
11314
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "text-muted-foreground text-sm", children: [
11312
11315
  reference.label,
11313
11316
  ": ",
@@ -11657,11 +11660,11 @@ function FormPlaceAutocomplete({
11657
11660
  const data = await response.json();
11658
11661
  if (data.suggestions) {
11659
11662
  const formattedSuggestions = data.suggestions.map((suggestion) => ({
11660
- place_id: _optionalChain([suggestion, 'access', _297 => _297.placePrediction, 'optionalAccess', _298 => _298.placeId]) || "",
11661
- description: _optionalChain([suggestion, 'access', _299 => _299.placePrediction, 'optionalAccess', _300 => _300.text, 'optionalAccess', _301 => _301.text]) || "",
11663
+ place_id: _optionalChain([suggestion, 'access', _298 => _298.placePrediction, 'optionalAccess', _299 => _299.placeId]) || "",
11664
+ description: _optionalChain([suggestion, 'access', _300 => _300.placePrediction, 'optionalAccess', _301 => _301.text, 'optionalAccess', _302 => _302.text]) || "",
11662
11665
  structured_formatting: {
11663
- main_text: _optionalChain([suggestion, 'access', _302 => _302.placePrediction, 'optionalAccess', _303 => _303.structuredFormat, 'optionalAccess', _304 => _304.mainText, 'optionalAccess', _305 => _305.text]) || "",
11664
- secondary_text: _optionalChain([suggestion, 'access', _306 => _306.placePrediction, 'optionalAccess', _307 => _307.structuredFormat, 'optionalAccess', _308 => _308.secondaryText, 'optionalAccess', _309 => _309.text]) || ""
11666
+ main_text: _optionalChain([suggestion, 'access', _303 => _303.placePrediction, 'optionalAccess', _304 => _304.structuredFormat, 'optionalAccess', _305 => _305.mainText, 'optionalAccess', _306 => _306.text]) || "",
11667
+ secondary_text: _optionalChain([suggestion, 'access', _307 => _307.placePrediction, 'optionalAccess', _308 => _308.structuredFormat, 'optionalAccess', _309 => _309.secondaryText, 'optionalAccess', _310 => _310.text]) || ""
11665
11668
  }
11666
11669
  }));
11667
11670
  setSuggestions(formattedSuggestions);
@@ -11808,8 +11811,8 @@ function FormPlaceAutocomplete({
11808
11811
  className: "hover:bg-muted cursor-pointer px-3 py-2 text-sm",
11809
11812
  onClick: () => handleSuggestionSelect(suggestion),
11810
11813
  children: [
11811
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "font-medium", children: _optionalChain([suggestion, 'access', _310 => _310.structured_formatting, 'optionalAccess', _311 => _311.main_text]) }),
11812
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-muted-foreground", children: _optionalChain([suggestion, 'access', _312 => _312.structured_formatting, 'optionalAccess', _313 => _313.secondary_text]) })
11814
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "font-medium", children: _optionalChain([suggestion, 'access', _311 => _311.structured_formatting, 'optionalAccess', _312 => _312.main_text]) }),
11815
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-muted-foreground", children: _optionalChain([suggestion, 'access', _313 => _313.structured_formatting, 'optionalAccess', _314 => _314.secondary_text]) })
11813
11816
  ]
11814
11817
  },
11815
11818
  suggestion.place_id || index
@@ -11857,7 +11860,7 @@ function FormSelect({
11857
11860
  disabled,
11858
11861
  "data-testid": testId,
11859
11862
  children: [
11860
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectValue, { children: field.value ? _optionalChain([values, 'access', _314 => _314.find, 'call', _315 => _315((v) => v.id === field.value), 'optionalAccess', _316 => _316.text]) : _nullishCoalesce(placeholder, () => ( "")) }) }),
11863
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectValue, { children: field.value ? _optionalChain([values, 'access', _315 => _315.find, 'call', _316 => _316((v) => v.id === field.value), 'optionalAccess', _317 => _317.text]) : _nullishCoalesce(placeholder, () => ( "")) }) }),
11861
11864
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, SelectContent, { children: [
11862
11865
  allowEmpty && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectItem, { value: EMPTY_VALUE, className: "text-muted-foreground", children: _nullishCoalesce(placeholder, () => ( "")) }),
11863
11866
  values.map((type) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectItem, { value: type.id, children: type.text }, type.id))
@@ -12037,7 +12040,7 @@ var FilePreviewItem = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ fi
12037
12040
  setObjectUrl(null);
12038
12041
  }, [file]);
12039
12042
  const getFileIcon = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
12040
- const extension = _optionalChain([file, 'access', _317 => _317.name, 'access', _318 => _318.split, 'call', _319 => _319("."), 'access', _320 => _320.pop, 'call', _321 => _321(), 'optionalAccess', _322 => _322.toLowerCase, 'call', _323 => _323()]);
12043
+ const extension = _optionalChain([file, 'access', _318 => _318.name, 'access', _319 => _319.split, 'call', _320 => _320("."), 'access', _321 => _321.pop, 'call', _322 => _322(), 'optionalAccess', _323 => _323.toLowerCase, 'call', _324 => _324()]);
12041
12044
  if (file.type.startsWith("image/")) {
12042
12045
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.FileImageIcon, { className: "text-muted h-10 w-10 sm:h-12 sm:w-12" });
12043
12046
  }
@@ -12087,7 +12090,7 @@ function UserAvatar({ user, className, showFull, showLink, showTooltip = true })
12087
12090
  }, "getInitials");
12088
12091
  const getAvatar = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
12089
12092
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "*:ring-border *:ring-1", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Avatar, { className: `h-6 w-6 ${className}`, children: [
12090
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { className: "object-cover", src: _optionalChain([user, 'optionalAccess', _324 => _324.avatar]) }),
12093
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { className: "object-cover", src: _optionalChain([user, 'optionalAccess', _325 => _325.avatar]) }),
12091
12094
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarFallback, { children: getInitials3(user.name) })
12092
12095
  ] }) });
12093
12096
  }, "getAvatar");
@@ -12293,7 +12296,7 @@ var useUserTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0,
12293
12296
  })
12294
12297
  };
12295
12298
  const columns = _react.useMemo.call(void 0, () => {
12296
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _325 => _325[field], 'optionalCall', _326 => _326()])).filter((col) => col !== void 0);
12299
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _326 => _326[field], 'optionalCall', _327 => _327()])).filter((col) => col !== void 0);
12297
12300
  }, [params.fields, fieldColumnMap, t, generateUrl]);
12298
12301
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
12299
12302
  }, "useUserTableStructure");
@@ -12408,10 +12411,10 @@ function UserSelector({ id, form, label, placeholder, onChange, isRequired = fal
12408
12411
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-row items-center justify-between", children: [
12409
12412
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PopoverTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-row items-center justify-start rounded-md", children: field.value ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "bg-input/20 dark:bg-input/30 border-input flex h-7 w-full flex-row items-center justify-start rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed", children: [
12410
12413
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "*:ring-border *:ring-1", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Avatar, { className: `me-2 h-4 w-4`, children: [
12411
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { src: _optionalChain([field, 'access', _327 => _327.value, 'optionalAccess', _328 => _328.avatar]) }),
12412
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarFallback, { children: _optionalChain([field, 'access', _329 => _329.value, 'optionalAccess', _330 => _330.name]) ? _optionalChain([field, 'access', _331 => _331.value, 'optionalAccess', _332 => _332.name, 'access', _333 => _333.split, 'call', _334 => _334(" "), 'access', _335 => _335.map, 'call', _336 => _336((name) => name.charAt(0).toUpperCase())]) : "X" })
12414
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { src: _optionalChain([field, 'access', _328 => _328.value, 'optionalAccess', _329 => _329.avatar]) }),
12415
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarFallback, { children: _optionalChain([field, 'access', _330 => _330.value, 'optionalAccess', _331 => _331.name]) ? _optionalChain([field, 'access', _332 => _332.value, 'optionalAccess', _333 => _333.name, 'access', _334 => _334.split, 'call', _335 => _335(" "), 'access', _336 => _336.map, 'call', _337 => _337((name) => name.charAt(0).toUpperCase())]) : "X" })
12413
12416
  ] }) }),
12414
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _nullishCoalesce(_optionalChain([field, 'access', _337 => _337.value, 'optionalAccess', _338 => _338.name]), () => ( "")) })
12417
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _nullishCoalesce(_optionalChain([field, 'access', _338 => _338.value, 'optionalAccess', _339 => _339.name]), () => ( "")) })
12415
12418
  ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-input/20 dark:bg-input/30 border-input text-muted-foreground flex h-7 w-full flex-row items-center justify-start rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed", children: _nullishCoalesce(placeholder, () => ( t(`ui.search.placeholder`, { type: t(`entities.users`, { count: 1 }) }))) }) }) }),
12416
12419
  field.value && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
12417
12420
  _lucidereact.CircleX,
@@ -12631,7 +12634,7 @@ function UserContent({ user }) {
12631
12634
  const updated = await _chunkHN7L6RRWjs.UserService.patchAvatar({ id: user.id, avatar: imageKey });
12632
12635
  setUser(updated);
12633
12636
  },
12634
- companyId: _nullishCoalesce(_optionalChain([company, 'optionalAccess', _339 => _339.id]), () => ( "")),
12637
+ companyId: _nullishCoalesce(_optionalChain([company, 'optionalAccess', _340 => _340.id]), () => ( "")),
12635
12638
  className: "h-24 w-24",
12636
12639
  fallbackClassName: "text-2xl"
12637
12640
  }
@@ -12787,7 +12790,7 @@ function CompanyUsersList({ isDeleted, fullWidth }) {
12787
12790
  const data = useDataListRetriever({
12788
12791
  ready: !!company,
12789
12792
  retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkHN7L6RRWjs.UserService.findAllUsers(params), "retriever"),
12790
- retrieverParams: { companyId: _optionalChain([company, 'optionalAccess', _340 => _340.id]), isDeleted },
12793
+ retrieverParams: { companyId: _optionalChain([company, 'optionalAccess', _341 => _341.id]), isDeleted },
12791
12794
  module: _chunkP7L6OFX5js.Modules.User
12792
12795
  });
12793
12796
  _react.useEffect.call(void 0, () => {
@@ -12895,11 +12898,11 @@ function UserListInAdd({ data, existingUsers, setSelectedUser, setLevelOpen }) {
12895
12898
  value: user.id,
12896
12899
  onClick: (_e) => {
12897
12900
  setSelectedUser(user);
12898
- _optionalChain([setLevelOpen, 'optionalCall', _341 => _341(true)]);
12901
+ _optionalChain([setLevelOpen, 'optionalCall', _342 => _342(true)]);
12899
12902
  },
12900
12903
  onSelect: (_e) => {
12901
12904
  setSelectedUser(user);
12902
- _optionalChain([setLevelOpen, 'optionalCall', _342 => _342(true)]);
12905
+ _optionalChain([setLevelOpen, 'optionalCall', _343 => _343(true)]);
12903
12906
  },
12904
12907
  children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-row items-center justify-between px-4 py-1", children: [
12905
12908
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, UserAvatar, { user }),
@@ -13040,7 +13043,7 @@ function CompanyContent({ company, actions }) {
13040
13043
  company.legal_address
13041
13044
  ] }),
13042
13045
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-1", children: [
13043
- _optionalChain([company, 'access', _343 => _343.configurations, 'optionalAccess', _344 => _344.country]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground text-sm", children: [
13046
+ _optionalChain([company, 'access', _344 => _344.configurations, 'optionalAccess', _345 => _345.country]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground text-sm", children: [
13044
13047
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "font-medium", children: [
13045
13048
  t("features.configuration.country"),
13046
13049
  ":"
@@ -13048,7 +13051,7 @@ function CompanyContent({ company, actions }) {
13048
13051
  " ",
13049
13052
  company.configurations.country
13050
13053
  ] }),
13051
- _optionalChain([company, 'access', _345 => _345.configurations, 'optionalAccess', _346 => _346.currency]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground text-sm", children: [
13054
+ _optionalChain([company, 'access', _346 => _346.configurations, 'optionalAccess', _347 => _347.currency]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground text-sm", children: [
13052
13055
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "font-medium", children: [
13053
13056
  t("features.configuration.currency"),
13054
13057
  ":"
@@ -13294,7 +13297,7 @@ function CompanyEditorInternal({
13294
13297
  _chunk7QVYU63Ejs.__name.call(void 0, fetchFeatures, "fetchFeatures");
13295
13298
  fetchFeatures();
13296
13299
  }
13297
- _optionalChain([onDialogOpenChange, 'optionalCall', _347 => _347(open)]);
13300
+ _optionalChain([onDialogOpenChange, 'optionalCall', _348 => _348(open)]);
13298
13301
  },
13299
13302
  [features.length, canAccessFeatures, hasRole, onDialogOpenChange]
13300
13303
  );
@@ -13339,12 +13342,12 @@ function CompanyEditorInternal({
13339
13342
  );
13340
13343
  const getDefaultValues = _react.useCallback.call(void 0, () => {
13341
13344
  return {
13342
- id: _optionalChain([company, 'optionalAccess', _348 => _348.id]) || _uuid.v4.call(void 0, ),
13343
- name: _optionalChain([company, 'optionalAccess', _349 => _349.name]) || "",
13344
- featureIds: _optionalChain([company, 'optionalAccess', _350 => _350.features, 'access', _351 => _351.map, 'call', _352 => _352((feature) => feature.id)]) || [],
13345
- moduleIds: _optionalChain([company, 'optionalAccess', _353 => _353.modules, 'access', _354 => _354.map, 'call', _355 => _355((module) => module.id)]) || [],
13346
- logo: _optionalChain([company, 'optionalAccess', _356 => _356.logo]) || "",
13347
- legal_address: _optionalChain([company, 'optionalAccess', _357 => _357.legal_address]) || ""
13345
+ id: _optionalChain([company, 'optionalAccess', _349 => _349.id]) || _uuid.v4.call(void 0, ),
13346
+ name: _optionalChain([company, 'optionalAccess', _350 => _350.name]) || "",
13347
+ featureIds: _optionalChain([company, 'optionalAccess', _351 => _351.features, 'access', _352 => _352.map, 'call', _353 => _353((feature) => feature.id)]) || [],
13348
+ moduleIds: _optionalChain([company, 'optionalAccess', _354 => _354.modules, 'access', _355 => _355.map, 'call', _356 => _356((module) => module.id)]) || [],
13349
+ logo: _optionalChain([company, 'optionalAccess', _357 => _357.logo]) || "",
13350
+ legal_address: _optionalChain([company, 'optionalAccess', _358 => _358.legal_address]) || ""
13348
13351
  };
13349
13352
  }, [company]);
13350
13353
  const form = _reacthookform.useForm.call(void 0, {
@@ -13356,7 +13359,7 @@ function CompanyEditorInternal({
13356
13359
  {
13357
13360
  form,
13358
13361
  entityType: t(`entities.companies`, { count: 1 }),
13359
- entityName: _optionalChain([company, 'optionalAccess', _358 => _358.name]),
13362
+ entityName: _optionalChain([company, 'optionalAccess', _359 => _359.name]),
13360
13363
  isEdit: !!company,
13361
13364
  module: _chunkP7L6OFX5js.Modules.Company,
13362
13365
  propagateChanges,
@@ -13381,7 +13384,7 @@ function CompanyEditorInternal({
13381
13384
  throw new Error(t("company.fiscal_data_invalid"));
13382
13385
  }
13383
13386
  const payload = {
13384
- id: _nullishCoalesce(_optionalChain([company, 'optionalAccess', _359 => _359.id]), () => ( _uuid.v4.call(void 0, ))),
13387
+ id: _nullishCoalesce(_optionalChain([company, 'optionalAccess', _360 => _360.id]), () => ( _uuid.v4.call(void 0, ))),
13385
13388
  name: values.name,
13386
13389
  logo: files && contentType ? values.logo : void 0,
13387
13390
  featureIds: values.featureIds,
@@ -13412,14 +13415,14 @@ function CompanyEditorInternal({
13412
13415
  dialogOpen,
13413
13416
  onDialogOpenChange: handleDialogOpenChange,
13414
13417
  children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full items-start justify-between gap-x-4", children: [
13415
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-96 flex-col justify-start gap-y-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FileUploader, { value: files, onValueChange: setFiles, dropzoneOptions: dropzone2, className: "w-full p-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FileInput, { className: "text-muted-foreground/50 rounded-lg outline-1 outline-dashed", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-col items-center justify-center pt-3 pb-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-col items-center justify-center pt-3 pb-4", children: file || _optionalChain([company, 'optionalAccess', _360 => _360.logo]) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
13418
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-96 flex-col justify-start gap-y-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FileUploader, { value: files, onValueChange: setFiles, dropzoneOptions: dropzone2, className: "w-full p-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FileInput, { className: "text-muted-foreground/50 rounded-lg outline-1 outline-dashed", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-col items-center justify-center pt-3 pb-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-col items-center justify-center pt-3 pb-4", children: file || _optionalChain([company, 'optionalAccess', _361 => _361.logo]) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
13416
13419
  _image2.default,
13417
13420
  {
13418
- src: file ? URL.createObjectURL(file) : _optionalChain([company, 'optionalAccess', _361 => _361.logo]) || "",
13421
+ src: file ? URL.createObjectURL(file) : _optionalChain([company, 'optionalAccess', _362 => _362.logo]) || "",
13419
13422
  alt: t("company.logo_alt"),
13420
13423
  width: 200,
13421
13424
  height: 200,
13422
- unoptimized: _chunkHN7L6RRWjs.isRemoteImageSrc.call(void 0, file ? void 0 : _optionalChain([company, 'optionalAccess', _362 => _362.logo]))
13425
+ unoptimized: _chunkHN7L6RRWjs.isRemoteImageSrc.call(void 0, file ? void 0 : _optionalChain([company, 'optionalAccess', _363 => _363.logo]))
13423
13426
  }
13424
13427
  ) : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
13425
13428
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.UploadIcon, { className: "my-4 h-8 w-8" }),
@@ -13450,7 +13453,7 @@ function CompanyEditorInternal({
13450
13453
  }
13451
13454
  ),
13452
13455
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SectionHeader, { className: "mt-2", children: t(`company.sections.fiscal_data`) }),
13453
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ItalianFiscalData_default, { ref: fiscalRef, initialData: parseFiscalData(_optionalChain([company, 'optionalAccess', _363 => _363.fiscal_data])) })
13456
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ItalianFiscalData_default, { ref: fiscalRef, initialData: parseFiscalData(_optionalChain([company, 'optionalAccess', _364 => _364.fiscal_data])) })
13454
13457
  ] }),
13455
13458
  canAccessFeatures && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-96 flex-col justify-start gap-y-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ScrollArea, { className: "h-max", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FormFeatures, { form, name: t(`company.features_and_modules`), features }) }) })
13456
13459
  ] })
@@ -13816,7 +13819,7 @@ function NotificationToast(notification, t, generateUrl, reouter, locale) {
13816
13819
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col", children: [
13817
13820
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: t.rich(`notification.${notification.notificationType}.description`, {
13818
13821
  strong: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (chunks) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: chunks }), "strong"),
13819
- actor: _nullishCoalesce(_optionalChain([data, 'access', _364 => _364.actor, 'optionalAccess', _365 => _365.name]), () => ( "")),
13822
+ actor: _nullishCoalesce(_optionalChain([data, 'access', _365 => _365.actor, 'optionalAccess', _366 => _366.name]), () => ( "")),
13820
13823
  title: data.title,
13821
13824
  message: _nullishCoalesce(notification.message, () => ( ""))
13822
13825
  }) }),
@@ -13854,7 +13857,7 @@ function NotificationMenuItem({ notification, closePopover }) {
13854
13857
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex min-w-0 flex-1 flex-col", children: [
13855
13858
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-foreground text-sm", children: t.rich(`notification.${notification.notificationType}.description`, {
13856
13859
  strong: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (chunks) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { className: "font-medium", children: chunks }), "strong"),
13857
- actor: _nullishCoalesce(_optionalChain([data, 'access', _366 => _366.actor, 'optionalAccess', _367 => _367.name]), () => ( "")),
13860
+ actor: _nullishCoalesce(_optionalChain([data, 'access', _367 => _367.actor, 'optionalAccess', _368 => _368.name]), () => ( "")),
13858
13861
  title: data.title,
13859
13862
  message: _nullishCoalesce(notification.message, () => ( ""))
13860
13863
  }) }),
@@ -13925,7 +13928,7 @@ var NotificationContextProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(v
13925
13928
  _react.useEffect.call(void 0, () => {
13926
13929
  if (hasInitiallyLoaded || !currentUser) return;
13927
13930
  if (_chunkG4JR3SFVjs.isRolesConfigured.call(void 0, )) {
13928
- const isAdmin = _optionalChain([currentUser, 'access', _368 => _368.roles, 'optionalAccess', _369 => _369.some, 'call', _370 => _370((role) => role.id === _chunkG4JR3SFVjs.getRoleId.call(void 0, ).Administrator)]);
13931
+ const isAdmin = _optionalChain([currentUser, 'access', _369 => _369.roles, 'optionalAccess', _370 => _370.some, 'call', _371 => _371((role) => role.id === _chunkG4JR3SFVjs.getRoleId.call(void 0, ).Administrator)]);
13929
13932
  if (isAdmin) {
13930
13933
  setHasInitiallyLoaded(true);
13931
13934
  return;
@@ -14111,7 +14114,7 @@ function OnboardingProvider({
14111
14114
  const id = activeTourIdRef.current;
14112
14115
  cleanupRoots();
14113
14116
  resetState();
14114
- if (id) _optionalChain([onTourEnd, 'optionalCall', _371 => _371(id, reason)]);
14117
+ if (id) _optionalChain([onTourEnd, 'optionalCall', _372 => _372(id, reason)]);
14115
14118
  },
14116
14119
  [cleanupRoots, resetState, onTourEnd]
14117
14120
  );
@@ -14124,14 +14127,14 @@ function OnboardingProvider({
14124
14127
  cleanupRoots();
14125
14128
  resetState();
14126
14129
  }, [cleanupRoots, resetState, teardown]);
14127
- const nextStep = _react.useCallback.call(void 0, () => _optionalChain([driverRef, 'access', _372 => _372.current, 'optionalAccess', _373 => _373.moveNext, 'call', _374 => _374()]), []);
14128
- const previousStep = _react.useCallback.call(void 0, () => _optionalChain([driverRef, 'access', _375 => _375.current, 'optionalAccess', _376 => _376.movePrevious, 'call', _377 => _377()]), []);
14129
- const goToStep = _react.useCallback.call(void 0, (index) => _optionalChain([driverRef, 'access', _378 => _378.current, 'optionalAccess', _379 => _379.moveTo, 'call', _380 => _380(index)]), []);
14130
+ const nextStep = _react.useCallback.call(void 0, () => _optionalChain([driverRef, 'access', _373 => _373.current, 'optionalAccess', _374 => _374.moveNext, 'call', _375 => _375()]), []);
14131
+ const previousStep = _react.useCallback.call(void 0, () => _optionalChain([driverRef, 'access', _376 => _376.current, 'optionalAccess', _377 => _377.movePrevious, 'call', _378 => _378()]), []);
14132
+ const goToStep = _react.useCallback.call(void 0, (index) => _optionalChain([driverRef, 'access', _379 => _379.current, 'optionalAccess', _380 => _380.moveTo, 'call', _381 => _381(index)]), []);
14130
14133
  const startTour = _react.useCallback.call(void 0,
14131
14134
  (tourId, steps) => {
14132
14135
  if (typeof window === "undefined") return;
14133
14136
  if (driverRef.current) closeTour();
14134
- const tourSteps = _nullishCoalesce(steps, () => ( _optionalChain([tours, 'access', _381 => _381.find, 'call', _382 => _382((t) => t.id === tourId), 'optionalAccess', _383 => _383.steps])));
14137
+ const tourSteps = _nullishCoalesce(steps, () => ( _optionalChain([tours, 'access', _382 => _382.find, 'call', _383 => _383((t) => t.id === tourId), 'optionalAccess', _384 => _384.steps])));
14135
14138
  if (!tourSteps || tourSteps.length === 0) {
14136
14139
  console.warn(`No steps found for tour: ${tourId}`);
14137
14140
  return;
@@ -14149,12 +14152,12 @@ function OnboardingProvider({
14149
14152
  else instance2.movePrevious();
14150
14153
  if (driverRef.current === instance2 && !instance2.isActive()) teardown("dismissed");
14151
14154
  }, "go");
14152
- if (_optionalChain([target, 'optionalAccess', _384 => _384.showDelay])) setTimeout(go, target.showDelay);
14155
+ if (_optionalChain([target, 'optionalAccess', _385 => _385.showDelay])) setTimeout(go, target.showDelay);
14153
14156
  else go();
14154
14157
  }, "move");
14155
14158
  const end = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (reason) => {
14156
14159
  endReasonRef.current = reason;
14157
- _optionalChain([driverRef, 'access', _385 => _385.current, 'optionalAccess', _386 => _386.destroy, 'call', _387 => _387()]);
14160
+ _optionalChain([driverRef, 'access', _386 => _386.current, 'optionalAccess', _387 => _387.destroy, 'call', _388 => _388()]);
14158
14161
  teardown(reason);
14159
14162
  }, "end");
14160
14163
  const driveSteps = tourSteps.map((stepConfig, index) => {
@@ -14196,10 +14199,10 @@ function OnboardingProvider({
14196
14199
  onHighlightStarted: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
14197
14200
  setIsTourActive(true);
14198
14201
  setCurrentStepIndex(index);
14199
- _optionalChain([stepConfig, 'access', _388 => _388.onShow, 'optionalCall', _389 => _389()]);
14202
+ _optionalChain([stepConfig, 'access', _389 => _389.onShow, 'optionalCall', _390 => _390()]);
14200
14203
  }, "onHighlightStarted"),
14201
14204
  onDeselected: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
14202
- _optionalChain([stepConfig, 'access', _390 => _390.onHide, 'optionalCall', _391 => _391()]);
14205
+ _optionalChain([stepConfig, 'access', _391 => _391.onHide, 'optionalCall', _392 => _392()]);
14203
14206
  const root = rootsRef.current.get(index);
14204
14207
  if (root) {
14205
14208
  rootsRef.current.delete(index);
@@ -14227,7 +14230,7 @@ function OnboardingProvider({
14227
14230
  );
14228
14231
  _react.useEffect.call(void 0, () => {
14229
14232
  return () => {
14230
- _optionalChain([driverRef, 'access', _392 => _392.current, 'optionalAccess', _393 => _393.destroy, 'call', _394 => _394()]);
14233
+ _optionalChain([driverRef, 'access', _393 => _393.current, 'optionalAccess', _394 => _394.destroy, 'call', _395 => _395()]);
14231
14234
  cleanupRoots();
14232
14235
  };
14233
14236
  }, [cleanupRoots]);
@@ -14360,7 +14363,7 @@ function HowToMultiSelector({
14360
14363
  retriever: (params) => _chunkHN7L6RRWjs.HowToService.findMany(params),
14361
14364
  module: _chunkP7L6OFX5js.Modules.HowTo,
14362
14365
  getLabel: (howTo) => howTo.name,
14363
- excludeId: _optionalChain([currentHowTo, 'optionalAccess', _395 => _395.id]),
14366
+ excludeId: _optionalChain([currentHowTo, 'optionalAccess', _396 => _396.id]),
14364
14367
  onChange
14365
14368
  }
14366
14369
  );
@@ -14468,17 +14471,17 @@ function HowToEditorInternal({
14468
14471
  );
14469
14472
  const getDefaultValues = _react.useCallback.call(void 0,
14470
14473
  () => ({
14471
- id: _optionalChain([howTo, 'optionalAccess', _396 => _396.id]) || _uuid.v4.call(void 0, ),
14472
- name: _optionalChain([howTo, 'optionalAccess', _397 => _397.name]) || "",
14473
- description: _optionalChain([howTo, 'optionalAccess', _398 => _398.description]) || [],
14474
- pages: _chunkHN7L6RRWjs.HowTo.parsePagesFromString(_optionalChain([howTo, 'optionalAccess', _399 => _399.pages])),
14475
- howToType: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _400 => _400.howToType]), () => ( "how-to")),
14476
- slug: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _401 => _401.slug]), () => ( "")),
14477
- order: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _402 => _402.order]), () => ( 0)),
14478
- summary: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _403 => _403.summary]), () => ( "")),
14479
- tags: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _404 => _404.tags]), () => ( []))).join(", "),
14480
- contextualKeys: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _405 => _405.contextualKeys]), () => ( []))).join(", "),
14481
- draft: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _406 => _406.draft]), () => ( false)),
14474
+ id: _optionalChain([howTo, 'optionalAccess', _397 => _397.id]) || _uuid.v4.call(void 0, ),
14475
+ name: _optionalChain([howTo, 'optionalAccess', _398 => _398.name]) || "",
14476
+ description: _optionalChain([howTo, 'optionalAccess', _399 => _399.description]) || [],
14477
+ pages: _chunkHN7L6RRWjs.HowTo.parsePagesFromString(_optionalChain([howTo, 'optionalAccess', _400 => _400.pages])),
14478
+ howToType: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _401 => _401.howToType]), () => ( "how-to")),
14479
+ slug: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _402 => _402.slug]), () => ( "")),
14480
+ order: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _403 => _403.order]), () => ( 0)),
14481
+ summary: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _404 => _404.summary]), () => ( "")),
14482
+ tags: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _405 => _405.tags]), () => ( []))).join(", "),
14483
+ contextualKeys: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _406 => _406.contextualKeys]), () => ( []))).join(", "),
14484
+ draft: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _407 => _407.draft]), () => ( false)),
14482
14485
  relatedArticles: []
14483
14486
  }),
14484
14487
  [howTo]
@@ -14489,7 +14492,7 @@ function HowToEditorInternal({
14489
14492
  });
14490
14493
  const initialRelatedIds = _react.useRef.call(void 0, []);
14491
14494
  _react.useEffect.call(void 0, () => {
14492
- if (!_optionalChain([howTo, 'optionalAccess', _407 => _407.howToType]) || !_optionalChain([howTo, 'optionalAccess', _408 => _408.slug])) return;
14495
+ if (!_optionalChain([howTo, 'optionalAccess', _408 => _408.howToType]) || !_optionalChain([howTo, 'optionalAccess', _409 => _409.slug])) return;
14493
14496
  let active = true;
14494
14497
  _chunkHN7L6RRWjs.HowToService.findRelated({ howToType: howTo.howToType, slug: howTo.slug }).then((list) => {
14495
14498
  if (!active) return;
@@ -14528,7 +14531,7 @@ function HowToEditorInternal({
14528
14531
  {
14529
14532
  form,
14530
14533
  entityType: t(`entities.howtos`, { count: 1 }),
14531
- entityName: _optionalChain([howTo, 'optionalAccess', _409 => _409.name]),
14534
+ entityName: _optionalChain([howTo, 'optionalAccess', _410 => _410.name]),
14532
14535
  isEdit: !!howTo,
14533
14536
  module: _chunkP7L6OFX5js.Modules.HowTo,
14534
14537
  propagateChanges,
@@ -14905,7 +14908,7 @@ function withPatchedTitle(source, title) {
14905
14908
  return _chunkHN7L6RRWjs.rehydrate.call(void 0, _chunkP7L6OFX5js.Modules.Assistant, {
14906
14909
  jsonApi: {
14907
14910
  ...dehydrated.jsonApi,
14908
- attributes: { ..._nullishCoalesce(_optionalChain([dehydrated, 'access', _410 => _410.jsonApi, 'optionalAccess', _411 => _411.attributes]), () => ( {})), title }
14911
+ attributes: { ..._nullishCoalesce(_optionalChain([dehydrated, 'access', _411 => _411.jsonApi, 'optionalAccess', _412 => _412.attributes]), () => ( {})), title }
14909
14912
  },
14910
14913
  included: dehydrated.included
14911
14914
  });
@@ -14940,7 +14943,7 @@ function AssistantProvider({
14940
14943
  const [status, setStatus] = _react.useState.call(void 0, void 0);
14941
14944
  const [failedMessageIds, setFailedMessageIds] = _react.useState.call(void 0, () => /* @__PURE__ */ new Set());
14942
14945
  const [operatorMode, setOperatorMode] = _react.useState.call(void 0,
14943
- () => _optionalChain([dehydratedAssistant, 'optionalAccess', _412 => _412.jsonApi, 'optionalAccess', _413 => _413.attributes, 'optionalAccess', _414 => _414.engine]) === "operator"
14946
+ () => _optionalChain([dehydratedAssistant, 'optionalAccess', _413 => _413.jsonApi, 'optionalAccess', _414 => _414.attributes, 'optionalAccess', _415 => _415.engine]) === "operator"
14944
14947
  );
14945
14948
  const [pendingScope, setPendingScope] = _react.useState.call(void 0, scope);
14946
14949
  const { socket } = useSocketContext();
@@ -14950,7 +14953,7 @@ function AssistantProvider({
14950
14953
  if (!trimmed) return;
14951
14954
  const optimistic = _chunkHN7L6RRWjs.AssistantMessage.buildOptimistic({
14952
14955
  content: trimmed,
14953
- assistantId: _optionalChain([assistant, 'optionalAccess', _415 => _415.id]),
14956
+ assistantId: _optionalChain([assistant, 'optionalAccess', _416 => _416.id]),
14954
14957
  position: nextPosition(messages)
14955
14958
  });
14956
14959
  setMessages((prev) => [...prev, optimistic]);
@@ -14960,22 +14963,22 @@ function AssistantProvider({
14960
14963
  if (assistant && payload.assistantId && payload.assistantId !== assistant.id) return;
14961
14964
  if (typeof payload.status === "string") setStatus(payload.status);
14962
14965
  }, "handler");
14963
- _optionalChain([socket, 'optionalAccess', _416 => _416.on, 'call', _417 => _417("assistant:status", handler)]);
14966
+ _optionalChain([socket, 'optionalAccess', _417 => _417.on, 'call', _418 => _418("assistant:status", handler)]);
14964
14967
  let createdHandled = false;
14965
14968
  const createdHandler = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (payload) => {
14966
14969
  if (createdHandled) return;
14967
- const data = _optionalChain([payload, 'optionalAccess', _418 => _418.assistant, 'optionalAccess', _419 => _419.data]);
14970
+ const data = _optionalChain([payload, 'optionalAccess', _419 => _419.assistant, 'optionalAccess', _420 => _420.data]);
14968
14971
  if (!data || typeof data !== "object" || typeof data.id !== "string" || !data.id) return;
14969
14972
  let thread;
14970
14973
  try {
14971
14974
  thread = _chunkHN7L6RRWjs.rehydrate.call(void 0, _chunkP7L6OFX5js.Modules.Assistant, {
14972
14975
  jsonApi: data,
14973
- included: _nullishCoalesce(_optionalChain([payload, 'access', _420 => _420.assistant, 'optionalAccess', _421 => _421.included]), () => ( []))
14976
+ included: _nullishCoalesce(_optionalChain([payload, 'access', _421 => _421.assistant, 'optionalAccess', _422 => _422.included]), () => ( []))
14974
14977
  });
14975
14978
  } catch (e9) {
14976
14979
  return;
14977
14980
  }
14978
- if (!_optionalChain([thread, 'optionalAccess', _422 => _422.id])) return;
14981
+ if (!_optionalChain([thread, 'optionalAccess', _423 => _423.id])) return;
14979
14982
  createdHandled = true;
14980
14983
  setAssistant(thread);
14981
14984
  setThreads((prev) => [thread, ...prev.filter((row) => row.id !== thread.id)]);
@@ -14983,16 +14986,16 @@ function AssistantProvider({
14983
14986
  window.history.replaceState(null, "", resolveThreadUrl(thread.id));
14984
14987
  }
14985
14988
  }, "createdHandler");
14986
- if (!assistant) _optionalChain([socket, 'optionalAccess', _423 => _423.on, 'call', _424 => _424("assistant:created", createdHandler)]);
14989
+ if (!assistant) _optionalChain([socket, 'optionalAccess', _424 => _424.on, 'call', _425 => _425("assistant:created", createdHandler)]);
14987
14990
  try {
14988
14991
  if (!assistant) {
14989
14992
  const input = {
14990
14993
  firstMessage: trimmed,
14991
- howToMode: _optionalChain([opts, 'optionalAccess', _425 => _425.howToMode]),
14992
- limitToHowToId: _optionalChain([opts, 'optionalAccess', _426 => _426.limitToHowToId]),
14993
- handbookMode: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _427 => _427.handbookMode]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _428 => _428.handbookMode]))),
14994
- limitToHandbookPageId: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _429 => _429.limitToHandbookPageId]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _430 => _430.limitToHandbookPageId]))),
14995
- contentBlocks: _optionalChain([opts, 'optionalAccess', _431 => _431.contentBlocks]),
14994
+ howToMode: _optionalChain([opts, 'optionalAccess', _426 => _426.howToMode]),
14995
+ limitToHowToId: _optionalChain([opts, 'optionalAccess', _427 => _427.limitToHowToId]),
14996
+ handbookMode: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _428 => _428.handbookMode]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _429 => _429.handbookMode]))),
14997
+ limitToHandbookPageId: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _430 => _430.limitToHandbookPageId]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _431 => _431.limitToHandbookPageId]))),
14998
+ contentBlocks: _optionalChain([opts, 'optionalAccess', _432 => _432.contentBlocks]),
14996
14999
  boundContent: pendingScope
14997
15000
  };
14998
15001
  const created = operatorMode ? await _chunkHN7L6RRWjs.AssistantService.createOperator(input) : await _chunkHN7L6RRWjs.AssistantService.create(input);
@@ -15009,15 +15012,15 @@ function AssistantProvider({
15009
15012
  const result = operatorMode ? await _chunkHN7L6RRWjs.AssistantService.appendMessageOperator({
15010
15013
  assistantId: assistant.id,
15011
15014
  content: trimmed,
15012
- contentBlocks: _optionalChain([opts, 'optionalAccess', _432 => _432.contentBlocks])
15015
+ contentBlocks: _optionalChain([opts, 'optionalAccess', _433 => _433.contentBlocks])
15013
15016
  }) : await _chunkHN7L6RRWjs.AssistantService.appendMessage({
15014
15017
  assistantId: assistant.id,
15015
15018
  content: trimmed,
15016
- howToMode: _optionalChain([opts, 'optionalAccess', _433 => _433.howToMode]),
15017
- limitToHowToId: _optionalChain([opts, 'optionalAccess', _434 => _434.limitToHowToId]),
15018
- handbookMode: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _435 => _435.handbookMode]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _436 => _436.handbookMode]))),
15019
- limitToHandbookPageId: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _437 => _437.limitToHandbookPageId]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _438 => _438.limitToHandbookPageId]))),
15020
- contentBlocks: _optionalChain([opts, 'optionalAccess', _439 => _439.contentBlocks])
15019
+ howToMode: _optionalChain([opts, 'optionalAccess', _434 => _434.howToMode]),
15020
+ limitToHowToId: _optionalChain([opts, 'optionalAccess', _435 => _435.limitToHowToId]),
15021
+ handbookMode: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _436 => _436.handbookMode]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _437 => _437.handbookMode]))),
15022
+ limitToHandbookPageId: _nullishCoalesce(_optionalChain([opts, 'optionalAccess', _438 => _438.limitToHandbookPageId]), () => ( _optionalChain([retrievalMode, 'optionalAccess', _439 => _439.limitToHandbookPageId]))),
15023
+ contentBlocks: _optionalChain([opts, 'optionalAccess', _440 => _440.contentBlocks])
15021
15024
  });
15022
15025
  setMessages((prev) => [...stripOptimistic(prev), ...result]);
15023
15026
  }
@@ -15028,8 +15031,8 @@ function AssistantProvider({
15028
15031
  return next;
15029
15032
  });
15030
15033
  } finally {
15031
- _optionalChain([socket, 'optionalAccess', _440 => _440.off, 'call', _441 => _441("assistant:status", handler)]);
15032
- if (!assistant) _optionalChain([socket, 'optionalAccess', _442 => _442.off, 'call', _443 => _443("assistant:created", createdHandler)]);
15034
+ _optionalChain([socket, 'optionalAccess', _441 => _441.off, 'call', _442 => _442("assistant:status", handler)]);
15035
+ if (!assistant) _optionalChain([socket, 'optionalAccess', _443 => _443.off, 'call', _444 => _444("assistant:created", createdHandler)]);
15033
15036
  setSending(false);
15034
15037
  setStatus(void 0);
15035
15038
  }
@@ -15095,7 +15098,7 @@ function AssistantProvider({
15095
15098
  await _chunkHN7L6RRWjs.AssistantService.delete({ id });
15096
15099
  setThreads((prev) => prev.filter((t2) => t2.id !== id));
15097
15100
  setAssistant((prev) => {
15098
- if (_optionalChain([prev, 'optionalAccess', _444 => _444.id]) === id) {
15101
+ if (_optionalChain([prev, 'optionalAccess', _445 => _445.id]) === id) {
15099
15102
  setMessages([]);
15100
15103
  return void 0;
15101
15104
  }
@@ -15107,7 +15110,7 @@ function AssistantProvider({
15107
15110
  (async () => {
15108
15111
  setThreadsLoading(true);
15109
15112
  try {
15110
- const loaded = await _chunkHN7L6RRWjs.AssistantService.findMany({ boundType: _optionalChain([scope, 'optionalAccess', _445 => _445.type]), boundId: _optionalChain([scope, 'optionalAccess', _446 => _446.id]) });
15113
+ const loaded = await _chunkHN7L6RRWjs.AssistantService.findMany({ boundType: _optionalChain([scope, 'optionalAccess', _446 => _446.type]), boundId: _optionalChain([scope, 'optionalAccess', _447 => _447.id]) });
15111
15114
  if (!cancelled) setThreads(loaded);
15112
15115
  } finally {
15113
15116
  if (!cancelled) setThreadsLoading(false);
@@ -15116,7 +15119,7 @@ function AssistantProvider({
15116
15119
  return () => {
15117
15120
  cancelled = true;
15118
15121
  };
15119
- }, [_optionalChain([scope, 'optionalAccess', _447 => _447.type]), _optionalChain([scope, 'optionalAccess', _448 => _448.id])]);
15122
+ }, [_optionalChain([scope, 'optionalAccess', _448 => _448.type]), _optionalChain([scope, 'optionalAccess', _449 => _449.id])]);
15120
15123
  const value = _react.useMemo.call(void 0,
15121
15124
  () => ({
15122
15125
  assistant,
@@ -15168,7 +15171,7 @@ function AssistantProvider({
15168
15171
  const response = {
15169
15172
  type: _nullishCoalesce(titleOverride, () => ( t("entities.assistants", { count: assistant ? 1 : 2 })))
15170
15173
  };
15171
- if (_optionalChain([assistant, 'optionalAccess', _449 => _449.title])) {
15174
+ if (_optionalChain([assistant, 'optionalAccess', _450 => _450.title])) {
15172
15175
  response.element = assistant.title.length > 25 ? `${assistant.title.substring(0, 25)}...` : assistant.title;
15173
15176
  }
15174
15177
  response.functions = [
@@ -15331,10 +15334,10 @@ function readEntityTitle() {
15331
15334
  const title = document.title;
15332
15335
  if (title.includes("]")) {
15333
15336
  const afterEntityType = title.split("]")[1];
15334
- return _optionalChain([afterEntityType, 'optionalAccess', _450 => _450.split, 'call', _451 => _451("|"), 'access', _452 => _452[0], 'optionalAccess', _453 => _453.trim, 'call', _454 => _454()]) || null;
15337
+ return _optionalChain([afterEntityType, 'optionalAccess', _451 => _451.split, 'call', _452 => _452("|"), 'access', _453 => _453[0], 'optionalAccess', _454 => _454.trim, 'call', _455 => _455()]) || null;
15335
15338
  }
15336
15339
  if (!title.includes("|")) return null;
15337
- return _optionalChain([title, 'access', _455 => _455.split, 'call', _456 => _456("|"), 'access', _457 => _457[0], 'access', _458 => _458.split, 'call', _459 => _459("\xB7"), 'access', _460 => _460[0], 'optionalAccess', _461 => _461.trim, 'call', _462 => _462()]) || null;
15340
+ return _optionalChain([title, 'access', _456 => _456.split, 'call', _457 => _457("|"), 'access', _458 => _458[0], 'access', _459 => _459.split, 'call', _460 => _460("\xB7"), 'access', _461 => _461[0], 'optionalAccess', _462 => _462.trim, 'call', _463 => _463()]) || null;
15338
15341
  }
15339
15342
  _chunk7QVYU63Ejs.__name.call(void 0, readEntityTitle, "readEntityTitle");
15340
15343
  function usePageTracker() {
@@ -15363,7 +15366,7 @@ function usePageTracker() {
15363
15366
  const existing = prev.find((page) => page.url === baseUrl);
15364
15367
  const refreshed = {
15365
15368
  url: baseUrl,
15366
- title: _nullishCoalesce(_optionalChain([existing, 'optionalAccess', _463 => _463.title]), () => ( foundModule.name)),
15369
+ title: _nullishCoalesce(_optionalChain([existing, 'optionalAccess', _464 => _464.title]), () => ( foundModule.name)),
15367
15370
  moduleType: foundModule.name,
15368
15371
  timestamp: Date.now()
15369
15372
  };
@@ -15421,7 +15424,7 @@ function urlBase64ToUint8Array(base64String) {
15421
15424
  _chunk7QVYU63Ejs.__name.call(void 0, urlBase64ToUint8Array, "urlBase64ToUint8Array");
15422
15425
  function usePushNotifications(params) {
15423
15426
  const { currentUser, canSubscribe } = params;
15424
- const userId = _optionalChain([currentUser, 'optionalAccess', _464 => _464.id]);
15427
+ const userId = _optionalChain([currentUser, 'optionalAccess', _465 => _465.id]);
15425
15428
  _react.useEffect.call(void 0, () => {
15426
15429
  if (!userId || !canSubscribe) return;
15427
15430
  const register = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
@@ -15471,7 +15474,7 @@ function usePushNotifications(params) {
15471
15474
  if (!("serviceWorker" in navigator)) return;
15472
15475
  const sessionKey = `push_registered_${userId}`;
15473
15476
  const onMessage = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (event) => {
15474
- if (_optionalChain([event, 'access', _465 => _465.data, 'optionalAccess', _466 => _466.type]) !== "PUSH_RESUBSCRIBED" || !event.data.subscription) return;
15477
+ if (_optionalChain([event, 'access', _466 => _466.data, 'optionalAccess', _467 => _467.type]) !== "PUSH_RESUBSCRIBED" || !event.data.subscription) return;
15475
15478
  const subscription = event.data.subscription;
15476
15479
  const subscriptionHash = btoa(JSON.stringify(subscription));
15477
15480
  if (sessionStorage.getItem(sessionKey) === subscriptionHash) return;
@@ -15554,14 +15557,14 @@ function useSocket({ token, paused = false }) {
15554
15557
  });
15555
15558
  }, "handleMessage");
15556
15559
  const handleNotification = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (data) => {
15557
- const resource = _nullishCoalesce(_optionalChain([data, 'optionalAccess', _467 => _467.data]), () => ( _optionalChain([data, 'optionalAccess', _468 => _468.jsonApi])));
15558
- if (!_optionalChain([resource, 'optionalAccess', _469 => _469.type])) {
15560
+ const resource = _nullishCoalesce(_optionalChain([data, 'optionalAccess', _468 => _468.data]), () => ( _optionalChain([data, 'optionalAccess', _469 => _469.jsonApi])));
15561
+ if (!_optionalChain([resource, 'optionalAccess', _470 => _470.type])) {
15559
15562
  console.warn("[useSocket] ignoring notification with unexpected payload shape", data);
15560
15563
  return;
15561
15564
  }
15562
15565
  const notification = _chunkHN7L6RRWjs.rehydrate.call(void 0, _chunkP7L6OFX5js.Modules.Notification, {
15563
15566
  jsonApi: resource,
15564
- included: _optionalChain([data, 'optionalAccess', _470 => _470.included]) || []
15567
+ included: _optionalChain([data, 'optionalAccess', _471 => _471.included]) || []
15565
15568
  });
15566
15569
  if (notification) {
15567
15570
  setSocketNotifications((prev) => {
@@ -15699,11 +15702,11 @@ function BreadcrumbMobile({
15699
15702
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Breadcrumb, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BreadcrumbList, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BreadcrumbItem, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Link, { href: generateUrl({ page: `/` }), children: rootLabel }) }) }) });
15700
15703
  }
15701
15704
  if (allItems.length <= 1) {
15702
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground block min-w-0 truncate px-1.5 text-xs/relaxed font-normal", children: _optionalChain([lastItem, 'optionalAccess', _471 => _471.name]) });
15705
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-foreground block min-w-0 truncate px-1.5 text-xs/relaxed font-normal", children: _optionalChain([lastItem, 'optionalAccess', _472 => _472.name]) });
15703
15706
  }
15704
15707
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, DropdownMenu, { open, onOpenChange: setOpen, children: [
15705
15708
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, DropdownMenuTrigger, { className: "text-foreground text-xs/relaxed font-normal hover:bg-accent flex min-h-9 min-w-0 items-center gap-1 rounded-md px-1.5 py-0.5 transition-colors outline-none", children: [
15706
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "truncate", children: _optionalChain([lastItem, 'optionalAccess', _472 => _472.name]) }),
15709
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "truncate", children: _optionalChain([lastItem, 'optionalAccess', _473 => _473.name]) }),
15707
15710
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ChevronDownIcon, { className: "text-muted-foreground size-3.5 shrink-0" })
15708
15711
  ] }),
15709
15712
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DropdownMenuContent, { align: "start", children: allItems.map(
@@ -15721,8 +15724,8 @@ function BreadcrumbMobile({
15721
15724
  href: item.href,
15722
15725
  className: _chunkHN7L6RRWjs.cn.call(void 0, props.className, "text-foreground font-normal"),
15723
15726
  onClick: (event) => {
15724
- _optionalChain([props, 'access', _473 => _473.onClick, 'optionalCall', _474 => _474(event)]);
15725
- _optionalChain([item, 'access', _475 => _475.onClick, 'optionalCall', _476 => _476()]);
15727
+ _optionalChain([props, 'access', _474 => _474.onClick, 'optionalCall', _475 => _475(event)]);
15728
+ _optionalChain([item, 'access', _476 => _476.onClick, 'optionalCall', _477 => _477()]);
15726
15729
  },
15727
15730
  children: props.children
15728
15731
  }
@@ -15740,7 +15743,7 @@ function BreadcrumbNavigation({ items, rootLabel, showRoot = true }) {
15740
15743
  const generateUrl = usePageUrlGenerator();
15741
15744
  const t = _nextintl.useTranslations.call(void 0, );
15742
15745
  const isMobile = _chunkHN7L6RRWjs.useIsMobile.call(void 0, );
15743
- const root = _optionalChain([rootLabel, 'optionalAccess', _477 => _477.trim, 'call', _478 => _478()]) ? rootLabel : t(`common.home`);
15746
+ const root = _optionalChain([rootLabel, 'optionalAccess', _478 => _478.trim, 'call', _479 => _479()]) ? rootLabel : t(`common.home`);
15744
15747
  if (isMobile) {
15745
15748
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BreadcrumbMobile, { items, generateUrl, rootLabel: root, showRoot });
15746
15749
  }
@@ -16147,12 +16150,12 @@ var _remarkgfm = require('remark-gfm'); var _remarkgfm2 = _interopRequireDefault
16147
16150
 
16148
16151
  function mermaidSourceOf(node) {
16149
16152
  const pre = node;
16150
- const code = _optionalChain([pre, 'optionalAccess', _479 => _479.children, 'optionalAccess', _480 => _480[0]]);
16151
- if (_optionalChain([code, 'optionalAccess', _481 => _481.tagName]) !== "code") return void 0;
16152
- const classNames = Array.isArray(_optionalChain([code, 'access', _482 => _482.properties, 'optionalAccess', _483 => _483.className])) ? code.properties.className : [];
16153
+ const code = _optionalChain([pre, 'optionalAccess', _480 => _480.children, 'optionalAccess', _481 => _481[0]]);
16154
+ if (_optionalChain([code, 'optionalAccess', _482 => _482.tagName]) !== "code") return void 0;
16155
+ const classNames = Array.isArray(_optionalChain([code, 'access', _483 => _483.properties, 'optionalAccess', _484 => _484.className])) ? code.properties.className : [];
16153
16156
  if (!classNames.includes("language-mermaid")) return void 0;
16154
- const text = _optionalChain([code, 'access', _484 => _484.children, 'optionalAccess', _485 => _485[0]]);
16155
- if (_optionalChain([text, 'optionalAccess', _486 => _486.type]) !== "text" || typeof text.value !== "string") return void 0;
16157
+ const text = _optionalChain([code, 'access', _485 => _485.children, 'optionalAccess', _486 => _486[0]]);
16158
+ if (_optionalChain([text, 'optionalAccess', _487 => _487.type]) !== "text" || typeof text.value !== "string") return void 0;
16156
16159
  return text.value;
16157
16160
  }
16158
16161
  _chunk7QVYU63Ejs.__name.call(void 0, mermaidSourceOf, "mermaidSourceOf");
@@ -16409,7 +16412,7 @@ var railTriggerClass = _chunkHN7L6RRWjs.cn.call(void 0,
16409
16412
  "data-active:text-primary dark:data-active:text-primary",
16410
16413
  "data-active:font-medium data-active:shadow-none"
16411
16414
  );
16412
- var tabValue = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (tab) => _nullishCoalesce(_nullishCoalesce(tab.sectionKey, () => ( _optionalChain([tab, 'access', _487 => _487.key, 'optionalAccess', _488 => _488.name]))), () => ( tab.label)), "tabValue");
16415
+ var tabValue = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (tab) => _nullishCoalesce(_nullishCoalesce(tab.sectionKey, () => ( _optionalChain([tab, 'access', _488 => _488.key, 'optionalAccess', _489 => _489.name]))), () => ( tab.label)), "tabValue");
16413
16416
  function RoundPageContainer({
16414
16417
  module,
16415
16418
  id,
@@ -16441,7 +16444,7 @@ function RoundPageContainer({
16441
16444
  const [mounted, setMounted] = _react.useState.call(void 0, false);
16442
16445
  _react.useEffect.call(void 0, () => {
16443
16446
  const match = document.cookie.split("; ").find((row) => row.startsWith(`${detailsCookieName}=`));
16444
- const stored = _optionalChain([match, 'optionalAccess', _489 => _489.split, 'call', _490 => _490("="), 'access', _491 => _491[1]]);
16447
+ const stored = _optionalChain([match, 'optionalAccess', _490 => _490.split, 'call', _491 => _491("="), 'access', _492 => _492[1]]);
16445
16448
  if (stored === "true") setShowDetailsState(true);
16446
16449
  else if (stored === "false") setShowDetailsState(false);
16447
16450
  }, []);
@@ -16457,7 +16460,7 @@ function RoundPageContainer({
16457
16460
  const clip = isFixed ? `overflow-hidden` : ``;
16458
16461
  const scrollY = isFixed ? `overflow-y-auto` : ``;
16459
16462
  const mobileBarClass = isFixed ? `` : `sticky bottom-0 z-30`;
16460
- const detailsCookieName = _optionalChain([module, 'optionalAccess', _492 => _492.name]) ? `${DETAILS_COOKIE_NAME}_${module.name}` : DETAILS_COOKIE_NAME;
16463
+ const detailsCookieName = _optionalChain([module, 'optionalAccess', _493 => _493.name]) ? `${DETAILS_COOKIE_NAME}_${module.name}` : DETAILS_COOKIE_NAME;
16461
16464
  const setShowDetails = _react.useCallback.call(void 0,
16462
16465
  (value) => {
16463
16466
  setShowDetailsState(value);
@@ -16490,13 +16493,13 @@ function RoundPageContainer({
16490
16493
  } else {
16491
16494
  rewriteUrl({ page: window.location.pathname, additionalParameters: { section: key }, mode: "push" });
16492
16495
  }
16493
- _optionalChain([onSectionChange, 'optionalCall', _493 => _493(key)]);
16496
+ _optionalChain([onSectionChange, 'optionalCall', _494 => _494(key)]);
16494
16497
  },
16495
16498
  [module, id, rewriteUrl, onSectionChange]
16496
16499
  );
16497
- const activeTabDefinition = _optionalChain([tabs, 'optionalAccess', _494 => _494.find, 'call', _495 => _495((t2) => tabValue(t2) === activeTab)]);
16498
- const activeFillHeight = _optionalChain([activeTabDefinition, 'optionalAccess', _496 => _496.fillHeight]) === true;
16499
- const activeConstrainWidth = _optionalChain([activeTabDefinition, 'optionalAccess', _497 => _497.constrainWidth]) === true;
16500
+ const activeTabDefinition = _optionalChain([tabs, 'optionalAccess', _495 => _495.find, 'call', _496 => _496((t2) => tabValue(t2) === activeTab)]);
16501
+ const activeFillHeight = _optionalChain([activeTabDefinition, 'optionalAccess', _497 => _497.fillHeight]) === true;
16502
+ const activeConstrainWidth = _optionalChain([activeTabDefinition, 'optionalAccess', _498 => _498.constrainWidth]) === true;
16500
16503
  const { ungrouped, groups } = _react.useMemo.call(void 0, () => partitionTabs(_nullishCoalesce(tabs, () => ( []))), [tabs]);
16501
16504
  const tabItems = _react.useMemo.call(void 0,
16502
16505
  () => Object.fromEntries((_nullishCoalesce(tabs, () => ( []))).map((tab) => [tabValue(tab), _nullishCoalesce(tab.contentLabel, () => ( tab.label))])),
@@ -16507,7 +16510,7 @@ function RoundPageContainer({
16507
16510
  const mobileFlow = isMobile && isFixed && (!activeFillHeight || activeDocumentTab) && !fullWidth;
16508
16511
  const innerClip = mobileFlow ? `` : clip;
16509
16512
  const innerScrollY = mobileFlow ? `` : scrollY;
16510
- const showMobileSectionPicker = (_nullishCoalesce(_optionalChain([tabs, 'optionalAccess', _498 => _498.length]), () => ( 0))) > 1;
16513
+ const showMobileSectionPicker = (_nullishCoalesce(_optionalChain([tabs, 'optionalAccess', _499 => _499.length]), () => ( 0))) > 1;
16511
16514
  if (!isReady) {
16512
16515
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
16513
16516
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -16909,14 +16912,14 @@ function BlockNoteEditorMentionHoverCard({
16909
16912
  const entityType = target.dataset.mentionType;
16910
16913
  const alias = target.dataset.mentionAlias;
16911
16914
  setHovered((prev) => {
16912
- if (_optionalChain([prev, 'optionalAccess', _499 => _499.id]) === id && _optionalChain([prev, 'optionalAccess', _500 => _500.element]) === target) return prev;
16915
+ if (_optionalChain([prev, 'optionalAccess', _500 => _500.id]) === id && _optionalChain([prev, 'optionalAccess', _501 => _501.element]) === target) return prev;
16913
16916
  return { id, entityType, alias, element: target };
16914
16917
  });
16915
16918
  }, "handleMouseOver");
16916
16919
  const handleMouseOut = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (e) => {
16917
16920
  const target = e.target.closest("[data-mention-id]");
16918
16921
  if (!target) return;
16919
- const related = _optionalChain([e, 'access', _501 => _501.relatedTarget, 'optionalAccess', _502 => _502.closest, 'call', _503 => _503("[data-mention-id]")]);
16922
+ const related = _optionalChain([e, 'access', _502 => _502.relatedTarget, 'optionalAccess', _503 => _503.closest, 'call', _504 => _504("[data-mention-id]")]);
16920
16923
  if (related) return;
16921
16924
  scheduleClose();
16922
16925
  }, "handleMouseOut");
@@ -16930,7 +16933,7 @@ function BlockNoteEditorMentionHoverCard({
16930
16933
  }, [containerRef, mentionResolveFn, cancelClose, scheduleClose]);
16931
16934
  if (!hovered || !mentionResolveFn) return null;
16932
16935
  const resolved = mentionResolveFn(hovered.id, hovered.entityType, hovered.alias);
16933
- if (!_optionalChain([resolved, 'optionalAccess', _504 => _504.HoverContent])) return null;
16936
+ if (!_optionalChain([resolved, 'optionalAccess', _505 => _505.HoverContent])) return null;
16934
16937
  const ContentComponent = resolved.HoverContent;
16935
16938
  const rect = hovered.element.getBoundingClientRect();
16936
16939
  return _reactdom.createPortal.call(void 0,
@@ -16974,28 +16977,28 @@ var parseMentionElement = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (
16974
16977
  }, "parseMentionElement");
16975
16978
  var createMentionInlineContentSpec = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (resolveFn, disableMention, nameResolver) => {
16976
16979
  const MentionExternalHTML = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (props) => {
16977
- const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall', _505 => _505(props.id, props.entityType, props.alias)]), () => ( props.alias));
16980
+ const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall', _506 => _506(props.id, props.entityType, props.alias)]), () => ( props.alias));
16978
16981
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { "data-mention-id": props.id, "data-mention-type": props.entityType, "data-mention-alias": props.alias, children: [
16979
16982
  "@",
16980
16983
  displayName
16981
16984
  ] });
16982
16985
  }, "MentionExternalHTML");
16983
16986
  const Mention = React2.default.memo(/* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, function Mention2(props) {
16984
- const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall', _506 => _506(props.id, props.entityType, props.alias)]), () => ( props.alias));
16987
+ const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall', _507 => _507(props.id, props.entityType, props.alias)]), () => ( props.alias));
16985
16988
  if (disableMention) {
16986
- const resolved2 = _optionalChain([resolveFn, 'optionalCall', _507 => _507(props.id, props.entityType, displayName)]);
16987
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _link2.default, { href: _nullishCoalesce(_optionalChain([resolved2, 'optionalAccess', _508 => _508.url]), () => ( "#")), className: "text-primary", children: [
16989
+ const resolved2 = _optionalChain([resolveFn, 'optionalCall', _508 => _508(props.id, props.entityType, displayName)]);
16990
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _link2.default, { href: _nullishCoalesce(_optionalChain([resolved2, 'optionalAccess', _509 => _509.url]), () => ( "#")), className: "text-primary", children: [
16988
16991
  "@",
16989
16992
  displayName
16990
16993
  ] });
16991
16994
  }
16992
- const resolved = _optionalChain([resolveFn, 'optionalCall', _509 => _509(props.id, props.entityType, displayName)]);
16993
- if (_optionalChain([resolved, 'optionalAccess', _510 => _510.Inline])) {
16995
+ const resolved = _optionalChain([resolveFn, 'optionalCall', _510 => _510(props.id, props.entityType, displayName)]);
16996
+ if (_optionalChain([resolved, 'optionalAccess', _511 => _511.Inline])) {
16994
16997
  const Custom = resolved.Inline;
16995
16998
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Custom, { ...props, alias: displayName });
16996
16999
  }
16997
- const href = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _511 => _511.url]), () => ( "#"));
16998
- const handleClick = _optionalChain([resolved, 'optionalAccess', _512 => _512.onActivate]) ? (e) => resolved.onActivate(e, props) : void 0;
17000
+ const href = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _512 => _512.url]), () => ( "#"));
17001
+ const handleClick = _optionalChain([resolved, 'optionalAccess', _513 => _513.onActivate]) ? (e) => resolved.onActivate(e, props) : void 0;
16999
17002
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
17000
17003
  _link2.default,
17001
17004
  {
@@ -17103,7 +17106,7 @@ function BlockNoteEditorMentionSuggestionMenu({
17103
17106
  if (!suggestionMenuComponent) return void 0;
17104
17107
  const Component2 = suggestionMenuComponent;
17105
17108
  const Wrapped = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (props) => {
17106
- const isSentinelOnly = props.items.length === 1 && _optionalChain([props, 'access', _513 => _513.items, 'access', _514 => _514[0], 'optionalAccess', _515 => _515.title]) === KEEP_OPEN_SENTINEL_TITLE;
17109
+ const isSentinelOnly = props.items.length === 1 && _optionalChain([props, 'access', _514 => _514.items, 'access', _515 => _515[0], 'optionalAccess', _516 => _516.title]) === KEEP_OPEN_SENTINEL_TITLE;
17107
17110
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
17108
17111
  Component2,
17109
17112
  {
@@ -17112,7 +17115,7 @@ function BlockNoteEditorMentionSuggestionMenu({
17112
17115
  selectedIndex: isSentinelOnly ? void 0 : props.selectedIndex,
17113
17116
  onItemClick: (item) => {
17114
17117
  if (item.title === KEEP_OPEN_SENTINEL_TITLE) return;
17115
- _optionalChain([props, 'access', _516 => _516.onItemClick, 'optionalCall', _517 => _517(item)]);
17118
+ _optionalChain([props, 'access', _517 => _517.onItemClick, 'optionalCall', _518 => _518(item)]);
17116
17119
  }
17117
17120
  }
17118
17121
  );
@@ -17359,10 +17362,10 @@ var cellId = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => {
17359
17362
  cell: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ row }) => params.toggleId ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
17360
17363
  SelectRowCheckbox,
17361
17364
  {
17362
- checked: _optionalChain([params, 'access', _518 => _518.checkedIds, 'optionalAccess', _519 => _519.includes, 'call', _520 => _520(row.getValue(params.name))]) || false,
17365
+ checked: _optionalChain([params, 'access', _519 => _519.checkedIds, 'optionalAccess', _520 => _520.includes, 'call', _521 => _521(row.getValue(params.name))]) || false,
17363
17366
  onCheckedChange: (value) => {
17364
17367
  row.toggleSelected(!!value);
17365
- _optionalChain([params, 'access', _521 => _521.toggleId, 'optionalCall', _522 => _522(row.getValue(params.name))]);
17368
+ _optionalChain([params, 'access', _522 => _522.toggleId, 'optionalCall', _523 => _523(row.getValue(params.name))]);
17366
17369
  }
17367
17370
  }
17368
17371
  ) : null, "cell"),
@@ -17420,7 +17423,7 @@ function useJsonApiGet(params) {
17420
17423
  const [response, setResponse] = _react.useState.call(void 0, null);
17421
17424
  const isMounted = _react.useRef.call(void 0, true);
17422
17425
  const fetchData = _react.useCallback.call(void 0, async () => {
17423
- if (_optionalChain([params, 'access', _523 => _523.options, 'optionalAccess', _524 => _524.enabled]) === false) return;
17426
+ if (_optionalChain([params, 'access', _524 => _524.options, 'optionalAccess', _525 => _525.enabled]) === false) return;
17424
17427
  setLoading(true);
17425
17428
  setError(null);
17426
17429
  try {
@@ -17447,9 +17450,9 @@ function useJsonApiGet(params) {
17447
17450
  setLoading(false);
17448
17451
  }
17449
17452
  }
17450
- }, [params.classKey, params.endpoint, params.companyId, _optionalChain([params, 'access', _525 => _525.options, 'optionalAccess', _526 => _526.enabled])]);
17453
+ }, [params.classKey, params.endpoint, params.companyId, _optionalChain([params, 'access', _526 => _526.options, 'optionalAccess', _527 => _527.enabled])]);
17451
17454
  const fetchNextPage = _react.useCallback.call(void 0, async () => {
17452
- if (!_optionalChain([response, 'optionalAccess', _527 => _527.nextPage])) return;
17455
+ if (!_optionalChain([response, 'optionalAccess', _528 => _528.nextPage])) return;
17453
17456
  setLoading(true);
17454
17457
  try {
17455
17458
  const nextResponse = await response.nextPage();
@@ -17470,7 +17473,7 @@ function useJsonApiGet(params) {
17470
17473
  }
17471
17474
  }, [response]);
17472
17475
  const fetchPreviousPage = _react.useCallback.call(void 0, async () => {
17473
- if (!_optionalChain([response, 'optionalAccess', _528 => _528.prevPage])) return;
17476
+ if (!_optionalChain([response, 'optionalAccess', _529 => _529.prevPage])) return;
17474
17477
  setLoading(true);
17475
17478
  try {
17476
17479
  const prevResponse = await response.prevPage();
@@ -17496,15 +17499,15 @@ function useJsonApiGet(params) {
17496
17499
  return () => {
17497
17500
  isMounted.current = false;
17498
17501
  };
17499
- }, [fetchData, ..._optionalChain([params, 'access', _529 => _529.options, 'optionalAccess', _530 => _530.deps]) || []]);
17502
+ }, [fetchData, ..._optionalChain([params, 'access', _530 => _530.options, 'optionalAccess', _531 => _531.deps]) || []]);
17500
17503
  return {
17501
17504
  data,
17502
17505
  loading,
17503
17506
  error,
17504
17507
  response,
17505
17508
  refetch: fetchData,
17506
- hasNextPage: !!_optionalChain([response, 'optionalAccess', _531 => _531.next]),
17507
- hasPreviousPage: !!_optionalChain([response, 'optionalAccess', _532 => _532.prev]),
17509
+ hasNextPage: !!_optionalChain([response, 'optionalAccess', _532 => _532.next]),
17510
+ hasPreviousPage: !!_optionalChain([response, 'optionalAccess', _533 => _533.prev]),
17508
17511
  fetchNextPage,
17509
17512
  fetchPreviousPage
17510
17513
  };
@@ -17582,17 +17585,17 @@ function useJsonApiMutation(config) {
17582
17585
  if (apiResponse.ok) {
17583
17586
  const resultData = apiResponse.data;
17584
17587
  setData(resultData);
17585
- _optionalChain([config, 'access', _533 => _533.onSuccess, 'optionalCall', _534 => _534(resultData)]);
17588
+ _optionalChain([config, 'access', _534 => _534.onSuccess, 'optionalCall', _535 => _535(resultData)]);
17586
17589
  return resultData;
17587
17590
  } else {
17588
17591
  setError(apiResponse.error);
17589
- _optionalChain([config, 'access', _535 => _535.onError, 'optionalCall', _536 => _536(apiResponse.error)]);
17592
+ _optionalChain([config, 'access', _536 => _536.onError, 'optionalCall', _537 => _537(apiResponse.error)]);
17590
17593
  return null;
17591
17594
  }
17592
17595
  } catch (err) {
17593
17596
  const errorMessage = err instanceof Error ? err.message : "Unknown error";
17594
17597
  setError(errorMessage);
17595
- _optionalChain([config, 'access', _537 => _537.onError, 'optionalCall', _538 => _538(errorMessage)]);
17598
+ _optionalChain([config, 'access', _538 => _538.onError, 'optionalCall', _539 => _539(errorMessage)]);
17596
17599
  return null;
17597
17600
  } finally {
17598
17601
  setLoading(false);
@@ -17665,7 +17668,7 @@ var useCompanyTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void
17665
17668
  {
17666
17669
  href: hasRole(_chunkG4JR3SFVjs.getRoleId.call(void 0, ).Administrator) ? generateUrl({
17667
17670
  page: "/administration",
17668
- id: _optionalChain([_chunkP7L6OFX5js.Modules, 'access', _539 => _539.Company, 'access', _540 => _540.pageUrl, 'optionalAccess', _541 => _541.substring, 'call', _542 => _542(1)]),
17671
+ id: _optionalChain([_chunkP7L6OFX5js.Modules, 'access', _540 => _540.Company, 'access', _541 => _541.pageUrl, 'optionalAccess', _542 => _542.substring, 'call', _543 => _543(1)]),
17669
17672
  childPage: company.id
17670
17673
  }) : generateUrl({ page: _chunkP7L6OFX5js.Modules.Company, id: company.id }),
17671
17674
  children: row.getValue("name")
@@ -17681,7 +17684,7 @@ var useCompanyTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void
17681
17684
  })
17682
17685
  };
17683
17686
  const columns = _react.useMemo.call(void 0, () => {
17684
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _543 => _543[field], 'optionalCall', _544 => _544()])).filter((col) => col !== void 0);
17687
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _544 => _544[field], 'optionalCall', _545 => _545()])).filter((col) => col !== void 0);
17685
17688
  }, [params.fields, fieldColumnMap, t, generateUrl, hasRole]);
17686
17689
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
17687
17690
  }, "useCompanyTableStructure");
@@ -17694,7 +17697,7 @@ var DAY_MS = 1e3 * 60 * 60 * 24;
17694
17697
  var isAdministrator = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (currentUser) => {
17695
17698
  if (!currentUser || !_chunkG4JR3SFVjs.isRolesConfigured.call(void 0, )) return false;
17696
17699
  const adminRoleId = _chunkG4JR3SFVjs.getRoleId.call(void 0, ).Administrator;
17697
- return !!_optionalChain([currentUser, 'access', _545 => _545.roles, 'optionalAccess', _546 => _546.some, 'call', _547 => _547((role) => role.id === adminRoleId)]);
17700
+ return !!_optionalChain([currentUser, 'access', _546 => _546.roles, 'optionalAccess', _547 => _547.some, 'call', _548 => _548((role) => role.id === adminRoleId)]);
17698
17701
  }, "isAdministrator");
17699
17702
  function useSubscriptionStatus() {
17700
17703
  const { company, currentUser } = useCurrentUserContext();
@@ -17811,7 +17814,7 @@ var useRoleTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0,
17811
17814
  })
17812
17815
  };
17813
17816
  const columns = _react.useMemo.call(void 0, () => {
17814
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _548 => _548[field], 'optionalCall', _549 => _549()])).filter((col) => col !== void 0);
17817
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _549 => _549[field], 'optionalCall', _550 => _550()])).filter((col) => col !== void 0);
17815
17818
  }, [params.fields, fieldColumnMap, t, generateUrl]);
17816
17819
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
17817
17820
  }, "useRoleTableStructure");
@@ -17851,12 +17854,12 @@ _chunk7QVYU63Ejs.__name.call(void 0, useBillingFormatOptions, "useBillingFormatO
17851
17854
 
17852
17855
  // src/features/billing/components/utils/discount.ts
17853
17856
  function promotionCodeDiscount(code) {
17854
- if (!_optionalChain([code, 'optionalAccess', _550 => _550.valid]) || !code.discountType || !code.discountValue) return null;
17857
+ if (!_optionalChain([code, 'optionalAccess', _551 => _551.valid]) || !code.discountType || !code.discountValue) return null;
17855
17858
  return { discountType: code.discountType, discountValue: code.discountValue, currency: code.currency };
17856
17859
  }
17857
17860
  _chunk7QVYU63Ejs.__name.call(void 0, promotionCodeDiscount, "promotionCodeDiscount");
17858
17861
  function subscriptionDiscount(subscription) {
17859
- const discount = _optionalChain([subscription, 'optionalAccess', _551 => _551.discount]);
17862
+ const discount = _optionalChain([subscription, 'optionalAccess', _552 => _552.discount]);
17860
17863
  if (!discount) return null;
17861
17864
  if (discount.percentOff) return { discountType: "percent_off", discountValue: discount.percentOff };
17862
17865
  if (discount.amountOff) {
@@ -17878,8 +17881,8 @@ var useStripePriceTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(
17878
17881
  const t = _nextintl.useTranslations.call(void 0, );
17879
17882
  const fmt = useBillingFormatOptions();
17880
17883
  const generateUrl = usePageUrlGenerator();
17881
- const onClone = _optionalChain([params, 'access', _552 => _552.context, 'optionalAccess', _553 => _553.onClone]);
17882
- const onExport = _optionalChain([params, 'access', _554 => _554.context, 'optionalAccess', _555 => _555.onExport]);
17884
+ const onClone = _optionalChain([params, 'access', _553 => _553.context, 'optionalAccess', _554 => _554.onClone]);
17885
+ const onExport = _optionalChain([params, 'access', _555 => _555.context, 'optionalAccess', _556 => _556.onExport]);
17883
17886
  const tableData = _react.useMemo.call(void 0, () => {
17884
17887
  return params.data.map((price) => {
17885
17888
  const entry = { jsonApiData: price };
@@ -17944,7 +17947,7 @@ var useStripePriceTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(
17944
17947
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "flex flex-wrap items-center gap-1", children: [
17945
17948
  price.active ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "softGreen", children: t("billing.admin.prices.status.active") }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "softGray", children: t("billing.admin.prices.status.archived") }),
17946
17949
  price.isTrial && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.trial") }),
17947
- _optionalChain([price, 'access', _556 => _556.recurring, 'optionalAccess', _557 => _557.usageType]) === "metered" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.metered") })
17950
+ _optionalChain([price, 'access', _557 => _557.recurring, 'optionalAccess', _558 => _558.usageType]) === "metered" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "softBlue", children: t("billing.admin.prices.badge.metered") })
17948
17951
  ] });
17949
17952
  }, "cell"),
17950
17953
  enableSorting: false,
@@ -17992,7 +17995,7 @@ var useStripePriceTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(
17992
17995
  })
17993
17996
  };
17994
17997
  const columns = _react.useMemo.call(void 0, () => {
17995
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _558 => _558[field], 'optionalCall', _559 => _559()])).filter((col) => col !== void 0);
17998
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _559 => _559[field], 'optionalCall', _560 => _560()])).filter((col) => col !== void 0);
17996
17999
  }, [params.fields, fieldColumnMap, t, fmt, generateUrl, onClone, onExport]);
17997
18000
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
17998
18001
  }, "useStripePriceTableStructure");
@@ -18051,7 +18054,7 @@ var useStripeProductTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.cal
18051
18054
  })
18052
18055
  };
18053
18056
  const columns = _react.useMemo.call(void 0, () => {
18054
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _560 => _560[field], 'optionalCall', _561 => _561()])).filter((col) => col !== void 0);
18057
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _561 => _561[field], 'optionalCall', _562 => _562()])).filter((col) => col !== void 0);
18055
18058
  }, [params.fields, fieldColumnMap, t, generateUrl]);
18056
18059
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
18057
18060
  }, "useStripeProductTableStructure");
@@ -18135,7 +18138,7 @@ var useStripeCouponTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call
18135
18138
  })
18136
18139
  };
18137
18140
  const columns = _react.useMemo.call(void 0, () => {
18138
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _562 => _562[field], 'optionalCall', _563 => _563()])).filter((col) => col !== void 0);
18141
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _563 => _563[field], 'optionalCall', _564 => _564()])).filter((col) => col !== void 0);
18139
18142
  }, [params.fields, fieldColumnMap, t, generateUrl]);
18140
18143
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
18141
18144
  }, "useStripeCouponTableStructure");
@@ -18264,13 +18267,13 @@ var toCouponCodeInput = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (va
18264
18267
  firstTimeTransaction: values.firstTimeTransaction,
18265
18268
  automatic: values.automatic
18266
18269
  };
18267
- if (_optionalChain([values, 'access', _564 => _564.code, 'optionalAccess', _565 => _565.trim, 'call', _566 => _566()])) input.code = values.code.trim();
18270
+ if (_optionalChain([values, 'access', _565 => _565.code, 'optionalAccess', _566 => _566.trim, 'call', _567 => _567()])) input.code = values.code.trim();
18268
18271
  const minimumAmount = parseOptionalDecimal(values.minimumAmount);
18269
18272
  if (minimumAmount !== void 0) {
18270
18273
  input.minimumAmount = Math.round(minimumAmount * 100);
18271
18274
  input.minimumAmountCurrency = values.minimumAmountCurrency;
18272
18275
  }
18273
- if (_optionalChain([values, 'access', _567 => _567.stripeCustomerId, 'optionalAccess', _568 => _568.trim, 'call', _569 => _569()])) input.stripeCustomerId = values.stripeCustomerId.trim();
18276
+ if (_optionalChain([values, 'access', _568 => _568.stripeCustomerId, 'optionalAccess', _569 => _569.trim, 'call', _570 => _570()])) input.stripeCustomerId = values.stripeCustomerId.trim();
18274
18277
  if (values.expiresAt) input.expiresAt = values.expiresAt;
18275
18278
  const maxRedemptions = parseOptionalPositiveInt(values.maxRedemptions);
18276
18279
  if (maxRedemptions !== void 0) input.maxRedemptions = maxRedemptions;
@@ -18439,7 +18442,7 @@ function toCouponInput(values) {
18439
18442
  ...toDiscountInput(values),
18440
18443
  ...toDurationInput(values)
18441
18444
  };
18442
- if (_optionalChain([values, 'access', _570 => _570.stripeCouponId, 'optionalAccess', _571 => _571.trim, 'call', _572 => _572()])) payload.stripeCouponId = values.stripeCouponId.trim();
18445
+ if (_optionalChain([values, 'access', _571 => _571.stripeCouponId, 'optionalAccess', _572 => _572.trim, 'call', _573 => _573()])) payload.stripeCouponId = values.stripeCouponId.trim();
18443
18446
  if (values.products.length > 0) payload.productIds = values.products.map((product) => product.id);
18444
18447
  if (values.redeemBy) payload.redeemBy = values.redeemBy;
18445
18448
  const maxRedemptions = parseOptionalPositiveInt(values.maxRedemptions);
@@ -18762,9 +18765,9 @@ var CouponProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ chi
18762
18765
  const [catalogueVersion, setCatalogueVersion] = _react.useState.call(void 0, 0);
18763
18766
  const refreshCatalogue = _react.useCallback.call(void 0, () => setCatalogueVersion((value2) => value2 + 1), []);
18764
18767
  const reloadCoupon = _react.useCallback.call(void 0, async () => {
18765
- if (!_optionalChain([coupon, 'optionalAccess', _573 => _573.id])) return;
18768
+ if (!_optionalChain([coupon, 'optionalAccess', _574 => _574.id])) return;
18766
18769
  setCoupon(await _chunkHN7L6RRWjs.StripeCouponService.getCoupon({ id: coupon.id }));
18767
- }, [_optionalChain([coupon, 'optionalAccess', _574 => _574.id])]);
18770
+ }, [_optionalChain([coupon, 'optionalAccess', _575 => _575.id])]);
18768
18771
  const createCoupon = _react.useCallback.call(void 0,
18769
18772
  async (input) => {
18770
18773
  const saved = await _chunkHN7L6RRWjs.StripeCouponService.createCoupon(input);
@@ -18784,13 +18787,13 @@ var CouponProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ chi
18784
18787
  );
18785
18788
  const refreshCounts = _react.useCallback.call(void 0,
18786
18789
  async (id) => {
18787
- const target = _nullishCoalesce(id, () => ( _optionalChain([coupon, 'optionalAccess', _575 => _575.id])));
18790
+ const target = _nullishCoalesce(id, () => ( _optionalChain([coupon, 'optionalAccess', _576 => _576.id])));
18788
18791
  if (!target) return;
18789
18792
  const saved = await _chunkHN7L6RRWjs.StripeCouponService.refreshCounts({ id: target });
18790
- if (_optionalChain([coupon, 'optionalAccess', _576 => _576.id]) === target) setCoupon(saved);
18793
+ if (_optionalChain([coupon, 'optionalAccess', _577 => _577.id]) === target) setCoupon(saved);
18791
18794
  refreshCatalogue();
18792
18795
  },
18793
- [_optionalChain([coupon, 'optionalAccess', _577 => _577.id]), refreshCatalogue]
18796
+ [_optionalChain([coupon, 'optionalAccess', _578 => _578.id]), refreshCatalogue]
18794
18797
  );
18795
18798
  const createCode = _react.useCallback.call(void 0,
18796
18799
  async (input) => {
@@ -19028,7 +19031,7 @@ var useStripeCouponCodeTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.
19028
19031
  })
19029
19032
  };
19030
19033
  const columns = _react.useMemo.call(void 0, () => {
19031
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _578 => _578[field], 'optionalCall', _579 => _579()])).filter((col) => col !== void 0);
19034
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _579 => _579[field], 'optionalCall', _580 => _580()])).filter((col) => col !== void 0);
19032
19035
  }, [params.fields, fieldColumnMap, t, coupon, now]);
19033
19036
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
19034
19037
  }, "useStripeCouponCodeTableStructure");
@@ -19054,7 +19057,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, formatSignupSource, "formatSignupSource");
19054
19057
  var useWaitlistTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => {
19055
19058
  const t = _nextintl.useTranslations.call(void 0, );
19056
19059
  const locale = _chunkP7L6OFX5js.useI18nLocale.call(void 0, );
19057
- const onInvite = _optionalChain([params, 'access', _580 => _580.context, 'optionalAccess', _581 => _581.onInvite]);
19060
+ const onInvite = _optionalChain([params, 'access', _581 => _581.context, 'optionalAccess', _582 => _582.onInvite]);
19058
19061
  const tableData = _react.useMemo.call(void 0, () => {
19059
19062
  return params.data.map((entry) => {
19060
19063
  const row = { jsonApiData: entry };
@@ -19149,7 +19152,7 @@ var useWaitlistTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(voi
19149
19152
  cell: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ row }) => {
19150
19153
  const entry = row.original.jsonApiData;
19151
19154
  if (entry.status === "confirmed") {
19152
- return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Button, { size: "sm", variant: "outline", onClick: () => _optionalChain([onInvite, 'optionalCall', _582 => _582(entry)]), children: [
19155
+ return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Button, { size: "sm", variant: "outline", onClick: () => _optionalChain([onInvite, 'optionalCall', _583 => _583(entry)]), children: [
19153
19156
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Send, { className: "me-2 h-4 w-4" }),
19154
19157
  t("waitlist.admin.actions.invite")
19155
19158
  ] });
@@ -19167,7 +19170,7 @@ var useWaitlistTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(voi
19167
19170
  })
19168
19171
  };
19169
19172
  const columns = _react.useMemo.call(void 0, () => {
19170
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _583 => _583[field], 'optionalCall', _584 => _584()])).filter((col) => col !== void 0);
19173
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _584 => _584[field], 'optionalCall', _585 => _585()])).filter((col) => col !== void 0);
19171
19174
  }, [params.fields, fieldColumnMap, t, locale]);
19172
19175
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
19173
19176
  }, "useWaitlistTableStructure");
@@ -19268,11 +19271,11 @@ var useContentTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void
19268
19271
  return params.fields.map((field) => {
19269
19272
  const localHandler = fieldColumnMap[field];
19270
19273
  if (localHandler) return localHandler();
19271
- const customHandler = _optionalChain([params, 'access', _585 => _585.context, 'optionalAccess', _586 => _586.customCells, 'optionalAccess', _587 => _587[field]]);
19274
+ const customHandler = _optionalChain([params, 'access', _586 => _586.context, 'optionalAccess', _587 => _587.customCells, 'optionalAccess', _588 => _588[field]]);
19272
19275
  if (customHandler) return customHandler({ t });
19273
19276
  return void 0;
19274
19277
  }).filter((col) => col !== void 0);
19275
- }, [params.fields, fieldColumnMap, t, generateUrl, _optionalChain([params, 'access', _588 => _588.context, 'optionalAccess', _589 => _589.customCells])]);
19278
+ }, [params.fields, fieldColumnMap, t, generateUrl, _optionalChain([params, 'access', _589 => _589.context, 'optionalAccess', _590 => _590.customCells])]);
19276
19279
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
19277
19280
  }, "useContentTableStructure");
19278
19281
 
@@ -19507,17 +19510,17 @@ function useOAuthConsent(params, options) {
19507
19510
  const [error, setError] = _react.useState.call(void 0, null);
19508
19511
  const [isSubmitting, setIsSubmitting] = _react.useState.call(void 0, false);
19509
19512
  const [companyId, setCompanyId] = _react.useState.call(void 0, void 0);
19510
- const contextCompanyId = _optionalChain([useCurrentUserContextOptional, 'call', _590 => _590(), 'optionalAccess', _591 => _591.company, 'optionalAccess', _592 => _592.id]);
19511
- const currentCompanyId = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _593 => _593.defaultCompanyId]), () => ( contextCompanyId));
19513
+ const contextCompanyId = _optionalChain([useCurrentUserContextOptional, 'call', _591 => _591(), 'optionalAccess', _592 => _592.company, 'optionalAccess', _593 => _593.id]);
19514
+ const currentCompanyId = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _594 => _594.defaultCompanyId]), () => ( contextCompanyId));
19512
19515
  const t = _nextintl.useTranslations.call(void 0, );
19513
19516
  const tRef = _react.useRef.call(void 0, t);
19514
19517
  tRef.current = t;
19515
19518
  _react.useEffect.call(void 0, () => {
19516
- const companies = _nullishCoalesce(_optionalChain([clientInfo, 'optionalAccess', _594 => _594.companies]), () => ( []));
19519
+ const companies = _nullishCoalesce(_optionalChain([clientInfo, 'optionalAccess', _595 => _595.companies]), () => ( []));
19517
19520
  if (companies.length === 0) return;
19518
19521
  if (companyId && companies.some((company) => company.id === companyId)) return;
19519
19522
  const current = currentCompanyId ? companies.find((company) => company.id === currentCompanyId) : void 0;
19520
- setCompanyId(_nullishCoalesce(_optionalChain([current, 'optionalAccess', _595 => _595.id]), () => ( _optionalChain([companies, 'access', _596 => _596[0], 'optionalAccess', _597 => _597.id]))));
19523
+ setCompanyId(_nullishCoalesce(_optionalChain([current, 'optionalAccess', _596 => _596.id]), () => ( _optionalChain([companies, 'access', _597 => _597[0], 'optionalAccess', _598 => _598.id]))));
19521
19524
  }, [clientInfo, currentCompanyId, companyId]);
19522
19525
  _react.useEffect.call(void 0, () => {
19523
19526
  const fetchInfo = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
@@ -19603,7 +19606,7 @@ function useOAuthScopeText() {
19603
19606
  };
19604
19607
  }
19605
19608
  const info = typeof scope === "string" ? void 0 : scope;
19606
- return { name: _optionalChain([info, 'optionalAccess', _598 => _598.name]) || id, description: _nullishCoalesce(_optionalChain([info, 'optionalAccess', _599 => _599.description]), () => ( "")) };
19609
+ return { name: _optionalChain([info, 'optionalAccess', _599 => _599.name]) || id, description: _nullishCoalesce(_optionalChain([info, 'optionalAccess', _600 => _600.description]), () => ( "")) };
19607
19610
  },
19608
19611
  [t]
19609
19612
  );
@@ -19659,7 +19662,7 @@ function ContentTableSearch({ data }) {
19659
19662
  const handleSearchIconClick = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
19660
19663
  if (!isExpanded) {
19661
19664
  setIsFocused(true);
19662
- setTimeout(() => _optionalChain([inputRef, 'access', _600 => _600.current, 'optionalAccess', _601 => _601.focus, 'call', _602 => _602()]), 50);
19665
+ setTimeout(() => _optionalChain([inputRef, 'access', _601 => _601.current, 'optionalAccess', _602 => _602.focus, 'call', _603 => _603()]), 50);
19663
19666
  }
19664
19667
  }, "handleSearchIconClick");
19665
19668
  const handleBlur = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
@@ -19745,7 +19748,7 @@ function getGroupKeys(item, field) {
19745
19748
  return [String(_nullishCoalesce(value, () => ( "")))];
19746
19749
  }
19747
19750
  _chunk7QVYU63Ejs.__name.call(void 0, getGroupKeys, "getGroupKeys");
19748
- var isClassComponent = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (component) => typeof component === "function" && !!_optionalChain([component, 'access', _603 => _603.prototype, 'optionalAccess', _604 => _604.isReactComponent]), "isClassComponent");
19751
+ var isClassComponent = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (component) => typeof component === "function" && !!_optionalChain([component, 'access', _604 => _604.prototype, 'optionalAccess', _605 => _605.isReactComponent]), "isClassComponent");
19749
19752
  function StableCell({ render, context }) {
19750
19753
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: render(context) });
19751
19754
  }
@@ -19769,7 +19772,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19769
19772
  if (data.isLoaded) setPendingDirection(null);
19770
19773
  }, [data.isLoaded]);
19771
19774
  const { data: tableData, columns: tableColumns } = useTableGenerator(props.tableGeneratorType, {
19772
- data: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _605 => _605.data]), () => ( EMPTY_ARRAY)),
19775
+ data: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _606 => _606.data]), () => ( EMPTY_ARRAY)),
19773
19776
  fields,
19774
19777
  checkedIds,
19775
19778
  toggleId,
@@ -19799,7 +19802,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19799
19802
  ...props.renderExpandedRow && {
19800
19803
  getExpandedRowModel: _reacttable.getExpandedRowModel.call(void 0, ),
19801
19804
  // Key rows by record id so an expansion stays with its record when a search or filter reorders the rows.
19802
- getRowId: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (row, index) => _nullishCoalesce(_optionalChain([row, 'access', _606 => _606.jsonApiData, 'optionalAccess', _607 => _607.id]), () => ( String(index))), "getRowId"),
19805
+ getRowId: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (row, index) => _nullishCoalesce(_optionalChain([row, 'access', _607 => _607.jsonApiData, 'optionalAccess', _608 => _608.id]), () => ( String(index))), "getRowId"),
19803
19806
  getRowCanExpand: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => true, "getRowCanExpand"),
19804
19807
  onExpandedChange: setExpanded,
19805
19808
  state: { expanded }
@@ -19816,7 +19819,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19816
19819
  });
19817
19820
  const rowModel = tableData ? table.getRowModel() : null;
19818
19821
  const groupedRows = _react.useMemo.call(void 0, () => {
19819
- if (!props.groupBy || !_optionalChain([rowModel, 'optionalAccess', _608 => _608.rows, 'optionalAccess', _609 => _609.length])) return null;
19822
+ if (!props.groupBy || !_optionalChain([rowModel, 'optionalAccess', _609 => _609.rows, 'optionalAccess', _610 => _610.length])) return null;
19820
19823
  const groupMap = /* @__PURE__ */ new Map();
19821
19824
  for (const row of rowModel.rows) {
19822
19825
  const keys = getGroupKeys(row.original, props.groupBy);
@@ -19895,20 +19898,20 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19895
19898
  ) }),
19896
19899
  !props.hideHeader && table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: headerGroup.headers.map((header) => {
19897
19900
  const meta = header.column.columnDef.meta;
19898
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableHead, { className: _optionalChain([meta, 'optionalAccess', _610 => _610.className]), children: header.isPlaceholder ? null : _reacttable.flexRender.call(void 0, header.column.columnDef.header, header.getContext()) }, header.id);
19901
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableHead, { className: _optionalChain([meta, 'optionalAccess', _611 => _611.className]), children: header.isPlaceholder ? null : _reacttable.flexRender.call(void 0, header.column.columnDef.header, header.getContext()) }, header.id);
19899
19902
  }) }, headerGroup.id))
19900
19903
  ] }),
19901
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableBody, { children: rowModel && _optionalChain([rowModel, 'access', _611 => _611.rows, 'optionalAccess', _612 => _612.length]) ? groupedRows ? groupedRows.map((group) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, React2.default.Fragment, { children: [
19902
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { colSpan: tableColumns.length, className: "bg-muted px-4 py-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, MicroLabel, { children: _nullishCoalesce(_optionalChain([props, 'access', _613 => _613.groupLabel, 'optionalCall', _614 => _614(group.groupKey)]), () => ( group.groupKey)) }) }) }),
19904
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableBody, { children: rowModel && _optionalChain([rowModel, 'access', _612 => _612.rows, 'optionalAccess', _613 => _613.length]) ? groupedRows ? groupedRows.map((group) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, React2.default.Fragment, { children: [
19905
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { colSpan: tableColumns.length, className: "bg-muted px-4 py-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, MicroLabel, { children: _nullishCoalesce(_optionalChain([props, 'access', _614 => _614.groupLabel, 'optionalCall', _615 => _615(group.groupKey)]), () => ( group.groupKey)) }) }) }),
19903
19906
  group.rows.map((row) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, React2.default.Fragment, { children: [
19904
19907
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
19905
19908
  TableRow,
19906
19909
  {
19907
- onClick: () => _optionalChain([onRowClick, 'optionalCall', _615 => _615(row.original.jsonApiData)]),
19910
+ onClick: () => _optionalChain([onRowClick, 'optionalCall', _616 => _616(row.original.jsonApiData)]),
19908
19911
  className: `group ${onRowClick ? "hover:bg-muted/50 cursor-pointer" : ""}`,
19909
19912
  children: row.getVisibleCells().map((cell) => {
19910
19913
  const meta = cell.column.columnDef.meta;
19911
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess', _616 => _616.className]), children: renderCell(cell.column.columnDef.cell, cell.getContext()) }, cell.id);
19914
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess', _617 => _617.className]), children: renderCell(cell.column.columnDef.cell, cell.getContext()) }, cell.id);
19912
19915
  })
19913
19916
  }
19914
19917
  ),
@@ -19918,11 +19921,11 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19918
19921
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
19919
19922
  TableRow,
19920
19923
  {
19921
- onClick: () => _optionalChain([onRowClick, 'optionalCall', _617 => _617(row.original.jsonApiData)]),
19924
+ onClick: () => _optionalChain([onRowClick, 'optionalCall', _618 => _618(row.original.jsonApiData)]),
19922
19925
  className: `group ${onRowClick ? "hover:bg-muted/50 cursor-pointer" : ""}`,
19923
19926
  children: row.getVisibleCells().map((cell) => {
19924
19927
  const meta = cell.column.columnDef.meta;
19925
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess', _618 => _618.className]), children: renderCell(cell.column.columnDef.cell, cell.getContext()) }, cell.id);
19928
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess', _619 => _619.className]), children: renderCell(cell.column.columnDef.cell, cell.getContext()) }, cell.id);
19926
19929
  })
19927
19930
  }
19928
19931
  ),
@@ -19937,7 +19940,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19937
19940
  onClick: (e) => {
19938
19941
  e.preventDefault();
19939
19942
  setPendingDirection("prev");
19940
- _optionalChain([data, 'access', _619 => _619.previous, 'optionalCall', _620 => _620(true)]);
19943
+ _optionalChain([data, 'access', _620 => _620.previous, 'optionalCall', _621 => _621(true)]);
19941
19944
  },
19942
19945
  disabled: !data.previous || pendingDirection !== null,
19943
19946
  children: pendingDirection === "prev" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ChevronLeft, { className: "h-4 w-4 rtl:rotate-180" })
@@ -19952,7 +19955,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
19952
19955
  onClick: (e) => {
19953
19956
  e.preventDefault();
19954
19957
  setPendingDirection("next");
19955
- _optionalChain([data, 'access', _621 => _621.next, 'optionalCall', _622 => _622(true)]);
19958
+ _optionalChain([data, 'access', _622 => _622.next, 'optionalCall', _623 => _623(true)]);
19956
19959
  },
19957
19960
  disabled: !data.next || pendingDirection !== null,
19958
19961
  children: pendingDirection === "next" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.Loader2, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ChevronRight, { className: "h-4 w-4 rtl:rotate-180" })
@@ -19974,7 +19977,7 @@ function ContentListGrid(props) {
19974
19977
  if (!data.next || !sentinelRef.current) return;
19975
19978
  const observer = new IntersectionObserver(
19976
19979
  (entries) => {
19977
- if (_optionalChain([entries, 'access', _623 => _623[0], 'optionalAccess', _624 => _624.isIntersecting])) _optionalChain([data, 'access', _625 => _625.next, 'optionalCall', _626 => _626()]);
19980
+ if (_optionalChain([entries, 'access', _624 => _624[0], 'optionalAccess', _625 => _625.isIntersecting])) _optionalChain([data, 'access', _626 => _626.next, 'optionalCall', _627 => _627()]);
19978
19981
  },
19979
19982
  { threshold: 0.1, rootMargin: "200px" }
19980
19983
  );
@@ -20826,7 +20829,7 @@ function TotpInput({ onComplete, disabled = false, autoFocus = true, error }) {
20826
20829
  newDigits[index] = digit;
20827
20830
  setDigits(newDigits);
20828
20831
  if (digit && index < 5) {
20829
- _optionalChain([inputRefs, 'access', _627 => _627.current, 'access', _628 => _628[index + 1], 'optionalAccess', _629 => _629.focus, 'call', _630 => _630()]);
20832
+ _optionalChain([inputRefs, 'access', _628 => _628.current, 'access', _629 => _629[index + 1], 'optionalAccess', _630 => _630.focus, 'call', _631 => _631()]);
20830
20833
  }
20831
20834
  const code = newDigits.join("");
20832
20835
  if (code.length === 6 && newDigits.every((d) => d !== "")) {
@@ -20835,7 +20838,7 @@ function TotpInput({ onComplete, disabled = false, autoFocus = true, error }) {
20835
20838
  }, "handleChange");
20836
20839
  const handleKeyDown = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (index, e) => {
20837
20840
  if (e.key === "Backspace" && !digits[index] && index > 0) {
20838
- _optionalChain([inputRefs, 'access', _631 => _631.current, 'access', _632 => _632[index - 1], 'optionalAccess', _633 => _633.focus, 'call', _634 => _634()]);
20841
+ _optionalChain([inputRefs, 'access', _632 => _632.current, 'access', _633 => _633[index - 1], 'optionalAccess', _634 => _634.focus, 'call', _635 => _635()]);
20839
20842
  }
20840
20843
  }, "handleKeyDown");
20841
20844
  const handlePaste = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (e) => {
@@ -20844,7 +20847,7 @@ function TotpInput({ onComplete, disabled = false, autoFocus = true, error }) {
20844
20847
  if (pastedData.length === 6) {
20845
20848
  const newDigits = pastedData.split("");
20846
20849
  setDigits(newDigits);
20847
- _optionalChain([inputRefs, 'access', _635 => _635.current, 'access', _636 => _636[5], 'optionalAccess', _637 => _637.focus, 'call', _638 => _638()]);
20850
+ _optionalChain([inputRefs, 'access', _636 => _636.current, 'access', _637 => _637[5], 'optionalAccess', _638 => _638.focus, 'call', _639 => _639()]);
20848
20851
  onComplete(pastedData);
20849
20852
  }
20850
20853
  }, "handlePaste");
@@ -21056,8 +21059,8 @@ function PasskeySetupDialog({ open, onOpenChange, onSuccess }) {
21056
21059
  try {
21057
21060
  const registrationData = await _chunkHN7L6RRWjs.TwoFactorService.getPasskeyRegistrationOptions({
21058
21061
  id: _uuid.v4.call(void 0, ),
21059
- userName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _639 => _639.email]), () => ( "")),
21060
- userDisplayName: _optionalChain([currentUser, 'optionalAccess', _640 => _640.name])
21062
+ userName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _640 => _640.email]), () => ( "")),
21063
+ userDisplayName: _optionalChain([currentUser, 'optionalAccess', _641 => _641.name])
21061
21064
  });
21062
21065
  const credential = await _browser.startRegistration.call(void 0, { optionsJSON: registrationData.options });
21063
21066
  await _chunkHN7L6RRWjs.TwoFactorService.verifyPasskeyRegistration({
@@ -21209,7 +21212,7 @@ function TotpSetupDialog({ onSuccess, trigger }) {
21209
21212
  const setup = await _chunkHN7L6RRWjs.TwoFactorService.setupTotp({
21210
21213
  id: _uuid.v4.call(void 0, ),
21211
21214
  name: name.trim(),
21212
- accountName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _641 => _641.email]), () => ( ""))
21215
+ accountName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _642 => _642.email]), () => ( ""))
21213
21216
  });
21214
21217
  setQrCodeUri(setup.qrCodeUri);
21215
21218
  setAuthenticatorId(setup.authenticatorId);
@@ -21343,7 +21346,7 @@ function TwoFactorSettings() {
21343
21346
  if (isLoading) {
21344
21347
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Card, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, CardContent, { className: "flex items-center justify-center py-8", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-muted-foreground", children: t("common.loading") }) }) });
21345
21348
  }
21346
- const isEnabled = _nullishCoalesce(_optionalChain([status, 'optionalAccess', _642 => _642.isEnabled]), () => ( false));
21349
+ const isEnabled = _nullishCoalesce(_optionalChain([status, 'optionalAccess', _643 => _643.isEnabled]), () => ( false));
21347
21350
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Card, { children: [
21348
21351
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, CardHeader, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
21349
21352
  isEnabled ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ShieldCheck, { className: "text-success h-6 w-6" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ShieldAlert, { className: "text-warning h-6 w-6" }),
@@ -21381,7 +21384,7 @@ function TwoFactorSettings() {
21381
21384
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "font-medium", children: t("auth.two_factor.backup_codes") }),
21382
21385
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: t("auth.two_factor.backup_codes_description") })
21383
21386
  ] }),
21384
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BackupCodesDialog, { remainingCodes: _nullishCoalesce(_optionalChain([status, 'optionalAccess', _643 => _643.backupCodesCount]), () => ( 0)), onRegenerate: handleRefresh })
21387
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, BackupCodesDialog, { remainingCodes: _nullishCoalesce(_optionalChain([status, 'optionalAccess', _644 => _644.backupCodesCount]), () => ( 0)), onRegenerate: handleRefresh })
21385
21388
  ] }) }),
21386
21389
  !isEnabled && (authenticators.length > 0 || passkeys.length > 0) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
21387
21390
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Separator, {}),
@@ -21563,9 +21566,9 @@ function AcceptInvitation() {
21563
21566
  });
21564
21567
  const onSubmit = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (values) => {
21565
21568
  try {
21566
- if (!_optionalChain([params, 'optionalAccess', _644 => _644.code])) return;
21569
+ if (!_optionalChain([params, 'optionalAccess', _645 => _645.code])) return;
21567
21570
  const payload = {
21568
- code: _optionalChain([params, 'optionalAccess', _645 => _645.code]),
21571
+ code: _optionalChain([params, 'optionalAccess', _646 => _646.code]),
21569
21572
  password: values.password
21570
21573
  };
21571
21574
  await _chunkHN7L6RRWjs.AuthService.acceptInvitation(payload);
@@ -21938,14 +21941,14 @@ function RefreshUser() {
21938
21941
  setUser(fullUser);
21939
21942
  const token = {
21940
21943
  userId: fullUser.id,
21941
- companyId: _optionalChain([fullUser, 'access', _646 => _646.company, 'optionalAccess', _647 => _647.id]),
21944
+ companyId: _optionalChain([fullUser, 'access', _647 => _647.company, 'optionalAccess', _648 => _648.id]),
21942
21945
  roles: fullUser.roles.map((role) => role.id),
21943
- features: _nullishCoalesce(_optionalChain([fullUser, 'access', _648 => _648.company, 'optionalAccess', _649 => _649.features, 'optionalAccess', _650 => _650.map, 'call', _651 => _651((feature) => feature.id)]), () => ( [])),
21946
+ features: _nullishCoalesce(_optionalChain([fullUser, 'access', _649 => _649.company, 'optionalAccess', _650 => _650.features, 'optionalAccess', _651 => _651.map, 'call', _652 => _652((feature) => feature.id)]), () => ( [])),
21944
21947
  modules: fullUser.modules.map((module) => {
21945
21948
  return { id: module.id, permissions: module.permissions };
21946
21949
  })
21947
21950
  };
21948
- await _optionalChain([_chunkHN7L6RRWjs.getTokenHandler.call(void 0, ), 'optionalAccess', _652 => _652.updateToken, 'call', _653 => _653(token)]);
21951
+ await _optionalChain([_chunkHN7L6RRWjs.getTokenHandler.call(void 0, ), 'optionalAccess', _653 => _653.updateToken, 'call', _654 => _654(token)]);
21949
21952
  _cookiesnext.deleteCookie.call(void 0, "reloadData");
21950
21953
  }
21951
21954
  }, "loadFullUser");
@@ -22009,9 +22012,9 @@ function ResetPassword() {
22009
22012
  });
22010
22013
  const onSubmit = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (values) => {
22011
22014
  try {
22012
- if (!_optionalChain([params, 'optionalAccess', _654 => _654.code])) return;
22015
+ if (!_optionalChain([params, 'optionalAccess', _655 => _655.code])) return;
22013
22016
  const payload = {
22014
- code: _optionalChain([params, 'optionalAccess', _655 => _655.code]),
22017
+ code: _optionalChain([params, 'optionalAccess', _656 => _656.code]),
22015
22018
  password: values.password
22016
22019
  };
22017
22020
  await _chunkHN7L6RRWjs.AuthService.resetPassword(payload);
@@ -22551,7 +22554,7 @@ function AiConnectionEditor({
22551
22554
  const registryRows = _react.useMemo.call(void 0, () => _nullishCoalesce(providerRegistry[connectionType], () => ( [])), [providerRegistry, connectionType]);
22552
22555
  const providers = _react.useMemo.call(void 0, () => registryRows.map((row) => row.provider), [registryRows]);
22553
22556
  const fieldsFor = _react.useCallback.call(void 0,
22554
- (provider) => _nullishCoalesce(_optionalChain([registryRows, 'access', _656 => _656.find, 'call', _657 => _657((row) => row.provider === provider), 'optionalAccess', _658 => _658.fields]), () => ( [])),
22557
+ (provider) => _nullishCoalesce(_optionalChain([registryRows, 'access', _657 => _657.find, 'call', _658 => _658((row) => row.provider === provider), 'optionalAccess', _659 => _659.fields]), () => ( [])),
22555
22558
  [registryRows]
22556
22559
  );
22557
22560
  const defaultsFor = _react.useCallback.call(void 0,
@@ -22560,7 +22563,7 @@ function AiConnectionEditor({
22560
22563
  const seeded = {};
22561
22564
  fieldsFor(provider).forEach((descriptor) => {
22562
22565
  if (descriptor.kind === "boolean") {
22563
- const current2 = _optionalChain([stored, 'optionalAccess', _659 => _659[descriptor.field]]);
22566
+ const current2 = _optionalChain([stored, 'optionalAccess', _660 => _660[descriptor.field]]);
22564
22567
  seeded[descriptor.field] = current2 !== void 0 && current2 !== null ? current2 === true : descriptor.default === true;
22565
22568
  return;
22566
22569
  }
@@ -22568,7 +22571,7 @@ function AiConnectionEditor({
22568
22571
  seeded[descriptor.field] = "";
22569
22572
  return;
22570
22573
  }
22571
- const current = _optionalChain([stored, 'optionalAccess', _660 => _660[descriptor.field]]);
22574
+ const current = _optionalChain([stored, 'optionalAccess', _661 => _661[descriptor.field]]);
22572
22575
  if (current !== void 0 && current !== null) seeded[descriptor.field] = String(current);
22573
22576
  else seeded[descriptor.field] = descriptor.default !== void 0 ? String(descriptor.default) : "";
22574
22577
  });
@@ -22594,7 +22597,7 @@ function AiConnectionEditor({
22594
22597
  values: _zod3.z.record(_zod3.z.string(), _zod3.z.any())
22595
22598
  }).superRefine((data, ctx) => {
22596
22599
  fieldsFor(data.provider).filter((descriptor) => descriptor.required).forEach((descriptor) => {
22597
- const value = _optionalChain([data, 'access', _661 => _661.values, 'optionalAccess', _662 => _662[descriptor.field]]);
22600
+ const value = _optionalChain([data, 'access', _662 => _662.values, 'optionalAccess', _663 => _663[descriptor.field]]);
22598
22601
  const filled = descriptor.kind === "secret" ? !!value || hasStoredSecret(descriptor.field) : descriptor.kind === "boolean" ? value !== void 0 : value !== void 0 && value !== null && String(value).trim() !== "";
22599
22602
  if (filled) return;
22600
22603
  ctx.addIssue({
@@ -22608,11 +22611,11 @@ function AiConnectionEditor({
22608
22611
  );
22609
22612
  const getDefaultValues = _react.useCallback.call(void 0,
22610
22613
  () => ({
22611
- id: _nullishCoalesce(_optionalChain([connection, 'optionalAccess', _663 => _663.id]), () => ( _uuid.v4.call(void 0, ))),
22612
- name: _nullishCoalesce(_optionalChain([connection, 'optionalAccess', _664 => _664.name]), () => ( "")),
22613
- provider: _nullishCoalesce(_nullishCoalesce(_optionalChain([connection, 'optionalAccess', _665 => _665.provider]), () => ( providers[0])), () => ( "")),
22614
- enabled: _nullishCoalesce(_optionalChain([connection, 'optionalAccess', _666 => _666.enabled]), () => ( true)),
22615
- values: defaultsFor(_nullishCoalesce(_nullishCoalesce(_optionalChain([connection, 'optionalAccess', _667 => _667.provider]), () => ( providers[0])), () => ( "")))
22614
+ id: _nullishCoalesce(_optionalChain([connection, 'optionalAccess', _664 => _664.id]), () => ( _uuid.v4.call(void 0, ))),
22615
+ name: _nullishCoalesce(_optionalChain([connection, 'optionalAccess', _665 => _665.name]), () => ( "")),
22616
+ provider: _nullishCoalesce(_nullishCoalesce(_optionalChain([connection, 'optionalAccess', _666 => _666.provider]), () => ( providers[0])), () => ( "")),
22617
+ enabled: _nullishCoalesce(_optionalChain([connection, 'optionalAccess', _667 => _667.enabled]), () => ( true)),
22618
+ values: defaultsFor(_nullishCoalesce(_nullishCoalesce(_optionalChain([connection, 'optionalAccess', _668 => _668.provider]), () => ( providers[0])), () => ( "")))
22616
22619
  }),
22617
22620
  [connection, providers, defaultsFor]
22618
22621
  );
@@ -22623,7 +22626,7 @@ function AiConnectionEditor({
22623
22626
  _react.useEffect.call(void 0, () => {
22624
22627
  if (registryRows.length === 0) return;
22625
22628
  const currentProvider = form.getValues("provider");
22626
- const provider = currentProvider || _optionalChain([connection, 'optionalAccess', _668 => _668.provider]) || providers[0] || "";
22629
+ const provider = currentProvider || _optionalChain([connection, 'optionalAccess', _669 => _669.provider]) || providers[0] || "";
22627
22630
  if (!provider) return;
22628
22631
  if (provider !== currentProvider) form.setValue("provider", provider);
22629
22632
  const currentValues = form.getValues("values");
@@ -22694,7 +22697,7 @@ function AiConnectionEditor({
22694
22697
  {
22695
22698
  form,
22696
22699
  entityType: t("ai_connections.admin.entity"),
22697
- entityName: _optionalChain([connection, 'optionalAccess', _669 => _669.name]),
22700
+ entityName: _optionalChain([connection, 'optionalAccess', _670 => _670.name]),
22698
22701
  isEdit,
22699
22702
  module: _chunkP7L6OFX5js.Modules.AiConnection,
22700
22703
  size: "md",
@@ -22702,7 +22705,7 @@ function AiConnectionEditor({
22702
22705
  onSubmit: async (values) => {
22703
22706
  const attributes = {};
22704
22707
  fieldsFor(values.provider).forEach((descriptor) => {
22705
- const coerced = coerce(descriptor, _optionalChain([values, 'access', _670 => _670.values, 'optionalAccess', _671 => _671[descriptor.field]]));
22708
+ const coerced = coerce(descriptor, _optionalChain([values, 'access', _671 => _671.values, 'optionalAccess', _672 => _672[descriptor.field]]));
22706
22709
  if (coerced !== void 0) attributes[descriptor.field] = coerced;
22707
22710
  });
22708
22711
  const payload = {
@@ -22932,7 +22935,7 @@ function AiConnectionTypeCard({ connectionType }) {
22932
22935
  ),
22933
22936
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "bg-muted/40 flex flex-wrap items-center gap-2 px-3 py-2", children: [
22934
22937
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "softGray", children: t("ai_connections.admin.env_fallback") }),
22935
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground truncate text-xs", children: [_optionalChain([envDefault, 'optionalAccess', _672 => _672.provider]), _optionalChain([envDefault, 'optionalAccess', _673 => _673.model]), _optionalChain([envDefault, 'optionalAccess', _674 => _674.url])].filter(Boolean).join(" \xB7 ") })
22938
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-muted-foreground truncate text-xs", children: [_optionalChain([envDefault, 'optionalAccess', _673 => _673.provider]), _optionalChain([envDefault, 'optionalAccess', _674 => _674.model]), _optionalChain([envDefault, 'optionalAccess', _675 => _675.url])].filter(Boolean).join(" \xB7 ") })
22936
22939
  ] })
22937
22940
  ] })
22938
22941
  ] })
@@ -23221,7 +23224,7 @@ var useEmailBlastTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(v
23221
23224
  )
23222
23225
  };
23223
23226
  const columns = _react.useMemo.call(void 0, () => {
23224
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _675 => _675[field], 'optionalCall', _676 => _676()])).filter((col) => col !== void 0);
23227
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _676 => _676[field], 'optionalCall', _677 => _677()])).filter((col) => col !== void 0);
23225
23228
  }, [params.fields, fieldColumnMap, t, generateUrl, locale]);
23226
23229
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
23227
23230
  }, "useEmailBlastTableStructure");
@@ -23264,12 +23267,12 @@ function EmailBlastEditorInternal({
23264
23267
  );
23265
23268
  const getDefaultValues = _react.useCallback.call(void 0,
23266
23269
  () => ({
23267
- id: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _677 => _677.id]), () => ( _uuid.v4.call(void 0, ))),
23268
- subject: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _678 => _678.subject]), () => ( "")),
23269
- body: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _679 => _679.body]), () => ( "")),
23270
- replyTo: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _680 => _680.replyTo]), () => ( "")),
23270
+ id: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _678 => _678.id]), () => ( _uuid.v4.call(void 0, ))),
23271
+ subject: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _679 => _679.subject]), () => ( "")),
23272
+ body: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _680 => _680.body]), () => ( "")),
23273
+ replyTo: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _681 => _681.replyTo]), () => ( "")),
23271
23274
  // No preselected value on create: the form refuses to save without a choice.
23272
- purpose: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _681 => _681.purpose]), () => ( ""))
23275
+ purpose: _nullishCoalesce(_optionalChain([blast, 'optionalAccess', _682 => _682.purpose]), () => ( ""))
23273
23276
  }),
23274
23277
  [blast]
23275
23278
  );
@@ -23291,7 +23294,7 @@ function EmailBlastEditorInternal({
23291
23294
  {
23292
23295
  form,
23293
23296
  entityType: t("emailBlasts.editor.title"),
23294
- entityName: _optionalChain([blast, 'optionalAccess', _682 => _682.subject]),
23297
+ entityName: _optionalChain([blast, 'optionalAccess', _683 => _683.subject]),
23295
23298
  title: isEdit ? t("emailBlasts.editor.editTitle") : t("emailBlasts.editor.title"),
23296
23299
  isEdit,
23297
23300
  module: _chunkP7L6OFX5js.Modules.EmailBlast,
@@ -23435,7 +23438,7 @@ function EmailBlastSendDialog({ blast, onSuccess }) {
23435
23438
  setIsSending(true);
23436
23439
  try {
23437
23440
  await _chunkHN7L6RRWjs.EmailBlastService.send({ id: blast.id });
23438
- await _optionalChain([onSuccess, 'optionalCall', _683 => _683()]);
23441
+ await _optionalChain([onSuccess, 'optionalCall', _684 => _684()]);
23439
23442
  setOpen(false);
23440
23443
  } catch (error) {
23441
23444
  errorToast({ title: t("common.errors.error"), error });
@@ -23642,7 +23645,7 @@ function extractHeadings(blocks) {
23642
23645
  function processBlocks(blockArray) {
23643
23646
  for (const block of blockArray) {
23644
23647
  if (block.type === "heading") {
23645
- const level = _optionalChain([block, 'access', _684 => _684.props, 'optionalAccess', _685 => _685.level]) || 1;
23648
+ const level = _optionalChain([block, 'access', _685 => _685.props, 'optionalAccess', _686 => _686.level]) || 1;
23646
23649
  const text = extractTextFromContent(block.content);
23647
23650
  if (text.trim()) {
23648
23651
  headings.push({
@@ -24002,7 +24005,7 @@ var useHowToTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0
24002
24005
  })
24003
24006
  };
24004
24007
  const columns = _react.useMemo.call(void 0, () => {
24005
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _686 => _686[field], 'optionalCall', _687 => _687()])).filter((col) => col !== void 0);
24008
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _687 => _687[field], 'optionalCall', _688 => _688()])).filter((col) => col !== void 0);
24006
24009
  }, [params.fields, fieldColumnMap, t, generateUrl]);
24007
24010
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
24008
24011
  }, "useHowToTableStructure");
@@ -24128,7 +24131,7 @@ function HowToSelector({
24128
24131
  }, "setHowTo");
24129
24132
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-col", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FormFieldWrapper, { form, name: id, label, isRequired, children: (field) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Popover, { open, onOpenChange: setOpen, modal: true, children: [
24130
24133
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-row items-center justify-between", children: [
24131
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PopoverTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-row items-center justify-start rounded-md", children: field.value ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-input/20 dark:bg-input/30 border-input flex h-7 w-full flex-row items-center justify-start rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _nullishCoalesce(_optionalChain([field, 'access', _688 => _688.value, 'optionalAccess', _689 => _689.name]), () => ( "")) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-input/20 dark:bg-input/30 border-input text-muted-foreground flex h-7 w-full flex-row items-center justify-start rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed", children: _nullishCoalesce(placeholder, () => ( t(`generic.search.placeholder`, { type: t(`entities.howtos`, { count: 1 }) }))) }) }) }),
24134
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, PopoverTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full flex-row items-center justify-start rounded-md", children: field.value ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-input/20 dark:bg-input/30 border-input flex h-7 w-full flex-row items-center justify-start rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _nullishCoalesce(_optionalChain([field, 'access', _689 => _689.value, 'optionalAccess', _690 => _690.name]), () => ( "")) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-input/20 dark:bg-input/30 border-input text-muted-foreground flex h-7 w-full flex-row items-center justify-start rounded-md border px-2 py-0.5 text-sm md:text-xs/relaxed", children: _nullishCoalesce(placeholder, () => ( t(`generic.search.placeholder`, { type: t(`entities.howtos`, { count: 1 }) }))) }) }) }),
24132
24135
  field.value && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
24133
24136
  _lucidereact.CircleX,
24134
24137
  {
@@ -24433,10 +24436,10 @@ function CitationsTab({ citations, sources }) {
24433
24436
  ] }) }),
24434
24437
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableBody, { children: sorted.map((chunk) => {
24435
24438
  const isOpen = expanded.has(chunk.id);
24436
- const resolved = chunk.nodeId ? _optionalChain([sources, 'optionalAccess', _690 => _690.get, 'call', _691 => _691(chunk.nodeId)]) : void 0;
24439
+ const resolved = chunk.nodeId ? _optionalChain([sources, 'optionalAccess', _691 => _691.get, 'call', _692 => _692(chunk.nodeId)]) : void 0;
24437
24440
  const typeLabel = chunk.nodeType ? entityLabel(chunk.nodeType) : t("features.assistant.message.sources.source");
24438
24441
  const fallbackName = chunk.nodeId ? `${typeLabel} ${chunk.nodeId.slice(0, 8)}` : typeLabel;
24439
- const sourceName = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _692 => _692.name]), () => ( fallbackName));
24442
+ const sourceName = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _693 => _693.name]), () => ( fallbackName));
24440
24443
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react.Fragment, { children: [
24441
24444
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, TableRow, { children: [
24442
24445
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
@@ -24500,7 +24503,7 @@ function ContentsTab({ citations, sources }) {
24500
24503
  for (const c of citations) {
24501
24504
  const id = c.nodeId;
24502
24505
  if (!id) continue;
24503
- const source = _optionalChain([sources, 'optionalAccess', _693 => _693.get, 'call', _694 => _694(id)]);
24506
+ const source = _optionalChain([sources, 'optionalAccess', _694 => _694.get, 'call', _695 => _695(id)]);
24504
24507
  if (!source) continue;
24505
24508
  const existing = map.get(id);
24506
24509
  if (existing) {
@@ -24567,7 +24570,7 @@ function UsersTab({ users, citations, sources }) {
24567
24570
  const generate = usePageUrlGenerator();
24568
24571
  const userMap = /* @__PURE__ */ new Map();
24569
24572
  for (const u of users) {
24570
- if (!_optionalChain([u, 'optionalAccess', _695 => _695.id])) continue;
24573
+ if (!_optionalChain([u, 'optionalAccess', _696 => _696.id])) continue;
24571
24574
  userMap.set(u.id, { user: u, contentCount: 0, citationCount: 0 });
24572
24575
  }
24573
24576
  if (citations && sources) {
@@ -24638,7 +24641,7 @@ function SuggestedQuestionsTab({ questions, onSelect }) {
24638
24641
  {
24639
24642
  type: "button",
24640
24643
  disabled: !onSelect,
24641
- onClick: () => _optionalChain([onSelect, 'optionalCall', _696 => _696(q)]),
24644
+ onClick: () => _optionalChain([onSelect, 'optionalCall', _697 => _697(q)]),
24642
24645
  className: "border-border bg-muted/30 hover:bg-muted disabled:hover:bg-muted/30 rounded-md border px-3 py-1.5 text-start text-sm disabled:cursor-not-allowed disabled:opacity-50",
24643
24646
  children: q
24644
24647
  },
@@ -24673,7 +24676,7 @@ function MessageSourcesPanel({ message, isLatestAssistant, onSelectFollowUp, sou
24673
24676
  }
24674
24677
  return ids.size;
24675
24678
  }, [message.citations, sources]);
24676
- const usersCount = _nullishCoalesce(_optionalChain([users, 'optionalAccess', _697 => _697.length]), () => ( 0));
24679
+ const usersCount = _nullishCoalesce(_optionalChain([users, 'optionalAccess', _698 => _698.length]), () => ( 0));
24677
24680
  const total = refsCount + citationsCount + contentsCount + usersCount + suggestionsCount;
24678
24681
  const visibleTabs = [];
24679
24682
  if (suggestionsCount > 0) visibleTabs.push("suggested");
@@ -24816,7 +24819,7 @@ function MessageSourcesContainer({ message, isLatestAssistant, onSelectFollowUp
24816
24819
  return void 0;
24817
24820
  }
24818
24821
  })()));
24819
- if (_optionalChain([author, 'optionalAccess', _698 => _698.id])) userMap.set(author.id, author);
24822
+ if (_optionalChain([author, 'optionalAccess', _699 => _699.id])) userMap.set(author.id, author);
24820
24823
  }
24821
24824
  return Array.from(userMap.values());
24822
24825
  }, [resolved]);
@@ -24851,7 +24854,7 @@ function MessageItem({
24851
24854
  }) {
24852
24855
  const t = _nextintl.useTranslations.call(void 0, );
24853
24856
  const isUser = message.role === "user";
24854
- const isFailed = isUser && !!_optionalChain([failedMessageIds, 'optionalAccess', _699 => _699.has, 'call', _700 => _700(message.id)]);
24857
+ const isFailed = isUser && !!_optionalChain([failedMessageIds, 'optionalAccess', _700 => _700.has, 'call', _701 => _701(message.id)]);
24855
24858
  const markdownComponents = _react.useMemo.call(void 0,
24856
24859
  () => ({
24857
24860
  a: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ href, children }) => {
@@ -24868,7 +24871,7 @@ function MessageItem({
24868
24871
  isFailed && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-destructive flex items-center gap-2 text-xs", children: [
24869
24872
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.AlertCircle, { className: "h-3.5 w-3.5" }),
24870
24873
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: t("features.assistant.send_failed") }),
24871
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { type: "button", onClick: () => _optionalChain([onRetry, 'optionalCall', _701 => _701(message.id)]), children: t("features.assistant.retry") })
24874
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { type: "button", onClick: () => _optionalChain([onRetry, 'optionalCall', _702 => _702(message.id)]), children: t("features.assistant.retry") })
24872
24875
  ] })
24873
24876
  ] });
24874
24877
  }
@@ -24959,7 +24962,7 @@ function AssistantThread({
24959
24962
  }) {
24960
24963
  const lastMessageRef = _react.useRef.call(void 0, null);
24961
24964
  _react.useEffect.call(void 0, () => {
24962
- _optionalChain([lastMessageRef, 'access', _702 => _702.current, 'optionalAccess', _703 => _703.scrollIntoView, 'call', _704 => _704({ block: "start", behavior: "smooth" })]);
24965
+ _optionalChain([lastMessageRef, 'access', _703 => _703.current, 'optionalAccess', _704 => _704.scrollIntoView, 'call', _705 => _705({ block: "start", behavior: "smooth" })]);
24963
24966
  }, [messages.length, sending]);
24964
24967
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex-1 min-w-0 overflow-x-hidden overflow-y-auto px-6 py-5", children: [
24965
24968
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -24998,7 +25001,7 @@ ${message.sources.map((source) => `- \`${source}\``).join("\n")}`;
24998
25001
  return _chunkHN7L6RRWjs.rehydrate.call(void 0, _chunkP7L6OFX5js.Modules.HandbookThreadMessage, {
24999
25002
  jsonApi: {
25000
25003
  ...dehydrated.jsonApi,
25001
- attributes: { ..._nullishCoalesce(_optionalChain([dehydrated, 'access', _705 => _705.jsonApi, 'optionalAccess', _706 => _706.attributes]), () => ( {})), content }
25004
+ attributes: { ..._nullishCoalesce(_optionalChain([dehydrated, 'access', _706 => _706.jsonApi, 'optionalAccess', _707 => _707.attributes]), () => ( {})), content }
25002
25005
  },
25003
25006
  included: dehydrated.included
25004
25007
  });
@@ -25007,8 +25010,8 @@ _chunk7QVYU63Ejs.__name.call(void 0, withSourcesInContent, "withSourcesInContent
25007
25010
  function useHandbookAsk(params) {
25008
25011
  const t = _nextintl.useTranslations.call(void 0, );
25009
25012
  const generateUrl = usePageUrlGenerator();
25010
- const shouldSyncUrl = _nullishCoalesce(_optionalChain([params, 'optionalAccess', _707 => _707.syncUrl]), () => ( true));
25011
- const handbookThreadId = _optionalChain([params, 'optionalAccess', _708 => _708.handbookThreadId]);
25013
+ const shouldSyncUrl = _nullishCoalesce(_optionalChain([params, 'optionalAccess', _708 => _708.syncUrl]), () => ( true));
25014
+ const handbookThreadId = _optionalChain([params, 'optionalAccess', _709 => _709.handbookThreadId]);
25012
25015
  const [threads, setThreads] = _react.useState.call(void 0, []);
25013
25016
  const [thread, setThread] = _react.useState.call(void 0, void 0);
25014
25017
  const [messages, setMessages] = _react.useState.call(void 0, []);
@@ -25070,12 +25073,12 @@ function useHandbookAsk(params) {
25070
25073
  ]);
25071
25074
  setSending(true);
25072
25075
  try {
25073
- let id = _optionalChain([thread, 'optionalAccess', _709 => _709.id]);
25076
+ let id = _optionalChain([thread, 'optionalAccess', _710 => _710.id]);
25074
25077
  if (id === void 0) {
25075
25078
  const created = await _chunkHN7L6RRWjs.HandbookThreadService.create({
25076
25079
  id: _uuid.v4.call(void 0, ),
25077
25080
  question: trimmed,
25078
- handbookPageId: _optionalChain([options, 'optionalAccess', _710 => _710.handbookPageId])
25081
+ handbookPageId: _optionalChain([options, 'optionalAccess', _711 => _711.handbookPageId])
25079
25082
  });
25080
25083
  id = created.id;
25081
25084
  setThreads((current) => [created, ...current]);
@@ -25084,7 +25087,7 @@ function useHandbookAsk(params) {
25084
25087
  id: _uuid.v4.call(void 0, ),
25085
25088
  threadId: id,
25086
25089
  question: trimmed,
25087
- handbookPageId: _optionalChain([options, 'optionalAccess', _711 => _711.handbookPageId])
25090
+ handbookPageId: _optionalChain([options, 'optionalAccess', _712 => _712.handbookPageId])
25088
25091
  });
25089
25092
  }
25090
25093
  const loaded = await _chunkHN7L6RRWjs.HandbookThreadService.findOne({ id });
@@ -25105,7 +25108,7 @@ function useHandbookAsk(params) {
25105
25108
  setSending(false);
25106
25109
  }
25107
25110
  },
25108
- [messages.length, sending, syncUrl, t, _optionalChain([thread, 'optionalAccess', _712 => _712.id])]
25111
+ [messages.length, sending, syncUrl, t, _optionalChain([thread, 'optionalAccess', _713 => _713.id])]
25109
25112
  );
25110
25113
  return { threads, thread, messages, sending, ask, selectThread, startNew };
25111
25114
  }
@@ -25661,7 +25664,7 @@ function HandbookPageContainer({ handbookPageId }) {
25661
25664
  };
25662
25665
  }, []);
25663
25666
  const section = _react.useMemo.call(void 0,
25664
- () => sections.find((candidate) => candidate.key === _optionalChain([handbookPage, 'optionalAccess', _713 => _713.section])),
25667
+ () => sections.find((candidate) => candidate.key === _optionalChain([handbookPage, 'optionalAccess', _714 => _714.section])),
25665
25668
  [sections, handbookPage]
25666
25669
  );
25667
25670
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -25750,7 +25753,7 @@ function AssistantSidebar({
25750
25753
  className: "block w-full truncate rounded-md px-2 py-1.5 text-start text-sm " + (activeId === thread.id ? "bg-primary/10 text-primary" : "hover:bg-muted text-foreground"),
25751
25754
  children: [
25752
25755
  thread.title,
25753
- _optionalChain([renderThreadBadge, 'optionalCall', _714 => _714(thread)])
25756
+ _optionalChain([renderThreadBadge, 'optionalCall', _715 => _715(thread)])
25754
25757
  ]
25755
25758
  },
25756
25759
  thread.id
@@ -25786,7 +25789,7 @@ function HandbookAskContainer({ handbookThreadId } = {}) {
25786
25789
  AssistantSidebar,
25787
25790
  {
25788
25791
  threads,
25789
- activeId: _optionalChain([thread, 'optionalAccess', _715 => _715.id]),
25792
+ activeId: _optionalChain([thread, 'optionalAccess', _716 => _716.id]),
25790
25793
  onSelect: selectThread,
25791
25794
  onNew: startNew,
25792
25795
  newLabel: t("handbook.chat.new"),
@@ -25794,7 +25797,7 @@ function HandbookAskContainer({ handbookThreadId } = {}) {
25794
25797
  }
25795
25798
  ) })
25796
25799
  ),
25797
- [selectThread, startNew, t, _optionalChain([thread, 'optionalAccess', _716 => _716.id]), threads]
25800
+ [selectThread, startNew, t, _optionalChain([thread, 'optionalAccess', _717 => _717.id]), threads]
25798
25801
  );
25799
25802
  return (
25800
25803
  // `RoundPageContainer` reads the page heading from the shared context, and
@@ -25806,7 +25809,7 @@ function HandbookAskContainer({ handbookThreadId } = {}) {
25806
25809
  RoundPageContainer,
25807
25810
  {
25808
25811
  module: _chunkP7L6OFX5js.Modules.HandbookPage,
25809
- id: _optionalChain([thread, 'optionalAccess', _717 => _717.id]),
25812
+ id: _optionalChain([thread, 'optionalAccess', _718 => _718.id]),
25810
25813
  fullWidth: true,
25811
25814
  forceHeader: true,
25812
25815
  defaultDetailsOpen: true,
@@ -25858,7 +25861,7 @@ function EntityMentionLinkView({ type, id, alias }) {
25858
25861
  } catch (e25) {
25859
25862
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: alias });
25860
25863
  }
25861
- if (!_optionalChain([module, 'optionalAccess', _718 => _718.pageUrl])) return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: alias });
25864
+ if (!_optionalChain([module, 'optionalAccess', _719 => _719.pageUrl])) return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: alias });
25862
25865
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Link, { href: generate({ page: module, id }), children: alias });
25863
25866
  }
25864
25867
  _chunk7QVYU63Ejs.__name.call(void 0, EntityMentionLinkView, "EntityMentionLinkView");
@@ -25990,13 +25993,13 @@ function AssistantContainer({
25990
25993
  AssistantSidebar,
25991
25994
  {
25992
25995
  threads: ctx.threads,
25993
- activeId: _optionalChain([ctx, 'access', _719 => _719.assistant, 'optionalAccess', _720 => _720.id]),
25996
+ activeId: _optionalChain([ctx, 'access', _720 => _720.assistant, 'optionalAccess', _721 => _721.id]),
25994
25997
  onSelect: ctx.selectThread,
25995
25998
  renderThreadBadge
25996
25999
  }
25997
26000
  ) })
25998
26001
  ),
25999
- [ctx.threads, _optionalChain([ctx, 'access', _721 => _721.assistant, 'optionalAccess', _722 => _722.id]), ctx.selectThread, renderThreadBadge]
26002
+ [ctx.threads, _optionalChain([ctx, 'access', _722 => _722.assistant, 'optionalAccess', _723 => _723.id]), ctx.selectThread, renderThreadBadge]
26000
26003
  );
26001
26004
  const thread = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: !showThread ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
26002
26005
  AssistantEmptyState,
@@ -26004,7 +26007,7 @@ function AssistantContainer({
26004
26007
  onSend: ctx.sendMessage,
26005
26008
  operatorMode: ctx.operatorMode,
26006
26009
  onOperatorModeChange: showOperatorToggle ? ctx.setOperatorMode : void 0,
26007
- composerLeading: _optionalChain([renderScopePicker, 'optionalCall', _723 => _723()])
26010
+ composerLeading: _optionalChain([renderScopePicker, 'optionalCall', _724 => _724()])
26008
26011
  }
26009
26012
  ) : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
26010
26013
  ctx.assistant ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -26036,7 +26039,7 @@ function AssistantContainer({
26036
26039
  AssistantSidebar,
26037
26040
  {
26038
26041
  threads: ctx.threads,
26039
- activeId: _optionalChain([ctx, 'access', _724 => _724.assistant, 'optionalAccess', _725 => _725.id]),
26042
+ activeId: _optionalChain([ctx, 'access', _725 => _725.assistant, 'optionalAccess', _726 => _726.id]),
26040
26043
  onSelect: ctx.selectThread,
26041
26044
  onNew: ctx.startNew,
26042
26045
  renderThreadBadge
@@ -26049,7 +26052,7 @@ function AssistantContainer({
26049
26052
  RoundPageContainer,
26050
26053
  {
26051
26054
  module: _chunkP7L6OFX5js.Modules.Assistant,
26052
- id: _optionalChain([ctx, 'access', _726 => _726.assistant, 'optionalAccess', _727 => _727.id]),
26055
+ id: _optionalChain([ctx, 'access', _727 => _727.assistant, 'optionalAccess', _728 => _728.id]),
26053
26056
  fullWidth: true,
26054
26057
  forceHeader: true,
26055
26058
  defaultDetailsOpen: true,
@@ -26077,7 +26080,7 @@ function flattenBlocks(blocks) {
26077
26080
  if (typeof inline === "string") return inline;
26078
26081
  if (!inline || typeof inline !== "object") return "";
26079
26082
  const node = inline;
26080
- if (node.type === "mention") return _nullishCoalesce(_optionalChain([node, 'access', _728 => _728.props, 'optionalAccess', _729 => _729.alias]), () => ( ""));
26083
+ if (node.type === "mention") return _nullishCoalesce(_optionalChain([node, 'access', _729 => _729.props, 'optionalAccess', _730 => _730.alias]), () => ( ""));
26081
26084
  if (typeof node.text === "string") return node.text;
26082
26085
  if (Array.isArray(node.content)) return node.content.map(readInline).join("");
26083
26086
  return "";
@@ -26194,7 +26197,7 @@ function AssistantPageContainer({
26194
26197
  AssistantSidebar,
26195
26198
  {
26196
26199
  threads: ctx.threads,
26197
- activeId: _optionalChain([ctx, 'access', _730 => _730.assistant, 'optionalAccess', _731 => _731.id]),
26200
+ activeId: _optionalChain([ctx, 'access', _731 => _731.assistant, 'optionalAccess', _732 => _732.id]),
26198
26201
  onSelect: ctx.selectThread,
26199
26202
  onNew: ctx.startNew
26200
26203
  }
@@ -26470,14 +26473,14 @@ function ApprovalActionCard({ actionId, summary, onResolved, hiddenRelationshipK
26470
26473
  const presented = _react.useMemo.call(void 0, () => parseOperatorProposal(actionProposal), [actionProposal]);
26471
26474
  const legacy = _react.useMemo.call(void 0, () => presented ? void 0 : parseLegacyProposal(toolArgs), [presented, toolArgs]);
26472
26475
  const isUpdate = toolName === "update_entity";
26473
- const entityType = _nullishCoalesce(_nullishCoalesce(_optionalChain([presented, 'optionalAccess', _732 => _732.type]), () => ( _optionalChain([legacy, 'optionalAccess', _733 => _733.type]))), () => ( ""));
26476
+ const entityType = _nullishCoalesce(_nullishCoalesce(_optionalChain([presented, 'optionalAccess', _733 => _733.type]), () => ( _optionalChain([legacy, 'optionalAccess', _734 => _734.type]))), () => ( ""));
26474
26477
  const loose = t;
26475
26478
  const entityLabel = entityName(loose, entityType);
26476
- const targetLabel = _nullishCoalesce(_optionalChain([presented, 'optionalAccess', _734 => _734.target, 'optionalAccess', _735 => _735.label]), () => ( ""));
26479
+ const targetLabel = _nullishCoalesce(_optionalChain([presented, 'optionalAccess', _735 => _735.target, 'optionalAccess', _736 => _736.label]), () => ( ""));
26477
26480
  const rows = _react.useMemo.call(void 0, () => {
26478
26481
  const yes = t("features.assistant.approval.proposal.yes");
26479
26482
  const no = t("features.assistant.approval.proposal.no");
26480
- const attributes = _nullishCoalesce(_optionalChain([presented, 'optionalAccess', _736 => _736.attributes]), () => ( _optionalChain([legacy, 'optionalAccess', _737 => _737.attributes])));
26483
+ const attributes = _nullishCoalesce(_optionalChain([presented, 'optionalAccess', _737 => _737.attributes]), () => ( _optionalChain([legacy, 'optionalAccess', _738 => _738.attributes])));
26481
26484
  const attributeRows = Object.entries(_nullishCoalesce(attributes, () => ( {}))).flatMap(([key, value]) => {
26482
26485
  const text = formatAttribute(value, yes, no);
26483
26486
  return text === void 0 ? [] : [{ key: `attribute:${key}`, label: fieldLabel(loose, entityType, key), value: text }];
@@ -26515,7 +26518,7 @@ function ApprovalActionCard({ actionId, summary, onResolved, hiddenRelationshipK
26515
26518
  try {
26516
26519
  const message = kind === "approve" ? await _chunkHN7L6RRWjs.AssistantActionService.approve({ id: actionId }) : await _chunkHN7L6RRWjs.AssistantActionService.deny({ id: actionId });
26517
26520
  setStatus(kind === "approve" ? "executed" : "denied");
26518
- if (message) _optionalChain([onResolved, 'optionalCall', _738 => _738(message)]);
26521
+ if (message) _optionalChain([onResolved, 'optionalCall', _739 => _739(message)]);
26519
26522
  } catch (error) {
26520
26523
  console.error(`ApprovalActionCard: failed to ${kind} assistant action ${actionId}`, error);
26521
26524
  setFailed(true);
@@ -26660,10 +26663,10 @@ var useNotificationTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call
26660
26663
  const dateLocale = _chunkHN7L6RRWjs.dateFormatLocale.call(void 0, _chunkP7L6OFX5js.useI18nLocale.call(void 0, ));
26661
26664
  const generateUrl = usePageUrlGenerator();
26662
26665
  const { loadNotifications } = useNotificationContext();
26663
- const archived = _optionalChain([params, 'access', _739 => _739.context, 'optionalAccess', _740 => _740.archived]) === true;
26666
+ const archived = _optionalChain([params, 'access', _740 => _740.context, 'optionalAccess', _741 => _741.archived]) === true;
26664
26667
  const archiveNotification = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (notification) => {
26665
26668
  await _chunkHN7L6RRWjs.NotificationService.archive({ id: notification.id });
26666
- _optionalChain([params, 'access', _741 => _741.dataRetriever, 'optionalAccess', _742 => _742.removeElement, 'call', _743 => _743(notification)]);
26669
+ _optionalChain([params, 'access', _742 => _742.dataRetriever, 'optionalAccess', _743 => _743.removeElement, 'call', _744 => _744(notification)]);
26667
26670
  await loadNotifications();
26668
26671
  }, "archiveNotification");
26669
26672
  const tableData = _react.useMemo.call(void 0, () => {
@@ -26702,7 +26705,7 @@ var useNotificationTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call
26702
26705
  const data = generateNotificationData({ notification, generateUrl });
26703
26706
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-foreground text-sm", children: t.rich(`notification.${notification.notificationType}.description`, {
26704
26707
  strong: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (chunks) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { className: "font-medium", children: chunks }), "strong"),
26705
- actor: _nullishCoalesce(_optionalChain([data, 'access', _744 => _744.actor, 'optionalAccess', _745 => _745.name]), () => ( "")),
26708
+ actor: _nullishCoalesce(_optionalChain([data, 'access', _745 => _745.actor, 'optionalAccess', _746 => _746.name]), () => ( "")),
26706
26709
  title: data.title,
26707
26710
  message: _nullishCoalesce(notification.message, () => ( ""))
26708
26711
  }) });
@@ -26757,7 +26760,7 @@ var useNotificationTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call
26757
26760
  })
26758
26761
  };
26759
26762
  const columns = _react.useMemo.call(void 0, () => {
26760
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _746 => _746[field], 'optionalCall', _747 => _747()])).filter((col) => col !== void 0);
26763
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _747 => _747[field], 'optionalCall', _748 => _748()])).filter((col) => col !== void 0);
26761
26764
  }, [params.fields, fieldColumnMap, t, generateUrl]);
26762
26765
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
26763
26766
  }, "useNotificationTableStructure");
@@ -27167,11 +27170,11 @@ _chunk7QVYU63Ejs.__name.call(void 0, useReferralStats, "useReferralStats");
27167
27170
  // src/features/referral/components/ReferralWidget.tsx
27168
27171
 
27169
27172
  function inviteErrorCode(err) {
27170
- return _optionalChain([err, 'optionalAccess', _748 => _748.body, 'optionalAccess', _749 => _749.errors, 'optionalAccess', _750 => _750[0], 'optionalAccess', _751 => _751.code]);
27173
+ return _optionalChain([err, 'optionalAccess', _749 => _749.body, 'optionalAccess', _750 => _750.errors, 'optionalAccess', _751 => _751[0], 'optionalAccess', _752 => _752.code]);
27171
27174
  }
27172
27175
  _chunk7QVYU63Ejs.__name.call(void 0, inviteErrorCode, "inviteErrorCode");
27173
27176
  async function copyToClipboard(text) {
27174
- if (_optionalChain([navigator, 'access', _752 => _752.clipboard, 'optionalAccess', _753 => _753.writeText])) {
27177
+ if (_optionalChain([navigator, 'access', _753 => _753.clipboard, 'optionalAccess', _754 => _754.writeText])) {
27175
27178
  try {
27176
27179
  await navigator.clipboard.writeText(text);
27177
27180
  return true;
@@ -27234,7 +27237,7 @@ function ReferralWidget({
27234
27237
  const linkInputRef = _react.useRef.call(void 0, null);
27235
27238
  const config = _chunkTNTCLVURjs.getReferralConfig.call(void 0, );
27236
27239
  const baseUrl = config.referralUrlBase || (typeof window !== "undefined" ? window.location.origin : "");
27237
- const referralUrl = _optionalChain([stats, 'optionalAccess', _754 => _754.referralCode]) ? `${baseUrl}${config.referralPath}?${config.urlParamName}=${stats.referralCode}` : "";
27240
+ const referralUrl = _optionalChain([stats, 'optionalAccess', _755 => _755.referralCode]) ? `${baseUrl}${config.referralPath}?${config.urlParamName}=${stats.referralCode}` : "";
27238
27241
  if (!_chunkTNTCLVURjs.isReferralEnabled.call(void 0, )) {
27239
27242
  return null;
27240
27243
  }
@@ -27244,7 +27247,7 @@ function ReferralWidget({
27244
27247
  if (success) {
27245
27248
  setCopied(true);
27246
27249
  _chunkHN7L6RRWjs.showToast.call(void 0, text.copiedMessage);
27247
- _optionalChain([onLinkCopied, 'optionalCall', _755 => _755()]);
27250
+ _optionalChain([onLinkCopied, 'optionalCall', _756 => _756()]);
27248
27251
  setTimeout(() => setCopied(false), 2e3);
27249
27252
  } else {
27250
27253
  _chunkHN7L6RRWjs.showError.call(void 0, text.copyError);
@@ -27258,14 +27261,14 @@ function ReferralWidget({
27258
27261
  try {
27259
27262
  await sendInvite(email);
27260
27263
  _chunkHN7L6RRWjs.showToast.call(void 0, text.inviteSent);
27261
- _optionalChain([onInviteSent, 'optionalCall', _756 => _756(email)]);
27264
+ _optionalChain([onInviteSent, 'optionalCall', _757 => _757(email)]);
27262
27265
  setEmail("");
27263
27266
  } catch (err) {
27264
27267
  const code = inviteErrorCode(err);
27265
27268
  _chunkHN7L6RRWjs.showError.call(void 0,
27266
27269
  code === "REFERRAL_ALREADY_INVITED" ? text.alreadyInvited : code === "REFERRAL_ALREADY_REGISTERED" ? text.alreadyRegistered : text.inviteError
27267
27270
  );
27268
- _optionalChain([onInviteError, 'optionalCall', _757 => _757(err instanceof Error ? err : new Error(text.inviteError))]);
27271
+ _optionalChain([onInviteError, 'optionalCall', _758 => _758(err instanceof Error ? err : new Error(text.inviteError))]);
27269
27272
  }
27270
27273
  }, [
27271
27274
  email,
@@ -27405,7 +27408,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, ReferralDialog, "ReferralDialog");
27405
27408
 
27406
27409
 
27407
27410
  function createUsageFormatters(locale, currency) {
27408
- const symbol = _nullishCoalesce(_optionalChain([new Intl.NumberFormat(locale, { style: "currency", currency, currencyDisplay: "narrowSymbol" }), 'access', _758 => _758.formatToParts, 'call', _759 => _759(0), 'access', _760 => _760.find, 'call', _761 => _761((part) => part.type === "currency"), 'optionalAccess', _762 => _762.value]), () => ( currency));
27411
+ const symbol = _nullishCoalesce(_optionalChain([new Intl.NumberFormat(locale, { style: "currency", currency, currencyDisplay: "narrowSymbol" }), 'access', _759 => _759.formatToParts, 'call', _760 => _760(0), 'access', _761 => _761.find, 'call', _762 => _762((part) => part.type === "currency"), 'optionalAccess', _763 => _763.value]), () => ( currency));
27409
27412
  const decimal = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (value, decimals) => value.toLocaleString(locale, { minimumFractionDigits: decimals, maximumFractionDigits: decimals }), "decimal");
27410
27413
  const dayFormat = new Intl.DateTimeFormat(locale, { day: "numeric", month: "short", timeZone: "UTC" });
27411
27414
  const monthFormat = new Intl.DateTimeFormat(locale, { month: "short", year: "numeric", timeZone: "UTC" });
@@ -27519,7 +27522,7 @@ var useReferralAdminReferralTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__
27519
27522
  })
27520
27523
  };
27521
27524
  const columns = _react.useMemo.call(void 0, () => {
27522
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _763 => _763[field], 'optionalCall', _764 => _764()])).filter((col) => col !== void 0);
27525
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _764 => _764[field], 'optionalCall', _765 => _765()])).filter((col) => col !== void 0);
27523
27526
  }, [params.fields, fieldColumnMap, t, decimal]);
27524
27527
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
27525
27528
  }, "useReferralAdminReferralTableStructure");
@@ -27553,7 +27556,7 @@ var useReferralAdminReferrerTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__
27553
27556
  });
27554
27557
  }, [params.data]);
27555
27558
  const sortableHeader = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (sort, label) => () => {
27556
- const active = _optionalChain([context, 'optionalAccess', _765 => _765.sort]) === sort;
27559
+ const active = _optionalChain([context, 'optionalAccess', _766 => _766.sort]) === sort;
27557
27560
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
27558
27561
  Button,
27559
27562
  {
@@ -27564,7 +27567,7 @@ var useReferralAdminReferrerTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__
27564
27567
  title: t("referral.admin.referrers.sortBy"),
27565
27568
  "aria-sort": active ? "descending" : void 0,
27566
27569
  "data-testid": active ? "referrals-referrers-sort" : void 0,
27567
- onClick: () => _optionalChain([context, 'optionalAccess', _766 => _766.onSort, 'call', _767 => _767(sort)]),
27570
+ onClick: () => _optionalChain([context, 'optionalAccess', _767 => _767.onSort, 'call', _768 => _768(sort)]),
27568
27571
  children: label
27569
27572
  }
27570
27573
  );
@@ -27676,8 +27679,8 @@ var useReferralAdminReferrerTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__
27676
27679
  })
27677
27680
  };
27678
27681
  const columns = _react.useMemo.call(void 0, () => {
27679
- return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _768 => _768[field], 'optionalCall', _769 => _769()])).filter((col) => col !== void 0);
27680
- }, [params.fields, fieldColumnMap, t, decimal, _optionalChain([context, 'optionalAccess', _770 => _770.sort])]);
27682
+ return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _769 => _769[field], 'optionalCall', _770 => _770()])).filter((col) => col !== void 0);
27683
+ }, [params.fields, fieldColumnMap, t, decimal, _optionalChain([context, 'optionalAccess', _771 => _771.sort])]);
27681
27684
  return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
27682
27685
  }, "useReferralAdminReferrerTableStructure");
27683
27686
  registerTableGenerator("referrals/administration/referrers", useReferralAdminReferrerTableStructure);
@@ -27726,10 +27729,10 @@ function ReferralsAdminFunnel({ summary }) {
27726
27729
  const { decimal } = useUsageFormatters();
27727
27730
  const current = summary.find((row) => row.window === "current");
27728
27731
  const steps = [
27729
- { label: t("referral.admin.tiles.visits"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _771 => _771.visits]), () => ( 0)) },
27730
- { label: t("referral.admin.tiles.invites"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _772 => _772.invitesSent]), () => ( 0)) },
27731
- { label: t("referral.admin.tiles.signups"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _773 => _773.signups]), () => ( 0)) },
27732
- { label: t("referral.admin.tiles.paying"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _774 => _774.paying]), () => ( 0)) }
27732
+ { label: t("referral.admin.tiles.visits"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _772 => _772.visits]), () => ( 0)) },
27733
+ { label: t("referral.admin.tiles.invites"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _773 => _773.invitesSent]), () => ( 0)) },
27734
+ { label: t("referral.admin.tiles.signups"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _774 => _774.signups]), () => ( 0)) },
27735
+ { label: t("referral.admin.tiles.paying"), value: _nullishCoalesce(_optionalChain([current, 'optionalAccess', _775 => _775.paying]), () => ( 0)) }
27733
27736
  ];
27734
27737
  const max = Math.max(...steps.map((step) => step.value), 0);
27735
27738
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "section", { "data-testid": "referrals-funnel", className: "grid gap-2", children: [
@@ -28694,7 +28697,7 @@ function OAuthClientList({
28694
28697
  OAuthClientCard,
28695
28698
  {
28696
28699
  client,
28697
- onClick: () => _optionalChain([onClientClick, 'optionalCall', _775 => _775(client)]),
28700
+ onClick: () => _optionalChain([onClientClick, 'optionalCall', _776 => _776(client)]),
28698
28701
  onEdit: onEditClick ? () => onEditClick(client) : void 0,
28699
28702
  onDelete: onDeleteClick ? () => onDeleteClick(client) : void 0
28700
28703
  },
@@ -28719,11 +28722,11 @@ function OAuthClientForm({
28719
28722
  const t = _nextintl.useTranslations.call(void 0, );
28720
28723
  const isEditMode = !!client;
28721
28724
  const [formState, setFormState] = _react.useState.call(void 0, {
28722
- name: _optionalChain([client, 'optionalAccess', _776 => _776.name]) || "",
28723
- description: _optionalChain([client, 'optionalAccess', _777 => _777.description]) || "",
28724
- redirectUris: _optionalChain([client, 'optionalAccess', _778 => _778.redirectUris, 'optionalAccess', _779 => _779.length]) ? client.redirectUris : [""],
28725
+ name: _optionalChain([client, 'optionalAccess', _777 => _777.name]) || "",
28726
+ description: _optionalChain([client, 'optionalAccess', _778 => _778.description]) || "",
28727
+ redirectUris: _optionalChain([client, 'optionalAccess', _779 => _779.redirectUris, 'optionalAccess', _780 => _780.length]) ? client.redirectUris : [""],
28725
28728
  allowedScopes: client ? client.allowedScopes || [] : defaultScopes,
28726
- isConfidential: _nullishCoalesce(_optionalChain([client, 'optionalAccess', _780 => _780.isConfidential]), () => ( true))
28729
+ isConfidential: _nullishCoalesce(_optionalChain([client, 'optionalAccess', _781 => _781.isConfidential]), () => ( true))
28727
28730
  });
28728
28731
  const [errors, setErrors] = _react.useState.call(void 0, {});
28729
28732
  const validate = _react.useCallback.call(void 0, () => {
@@ -29133,7 +29136,7 @@ function OAuthConsentScreen({
29133
29136
  if (error || !clientInfo) {
29134
29137
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "min-h-dvh flex items-center justify-center p-4", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Card, { className: "w-full max-w-md", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, CardContent, { className: "py-8", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Alert, { variant: "destructive", children: [
29135
29138
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.AlertTriangle, { className: "h-4 w-4" }),
29136
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AlertDescription, { children: _optionalChain([error, 'optionalAccess', _781 => _781.message]) || t("oauth.consent.invalid_request") })
29139
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AlertDescription, { children: _optionalChain([error, 'optionalAccess', _782 => _782.message]) || t("oauth.consent.invalid_request") })
29137
29140
  ] }) }) }) });
29138
29141
  }
29139
29142
  const { client, scopes } = clientInfo;
@@ -29356,7 +29359,7 @@ function WaitlistForm({ onSuccess }) {
29356
29359
  source: _chunkTNTCLVURjs.getSignupSource.call(void 0, )
29357
29360
  });
29358
29361
  setIsSuccess(true);
29359
- _optionalChain([onSuccess, 'optionalCall', _782 => _782()]);
29362
+ _optionalChain([onSuccess, 'optionalCall', _783 => _783()]);
29360
29363
  } catch (e) {
29361
29364
  errorToast({ title: t("common.errors.error"), error: e });
29362
29365
  } finally {
@@ -29567,11 +29570,11 @@ function WaitlistList({ fullWidth } = {}) {
29567
29570
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Button, { variant: "outline", size: "icon", onClick: refresh, disabled: !data.isLoaded, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.RefreshCw, { className: `h-4 w-4 ${!data.isLoaded ? "animate-spin" : ""}` }) })
29568
29571
  ] });
29569
29572
  const totals = [
29570
- { key: "total", label: t("waitlist.admin.total"), value: _optionalChain([stats, 'optionalAccess', _783 => _783.total]) },
29571
- { key: "pending", label: t("waitlist.admin.status.pending"), value: _optionalChain([stats, 'optionalAccess', _784 => _784.pending]) },
29572
- { key: "confirmed", label: t("waitlist.admin.status.confirmed"), value: _optionalChain([stats, 'optionalAccess', _785 => _785.confirmed]) },
29573
- { key: "invited", label: t("waitlist.admin.status.invited"), value: _optionalChain([stats, 'optionalAccess', _786 => _786.invited]) },
29574
- { key: "registered", label: t("waitlist.admin.status.registered"), value: _optionalChain([stats, 'optionalAccess', _787 => _787.registered]) }
29573
+ { key: "total", label: t("waitlist.admin.total"), value: _optionalChain([stats, 'optionalAccess', _784 => _784.total]) },
29574
+ { key: "pending", label: t("waitlist.admin.status.pending"), value: _optionalChain([stats, 'optionalAccess', _785 => _785.pending]) },
29575
+ { key: "confirmed", label: t("waitlist.admin.status.confirmed"), value: _optionalChain([stats, 'optionalAccess', _786 => _786.confirmed]) },
29576
+ { key: "invited", label: t("waitlist.admin.status.invited"), value: _optionalChain([stats, 'optionalAccess', _787 => _787.invited]) },
29577
+ { key: "registered", label: t("waitlist.admin.status.registered"), value: _optionalChain([stats, 'optionalAccess', _788 => _788.registered]) }
29575
29578
  ];
29576
29579
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-4", children: [
29577
29580
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "dl", { className: "grid grid-cols-5 divide-x divide-border rounded-md border", "data-testid": "waitlist-totals", children: totals.map((total) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col-reverse items-center gap-1 p-3", children: [
@@ -29926,7 +29929,7 @@ var ModuleEditor = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs.__n
29926
29929
  ] }),
29927
29930
  roleIds.map((roleId) => {
29928
29931
  const roleTokens = block[roleId];
29929
- const roleLabel = _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _788 => _788[roleId]]), () => ( roleId));
29932
+ const roleLabel = _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _789 => _789[roleId]]), () => ( roleId));
29930
29933
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: "border-b last:border-b-0", children: [
29931
29934
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-4 py-1 text-xs font-medium text-muted-foreground", children: roleLabel }),
29932
29935
  _chunkTNTCLVURjs.ACTION_TYPES.map((action) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-2 py-1", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -29963,7 +29966,7 @@ function RbacContainer() {
29963
29966
  }, []);
29964
29967
  const sortedModuleIds = _react.useMemo.call(void 0, () => {
29965
29968
  if (!matrix) return [];
29966
- return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _789 => _789[a]]), () => ( a))).localeCompare(_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _790 => _790[b]]), () => ( b))));
29969
+ return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _790 => _790[a]]), () => ( a))).localeCompare(_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _791 => _791[b]]), () => ( b))));
29967
29970
  }, [matrix, moduleNames]);
29968
29971
  const roleIds = _react.useMemo.call(void 0, () => {
29969
29972
  if (roleNames) {
@@ -30026,7 +30029,7 @@ function RbacContainer() {
30026
30029
  id === selectedModuleId && "bg-muted font-medium text-foreground",
30027
30030
  id !== selectedModuleId && "text-muted-foreground"
30028
30031
  ),
30029
- children: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _791 => _791[id]]), () => ( id))
30032
+ children: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _792 => _792[id]]), () => ( id))
30030
30033
  }
30031
30034
  ) }, id)) }) }),
30032
30035
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "section", { className: "flex-1 overflow-y-auto p-4", children: selectedModuleId && selectedBlock ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -30034,7 +30037,7 @@ function RbacContainer() {
30034
30037
  {
30035
30038
  moduleId: selectedModuleId,
30036
30039
  block: selectedBlock,
30037
- moduleLabel: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _792 => _792[selectedModuleId]]), () => ( selectedModuleId)),
30040
+ moduleLabel: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _793 => _793[selectedModuleId]]), () => ( selectedModuleId)),
30038
30041
  roleIds,
30039
30042
  roleNames,
30040
30043
  onOpenPicker: openPicker
@@ -30045,12 +30048,12 @@ function RbacContainer() {
30045
30048
  RbacPermissionPicker,
30046
30049
  {
30047
30050
  open: !!activePicker,
30048
- anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _793 => _793.anchor]), () => ( null)),
30051
+ anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _794 => _794.anchor]), () => ( null)),
30049
30052
  value: activeValue,
30050
- isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _794 => _794.isRoleColumn]), () => ( false)),
30053
+ isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _795 => _795.isRoleColumn]), () => ( false)),
30051
30054
  knownSegments: activeSegments,
30052
30055
  onSetValue: handleSetValue,
30053
- onClear: _optionalChain([activePicker, 'optionalAccess', _795 => _795.isRoleColumn]) ? handleClear : void 0,
30056
+ onClear: _optionalChain([activePicker, 'optionalAccess', _796 => _796.isRoleColumn]) ? handleClear : void 0,
30054
30057
  onClose: closePicker
30055
30058
  }
30056
30059
  )
@@ -30117,7 +30120,7 @@ function RbacByRoleContainer() {
30117
30120
  }, [roleNames]);
30118
30121
  const sortedModuleIds = _react.useMemo.call(void 0, () => {
30119
30122
  if (!matrix) return [];
30120
- return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _796 => _796[a]]), () => ( a))).localeCompare(_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _797 => _797[b]]), () => ( b))));
30123
+ return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _797 => _797[a]]), () => ( a))).localeCompare(_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _798 => _798[b]]), () => ( b))));
30121
30124
  }, [matrix, moduleNames]);
30122
30125
  _react.useEffect.call(void 0, () => {
30123
30126
  if (!selectedRoleId && sortedRoleIds.length > 0) {
@@ -30166,7 +30169,7 @@ function RbacByRoleContainer() {
30166
30169
  id === selectedRoleId && "bg-muted font-medium text-foreground",
30167
30170
  id !== selectedRoleId && "text-muted-foreground"
30168
30171
  ),
30169
- children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _798 => _798[id]]), () => ( id))
30172
+ children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _799 => _799[id]]), () => ( id))
30170
30173
  }
30171
30174
  ) }, id)) }) }),
30172
30175
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "section", { className: "flex-1 overflow-y-auto p-4", children: sortedModuleIds.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rounded-lg border border-accent bg-card", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "overflow-x-auto", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "table", { className: "w-full text-sm", children: [
@@ -30186,7 +30189,7 @@ function RbacByRoleContainer() {
30186
30189
  if (!block) return null;
30187
30190
  const defaultTokens = _nullishCoalesce(block.default, () => ( []));
30188
30191
  const roleTokens = block[selectedRoleId];
30189
- const moduleLabel = _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _799 => _799[moduleId]]), () => ( moduleId));
30192
+ const moduleLabel = _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _800 => _800[moduleId]]), () => ( moduleId));
30190
30193
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react.Fragment, { children: [
30191
30194
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { className: "border-b bg-muted/40", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
30192
30195
  "td",
@@ -30201,7 +30204,7 @@ function RbacByRoleContainer() {
30201
30204
  _chunkTNTCLVURjs.ACTION_TYPES.map((action) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-2 py-1", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, RbacPermissionCell, { value: cellValue2(defaultTokens, action) }) }, action))
30202
30205
  ] }),
30203
30206
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: "border-b last:border-b-0", children: [
30204
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-4 py-1 text-xs font-medium text-muted-foreground", children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _800 => _800[selectedRoleId]]), () => ( selectedRoleId)) }),
30207
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-4 py-1 text-xs font-medium text-muted-foreground", children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _801 => _801[selectedRoleId]]), () => ( selectedRoleId)) }),
30205
30208
  _chunkTNTCLVURjs.ACTION_TYPES.map((action) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-2 py-1", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
30206
30209
  CellButton3,
30207
30210
  {
@@ -30222,12 +30225,12 @@ function RbacByRoleContainer() {
30222
30225
  RbacPermissionPicker,
30223
30226
  {
30224
30227
  open: !!activePicker,
30225
- anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _801 => _801.anchor]), () => ( null)),
30228
+ anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _802 => _802.anchor]), () => ( null)),
30226
30229
  value: activeValue,
30227
- isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _802 => _802.isRoleColumn]), () => ( false)),
30230
+ isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _803 => _803.isRoleColumn]), () => ( false)),
30228
30231
  knownSegments: activeSegments,
30229
30232
  onSetValue: handleSetValue,
30230
- onClear: _optionalChain([activePicker, 'optionalAccess', _803 => _803.isRoleColumn]) ? handleClear : void 0,
30233
+ onClear: _optionalChain([activePicker, 'optionalAccess', _804 => _804.isRoleColumn]) ? handleClear : void 0,
30231
30234
  onClose: closePicker
30232
30235
  }
30233
30236
  )
@@ -30887,4 +30890,4 @@ _chunk7QVYU63Ejs.__name.call(void 0, RbacByRoleContainer, "RbacByRoleContainer")
30887
30890
 
30888
30891
 
30889
30892
  exports.JsonApiProvider = JsonApiProvider; exports.useJsonApiGet = useJsonApiGet; exports.useJsonApiMutation = useJsonApiMutation; exports.useRehydration = useRehydration; exports.useRehydrationList = useRehydrationList; exports.TableGeneratorRegistry = TableGeneratorRegistry; exports.tableGeneratorRegistry = tableGeneratorRegistry; exports.usePageUrlGenerator = usePageUrlGenerator; exports.useUrlRewriter = useUrlRewriter; exports.useDataListRetriever = useDataListRetriever; exports.useDebounce = useDebounce2; exports.registerTableGenerator = registerTableGenerator; exports.useTableGenerator = useTableGenerator; exports.computeLayeredLayout = computeLayeredLayout; exports.fitLayeredLayoutToAspectRatio = fitLayeredLayoutToAspectRatio; exports.useCustomD3Graph = useCustomD3Graph; exports.SharedProvider = SharedProvider; exports.useSharedContext = useSharedContext; exports.AdministrationProvider = AdministrationProvider; exports.useAdministrationContext = useAdministrationContext; exports.SocketContext = SocketContext; exports.SocketProvider = SocketProvider; exports.useSocketContext = useSocketContext; exports.CurrentUserProvider = CurrentUserProvider; exports.useCurrentUserContext = useCurrentUserContext; exports.useCurrentUserContextOptional = useCurrentUserContextOptional; exports.errorToast = errorToast; exports.buttonVariants = buttonVariants; exports.Button = Button; exports.AlertDialog = AlertDialog; exports.AlertDialogTrigger = AlertDialogTrigger; exports.AlertDialogPortal = AlertDialogPortal; exports.AlertDialogOverlay = AlertDialogOverlay; exports.AlertDialogContent = AlertDialogContent; exports.AlertDialogHeader = AlertDialogHeader; exports.AlertDialogFooter = AlertDialogFooter; exports.AlertDialogMedia = AlertDialogMedia; exports.AlertDialogTitle = AlertDialogTitle; exports.AlertDialogDescription = AlertDialogDescription; exports.AlertDialogAction = AlertDialogAction; exports.AlertDialogCancel = AlertDialogCancel; exports.Input = Input; exports.Label = Label; exports.isAccountDeletionEnabled = isAccountDeletionEnabled; exports.AccountDeletionAdminTrigger = AccountDeletionAdminTrigger; exports.Accordion = Accordion; exports.AccordionItem = AccordionItem; exports.AccordionTrigger = AccordionTrigger; exports.AccordionContent = AccordionContent; exports.Alert = Alert; exports.AlertTitle = AlertTitle; exports.AlertDescription = AlertDescription; exports.AlertAction = AlertAction; exports.Avatar = Avatar; exports.AvatarImage = AvatarImage; exports.AvatarFallback = AvatarFallback; exports.AvatarBadge = AvatarBadge; exports.AvatarGroup = AvatarGroup; exports.AvatarGroupCount = AvatarGroupCount; exports.badgeVariants = badgeVariants; exports.Badge = Badge; exports.Breadcrumb = Breadcrumb; exports.BreadcrumbList = BreadcrumbList; exports.BreadcrumbItem = BreadcrumbItem; exports.BreadcrumbLink = BreadcrumbLink; exports.BreadcrumbPage = BreadcrumbPage; exports.BreadcrumbSeparator = BreadcrumbSeparator; exports.BreadcrumbEllipsis = BreadcrumbEllipsis; exports.DirectionProvider = DirectionProvider; exports.useDir = useDir; exports.Calendar = Calendar; exports.CalendarDayButton = CalendarDayButton; exports.Card = Card; exports.CardHeader = CardHeader; exports.CardTitle = CardTitle; exports.CardDescription = CardDescription; exports.CardAction = CardAction; exports.CardContent = CardContent; exports.CardFooter = CardFooter; exports.useCarousel = useCarousel; exports.Carousel = Carousel; exports.CarouselContent = CarouselContent; exports.CarouselItem = CarouselItem; exports.CarouselPrevious = CarouselPrevious; exports.CarouselNext = CarouselNext; exports.ChartContainer = ChartContainer; exports.ChartStyle = ChartStyle; exports.ChartTooltip = ChartTooltip; exports.ChartTooltipContent = ChartTooltipContent; exports.ChartLegend = ChartLegend; exports.ChartLegendContent = ChartLegendContent; exports.Checkbox = Checkbox; exports.Collapsible = Collapsible; exports.CollapsibleTrigger = CollapsibleTrigger; exports.CollapsibleContent = CollapsibleContent; exports.Textarea = Textarea; exports.InputGroup = InputGroup; exports.InputGroupAddon = InputGroupAddon; exports.InputGroupButton = InputGroupButton; exports.InputGroupText = InputGroupText; exports.InputGroupInput = InputGroupInput; exports.InputGroupTextarea = InputGroupTextarea; exports.Combobox = Combobox; exports.ComboboxValue = ComboboxValue; exports.ComboboxTrigger = ComboboxTrigger; exports.ComboboxInput = ComboboxInput; exports.ComboboxContent = ComboboxContent; exports.ComboboxList = ComboboxList; exports.ComboboxItem = ComboboxItem; exports.ComboboxGroup = ComboboxGroup; exports.ComboboxLabel = ComboboxLabel; exports.ComboboxCollection = ComboboxCollection; exports.ComboboxEmpty = ComboboxEmpty; exports.ComboboxSeparator = ComboboxSeparator; exports.ComboboxChips = ComboboxChips; exports.ComboboxChip = ComboboxChip; exports.ComboboxChipsInput = ComboboxChipsInput; exports.useComboboxAnchor = useComboboxAnchor; exports.Dialog = Dialog; exports.DialogTrigger = DialogTrigger; exports.DialogPortal = DialogPortal; exports.DialogClose = DialogClose; exports.DialogOverlay = DialogOverlay; exports.DialogContent = DialogContent; exports.DialogHeader = DialogHeader; exports.DialogFooter = DialogFooter; exports.DialogTitle = DialogTitle; exports.DialogDescription = DialogDescription; exports.Command = Command; exports.CommandDialog = CommandDialog; exports.CommandInput = CommandInput; exports.CommandList = CommandList; exports.CommandEmpty = CommandEmpty; exports.CommandGroup = CommandGroup; exports.CommandSeparator = CommandSeparator; exports.CommandItem = CommandItem; exports.CommandShortcut = CommandShortcut; exports.commandFilterByKeywords = commandFilterByKeywords; exports.ConfirmDialog = ConfirmDialog; exports.ContextMenu = ContextMenu; exports.ContextMenuPortal = ContextMenuPortal; exports.ContextMenuTrigger = ContextMenuTrigger; exports.ContextMenuContent = ContextMenuContent; exports.ContextMenuGroup = ContextMenuGroup; exports.ContextMenuLabel = ContextMenuLabel; exports.ContextMenuItem = ContextMenuItem; exports.ContextMenuSub = ContextMenuSub; exports.ContextMenuSubTrigger = ContextMenuSubTrigger; exports.ContextMenuSubContent = ContextMenuSubContent; exports.ContextMenuCheckboxItem = ContextMenuCheckboxItem; exports.ContextMenuRadioGroup = ContextMenuRadioGroup; exports.ContextMenuRadioItem = ContextMenuRadioItem; exports.ContextMenuSeparator = ContextMenuSeparator; exports.ContextMenuShortcut = ContextMenuShortcut; exports.Drawer = Drawer; exports.DrawerTrigger = DrawerTrigger; exports.DrawerPortal = DrawerPortal; exports.DrawerClose = DrawerClose; exports.DrawerOverlay = DrawerOverlay; exports.DrawerContent = DrawerContent; exports.DrawerHeader = DrawerHeader; exports.DrawerFooter = DrawerFooter; exports.DrawerTitle = DrawerTitle; exports.DrawerDescription = DrawerDescription; exports.DropdownMenu = DropdownMenu; exports.DropdownMenuPortal = DropdownMenuPortal; exports.DropdownMenuTrigger = DropdownMenuTrigger; exports.DropdownMenuContent = DropdownMenuContent; exports.DropdownMenuGroup = DropdownMenuGroup; exports.DropdownMenuLabel = DropdownMenuLabel; exports.DropdownMenuItem = DropdownMenuItem; exports.DropdownMenuSub = DropdownMenuSub; exports.DropdownMenuSubTrigger = DropdownMenuSubTrigger; exports.DropdownMenuSubContent = DropdownMenuSubContent; exports.DropdownMenuCheckboxItem = DropdownMenuCheckboxItem; exports.DropdownMenuRadioGroup = DropdownMenuRadioGroup; exports.DropdownMenuRadioItem = DropdownMenuRadioItem; exports.DropdownMenuSeparator = DropdownMenuSeparator; exports.DropdownMenuShortcut = DropdownMenuShortcut; exports.EmptyState = EmptyState; exports.Separator = Separator; exports.FieldSet = FieldSet; exports.FieldLegend = FieldLegend; exports.FieldGroup = FieldGroup; exports.Field = Field; exports.FieldContent = FieldContent; exports.FieldLabel = FieldLabel; exports.FieldTitle = FieldTitle; exports.FieldDescription = FieldDescription; exports.FieldSeparator = FieldSeparator; exports.FieldError = FieldError; exports.Form = Form; exports.HoverCard = HoverCard; exports.HoverCardTrigger = HoverCardTrigger; exports.HoverCardContent = HoverCardContent; exports.InputOTP = InputOTP; exports.InputOTPGroup = InputOTPGroup; exports.InputOTPSlot = InputOTPSlot; exports.InputOTPSeparator = InputOTPSeparator; exports.NavigationMenu = NavigationMenu; exports.NavigationMenuList = NavigationMenuList; exports.NavigationMenuItem = NavigationMenuItem; exports.navigationMenuTriggerStyle = navigationMenuTriggerStyle; exports.NavigationMenuTrigger = NavigationMenuTrigger; exports.NavigationMenuContent = NavigationMenuContent; exports.NavigationMenuPositioner = NavigationMenuPositioner; exports.NavigationMenuLink = NavigationMenuLink; exports.NavigationMenuIndicator = NavigationMenuIndicator; exports.Popover = Popover; exports.PopoverTrigger = PopoverTrigger; exports.PopoverContent = PopoverContent; exports.PopoverHeader = PopoverHeader; exports.PopoverTitle = PopoverTitle; exports.PopoverDescription = PopoverDescription; exports.Progress = Progress; exports.ProgressTrack = ProgressTrack; exports.ProgressIndicator = ProgressIndicator; exports.ProgressLabel = ProgressLabel; exports.ProgressValue = ProgressValue; exports.RadioGroup = RadioGroup; exports.RadioGroupItem = RadioGroupItem; exports.ResizablePanelGroup = ResizablePanelGroup; exports.ResizablePanel = ResizablePanel; exports.ResizableHandle = ResizableHandle; exports.ScrollArea = ScrollArea; exports.ScrollBar = ScrollBar; exports.Select = Select; exports.SelectGroup = SelectGroup; exports.SelectValue = SelectValue; exports.SelectTrigger = SelectTrigger; exports.SelectContent = SelectContent; exports.SelectLabel = SelectLabel; exports.SelectItem = SelectItem; exports.SelectSeparator = SelectSeparator; exports.SelectScrollUpButton = SelectScrollUpButton; exports.SelectScrollDownButton = SelectScrollDownButton; exports.Sheet = Sheet; exports.SheetTrigger = SheetTrigger; exports.SheetClose = SheetClose; exports.SheetContent = SheetContent; exports.SheetHeader = SheetHeader; exports.SheetFooter = SheetFooter; exports.SheetTitle = SheetTitle; exports.SheetDescription = SheetDescription; exports.Skeleton = Skeleton; exports.TooltipProvider = TooltipProvider; exports.Tooltip = Tooltip2; exports.TooltipTrigger = TooltipTrigger; exports.TooltipContent = TooltipContent; exports.useSidebar = useSidebar; exports.useSidebarControls = useSidebarControls; exports.useOptionalSidebar = useOptionalSidebar; exports.SidebarProvider = SidebarProvider; exports.Sidebar = Sidebar; exports.SidebarTrigger = SidebarTrigger; exports.SidebarRail = SidebarRail; exports.SidebarInset = SidebarInset; exports.SidebarInput = SidebarInput; exports.SidebarHeader = SidebarHeader; exports.SidebarFooter = SidebarFooter; exports.SidebarSeparator = SidebarSeparator; exports.SidebarContent = SidebarContent; exports.SidebarGroup = SidebarGroup; exports.SidebarGroupLabel = SidebarGroupLabel; exports.SidebarGroupAction = SidebarGroupAction; exports.SidebarGroupContent = SidebarGroupContent; exports.SidebarMenu = SidebarMenu; exports.SidebarMenuItem = SidebarMenuItem; exports.SidebarMenuButton = SidebarMenuButton; exports.SidebarMenuAction = SidebarMenuAction; exports.SidebarMenuBadge = SidebarMenuBadge; exports.SidebarMenuSkeleton = SidebarMenuSkeleton; exports.SidebarMenuSub = SidebarMenuSub; exports.SidebarMenuSubItem = SidebarMenuSubItem; exports.SidebarMenuSubButton = SidebarMenuSubButton; exports.Slider = Slider; exports.Toaster = Toaster; exports.spinnerVariants = spinnerVariants; exports.Spinner = Spinner; exports.Switch = Switch; exports.Table = Table; exports.TableHeader = TableHeader; exports.TableBody = TableBody; exports.TableFooter = TableFooter; exports.TableRow = TableRow; exports.TableHead = TableHead; exports.TableCell = TableCell; exports.TableCaption = TableCaption; exports.Tabs = Tabs; exports.tabsListVariants = tabsListVariants; exports.TabsList = TabsList; exports.TabsTrigger = TabsTrigger; exports.TabsContent = TabsContent; exports.toggleVariants = toggleVariants; exports.Toggle = Toggle; exports.KanbanRoot = KanbanRoot; exports.KanbanBoard = KanbanBoard; exports.KanbanColumn = KanbanColumn; exports.KanbanColumnHandle = KanbanColumnHandle; exports.KanbanItem = KanbanItem; exports.KanbanItemHandle = KanbanItemHandle; exports.KanbanOverlay = KanbanOverlay; exports.Link = Link; exports.MultiSelect = MultiSelect; exports.useDebounce2 = useDebounce; exports.MultipleSelector = MultipleSelector; exports.EntityAvatar = EntityAvatar; exports.EditableAvatar = EditableAvatar; exports.TableCellAvatar = TableCellAvatar; exports.HeaderChildrenProvider = HeaderChildrenProvider; exports.useHeaderChildren = useHeaderChildren; exports.useHeaderMobileChildren = useHeaderMobileChildren; exports.useHeaderRootLabel = useHeaderRootLabel; exports.HeaderLeftContentProvider = HeaderLeftContentProvider; exports.useHeaderLeftContent = useHeaderLeftContent; exports.HeaderLogoProvider = HeaderLogoProvider; exports.useHeaderLogo = useHeaderLogo; exports.BreadcrumbNavigation = BreadcrumbNavigation; exports.ContentTitle = ContentTitle; exports.BreadcrumbRootProvider = BreadcrumbRootProvider; exports.useIsBreadcrumbRootHidden = useIsBreadcrumbRootHidden; exports.Header = Header; exports.MobileNavigationProvider = MobileNavigationProvider; exports.useMobileNavigationItems = useMobileNavigationItems; exports.MobileNavigationBar = MobileNavigationBar; exports.ModeToggleSwitch = ModeToggleSwitch; exports.PageSection = PageSection; exports.recentPagesAtom = recentPagesAtom; exports.RecentPagesNavigator = RecentPagesNavigator; exports.PageContainer = PageContainer; exports.partitionTabs = partitionTabs; exports.MermaidDiagram = MermaidDiagram; exports.ReactMarkdownContainer = ReactMarkdownContainer; exports.HEADER_ROW_MIN_H = HEADER_ROW_MIN_H; exports.RoundPageContainerTitle = RoundPageContainerTitle; exports.SectionHeader = SectionHeader; exports.MicroLabel = MicroLabel; exports.DetailField = DetailField; exports.RoundPageContainer = RoundPageContainer; exports.TabsContainer = TabsContainer; exports.AttributeElement = AttributeElement; exports.AllUsersListContainer = AllUsersListContainer; exports.PlatformUsersList = PlatformUsersList; exports.PlatformUsersContainer = PlatformUsersContainer; exports.UserContent = UserContent; exports.UserAvatar = UserAvatar; exports.UserAvatarList = UserAvatarList; exports.useUserSearch = useUserSearch; exports.useUserTableStructure = useUserTableStructure; exports.UserSearchPopover = UserSearchPopover; exports.UserIndexDetails = UserIndexDetails; exports.UserStanadaloneDetails = UserStanadaloneDetails; exports.UserContainer = UserContainer; exports.UserIndexContainer = UserIndexContainer; exports.UsersListContainer = UsersListContainer; exports.AdminUsersList = AdminUsersList; exports.CompanyUsersList = CompanyUsersList; exports.ContributorsList = ContributorsList; exports.RelevantUsersList = RelevantUsersList; exports.RoleUsersList = RoleUsersList; exports.UserListInAdd = UserListInAdd; exports.UsersList = UsersList; exports.UsersListByContentIds = UsersListByContentIds; exports.AllowedUsersDetails = AllowedUsersDetails; exports.ErrorDetails = ErrorDetails; exports.BlockNoteEditorMentionHoverCard = BlockNoteEditorMentionHoverCard; exports.mentionDataAttrs = mentionDataAttrs; exports.parseMentionElement = parseMentionElement; exports.createMentionInlineContentSpec = createMentionInlineContentSpec; exports.useMentionInsert = useMentionInsert; exports.BlockNoteEditorMentionSuggestionMenu = BlockNoteEditorMentionSuggestionMenu; exports.BlockNoteEditorContainer = BlockNoteEditorContainer; exports.BlockNoteViewerContainer = BlockNoteViewerContainer; exports.BlockNoteStaticViewer = BlockNoteStaticViewer; exports.FormFeatures = FormFeatures; exports.CommonAssociationTrigger = CommonAssociationTrigger; exports.CommonAssociationCommandDialog = CommonAssociationCommandDialog; exports.triggerAssociationToast = triggerAssociationToast; exports.ActionBarProvider = ActionBarProvider; exports.useIsInActionBar = useIsInActionBar; exports.CommonDeleter = CommonDeleter; exports.CommonEditorButtons = CommonEditorButtons; exports.CommonEditorDiscardDialog = CommonEditorDiscardDialog; exports.CommonEditorHeader = CommonEditorHeader; exports.CommonEditorTrigger = CommonEditorTrigger; exports.CommonAddTrigger = CommonAddTrigger; exports.CurrencyInput = CurrencyInput; exports.DatePickerPopover = DatePickerPopover; exports.nextDateRange = nextDateRange; exports.DateRangeSelector = DateRangeSelector; exports.hasOpenInnerLayer = hasOpenInnerLayer; exports.useEditorDialog = useEditorDialog; exports.EditorSheet = EditorSheet; exports.FormFieldWrapper = FormFieldWrapper; exports.EntityMultiSelector = EntityMultiSelector; exports.EntitySelector = EntitySelector; exports.useFileUpload = useFileUpload; exports.FileUploader = FileUploader; exports.FileUploaderContent = FileUploaderContent; exports.FileUploaderItem = FileUploaderItem; exports.FileInput = FileInput; exports.FormBlockNote = FormBlockNote; exports.FormCheckbox = FormCheckbox; exports.FormDate = FormDate; exports.FormDateTime = FormDateTime; exports.FormInput = FormInput; exports.FormBody = FormBody; exports.FormSection = FormSection; exports.FormRow = FormRow; exports.FormCol = FormCol; exports.PasswordInput = PasswordInput; exports.FormPassword = FormPassword; exports.FormPlaceAutocomplete = FormPlaceAutocomplete; exports.FormSelect = FormSelect; exports.FormSlider = FormSlider; exports.FormSwitch = FormSwitch; exports.FormTextarea = FormTextarea; exports.GdprConsentCheckbox = GdprConsentCheckbox; exports.MultiFileUploader = MultiFileUploader; exports.PageContainerContentDetails = PageContainerContentDetails; exports.PageContentContainer = PageContentContainer; exports.cellComponent = cellComponent; exports.cellDate = cellDate; exports.cellDateTime = cellDateTime; exports.cellId = cellId; exports.cellLink = cellLink; exports.cellUrl = cellUrl; exports.ContentTableSearch = ContentTableSearch; exports.ContentListTable = ContentListTable; exports.ContentListGrid = ContentListGrid; exports.ItalianFiscalData_default = ItalianFiscalData_default; exports.ItalianFiscalDataDisplay = ItalianFiscalDataDisplay; exports.parseFiscalData = parseFiscalData; exports.FiscalDataDisplay = FiscalDataDisplay; exports.EntityHeroLayout = EntityHeroLayout; exports.EntityHero = EntityHero; exports.EntityHeroAvatar = EntityHeroAvatar; exports.EntityHeroMetaRow = EntityHeroMetaRow; exports.EntitySection = EntitySection; exports.AccountDeletionCancelledNotice = AccountDeletionCancelledNotice; exports.AccountDeletionKeepContainer = AccountDeletionKeepContainer; exports.GdprConsentSection = GdprConsentSection; exports.AuthContainer = AuthContainer; exports.BackupCodesDialog = BackupCodesDialog; exports.TotpInput = TotpInput; exports.DisableTwoFactorDialog = DisableTwoFactorDialog; exports.PasskeyList = PasskeyList; exports.PasskeySetupDialog = PasskeySetupDialog; exports.TotpAuthenticatorList = TotpAuthenticatorList; exports.TotpSetupDialog = TotpSetupDialog; exports.TwoFactorSettings = TwoFactorSettings; exports.SecurityContainer = SecurityContainer; exports.LandingComponent = LandingComponent; exports.AcceptInvitation = AcceptInvitation; exports.ActivateAccount = ActivateAccount; exports.Cookies = Cookies; exports.ForgotPassword = ForgotPassword; exports.Login = Login; exports.Logout = Logout; exports.RefreshUser = RefreshUser; exports.ResetPassword = ResetPassword; exports.PasskeyButton = PasskeyButton; exports.TwoFactorChallenge = TwoFactorChallenge; exports.ADMIN_PLATFORM_SECTIONS = ADMIN_PLATFORM_SECTIONS; exports.AdminIndexGrid = AdminIndexGrid; exports.AdminIndexContainer = AdminIndexContainer; exports.ADMINISTRATION_I18N_KEYS = ADMINISTRATION_I18N_KEYS; exports.AI_CONNECTIONS_I18N_KEYS = AI_CONNECTIONS_I18N_KEYS; exports.AiConnectionsProvider = AiConnectionsProvider; exports.useAiConnections = useAiConnections; exports.AiConnectionDeleter = AiConnectionDeleter; exports.AiConnectionEditor = AiConnectionEditor; exports.AiConnectionTypeCard = AiConnectionTypeCard; exports.AI_CONNECTION_TYPE_ORDER = AI_CONNECTION_TYPE_ORDER; exports.AiConnectionsContainer = AiConnectionsContainer; exports.CreditWarningBanner = CreditWarningBanner; exports.CompanyContent = CompanyContent; exports.TokenStatusIndicator = TokenStatusIndicator; exports.CompanyDetails = CompanyDetails; exports.AdminCompanyContainer = AdminCompanyContainer; exports.CompanyEditor = CompanyEditor; exports.CompaniesList = CompaniesList; exports.CompaniesListContainer = CompaniesListContainer; exports.CompanyContainer = CompanyContainer; exports.CompanyConfigurationEditor = CompanyConfigurationEditor; exports.CompanyDeleter = CompanyDeleter; exports.ContentsList = ContentsList; exports.ContentsListById = ContentsListById; exports.RelevantContentsList = RelevantContentsList; exports.EmailBlastEditor = EmailBlastEditor; exports.EmailBlastsList = EmailBlastsList; exports.EmailBlastsListContainer = EmailBlastsListContainer; exports.EmailBlastSendDialog = EmailBlastSendDialog; exports.EmailBlastContainer = EmailBlastContainer; exports.HowToCommandViewer = HowToCommandViewer; exports.HowToCommand = HowToCommand; exports.HowToDeleter = HowToDeleter; exports.HowToMultiSelector = HowToMultiSelector; exports.HowToEditor = HowToEditor; exports.HowToProvider = HowToProvider; exports.useHowToContext = useHowToContext; exports.HowToContent = HowToContent; exports.HowToDetails = HowToDetails; exports.HowToContainer = HowToContainer; exports.HowToReindexButton = HowToReindexButton; exports.HowToList = HowToList; exports.HowToListContainer = HowToListContainer; exports.HowToSelector = HowToSelector; exports.AssistantComposer = AssistantComposer; exports.MessageSourcesPanel = MessageSourcesPanel; exports.MessageItem = MessageItem; exports.MessageList = MessageList; exports.AssistantThread = AssistantThread; exports.HandbookAskSheet = HandbookAskSheet; exports.HandbookSyncButton = HandbookSyncButton; exports.HandbookIndexStatus = HandbookIndexStatus; exports.HandbookSectionGroup = HandbookSectionGroup; exports.HandbookContents = HandbookContents; exports.HandbookAdminContainer = HandbookAdminContainer; exports.HandbookPageDetails = HandbookPageDetails; exports.HandbookPageNeighbours = HandbookPageNeighbours; exports.HandbookPageToc = HandbookPageToc; exports.HandbookPageNavigator = HandbookPageNavigator; exports.HandbookPageContainer = HandbookPageContainer; exports.HandbookAskContainer = HandbookAskContainer; exports.EntityMentionLink = EntityMentionLink; exports.AssistantProvider = AssistantProvider; exports.useAssistantContext = useAssistantContext; exports.AssistantEmptyState = AssistantEmptyState; exports.AssistantContainer = AssistantContainer; exports.AssistantBlockNoteComposer = AssistantBlockNoteComposer; exports.AssistantPageContainer = AssistantPageContainer; exports.ApprovalActionCard = ApprovalActionCard; exports.AssistantContainerWithApprovals = AssistantContainerWithApprovals; exports.NotificationErrorBoundary = NotificationErrorBoundary; exports.NotificationIcon = NotificationIcon; exports.generateNotificationData = generateNotificationData; exports.NotificationToast = NotificationToast; exports.NotificationMenuItem = NotificationMenuItem; exports.NotificationContextProvider = NotificationContextProvider; exports.useNotificationContext = useNotificationContext; exports.NotificationViewSwitcher = NotificationViewSwitcher; exports.NotificationsList = NotificationsList; exports.NotificationsListContainer = NotificationsListContainer; exports.NotificationModal = NotificationModal; exports.usePushNotifications = usePushNotifications; exports.PushNotificationProvider = PushNotificationProvider; exports.OnboardingCard = OnboardingCard; exports.ReferralCodeCapture = ReferralCodeCapture; exports.ReferralWidget = ReferralWidget; exports.ReferralDialog = ReferralDialog; exports.createUsageFormatters = createUsageFormatters; exports.useUsageFormatters = useUsageFormatters; exports.CATEGORICAL_CEILING = CATEGORICAL_CEILING; exports.OTHER_COLOR = OTHER_COLOR; exports.SEQUENTIAL_RAMP = SEQUENTIAL_RAMP; exports.seriesColor = seriesColor; exports.seriesTheme = seriesTheme; exports.ReferralsAdminFunnel = ReferralsAdminFunnel; exports.metricValue = metricValue; exports.cacheHitPercentage = cacheHitPercentage; exports.percentageDelta = percentageDelta; exports.ReferralsAdminTiles = ReferralsAdminTiles; exports.ReferralsAdminContainer = ReferralsAdminContainer; exports.SignupSourceCapture = SignupSourceCapture; exports.RoleProvider = RoleProvider; exports.useRoleContext = useRoleContext; exports.RoleDetails = RoleDetails; exports.RoleContainer = RoleContainer; exports.FormRoles = FormRoles; exports.RemoveUserFromRole = RemoveUserFromRole; exports.UserRoleAdd = UserRoleAdd; exports.useRoleTableStructure = useRoleTableStructure; exports.RolesList = RolesList; exports.UserRolesList = UserRolesList; exports.OAuthRedirectUriInput = OAuthRedirectUriInput; exports.useOAuthScopeText = useOAuthScopeText; exports.OAuthScopeSelector = OAuthScopeSelector; exports.OAuthClientSecretDisplay = OAuthClientSecretDisplay; exports.OAuthClientCard = OAuthClientCard; exports.OAuthClientList = OAuthClientList; exports.OAuthClientForm = OAuthClientForm; exports.OAuthClientDetail = OAuthClientDetail; exports.OAuthConsentHeader = OAuthConsentHeader; exports.OAuthScopeList = OAuthScopeList; exports.OAuthConsentActions = OAuthConsentActions; exports.OAuthCompanySelector = OAuthCompanySelector; exports.useOAuthConsent = useOAuthConsent; exports.OAuthConsentScreen = OAuthConsentScreen; exports.WaitlistQuestionnaireRenderer = WaitlistQuestionnaireRenderer; exports.WaitlistForm = WaitlistForm; exports.WaitlistHeroSection = WaitlistHeroSection; exports.WaitlistSuccessState = WaitlistSuccessState; exports.WaitlistConfirmation = WaitlistConfirmation; exports.WaitlistList = WaitlistList; exports.RbacProvider = RbacProvider; exports.useRbacContext = useRbacContext; exports.RbacPermissionCell = RbacPermissionCell; exports.RbacPermissionPicker = RbacPermissionPicker; exports.RbacContainer = RbacContainer; exports.RbacByRoleContainer = RbacByRoleContainer; exports.AddUserToRole = AddUserToRole; exports.UserAvatarEditor = UserAvatarEditor; exports.UserDeleter = UserDeleter; exports.UserEditor = UserEditor; exports.UserMultiSelect = UserMultiSelect; exports.UserReactivator = UserReactivator; exports.UserResentInvitationEmail = UserResentInvitationEmail; exports.UserSelector = UserSelector; exports.UserProvider = UserProvider; exports.useUserContext = useUserContext; exports.CompanyProvider = CompanyProvider; exports.useCompanyContext = useCompanyContext; exports.DEFAULT_ONBOARDING_LABELS = DEFAULT_ONBOARDING_LABELS; exports.mapOnboardingSide = mapOnboardingSide; exports.OnboardingProvider = OnboardingProvider; exports.useOnboarding = useOnboarding; exports.CommonProvider = CommonProvider; exports.useCommonContext = useCommonContext; exports.SessionProvider = SessionProvider; exports.useSession = useSession; exports.ViewportProvider = ViewportProvider; exports.useNotificationSync = useNotificationSync; exports.usePageTracker = usePageTracker; exports.useSocket = useSocket; exports.useSubscriptionStatus = useSubscriptionStatus; exports.formatDate = formatDate2; exports.useBillingFormatOptions = useBillingFormatOptions; exports.promotionCodeDiscount = promotionCodeDiscount; exports.subscriptionDiscount = subscriptionDiscount; exports.applyDiscount = applyDiscount; exports.CouponRefresher = CouponRefresher; exports.couponPageModule = couponPageModule; exports.parseOptionalPositiveInt = parseOptionalPositiveInt; exports.parseOptionalDecimal = parseOptionalDecimal; exports.optionalPositiveInt = optionalPositiveInt; exports.optionalDecimal = optionalDecimal; exports.optionalDate = optionalDate; exports.couponCodeSchema = couponCodeSchema; exports.couponCodeDefaults = couponCodeDefaults; exports.toCouponCodeInput = toCouponCodeInput; exports.couponCurrencyOptions = couponCurrencyOptions; exports.CouponCodeFields = CouponCodeFields; exports.CouponEditor = CouponEditor; exports.CouponProvider = CouponProvider; exports.useCouponContext = useCouponContext; exports.CouponCodeActions = CouponCodeActions; exports.useContentTableStructure = useContentTableStructure; exports.useOAuthClients = useOAuthClients; exports.useOAuthClient = useOAuthClient;
30890
- //# sourceMappingURL=chunk-R5722NLL.js.map
30893
+ //# sourceMappingURL=chunk-BDWV4KYR.js.map