@carlonicora/nextjs-jsonapi 1.122.0 → 1.123.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{BlockNoteEditor-AY23XLHO.mjs → BlockNoteEditor-4UBKHQHZ.mjs} +2 -2
- package/dist/{BlockNoteEditor-ICKHUZYK.js → BlockNoteEditor-JWE5R6TH.js} +9 -9
- package/dist/{BlockNoteEditor-ICKHUZYK.js.map → BlockNoteEditor-JWE5R6TH.js.map} +1 -1
- package/dist/billing/index.js +299 -299
- package/dist/billing/index.mjs +1 -1
- package/dist/{chunk-5RS7Z4YW.js → chunk-NHTN4LWQ.js} +337 -311
- package/dist/chunk-NHTN4LWQ.js.map +1 -0
- package/dist/{chunk-IRVHKT5I.mjs → chunk-WDWU5VJ5.mjs} +402 -376
- package/dist/chunk-WDWU5VJ5.mjs.map +1 -0
- package/dist/client/index.js +2 -2
- package/dist/client/index.mjs +1 -1
- package/dist/components/index.d.mts +2 -2
- package/dist/components/index.d.ts +2 -2
- package/dist/components/index.js +2 -2
- package/dist/components/index.mjs +1 -1
- package/dist/contexts/index.js +2 -2
- package/dist/contexts/index.mjs +1 -1
- package/dist/features/help/index.js +30 -30
- package/dist/features/help/index.mjs +1 -1
- package/package.json +1 -1
- package/src/components/containers/RoundPageContainerTitle.tsx +7 -4
- package/src/shadcnui/ui/tabs.tsx +48 -10
- package/dist/chunk-5RS7Z4YW.js.map +0 -1
- package/dist/chunk-IRVHKT5I.mjs.map +0 -1
- /package/dist/{BlockNoteEditor-AY23XLHO.mjs.map → BlockNoteEditor-4UBKHQHZ.mjs.map} +0 -0
|
@@ -4417,16 +4417,33 @@ _chunk7QVYU63Ejs.__name.call(void 0, TableCaption, "TableCaption");
|
|
|
4417
4417
|
var _tabs = require('@base-ui/react/tabs');
|
|
4418
4418
|
|
|
4419
4419
|
|
|
4420
|
-
|
|
4421
|
-
|
|
4420
|
+
|
|
4421
|
+
var TabsActiveValueContext = _react.createContext.call(void 0, void 0);
|
|
4422
|
+
function Tabs({
|
|
4423
|
+
className,
|
|
4424
|
+
orientation = "horizontal",
|
|
4425
|
+
value,
|
|
4426
|
+
defaultValue,
|
|
4427
|
+
onValueChange,
|
|
4428
|
+
...props
|
|
4429
|
+
}) {
|
|
4430
|
+
const [uncontrolledValue, setUncontrolledValue] = _react.useState.call(void 0, defaultValue);
|
|
4431
|
+
const activeValue = value !== void 0 ? value : uncontrolledValue;
|
|
4432
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TabsActiveValueContext.Provider, { value: activeValue, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4422
4433
|
_tabs.Tabs.Root,
|
|
4423
4434
|
{
|
|
4424
4435
|
"data-slot": "tabs",
|
|
4425
4436
|
"data-orientation": orientation,
|
|
4426
4437
|
className: _chunkPQBKPWBYjs.cn.call(void 0, "gap-2 group/tabs flex data-[orientation=horizontal]:flex-col", className),
|
|
4438
|
+
value,
|
|
4439
|
+
defaultValue,
|
|
4440
|
+
onValueChange: (newValue, eventDetails) => {
|
|
4441
|
+
setUncontrolledValue(newValue);
|
|
4442
|
+
_optionalChain([onValueChange, 'optionalCall', _44 => _44(newValue, eventDetails)]);
|
|
4443
|
+
},
|
|
4427
4444
|
...props
|
|
4428
4445
|
}
|
|
4429
|
-
);
|
|
4446
|
+
) });
|
|
4430
4447
|
}
|
|
4431
4448
|
_chunk7QVYU63Ejs.__name.call(void 0, Tabs, "Tabs");
|
|
4432
4449
|
var tabsListVariants = _classvarianceauthority.cva.call(void 0,
|
|
@@ -4476,13 +4493,21 @@ function TabsTrigger({ className, ...props }) {
|
|
|
4476
4493
|
);
|
|
4477
4494
|
}
|
|
4478
4495
|
_chunk7QVYU63Ejs.__name.call(void 0, TabsTrigger, "TabsTrigger");
|
|
4479
|
-
function TabsContent({ className, ...props }) {
|
|
4496
|
+
function TabsContent({ className, value, keepMounted, children, ...props }) {
|
|
4497
|
+
const activeValue = _react.useContext.call(void 0, TabsActiveValueContext);
|
|
4498
|
+
const isActive = activeValue !== void 0 && activeValue === value;
|
|
4499
|
+
const [hasBeenActive, setHasBeenActive] = _react.useState.call(void 0, isActive);
|
|
4500
|
+
if (isActive && !hasBeenActive) setHasBeenActive(true);
|
|
4501
|
+
const shouldRenderChildren = !keepMounted || activeValue === void 0 || hasBeenActive;
|
|
4480
4502
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4481
4503
|
_tabs.Tabs.Panel,
|
|
4482
4504
|
{
|
|
4483
4505
|
"data-slot": "tabs-content",
|
|
4506
|
+
value,
|
|
4507
|
+
keepMounted,
|
|
4484
4508
|
className: _chunkPQBKPWBYjs.cn.call(void 0, "text-xs/relaxed flex-1 outline-none", className),
|
|
4485
|
-
...props
|
|
4509
|
+
...props,
|
|
4510
|
+
children: shouldRenderChildren ? children : null
|
|
4486
4511
|
}
|
|
4487
4512
|
);
|
|
4488
4513
|
}
|
|
@@ -4561,14 +4586,14 @@ var coordinateGetter = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (eve
|
|
|
4561
4586
|
if (!active || !collisionRect) return;
|
|
4562
4587
|
const filteredContainers = [];
|
|
4563
4588
|
for (const entry of droppableContainers.getEnabled()) {
|
|
4564
|
-
if (!entry || _optionalChain([entry, 'optionalAccess',
|
|
4589
|
+
if (!entry || _optionalChain([entry, 'optionalAccess', _45 => _45.disabled])) return;
|
|
4565
4590
|
const rect = droppableRects.get(entry.id);
|
|
4566
4591
|
if (!rect) return;
|
|
4567
4592
|
const data = entry.data.current;
|
|
4568
4593
|
if (data) {
|
|
4569
4594
|
const { type, children } = data;
|
|
4570
|
-
if (type === "container" && _optionalChain([children, 'optionalAccess',
|
|
4571
|
-
if (_optionalChain([active, 'access',
|
|
4595
|
+
if (type === "container" && _optionalChain([children, 'optionalAccess', _46 => _46.length]) > 0) {
|
|
4596
|
+
if (_optionalChain([active, 'access', _47 => _47.data, 'access', _48 => _48.current, 'optionalAccess', _49 => _49.type]) !== "container") {
|
|
4572
4597
|
return;
|
|
4573
4598
|
}
|
|
4574
4599
|
}
|
|
@@ -4606,8 +4631,8 @@ var coordinateGetter = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (eve
|
|
|
4606
4631
|
const closestId = _core.getFirstCollision.call(void 0, collisions, "id");
|
|
4607
4632
|
if (closestId != null) {
|
|
4608
4633
|
const newDroppable = droppableContainers.get(closestId);
|
|
4609
|
-
const newNode = _optionalChain([newDroppable, 'optionalAccess',
|
|
4610
|
-
const newRect = _optionalChain([newDroppable, 'optionalAccess',
|
|
4634
|
+
const newNode = _optionalChain([newDroppable, 'optionalAccess', _50 => _50.node, 'access', _51 => _51.current]);
|
|
4635
|
+
const newRect = _optionalChain([newDroppable, 'optionalAccess', _52 => _52.rect, 'access', _53 => _53.current]);
|
|
4611
4636
|
if (newNode && newRect) {
|
|
4612
4637
|
if (newDroppable.id === "placeholder") {
|
|
4613
4638
|
return {
|
|
@@ -4615,7 +4640,7 @@ var coordinateGetter = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (eve
|
|
|
4615
4640
|
y: newRect.top + (newRect.height - collisionRect.height) / 2
|
|
4616
4641
|
};
|
|
4617
4642
|
}
|
|
4618
|
-
if (_optionalChain([newDroppable, 'access',
|
|
4643
|
+
if (_optionalChain([newDroppable, 'access', _54 => _54.data, 'access', _55 => _55.current, 'optionalAccess', _56 => _56.type]) === "container") {
|
|
4619
4644
|
return {
|
|
4620
4645
|
x: newRect.left + 20,
|
|
4621
4646
|
y: newRect.top + 74
|
|
@@ -4719,7 +4744,7 @@ function KanbanRoot(props) {
|
|
|
4719
4744
|
)
|
|
4720
4745
|
});
|
|
4721
4746
|
if (closestItem.length > 0) {
|
|
4722
|
-
overId = _nullishCoalesce(_optionalChain([closestItem, 'access',
|
|
4747
|
+
overId = _nullishCoalesce(_optionalChain([closestItem, 'access', _57 => _57[0], 'optionalAccess', _58 => _58.id]), () => ( overId));
|
|
4723
4748
|
}
|
|
4724
4749
|
}
|
|
4725
4750
|
}
|
|
@@ -4730,7 +4755,7 @@ function KanbanRoot(props) {
|
|
|
4730
4755
|
);
|
|
4731
4756
|
const onDragStart = React9.useCallback(
|
|
4732
4757
|
(event) => {
|
|
4733
|
-
_optionalChain([kanbanProps, 'access',
|
|
4758
|
+
_optionalChain([kanbanProps, 'access', _59 => _59.onDragStart, 'optionalCall', _60 => _60(event)]);
|
|
4734
4759
|
if (event.activatorEvent.defaultPrevented) return;
|
|
4735
4760
|
setActiveId(event.active.id);
|
|
4736
4761
|
},
|
|
@@ -4738,7 +4763,7 @@ function KanbanRoot(props) {
|
|
|
4738
4763
|
);
|
|
4739
4764
|
const onDragOver = React9.useCallback(
|
|
4740
4765
|
(event) => {
|
|
4741
|
-
_optionalChain([kanbanProps, 'access',
|
|
4766
|
+
_optionalChain([kanbanProps, 'access', _61 => _61.onDragOver, 'optionalCall', _62 => _62(event)]);
|
|
4742
4767
|
if (event.activatorEvent.defaultPrevented) return;
|
|
4743
4768
|
const { active, over } = event;
|
|
4744
4769
|
if (!over) return;
|
|
@@ -4753,7 +4778,7 @@ function KanbanRoot(props) {
|
|
|
4753
4778
|
if (activeIndex !== overIndex) {
|
|
4754
4779
|
const newColumns = { ...value };
|
|
4755
4780
|
newColumns[activeColumn] = _sortable.arrayMove.call(void 0, items, activeIndex, overIndex);
|
|
4756
|
-
_optionalChain([onValueChange, 'optionalCall',
|
|
4781
|
+
_optionalChain([onValueChange, 'optionalCall', _63 => _63(newColumns)]);
|
|
4757
4782
|
}
|
|
4758
4783
|
} else {
|
|
4759
4784
|
const activeItems = value[activeColumn];
|
|
@@ -4768,7 +4793,7 @@ function KanbanRoot(props) {
|
|
|
4768
4793
|
[activeColumn]: activeItems.filter((item) => getItemValue(item) !== active.id),
|
|
4769
4794
|
[overColumn]: [...overItems, activeItem]
|
|
4770
4795
|
};
|
|
4771
|
-
_optionalChain([onValueChange, 'optionalCall',
|
|
4796
|
+
_optionalChain([onValueChange, 'optionalCall', _64 => _64(updatedItems)]);
|
|
4772
4797
|
hasMovedRef.current = true;
|
|
4773
4798
|
}
|
|
4774
4799
|
},
|
|
@@ -4776,7 +4801,7 @@ function KanbanRoot(props) {
|
|
|
4776
4801
|
);
|
|
4777
4802
|
const onDragEnd = React9.useCallback(
|
|
4778
4803
|
(event) => {
|
|
4779
|
-
_optionalChain([kanbanProps, 'access',
|
|
4804
|
+
_optionalChain([kanbanProps, 'access', _65 => _65.onDragEnd, 'optionalCall', _66 => _66(event)]);
|
|
4780
4805
|
if (event.activatorEvent.defaultPrevented) return;
|
|
4781
4806
|
const { active, over } = event;
|
|
4782
4807
|
if (!over) {
|
|
@@ -4799,7 +4824,7 @@ function KanbanRoot(props) {
|
|
|
4799
4824
|
if (onMove) {
|
|
4800
4825
|
onMove({ ...event, activeIndex, overIndex });
|
|
4801
4826
|
} else {
|
|
4802
|
-
_optionalChain([onValueChange, 'optionalCall',
|
|
4827
|
+
_optionalChain([onValueChange, 'optionalCall', _67 => _67(newColumns)]);
|
|
4803
4828
|
}
|
|
4804
4829
|
}
|
|
4805
4830
|
} else {
|
|
@@ -4827,7 +4852,7 @@ function KanbanRoot(props) {
|
|
|
4827
4852
|
overIndex
|
|
4828
4853
|
});
|
|
4829
4854
|
} else {
|
|
4830
|
-
_optionalChain([onValueChange, 'optionalCall',
|
|
4855
|
+
_optionalChain([onValueChange, 'optionalCall', _68 => _68(newColumns)]);
|
|
4831
4856
|
}
|
|
4832
4857
|
}
|
|
4833
4858
|
}
|
|
@@ -4839,7 +4864,7 @@ function KanbanRoot(props) {
|
|
|
4839
4864
|
);
|
|
4840
4865
|
const onDragCancel = React9.useCallback(
|
|
4841
4866
|
(event) => {
|
|
4842
|
-
_optionalChain([kanbanProps, 'access',
|
|
4867
|
+
_optionalChain([kanbanProps, 'access', _69 => _69.onDragCancel, 'optionalCall', _70 => _70(event)]);
|
|
4843
4868
|
if (event.activatorEvent.defaultPrevented) return;
|
|
4844
4869
|
setActiveId(null);
|
|
4845
4870
|
hasMovedRef.current = false;
|
|
@@ -4858,7 +4883,7 @@ function KanbanRoot(props) {
|
|
|
4858
4883
|
})();
|
|
4859
4884
|
const total = isColumn ? Object.keys(value).length : (() => {
|
|
4860
4885
|
const column = getColumn(active.id);
|
|
4861
|
-
return column ? _nullishCoalesce(_optionalChain([value, 'access',
|
|
4886
|
+
return column ? _nullishCoalesce(_optionalChain([value, 'access', _71 => _71[column], 'optionalAccess', _72 => _72.length]), () => ( 0)) : 0;
|
|
4862
4887
|
})();
|
|
4863
4888
|
return `Picked up ${itemType} at position ${position} of ${total}`;
|
|
4864
4889
|
},
|
|
@@ -4873,7 +4898,7 @@ function KanbanRoot(props) {
|
|
|
4873
4898
|
})();
|
|
4874
4899
|
const total = isColumn ? Object.keys(value).length : (() => {
|
|
4875
4900
|
const column = getColumn(over.id);
|
|
4876
|
-
return column ? _nullishCoalesce(_optionalChain([value, 'access',
|
|
4901
|
+
return column ? _nullishCoalesce(_optionalChain([value, 'access', _73 => _73[column], 'optionalAccess', _74 => _74.length]), () => ( 0)) : 0;
|
|
4877
4902
|
})();
|
|
4878
4903
|
const overColumn = getColumn(over.id);
|
|
4879
4904
|
const activeColumn = getColumn(active.id);
|
|
@@ -4896,7 +4921,7 @@ function KanbanRoot(props) {
|
|
|
4896
4921
|
})();
|
|
4897
4922
|
const total = isColumn ? Object.keys(value).length : (() => {
|
|
4898
4923
|
const column = getColumn(over.id);
|
|
4899
|
-
return column ? _nullishCoalesce(_optionalChain([value, 'access',
|
|
4924
|
+
return column ? _nullishCoalesce(_optionalChain([value, 'access', _75 => _75[column], 'optionalAccess', _76 => _76.length]), () => ( 0)) : 0;
|
|
4900
4925
|
})();
|
|
4901
4926
|
const overColumn = getColumn(over.id);
|
|
4902
4927
|
const activeColumn = getColumn(active.id);
|
|
@@ -5242,7 +5267,7 @@ function KanbanOverlay(props) {
|
|
|
5242
5267
|
const context = useKanbanContext(OVERLAY_NAME);
|
|
5243
5268
|
const [mounted, setMounted] = React9.useState(false);
|
|
5244
5269
|
React9.useLayoutEffect(() => setMounted(true), []);
|
|
5245
|
-
const container = _nullishCoalesce(containerProp, () => ( (mounted ? _optionalChain([globalThis, 'access',
|
|
5270
|
+
const container = _nullishCoalesce(containerProp, () => ( (mounted ? _optionalChain([globalThis, 'access', _77 => _77.document, 'optionalAccess', _78 => _78.body]) : null)));
|
|
5246
5271
|
if (!container) return null;
|
|
5247
5272
|
const variant = context.activeId && context.activeId in context.items ? "column" : "item";
|
|
5248
5273
|
return ReactDOM.createPortal(
|
|
@@ -5391,7 +5416,7 @@ var MultiSelect = React11.forwardRef(
|
|
|
5391
5416
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-wrap items-center", children: [
|
|
5392
5417
|
selectedValues.slice(0, maxCount).map((value2) => {
|
|
5393
5418
|
const option = options.find((o) => o.value === value2);
|
|
5394
|
-
const IconComponent = _optionalChain([option, 'optionalAccess',
|
|
5419
|
+
const IconComponent = _optionalChain([option, 'optionalAccess', _79 => _79.icon]);
|
|
5395
5420
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
5396
5421
|
Badge,
|
|
5397
5422
|
{
|
|
@@ -5399,7 +5424,7 @@ var MultiSelect = React11.forwardRef(
|
|
|
5399
5424
|
style: { animationDuration: `${animation}s` },
|
|
5400
5425
|
children: [
|
|
5401
5426
|
IconComponent && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, IconComponent, { className: "mr-2 h-4 w-4" }),
|
|
5402
|
-
_nullishCoalesce(_optionalChain([option, 'optionalAccess',
|
|
5427
|
+
_nullishCoalesce(_optionalChain([option, 'optionalAccess', _80 => _80.selectedLabel]), () => ( _optionalChain([option, 'optionalAccess', _81 => _81.label]))),
|
|
5403
5428
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
5404
5429
|
_lucidereact.XCircle,
|
|
5405
5430
|
{
|
|
@@ -5696,7 +5721,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5696
5721
|
() => ({
|
|
5697
5722
|
selectedValue: [...selected],
|
|
5698
5723
|
input: inputRef.current,
|
|
5699
|
-
focus: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => _optionalChain([inputRef, 'optionalAccess',
|
|
5724
|
+
focus: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => _optionalChain([inputRef, 'optionalAccess', _82 => _82.current, 'optionalAccess', _83 => _83.focus, 'call', _84 => _84()]), "focus"),
|
|
5700
5725
|
reset: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => setSelected([]), "reset")
|
|
5701
5726
|
}),
|
|
5702
5727
|
[selected]
|
|
@@ -5711,7 +5736,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5711
5736
|
(option) => {
|
|
5712
5737
|
const newOptions = selected.filter((s) => s.value !== option.value);
|
|
5713
5738
|
setSelected(newOptions);
|
|
5714
|
-
_optionalChain([onChange, 'optionalCall',
|
|
5739
|
+
_optionalChain([onChange, 'optionalCall', _85 => _85(newOptions)]);
|
|
5715
5740
|
},
|
|
5716
5741
|
[onChange, selected]
|
|
5717
5742
|
);
|
|
@@ -5763,7 +5788,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5763
5788
|
}, [arrayDefaultOptions, arrayOptions, groupBy, onSearch, options]);
|
|
5764
5789
|
_react.useEffect.call(void 0, () => {
|
|
5765
5790
|
const doSearchSync = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
|
|
5766
|
-
const res = _optionalChain([onSearchSync, 'optionalCall',
|
|
5791
|
+
const res = _optionalChain([onSearchSync, 'optionalCall', _86 => _86(debouncedSearchTerm)]);
|
|
5767
5792
|
setOptions(transToGroupOption(res || [], groupBy));
|
|
5768
5793
|
}, "doSearchSync");
|
|
5769
5794
|
const exec = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
|
|
@@ -5808,7 +5833,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5808
5833
|
_react.useEffect.call(void 0, () => {
|
|
5809
5834
|
const doSearch = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
|
|
5810
5835
|
setIsLoading(true);
|
|
5811
|
-
const res = await _optionalChain([onSearch, 'optionalCall',
|
|
5836
|
+
const res = await _optionalChain([onSearch, 'optionalCall', _87 => _87(debouncedSearchTerm)]);
|
|
5812
5837
|
setOptions(transToGroupOption(res || [], groupBy));
|
|
5813
5838
|
setIsLoading(false);
|
|
5814
5839
|
}, "doSearch");
|
|
@@ -5839,13 +5864,13 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5839
5864
|
},
|
|
5840
5865
|
onSelect: (value2) => {
|
|
5841
5866
|
if (selected.length >= maxSelected) {
|
|
5842
|
-
_optionalChain([onMaxSelected, 'optionalCall',
|
|
5867
|
+
_optionalChain([onMaxSelected, 'optionalCall', _88 => _88(selected.length)]);
|
|
5843
5868
|
return;
|
|
5844
5869
|
}
|
|
5845
5870
|
setInputValue("");
|
|
5846
5871
|
const newOptions = [...selected, { value: value2, label: value2 }];
|
|
5847
5872
|
setSelected(newOptions);
|
|
5848
|
-
_optionalChain([onChange, 'optionalCall',
|
|
5873
|
+
_optionalChain([onChange, 'optionalCall', _89 => _89(newOptions)]);
|
|
5849
5874
|
},
|
|
5850
5875
|
children: `Create "${inputValue}"`
|
|
5851
5876
|
}
|
|
@@ -5867,7 +5892,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5867
5892
|
}, [creatable, emptyIndicator, onSearch, options]);
|
|
5868
5893
|
const selectables = React12.useMemo(() => removePickedOption(options, selected), [options, selected]);
|
|
5869
5894
|
const commandFilter = React12.useCallback(() => {
|
|
5870
|
-
if (_optionalChain([commandProps, 'optionalAccess',
|
|
5895
|
+
if (_optionalChain([commandProps, 'optionalAccess', _90 => _90.filter])) {
|
|
5871
5896
|
return commandProps.filter;
|
|
5872
5897
|
}
|
|
5873
5898
|
if (creatable) {
|
|
@@ -5876,7 +5901,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5876
5901
|
};
|
|
5877
5902
|
}
|
|
5878
5903
|
return void 0;
|
|
5879
|
-
}, [creatable, _optionalChain([commandProps, 'optionalAccess',
|
|
5904
|
+
}, [creatable, _optionalChain([commandProps, 'optionalAccess', _91 => _91.filter])]);
|
|
5880
5905
|
const displayedBadges = maxDisplayCount ? selected.slice(0, maxDisplayCount) : selected;
|
|
5881
5906
|
const hiddenCount = maxDisplayCount ? Math.max(0, selected.length - maxDisplayCount) : 0;
|
|
5882
5907
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
@@ -5886,10 +5911,10 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5886
5911
|
...commandProps,
|
|
5887
5912
|
onKeyDown: (e) => {
|
|
5888
5913
|
handleKeyDown(e);
|
|
5889
|
-
_optionalChain([commandProps, 'optionalAccess',
|
|
5914
|
+
_optionalChain([commandProps, 'optionalAccess', _92 => _92.onKeyDown, 'optionalCall', _93 => _93(e)]);
|
|
5890
5915
|
},
|
|
5891
|
-
className: _chunkPQBKPWBYjs.cn.call(void 0, "h-auto overflow-visible bg-transparent!", _optionalChain([commandProps, 'optionalAccess',
|
|
5892
|
-
shouldFilter: _optionalChain([commandProps, 'optionalAccess',
|
|
5916
|
+
className: _chunkPQBKPWBYjs.cn.call(void 0, "h-auto overflow-visible bg-transparent!", _optionalChain([commandProps, 'optionalAccess', _94 => _94.className])),
|
|
5917
|
+
shouldFilter: _optionalChain([commandProps, 'optionalAccess', _95 => _95.shouldFilter]) !== void 0 ? commandProps.shouldFilter : !onSearch,
|
|
5893
5918
|
filter: commandFilter(),
|
|
5894
5919
|
children: [
|
|
5895
5920
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
@@ -5905,7 +5930,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5905
5930
|
),
|
|
5906
5931
|
onClick: () => {
|
|
5907
5932
|
if (disabled) return;
|
|
5908
|
-
_optionalChain([inputRef, 'optionalAccess',
|
|
5933
|
+
_optionalChain([inputRef, 'optionalAccess', _96 => _96.current, 'optionalAccess', _97 => _97.focus, 'call', _98 => _98()]);
|
|
5909
5934
|
},
|
|
5910
5935
|
children: [
|
|
5911
5936
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "relative flex flex-1 flex-wrap gap-1", children: [
|
|
@@ -5959,17 +5984,17 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5959
5984
|
disabled,
|
|
5960
5985
|
onValueChange: (value2) => {
|
|
5961
5986
|
setInputValue(value2);
|
|
5962
|
-
_optionalChain([inputProps, 'optionalAccess',
|
|
5987
|
+
_optionalChain([inputProps, 'optionalAccess', _99 => _99.onValueChange, 'optionalCall', _100 => _100(value2)]);
|
|
5963
5988
|
},
|
|
5964
5989
|
onBlur: (event) => {
|
|
5965
5990
|
if (!onScrollbar) {
|
|
5966
5991
|
setOpen(false);
|
|
5967
5992
|
}
|
|
5968
|
-
_optionalChain([inputProps, 'optionalAccess',
|
|
5993
|
+
_optionalChain([inputProps, 'optionalAccess', _101 => _101.onBlur, 'optionalCall', _102 => _102(event)]);
|
|
5969
5994
|
},
|
|
5970
5995
|
onFocus: (event) => {
|
|
5971
5996
|
setOpen(true);
|
|
5972
|
-
_optionalChain([inputProps, 'optionalAccess',
|
|
5997
|
+
_optionalChain([inputProps, 'optionalAccess', _103 => _103.onFocus, 'optionalCall', _104 => _104(event)]);
|
|
5973
5998
|
},
|
|
5974
5999
|
placeholder: hidePlaceholderWhenSelected && selected.length !== 0 ? "" : placeholder,
|
|
5975
6000
|
className: _chunkPQBKPWBYjs.cn.call(void 0,
|
|
@@ -5978,7 +6003,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5978
6003
|
"w-full": hidePlaceholderWhenSelected,
|
|
5979
6004
|
"ml-1": selected.length !== 0
|
|
5980
6005
|
},
|
|
5981
|
-
_optionalChain([inputProps, 'optionalAccess',
|
|
6006
|
+
_optionalChain([inputProps, 'optionalAccess', _105 => _105.className])
|
|
5982
6007
|
)
|
|
5983
6008
|
}
|
|
5984
6009
|
)
|
|
@@ -5990,7 +6015,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
5990
6015
|
type: "button",
|
|
5991
6016
|
onClick: () => {
|
|
5992
6017
|
setSelected(selected.filter((s) => s.fixed));
|
|
5993
|
-
_optionalChain([onChange, 'optionalCall',
|
|
6018
|
+
_optionalChain([onChange, 'optionalCall', _106 => _106(selected.filter((s) => s.fixed))]);
|
|
5994
6019
|
},
|
|
5995
6020
|
className: _chunkPQBKPWBYjs.cn.call(void 0,
|
|
5996
6021
|
"size-5",
|
|
@@ -6015,7 +6040,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
6015
6040
|
setOnScrollbar(true);
|
|
6016
6041
|
},
|
|
6017
6042
|
onMouseUp: () => {
|
|
6018
|
-
_optionalChain([inputRef, 'optionalAccess',
|
|
6043
|
+
_optionalChain([inputRef, 'optionalAccess', _107 => _107.current, 'optionalAccess', _108 => _108.focus, 'call', _109 => _109()]);
|
|
6019
6044
|
},
|
|
6020
6045
|
children: isLoading ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: loadingIndicator }) : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
6021
6046
|
EmptyItem(),
|
|
@@ -6038,13 +6063,13 @@ var MultipleSelector = React12.forwardRef(
|
|
|
6038
6063
|
},
|
|
6039
6064
|
onSelect: () => {
|
|
6040
6065
|
if (selected.length >= maxSelected) {
|
|
6041
|
-
_optionalChain([onMaxSelected, 'optionalCall',
|
|
6066
|
+
_optionalChain([onMaxSelected, 'optionalCall', _110 => _110(selected.length)]);
|
|
6042
6067
|
return;
|
|
6043
6068
|
}
|
|
6044
6069
|
setInputValue("");
|
|
6045
6070
|
const newOptions = [...selected, option];
|
|
6046
6071
|
setSelected(newOptions);
|
|
6047
|
-
_optionalChain([onChange, 'optionalCall',
|
|
6072
|
+
_optionalChain([onChange, 'optionalCall', _111 => _111(newOptions)]);
|
|
6048
6073
|
},
|
|
6049
6074
|
className: _chunkPQBKPWBYjs.cn.call(void 0,
|
|
6050
6075
|
"cursor-pointer bg-transparent hover:bg-accent data-selected:bg-transparent data-selected:hover:bg-accent",
|
|
@@ -6079,7 +6104,7 @@ var MultipleSelector = React12.forwardRef(
|
|
|
6079
6104
|
setOnScrollbar(true);
|
|
6080
6105
|
},
|
|
6081
6106
|
onMouseUp: () => {
|
|
6082
|
-
_optionalChain([inputRef, 'optionalAccess',
|
|
6107
|
+
_optionalChain([inputRef, 'optionalAccess', _112 => _112.current, 'optionalAccess', _113 => _113.focus, 'call', _114 => _114()]);
|
|
6083
6108
|
},
|
|
6084
6109
|
children: isLoading ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: loadingIndicator }) : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
6085
6110
|
EmptyItem(),
|
|
@@ -6102,13 +6127,13 @@ var MultipleSelector = React12.forwardRef(
|
|
|
6102
6127
|
},
|
|
6103
6128
|
onSelect: () => {
|
|
6104
6129
|
if (selected.length >= maxSelected) {
|
|
6105
|
-
_optionalChain([onMaxSelected, 'optionalCall',
|
|
6130
|
+
_optionalChain([onMaxSelected, 'optionalCall', _115 => _115(selected.length)]);
|
|
6106
6131
|
return;
|
|
6107
6132
|
}
|
|
6108
6133
|
setInputValue("");
|
|
6109
6134
|
const newOptions = [...selected, option];
|
|
6110
6135
|
setSelected(newOptions);
|
|
6111
|
-
_optionalChain([onChange, 'optionalCall',
|
|
6136
|
+
_optionalChain([onChange, 'optionalCall', _116 => _116(newOptions)]);
|
|
6112
6137
|
},
|
|
6113
6138
|
className: _chunkPQBKPWBYjs.cn.call(void 0,
|
|
6114
6139
|
"cursor-pointer bg-transparent hover:bg-accent data-selected:bg-transparent data-selected:hover:bg-accent",
|
|
@@ -6328,19 +6353,19 @@ function useDataListRetriever(params) {
|
|
|
6328
6353
|
const fetchData = _react.useCallback.call(void 0,
|
|
6329
6354
|
async (fetchParams) => {
|
|
6330
6355
|
if (ready === false) return;
|
|
6331
|
-
if ((_optionalChain([fetchParams, 'optionalAccess',
|
|
6356
|
+
if ((_optionalChain([fetchParams, 'optionalAccess', _117 => _117.callNext]) || _optionalChain([fetchParams, 'optionalAccess', _118 => _118.callPrevious])) && isPaginatingRef.current) {
|
|
6332
6357
|
return;
|
|
6333
6358
|
}
|
|
6334
|
-
if (isFetchingRef.current && !_optionalChain([fetchParams, 'optionalAccess',
|
|
6335
|
-
if (_optionalChain([fetchParams, 'optionalAccess',
|
|
6359
|
+
if (isFetchingRef.current && !_optionalChain([fetchParams, 'optionalAccess', _119 => _119.callNext]) && !_optionalChain([fetchParams, 'optionalAccess', _120 => _120.callPrevious])) return;
|
|
6360
|
+
if (_optionalChain([fetchParams, 'optionalAccess', _121 => _121.callNext]) || _optionalChain([fetchParams, 'optionalAccess', _122 => _122.callPrevious])) {
|
|
6336
6361
|
isPaginatingRef.current = true;
|
|
6337
6362
|
}
|
|
6338
6363
|
const thisRequestId = ++requestIdRef.current;
|
|
6339
6364
|
isFetchingRef.current = true;
|
|
6340
|
-
if (stableParams.requiresSearch === true && _optionalChain([fetchParams, 'optionalAccess',
|
|
6365
|
+
if (stableParams.requiresSearch === true && _optionalChain([fetchParams, 'optionalAccess', _123 => _123.isRefine]) !== true && _optionalChain([fetchParams, 'optionalAccess', _124 => _124.isRefresh]) !== true) {
|
|
6341
6366
|
return;
|
|
6342
6367
|
}
|
|
6343
|
-
if (!nextPage && !previousPage && isLoaded && _optionalChain([fetchParams, 'optionalAccess',
|
|
6368
|
+
if (!nextPage && !previousPage && isLoaded && _optionalChain([fetchParams, 'optionalAccess', _125 => _125.callNext]) !== true && _optionalChain([fetchParams, 'optionalAccess', _126 => _126.callPrevious]) !== true && params.search === searchTermRef.current) {
|
|
6344
6369
|
return;
|
|
6345
6370
|
}
|
|
6346
6371
|
const currentSearchTerm = searchTermRef.current;
|
|
@@ -6351,7 +6376,7 @@ function useDataListRetriever(params) {
|
|
|
6351
6376
|
const previousRef = { previous: void 0 };
|
|
6352
6377
|
const selfRef = { self: void 0 };
|
|
6353
6378
|
const totalRef = { total: void 0 };
|
|
6354
|
-
if (nextPage && _optionalChain([fetchParams, 'optionalAccess',
|
|
6379
|
+
if (nextPage && _optionalChain([fetchParams, 'optionalAccess', _127 => _127.callNext]) && _optionalChain([fetchParams, 'optionalAccess', _128 => _128.isRefine]) !== true) {
|
|
6355
6380
|
const ServiceClass = stableParams.service;
|
|
6356
6381
|
response = await ServiceClass.next({
|
|
6357
6382
|
type: stableParams.type,
|
|
@@ -6361,7 +6386,7 @@ function useDataListRetriever(params) {
|
|
|
6361
6386
|
self: selfRef,
|
|
6362
6387
|
total: totalRef
|
|
6363
6388
|
});
|
|
6364
|
-
} else if (previousPage && _optionalChain([fetchParams, 'optionalAccess',
|
|
6389
|
+
} else if (previousPage && _optionalChain([fetchParams, 'optionalAccess', _129 => _129.callPrevious]) && _optionalChain([fetchParams, 'optionalAccess', _130 => _130.isRefine]) !== true) {
|
|
6365
6390
|
const ServiceClass = stableParams.service;
|
|
6366
6391
|
response = await ServiceClass.previous({
|
|
6367
6392
|
type: stableParams.type,
|
|
@@ -6384,8 +6409,8 @@ function useDataListRetriever(params) {
|
|
|
6384
6409
|
retrieverParams.total = totalRef;
|
|
6385
6410
|
response = await stableParams.retriever(retrieverParams);
|
|
6386
6411
|
}
|
|
6387
|
-
if (thisRequestId === requestIdRef.current && !_optionalChain([abortControllerRef, 'access',
|
|
6388
|
-
if (_optionalChain([fetchParams, 'optionalAccess',
|
|
6412
|
+
if (thisRequestId === requestIdRef.current && !_optionalChain([abortControllerRef, 'access', _131 => _131.current, 'optionalAccess', _132 => _132.signal, 'access', _133 => _133.aborted])) {
|
|
6413
|
+
if (_optionalChain([fetchParams, 'optionalAccess', _134 => _134.isRefresh]) === true) {
|
|
6389
6414
|
setData(response);
|
|
6390
6415
|
} else {
|
|
6391
6416
|
setData((prevData) => [...prevData ? prevData : [], ...response]);
|
|
@@ -6590,12 +6615,12 @@ var SUBTITLE_PX_PER_CHAR_11 = 6;
|
|
|
6590
6615
|
var LABEL_PADDING_PX = 16;
|
|
6591
6616
|
function estimateLabelWidth(node) {
|
|
6592
6617
|
if (node.subtitle) {
|
|
6593
|
-
const titleWidth = (_nullishCoalesce(_optionalChain([node, 'access',
|
|
6618
|
+
const titleWidth = (_nullishCoalesce(_optionalChain([node, 'access', _135 => _135.name, 'optionalAccess', _136 => _136.length]), () => ( 0))) * TITLE_PX_PER_CHAR_16;
|
|
6594
6619
|
const subtitleWidth = node.subtitle.length * SUBTITLE_PX_PER_CHAR_11;
|
|
6595
6620
|
return Math.max(titleWidth, subtitleWidth) + LABEL_PADDING_PX;
|
|
6596
6621
|
}
|
|
6597
6622
|
const perChar = node.bold ? NAME_PX_PER_CHAR_16_BOLD : NAME_PX_PER_CHAR_12;
|
|
6598
|
-
return (_nullishCoalesce(_optionalChain([node, 'access',
|
|
6623
|
+
return (_nullishCoalesce(_optionalChain([node, 'access', _137 => _137.name, 'optionalAccess', _138 => _138.length]), () => ( 0))) * perChar + LABEL_PADDING_PX;
|
|
6599
6624
|
}
|
|
6600
6625
|
_chunk7QVYU63Ejs.__name.call(void 0, estimateLabelWidth, "estimateLabelWidth");
|
|
6601
6626
|
function linkEndpointId(end) {
|
|
@@ -6708,12 +6733,12 @@ var SUBTITLE_PX_PER_CHAR_112 = 6;
|
|
|
6708
6733
|
var LABEL_PADDING_PX2 = 16;
|
|
6709
6734
|
function estimateLabelWidth2(node) {
|
|
6710
6735
|
if (node.subtitle) {
|
|
6711
|
-
const titleWidth = (_nullishCoalesce(_optionalChain([node, 'access',
|
|
6736
|
+
const titleWidth = (_nullishCoalesce(_optionalChain([node, 'access', _139 => _139.name, 'optionalAccess', _140 => _140.length]), () => ( 0))) * TITLE_PX_PER_CHAR_162;
|
|
6712
6737
|
const subtitleWidth = node.subtitle.length * SUBTITLE_PX_PER_CHAR_112;
|
|
6713
6738
|
return Math.max(titleWidth, subtitleWidth) + LABEL_PADDING_PX2;
|
|
6714
6739
|
}
|
|
6715
6740
|
const perChar = node.bold ? NAME_PX_PER_CHAR_16_BOLD2 : NAME_PX_PER_CHAR_122;
|
|
6716
|
-
return (_nullishCoalesce(_optionalChain([node, 'access',
|
|
6741
|
+
return (_nullishCoalesce(_optionalChain([node, 'access', _141 => _141.name, 'optionalAccess', _142 => _142.length]), () => ( 0))) * perChar + LABEL_PADDING_PX2;
|
|
6717
6742
|
}
|
|
6718
6743
|
_chunk7QVYU63Ejs.__name.call(void 0, estimateLabelWidth2, "estimateLabelWidth");
|
|
6719
6744
|
function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, loadingNodeIds, containerKey) {
|
|
@@ -6780,7 +6805,7 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, lo
|
|
|
6780
6805
|
});
|
|
6781
6806
|
const typeColorMap = /* @__PURE__ */ new Map();
|
|
6782
6807
|
Array.from(groupTypes).forEach((type, index) => {
|
|
6783
|
-
if (type === _optionalChain([nodes, 'access',
|
|
6808
|
+
if (type === _optionalChain([nodes, 'access', _143 => _143[0], 'optionalAccess', _144 => _144.instanceType])) {
|
|
6784
6809
|
typeColorMap.set(type, accentColor);
|
|
6785
6810
|
} else if (type === "documents" || type === "articles" || type === "hyperlinks") {
|
|
6786
6811
|
typeColorMap.set(type, contentColor);
|
|
@@ -6826,14 +6851,14 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, lo
|
|
|
6826
6851
|
});
|
|
6827
6852
|
const svg = d3.select(svgRef.current);
|
|
6828
6853
|
svg.selectAll("*").remove();
|
|
6829
|
-
const container = _optionalChain([svgRef, 'access',
|
|
6854
|
+
const container = _optionalChain([svgRef, 'access', _145 => _145.current, 'optionalAccess', _146 => _146.parentElement]);
|
|
6830
6855
|
if (!container) return;
|
|
6831
6856
|
const width = container.clientWidth;
|
|
6832
6857
|
const height = container.clientHeight;
|
|
6833
6858
|
svg.attr("width", width).attr("height", height).attr("viewBox", `0 0 ${width} ${height}`);
|
|
6834
6859
|
const graphGroup = svg.append("g").attr("class", "graph-content");
|
|
6835
6860
|
const nodeRadius = 40;
|
|
6836
|
-
const directed = _optionalChain([options, 'optionalAccess',
|
|
6861
|
+
const directed = _optionalChain([options, 'optionalAccess', _147 => _147.directed]) === true;
|
|
6837
6862
|
if (directed) {
|
|
6838
6863
|
const defs = svg.append("defs");
|
|
6839
6864
|
defs.append("marker").attr("id", "narr8-arrow").attr("viewBox", "-10 -10 20 20").attr("markerWidth", 14).attr("markerHeight", 14).attr("markerUnits", "userSpaceOnUse").attr("orient", "auto").attr("refX", 0).attr("refY", 0).append("path").attr("d", "M-10,-10 L0,0 L-10,10 z").attr("fill", "#999");
|
|
@@ -6845,10 +6870,10 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, lo
|
|
|
6845
6870
|
});
|
|
6846
6871
|
zoomBehaviorRef.current = zoom2;
|
|
6847
6872
|
svg.call(zoom2).on("wheel.zoom", null).on("dblclick.zoom", null);
|
|
6848
|
-
const layoutMode = _nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
6873
|
+
const layoutMode = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _148 => _148.layout]), () => ( "radial"));
|
|
6849
6874
|
let layeredPositionsApplied = false;
|
|
6850
6875
|
if (layoutMode === "layered") {
|
|
6851
|
-
const layeredOpts = _nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
6876
|
+
const layeredOpts = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _149 => _149.layered]), () => ( {}));
|
|
6852
6877
|
const useFit = layeredOpts.fitContainer === true && width > 0 && height > 0;
|
|
6853
6878
|
const positions = useFit ? fitLayeredLayoutToAspectRatio(visibleNodes, visibleLinks, {
|
|
6854
6879
|
rankdir: _nullishCoalesce(layeredOpts.rankdir, () => ( "LR")),
|
|
@@ -6931,7 +6956,7 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, lo
|
|
|
6931
6956
|
sourceNode.children.push(targetId);
|
|
6932
6957
|
}
|
|
6933
6958
|
});
|
|
6934
|
-
const rootChildren = _optionalChain([nodeHierarchy, 'access',
|
|
6959
|
+
const rootChildren = _optionalChain([nodeHierarchy, 'access', _150 => _150.get, 'call', _151 => _151(centralNodeId), 'optionalAccess', _152 => _152.children]) || [];
|
|
6935
6960
|
const childAngleStep = 2 * Math.PI / Math.max(rootChildren.length, 1);
|
|
6936
6961
|
rootChildren.forEach((childId, index) => {
|
|
6937
6962
|
const childNode = nodeHierarchy.get(childId);
|
|
@@ -7083,7 +7108,7 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, lo
|
|
|
7083
7108
|
if (d.instanceType === "root") return;
|
|
7084
7109
|
const currentNode = d3.select(this);
|
|
7085
7110
|
currentNode.raise();
|
|
7086
|
-
const currentZoom = _optionalChain([zoomRef, 'access',
|
|
7111
|
+
const currentZoom = _optionalChain([zoomRef, 'access', _153 => _153.current, 'optionalAccess', _154 => _154.k]) || 1;
|
|
7087
7112
|
const targetScreenFontSize = 20;
|
|
7088
7113
|
const baseFontSize = 12;
|
|
7089
7114
|
const textScale = targetScreenFontSize / (baseFontSize * currentZoom);
|
|
@@ -7158,19 +7183,19 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, options, lo
|
|
|
7158
7183
|
}
|
|
7159
7184
|
});
|
|
7160
7185
|
return () => {
|
|
7161
|
-
_optionalChain([simulation, 'optionalAccess',
|
|
7186
|
+
_optionalChain([simulation, 'optionalAccess', _155 => _155.stop, 'call', _156 => _156()]);
|
|
7162
7187
|
};
|
|
7163
7188
|
}, [
|
|
7164
7189
|
nodes,
|
|
7165
7190
|
links,
|
|
7166
7191
|
colorScale,
|
|
7167
7192
|
visibleNodeIds,
|
|
7168
|
-
_optionalChain([options, 'optionalAccess',
|
|
7169
|
-
_optionalChain([options, 'optionalAccess',
|
|
7170
|
-
_optionalChain([options, 'optionalAccess',
|
|
7171
|
-
_optionalChain([options, 'optionalAccess',
|
|
7172
|
-
_optionalChain([options, 'optionalAccess',
|
|
7173
|
-
_optionalChain([options, 'optionalAccess',
|
|
7193
|
+
_optionalChain([options, 'optionalAccess', _157 => _157.directed]),
|
|
7194
|
+
_optionalChain([options, 'optionalAccess', _158 => _158.layout]),
|
|
7195
|
+
_optionalChain([options, 'optionalAccess', _159 => _159.layered, 'optionalAccess', _160 => _160.rankdir]),
|
|
7196
|
+
_optionalChain([options, 'optionalAccess', _161 => _161.layered, 'optionalAccess', _162 => _162.nodesep]),
|
|
7197
|
+
_optionalChain([options, 'optionalAccess', _163 => _163.layered, 'optionalAccess', _164 => _164.ranksep]),
|
|
7198
|
+
_optionalChain([options, 'optionalAccess', _165 => _165.layered, 'optionalAccess', _166 => _166.fitContainer]),
|
|
7174
7199
|
loadingNodeIds,
|
|
7175
7200
|
onNodeClick
|
|
7176
7201
|
]);
|
|
@@ -7293,7 +7318,7 @@ function usePageTracker() {
|
|
|
7293
7318
|
if (typeof document !== "undefined") {
|
|
7294
7319
|
const titleParts = document.title.split("]");
|
|
7295
7320
|
if (titleParts[1]) {
|
|
7296
|
-
const cleanTitle = _optionalChain([titleParts, 'access',
|
|
7321
|
+
const cleanTitle = _optionalChain([titleParts, 'access', _167 => _167[1], 'access', _168 => _168.split, 'call', _169 => _169("|"), 'access', _170 => _170[0], 'optionalAccess', _171 => _171.trim, 'call', _172 => _172()]);
|
|
7297
7322
|
pageTitle = cleanTitle || foundModule.name;
|
|
7298
7323
|
}
|
|
7299
7324
|
}
|
|
@@ -7330,7 +7355,7 @@ function usePushNotifications() {
|
|
|
7330
7355
|
const register = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
|
|
7331
7356
|
if ("serviceWorker" in navigator && "PushManager" in window) {
|
|
7332
7357
|
try {
|
|
7333
|
-
const sessionKey = `push_registered_${_optionalChain([currentUser, 'optionalAccess',
|
|
7358
|
+
const sessionKey = `push_registered_${_optionalChain([currentUser, 'optionalAccess', _173 => _173.id])}`;
|
|
7334
7359
|
const lastRegisteredSubscription = sessionStorage.getItem(sessionKey);
|
|
7335
7360
|
const registration = await navigator.serviceWorker.register(`${_chunkJO5BLONKjs.getAppUrl.call(void 0, )}/sw.js`);
|
|
7336
7361
|
let permission = Notification.permission;
|
|
@@ -7387,7 +7412,7 @@ function useSocket({ token }) {
|
|
|
7387
7412
|
const socketRef = _react.useRef.call(void 0, null);
|
|
7388
7413
|
_react.useEffect.call(void 0, () => {
|
|
7389
7414
|
if (!token) return;
|
|
7390
|
-
const globalSocketKey = `__socket_${_optionalChain([process, 'access',
|
|
7415
|
+
const globalSocketKey = `__socket_${_optionalChain([process, 'access', _174 => _174.env, 'access', _175 => _175.NEXT_PUBLIC_API_URL, 'optionalAccess', _176 => _176.replace, 'call', _177 => _177(/[^a-zA-Z0-9]/g, "_")])}`;
|
|
7391
7416
|
if (typeof window !== "undefined") {
|
|
7392
7417
|
const _allSocketKeys = Object.keys(window).filter((key) => key.startsWith("__socket_"));
|
|
7393
7418
|
const existingSocket = window[globalSocketKey];
|
|
@@ -7443,14 +7468,14 @@ function useSocket({ token }) {
|
|
|
7443
7468
|
});
|
|
7444
7469
|
}, "handleMessage");
|
|
7445
7470
|
const handleNotification = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (data) => {
|
|
7446
|
-
const resource = _nullishCoalesce(_optionalChain([data, 'optionalAccess',
|
|
7447
|
-
if (!_optionalChain([resource, 'optionalAccess',
|
|
7471
|
+
const resource = _nullishCoalesce(_optionalChain([data, 'optionalAccess', _178 => _178.data]), () => ( _optionalChain([data, 'optionalAccess', _179 => _179.jsonApi])));
|
|
7472
|
+
if (!_optionalChain([resource, 'optionalAccess', _180 => _180.type])) {
|
|
7448
7473
|
console.warn("[useSocket] ignoring notification with unexpected payload shape", data);
|
|
7449
7474
|
return;
|
|
7450
7475
|
}
|
|
7451
7476
|
const notification = _chunkPQBKPWBYjs.rehydrate.call(void 0, _chunkPQBKPWBYjs.Modules.Notification, {
|
|
7452
7477
|
jsonApi: resource,
|
|
7453
|
-
included: _optionalChain([data, 'optionalAccess',
|
|
7478
|
+
included: _optionalChain([data, 'optionalAccess', _181 => _181.included]) || []
|
|
7454
7479
|
});
|
|
7455
7480
|
if (notification) {
|
|
7456
7481
|
setSocketNotifications((prev) => {
|
|
@@ -7588,23 +7613,23 @@ var CurrentUserProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (
|
|
|
7588
7613
|
);
|
|
7589
7614
|
const matchedModuleKey = moduleKeys.find((key) => {
|
|
7590
7615
|
const descriptor2 = Object.getOwnPropertyDescriptor(_chunkPQBKPWBYjs.Modules, key);
|
|
7591
|
-
if (!_optionalChain([descriptor2, 'optionalAccess',
|
|
7616
|
+
if (!_optionalChain([descriptor2, 'optionalAccess', _182 => _182.get])) return false;
|
|
7592
7617
|
const selectedModule = descriptor2.get.call(_chunkPQBKPWBYjs.Modules);
|
|
7593
|
-
return path.toLowerCase().startsWith(_optionalChain([selectedModule, 'access',
|
|
7618
|
+
return path.toLowerCase().startsWith(_optionalChain([selectedModule, 'access', _183 => _183.pageUrl, 'optionalAccess', _184 => _184.toLowerCase, 'call', _185 => _185()]));
|
|
7594
7619
|
});
|
|
7595
7620
|
if (!matchedModuleKey) return void 0;
|
|
7596
7621
|
const descriptor = Object.getOwnPropertyDescriptor(_chunkPQBKPWBYjs.Modules, matchedModuleKey);
|
|
7597
|
-
return _optionalChain([descriptor, 'optionalAccess',
|
|
7622
|
+
return _optionalChain([descriptor, 'optionalAccess', _186 => _186.get, 'optionalAccess', _187 => _187.call, 'call', _188 => _188(_chunkPQBKPWBYjs.Modules)]);
|
|
7598
7623
|
}, "matchUrlToModule");
|
|
7599
7624
|
const currentUser = dehydratedUser ? _chunkPQBKPWBYjs.rehydrate.call(void 0, _chunkPQBKPWBYjs.Modules.User, dehydratedUser) : null;
|
|
7600
|
-
const company = _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess',
|
|
7625
|
+
const company = _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _189 => _189.company]), () => ( null));
|
|
7601
7626
|
const setUser = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (user) => {
|
|
7602
7627
|
if (user) setDehydratedUser(user.dehydrate());
|
|
7603
7628
|
else setDehydratedUser(null);
|
|
7604
7629
|
}, "setUser");
|
|
7605
7630
|
const hasRole = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (roleId) => {
|
|
7606
7631
|
if (!currentUser) return false;
|
|
7607
|
-
return !!_optionalChain([currentUser, 'access',
|
|
7632
|
+
return !!_optionalChain([currentUser, 'access', _190 => _190.roles, 'optionalAccess', _191 => _191.some, 'call', _192 => _192((userRole) => userRole.id === roleId)]);
|
|
7608
7633
|
}, "hasRole");
|
|
7609
7634
|
const hasAccesToFeature = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (featureIdentifier) => {
|
|
7610
7635
|
if (hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator)) return true;
|
|
@@ -7644,12 +7669,12 @@ var CurrentUserProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (
|
|
|
7644
7669
|
try {
|
|
7645
7670
|
const fullUser = await _chunkPQBKPWBYjs.UserService.findFullUser();
|
|
7646
7671
|
if (fullUser) {
|
|
7647
|
-
if (!_optionalChain([options, 'optionalAccess',
|
|
7648
|
-
await _optionalChain([_chunkPQBKPWBYjs.getTokenHandler.call(void 0, ), 'optionalAccess',
|
|
7672
|
+
if (!_optionalChain([options, 'optionalAccess', _193 => _193.skipCookieUpdate])) {
|
|
7673
|
+
await _optionalChain([_chunkPQBKPWBYjs.getTokenHandler.call(void 0, ), 'optionalAccess', _194 => _194.updateToken, 'call', _195 => _195({
|
|
7649
7674
|
userId: fullUser.id,
|
|
7650
|
-
companyId: _optionalChain([fullUser, 'access',
|
|
7675
|
+
companyId: _optionalChain([fullUser, 'access', _196 => _196.company, 'optionalAccess', _197 => _197.id]),
|
|
7651
7676
|
roles: fullUser.roles.map((role) => role.id),
|
|
7652
|
-
features: _nullishCoalesce(_optionalChain([fullUser, 'access',
|
|
7677
|
+
features: _nullishCoalesce(_optionalChain([fullUser, 'access', _198 => _198.company, 'optionalAccess', _199 => _199.features, 'optionalAccess', _200 => _200.map, 'call', _201 => _201((feature) => feature.id)]), () => ( [])),
|
|
7653
7678
|
modules: fullUser.modules.map((module) => ({
|
|
7654
7679
|
id: module.id,
|
|
7655
7680
|
permissions: module.permissions
|
|
@@ -7671,11 +7696,11 @@ var CurrentUserProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (
|
|
|
7671
7696
|
refreshUserRef.current = refreshUser;
|
|
7672
7697
|
const isRefreshingRef = _react.useRef.call(void 0, false);
|
|
7673
7698
|
_react.useEffect.call(void 0, () => {
|
|
7674
|
-
if (!socket || !isConnected || !_optionalChain([currentUser, 'optionalAccess',
|
|
7699
|
+
if (!socket || !isConnected || !_optionalChain([currentUser, 'optionalAccess', _202 => _202.company, 'optionalAccess', _203 => _203.id])) {
|
|
7675
7700
|
return;
|
|
7676
7701
|
}
|
|
7677
7702
|
const handleCompanyUpdate = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (data) => {
|
|
7678
|
-
if (data.companyId === _optionalChain([currentUser, 'access',
|
|
7703
|
+
if (data.companyId === _optionalChain([currentUser, 'access', _204 => _204.company, 'optionalAccess', _205 => _205.id]) && !isRefreshingRef.current) {
|
|
7679
7704
|
isRefreshingRef.current = true;
|
|
7680
7705
|
refreshUserRef.current({ skipCookieUpdate: true }).finally(() => {
|
|
7681
7706
|
isRefreshingRef.current = false;
|
|
@@ -7688,7 +7713,7 @@ var CurrentUserProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (
|
|
|
7688
7713
|
socket.off("company:tokens_updated", handleCompanyUpdate);
|
|
7689
7714
|
socket.off("company:subscription_updated", handleCompanyUpdate);
|
|
7690
7715
|
};
|
|
7691
|
-
}, [socket, isConnected, _optionalChain([currentUser, 'optionalAccess',
|
|
7716
|
+
}, [socket, isConnected, _optionalChain([currentUser, 'optionalAccess', _206 => _206.company, 'optionalAccess', _207 => _207.id])]);
|
|
7692
7717
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
7693
7718
|
CurrentUserContext.Provider,
|
|
7694
7719
|
{
|
|
@@ -7759,7 +7784,7 @@ function AddUserToRoleInternal({ role, refresh }) {
|
|
|
7759
7784
|
const data = useDataListRetriever({
|
|
7760
7785
|
ready: !!company && show,
|
|
7761
7786
|
retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkPQBKPWBYjs.UserService.findAllUsers(params), "retriever"),
|
|
7762
|
-
retrieverParams: { companyId: _optionalChain([company, 'optionalAccess',
|
|
7787
|
+
retrieverParams: { companyId: _optionalChain([company, 'optionalAccess', _208 => _208.id]) },
|
|
7763
7788
|
module: _chunkPQBKPWBYjs.Modules.User
|
|
7764
7789
|
});
|
|
7765
7790
|
_react.useEffect.call(void 0, () => {
|
|
@@ -7827,10 +7852,10 @@ function UserAvatarEditor({ user, file, setFile, resetImage, setResetImage }) {
|
|
|
7827
7852
|
onValueChange: setFiles,
|
|
7828
7853
|
dropzoneOptions: dropzone2,
|
|
7829
7854
|
className: "h-40 w-40 rounded-full p-0",
|
|
7830
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FileInput, { className: "bg-muted text-muted-foreground flex h-full w-full flex-col items-center justify-center", children: !resetImage && (file || _optionalChain([user, 'optionalAccess',
|
|
7855
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FileInput, { className: "bg-muted text-muted-foreground flex h-full w-full flex-col items-center justify-center", children: !resetImage && (file || _optionalChain([user, 'optionalAccess', _209 => _209.avatar])) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
7831
7856
|
_image2.default,
|
|
7832
7857
|
{
|
|
7833
|
-
src: file ? URL.createObjectURL(file) : _optionalChain([user, 'optionalAccess',
|
|
7858
|
+
src: file ? URL.createObjectURL(file) : _optionalChain([user, 'optionalAccess', _210 => _210.avatar]) || "",
|
|
7834
7859
|
alt: t(`common.avatar`),
|
|
7835
7860
|
width: 200,
|
|
7836
7861
|
height: 200
|
|
@@ -7838,7 +7863,7 @@ function UserAvatarEditor({ user, file, setFile, resetImage, setResetImage }) {
|
|
|
7838
7863
|
) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.UploadIcon, { className: "my-4 h-8 w-8" }) })
|
|
7839
7864
|
}
|
|
7840
7865
|
),
|
|
7841
|
-
!resetImage && (file || _optionalChain([user, 'optionalAccess',
|
|
7866
|
+
!resetImage && (file || _optionalChain([user, 'optionalAccess', _211 => _211.avatar])) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
7842
7867
|
Button,
|
|
7843
7868
|
{
|
|
7844
7869
|
className: "",
|
|
@@ -7866,7 +7891,7 @@ function UserDeleterInternal({ user, onDeleted, companyId }) {
|
|
|
7866
7891
|
const router = _chunkJO5BLONKjs.useI18nRouter.call(void 0, );
|
|
7867
7892
|
const _t = _nextintl.useTranslations.call(void 0, );
|
|
7868
7893
|
let cId;
|
|
7869
|
-
if (_optionalChain([currentUser, 'optionalAccess',
|
|
7894
|
+
if (_optionalChain([currentUser, 'optionalAccess', _212 => _212.roles, 'access', _213 => _213.find, 'call', _214 => _214((role) => role.id === _chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator)]) && companyId) {
|
|
7870
7895
|
cId = companyId;
|
|
7871
7896
|
} else {
|
|
7872
7897
|
if (!company) return;
|
|
@@ -7929,18 +7954,18 @@ function UserEditorInternal({
|
|
|
7929
7954
|
}, [company]);
|
|
7930
7955
|
const handleDialogOpenChange = _react.useCallback.call(void 0,
|
|
7931
7956
|
(open) => {
|
|
7932
|
-
if (open && (company || _optionalChain([currentUser, 'optionalAccess',
|
|
7957
|
+
if (open && (company || _optionalChain([currentUser, 'optionalAccess', _215 => _215.roles, 'access', _216 => _216.find, 'call', _217 => _217((role) => role.id === _chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator)])) && roles.length === 0) {
|
|
7933
7958
|
async function fetchRoles() {
|
|
7934
7959
|
const allRoles = await _chunkPQBKPWBYjs.RoleService.findAllRoles({});
|
|
7935
7960
|
const availableRoles = allRoles.filter(
|
|
7936
|
-
(role) => role.id !== _chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator && (role.requiredFeature === void 0 || _optionalChain([company, 'optionalAccess',
|
|
7961
|
+
(role) => role.id !== _chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator && (role.requiredFeature === void 0 || _optionalChain([company, 'optionalAccess', _218 => _218.features, 'access', _219 => _219.some, 'call', _220 => _220((feature) => feature.id === _optionalChain([role, 'access', _221 => _221.requiredFeature, 'optionalAccess', _222 => _222.id]))]))
|
|
7937
7962
|
);
|
|
7938
7963
|
setRoles(availableRoles);
|
|
7939
7964
|
}
|
|
7940
7965
|
_chunk7QVYU63Ejs.__name.call(void 0, fetchRoles, "fetchRoles");
|
|
7941
7966
|
fetchRoles();
|
|
7942
7967
|
}
|
|
7943
|
-
_optionalChain([onDialogOpenChange, 'optionalCall',
|
|
7968
|
+
_optionalChain([onDialogOpenChange, 'optionalCall', _223 => _223(open)]);
|
|
7944
7969
|
},
|
|
7945
7970
|
[company, currentUser, roles.length, onDialogOpenChange]
|
|
7946
7971
|
);
|
|
@@ -7974,29 +7999,29 @@ function UserEditorInternal({
|
|
|
7974
7999
|
);
|
|
7975
8000
|
const getDefaultValues = _react.useCallback.call(void 0, () => {
|
|
7976
8001
|
return {
|
|
7977
|
-
id: _optionalChain([user, 'optionalAccess',
|
|
7978
|
-
name: _optionalChain([user, 'optionalAccess',
|
|
7979
|
-
title: _optionalChain([user, 'optionalAccess',
|
|
7980
|
-
bio: _optionalChain([user, 'optionalAccess',
|
|
7981
|
-
email: _optionalChain([user, 'optionalAccess',
|
|
7982
|
-
phone: _optionalChain([user, 'optionalAccess',
|
|
8002
|
+
id: _optionalChain([user, 'optionalAccess', _224 => _224.id]) || _uuid.v4.call(void 0, ),
|
|
8003
|
+
name: _optionalChain([user, 'optionalAccess', _225 => _225.name]) || "",
|
|
8004
|
+
title: _optionalChain([user, 'optionalAccess', _226 => _226.title]) || "",
|
|
8005
|
+
bio: _optionalChain([user, 'optionalAccess', _227 => _227.bio]) || "",
|
|
8006
|
+
email: _optionalChain([user, 'optionalAccess', _228 => _228.email]) || "",
|
|
8007
|
+
phone: _optionalChain([user, 'optionalAccess', _229 => _229.phone]) || "",
|
|
7983
8008
|
password: "",
|
|
7984
|
-
roleIds: _optionalChain([user, 'optionalAccess',
|
|
8009
|
+
roleIds: _optionalChain([user, 'optionalAccess', _230 => _230.roles, 'access', _231 => _231.map, 'call', _232 => _232((role) => role.id)]) || [],
|
|
7985
8010
|
sendInvitationEmail: false,
|
|
7986
|
-
avatar: _optionalChain([user, 'optionalAccess',
|
|
8011
|
+
avatar: _optionalChain([user, 'optionalAccess', _233 => _233.avatarUrl]) || ""
|
|
7987
8012
|
};
|
|
7988
8013
|
}, [user]);
|
|
7989
8014
|
const form = _reacthookform.useForm.call(void 0, {
|
|
7990
8015
|
resolver: _zod.zodResolver.call(void 0, formSchema),
|
|
7991
8016
|
defaultValues: getDefaultValues()
|
|
7992
8017
|
});
|
|
7993
|
-
const canChangeRoles = !(_optionalChain([currentUser, 'optionalAccess',
|
|
8018
|
+
const canChangeRoles = !(_optionalChain([currentUser, 'optionalAccess', _234 => _234.id]) === _optionalChain([user, 'optionalAccess', _235 => _235.id]) && hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator)) && (hasPermissionToModule({ module: _chunkPQBKPWBYjs.Modules.User, action: "update" /* Update */ }) || hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator));
|
|
7994
8019
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
7995
8020
|
EditorSheet,
|
|
7996
8021
|
{
|
|
7997
8022
|
form,
|
|
7998
8023
|
entityType: t(`entities.users`, { count: 1 }),
|
|
7999
|
-
entityName: _optionalChain([user, 'optionalAccess',
|
|
8024
|
+
entityName: _optionalChain([user, 'optionalAccess', _236 => _236.name]),
|
|
8000
8025
|
isEdit: !!user,
|
|
8001
8026
|
module: _chunkPQBKPWBYjs.Modules.User,
|
|
8002
8027
|
propagateChanges,
|
|
@@ -8048,7 +8073,7 @@ function UserEditorInternal({
|
|
|
8048
8073
|
adminCreated
|
|
8049
8074
|
};
|
|
8050
8075
|
const updatedUser = user ? await _chunkPQBKPWBYjs.UserService.update(payload) : await _chunkPQBKPWBYjs.UserService.create(payload);
|
|
8051
|
-
if (_optionalChain([currentUser, 'optionalAccess',
|
|
8076
|
+
if (_optionalChain([currentUser, 'optionalAccess', _237 => _237.id]) === updatedUser.id) setUser(updatedUser);
|
|
8052
8077
|
return updatedUser;
|
|
8053
8078
|
},
|
|
8054
8079
|
onRevalidate,
|
|
@@ -8296,7 +8321,7 @@ function EntityMultiSelector({
|
|
|
8296
8321
|
if (open) {
|
|
8297
8322
|
setSearchTerm("");
|
|
8298
8323
|
requestAnimationFrame(() => {
|
|
8299
|
-
_optionalChain([searchInputRef, 'access',
|
|
8324
|
+
_optionalChain([searchInputRef, 'access', _238 => _238.current, 'optionalAccess', _239 => _239.focus, 'call', _240 => _240()]);
|
|
8300
8325
|
});
|
|
8301
8326
|
}
|
|
8302
8327
|
}, [open]);
|
|
@@ -8313,7 +8338,7 @@ function EntityMultiSelector({
|
|
|
8313
8338
|
form.setValue(id, next, { shouldDirty: true, shouldTouch: true });
|
|
8314
8339
|
const cb = onChangeRef.current;
|
|
8315
8340
|
if (cb) {
|
|
8316
|
-
const fullData = next.map((v) => _optionalChain([options, 'access',
|
|
8341
|
+
const fullData = next.map((v) => _optionalChain([options, 'access', _241 => _241.find, 'call', _242 => _242((opt) => opt.id === v.id), 'optionalAccess', _243 => _243.entityData])).filter(Boolean);
|
|
8317
8342
|
cb(fullData);
|
|
8318
8343
|
}
|
|
8319
8344
|
},
|
|
@@ -8326,7 +8351,7 @@ function EntityMultiSelector({
|
|
|
8326
8351
|
form.setValue(id, next, { shouldDirty: true, shouldTouch: true });
|
|
8327
8352
|
const cb = onChangeRef.current;
|
|
8328
8353
|
if (cb) {
|
|
8329
|
-
const fullData = next.map((v) => _optionalChain([options, 'access',
|
|
8354
|
+
const fullData = next.map((v) => _optionalChain([options, 'access', _244 => _244.find, 'call', _245 => _245((opt) => opt.id === v.id), 'optionalAccess', _246 => _246.entityData])).filter(Boolean);
|
|
8330
8355
|
cb(fullData);
|
|
8331
8356
|
}
|
|
8332
8357
|
},
|
|
@@ -8464,11 +8489,11 @@ function UserMultiSelect({
|
|
|
8464
8489
|
emptyText: t("ui.search.no_results", { type: t("entities.users", { count: 2 }) }),
|
|
8465
8490
|
isRequired,
|
|
8466
8491
|
retriever: (params) => _chunkPQBKPWBYjs.UserService.findAllUsers(params),
|
|
8467
|
-
retrieverParams: { companyId: _optionalChain([company, 'optionalAccess',
|
|
8492
|
+
retrieverParams: { companyId: _optionalChain([company, 'optionalAccess', _247 => _247.id]) },
|
|
8468
8493
|
module: _chunkPQBKPWBYjs.Modules.User,
|
|
8469
8494
|
getLabel: (user) => user.name,
|
|
8470
8495
|
toFormValue: (user) => ({ id: user.id, name: user.name, avatar: user.avatar }),
|
|
8471
|
-
excludeId: _optionalChain([currentUser, 'optionalAccess',
|
|
8496
|
+
excludeId: _optionalChain([currentUser, 'optionalAccess', _248 => _248.id]),
|
|
8472
8497
|
onChange,
|
|
8473
8498
|
renderOption: (user) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "flex items-center gap-2", children: [
|
|
8474
8499
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, UserAvatarIcon, { url: user.avatar, name: user.name }),
|
|
@@ -8734,7 +8759,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, ErrorDetails, "ErrorDetails");
|
|
|
8734
8759
|
|
|
8735
8760
|
// src/components/errors/errorToast.ts
|
|
8736
8761
|
function errorToast(params) {
|
|
8737
|
-
_chunkPQBKPWBYjs.showError.call(void 0, _nullishCoalesce(_optionalChain([params, 'optionalAccess',
|
|
8762
|
+
_chunkPQBKPWBYjs.showError.call(void 0, _nullishCoalesce(_optionalChain([params, 'optionalAccess', _249 => _249.title]), () => ( "Error")), {
|
|
8738
8763
|
description: params.error instanceof Error ? params.error.message : String(params.error)
|
|
8739
8764
|
});
|
|
8740
8765
|
}
|
|
@@ -8931,21 +8956,21 @@ function useEditorDialog(isFormDirty, options) {
|
|
|
8931
8956
|
const [open, setOpen] = _react.useState.call(void 0, false);
|
|
8932
8957
|
const [showDiscardConfirm, setShowDiscardConfirm] = _react.useState.call(void 0, false);
|
|
8933
8958
|
_react.useEffect.call(void 0, () => {
|
|
8934
|
-
if (_optionalChain([options, 'optionalAccess',
|
|
8959
|
+
if (_optionalChain([options, 'optionalAccess', _250 => _250.dialogOpen]) !== void 0) {
|
|
8935
8960
|
setOpen(options.dialogOpen);
|
|
8936
8961
|
}
|
|
8937
|
-
}, [_optionalChain([options, 'optionalAccess',
|
|
8962
|
+
}, [_optionalChain([options, 'optionalAccess', _251 => _251.dialogOpen])]);
|
|
8938
8963
|
_react.useEffect.call(void 0, () => {
|
|
8939
|
-
if (typeof _optionalChain([options, 'optionalAccess',
|
|
8964
|
+
if (typeof _optionalChain([options, 'optionalAccess', _252 => _252.onDialogOpenChange]) === "function") {
|
|
8940
8965
|
options.onDialogOpenChange(open);
|
|
8941
8966
|
}
|
|
8942
|
-
}, [open, _optionalChain([options, 'optionalAccess',
|
|
8967
|
+
}, [open, _optionalChain([options, 'optionalAccess', _253 => _253.onDialogOpenChange])]);
|
|
8943
8968
|
_react.useEffect.call(void 0, () => {
|
|
8944
|
-
if (_optionalChain([options, 'optionalAccess',
|
|
8945
|
-
}, [_optionalChain([options, 'optionalAccess',
|
|
8969
|
+
if (_optionalChain([options, 'optionalAccess', _254 => _254.forceShow])) setOpen(true);
|
|
8970
|
+
}, [_optionalChain([options, 'optionalAccess', _255 => _255.forceShow])]);
|
|
8946
8971
|
_react.useEffect.call(void 0, () => {
|
|
8947
8972
|
if (!open) {
|
|
8948
|
-
if (_optionalChain([options, 'optionalAccess',
|
|
8973
|
+
if (_optionalChain([options, 'optionalAccess', _256 => _256.onClose])) options.onClose();
|
|
8949
8974
|
}
|
|
8950
8975
|
}, [open]);
|
|
8951
8976
|
const handleOpenChange = _react.useCallback.call(void 0,
|
|
@@ -9041,7 +9066,7 @@ function EditorSheet({
|
|
|
9041
9066
|
hasBeenOpen.current = true;
|
|
9042
9067
|
} else if (hasBeenOpen.current) {
|
|
9043
9068
|
form.reset(onReset());
|
|
9044
|
-
_optionalChain([onClose, 'optionalCall',
|
|
9069
|
+
_optionalChain([onClose, 'optionalCall', _257 => _257()]);
|
|
9045
9070
|
}
|
|
9046
9071
|
}, [open]);
|
|
9047
9072
|
const wrappedOnSubmit = _react.useCallback.call(void 0,
|
|
@@ -9055,11 +9080,11 @@ function EditorSheet({
|
|
|
9055
9080
|
if (onSuccess) {
|
|
9056
9081
|
await onSuccess();
|
|
9057
9082
|
} else if (result) {
|
|
9058
|
-
_optionalChain([onRevalidate, 'optionalCall',
|
|
9083
|
+
_optionalChain([onRevalidate, 'optionalCall', _258 => _258(generateUrl({ page: module, id: result.id, language: "[locale]" }))]);
|
|
9059
9084
|
if (isEdit && propagateChanges) {
|
|
9060
9085
|
propagateChanges(result);
|
|
9061
9086
|
} else {
|
|
9062
|
-
_optionalChain([onNavigate, 'optionalCall',
|
|
9087
|
+
_optionalChain([onNavigate, 'optionalCall', _259 => _259(generateUrl({ page: module, id: result.id }))]);
|
|
9063
9088
|
}
|
|
9064
9089
|
}
|
|
9065
9090
|
} catch (error) {
|
|
@@ -9320,7 +9345,7 @@ function DateRangeSelector({ onDateChange, avoidSettingDates, showPreviousMonth
|
|
|
9320
9345
|
}, []);
|
|
9321
9346
|
const [prevRange, setPrevRange] = _react.useState.call(void 0, date);
|
|
9322
9347
|
_react.useEffect.call(void 0, () => {
|
|
9323
|
-
if (_optionalChain([date, 'optionalAccess',
|
|
9348
|
+
if (_optionalChain([date, 'optionalAccess', _260 => _260.from]) && _optionalChain([date, 'optionalAccess', _261 => _261.to]) && date.to > date.from && (_optionalChain([prevRange, 'optionalAccess', _262 => _262.from, 'optionalAccess', _263 => _263.getTime, 'call', _264 => _264()]) !== date.from.getTime() || _optionalChain([prevRange, 'optionalAccess', _265 => _265.to, 'optionalAccess', _266 => _266.getTime, 'call', _267 => _267()]) !== date.to.getTime())) {
|
|
9324
9349
|
onDateChange(date);
|
|
9325
9350
|
setPrevRange(date);
|
|
9326
9351
|
setOpen(false);
|
|
@@ -9331,7 +9356,7 @@ function DateRangeSelector({ onDateChange, avoidSettingDates, showPreviousMonth
|
|
|
9331
9356
|
setDate(void 0);
|
|
9332
9357
|
return;
|
|
9333
9358
|
}
|
|
9334
|
-
if (range.from && (!_optionalChain([date, 'optionalAccess',
|
|
9359
|
+
if (range.from && (!_optionalChain([date, 'optionalAccess', _268 => _268.from]) || range.from.getTime() !== date.from.getTime())) {
|
|
9335
9360
|
setDate({ from: range.from, to: void 0 });
|
|
9336
9361
|
} else {
|
|
9337
9362
|
setDate(range);
|
|
@@ -9346,7 +9371,7 @@ function DateRangeSelector({ onDateChange, avoidSettingDates, showPreviousMonth
|
|
|
9346
9371
|
className: _chunkPQBKPWBYjs.cn.call(void 0, "w-[300px] justify-start text-left font-normal", !date && "text-muted-foreground"),
|
|
9347
9372
|
children: [
|
|
9348
9373
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CalendarIcon, {}),
|
|
9349
|
-
_optionalChain([date, 'optionalAccess',
|
|
9374
|
+
_optionalChain([date, 'optionalAccess', _269 => _269.from]) ? date.to ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
9350
9375
|
_datefns.format.call(void 0, date.from, "LLL dd, y"),
|
|
9351
9376
|
" - ",
|
|
9352
9377
|
_datefns.format.call(void 0, date.to, "LLL dd, y")
|
|
@@ -9369,7 +9394,7 @@ function DateRangeSelector({ onDateChange, avoidSettingDates, showPreviousMonth
|
|
|
9369
9394
|
),
|
|
9370
9395
|
children: [
|
|
9371
9396
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.CalendarIcon, {}),
|
|
9372
|
-
_optionalChain([date, 'optionalAccess',
|
|
9397
|
+
_optionalChain([date, 'optionalAccess', _270 => _270.from]) ? date.to ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
9373
9398
|
_datefns.format.call(void 0, date.from, "LLL dd, y"),
|
|
9374
9399
|
" - ",
|
|
9375
9400
|
_datefns.format.call(void 0, date.to, "LLL dd, y")
|
|
@@ -9382,7 +9407,7 @@ function DateRangeSelector({ onDateChange, avoidSettingDates, showPreviousMonth
|
|
|
9382
9407
|
Calendar,
|
|
9383
9408
|
{
|
|
9384
9409
|
mode: "range",
|
|
9385
|
-
defaultMonth: _nullishCoalesce(_optionalChain([date, 'optionalAccess',
|
|
9410
|
+
defaultMonth: _nullishCoalesce(_optionalChain([date, 'optionalAccess', _271 => _271.from]), () => ( (showPreviousMonth ? new Date((/* @__PURE__ */ new Date()).getFullYear(), (/* @__PURE__ */ new Date()).getMonth() - 1, 1) : void 0))),
|
|
9386
9411
|
selected: date,
|
|
9387
9412
|
onSelect: handleSelect,
|
|
9388
9413
|
numberOfMonths: 2
|
|
@@ -9470,7 +9495,7 @@ var FileUploader = _react.forwardRef.call(void 0,
|
|
|
9470
9495
|
movePrev();
|
|
9471
9496
|
} else if (e.key === "Enter" || e.key === "Space") {
|
|
9472
9497
|
if (activeIndex === -1) {
|
|
9473
|
-
_optionalChain([dropzoneState, 'access',
|
|
9498
|
+
_optionalChain([dropzoneState, 'access', _272 => _272.inputRef, 'access', _273 => _273.current, 'optionalAccess', _274 => _274.click, 'call', _275 => _275()]);
|
|
9474
9499
|
}
|
|
9475
9500
|
} else if (e.key === "Delete" || e.key === "Backspace") {
|
|
9476
9501
|
if (activeIndex !== -1) {
|
|
@@ -9508,13 +9533,13 @@ var FileUploader = _react.forwardRef.call(void 0,
|
|
|
9508
9533
|
onValueChange(newValues);
|
|
9509
9534
|
if (rejectedFiles.length > 0) {
|
|
9510
9535
|
for (let i = 0; i < rejectedFiles.length; i++) {
|
|
9511
|
-
if (_optionalChain([rejectedFiles, 'access',
|
|
9536
|
+
if (_optionalChain([rejectedFiles, 'access', _276 => _276[i], 'access', _277 => _277.errors, 'access', _278 => _278[0], 'optionalAccess', _279 => _279.code]) === "file-too-large") {
|
|
9512
9537
|
_chunkPQBKPWBYjs.showError.call(void 0, t("common.errors.file"), {
|
|
9513
9538
|
description: t(`common.errors.file_max`, { size: maxSize / 1024 / 1024 })
|
|
9514
9539
|
});
|
|
9515
9540
|
break;
|
|
9516
9541
|
}
|
|
9517
|
-
if (_optionalChain([rejectedFiles, 'access',
|
|
9542
|
+
if (_optionalChain([rejectedFiles, 'access', _280 => _280[i], 'access', _281 => _281.errors, 'access', _282 => _282[0], 'optionalAccess', _283 => _283.message])) {
|
|
9518
9543
|
_chunkPQBKPWBYjs.showError.call(void 0, t(`common.errors.file`), {
|
|
9519
9544
|
description: rejectedFiles[i].errors[0].message
|
|
9520
9545
|
});
|
|
@@ -9813,7 +9838,7 @@ _chunk7QVYU63Ejs.__name.call(void 0, FormCheckbox, "FormCheckbox");
|
|
|
9813
9838
|
var _dynamic = require('next/dynamic'); var _dynamic2 = _interopRequireDefault(_dynamic);
|
|
9814
9839
|
|
|
9815
9840
|
|
|
9816
|
-
var BlockNoteEditor = _dynamic2.default.call(void 0, () => Promise.resolve().then(() => _interopRequireWildcard(require("./BlockNoteEditor-
|
|
9841
|
+
var BlockNoteEditor = _dynamic2.default.call(void 0, () => Promise.resolve().then(() => _interopRequireWildcard(require("./BlockNoteEditor-JWE5R6TH.js"))), {
|
|
9817
9842
|
ssr: false
|
|
9818
9843
|
});
|
|
9819
9844
|
var BlockNoteEditorContainer = React.default.memo(/* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, function EditorContainer(props) {
|
|
@@ -9878,7 +9903,7 @@ function FormBlockNote({
|
|
|
9878
9903
|
onChange: (content, isEmpty) => {
|
|
9879
9904
|
lastEditorContentRef.current = content;
|
|
9880
9905
|
field.onChange(content);
|
|
9881
|
-
_optionalChain([onEmptyChange, 'optionalCall',
|
|
9906
|
+
_optionalChain([onEmptyChange, 'optionalCall', _284 => _284(isEmpty)]);
|
|
9882
9907
|
},
|
|
9883
9908
|
placeholder,
|
|
9884
9909
|
bordered: true,
|
|
@@ -10477,11 +10502,11 @@ function FormPlaceAutocomplete({
|
|
|
10477
10502
|
const data = await response.json();
|
|
10478
10503
|
if (data.suggestions) {
|
|
10479
10504
|
const formattedSuggestions = data.suggestions.map((suggestion) => ({
|
|
10480
|
-
place_id: _optionalChain([suggestion, 'access',
|
|
10481
|
-
description: _optionalChain([suggestion, 'access',
|
|
10505
|
+
place_id: _optionalChain([suggestion, 'access', _285 => _285.placePrediction, 'optionalAccess', _286 => _286.placeId]) || "",
|
|
10506
|
+
description: _optionalChain([suggestion, 'access', _287 => _287.placePrediction, 'optionalAccess', _288 => _288.text, 'optionalAccess', _289 => _289.text]) || "",
|
|
10482
10507
|
structured_formatting: {
|
|
10483
|
-
main_text: _optionalChain([suggestion, 'access',
|
|
10484
|
-
secondary_text: _optionalChain([suggestion, 'access',
|
|
10508
|
+
main_text: _optionalChain([suggestion, 'access', _290 => _290.placePrediction, 'optionalAccess', _291 => _291.structuredFormat, 'optionalAccess', _292 => _292.mainText, 'optionalAccess', _293 => _293.text]) || "",
|
|
10509
|
+
secondary_text: _optionalChain([suggestion, 'access', _294 => _294.placePrediction, 'optionalAccess', _295 => _295.structuredFormat, 'optionalAccess', _296 => _296.secondaryText, 'optionalAccess', _297 => _297.text]) || ""
|
|
10485
10510
|
}
|
|
10486
10511
|
}));
|
|
10487
10512
|
setSuggestions(formattedSuggestions);
|
|
@@ -10628,8 +10653,8 @@ function FormPlaceAutocomplete({
|
|
|
10628
10653
|
className: "hover:bg-muted cursor-pointer px-3 py-2 text-sm",
|
|
10629
10654
|
onClick: () => handleSuggestionSelect(suggestion),
|
|
10630
10655
|
children: [
|
|
10631
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "font-medium", children: _optionalChain([suggestion, 'access',
|
|
10632
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-muted-foreground", children: _optionalChain([suggestion, 'access',
|
|
10656
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "font-medium", children: _optionalChain([suggestion, 'access', _298 => _298.structured_formatting, 'optionalAccess', _299 => _299.main_text]) }),
|
|
10657
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-muted-foreground", children: _optionalChain([suggestion, 'access', _300 => _300.structured_formatting, 'optionalAccess', _301 => _301.secondary_text]) })
|
|
10633
10658
|
]
|
|
10634
10659
|
},
|
|
10635
10660
|
suggestion.place_id || index
|
|
@@ -10677,7 +10702,7 @@ function FormSelect({
|
|
|
10677
10702
|
disabled,
|
|
10678
10703
|
"data-testid": testId,
|
|
10679
10704
|
children: [
|
|
10680
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectValue, { children: field.value ? _optionalChain([values, 'access',
|
|
10705
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectTrigger, { className: "w-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectValue, { children: field.value ? _optionalChain([values, 'access', _302 => _302.find, 'call', _303 => _303((v) => v.id === field.value), 'optionalAccess', _304 => _304.text]) : _nullishCoalesce(placeholder, () => ( "")) }) }),
|
|
10681
10706
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, SelectContent, { children: [
|
|
10682
10707
|
allowEmpty && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectItem, { value: EMPTY_VALUE, className: "text-muted-foreground", children: _nullishCoalesce(placeholder, () => ( "")) }),
|
|
10683
10708
|
values.map((type) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SelectItem, { value: type.id, children: type.text }, type.id))
|
|
@@ -10864,7 +10889,7 @@ function UserAvatar({ user, className, showFull, showLink, showTooltip = true })
|
|
|
10864
10889
|
}, "getInitials");
|
|
10865
10890
|
const getAvatar = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
|
|
10866
10891
|
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: [
|
|
10867
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { className: "object-cover", src: _optionalChain([user, 'optionalAccess',
|
|
10892
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { className: "object-cover", src: _optionalChain([user, 'optionalAccess', _305 => _305.avatar]) }),
|
|
10868
10893
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarFallback, { children: getInitials3(user.name) })
|
|
10869
10894
|
] }) });
|
|
10870
10895
|
}, "getAvatar");
|
|
@@ -11055,7 +11080,7 @@ var useUserTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0,
|
|
|
11055
11080
|
})
|
|
11056
11081
|
};
|
|
11057
11082
|
const columns = _react.useMemo.call(void 0, () => {
|
|
11058
|
-
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access',
|
|
11083
|
+
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _306 => _306[field], 'optionalCall', _307 => _307()])).filter((col) => col !== void 0);
|
|
11059
11084
|
}, [params.fields, fieldColumnMap, t, generateUrl]);
|
|
11060
11085
|
return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
|
|
11061
11086
|
}, "useUserTableStructure");
|
|
@@ -11169,10 +11194,10 @@ function UserSelector({ id, form, label, placeholder, onChange, isRequired = fal
|
|
|
11169
11194
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-row items-center justify-between", children: [
|
|
11170
11195
|
/* @__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: [
|
|
11171
11196
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "*:ring-border *:ring-1", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Avatar, { className: `mr-2 h-4 w-4`, children: [
|
|
11172
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { src: _optionalChain([field, 'access',
|
|
11173
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarFallback, { children: _optionalChain([field, 'access',
|
|
11197
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarImage, { src: _optionalChain([field, 'access', _308 => _308.value, 'optionalAccess', _309 => _309.avatar]) }),
|
|
11198
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AvatarFallback, { children: _optionalChain([field, 'access', _310 => _310.value, 'optionalAccess', _311 => _311.name]) ? _optionalChain([field, 'access', _312 => _312.value, 'optionalAccess', _313 => _313.name, 'access', _314 => _314.split, 'call', _315 => _315(" "), 'access', _316 => _316.map, 'call', _317 => _317((name) => name.charAt(0).toUpperCase())]) : "X" })
|
|
11174
11199
|
] }) }),
|
|
11175
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _nullishCoalesce(_optionalChain([field, 'access',
|
|
11200
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _nullishCoalesce(_optionalChain([field, 'access', _318 => _318.value, 'optionalAccess', _319 => _319.name]), () => ( "")) })
|
|
11176
11201
|
] }) : /* @__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 }) }))) }) }) }),
|
|
11177
11202
|
field.value && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
11178
11203
|
_lucidereact.CircleX,
|
|
@@ -11503,7 +11528,7 @@ function CompanyUsersList({ isDeleted, fullWidth }) {
|
|
|
11503
11528
|
const data = useDataListRetriever({
|
|
11504
11529
|
ready: !!company,
|
|
11505
11530
|
retriever: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => _chunkPQBKPWBYjs.UserService.findAllUsers(params), "retriever"),
|
|
11506
|
-
retrieverParams: { companyId: _optionalChain([company, 'optionalAccess',
|
|
11531
|
+
retrieverParams: { companyId: _optionalChain([company, 'optionalAccess', _320 => _320.id]), isDeleted },
|
|
11507
11532
|
module: _chunkPQBKPWBYjs.Modules.User
|
|
11508
11533
|
});
|
|
11509
11534
|
_react.useEffect.call(void 0, () => {
|
|
@@ -11610,11 +11635,11 @@ function UserListInAdd({ data, existingUsers, setSelectedUser, setLevelOpen }) {
|
|
|
11610
11635
|
className: "cursor-pointer hover:bg-muted data-selected:hover:bg-muted bg-transparent data-selected:bg-transparent",
|
|
11611
11636
|
onClick: (_e) => {
|
|
11612
11637
|
setSelectedUser(user);
|
|
11613
|
-
_optionalChain([setLevelOpen, 'optionalCall',
|
|
11638
|
+
_optionalChain([setLevelOpen, 'optionalCall', _321 => _321(true)]);
|
|
11614
11639
|
},
|
|
11615
11640
|
onSelect: (_e) => {
|
|
11616
11641
|
setSelectedUser(user);
|
|
11617
|
-
_optionalChain([setLevelOpen, 'optionalCall',
|
|
11642
|
+
_optionalChain([setLevelOpen, 'optionalCall', _322 => _322(true)]);
|
|
11618
11643
|
},
|
|
11619
11644
|
children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-row items-center justify-between px-4 py-1", children: [
|
|
11620
11645
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, UserAvatar, { user }),
|
|
@@ -11745,7 +11770,7 @@ function CompanyContent({ company, actions }) {
|
|
|
11745
11770
|
company.legal_address
|
|
11746
11771
|
] }),
|
|
11747
11772
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-y-1", children: [
|
|
11748
|
-
_optionalChain([company, 'access',
|
|
11773
|
+
_optionalChain([company, 'access', _323 => _323.configurations, 'optionalAccess', _324 => _324.country]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground text-sm", children: [
|
|
11749
11774
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "font-medium", children: [
|
|
11750
11775
|
t("features.configuration.country"),
|
|
11751
11776
|
":"
|
|
@@ -11753,7 +11778,7 @@ function CompanyContent({ company, actions }) {
|
|
|
11753
11778
|
" ",
|
|
11754
11779
|
company.configurations.country
|
|
11755
11780
|
] }),
|
|
11756
|
-
_optionalChain([company, 'access',
|
|
11781
|
+
_optionalChain([company, 'access', _325 => _325.configurations, 'optionalAccess', _326 => _326.currency]) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-muted-foreground text-sm", children: [
|
|
11757
11782
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "font-medium", children: [
|
|
11758
11783
|
t("features.configuration.currency"),
|
|
11759
11784
|
":"
|
|
@@ -12163,7 +12188,7 @@ function CompanyEditorInternal({
|
|
|
12163
12188
|
const t = _nextintl.useTranslations.call(void 0, );
|
|
12164
12189
|
const fiscalRef = _react.useRef.call(void 0, null);
|
|
12165
12190
|
const addressComponentsRef = _react.useRef.call(void 0, {});
|
|
12166
|
-
const canAccessFeatures = hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator) || hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).CompanyAdministrator) && _optionalChain([process, 'access',
|
|
12191
|
+
const canAccessFeatures = hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator) || hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).CompanyAdministrator) && _optionalChain([process, 'access', _327 => _327.env, 'access', _328 => _328.NEXT_PUBLIC_PRIVATE_INSTALLATION, 'optionalAccess', _329 => _329.toLowerCase, 'call', _330 => _330()]) === "true";
|
|
12167
12192
|
const handleDialogOpenChange = _react.useCallback.call(void 0,
|
|
12168
12193
|
(open) => {
|
|
12169
12194
|
if (open && features.length === 0 && canAccessFeatures) {
|
|
@@ -12178,7 +12203,7 @@ function CompanyEditorInternal({
|
|
|
12178
12203
|
_chunk7QVYU63Ejs.__name.call(void 0, fetchFeatures, "fetchFeatures");
|
|
12179
12204
|
fetchFeatures();
|
|
12180
12205
|
}
|
|
12181
|
-
_optionalChain([onDialogOpenChange, 'optionalCall',
|
|
12206
|
+
_optionalChain([onDialogOpenChange, 'optionalCall', _331 => _331(open)]);
|
|
12182
12207
|
},
|
|
12183
12208
|
[features.length, canAccessFeatures, hasRole, onDialogOpenChange]
|
|
12184
12209
|
);
|
|
@@ -12223,12 +12248,12 @@ function CompanyEditorInternal({
|
|
|
12223
12248
|
);
|
|
12224
12249
|
const getDefaultValues = _react.useCallback.call(void 0, () => {
|
|
12225
12250
|
return {
|
|
12226
|
-
id: _optionalChain([company, 'optionalAccess',
|
|
12227
|
-
name: _optionalChain([company, 'optionalAccess',
|
|
12228
|
-
featureIds: _optionalChain([company, 'optionalAccess',
|
|
12229
|
-
moduleIds: _optionalChain([company, 'optionalAccess',
|
|
12230
|
-
logo: _optionalChain([company, 'optionalAccess',
|
|
12231
|
-
legal_address: _optionalChain([company, 'optionalAccess',
|
|
12251
|
+
id: _optionalChain([company, 'optionalAccess', _332 => _332.id]) || _uuid.v4.call(void 0, ),
|
|
12252
|
+
name: _optionalChain([company, 'optionalAccess', _333 => _333.name]) || "",
|
|
12253
|
+
featureIds: _optionalChain([company, 'optionalAccess', _334 => _334.features, 'access', _335 => _335.map, 'call', _336 => _336((feature) => feature.id)]) || [],
|
|
12254
|
+
moduleIds: _optionalChain([company, 'optionalAccess', _337 => _337.modules, 'access', _338 => _338.map, 'call', _339 => _339((module) => module.id)]) || [],
|
|
12255
|
+
logo: _optionalChain([company, 'optionalAccess', _340 => _340.logo]) || "",
|
|
12256
|
+
legal_address: _optionalChain([company, 'optionalAccess', _341 => _341.legal_address]) || ""
|
|
12232
12257
|
};
|
|
12233
12258
|
}, [company]);
|
|
12234
12259
|
const form = _reacthookform.useForm.call(void 0, {
|
|
@@ -12240,7 +12265,7 @@ function CompanyEditorInternal({
|
|
|
12240
12265
|
{
|
|
12241
12266
|
form,
|
|
12242
12267
|
entityType: t(`entities.companies`, { count: 1 }),
|
|
12243
|
-
entityName: _optionalChain([company, 'optionalAccess',
|
|
12268
|
+
entityName: _optionalChain([company, 'optionalAccess', _342 => _342.name]),
|
|
12244
12269
|
isEdit: !!company,
|
|
12245
12270
|
module: _chunkPQBKPWBYjs.Modules.Company,
|
|
12246
12271
|
propagateChanges,
|
|
@@ -12265,7 +12290,7 @@ function CompanyEditorInternal({
|
|
|
12265
12290
|
throw new Error("Fiscal data validation failed");
|
|
12266
12291
|
}
|
|
12267
12292
|
const payload = {
|
|
12268
|
-
id: _nullishCoalesce(_optionalChain([company, 'optionalAccess',
|
|
12293
|
+
id: _nullishCoalesce(_optionalChain([company, 'optionalAccess', _343 => _343.id]), () => ( _uuid.v4.call(void 0, ))),
|
|
12269
12294
|
name: values.name,
|
|
12270
12295
|
logo: files && contentType ? values.logo : void 0,
|
|
12271
12296
|
featureIds: values.featureIds,
|
|
@@ -12296,10 +12321,10 @@ function CompanyEditorInternal({
|
|
|
12296
12321
|
dialogOpen,
|
|
12297
12322
|
onDialogOpenChange: handleDialogOpenChange,
|
|
12298
12323
|
children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full items-start justify-between gap-x-4", children: [
|
|
12299
|
-
/* @__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-neutral-300 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',
|
|
12324
|
+
/* @__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-neutral-300 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', _344 => _344.logo]) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
12300
12325
|
_image2.default,
|
|
12301
12326
|
{
|
|
12302
|
-
src: file ? URL.createObjectURL(file) : _optionalChain([company, 'optionalAccess',
|
|
12327
|
+
src: file ? URL.createObjectURL(file) : _optionalChain([company, 'optionalAccess', _345 => _345.logo]) || "",
|
|
12303
12328
|
alt: "Company Logo",
|
|
12304
12329
|
width: 200,
|
|
12305
12330
|
height: 200
|
|
@@ -12333,7 +12358,7 @@ function CompanyEditorInternal({
|
|
|
12333
12358
|
}
|
|
12334
12359
|
),
|
|
12335
12360
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "mt-2 text-sm font-semibold", children: t(`company.sections.fiscal_data`) }),
|
|
12336
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, ItalianFiscalData_default, { ref: fiscalRef, initialData: parseFiscalData(_optionalChain([company, 'optionalAccess',
|
|
12361
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, ItalianFiscalData_default, { ref: fiscalRef, initialData: parseFiscalData(_optionalChain([company, 'optionalAccess', _346 => _346.fiscal_data])) })
|
|
12337
12362
|
] }),
|
|
12338
12363
|
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 }) }) })
|
|
12339
12364
|
] })
|
|
@@ -12450,7 +12475,7 @@ function NotificationToast(notification, t, generateUrl, reouter) {
|
|
|
12450
12475
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col", children: [
|
|
12451
12476
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: t.rich(`notification.${notification.notificationType}.description`, {
|
|
12452
12477
|
strong: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (chunks) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: chunks }), "strong"),
|
|
12453
|
-
actor: _nullishCoalesce(_optionalChain([data, 'access',
|
|
12478
|
+
actor: _nullishCoalesce(_optionalChain([data, 'access', _347 => _347.actor, 'optionalAccess', _348 => _348.name]), () => ( "")),
|
|
12454
12479
|
title: data.title,
|
|
12455
12480
|
message: _nullishCoalesce(notification.message, () => ( ""))
|
|
12456
12481
|
}) }),
|
|
@@ -12479,7 +12504,7 @@ function NotificationMenuItem({ notification, closePopover }) {
|
|
|
12479
12504
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col", children: [
|
|
12480
12505
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: t.rich(`notification.${notification.notificationType}.description`, {
|
|
12481
12506
|
strong: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (chunks) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: chunks }), "strong"),
|
|
12482
|
-
actor: _nullishCoalesce(_optionalChain([data, 'access',
|
|
12507
|
+
actor: _nullishCoalesce(_optionalChain([data, 'access', _349 => _349.actor, 'optionalAccess', _350 => _350.name]), () => ( "")),
|
|
12483
12508
|
title: data.title,
|
|
12484
12509
|
message: _nullishCoalesce(notification.message, () => ( ""))
|
|
12485
12510
|
}) }),
|
|
@@ -12543,7 +12568,7 @@ var NotificationContextProvider = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(v
|
|
|
12543
12568
|
_react.useEffect.call(void 0, () => {
|
|
12544
12569
|
if (hasInitiallyLoaded || !currentUser) return;
|
|
12545
12570
|
if (_chunkJO5BLONKjs.isRolesConfigured.call(void 0, )) {
|
|
12546
|
-
const isAdmin = _optionalChain([currentUser, 'access',
|
|
12571
|
+
const isAdmin = _optionalChain([currentUser, 'access', _351 => _351.roles, 'optionalAccess', _352 => _352.some, 'call', _353 => _353((role) => role.id === _chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator)]);
|
|
12547
12572
|
if (isAdmin) {
|
|
12548
12573
|
setHasInitiallyLoaded(true);
|
|
12549
12574
|
return;
|
|
@@ -12745,7 +12770,7 @@ function OnboardingProvider({
|
|
|
12745
12770
|
let tourSteps = steps;
|
|
12746
12771
|
if (!tourSteps) {
|
|
12747
12772
|
const tour2 = tours.find((t) => t.id === tourId);
|
|
12748
|
-
tourSteps = _optionalChain([tour2, 'optionalAccess',
|
|
12773
|
+
tourSteps = _optionalChain([tour2, 'optionalAccess', _354 => _354.steps]);
|
|
12749
12774
|
}
|
|
12750
12775
|
if (!tourSteps || tourSteps.length === 0) {
|
|
12751
12776
|
console.warn(`No steps found for tour: ${tourId}`);
|
|
@@ -12813,10 +12838,10 @@ function OnboardingProvider({
|
|
|
12813
12838
|
when: {
|
|
12814
12839
|
show: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
|
|
12815
12840
|
setCurrentStepIndex(index);
|
|
12816
|
-
_optionalChain([stepConfig, 'access',
|
|
12841
|
+
_optionalChain([stepConfig, 'access', _355 => _355.onShow, 'optionalCall', _356 => _356()]);
|
|
12817
12842
|
}, "show"),
|
|
12818
12843
|
hide: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
|
|
12819
|
-
_optionalChain([stepConfig, 'access',
|
|
12844
|
+
_optionalChain([stepConfig, 'access', _357 => _357.onHide, 'optionalCall', _358 => _358()]);
|
|
12820
12845
|
}, "hide")
|
|
12821
12846
|
}
|
|
12822
12847
|
});
|
|
@@ -12982,7 +13007,7 @@ function HowToMultiSelector({
|
|
|
12982
13007
|
retriever: (params) => _chunkPQBKPWBYjs.HowToService.findMany(params),
|
|
12983
13008
|
module: _chunkPQBKPWBYjs.Modules.HowTo,
|
|
12984
13009
|
getLabel: (howTo) => howTo.name,
|
|
12985
|
-
excludeId: _optionalChain([currentHowTo, 'optionalAccess',
|
|
13010
|
+
excludeId: _optionalChain([currentHowTo, 'optionalAccess', _359 => _359.id]),
|
|
12986
13011
|
onChange
|
|
12987
13012
|
}
|
|
12988
13013
|
);
|
|
@@ -13090,17 +13115,17 @@ function HowToEditorInternal({
|
|
|
13090
13115
|
);
|
|
13091
13116
|
const getDefaultValues = _react.useCallback.call(void 0,
|
|
13092
13117
|
() => ({
|
|
13093
|
-
id: _optionalChain([howTo, 'optionalAccess',
|
|
13094
|
-
name: _optionalChain([howTo, 'optionalAccess',
|
|
13095
|
-
description: _optionalChain([howTo, 'optionalAccess',
|
|
13096
|
-
pages: _chunkPQBKPWBYjs.HowTo.parsePagesFromString(_optionalChain([howTo, 'optionalAccess',
|
|
13097
|
-
howToType: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13098
|
-
slug: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13099
|
-
order: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13100
|
-
summary: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13101
|
-
tags: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13102
|
-
contextualKeys: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13103
|
-
draft: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess',
|
|
13118
|
+
id: _optionalChain([howTo, 'optionalAccess', _360 => _360.id]) || _uuid.v4.call(void 0, ),
|
|
13119
|
+
name: _optionalChain([howTo, 'optionalAccess', _361 => _361.name]) || "",
|
|
13120
|
+
description: _optionalChain([howTo, 'optionalAccess', _362 => _362.description]) || [],
|
|
13121
|
+
pages: _chunkPQBKPWBYjs.HowTo.parsePagesFromString(_optionalChain([howTo, 'optionalAccess', _363 => _363.pages])),
|
|
13122
|
+
howToType: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _364 => _364.howToType]), () => ( "how-to")),
|
|
13123
|
+
slug: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _365 => _365.slug]), () => ( "")),
|
|
13124
|
+
order: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _366 => _366.order]), () => ( 0)),
|
|
13125
|
+
summary: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _367 => _367.summary]), () => ( "")),
|
|
13126
|
+
tags: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _368 => _368.tags]), () => ( []))).join(", "),
|
|
13127
|
+
contextualKeys: (_nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _369 => _369.contextualKeys]), () => ( []))).join(", "),
|
|
13128
|
+
draft: _nullishCoalesce(_optionalChain([howTo, 'optionalAccess', _370 => _370.draft]), () => ( false)),
|
|
13104
13129
|
relatedArticles: []
|
|
13105
13130
|
}),
|
|
13106
13131
|
[howTo]
|
|
@@ -13111,7 +13136,7 @@ function HowToEditorInternal({
|
|
|
13111
13136
|
});
|
|
13112
13137
|
const initialRelatedIds = _react.useRef.call(void 0, []);
|
|
13113
13138
|
_react.useEffect.call(void 0, () => {
|
|
13114
|
-
if (!_optionalChain([howTo, 'optionalAccess',
|
|
13139
|
+
if (!_optionalChain([howTo, 'optionalAccess', _371 => _371.howToType]) || !_optionalChain([howTo, 'optionalAccess', _372 => _372.slug])) return;
|
|
13115
13140
|
let active = true;
|
|
13116
13141
|
_chunkPQBKPWBYjs.HowToService.findRelated({ howToType: howTo.howToType, slug: howTo.slug }).then((list) => {
|
|
13117
13142
|
if (!active) return;
|
|
@@ -13150,7 +13175,7 @@ function HowToEditorInternal({
|
|
|
13150
13175
|
{
|
|
13151
13176
|
form,
|
|
13152
13177
|
entityType: t(`entities.howtos`, { count: 1 }),
|
|
13153
|
-
entityName: _optionalChain([howTo, 'optionalAccess',
|
|
13178
|
+
entityName: _optionalChain([howTo, 'optionalAccess', _373 => _373.name]),
|
|
13154
13179
|
isEdit: !!howTo,
|
|
13155
13180
|
module: _chunkPQBKPWBYjs.Modules.HowTo,
|
|
13156
13181
|
propagateChanges,
|
|
@@ -13531,7 +13556,7 @@ function withPatchedTitle(source, title) {
|
|
|
13531
13556
|
return _chunkPQBKPWBYjs.rehydrate.call(void 0, _chunkPQBKPWBYjs.Modules.Assistant, {
|
|
13532
13557
|
jsonApi: {
|
|
13533
13558
|
...dehydrated.jsonApi,
|
|
13534
|
-
attributes: { ..._nullishCoalesce(_optionalChain([dehydrated, 'access',
|
|
13559
|
+
attributes: { ..._nullishCoalesce(_optionalChain([dehydrated, 'access', _374 => _374.jsonApi, 'optionalAccess', _375 => _375.attributes]), () => ( {})), title }
|
|
13535
13560
|
},
|
|
13536
13561
|
included: dehydrated.included
|
|
13537
13562
|
});
|
|
@@ -13552,7 +13577,7 @@ function AssistantProvider({ children, dehydratedAssistant, dehydratedMessages,
|
|
|
13552
13577
|
const [status, setStatus] = _react.useState.call(void 0, void 0);
|
|
13553
13578
|
const [failedMessageIds, setFailedMessageIds] = _react.useState.call(void 0, () => /* @__PURE__ */ new Set());
|
|
13554
13579
|
const [operatorMode, setOperatorMode] = _react.useState.call(void 0,
|
|
13555
|
-
() => _optionalChain([dehydratedAssistant, 'optionalAccess',
|
|
13580
|
+
() => _optionalChain([dehydratedAssistant, 'optionalAccess', _376 => _376.jsonApi, 'optionalAccess', _377 => _377.attributes, 'optionalAccess', _378 => _378.engine]) === "operator"
|
|
13556
13581
|
);
|
|
13557
13582
|
const { socket } = useSocketContext();
|
|
13558
13583
|
const sendMessage = _react.useCallback.call(void 0,
|
|
@@ -13561,7 +13586,7 @@ function AssistantProvider({ children, dehydratedAssistant, dehydratedMessages,
|
|
|
13561
13586
|
if (!trimmed) return;
|
|
13562
13587
|
const optimistic = _chunkPQBKPWBYjs.AssistantMessage.buildOptimistic({
|
|
13563
13588
|
content: trimmed,
|
|
13564
|
-
assistantId: _optionalChain([assistant, 'optionalAccess',
|
|
13589
|
+
assistantId: _optionalChain([assistant, 'optionalAccess', _379 => _379.id]),
|
|
13565
13590
|
position: nextPosition(messages)
|
|
13566
13591
|
});
|
|
13567
13592
|
setMessages((prev) => [...prev, optimistic]);
|
|
@@ -13571,13 +13596,13 @@ function AssistantProvider({ children, dehydratedAssistant, dehydratedMessages,
|
|
|
13571
13596
|
if (assistant && payload.assistantId && payload.assistantId !== assistant.id) return;
|
|
13572
13597
|
if (typeof payload.status === "string") setStatus(payload.status);
|
|
13573
13598
|
}, "handler");
|
|
13574
|
-
_optionalChain([socket, 'optionalAccess',
|
|
13599
|
+
_optionalChain([socket, 'optionalAccess', _380 => _380.on, 'call', _381 => _381("assistant:status", handler)]);
|
|
13575
13600
|
try {
|
|
13576
13601
|
if (!assistant) {
|
|
13577
13602
|
const input = {
|
|
13578
13603
|
firstMessage: trimmed,
|
|
13579
|
-
howToMode: _optionalChain([opts, 'optionalAccess',
|
|
13580
|
-
limitToHowToId: _optionalChain([opts, 'optionalAccess',
|
|
13604
|
+
howToMode: _optionalChain([opts, 'optionalAccess', _382 => _382.howToMode]),
|
|
13605
|
+
limitToHowToId: _optionalChain([opts, 'optionalAccess', _383 => _383.limitToHowToId])
|
|
13581
13606
|
};
|
|
13582
13607
|
const created = operatorMode ? await _chunkPQBKPWBYjs.AssistantService.createOperator(input) : await _chunkPQBKPWBYjs.AssistantService.create(input);
|
|
13583
13608
|
const msgs = await _chunkPQBKPWBYjs.AssistantMessageService.findByAssistant({ assistantId: created.id });
|
|
@@ -13594,8 +13619,8 @@ function AssistantProvider({ children, dehydratedAssistant, dehydratedMessages,
|
|
|
13594
13619
|
}) : await _chunkPQBKPWBYjs.AssistantService.appendMessage({
|
|
13595
13620
|
assistantId: assistant.id,
|
|
13596
13621
|
content: trimmed,
|
|
13597
|
-
howToMode: _optionalChain([opts, 'optionalAccess',
|
|
13598
|
-
limitToHowToId: _optionalChain([opts, 'optionalAccess',
|
|
13622
|
+
howToMode: _optionalChain([opts, 'optionalAccess', _384 => _384.howToMode]),
|
|
13623
|
+
limitToHowToId: _optionalChain([opts, 'optionalAccess', _385 => _385.limitToHowToId])
|
|
13599
13624
|
});
|
|
13600
13625
|
setMessages((prev) => [...stripOptimistic(prev), ...result]);
|
|
13601
13626
|
}
|
|
@@ -13606,7 +13631,7 @@ function AssistantProvider({ children, dehydratedAssistant, dehydratedMessages,
|
|
|
13606
13631
|
return next;
|
|
13607
13632
|
});
|
|
13608
13633
|
} finally {
|
|
13609
|
-
_optionalChain([socket, 'optionalAccess',
|
|
13634
|
+
_optionalChain([socket, 'optionalAccess', _386 => _386.off, 'call', _387 => _387("assistant:status", handler)]);
|
|
13610
13635
|
setSending(false);
|
|
13611
13636
|
setStatus(void 0);
|
|
13612
13637
|
}
|
|
@@ -13664,7 +13689,7 @@ function AssistantProvider({ children, dehydratedAssistant, dehydratedMessages,
|
|
|
13664
13689
|
await _chunkPQBKPWBYjs.AssistantService.delete({ id });
|
|
13665
13690
|
setThreads((prev) => prev.filter((t2) => t2.id !== id));
|
|
13666
13691
|
setAssistant((prev) => {
|
|
13667
|
-
if (_optionalChain([prev, 'optionalAccess',
|
|
13692
|
+
if (_optionalChain([prev, 'optionalAccess', _388 => _388.id]) === id) {
|
|
13668
13693
|
setMessages([]);
|
|
13669
13694
|
return void 0;
|
|
13670
13695
|
}
|
|
@@ -13884,7 +13909,7 @@ function EditableAvatar({
|
|
|
13884
13909
|
}, [image, isUploading, patchImage, t]);
|
|
13885
13910
|
const handleFileInputChange = _react.useCallback.call(void 0,
|
|
13886
13911
|
(e) => {
|
|
13887
|
-
const file = _optionalChain([e, 'access',
|
|
13912
|
+
const file = _optionalChain([e, 'access', _389 => _389.target, 'access', _390 => _390.files, 'optionalAccess', _391 => _391[0]]);
|
|
13888
13913
|
if (file) handleFile(file);
|
|
13889
13914
|
e.target.value = "";
|
|
13890
13915
|
},
|
|
@@ -13893,7 +13918,7 @@ function EditableAvatar({
|
|
|
13893
13918
|
const handleDrop = _react.useCallback.call(void 0,
|
|
13894
13919
|
(e) => {
|
|
13895
13920
|
e.preventDefault();
|
|
13896
|
-
const file = _optionalChain([e, 'access',
|
|
13921
|
+
const file = _optionalChain([e, 'access', _392 => _392.dataTransfer, 'access', _393 => _393.files, 'optionalAccess', _394 => _394[0]]);
|
|
13897
13922
|
if (file && file.type.startsWith("image/")) {
|
|
13898
13923
|
handleFile(file);
|
|
13899
13924
|
}
|
|
@@ -13920,7 +13945,7 @@ function EditableAvatar({
|
|
|
13920
13945
|
"button",
|
|
13921
13946
|
{
|
|
13922
13947
|
type: "button",
|
|
13923
|
-
onClick: () => _optionalChain([fileInputRef, 'access',
|
|
13948
|
+
onClick: () => _optionalChain([fileInputRef, 'access', _395 => _395.current, 'optionalAccess', _396 => _396.click, 'call', _397 => _397()]),
|
|
13924
13949
|
disabled: isUploading,
|
|
13925
13950
|
className: "rounded-full p-2 text-white hover:bg-white/20 disabled:opacity-50",
|
|
13926
13951
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.PencilIcon, { className: "h-4 w-4" })
|
|
@@ -14001,7 +14026,7 @@ function BreadcrumbMobile({
|
|
|
14001
14026
|
}
|
|
14002
14027
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, DropdownMenu, { open, onOpenChange: setOpen, children: [
|
|
14003
14028
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, DropdownMenuTrigger, { className: "text-foreground text-xs/relaxed font-normal hover:bg-accent flex items-center gap-1 rounded-md px-1.5 py-0.5 transition-colors outline-none", children: [
|
|
14004
|
-
_optionalChain([lastItem, 'optionalAccess',
|
|
14029
|
+
_optionalChain([lastItem, 'optionalAccess', _398 => _398.name]),
|
|
14005
14030
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ChevronDownIcon, { className: "text-muted-foreground size-3.5" })
|
|
14006
14031
|
] }),
|
|
14007
14032
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, DropdownMenuContent, { align: "start", children: allItems.map((item, index) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DropdownMenuItem, { children: item.href ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Link, { href: item.href, onClick: item.onClick, children: item.name }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, { children: item.name }) }, index)) })
|
|
@@ -14297,9 +14322,10 @@ function RoundPageContainerTitle({
|
|
|
14297
14322
|
{
|
|
14298
14323
|
render: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {}),
|
|
14299
14324
|
nativeButton: false,
|
|
14300
|
-
variant: `ghost`,
|
|
14325
|
+
variant: showDetails ? `ghost` : `default`,
|
|
14301
14326
|
onClick: () => setShowDetails(!showDetails),
|
|
14302
|
-
|
|
14327
|
+
className: _chunkPQBKPWBYjs.cn.call(void 0, `cursor-pointer`),
|
|
14328
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.InfoIcon, {})
|
|
14303
14329
|
}
|
|
14304
14330
|
) }),
|
|
14305
14331
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TooltipContent, { children: showDetails ? "Hide details" : "Show details" })
|
|
@@ -14322,7 +14348,7 @@ var railTriggerClass = _chunkPQBKPWBYjs.cn.call(void 0,
|
|
|
14322
14348
|
"data-[state=active]:bg-foreground data-[state=active]:text-background",
|
|
14323
14349
|
"data-[state=active]:font-semibold data-[state=active]:shadow-none"
|
|
14324
14350
|
);
|
|
14325
|
-
var tabValue = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (tab) => _nullishCoalesce(_nullishCoalesce(tab.sectionKey, () => ( _optionalChain([tab, 'access',
|
|
14351
|
+
var tabValue = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (tab) => _nullishCoalesce(_nullishCoalesce(tab.sectionKey, () => ( _optionalChain([tab, 'access', _399 => _399.key, 'optionalAccess', _400 => _400.name]))), () => ( tab.label)), "tabValue");
|
|
14326
14352
|
function RoundPageContainer({
|
|
14327
14353
|
module,
|
|
14328
14354
|
id,
|
|
@@ -14341,7 +14367,7 @@ function RoundPageContainer({
|
|
|
14341
14367
|
const [mounted, setMounted] = _react.useState.call(void 0, false);
|
|
14342
14368
|
_react.useEffect.call(void 0, () => {
|
|
14343
14369
|
const match = document.cookie.split("; ").find((row) => row.startsWith(`${DETAILS_COOKIE_NAME}=`));
|
|
14344
|
-
if (_optionalChain([match, 'optionalAccess',
|
|
14370
|
+
if (_optionalChain([match, 'optionalAccess', _401 => _401.split, 'call', _402 => _402("="), 'access', _403 => _403[1]]) === "true") setShowDetailsState(true);
|
|
14345
14371
|
}, []);
|
|
14346
14372
|
_react.useEffect.call(void 0, () => {
|
|
14347
14373
|
setMounted(true);
|
|
@@ -14370,7 +14396,7 @@ function RoundPageContainer({
|
|
|
14370
14396
|
},
|
|
14371
14397
|
[module, id, rewriteUrl]
|
|
14372
14398
|
);
|
|
14373
|
-
const activeFillHeight = _optionalChain([tabs, 'optionalAccess',
|
|
14399
|
+
const activeFillHeight = _optionalChain([tabs, 'optionalAccess', _404 => _404.find, 'call', _405 => _405((t) => tabValue(t) === activeTab), 'optionalAccess', _406 => _406.fillHeight]) === true;
|
|
14374
14400
|
const { ungrouped, groups } = _react.useMemo.call(void 0, () => partitionTabs(_nullishCoalesce(tabs, () => ( []))), [tabs]);
|
|
14375
14401
|
const isReady = mounted && isMobile !== void 0;
|
|
14376
14402
|
if (!isReady) {
|
|
@@ -14652,14 +14678,14 @@ function BlockNoteEditorMentionHoverCard({
|
|
|
14652
14678
|
const entityType = target.dataset.mentionType;
|
|
14653
14679
|
const alias = target.dataset.mentionAlias;
|
|
14654
14680
|
setHovered((prev) => {
|
|
14655
|
-
if (_optionalChain([prev, 'optionalAccess',
|
|
14681
|
+
if (_optionalChain([prev, 'optionalAccess', _407 => _407.id]) === id && _optionalChain([prev, 'optionalAccess', _408 => _408.element]) === target) return prev;
|
|
14656
14682
|
return { id, entityType, alias, element: target };
|
|
14657
14683
|
});
|
|
14658
14684
|
}, "handleMouseOver");
|
|
14659
14685
|
const handleMouseOut = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (e) => {
|
|
14660
14686
|
const target = e.target.closest("[data-mention-id]");
|
|
14661
14687
|
if (!target) return;
|
|
14662
|
-
const related = _optionalChain([e, 'access',
|
|
14688
|
+
const related = _optionalChain([e, 'access', _409 => _409.relatedTarget, 'optionalAccess', _410 => _410.closest, 'call', _411 => _411("[data-mention-id]")]);
|
|
14663
14689
|
if (related) return;
|
|
14664
14690
|
scheduleClose();
|
|
14665
14691
|
}, "handleMouseOut");
|
|
@@ -14673,7 +14699,7 @@ function BlockNoteEditorMentionHoverCard({
|
|
|
14673
14699
|
}, [containerRef, mentionResolveFn, cancelClose, scheduleClose]);
|
|
14674
14700
|
if (!hovered || !mentionResolveFn) return null;
|
|
14675
14701
|
const resolved = mentionResolveFn(hovered.id, hovered.entityType, hovered.alias);
|
|
14676
|
-
if (!_optionalChain([resolved, 'optionalAccess',
|
|
14702
|
+
if (!_optionalChain([resolved, 'optionalAccess', _412 => _412.HoverContent])) return null;
|
|
14677
14703
|
const ContentComponent = resolved.HoverContent;
|
|
14678
14704
|
const rect = hovered.element.getBoundingClientRect();
|
|
14679
14705
|
return _reactdom.createPortal.call(void 0,
|
|
@@ -14716,28 +14742,28 @@ var parseMentionElement = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (
|
|
|
14716
14742
|
}, "parseMentionElement");
|
|
14717
14743
|
var createMentionInlineContentSpec = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (resolveFn, disableMention, nameResolver) => {
|
|
14718
14744
|
const MentionExternalHTML = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (props) => {
|
|
14719
|
-
const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall',
|
|
14745
|
+
const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall', _413 => _413(props.id, props.entityType, props.alias)]), () => ( props.alias));
|
|
14720
14746
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { "data-mention-id": props.id, "data-mention-type": props.entityType, "data-mention-alias": props.alias, children: [
|
|
14721
14747
|
"@",
|
|
14722
14748
|
displayName
|
|
14723
14749
|
] });
|
|
14724
14750
|
}, "MentionExternalHTML");
|
|
14725
14751
|
const Mention = React.default.memo(/* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, function Mention2(props) {
|
|
14726
|
-
const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall',
|
|
14752
|
+
const displayName = _nullishCoalesce(_optionalChain([nameResolver, 'optionalCall', _414 => _414(props.id, props.entityType, props.alias)]), () => ( props.alias));
|
|
14727
14753
|
if (disableMention) {
|
|
14728
|
-
const resolved2 = _optionalChain([resolveFn, 'optionalCall',
|
|
14729
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _link2.default, { href: _nullishCoalesce(_optionalChain([resolved2, 'optionalAccess',
|
|
14754
|
+
const resolved2 = _optionalChain([resolveFn, 'optionalCall', _415 => _415(props.id, props.entityType, displayName)]);
|
|
14755
|
+
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _link2.default, { href: _nullishCoalesce(_optionalChain([resolved2, 'optionalAccess', _416 => _416.url]), () => ( "#")), className: "text-primary", children: [
|
|
14730
14756
|
"@",
|
|
14731
14757
|
displayName
|
|
14732
14758
|
] });
|
|
14733
14759
|
}
|
|
14734
|
-
const resolved = _optionalChain([resolveFn, 'optionalCall',
|
|
14735
|
-
if (_optionalChain([resolved, 'optionalAccess',
|
|
14760
|
+
const resolved = _optionalChain([resolveFn, 'optionalCall', _417 => _417(props.id, props.entityType, displayName)]);
|
|
14761
|
+
if (_optionalChain([resolved, 'optionalAccess', _418 => _418.Inline])) {
|
|
14736
14762
|
const Custom = resolved.Inline;
|
|
14737
14763
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Custom, { ...props, alias: displayName });
|
|
14738
14764
|
}
|
|
14739
|
-
const href = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess',
|
|
14740
|
-
const handleClick = _optionalChain([resolved, 'optionalAccess',
|
|
14765
|
+
const href = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _419 => _419.url]), () => ( "#"));
|
|
14766
|
+
const handleClick = _optionalChain([resolved, 'optionalAccess', _420 => _420.onActivate]) ? (e) => resolved.onActivate(e, props) : void 0;
|
|
14741
14767
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
14742
14768
|
_link2.default,
|
|
14743
14769
|
{
|
|
@@ -14843,7 +14869,7 @@ function BlockNoteEditorMentionSuggestionMenu({
|
|
|
14843
14869
|
if (!suggestionMenuComponent) return void 0;
|
|
14844
14870
|
const Component2 = suggestionMenuComponent;
|
|
14845
14871
|
const Wrapped = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (props) => {
|
|
14846
|
-
const isSentinelOnly = props.items.length === 1 && _optionalChain([props, 'access',
|
|
14872
|
+
const isSentinelOnly = props.items.length === 1 && _optionalChain([props, 'access', _421 => _421.items, 'access', _422 => _422[0], 'optionalAccess', _423 => _423.title]) === KEEP_OPEN_SENTINEL_TITLE;
|
|
14847
14873
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
14848
14874
|
Component2,
|
|
14849
14875
|
{
|
|
@@ -14852,7 +14878,7 @@ function BlockNoteEditorMentionSuggestionMenu({
|
|
|
14852
14878
|
selectedIndex: isSentinelOnly ? void 0 : props.selectedIndex,
|
|
14853
14879
|
onItemClick: (item) => {
|
|
14854
14880
|
if (item.title === KEEP_OPEN_SENTINEL_TITLE) return;
|
|
14855
|
-
_optionalChain([props, 'access',
|
|
14881
|
+
_optionalChain([props, 'access', _424 => _424.onItemClick, 'optionalCall', _425 => _425(item)]);
|
|
14856
14882
|
}
|
|
14857
14883
|
}
|
|
14858
14884
|
);
|
|
@@ -15046,10 +15072,10 @@ var cellId = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (params) => {
|
|
|
15046
15072
|
cell: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, ({ row }) => params.toggleId ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
15047
15073
|
Checkbox,
|
|
15048
15074
|
{
|
|
15049
|
-
checked: _optionalChain([params, 'access',
|
|
15075
|
+
checked: _optionalChain([params, 'access', _426 => _426.checkedIds, 'optionalAccess', _427 => _427.includes, 'call', _428 => _428(row.getValue(params.name))]) || false,
|
|
15050
15076
|
onCheckedChange: (value) => {
|
|
15051
15077
|
row.toggleSelected(!!value);
|
|
15052
|
-
_optionalChain([params, 'access',
|
|
15078
|
+
_optionalChain([params, 'access', _429 => _429.toggleId, 'optionalCall', _430 => _430(row.getValue(params.name))]);
|
|
15053
15079
|
},
|
|
15054
15080
|
"aria-label": "Select row"
|
|
15055
15081
|
}
|
|
@@ -15108,7 +15134,7 @@ function useJsonApiGet(params) {
|
|
|
15108
15134
|
const [response, setResponse] = _react.useState.call(void 0, null);
|
|
15109
15135
|
const isMounted = _react.useRef.call(void 0, true);
|
|
15110
15136
|
const fetchData = _react.useCallback.call(void 0, async () => {
|
|
15111
|
-
if (_optionalChain([params, 'access',
|
|
15137
|
+
if (_optionalChain([params, 'access', _431 => _431.options, 'optionalAccess', _432 => _432.enabled]) === false) return;
|
|
15112
15138
|
setLoading(true);
|
|
15113
15139
|
setError(null);
|
|
15114
15140
|
try {
|
|
@@ -15135,9 +15161,9 @@ function useJsonApiGet(params) {
|
|
|
15135
15161
|
setLoading(false);
|
|
15136
15162
|
}
|
|
15137
15163
|
}
|
|
15138
|
-
}, [params.classKey, params.endpoint, params.companyId, _optionalChain([params, 'access',
|
|
15164
|
+
}, [params.classKey, params.endpoint, params.companyId, _optionalChain([params, 'access', _433 => _433.options, 'optionalAccess', _434 => _434.enabled])]);
|
|
15139
15165
|
const fetchNextPage = _react.useCallback.call(void 0, async () => {
|
|
15140
|
-
if (!_optionalChain([response, 'optionalAccess',
|
|
15166
|
+
if (!_optionalChain([response, 'optionalAccess', _435 => _435.nextPage])) return;
|
|
15141
15167
|
setLoading(true);
|
|
15142
15168
|
try {
|
|
15143
15169
|
const nextResponse = await response.nextPage();
|
|
@@ -15158,7 +15184,7 @@ function useJsonApiGet(params) {
|
|
|
15158
15184
|
}
|
|
15159
15185
|
}, [response]);
|
|
15160
15186
|
const fetchPreviousPage = _react.useCallback.call(void 0, async () => {
|
|
15161
|
-
if (!_optionalChain([response, 'optionalAccess',
|
|
15187
|
+
if (!_optionalChain([response, 'optionalAccess', _436 => _436.prevPage])) return;
|
|
15162
15188
|
setLoading(true);
|
|
15163
15189
|
try {
|
|
15164
15190
|
const prevResponse = await response.prevPage();
|
|
@@ -15184,15 +15210,15 @@ function useJsonApiGet(params) {
|
|
|
15184
15210
|
return () => {
|
|
15185
15211
|
isMounted.current = false;
|
|
15186
15212
|
};
|
|
15187
|
-
}, [fetchData, ..._optionalChain([params, 'access',
|
|
15213
|
+
}, [fetchData, ..._optionalChain([params, 'access', _437 => _437.options, 'optionalAccess', _438 => _438.deps]) || []]);
|
|
15188
15214
|
return {
|
|
15189
15215
|
data,
|
|
15190
15216
|
loading,
|
|
15191
15217
|
error,
|
|
15192
15218
|
response,
|
|
15193
15219
|
refetch: fetchData,
|
|
15194
|
-
hasNextPage: !!_optionalChain([response, 'optionalAccess',
|
|
15195
|
-
hasPreviousPage: !!_optionalChain([response, 'optionalAccess',
|
|
15220
|
+
hasNextPage: !!_optionalChain([response, 'optionalAccess', _439 => _439.next]),
|
|
15221
|
+
hasPreviousPage: !!_optionalChain([response, 'optionalAccess', _440 => _440.prev]),
|
|
15196
15222
|
fetchNextPage,
|
|
15197
15223
|
fetchPreviousPage
|
|
15198
15224
|
};
|
|
@@ -15270,17 +15296,17 @@ function useJsonApiMutation(config) {
|
|
|
15270
15296
|
if (apiResponse.ok) {
|
|
15271
15297
|
const resultData = apiResponse.data;
|
|
15272
15298
|
setData(resultData);
|
|
15273
|
-
_optionalChain([config, 'access',
|
|
15299
|
+
_optionalChain([config, 'access', _441 => _441.onSuccess, 'optionalCall', _442 => _442(resultData)]);
|
|
15274
15300
|
return resultData;
|
|
15275
15301
|
} else {
|
|
15276
15302
|
setError(apiResponse.error);
|
|
15277
|
-
_optionalChain([config, 'access',
|
|
15303
|
+
_optionalChain([config, 'access', _443 => _443.onError, 'optionalCall', _444 => _444(apiResponse.error)]);
|
|
15278
15304
|
return null;
|
|
15279
15305
|
}
|
|
15280
15306
|
} catch (err) {
|
|
15281
15307
|
const errorMessage = err instanceof Error ? err.message : "Unknown error";
|
|
15282
15308
|
setError(errorMessage);
|
|
15283
|
-
_optionalChain([config, 'access',
|
|
15309
|
+
_optionalChain([config, 'access', _445 => _445.onError, 'optionalCall', _446 => _446(errorMessage)]);
|
|
15284
15310
|
return null;
|
|
15285
15311
|
} finally {
|
|
15286
15312
|
setLoading(false);
|
|
@@ -15353,7 +15379,7 @@ var useCompanyTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void
|
|
|
15353
15379
|
{
|
|
15354
15380
|
href: hasRole(_chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator) ? generateUrl({
|
|
15355
15381
|
page: "/administration",
|
|
15356
|
-
id: _optionalChain([_chunkPQBKPWBYjs.Modules, 'access',
|
|
15382
|
+
id: _optionalChain([_chunkPQBKPWBYjs.Modules, 'access', _447 => _447.Company, 'access', _448 => _448.pageUrl, 'optionalAccess', _449 => _449.substring, 'call', _450 => _450(1)]),
|
|
15357
15383
|
childPage: company.id
|
|
15358
15384
|
}) : generateUrl({ page: _chunkPQBKPWBYjs.Modules.Company, id: company.id }),
|
|
15359
15385
|
children: row.getValue("name")
|
|
@@ -15369,7 +15395,7 @@ var useCompanyTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void
|
|
|
15369
15395
|
})
|
|
15370
15396
|
};
|
|
15371
15397
|
const columns = _react.useMemo.call(void 0, () => {
|
|
15372
|
-
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access',
|
|
15398
|
+
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _451 => _451[field], 'optionalCall', _452 => _452()])).filter((col) => col !== void 0);
|
|
15373
15399
|
}, [params.fields, fieldColumnMap, t, generateUrl, hasRole]);
|
|
15374
15400
|
return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
|
|
15375
15401
|
}, "useCompanyTableStructure");
|
|
@@ -15381,7 +15407,7 @@ var GRACE_DAYS = 3;
|
|
|
15381
15407
|
var isAdministrator = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (currentUser) => {
|
|
15382
15408
|
if (!currentUser || !_chunkJO5BLONKjs.isRolesConfigured.call(void 0, )) return false;
|
|
15383
15409
|
const adminRoleId = _chunkJO5BLONKjs.getRoleId.call(void 0, ).Administrator;
|
|
15384
|
-
return !!_optionalChain([currentUser, 'access',
|
|
15410
|
+
return !!_optionalChain([currentUser, 'access', _453 => _453.roles, 'optionalAccess', _454 => _454.some, 'call', _455 => _455((role) => role.id === adminRoleId)]);
|
|
15385
15411
|
}, "isAdministrator");
|
|
15386
15412
|
function useSubscriptionStatus() {
|
|
15387
15413
|
const { company, currentUser } = useCurrentUserContext();
|
|
@@ -15498,7 +15524,7 @@ var useRoleTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0,
|
|
|
15498
15524
|
})
|
|
15499
15525
|
};
|
|
15500
15526
|
const columns = _react.useMemo.call(void 0, () => {
|
|
15501
|
-
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access',
|
|
15527
|
+
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _456 => _456[field], 'optionalCall', _457 => _457()])).filter((col) => col !== void 0);
|
|
15502
15528
|
}, [params.fields, fieldColumnMap, t, generateUrl]);
|
|
15503
15529
|
return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
|
|
15504
15530
|
}, "useRoleTableStructure");
|
|
@@ -15599,11 +15625,11 @@ var useContentTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void
|
|
|
15599
15625
|
return params.fields.map((field) => {
|
|
15600
15626
|
const localHandler = fieldColumnMap[field];
|
|
15601
15627
|
if (localHandler) return localHandler();
|
|
15602
|
-
const customHandler = _optionalChain([params, 'access',
|
|
15628
|
+
const customHandler = _optionalChain([params, 'access', _458 => _458.context, 'optionalAccess', _459 => _459.customCells, 'optionalAccess', _460 => _460[field]]);
|
|
15603
15629
|
if (customHandler) return customHandler({ t });
|
|
15604
15630
|
return void 0;
|
|
15605
15631
|
}).filter((col) => col !== void 0);
|
|
15606
|
-
}, [params.fields, fieldColumnMap, t, generateUrl, _optionalChain([params, 'access',
|
|
15632
|
+
}, [params.fields, fieldColumnMap, t, generateUrl, _optionalChain([params, 'access', _461 => _461.context, 'optionalAccess', _462 => _462.customCells])]);
|
|
15607
15633
|
return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
|
|
15608
15634
|
}, "useContentTableStructure");
|
|
15609
15635
|
|
|
@@ -15938,7 +15964,7 @@ function ContentTableSearch({ data }) {
|
|
|
15938
15964
|
const handleSearchIconClick = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
|
|
15939
15965
|
if (!isExpanded) {
|
|
15940
15966
|
setIsFocused(true);
|
|
15941
|
-
setTimeout(() => _optionalChain([inputRef, 'access',
|
|
15967
|
+
setTimeout(() => _optionalChain([inputRef, 'access', _463 => _463.current, 'optionalAccess', _464 => _464.focus, 'call', _465 => _465()]), 50);
|
|
15942
15968
|
}
|
|
15943
15969
|
}, "handleSearchIconClick");
|
|
15944
15970
|
const handleBlur = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, () => {
|
|
@@ -16015,7 +16041,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
|
|
|
16015
16041
|
props.defaultExpanded === true ? true : typeof props.defaultExpanded === "object" ? props.defaultExpanded : {}
|
|
16016
16042
|
);
|
|
16017
16043
|
const { data: tableData, columns: tableColumns } = useTableGenerator(props.tableGeneratorType, {
|
|
16018
|
-
data: _nullishCoalesce(_optionalChain([data, 'optionalAccess',
|
|
16044
|
+
data: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _466 => _466.data]), () => ( EMPTY_ARRAY)),
|
|
16019
16045
|
fields,
|
|
16020
16046
|
checkedIds,
|
|
16021
16047
|
toggleId,
|
|
@@ -16048,7 +16074,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
|
|
|
16048
16074
|
});
|
|
16049
16075
|
const rowModel = tableData ? table.getRowModel() : null;
|
|
16050
16076
|
const groupedRows = _react.useMemo.call(void 0, () => {
|
|
16051
|
-
if (!props.groupBy || !_optionalChain([rowModel, 'optionalAccess',
|
|
16077
|
+
if (!props.groupBy || !_optionalChain([rowModel, 'optionalAccess', _467 => _467.rows, 'optionalAccess', _468 => _468.length])) return null;
|
|
16052
16078
|
const groupMap = /* @__PURE__ */ new Map();
|
|
16053
16079
|
for (const row of rowModel.rows) {
|
|
16054
16080
|
const keys = getGroupKeys(row.original, props.groupBy);
|
|
@@ -16104,10 +16130,10 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
|
|
|
16104
16130
|
) }),
|
|
16105
16131
|
table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: headerGroup.headers.map((header) => {
|
|
16106
16132
|
const meta = header.column.columnDef.meta;
|
|
16107
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableHead, { className: _optionalChain([meta, 'optionalAccess',
|
|
16133
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableHead, { className: _optionalChain([meta, 'optionalAccess', _469 => _469.className]), children: header.isPlaceholder ? null : _reacttable.flexRender.call(void 0, header.column.columnDef.header, header.getContext()) }, header.id);
|
|
16108
16134
|
}) }, headerGroup.id))
|
|
16109
16135
|
] }),
|
|
16110
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableBody, { children: rowModel && _optionalChain([rowModel, 'access',
|
|
16136
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableBody, { children: rowModel && _optionalChain([rowModel, 'access', _470 => _470.rows, 'optionalAccess', _471 => _471.length]) ? groupedRows ? groupedRows.map((group) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, React.default.Fragment, { children: [
|
|
16111
16137
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
16112
16138
|
TableCell,
|
|
16113
16139
|
{
|
|
@@ -16118,11 +16144,11 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
|
|
|
16118
16144
|
) }),
|
|
16119
16145
|
group.rows.map((row) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: row.getVisibleCells().map((cell) => {
|
|
16120
16146
|
const meta = cell.column.columnDef.meta;
|
|
16121
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess',
|
|
16147
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess', _472 => _472.className]), children: _reacttable.flexRender.call(void 0, cell.column.columnDef.cell, cell.getContext()) }, cell.id);
|
|
16122
16148
|
}) }, row.id))
|
|
16123
16149
|
] }, group.groupKey)) : rowModel.rows.map((row) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: row.getVisibleCells().map((cell) => {
|
|
16124
16150
|
const meta = cell.column.columnDef.meta;
|
|
16125
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess',
|
|
16151
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { className: _optionalChain([meta, 'optionalAccess', _473 => _473.className]), children: _reacttable.flexRender.call(void 0, cell.column.columnDef.cell, cell.getContext()) }, cell.id);
|
|
16126
16152
|
}) }, row.id)) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { colSpan: tableColumns.length, className: "h-24 text-center", children: _nullishCoalesce(props.emptyState, () => ( "No results.")) }) }) }),
|
|
16127
16153
|
showFooter && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableFooter, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableRow, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { colSpan: tableColumns.length, className: "bg-card py-4 text-right", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center justify-end space-x-2", children: [
|
|
16128
16154
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -16132,7 +16158,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
|
|
|
16132
16158
|
size: "sm",
|
|
16133
16159
|
onClick: (e) => {
|
|
16134
16160
|
e.preventDefault();
|
|
16135
|
-
_optionalChain([data, 'access',
|
|
16161
|
+
_optionalChain([data, 'access', _474 => _474.previous, 'optionalCall', _475 => _475(true)]);
|
|
16136
16162
|
},
|
|
16137
16163
|
disabled: !data.previous,
|
|
16138
16164
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ChevronLeft, { className: "h-4 w-4" })
|
|
@@ -16146,7 +16172,7 @@ var ContentListTable = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs
|
|
|
16146
16172
|
size: "sm",
|
|
16147
16173
|
onClick: (e) => {
|
|
16148
16174
|
e.preventDefault();
|
|
16149
|
-
_optionalChain([data, 'access',
|
|
16175
|
+
_optionalChain([data, 'access', _476 => _476.next, 'optionalCall', _477 => _477(true)]);
|
|
16150
16176
|
},
|
|
16151
16177
|
disabled: !data.next,
|
|
16152
16178
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ChevronRight, { className: "h-4 w-4" })
|
|
@@ -16167,7 +16193,7 @@ function ContentListGrid(props) {
|
|
|
16167
16193
|
if (!data.next || !sentinelRef.current) return;
|
|
16168
16194
|
const observer = new IntersectionObserver(
|
|
16169
16195
|
(entries) => {
|
|
16170
|
-
if (_optionalChain([entries, 'access',
|
|
16196
|
+
if (_optionalChain([entries, 'access', _478 => _478[0], 'optionalAccess', _479 => _479.isIntersecting])) _optionalChain([data, 'access', _480 => _480.next, 'optionalCall', _481 => _481()]);
|
|
16171
16197
|
},
|
|
16172
16198
|
{ threshold: 0.1, rootMargin: "200px" }
|
|
16173
16199
|
);
|
|
@@ -16917,7 +16943,7 @@ function TotpInput({ onComplete, disabled = false, autoFocus = true, error }) {
|
|
|
16917
16943
|
newDigits[index] = digit;
|
|
16918
16944
|
setDigits(newDigits);
|
|
16919
16945
|
if (digit && index < 5) {
|
|
16920
|
-
_optionalChain([inputRefs, 'access',
|
|
16946
|
+
_optionalChain([inputRefs, 'access', _482 => _482.current, 'access', _483 => _483[index + 1], 'optionalAccess', _484 => _484.focus, 'call', _485 => _485()]);
|
|
16921
16947
|
}
|
|
16922
16948
|
const code = newDigits.join("");
|
|
16923
16949
|
if (code.length === 6 && newDigits.every((d) => d !== "")) {
|
|
@@ -16926,7 +16952,7 @@ function TotpInput({ onComplete, disabled = false, autoFocus = true, error }) {
|
|
|
16926
16952
|
}, "handleChange");
|
|
16927
16953
|
const handleKeyDown = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (index, e) => {
|
|
16928
16954
|
if (e.key === "Backspace" && !digits[index] && index > 0) {
|
|
16929
|
-
_optionalChain([inputRefs, 'access',
|
|
16955
|
+
_optionalChain([inputRefs, 'access', _486 => _486.current, 'access', _487 => _487[index - 1], 'optionalAccess', _488 => _488.focus, 'call', _489 => _489()]);
|
|
16930
16956
|
}
|
|
16931
16957
|
}, "handleKeyDown");
|
|
16932
16958
|
const handlePaste = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (e) => {
|
|
@@ -16935,7 +16961,7 @@ function TotpInput({ onComplete, disabled = false, autoFocus = true, error }) {
|
|
|
16935
16961
|
if (pastedData.length === 6) {
|
|
16936
16962
|
const newDigits = pastedData.split("");
|
|
16937
16963
|
setDigits(newDigits);
|
|
16938
|
-
_optionalChain([inputRefs, 'access',
|
|
16964
|
+
_optionalChain([inputRefs, 'access', _490 => _490.current, 'access', _491 => _491[5], 'optionalAccess', _492 => _492.focus, 'call', _493 => _493()]);
|
|
16939
16965
|
onComplete(pastedData);
|
|
16940
16966
|
}
|
|
16941
16967
|
}, "handlePaste");
|
|
@@ -17146,8 +17172,8 @@ function PasskeySetupDialog({ open, onOpenChange, onSuccess }) {
|
|
|
17146
17172
|
try {
|
|
17147
17173
|
const registrationData = await _chunkPQBKPWBYjs.TwoFactorService.getPasskeyRegistrationOptions({
|
|
17148
17174
|
id: _uuid.v4.call(void 0, ),
|
|
17149
|
-
userName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess',
|
|
17150
|
-
userDisplayName: _optionalChain([currentUser, 'optionalAccess',
|
|
17175
|
+
userName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _494 => _494.email]), () => ( "")),
|
|
17176
|
+
userDisplayName: _optionalChain([currentUser, 'optionalAccess', _495 => _495.name])
|
|
17151
17177
|
});
|
|
17152
17178
|
const credential = await _browser.startRegistration.call(void 0, { optionsJSON: registrationData.options });
|
|
17153
17179
|
await _chunkPQBKPWBYjs.TwoFactorService.verifyPasskeyRegistration({
|
|
@@ -17298,7 +17324,7 @@ function TotpSetupDialog({ onSuccess, trigger }) {
|
|
|
17298
17324
|
const setup = await _chunkPQBKPWBYjs.TwoFactorService.setupTotp({
|
|
17299
17325
|
id: _uuid.v4.call(void 0, ),
|
|
17300
17326
|
name: name.trim(),
|
|
17301
|
-
accountName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess',
|
|
17327
|
+
accountName: _nullishCoalesce(_optionalChain([currentUser, 'optionalAccess', _496 => _496.email]), () => ( ""))
|
|
17302
17328
|
});
|
|
17303
17329
|
setQrCodeUri(setup.qrCodeUri);
|
|
17304
17330
|
setAuthenticatorId(setup.authenticatorId);
|
|
@@ -17432,7 +17458,7 @@ function TwoFactorSettings() {
|
|
|
17432
17458
|
if (isLoading) {
|
|
17433
17459
|
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") }) }) });
|
|
17434
17460
|
}
|
|
17435
|
-
const isEnabled = _nullishCoalesce(_optionalChain([status, 'optionalAccess',
|
|
17461
|
+
const isEnabled = _nullishCoalesce(_optionalChain([status, 'optionalAccess', _497 => _497.isEnabled]), () => ( false));
|
|
17436
17462
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Card, { children: [
|
|
17437
17463
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, CardHeader, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
|
|
17438
17464
|
isEnabled ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ShieldCheck, { className: "h-6 w-6 text-green-600" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.ShieldAlert, { className: "h-6 w-6 text-yellow-600" }),
|
|
@@ -17470,7 +17496,7 @@ function TwoFactorSettings() {
|
|
|
17470
17496
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "font-medium", children: t("auth.two_factor.backup_codes") }),
|
|
17471
17497
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm text-muted-foreground", children: t("auth.two_factor.backup_codes_description") })
|
|
17472
17498
|
] }),
|
|
17473
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, BackupCodesDialog, { remainingCodes: _nullishCoalesce(_optionalChain([status, 'optionalAccess',
|
|
17499
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, BackupCodesDialog, { remainingCodes: _nullishCoalesce(_optionalChain([status, 'optionalAccess', _498 => _498.backupCodesCount]), () => ( 0)), onRegenerate: handleRefresh })
|
|
17474
17500
|
] }) }),
|
|
17475
17501
|
!isEnabled && (authenticators.length > 0 || passkeys.length > 0) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
17476
17502
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, Separator, {}),
|
|
@@ -17648,9 +17674,9 @@ function AcceptInvitation() {
|
|
|
17648
17674
|
});
|
|
17649
17675
|
const onSubmit = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (values) => {
|
|
17650
17676
|
try {
|
|
17651
|
-
if (!_optionalChain([params, 'optionalAccess',
|
|
17677
|
+
if (!_optionalChain([params, 'optionalAccess', _499 => _499.code])) return;
|
|
17652
17678
|
const payload = {
|
|
17653
|
-
code: _optionalChain([params, 'optionalAccess',
|
|
17679
|
+
code: _optionalChain([params, 'optionalAccess', _500 => _500.code]),
|
|
17654
17680
|
password: values.password
|
|
17655
17681
|
};
|
|
17656
17682
|
await _chunkPQBKPWBYjs.AuthService.acceptInvitation(payload);
|
|
@@ -18000,7 +18026,7 @@ function Logout({ storageKeys }) {
|
|
|
18000
18026
|
const generateUrl = usePageUrlGenerator();
|
|
18001
18027
|
_react.useEffect.call(void 0, () => {
|
|
18002
18028
|
const logOut = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async () => {
|
|
18003
|
-
if (_optionalChain([storageKeys, 'optionalAccess',
|
|
18029
|
+
if (_optionalChain([storageKeys, 'optionalAccess', _501 => _501.length])) {
|
|
18004
18030
|
clearClientStorage(storageKeys);
|
|
18005
18031
|
}
|
|
18006
18032
|
await _chunkPQBKPWBYjs.AuthService.logout();
|
|
@@ -18023,14 +18049,14 @@ function RefreshUser() {
|
|
|
18023
18049
|
setUser(fullUser);
|
|
18024
18050
|
const token = {
|
|
18025
18051
|
userId: fullUser.id,
|
|
18026
|
-
companyId: _optionalChain([fullUser, 'access',
|
|
18052
|
+
companyId: _optionalChain([fullUser, 'access', _502 => _502.company, 'optionalAccess', _503 => _503.id]),
|
|
18027
18053
|
roles: fullUser.roles.map((role) => role.id),
|
|
18028
|
-
features: _nullishCoalesce(_optionalChain([fullUser, 'access',
|
|
18054
|
+
features: _nullishCoalesce(_optionalChain([fullUser, 'access', _504 => _504.company, 'optionalAccess', _505 => _505.features, 'optionalAccess', _506 => _506.map, 'call', _507 => _507((feature) => feature.id)]), () => ( [])),
|
|
18029
18055
|
modules: fullUser.modules.map((module) => {
|
|
18030
18056
|
return { id: module.id, permissions: module.permissions };
|
|
18031
18057
|
})
|
|
18032
18058
|
};
|
|
18033
|
-
await _optionalChain([_chunkPQBKPWBYjs.getTokenHandler.call(void 0, ), 'optionalAccess',
|
|
18059
|
+
await _optionalChain([_chunkPQBKPWBYjs.getTokenHandler.call(void 0, ), 'optionalAccess', _508 => _508.updateToken, 'call', _509 => _509(token)]);
|
|
18034
18060
|
_cookiesnext.deleteCookie.call(void 0, "reloadData");
|
|
18035
18061
|
}
|
|
18036
18062
|
}, "loadFullUser");
|
|
@@ -18094,9 +18120,9 @@ function ResetPassword() {
|
|
|
18094
18120
|
});
|
|
18095
18121
|
const onSubmit = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, async (values) => {
|
|
18096
18122
|
try {
|
|
18097
|
-
if (!_optionalChain([params, 'optionalAccess',
|
|
18123
|
+
if (!_optionalChain([params, 'optionalAccess', _510 => _510.code])) return;
|
|
18098
18124
|
const payload = {
|
|
18099
|
-
code: _optionalChain([params, 'optionalAccess',
|
|
18125
|
+
code: _optionalChain([params, 'optionalAccess', _511 => _511.code]),
|
|
18100
18126
|
password: values.password
|
|
18101
18127
|
};
|
|
18102
18128
|
await _chunkPQBKPWBYjs.AuthService.resetPassword(payload);
|
|
@@ -18445,7 +18471,7 @@ function extractHeadings(blocks) {
|
|
|
18445
18471
|
function processBlocks(blockArray) {
|
|
18446
18472
|
for (const block of blockArray) {
|
|
18447
18473
|
if (block.type === "heading") {
|
|
18448
|
-
const level = _optionalChain([block, 'access',
|
|
18474
|
+
const level = _optionalChain([block, 'access', _512 => _512.props, 'optionalAccess', _513 => _513.level]) || 1;
|
|
18449
18475
|
const text = extractTextFromContent(block.content);
|
|
18450
18476
|
if (text.trim()) {
|
|
18451
18477
|
headings.push({
|
|
@@ -18788,7 +18814,7 @@ var useHowToTableStructure = /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0
|
|
|
18788
18814
|
})
|
|
18789
18815
|
};
|
|
18790
18816
|
const columns = _react.useMemo.call(void 0, () => {
|
|
18791
|
-
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access',
|
|
18817
|
+
return params.fields.map((field) => _optionalChain([fieldColumnMap, 'access', _514 => _514[field], 'optionalCall', _515 => _515()])).filter((col) => col !== void 0);
|
|
18792
18818
|
}, [params.fields, fieldColumnMap, t, generateUrl]);
|
|
18793
18819
|
return _react.useMemo.call(void 0, () => ({ data: tableData, columns }), [tableData, columns]);
|
|
18794
18820
|
}, "useHowToTableStructure");
|
|
@@ -18887,7 +18913,7 @@ function HowToSelector({
|
|
|
18887
18913
|
}, "setHowTo");
|
|
18888
18914
|
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: [
|
|
18889
18915
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-row items-center justify-between", children: [
|
|
18890
|
-
/* @__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',
|
|
18916
|
+
/* @__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', _516 => _516.value, 'optionalAccess', _517 => _517.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 }) }))) }) }) }),
|
|
18891
18917
|
field.value && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
18892
18918
|
_lucidereact.CircleX,
|
|
18893
18919
|
{
|
|
@@ -19256,9 +19282,9 @@ function CitationsTab({ citations, sources }) {
|
|
|
19256
19282
|
] }) }),
|
|
19257
19283
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableBody, { children: sorted.map((chunk) => {
|
|
19258
19284
|
const isOpen = expanded.has(chunk.id);
|
|
19259
|
-
const resolved = chunk.nodeId ? _optionalChain([sources, 'optionalAccess',
|
|
19285
|
+
const resolved = chunk.nodeId ? _optionalChain([sources, 'optionalAccess', _518 => _518.get, 'call', _519 => _519(chunk.nodeId)]) : void 0;
|
|
19260
19286
|
const fallbackName = chunk.nodeId ? `${_nullishCoalesce(chunk.nodeType, () => ( t("features.assistant.message.sources.source")))} ${chunk.nodeId.slice(0, 8)}` : _nullishCoalesce(chunk.nodeType, () => ( t("features.assistant.message.sources.source")));
|
|
19261
|
-
const sourceName = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess',
|
|
19287
|
+
const sourceName = _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _520 => _520.name]), () => ( fallbackName));
|
|
19262
19288
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react.Fragment, { children: [
|
|
19263
19289
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, TableRow, { children: [
|
|
19264
19290
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TableCell, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
@@ -19305,7 +19331,7 @@ function ContentsTab({ citations, sources }) {
|
|
|
19305
19331
|
for (const c of citations) {
|
|
19306
19332
|
const id = c.nodeId;
|
|
19307
19333
|
if (!id) continue;
|
|
19308
|
-
const source = _optionalChain([sources, 'optionalAccess',
|
|
19334
|
+
const source = _optionalChain([sources, 'optionalAccess', _521 => _521.get, 'call', _522 => _522(id)]);
|
|
19309
19335
|
if (!source) continue;
|
|
19310
19336
|
const existing = map.get(id);
|
|
19311
19337
|
if (existing) {
|
|
@@ -19372,7 +19398,7 @@ function UsersTab({ users, citations, sources }) {
|
|
|
19372
19398
|
const generate = usePageUrlGenerator();
|
|
19373
19399
|
const userMap = /* @__PURE__ */ new Map();
|
|
19374
19400
|
for (const u of users) {
|
|
19375
|
-
if (!_optionalChain([u, 'optionalAccess',
|
|
19401
|
+
if (!_optionalChain([u, 'optionalAccess', _523 => _523.id])) continue;
|
|
19376
19402
|
userMap.set(u.id, { user: u, contentCount: 0, citationCount: 0 });
|
|
19377
19403
|
}
|
|
19378
19404
|
if (citations && sources) {
|
|
@@ -19477,7 +19503,7 @@ function MessageSourcesPanel({ message, isLatestAssistant, onSelectFollowUp, sou
|
|
|
19477
19503
|
}
|
|
19478
19504
|
return ids.size;
|
|
19479
19505
|
}, [message.citations, sources]);
|
|
19480
|
-
const usersCount = _nullishCoalesce(_optionalChain([users, 'optionalAccess',
|
|
19506
|
+
const usersCount = _nullishCoalesce(_optionalChain([users, 'optionalAccess', _524 => _524.length]), () => ( 0));
|
|
19481
19507
|
const total = refsCount + citationsCount + contentsCount + usersCount + suggestionsCount;
|
|
19482
19508
|
const visibleTabs = [];
|
|
19483
19509
|
if (suggestionsCount > 0) visibleTabs.push("suggested");
|
|
@@ -19537,8 +19563,8 @@ var SourcesFetcher = class extends _chunkPQBKPWBYjs.ClientAbstractService {
|
|
|
19537
19563
|
const endpoint = new (0, _chunkPQBKPWBYjs.EndpointCreator)({ endpoint: params.module });
|
|
19538
19564
|
endpoint.addAdditionalParam(params.idsParam, params.ids.join(","));
|
|
19539
19565
|
endpoint.addAdditionalParam("fetchAll", "true");
|
|
19540
|
-
if (_optionalChain([params, 'access',
|
|
19541
|
-
if (_optionalChain([params, 'access',
|
|
19566
|
+
if (_optionalChain([params, 'access', _525 => _525.module, 'access', _526 => _526.inclusions, 'optionalAccess', _527 => _527.lists, 'optionalAccess', _528 => _528.fields])) endpoint.limitToFields(params.module.inclusions.lists.fields);
|
|
19567
|
+
if (_optionalChain([params, 'access', _529 => _529.module, 'access', _530 => _530.inclusions, 'optionalAccess', _531 => _531.lists, 'optionalAccess', _532 => _532.types])) endpoint.limitToType(params.module.inclusions.lists.types);
|
|
19542
19568
|
return this.callApi({
|
|
19543
19569
|
type: params.module,
|
|
19544
19570
|
method: "GET" /* GET */,
|
|
@@ -19617,7 +19643,7 @@ function MessageSourcesContainer({ message, isLatestAssistant, onSelectFollowUp
|
|
|
19617
19643
|
return void 0;
|
|
19618
19644
|
}
|
|
19619
19645
|
})()));
|
|
19620
|
-
if (_optionalChain([author, 'optionalAccess',
|
|
19646
|
+
if (_optionalChain([author, 'optionalAccess', _533 => _533.id])) userMap.set(author.id, author);
|
|
19621
19647
|
}
|
|
19622
19648
|
return Array.from(userMap.values());
|
|
19623
19649
|
}, [resolved]);
|
|
@@ -19646,14 +19672,14 @@ function MessageItem({
|
|
|
19646
19672
|
}) {
|
|
19647
19673
|
const t = _nextintl.useTranslations.call(void 0, );
|
|
19648
19674
|
const isUser = message.role === "user";
|
|
19649
|
-
const isFailed = isUser && !!_optionalChain([failedMessageIds, 'optionalAccess',
|
|
19675
|
+
const isFailed = isUser && !!_optionalChain([failedMessageIds, 'optionalAccess', _534 => _534.has, 'call', _535 => _535(message.id)]);
|
|
19650
19676
|
if (isUser) {
|
|
19651
19677
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col items-end gap-1", children: [
|
|
19652
19678
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "bg-primary text-primary-foreground max-w-[72%] rounded-2xl rounded-br-sm px-3.5 py-2 text-sm", children: message.content }),
|
|
19653
19679
|
isFailed && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "text-destructive flex items-center gap-2 text-xs", children: [
|
|
19654
19680
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.AlertCircle, { className: "h-3.5 w-3.5" }),
|
|
19655
19681
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: t("features.assistant.send_failed") }),
|
|
19656
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { type: "button", className: "underline", onClick: () => _optionalChain([onRetry, 'optionalCall',
|
|
19682
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { type: "button", className: "underline", onClick: () => _optionalChain([onRetry, 'optionalCall', _536 => _536(message.id)]), children: t("features.assistant.retry") })
|
|
19657
19683
|
] })
|
|
19658
19684
|
] });
|
|
19659
19685
|
}
|
|
@@ -19729,7 +19755,7 @@ function AssistantThread({
|
|
|
19729
19755
|
}) {
|
|
19730
19756
|
const endRef = _react.useRef.call(void 0, null);
|
|
19731
19757
|
_react.useEffect.call(void 0, () => {
|
|
19732
|
-
_optionalChain([endRef, 'access',
|
|
19758
|
+
_optionalChain([endRef, 'access', _537 => _537.current, 'optionalAccess', _538 => _538.scrollIntoView, 'call', _539 => _539({ behavior: "smooth" })]);
|
|
19733
19759
|
}, [messages.length, sending]);
|
|
19734
19760
|
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: [
|
|
19735
19761
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -19758,7 +19784,7 @@ function AssistantContainer({ renderApprovalAction } = {}) {
|
|
|
19758
19784
|
AssistantSidebar,
|
|
19759
19785
|
{
|
|
19760
19786
|
threads: ctx.threads,
|
|
19761
|
-
activeId: _optionalChain([ctx, 'access',
|
|
19787
|
+
activeId: _optionalChain([ctx, 'access', _540 => _540.assistant, 'optionalAccess', _541 => _541.id]),
|
|
19762
19788
|
onSelect: ctx.selectThread,
|
|
19763
19789
|
onNew: ctx.startNew
|
|
19764
19790
|
}
|
|
@@ -19859,14 +19885,14 @@ function NotificationsList({ archived }) {
|
|
|
19859
19885
|
] }),
|
|
19860
19886
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, Skeleton, { className: "h-8 w-20" })
|
|
19861
19887
|
] }) }) }, i)) }), "LoadingSkeleton");
|
|
19862
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "space-y-4", children: data.isLoaded ? _optionalChain([data, 'access',
|
|
19888
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "space-y-4", children: data.isLoaded ? _optionalChain([data, 'access', _542 => _542.data, 'optionalAccess', _543 => _543.map, 'call', _544 => _544((notification) => {
|
|
19863
19889
|
const notificationData = generateNotificationData({ notification, generateUrl });
|
|
19864
19890
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Card, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, CardContent, { className: "p-0", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: `flex w-full flex-row items-center p-2`, children: [
|
|
19865
19891
|
notificationData.actor ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-12 max-w-12 px-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Link, { href: generateUrl({ page: _chunkPQBKPWBYjs.Modules.User, id: notificationData.actor.id }), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, UserAvatar, { user: notificationData.actor, className: "h-8 w-8" }) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-14 max-w-14 px-2" }),
|
|
19866
19892
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col", children: [
|
|
19867
19893
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm", children: t.rich(`notification.${notification.notificationType}.description`, {
|
|
19868
19894
|
strong: /* @__PURE__ */ _chunk7QVYU63Ejs.__name.call(void 0, (chunks) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: chunks }), "strong"),
|
|
19869
|
-
actor: _nullishCoalesce(_optionalChain([notificationData, 'access',
|
|
19895
|
+
actor: _nullishCoalesce(_optionalChain([notificationData, 'access', _545 => _545.actor, 'optionalAccess', _546 => _546.name]), () => ( "")),
|
|
19870
19896
|
title: notificationData.title
|
|
19871
19897
|
}) }),
|
|
19872
19898
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "text-muted-foreground mt-1 w-full text-xs", children: new Date(notification.createdAt).toLocaleString() })
|
|
@@ -20212,7 +20238,7 @@ var DEFAULT_TRANSLATIONS = {
|
|
|
20212
20238
|
invalidEmail: "Please enter a valid email address"
|
|
20213
20239
|
};
|
|
20214
20240
|
async function copyToClipboard(text) {
|
|
20215
|
-
if (_optionalChain([navigator, 'access',
|
|
20241
|
+
if (_optionalChain([navigator, 'access', _547 => _547.clipboard, 'optionalAccess', _548 => _548.writeText])) {
|
|
20216
20242
|
try {
|
|
20217
20243
|
await navigator.clipboard.writeText(text);
|
|
20218
20244
|
return true;
|
|
@@ -20254,7 +20280,7 @@ function ReferralWidget({
|
|
|
20254
20280
|
const linkInputRef = _react.useRef.call(void 0, null);
|
|
20255
20281
|
const config = _chunkJO5BLONKjs.getReferralConfig.call(void 0, );
|
|
20256
20282
|
const baseUrl = config.referralUrlBase || (typeof window !== "undefined" ? window.location.origin : "");
|
|
20257
|
-
const referralUrl = _optionalChain([stats, 'optionalAccess',
|
|
20283
|
+
const referralUrl = _optionalChain([stats, 'optionalAccess', _549 => _549.referralCode]) ? `${baseUrl}${config.referralPath}?${config.urlParamName}=${stats.referralCode}` : "";
|
|
20258
20284
|
if (!_chunkJO5BLONKjs.isReferralEnabled.call(void 0, )) {
|
|
20259
20285
|
return null;
|
|
20260
20286
|
}
|
|
@@ -20264,7 +20290,7 @@ function ReferralWidget({
|
|
|
20264
20290
|
if (success) {
|
|
20265
20291
|
setCopied(true);
|
|
20266
20292
|
_chunkPQBKPWBYjs.showToast.call(void 0, t.copiedMessage);
|
|
20267
|
-
_optionalChain([onLinkCopied, 'optionalCall',
|
|
20293
|
+
_optionalChain([onLinkCopied, 'optionalCall', _550 => _550()]);
|
|
20268
20294
|
setTimeout(() => setCopied(false), 2e3);
|
|
20269
20295
|
} else {
|
|
20270
20296
|
_chunkPQBKPWBYjs.showError.call(void 0, t.copyError);
|
|
@@ -20278,12 +20304,12 @@ function ReferralWidget({
|
|
|
20278
20304
|
try {
|
|
20279
20305
|
await sendInvite(email);
|
|
20280
20306
|
_chunkPQBKPWBYjs.showToast.call(void 0, t.inviteSent);
|
|
20281
|
-
_optionalChain([onInviteSent, 'optionalCall',
|
|
20307
|
+
_optionalChain([onInviteSent, 'optionalCall', _551 => _551(email)]);
|
|
20282
20308
|
setEmail("");
|
|
20283
20309
|
} catch (err) {
|
|
20284
20310
|
const error2 = err instanceof Error ? err : new Error(t.inviteError);
|
|
20285
20311
|
_chunkPQBKPWBYjs.showError.call(void 0, error2.message);
|
|
20286
|
-
_optionalChain([onInviteError, 'optionalCall',
|
|
20312
|
+
_optionalChain([onInviteError, 'optionalCall', _552 => _552(error2)]);
|
|
20287
20313
|
}
|
|
20288
20314
|
}, [email, sendInvite, t.inviteSent, t.inviteError, t.invalidEmail, onInviteSent, onInviteError]);
|
|
20289
20315
|
const handleEmailKeyDown = _react.useCallback.call(void 0,
|
|
@@ -21037,7 +21063,7 @@ function OAuthClientList({
|
|
|
21037
21063
|
OAuthClientCard,
|
|
21038
21064
|
{
|
|
21039
21065
|
client,
|
|
21040
|
-
onClick: () => _optionalChain([onClientClick, 'optionalCall',
|
|
21066
|
+
onClick: () => _optionalChain([onClientClick, 'optionalCall', _553 => _553(client)]),
|
|
21041
21067
|
onEdit: onEditClick ? () => onEditClick(client) : void 0,
|
|
21042
21068
|
onDelete: onDeleteClick ? () => onDeleteClick(client) : void 0
|
|
21043
21069
|
},
|
|
@@ -21053,11 +21079,11 @@ _chunk7QVYU63Ejs.__name.call(void 0, OAuthClientList, "OAuthClientList");
|
|
|
21053
21079
|
function OAuthClientForm({ client, onSubmit, onCancel, isLoading = false }) {
|
|
21054
21080
|
const isEditMode = !!client;
|
|
21055
21081
|
const [formState, setFormState] = _react.useState.call(void 0, {
|
|
21056
|
-
name: _optionalChain([client, 'optionalAccess',
|
|
21057
|
-
description: _optionalChain([client, 'optionalAccess',
|
|
21058
|
-
redirectUris: _optionalChain([client, 'optionalAccess',
|
|
21059
|
-
allowedScopes: _optionalChain([client, 'optionalAccess',
|
|
21060
|
-
isConfidential: _nullishCoalesce(_optionalChain([client, 'optionalAccess',
|
|
21082
|
+
name: _optionalChain([client, 'optionalAccess', _554 => _554.name]) || "",
|
|
21083
|
+
description: _optionalChain([client, 'optionalAccess', _555 => _555.description]) || "",
|
|
21084
|
+
redirectUris: _optionalChain([client, 'optionalAccess', _556 => _556.redirectUris, 'optionalAccess', _557 => _557.length]) ? client.redirectUris : [""],
|
|
21085
|
+
allowedScopes: _optionalChain([client, 'optionalAccess', _558 => _558.allowedScopes]) || [],
|
|
21086
|
+
isConfidential: _nullishCoalesce(_optionalChain([client, 'optionalAccess', _559 => _559.isConfidential]), () => ( true))
|
|
21061
21087
|
});
|
|
21062
21088
|
const [errors, setErrors] = _react.useState.call(void 0, {});
|
|
21063
21089
|
const validate = _react.useCallback.call(void 0, () => {
|
|
@@ -21285,7 +21311,7 @@ function OAuthClientDetail({
|
|
|
21285
21311
|
] }),
|
|
21286
21312
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
|
|
21287
21313
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, Label, { children: "Allowed Scopes" }),
|
|
21288
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex flex-wrap gap-2", children: client.allowedScopes.map((scope) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "secondary", children: _optionalChain([_chunkPQBKPWBYjs.OAUTH_SCOPE_DISPLAY, 'access',
|
|
21314
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex flex-wrap gap-2", children: client.allowedScopes.map((scope) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Badge, { variant: "secondary", children: _optionalChain([_chunkPQBKPWBYjs.OAUTH_SCOPE_DISPLAY, 'access', _560 => _560[scope], 'optionalAccess', _561 => _561.name]) || scope }, scope)) })
|
|
21289
21315
|
] }),
|
|
21290
21316
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-2", children: [
|
|
21291
21317
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, Label, { children: "Grant Types" }),
|
|
@@ -21429,7 +21455,7 @@ function OAuthConsentScreen({
|
|
|
21429
21455
|
if (error || !clientInfo) {
|
|
21430
21456
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "min-h-screen 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: [
|
|
21431
21457
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _lucidereact.AlertTriangle, { className: "h-4 w-4" }),
|
|
21432
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AlertDescription, { children: _optionalChain([error, 'optionalAccess',
|
|
21458
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, AlertDescription, { children: _optionalChain([error, 'optionalAccess', _562 => _562.message]) || "Invalid authorization request. Please try again." })
|
|
21433
21459
|
] }) }) }) });
|
|
21434
21460
|
}
|
|
21435
21461
|
const { client, scopes } = clientInfo;
|
|
@@ -21645,7 +21671,7 @@ function WaitlistForm({ onSuccess }) {
|
|
|
21645
21671
|
questionnaire: values.questionnaire
|
|
21646
21672
|
});
|
|
21647
21673
|
setIsSuccess(true);
|
|
21648
|
-
_optionalChain([onSuccess, 'optionalCall',
|
|
21674
|
+
_optionalChain([onSuccess, 'optionalCall', _563 => _563()]);
|
|
21649
21675
|
} catch (e) {
|
|
21650
21676
|
errorToast({ error: e });
|
|
21651
21677
|
} finally {
|
|
@@ -22283,7 +22309,7 @@ var ModuleEditor = _react.memo.call(void 0, /* @__PURE__ */ _chunk7QVYU63Ejs.__n
|
|
|
22283
22309
|
] }),
|
|
22284
22310
|
roleIds.map((roleId) => {
|
|
22285
22311
|
const roleTokens = block[roleId];
|
|
22286
|
-
const roleLabel = _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess',
|
|
22312
|
+
const roleLabel = _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _564 => _564[roleId]]), () => ( roleId));
|
|
22287
22313
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: "border-b last:border-b-0", children: [
|
|
22288
22314
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-4 py-1 text-xs font-medium text-muted-foreground", children: roleLabel }),
|
|
22289
22315
|
_chunkJO5BLONKjs.ACTION_TYPES.map((action) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-2 py-1", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -22320,7 +22346,7 @@ function RbacContainer() {
|
|
|
22320
22346
|
}, []);
|
|
22321
22347
|
const sortedModuleIds = _react.useMemo.call(void 0, () => {
|
|
22322
22348
|
if (!matrix) return [];
|
|
22323
|
-
return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess',
|
|
22349
|
+
return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _565 => _565[a]]), () => ( a))).localeCompare(_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _566 => _566[b]]), () => ( b))));
|
|
22324
22350
|
}, [matrix, moduleNames]);
|
|
22325
22351
|
const roleIds = _react.useMemo.call(void 0, () => {
|
|
22326
22352
|
if (roleNames) {
|
|
@@ -22383,7 +22409,7 @@ function RbacContainer() {
|
|
|
22383
22409
|
id === selectedModuleId && "bg-muted font-medium text-foreground",
|
|
22384
22410
|
id !== selectedModuleId && "text-muted-foreground"
|
|
22385
22411
|
),
|
|
22386
|
-
children: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess',
|
|
22412
|
+
children: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _567 => _567[id]]), () => ( id))
|
|
22387
22413
|
}
|
|
22388
22414
|
) }, id)) }) }),
|
|
22389
22415
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "section", { className: "flex-1 overflow-y-auto p-4", children: selectedModuleId && selectedBlock ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -22391,7 +22417,7 @@ function RbacContainer() {
|
|
|
22391
22417
|
{
|
|
22392
22418
|
moduleId: selectedModuleId,
|
|
22393
22419
|
block: selectedBlock,
|
|
22394
|
-
moduleLabel: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess',
|
|
22420
|
+
moduleLabel: _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _568 => _568[selectedModuleId]]), () => ( selectedModuleId)),
|
|
22395
22421
|
roleIds,
|
|
22396
22422
|
roleNames,
|
|
22397
22423
|
onOpenPicker: openPicker
|
|
@@ -22402,12 +22428,12 @@ function RbacContainer() {
|
|
|
22402
22428
|
RbacPermissionPicker,
|
|
22403
22429
|
{
|
|
22404
22430
|
open: !!activePicker,
|
|
22405
|
-
anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess',
|
|
22431
|
+
anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _569 => _569.anchor]), () => ( null)),
|
|
22406
22432
|
value: activeValue,
|
|
22407
|
-
isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess',
|
|
22433
|
+
isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _570 => _570.isRoleColumn]), () => ( false)),
|
|
22408
22434
|
knownSegments: activeSegments,
|
|
22409
22435
|
onSetValue: handleSetValue,
|
|
22410
|
-
onClear: _optionalChain([activePicker, 'optionalAccess',
|
|
22436
|
+
onClear: _optionalChain([activePicker, 'optionalAccess', _571 => _571.isRoleColumn]) ? handleClear : void 0,
|
|
22411
22437
|
onClose: closePicker
|
|
22412
22438
|
}
|
|
22413
22439
|
)
|
|
@@ -22474,7 +22500,7 @@ function RbacByRoleContainer() {
|
|
|
22474
22500
|
}, [roleNames]);
|
|
22475
22501
|
const sortedModuleIds = _react.useMemo.call(void 0, () => {
|
|
22476
22502
|
if (!matrix) return [];
|
|
22477
|
-
return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess',
|
|
22503
|
+
return Object.keys(matrix).sort((a, b) => (_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _572 => _572[a]]), () => ( a))).localeCompare(_nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _573 => _573[b]]), () => ( b))));
|
|
22478
22504
|
}, [matrix, moduleNames]);
|
|
22479
22505
|
_react.useEffect.call(void 0, () => {
|
|
22480
22506
|
if (!selectedRoleId && sortedRoleIds.length > 0) {
|
|
@@ -22523,7 +22549,7 @@ function RbacByRoleContainer() {
|
|
|
22523
22549
|
id === selectedRoleId && "bg-muted font-medium text-foreground",
|
|
22524
22550
|
id !== selectedRoleId && "text-muted-foreground"
|
|
22525
22551
|
),
|
|
22526
|
-
children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess',
|
|
22552
|
+
children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _574 => _574[id]]), () => ( id))
|
|
22527
22553
|
}
|
|
22528
22554
|
) }, id)) }) }),
|
|
22529
22555
|
/* @__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: [
|
|
@@ -22543,7 +22569,7 @@ function RbacByRoleContainer() {
|
|
|
22543
22569
|
if (!block) return null;
|
|
22544
22570
|
const defaultTokens = _nullishCoalesce(block.default, () => ( []));
|
|
22545
22571
|
const roleTokens = block[selectedRoleId];
|
|
22546
|
-
const moduleLabel = _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess',
|
|
22572
|
+
const moduleLabel = _nullishCoalesce(_optionalChain([moduleNames, 'optionalAccess', _575 => _575[moduleId]]), () => ( moduleId));
|
|
22547
22573
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react.Fragment, { children: [
|
|
22548
22574
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { className: "border-b bg-muted/40", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
22549
22575
|
"td",
|
|
@@ -22558,7 +22584,7 @@ function RbacByRoleContainer() {
|
|
|
22558
22584
|
_chunkJO5BLONKjs.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))
|
|
22559
22585
|
] }),
|
|
22560
22586
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: "border-b last:border-b-0", children: [
|
|
22561
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-4 py-1 text-xs font-medium text-muted-foreground", children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess',
|
|
22587
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-4 py-1 text-xs font-medium text-muted-foreground", children: _nullishCoalesce(_optionalChain([roleNames, 'optionalAccess', _576 => _576[selectedRoleId]]), () => ( selectedRoleId)) }),
|
|
22562
22588
|
_chunkJO5BLONKjs.ACTION_TYPES.map((action) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: "px-2 py-1", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
22563
22589
|
CellButton3,
|
|
22564
22590
|
{
|
|
@@ -22579,12 +22605,12 @@ function RbacByRoleContainer() {
|
|
|
22579
22605
|
RbacPermissionPicker,
|
|
22580
22606
|
{
|
|
22581
22607
|
open: !!activePicker,
|
|
22582
|
-
anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess',
|
|
22608
|
+
anchor: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _577 => _577.anchor]), () => ( null)),
|
|
22583
22609
|
value: activeValue,
|
|
22584
|
-
isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess',
|
|
22610
|
+
isRoleColumn: _nullishCoalesce(_optionalChain([activePicker, 'optionalAccess', _578 => _578.isRoleColumn]), () => ( false)),
|
|
22585
22611
|
knownSegments: activeSegments,
|
|
22586
22612
|
onSetValue: handleSetValue,
|
|
22587
|
-
onClear: _optionalChain([activePicker, 'optionalAccess',
|
|
22613
|
+
onClear: _optionalChain([activePicker, 'optionalAccess', _579 => _579.isRoleColumn]) ? handleClear : void 0,
|
|
22588
22614
|
onClose: closePicker
|
|
22589
22615
|
}
|
|
22590
22616
|
)
|
|
@@ -23119,4 +23145,4 @@ _chunk7QVYU63Ejs.__name.call(void 0, RbacByRoleContainer, "RbacByRoleContainer")
|
|
|
23119
23145
|
|
|
23120
23146
|
|
|
23121
23147
|
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.SocketContext = SocketContext; exports.SocketProvider = SocketProvider; exports.useSocketContext = useSocketContext; exports.CurrentUserProvider = CurrentUserProvider; exports.useCurrentUserContext = useCurrentUserContext; 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.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.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.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.Input = Input; 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.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.Label = Label; 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.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.errorToast = errorToast; exports.EditableAvatar = EditableAvatar; exports.TableCellAvatar = TableCellAvatar; exports.HeaderChildrenProvider = HeaderChildrenProvider; exports.useHeaderChildren = useHeaderChildren; exports.HeaderLeftContentProvider = HeaderLeftContentProvider; exports.useHeaderLeftContent = useHeaderLeftContent; exports.BreadcrumbNavigation = BreadcrumbNavigation; exports.ContentTitle = ContentTitle; exports.SharedProvider = SharedProvider; exports.useSharedContext = useSharedContext; exports.Header = Header; exports.ModeToggleSwitch = ModeToggleSwitch; exports.PageSection = PageSection; exports.recentPagesAtom = recentPagesAtom; exports.RecentPagesNavigator = RecentPagesNavigator; exports.PageContainer = PageContainer; exports.partitionTabs = partitionTabs; exports.ReactMarkdownContainer = ReactMarkdownContainer; exports.RoundPageContainerTitle = RoundPageContainerTitle; exports.RoundPageContainer = RoundPageContainer; exports.TabsContainer = TabsContainer; exports.AttributeElement = AttributeElement; exports.AllUsersListContainer = AllUsersListContainer; 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.CommonAssociationTrigger = CommonAssociationTrigger; exports.CommonAssociationCommandDialog = CommonAssociationCommandDialog; exports.triggerAssociationToast = triggerAssociationToast; exports.FormFieldWrapper = FormFieldWrapper; exports.EntityMultiSelector = EntityMultiSelector; exports.CommonDeleter = CommonDeleter; exports.CommonEditorButtons = CommonEditorButtons; exports.CommonEditorHeader = CommonEditorHeader; exports.CommonEditorDiscardDialog = CommonEditorDiscardDialog; exports.CommonEditorTrigger = CommonEditorTrigger; exports.CommonAddTrigger = CommonAddTrigger; exports.useEditorDialog = useEditorDialog; exports.EditorSheet = EditorSheet; exports.DatePickerPopover = DatePickerPopover; exports.DateRangeSelector = DateRangeSelector; exports.useFileUpload = useFileUpload; exports.FileUploader = FileUploader; exports.FileUploaderContent = FileUploaderContent; exports.FileUploaderItem = FileUploaderItem; exports.FileInput = FileInput; exports.CurrencyInput = CurrencyInput; exports.FormCheckbox = FormCheckbox; exports.FormBlockNote = FormBlockNote; exports.FormDate = FormDate; exports.FormDateTime = FormDateTime; exports.FormInput = FormInput; 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.FormFeatures = FormFeatures; 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.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.CompanyContent = CompanyContent; exports.TokenStatusIndicator = TokenStatusIndicator; exports.CompanyDetails = CompanyDetails; exports.AdminCompanyContainer = AdminCompanyContainer; exports.CompanyContainer = CompanyContainer; exports.CompanyConfigurationEditor = CompanyConfigurationEditor; exports.CompanyDeleter = CompanyDeleter; exports.CompanyEditor = CompanyEditor; exports.CompaniesList = CompaniesList; exports.ContentsList = ContentsList; exports.ContentsListById = ContentsListById; exports.RelevantContentsList = RelevantContentsList; 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.HowToList = HowToList; exports.HowToListContainer = HowToListContainer; exports.HowToSelector = HowToSelector; exports.AssistantProvider = AssistantProvider; exports.useAssistantContext = useAssistantContext; exports.AssistantComposer = AssistantComposer; exports.AssistantEmptyState = AssistantEmptyState; exports.MessageSourcesPanel = MessageSourcesPanel; exports.MessageItem = MessageItem; exports.MessageList = MessageList; exports.AssistantThread = AssistantThread; exports.AssistantContainer = AssistantContainer; exports.NotificationErrorBoundary = NotificationErrorBoundary; exports.generateNotificationData = generateNotificationData; exports.NotificationToast = NotificationToast; exports.NotificationMenuItem = NotificationMenuItem; exports.NotificationContextProvider = NotificationContextProvider; exports.useNotificationContext = useNotificationContext; exports.NotificationsList = NotificationsList; exports.NotificationsListContainer = NotificationsListContainer; exports.NotificationModal = NotificationModal; exports.PushNotificationProvider = PushNotificationProvider; exports.OnboardingCard = OnboardingCard; exports.ReferralCodeCapture = ReferralCodeCapture; exports.ReferralWidget = ReferralWidget; exports.ReferralDialog = ReferralDialog; 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.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.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.OnboardingProvider = OnboardingProvider; exports.useOnboarding = useOnboarding; exports.CommonProvider = CommonProvider; exports.useCommonContext = useCommonContext; exports.useNotificationSync = useNotificationSync; exports.usePageTracker = usePageTracker; exports.useSocket = useSocket; exports.useSubscriptionStatus = useSubscriptionStatus; exports.useContentTableStructure = useContentTableStructure; exports.useOAuthClients = useOAuthClients; exports.useOAuthClient = useOAuthClient;
|
|
23122
|
-
//# sourceMappingURL=chunk-
|
|
23148
|
+
//# sourceMappingURL=chunk-NHTN4LWQ.js.map
|