@overmap-ai/blocks 1.0.6 → 1.0.7
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/README.md +3 -3
- package/dist/BaseMenuGroups/BaseItemGroup/BaseItemGroup.d.ts +3 -0
- package/dist/BaseMenuGroups/BaseItemGroup/index.d.ts +2 -0
- package/dist/BaseMenuGroups/BaseItemGroup/typings.d.ts +11 -0
- package/dist/BaseMenuGroups/BaseMenuComponents.d.ts +11 -0
- package/dist/BaseMenuGroups/BaseMultiSelectGroup/BaseMultiSelectGroup.d.ts +3 -0
- package/dist/BaseMenuGroups/BaseMultiSelectGroup/index.d.ts +2 -0
- package/dist/BaseMenuGroups/BaseMultiSelectGroup/typings.d.ts +16 -0
- package/dist/BaseMenuGroups/BaseSelectGroup/BaseSelectGroup.d.ts +3 -0
- package/dist/BaseMenuGroups/BaseSelectGroup/index.d.ts +2 -0
- package/dist/BaseMenuGroups/BaseSelectGroup/typings.d.ts +16 -0
- package/dist/BaseMenuGroups/BaseSubMenuGroup/BaseSubMenuGroup.d.ts +3 -0
- package/dist/BaseMenuGroups/BaseSubMenuGroup/index.d.ts +2 -0
- package/dist/BaseMenuGroups/BaseSubMenuGroup/typings.d.ts +14 -0
- package/dist/BaseMenuGroups/index.d.ts +5 -0
- package/dist/BaseMenuGroups/typings.d.ts +37 -0
- package/dist/BaseMenuGroups/utils.d.ts +5 -0
- package/dist/Dialogs/Dialog/index.d.ts +1 -0
- package/dist/Dialogs/Dialog/utils.d.ts +7 -0
- package/dist/DropdownItemMenu/DropdownItemMenu.d.ts +9 -0
- package/dist/DropdownItemMenu/index.d.ts +2 -0
- package/dist/DropdownMenu/DropdownMenu.d.ts +5 -17
- package/dist/DropdownMenu/DropdownMenuGroups.d.ts +18 -0
- package/dist/DropdownMenu/index.d.ts +2 -0
- package/dist/DropdownMultiSelect/DropdownMultiSelect.d.ts +6 -0
- package/dist/DropdownMultiSelect/index.d.ts +2 -0
- package/dist/DropdownSelect/DropdownSelect.d.ts +5 -57
- package/dist/DropdownSelect/index.d.ts +1 -1
- package/dist/Separator/typings.d.ts +2 -1
- package/dist/blocks.js +522 -251
- package/dist/blocks.js.map +1 -1
- package/dist/blocks.umd.cjs +515 -247
- package/dist/blocks.umd.cjs.map +1 -1
- package/dist/index.d.ts +4 -2
- package/dist/style.css +59 -59
- package/dist/utils.d.ts +12 -1
- package/package.json +102 -98
package/dist/blocks.umd.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
(function(global, factory) {
|
|
2
|
-
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("@radix-ui/colors"), require("@radix-ui/react-icons"), require("@radix-ui/themes"), require("react/jsx-runtime"), require("react"), require("react-responsive"), require("@radix-ui/react-dialog"), require("re-resizable"), require("@radix-ui/react-dismissable-layer"), require("react-transition-group"), require("@radix-ui/react-toggle-group"), require("@radix-ui/react-toolbar"), require("@radix-ui/react-toast"), require("react-dom"), require("@table-library/react-table-library/table"), require("@table-library/react-table-library/theme"), require("@table-library/react-table-library/sort"), require("@table-library/react-table-library/select"), require("@table-library/react-table-library/pagination"), require("react-device-detect")) : typeof define === "function" && define.amd ? define(["exports", "@radix-ui/colors", "@radix-ui/react-icons", "@radix-ui/themes", "react/jsx-runtime", "react", "react-responsive", "@radix-ui/react-dialog", "re-resizable", "@radix-ui/react-dismissable-layer", "react-transition-group", "@radix-ui/react-toggle-group", "@radix-ui/react-toolbar", "@radix-ui/react-toast", "react-dom", "@table-library/react-table-library/table", "@table-library/react-table-library/theme", "@table-library/react-table-library/sort", "@table-library/react-table-library/select", "@table-library/react-table-library/pagination", "react-device-detect"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.blocks = {}, global.colors, global.reactIcons, global.themes, global.jsxRuntime, global.React, global.reactResponsive, global.RadixDialogPrimitive, global.reResizable, global.reactDismissableLayer, global.reactTransitionGroup, global.reactToggleGroup, global.reactToolbar, global.RadixToast, global.reactDom, global.table$1, global.theme, global.sort, global.select, global.pagination, global.reactDeviceDetect));
|
|
3
|
-
})(this, function(exports2, colors, reactIcons, themes, jsxRuntime, React, reactResponsive, RadixDialogPrimitive, reResizable, reactDismissableLayer, reactTransitionGroup, reactToggleGroup, reactToolbar, RadixToast, reactDom, table$1, theme, sort, select, pagination, reactDeviceDetect) {
|
|
2
|
+
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("@radix-ui/colors"), require("@radix-ui/react-icons"), require("@radix-ui/themes"), require("react/jsx-runtime"), require("react"), require("react-responsive"), require("@radix-ui/react-dropdown-menu"), require("@radix-ui/react-dialog"), require("re-resizable"), require("@radix-ui/react-dismissable-layer"), require("react-transition-group"), require("@radix-ui/react-toggle-group"), require("@radix-ui/react-toolbar"), require("@radix-ui/react-toast"), require("react-dom"), require("@table-library/react-table-library/table"), require("@table-library/react-table-library/theme"), require("@table-library/react-table-library/sort"), require("@table-library/react-table-library/select"), require("@table-library/react-table-library/pagination"), require("react-device-detect")) : typeof define === "function" && define.amd ? define(["exports", "@radix-ui/colors", "@radix-ui/react-icons", "@radix-ui/themes", "react/jsx-runtime", "react", "react-responsive", "@radix-ui/react-dropdown-menu", "@radix-ui/react-dialog", "re-resizable", "@radix-ui/react-dismissable-layer", "react-transition-group", "@radix-ui/react-toggle-group", "@radix-ui/react-toolbar", "@radix-ui/react-toast", "react-dom", "@table-library/react-table-library/table", "@table-library/react-table-library/theme", "@table-library/react-table-library/sort", "@table-library/react-table-library/select", "@table-library/react-table-library/pagination", "react-device-detect"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.blocks = {}, global.colors, global.reactIcons, global.themes, global.jsxRuntime, global.React, global.reactResponsive, global.RadixDropdownMenu, global.RadixDialogPrimitive, global.reResizable, global.reactDismissableLayer, global.reactTransitionGroup, global.reactToggleGroup, global.reactToolbar, global.RadixToast, global.reactDom, global.table$1, global.theme, global.sort, global.select, global.pagination, global.reactDeviceDetect));
|
|
3
|
+
})(this, function(exports2, colors, reactIcons, themes, jsxRuntime, React, reactResponsive, RadixDropdownMenu, RadixDialogPrimitive, reResizable, reactDismissableLayer, reactTransitionGroup, reactToggleGroup, reactToolbar, RadixToast, reactDom, table$1, theme, sort, select, pagination, reactDeviceDetect) {
|
|
4
4
|
"use strict";
|
|
5
5
|
function _interopNamespaceDefault(e) {
|
|
6
6
|
const n = Object.create(null, { [Symbol.toStringTag]: { value: "Module" } });
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
n.default = e;
|
|
19
19
|
return Object.freeze(n);
|
|
20
20
|
}
|
|
21
|
+
const RadixDropdownMenu__namespace = /* @__PURE__ */ _interopNamespaceDefault(RadixDropdownMenu);
|
|
21
22
|
const RadixDialogPrimitive__namespace = /* @__PURE__ */ _interopNamespaceDefault(RadixDialogPrimitive);
|
|
22
23
|
const RadixToast__namespace = /* @__PURE__ */ _interopNamespaceDefault(RadixToast);
|
|
23
24
|
function getDefaultExportFromCjs(x) {
|
|
@@ -174,6 +175,19 @@
|
|
|
174
175
|
}
|
|
175
176
|
return tempChildrenToArray;
|
|
176
177
|
};
|
|
178
|
+
const useStopEventPropagation = () => {
|
|
179
|
+
return React.useCallback((event) => {
|
|
180
|
+
event.stopPropagation();
|
|
181
|
+
}, []);
|
|
182
|
+
};
|
|
183
|
+
function useTextFilter(values, filterFunction) {
|
|
184
|
+
const [filteredOptions, setFilteredOptions] = React.useState([]);
|
|
185
|
+
const [filterValue, setFilterValue] = React.useState("");
|
|
186
|
+
React.useEffect(() => {
|
|
187
|
+
setFilteredOptions(values.filter((value) => filterFunction(value, filterValue)));
|
|
188
|
+
}, [filterFunction, filterValue, values]);
|
|
189
|
+
return [filteredOptions, filterValue, setFilterValue];
|
|
190
|
+
}
|
|
177
191
|
const _Badge = React.forwardRef(function Badge2({ className, severity = "primary", color, children, ...rest }, ref) {
|
|
178
192
|
const severityColor = useSeverityColor(severity);
|
|
179
193
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -560,6 +574,15 @@
|
|
|
560
574
|
] });
|
|
561
575
|
})
|
|
562
576
|
);
|
|
577
|
+
const useWrapCallbackInDialogClose = (callback, closeOptions) => {
|
|
578
|
+
return React.useCallback(
|
|
579
|
+
(...arg) => (closeDialog) => {
|
|
580
|
+
callback(...arg);
|
|
581
|
+
closeDialog(closeOptions);
|
|
582
|
+
},
|
|
583
|
+
[callback, closeOptions]
|
|
584
|
+
);
|
|
585
|
+
};
|
|
563
586
|
const Title = (props) => /* @__PURE__ */ jsxRuntime.jsx(themes.AlertDialog.Title, { mb: "0", ...props });
|
|
564
587
|
const AlertDialogContent$1 = (props) => {
|
|
565
588
|
const { title, description, actionText = "Confirm", cancelText = "Cancel", onAction, onCancel, severity } = props;
|
|
@@ -625,128 +648,341 @@
|
|
|
625
648
|
[openAlertDialog]
|
|
626
649
|
);
|
|
627
650
|
};
|
|
628
|
-
const DropdownMenu
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
651
|
+
const DropdownMenu = React.memo(
|
|
652
|
+
React.forwardRef(({ trigger, disabled, children, ...rest }) => {
|
|
653
|
+
const infoColor = useSeverityColor("info");
|
|
654
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(themes.DropdownMenu.Root, { children: [
|
|
655
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Trigger, { disabled, children: trigger }),
|
|
656
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Content, { variant: "soft", color: infoColor, ...rest, children })
|
|
657
|
+
] });
|
|
658
|
+
})
|
|
659
|
+
);
|
|
660
|
+
const BaseMenuItem$1 = "_BaseMenuItem_1s610_1";
|
|
661
|
+
const RemoveOutline = "_RemoveOutline_1s610_15";
|
|
662
|
+
const BaseMenuSeparator$1 = "_BaseMenuSeparator_1s610_19";
|
|
663
|
+
const BaseMenuInput$1 = "_BaseMenuInput_1s610_27";
|
|
632
664
|
const styles$h = {
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
665
|
+
BaseMenuItem: BaseMenuItem$1,
|
|
666
|
+
RemoveOutline,
|
|
667
|
+
BaseMenuSeparator: BaseMenuSeparator$1,
|
|
668
|
+
BaseMenuInput: BaseMenuInput$1
|
|
637
669
|
};
|
|
638
|
-
const
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
670
|
+
const BaseMenuItem = React.memo(
|
|
671
|
+
React.forwardRef(({ children, rightSlot }, ref) => {
|
|
672
|
+
return /* @__PURE__ */ jsxRuntime.jsx(themes.Box, { className: styles$h.BaseMenuItem, ref, position: "relative", px: "2", height: "6", children: /* @__PURE__ */ jsxRuntime.jsxs(Flex, { gap: "6", height: "100%", align: "center", children: [
|
|
673
|
+
/* @__PURE__ */ jsxRuntime.jsx(Flex, { grow: "1", height: "100%", align: "center", gap: "1", children }),
|
|
674
|
+
/* @__PURE__ */ jsxRuntime.jsx(Flex, { height: "100%", width: "4", align: "center", justify: "end", children: rightSlot })
|
|
675
|
+
] }) });
|
|
676
|
+
})
|
|
677
|
+
);
|
|
678
|
+
const BaseMenuInput = React.memo(
|
|
679
|
+
React.forwardRef((props) => {
|
|
680
|
+
return /* @__PURE__ */ jsxRuntime.jsx(themes.Box, { className: styles$h.BaseMenuInput, px: "2", height: "6", width: "max-content", children: /* @__PURE__ */ jsxRuntime.jsx(Input, { ...props, variant: "ghost" }) });
|
|
681
|
+
})
|
|
682
|
+
);
|
|
683
|
+
const BaseMenuSeparator = React.memo(function BaseMenuSeparator2() {
|
|
684
|
+
return /* @__PURE__ */ jsxRuntime.jsx(themes.Box, { className: styles$h.BaseMenuSeparator, width: "100%", py: "1", children: /* @__PURE__ */ jsxRuntime.jsx(themes.Box, { height: "0", width: "100%" }) });
|
|
685
|
+
});
|
|
686
|
+
const useCloseOnSelectHandler = (closeOnSelect) => {
|
|
687
|
+
return React.useCallback(
|
|
688
|
+
(onSelect) => (event) => {
|
|
689
|
+
if (!closeOnSelect) {
|
|
690
|
+
event.preventDefault();
|
|
691
|
+
}
|
|
692
|
+
if (onSelect)
|
|
693
|
+
onSelect(event);
|
|
694
|
+
},
|
|
695
|
+
[closeOnSelect]
|
|
696
|
+
);
|
|
643
697
|
};
|
|
644
|
-
const
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
width: orientation === "horizontal" ? computedSizing : "max-content",
|
|
652
|
-
height: orientation === "vertical" ? computedSizing : "max-content",
|
|
653
|
-
direction: orientation === "vertical" ? "column" : "row",
|
|
654
|
-
align: "center",
|
|
655
|
-
gap,
|
|
656
|
-
children: [
|
|
657
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.Separator, { size, orientation, color: severityColor, ...rest }),
|
|
658
|
-
text && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
659
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.Text, { as: "span", size: "1", weight, color: severityColor, children: text }),
|
|
660
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.Separator, { size, orientation, color: severityColor, ...rest })
|
|
661
|
-
] })
|
|
662
|
-
]
|
|
663
|
-
}
|
|
698
|
+
const useTextFilterChangeHandler = () => {
|
|
699
|
+
return React.useCallback(
|
|
700
|
+
(onTextFilterChange) => (event) => {
|
|
701
|
+
if (onTextFilterChange)
|
|
702
|
+
onTextFilterChange(event.target.value);
|
|
703
|
+
},
|
|
704
|
+
[]
|
|
664
705
|
);
|
|
665
|
-
}
|
|
666
|
-
const
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
706
|
+
};
|
|
707
|
+
const BaseItemGroup = React.memo(function BaseItemGroup2({
|
|
708
|
+
items,
|
|
709
|
+
closeOnSelect = true,
|
|
710
|
+
groupElement: GroupElement,
|
|
711
|
+
itemElement: ItemElement,
|
|
712
|
+
filterValue,
|
|
713
|
+
onFilterValueChange,
|
|
714
|
+
placeholder,
|
|
715
|
+
icons,
|
|
716
|
+
separator,
|
|
671
717
|
...rest
|
|
672
718
|
}) {
|
|
673
|
-
const
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
if (
|
|
678
|
-
|
|
719
|
+
const closeOnSelectHandler = useCloseOnSelectHandler(closeOnSelect);
|
|
720
|
+
const textFilterChangeHandler = useTextFilterChangeHandler();
|
|
721
|
+
React.useEffect(() => {
|
|
722
|
+
return () => {
|
|
723
|
+
if (onFilterValueChange) {
|
|
724
|
+
onFilterValueChange("");
|
|
725
|
+
}
|
|
726
|
+
};
|
|
727
|
+
}, []);
|
|
728
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
729
|
+
/* @__PURE__ */ jsxRuntime.jsx(GroupElement, { ...rest, children: /* @__PURE__ */ jsxRuntime.jsxs(Flex, { direction: "column", children: [
|
|
730
|
+
filterValue !== void 0 && !!onFilterValueChange && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
731
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
732
|
+
BaseMenuInput,
|
|
733
|
+
{
|
|
734
|
+
value: filterValue,
|
|
735
|
+
onChange: textFilterChangeHandler(onFilterValueChange),
|
|
736
|
+
placeholder,
|
|
737
|
+
leftSlot: icons == null ? void 0 : icons.left,
|
|
738
|
+
rightSlot: icons == null ? void 0 : icons.right
|
|
739
|
+
}
|
|
740
|
+
),
|
|
741
|
+
items.length !== 0 && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
742
|
+
] }),
|
|
743
|
+
items.map(({ content, shortcut, className, onSelect, ...rest2 }, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
744
|
+
ItemElement,
|
|
745
|
+
{
|
|
746
|
+
className: classNames(className, styles$h.RemoveOutline),
|
|
747
|
+
onSelect: closeOnSelectHandler(onSelect),
|
|
748
|
+
...rest2,
|
|
749
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(BaseMenuItem, { rightSlot: shortcut == null ? void 0 : shortcut.map((key, index2) => /* @__PURE__ */ jsxRuntime.jsx(themes.Kbd, { children: key }, index2)), children: content })
|
|
750
|
+
},
|
|
751
|
+
index
|
|
752
|
+
))
|
|
753
|
+
] }) }),
|
|
754
|
+
separator && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
755
|
+
] });
|
|
756
|
+
});
|
|
757
|
+
const BaseSelectGroup = React.memo(function BaseSelectGroup2({
|
|
758
|
+
items,
|
|
759
|
+
value,
|
|
760
|
+
closeOnSelect = false,
|
|
761
|
+
onValueChange,
|
|
762
|
+
groupElement: GroupElement,
|
|
763
|
+
selectedIndicator,
|
|
764
|
+
itemElement: ItemElement,
|
|
765
|
+
itemIndicatorElement: ItemIndicatorElement,
|
|
766
|
+
filterValue,
|
|
767
|
+
onFilterValueChange,
|
|
768
|
+
placeholder,
|
|
769
|
+
icons,
|
|
770
|
+
separator
|
|
771
|
+
}) {
|
|
772
|
+
const textFilterChangeHandler = useTextFilterChangeHandler();
|
|
773
|
+
const closeOnSelectHandler = useCloseOnSelectHandler(closeOnSelect);
|
|
774
|
+
React.useEffect(() => {
|
|
775
|
+
return () => {
|
|
776
|
+
if (onFilterValueChange) {
|
|
777
|
+
onFilterValueChange("");
|
|
778
|
+
}
|
|
779
|
+
};
|
|
780
|
+
}, []);
|
|
781
|
+
const handleCheckedChange = React.useCallback(
|
|
782
|
+
(value2) => (checked) => {
|
|
783
|
+
onValueChange(checked ? value2 : null);
|
|
679
784
|
},
|
|
680
|
-
[
|
|
785
|
+
[onValueChange]
|
|
681
786
|
);
|
|
682
|
-
return /* @__PURE__ */ jsxRuntime.
|
|
787
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
788
|
+
/* @__PURE__ */ jsxRuntime.jsx(GroupElement, { children: /* @__PURE__ */ jsxRuntime.jsxs(Flex, { direction: "column", children: [
|
|
789
|
+
filterValue !== void 0 && !!onFilterValueChange && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
790
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
791
|
+
BaseMenuInput,
|
|
792
|
+
{
|
|
793
|
+
value: filterValue,
|
|
794
|
+
onChange: textFilterChangeHandler(onFilterValueChange),
|
|
795
|
+
placeholder,
|
|
796
|
+
leftSlot: icons == null ? void 0 : icons.left,
|
|
797
|
+
rightSlot: (icons == null ? void 0 : icons.right) || /* @__PURE__ */ jsxRuntime.jsx(reactIcons.MagnifyingGlassIcon, {})
|
|
798
|
+
}
|
|
799
|
+
),
|
|
800
|
+
items.length !== 0 && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
801
|
+
] }),
|
|
802
|
+
items.map(({ content, value: itemValue, onSelect, ...rest }, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
803
|
+
ItemElement,
|
|
804
|
+
{
|
|
805
|
+
className: styles$h.RemoveOutline,
|
|
806
|
+
checked: itemValue === value,
|
|
807
|
+
onCheckedChange: handleCheckedChange(itemValue),
|
|
808
|
+
onSelect: closeOnSelectHandler(onSelect),
|
|
809
|
+
textValue: "",
|
|
810
|
+
...rest,
|
|
811
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
812
|
+
BaseMenuItem,
|
|
813
|
+
{
|
|
814
|
+
rightSlot: /* @__PURE__ */ jsxRuntime.jsx(ItemIndicatorElement, { asChild: true, children: selectedIndicator || /* @__PURE__ */ jsxRuntime.jsx(reactIcons.CheckIcon, {}) }),
|
|
815
|
+
children: content
|
|
816
|
+
}
|
|
817
|
+
)
|
|
818
|
+
},
|
|
819
|
+
index
|
|
820
|
+
))
|
|
821
|
+
] }) }),
|
|
822
|
+
separator && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
823
|
+
] });
|
|
683
824
|
});
|
|
684
|
-
const
|
|
825
|
+
const BaseMultiSelectGroup = React.memo(function BaseMultiSelectGroup2({
|
|
826
|
+
items,
|
|
827
|
+
values,
|
|
828
|
+
onValueChange,
|
|
829
|
+
closeOnSelect = false,
|
|
830
|
+
groupElement: GroupElement,
|
|
831
|
+
selectedIndicator,
|
|
832
|
+
itemElement: ItemElement,
|
|
833
|
+
itemIndicatorElement: ItemIndicatorElement,
|
|
834
|
+
filterValue,
|
|
835
|
+
onFilterValueChange,
|
|
836
|
+
placeholder,
|
|
837
|
+
icons,
|
|
838
|
+
separator = false
|
|
839
|
+
}) {
|
|
840
|
+
const closeOnSelectHandler = useCloseOnSelectHandler(closeOnSelect);
|
|
841
|
+
const textFilterChangeHandler = useTextFilterChangeHandler();
|
|
842
|
+
React.useEffect(() => {
|
|
843
|
+
return () => {
|
|
844
|
+
if (onFilterValueChange) {
|
|
845
|
+
onFilterValueChange("");
|
|
846
|
+
}
|
|
847
|
+
};
|
|
848
|
+
}, []);
|
|
849
|
+
const handleCheckedChange = React.useCallback(
|
|
850
|
+
(value) => (checked) => {
|
|
851
|
+
if (checked) {
|
|
852
|
+
onValueChange([...values, value]);
|
|
853
|
+
} else {
|
|
854
|
+
const valueIndex = values.indexOf(value);
|
|
855
|
+
if (valueIndex < 0) {
|
|
856
|
+
throw new Error("unexpected value not found within values array");
|
|
857
|
+
}
|
|
858
|
+
const tempValues = [...values];
|
|
859
|
+
tempValues.splice(valueIndex, 1);
|
|
860
|
+
onValueChange(tempValues);
|
|
861
|
+
}
|
|
862
|
+
},
|
|
863
|
+
[onValueChange, values]
|
|
864
|
+
);
|
|
865
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
866
|
+
/* @__PURE__ */ jsxRuntime.jsx(GroupElement, { children: /* @__PURE__ */ jsxRuntime.jsxs(Flex, { direction: "column", children: [
|
|
867
|
+
filterValue !== void 0 && !!onFilterValueChange && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
868
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
869
|
+
BaseMenuInput,
|
|
870
|
+
{
|
|
871
|
+
value: filterValue,
|
|
872
|
+
onChange: textFilterChangeHandler(onFilterValueChange),
|
|
873
|
+
placeholder,
|
|
874
|
+
leftSlot: icons == null ? void 0 : icons.left,
|
|
875
|
+
rightSlot: icons == null ? void 0 : icons.right
|
|
876
|
+
}
|
|
877
|
+
),
|
|
878
|
+
items.length !== 0 && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
879
|
+
] }),
|
|
880
|
+
items.map(({ value, content, className, onSelect, ...rest }, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
881
|
+
ItemElement,
|
|
882
|
+
{
|
|
883
|
+
className: classNames(className, styles$h.RemoveOutline),
|
|
884
|
+
onSelect: closeOnSelectHandler(onSelect),
|
|
885
|
+
onCheckedChange: handleCheckedChange(value),
|
|
886
|
+
checked: values.includes(value),
|
|
887
|
+
textValue: "",
|
|
888
|
+
...rest,
|
|
889
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
890
|
+
BaseMenuItem,
|
|
891
|
+
{
|
|
892
|
+
rightSlot: /* @__PURE__ */ jsxRuntime.jsx(ItemIndicatorElement, { asChild: true, children: selectedIndicator || /* @__PURE__ */ jsxRuntime.jsx(reactIcons.CheckIcon, {}) }),
|
|
893
|
+
children: content
|
|
894
|
+
}
|
|
895
|
+
)
|
|
896
|
+
},
|
|
897
|
+
index
|
|
898
|
+
))
|
|
899
|
+
] }) }),
|
|
900
|
+
separator && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
901
|
+
] });
|
|
902
|
+
});
|
|
903
|
+
const BaseSubMenuGroup = React.memo(function BaseSubMenuGroup2({
|
|
904
|
+
subTriggerElement: SubTriggerElement,
|
|
905
|
+
groupElement: GroupElement,
|
|
906
|
+
subContentElement: SubContentElement,
|
|
907
|
+
subElement: SubElement,
|
|
908
|
+
items,
|
|
909
|
+
separator = false,
|
|
910
|
+
...rest
|
|
911
|
+
}) {
|
|
912
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
913
|
+
/* @__PURE__ */ jsxRuntime.jsx(GroupElement, { ...rest, children: items.map(({ triggerIndicator, content, subContent, className, ...rest2 }, index) => /* @__PURE__ */ jsxRuntime.jsxs(SubElement, { children: [
|
|
914
|
+
/* @__PURE__ */ jsxRuntime.jsx(SubTriggerElement, { className: classNames(className, styles$h.RemoveOutline), ...rest2, children: /* @__PURE__ */ jsxRuntime.jsx(BaseMenuItem, { rightSlot: triggerIndicator, children: content }) }),
|
|
915
|
+
/* @__PURE__ */ jsxRuntime.jsx(SubContentElement, { sideOffset: 10, children: subContent })
|
|
916
|
+
] }, index)) }),
|
|
917
|
+
separator && /* @__PURE__ */ jsxRuntime.jsx(BaseMenuSeparator, {})
|
|
918
|
+
] });
|
|
919
|
+
});
|
|
920
|
+
const DropdownMenuItemGroup = React.memo(function DropdownMenuItemGroup2(props) {
|
|
921
|
+
return /* @__PURE__ */ jsxRuntime.jsx(BaseItemGroup, { ...props, itemElement: RadixDropdownMenu__namespace.Item, groupElement: RadixDropdownMenu__namespace.Group });
|
|
922
|
+
});
|
|
923
|
+
const DropdownMenuSelectGroup = React.memo(function DropdownMenuSelectGroup2(props) {
|
|
924
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
925
|
+
BaseSelectGroup,
|
|
926
|
+
{
|
|
927
|
+
...props,
|
|
928
|
+
itemElement: RadixDropdownMenu__namespace.CheckboxItem,
|
|
929
|
+
groupElement: RadixDropdownMenu__namespace.Group,
|
|
930
|
+
itemIndicatorElement: RadixDropdownMenu__namespace.ItemIndicator
|
|
931
|
+
}
|
|
932
|
+
);
|
|
933
|
+
});
|
|
934
|
+
const DropdownMenuMultiSelectGroup = React.memo(function DropdownMenuMultiSelectGroup2(props) {
|
|
935
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
936
|
+
BaseMultiSelectGroup,
|
|
937
|
+
{
|
|
938
|
+
...props,
|
|
939
|
+
itemElement: RadixDropdownMenu__namespace.CheckboxItem,
|
|
940
|
+
groupElement: RadixDropdownMenu__namespace.Group,
|
|
941
|
+
itemIndicatorElement: RadixDropdownMenu__namespace.ItemIndicator
|
|
942
|
+
}
|
|
943
|
+
);
|
|
944
|
+
});
|
|
945
|
+
const DropdownMenuSubMenuGroup = React.memo(function DropdownMenuSubMenuGroup2(props) {
|
|
946
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
947
|
+
BaseSubMenuGroup,
|
|
948
|
+
{
|
|
949
|
+
...props,
|
|
950
|
+
groupElement: RadixDropdownMenu__namespace.Group,
|
|
951
|
+
subElement: themes.DropdownMenu.Sub,
|
|
952
|
+
subTriggerElement: RadixDropdownMenu__namespace.SubTrigger,
|
|
953
|
+
subContentElement: themes.DropdownMenu.SubContent
|
|
954
|
+
}
|
|
955
|
+
);
|
|
956
|
+
});
|
|
957
|
+
const DropdownItemMenu = React.memo(
|
|
685
958
|
React.forwardRef(
|
|
686
959
|
({
|
|
687
|
-
className,
|
|
688
960
|
trigger,
|
|
689
961
|
items,
|
|
690
|
-
label,
|
|
691
962
|
disabled,
|
|
692
|
-
severity = "info",
|
|
693
|
-
modal = false,
|
|
694
963
|
closeOnSelect = true,
|
|
964
|
+
filterValue,
|
|
965
|
+
onFilterValueChange,
|
|
966
|
+
placeholder,
|
|
695
967
|
...rest
|
|
696
|
-
}
|
|
697
|
-
const
|
|
698
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(themes.DropdownMenu.Root, {
|
|
968
|
+
}) => {
|
|
969
|
+
const infoColor = useSeverityColor("info");
|
|
970
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(themes.DropdownMenu.Root, { children: [
|
|
699
971
|
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Trigger, { disabled, children: trigger }),
|
|
700
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
701
|
-
|
|
972
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Content, { variant: "soft", ...rest, color: infoColor, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
973
|
+
DropdownMenuItemGroup,
|
|
702
974
|
{
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
709
|
-
themes.Flex,
|
|
710
|
-
{
|
|
711
|
-
className: styles$h.DropdownMenu,
|
|
712
|
-
direction: "column",
|
|
713
|
-
height: "max-content",
|
|
714
|
-
width: "max-content",
|
|
715
|
-
children: [
|
|
716
|
-
!!label && /* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Label, { children: label }),
|
|
717
|
-
items.map(({ closeOnSelect: itemCloseOnSelect, separator, ...rest2 }, index) => /* @__PURE__ */ jsxRuntime.jsxs(themes.Box, { children: [
|
|
718
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.Box, { className: styles$h.DropdownMenuItemWrapper, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
719
|
-
DropdownMenuItem,
|
|
720
|
-
{
|
|
721
|
-
closeOnSelect: itemCloseOnSelect ?? closeOnSelect,
|
|
722
|
-
...rest2
|
|
723
|
-
},
|
|
724
|
-
index
|
|
725
|
-
) }),
|
|
726
|
-
!!separator && /* @__PURE__ */ jsxRuntime.jsx(themes.Box, { className: styles$h.DropdownMenuSeparatorWrapper, children: /* @__PURE__ */ jsxRuntime.jsx(Separator, { size: "4" }) })
|
|
727
|
-
] }, index))
|
|
728
|
-
]
|
|
729
|
-
}
|
|
730
|
-
)
|
|
975
|
+
items,
|
|
976
|
+
filterValue,
|
|
977
|
+
onFilterValueChange,
|
|
978
|
+
placeholder,
|
|
979
|
+
closeOnSelect
|
|
731
980
|
}
|
|
732
|
-
)
|
|
981
|
+
) })
|
|
733
982
|
] });
|
|
734
983
|
}
|
|
735
984
|
)
|
|
736
985
|
);
|
|
737
|
-
const DropdownSelect$1 = "_DropdownSelect_k517z_1";
|
|
738
|
-
const BorderBottom = "_BorderBottom_k517z_8";
|
|
739
|
-
const DropdownSelectInputWrapper = "_DropdownSelectInputWrapper_k517z_12";
|
|
740
|
-
const DropdownSelectInput = "_DropdownSelectInput_k517z_12";
|
|
741
|
-
const DropdownSelectItem = "_DropdownSelectItem_k517z_27";
|
|
742
|
-
const styles$g = {
|
|
743
|
-
DropdownSelect: DropdownSelect$1,
|
|
744
|
-
BorderBottom,
|
|
745
|
-
DropdownSelectInputWrapper,
|
|
746
|
-
DropdownSelectInput,
|
|
747
|
-
DropdownSelectItem
|
|
748
|
-
};
|
|
749
|
-
const TIMEOUT = 150;
|
|
750
986
|
const DropdownSelect = React.memo(
|
|
751
987
|
React.forwardRef(
|
|
752
988
|
({
|
|
@@ -760,84 +996,59 @@
|
|
|
760
996
|
onFilterValueChange,
|
|
761
997
|
closeOnSelect = true,
|
|
762
998
|
icons,
|
|
763
|
-
|
|
999
|
+
side
|
|
764
1000
|
}, ref) => {
|
|
765
|
-
const infoColor = useSeverityColor(
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
[onFilterValueChange]
|
|
780
|
-
);
|
|
781
|
-
const handleOnOpenChange = React.useCallback(
|
|
782
|
-
(open) => {
|
|
783
|
-
if (!open && onFilterValueChange) {
|
|
784
|
-
setTimeout(() => {
|
|
785
|
-
onFilterValueChange("");
|
|
786
|
-
}, TIMEOUT);
|
|
1001
|
+
const infoColor = useSeverityColor("info");
|
|
1002
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(themes.DropdownMenu.Root, { children: [
|
|
1003
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Trigger, { disabled, children: trigger }),
|
|
1004
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Content, { ref, variant: "soft", color: infoColor, side, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1005
|
+
DropdownMenuSelectGroup,
|
|
1006
|
+
{
|
|
1007
|
+
value,
|
|
1008
|
+
onValueChange,
|
|
1009
|
+
items,
|
|
1010
|
+
closeOnSelect,
|
|
1011
|
+
filterValue,
|
|
1012
|
+
onFilterValueChange,
|
|
1013
|
+
placeholder,
|
|
1014
|
+
icons
|
|
787
1015
|
}
|
|
788
|
-
}
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
1016
|
+
) })
|
|
1017
|
+
] });
|
|
1018
|
+
}
|
|
1019
|
+
)
|
|
1020
|
+
);
|
|
1021
|
+
const DropdownMultiSelect = React.memo(
|
|
1022
|
+
React.forwardRef(
|
|
1023
|
+
({
|
|
1024
|
+
trigger,
|
|
1025
|
+
items,
|
|
1026
|
+
disabled = false,
|
|
1027
|
+
values,
|
|
1028
|
+
onValueChange,
|
|
1029
|
+
placeholder,
|
|
1030
|
+
filterValue,
|
|
1031
|
+
onFilterValueChange,
|
|
1032
|
+
closeOnSelect = false,
|
|
1033
|
+
icons,
|
|
1034
|
+
side
|
|
1035
|
+
}, ref) => {
|
|
1036
|
+
const infoColor = useSeverityColor("info");
|
|
1037
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(themes.DropdownMenu.Root, { children: [
|
|
792
1038
|
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Trigger, { disabled, children: trigger }),
|
|
793
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Content, { ref, variant: "soft", color: infoColor,
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
value: filterValue,
|
|
807
|
-
placeholder,
|
|
808
|
-
onChange: handleOnInputValueChange
|
|
809
|
-
}
|
|
810
|
-
),
|
|
811
|
-
!!icons && !!icons.rightInputIcon && /* @__PURE__ */ jsxRuntime.jsx(themes.TextField.Slot, { children: icons.rightInputIcon })
|
|
812
|
-
]
|
|
813
|
-
}
|
|
814
|
-
) }),
|
|
815
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.Box, { p: items.length !== 0 ? "1" : "0", children: /* @__PURE__ */ jsxRuntime.jsx(Flex, { direction: "column", children: items.map(({ content, value: itemValue }, index) => {
|
|
816
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
817
|
-
themes.DropdownMenu.Item,
|
|
818
|
-
{
|
|
819
|
-
className: styles$g.DropdownSelectItem,
|
|
820
|
-
onSelect: handleOnSelect(itemValue),
|
|
821
|
-
textValue: "",
|
|
822
|
-
asChild: true,
|
|
823
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs(Flex, { align: "center", height: "max-content", width: "100%", gap: "5", children: [
|
|
824
|
-
/* @__PURE__ */ jsxRuntime.jsx(themes.Box, { grow: "1", children: content }),
|
|
825
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
826
|
-
Flex,
|
|
827
|
-
{
|
|
828
|
-
justify: "center",
|
|
829
|
-
align: "center",
|
|
830
|
-
height: "max-content",
|
|
831
|
-
width: "4",
|
|
832
|
-
children: value === itemValue && (icons && (icons == null ? void 0 : icons.selectedItemIcon) ? icons.selectedItemIcon : /* @__PURE__ */ jsxRuntime.jsx(reactIcons.CheckIcon, {}))
|
|
833
|
-
}
|
|
834
|
-
)
|
|
835
|
-
] })
|
|
836
|
-
},
|
|
837
|
-
index
|
|
838
|
-
);
|
|
839
|
-
}) }) })
|
|
840
|
-
] }) })
|
|
1039
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.DropdownMenu.Content, { ref, variant: "soft", color: infoColor, side, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1040
|
+
DropdownMenuMultiSelectGroup,
|
|
1041
|
+
{
|
|
1042
|
+
values,
|
|
1043
|
+
onValueChange,
|
|
1044
|
+
items,
|
|
1045
|
+
closeOnSelect,
|
|
1046
|
+
filterValue,
|
|
1047
|
+
onFilterValueChange,
|
|
1048
|
+
placeholder,
|
|
1049
|
+
icons
|
|
1050
|
+
}
|
|
1051
|
+
) })
|
|
841
1052
|
] });
|
|
842
1053
|
}
|
|
843
1054
|
)
|
|
@@ -857,7 +1068,7 @@
|
|
|
857
1068
|
});
|
|
858
1069
|
});
|
|
859
1070
|
const fluid = "_fluid_7n1wr_1";
|
|
860
|
-
const styles$
|
|
1071
|
+
const styles$g = {
|
|
861
1072
|
fluid
|
|
862
1073
|
};
|
|
863
1074
|
const _Select = React.forwardRef(function Select2({
|
|
@@ -881,7 +1092,7 @@
|
|
|
881
1092
|
themes.Select.Trigger,
|
|
882
1093
|
{
|
|
883
1094
|
className: classNames(className, {
|
|
884
|
-
[styles$
|
|
1095
|
+
[styles$g.fluid]: fluid2
|
|
885
1096
|
}),
|
|
886
1097
|
id,
|
|
887
1098
|
ref,
|
|
@@ -893,7 +1104,7 @@
|
|
|
893
1104
|
themes.Select.Content,
|
|
894
1105
|
{
|
|
895
1106
|
side,
|
|
896
|
-
className: styles$
|
|
1107
|
+
className: styles$g.contentDefault,
|
|
897
1108
|
position: "popper",
|
|
898
1109
|
variant: variant !== "surface" ? "soft" : "solid",
|
|
899
1110
|
color: itemSeverityColor,
|
|
@@ -1006,7 +1217,7 @@
|
|
|
1006
1217
|
);
|
|
1007
1218
|
})
|
|
1008
1219
|
);
|
|
1009
|
-
const styles$
|
|
1220
|
+
const styles$f = {
|
|
1010
1221
|
"default": "_default_u936h_1"
|
|
1011
1222
|
};
|
|
1012
1223
|
const _Switch = React.forwardRef(function Switch2({ className, severity = "primary", icon, defaultChecked = false, onCheckedChange, ...rest }, ref) {
|
|
@@ -1034,7 +1245,7 @@
|
|
|
1034
1245
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1035
1246
|
themes.Switch,
|
|
1036
1247
|
{
|
|
1037
|
-
className: classNames("overmap-switch", className, styles$
|
|
1248
|
+
className: classNames("overmap-switch", className, styles$f.default),
|
|
1038
1249
|
ref: ref ? ref : fallbackRef,
|
|
1039
1250
|
color: severityColor,
|
|
1040
1251
|
radius: "full",
|
|
@@ -1052,7 +1263,7 @@
|
|
|
1052
1263
|
const resizeHandle$1 = "_resizeHandle_1onyo_10";
|
|
1053
1264
|
const left$2 = "_left_1onyo_13";
|
|
1054
1265
|
const overlay = "_overlay_1onyo_33";
|
|
1055
|
-
const styles$
|
|
1266
|
+
const styles$e = {
|
|
1056
1267
|
sidebarContent,
|
|
1057
1268
|
right: right$2,
|
|
1058
1269
|
resizeHandle: resizeHandle$1,
|
|
@@ -1085,13 +1296,13 @@
|
|
|
1085
1296
|
setContainer(tempContainer);
|
|
1086
1297
|
}, [containerSelector]);
|
|
1087
1298
|
return /* @__PURE__ */ jsxRuntime.jsx(RadixDialogPrimitive__namespace.Root, { open, modal, children: /* @__PURE__ */ jsxRuntime.jsxs(RadixDialogPrimitive__namespace.Portal, { container, children: [
|
|
1088
|
-
overlay2 && /* @__PURE__ */ jsxRuntime.jsx(RadixDialogPrimitive__namespace.Overlay, { className: classNames(styles$
|
|
1299
|
+
overlay2 && /* @__PURE__ */ jsxRuntime.jsx(RadixDialogPrimitive__namespace.Overlay, { className: classNames(styles$e.overlay) }),
|
|
1089
1300
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1090
1301
|
RadixDialogPrimitive__namespace.Content,
|
|
1091
1302
|
{
|
|
1092
|
-
className: classNames("overmap-sidebar", "rt-DialogContent", styles$
|
|
1093
|
-
[styles$
|
|
1094
|
-
[styles$
|
|
1303
|
+
className: classNames("overmap-sidebar", "rt-DialogContent", styles$e.sidebarContent, {
|
|
1304
|
+
[styles$e.left]: isLeft,
|
|
1305
|
+
[styles$e.right]: isRight
|
|
1095
1306
|
}),
|
|
1096
1307
|
ref,
|
|
1097
1308
|
asChild: true,
|
|
@@ -1103,7 +1314,7 @@
|
|
|
1103
1314
|
maxWidth,
|
|
1104
1315
|
defaultSize: defaultSidebarSize,
|
|
1105
1316
|
enable: { right: resizable2 && isLeft, left: resizable2 && isRight },
|
|
1106
|
-
handleClasses: { left: styles$
|
|
1317
|
+
handleClasses: { left: styles$e.resizeHandle, right: styles$e.resizeHandle },
|
|
1107
1318
|
handleComponent: {
|
|
1108
1319
|
right: /* @__PURE__ */ jsxRuntime.jsx(reactIcons.DragHandleDots2Icon, {}),
|
|
1109
1320
|
left: /* @__PURE__ */ jsxRuntime.jsx(reactIcons.DragHandleDots2Icon, {})
|
|
@@ -1125,7 +1336,7 @@
|
|
|
1125
1336
|
const exitDone = "_exitDone_1iy9c_32";
|
|
1126
1337
|
const resizable$1 = "_resizable_1iy9c_41";
|
|
1127
1338
|
const slideOutOverlay = "_slideOutOverlay_1iy9c_47";
|
|
1128
|
-
const styles$
|
|
1339
|
+
const styles$d = {
|
|
1129
1340
|
outerContent,
|
|
1130
1341
|
enter,
|
|
1131
1342
|
right: right$1,
|
|
@@ -1169,23 +1380,23 @@
|
|
|
1169
1380
|
{
|
|
1170
1381
|
in: open,
|
|
1171
1382
|
classNames: {
|
|
1172
|
-
enter: styles$
|
|
1173
|
-
enterActive: styles$
|
|
1174
|
-
exitActive: styles$
|
|
1175
|
-
exitDone: styles$
|
|
1383
|
+
enter: styles$d.enter,
|
|
1384
|
+
enterActive: styles$d.enterActive,
|
|
1385
|
+
exitActive: styles$d.exitActive,
|
|
1386
|
+
exitDone: styles$d.exitDone
|
|
1176
1387
|
},
|
|
1177
1388
|
timeout: TRANSITION_DURATION$1,
|
|
1178
1389
|
nodeRef: contentRef,
|
|
1179
1390
|
unmountOnExit: true,
|
|
1180
1391
|
mountOnEnter: true,
|
|
1181
1392
|
children: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1182
|
-
overlay2 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: classNames("overamp-slide-out-overlay", styles$
|
|
1393
|
+
overlay2 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: classNames("overamp-slide-out-overlay", styles$d.slideOutOverlay) }),
|
|
1183
1394
|
/* @__PURE__ */ jsxRuntime.jsx(reactDismissableLayer.DismissableLayer, { disableOutsidePointerEvents: modal, asChild: true, ...rest, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1184
1395
|
themes.Flex,
|
|
1185
1396
|
{
|
|
1186
|
-
className: classNames("overmap-slide-out", className, styles$
|
|
1187
|
-
[styles$
|
|
1188
|
-
[styles$
|
|
1397
|
+
className: classNames("overmap-slide-out", className, styles$d.outerContent, {
|
|
1398
|
+
[styles$d.left]: isSideLeft,
|
|
1399
|
+
[styles$d.right]: isSideRight
|
|
1189
1400
|
}),
|
|
1190
1401
|
style: { "--slide-out-width": `${slideOutWidth}px` },
|
|
1191
1402
|
height: "100%",
|
|
@@ -1199,7 +1410,7 @@
|
|
|
1199
1410
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1200
1411
|
reResizable.Resizable,
|
|
1201
1412
|
{
|
|
1202
|
-
className: styles$
|
|
1413
|
+
className: styles$d.resizable,
|
|
1203
1414
|
defaultSize: { width: slideOutWidth, height: "100%" },
|
|
1204
1415
|
onResize: handleResize,
|
|
1205
1416
|
enable: { right: resizable2 && isSideLeft, left: resizable2 && isSideRight },
|
|
@@ -1221,7 +1432,7 @@
|
|
|
1221
1432
|
const noRightIcon = "_noRightIcon_1octa_18";
|
|
1222
1433
|
const ghost$1 = "_ghost_1octa_22";
|
|
1223
1434
|
const charCount$1 = "_charCount_1octa_40";
|
|
1224
|
-
const styles$
|
|
1435
|
+
const styles$c = {
|
|
1225
1436
|
accommodateCharCount,
|
|
1226
1437
|
wrapper: wrapper$2,
|
|
1227
1438
|
"default": "_default_1octa_10",
|
|
@@ -1248,9 +1459,9 @@
|
|
|
1248
1459
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1249
1460
|
themes.TextField.Root,
|
|
1250
1461
|
{
|
|
1251
|
-
className: classNames(styles$
|
|
1252
|
-
[styles$
|
|
1253
|
-
[styles$
|
|
1462
|
+
className: classNames(styles$c.wrapper, className, {
|
|
1463
|
+
[styles$c.ghost]: variant === "ghost",
|
|
1464
|
+
[styles$c.accommodateCharCount]: displayInputLength
|
|
1254
1465
|
}),
|
|
1255
1466
|
size: computedSize,
|
|
1256
1467
|
variant: variant !== "ghost" ? variant : void 0,
|
|
@@ -1260,9 +1471,9 @@
|
|
|
1260
1471
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1261
1472
|
themes.TextField.Input,
|
|
1262
1473
|
{
|
|
1263
|
-
className: classNames(styles$
|
|
1264
|
-
[styles$
|
|
1265
|
-
[styles$
|
|
1474
|
+
className: classNames(styles$c.default, {
|
|
1475
|
+
[styles$c.noLeftIcon]: !leftSlot,
|
|
1476
|
+
[styles$c.noRightIcon]: !rightSlot
|
|
1266
1477
|
}),
|
|
1267
1478
|
ref,
|
|
1268
1479
|
value,
|
|
@@ -1273,7 +1484,7 @@
|
|
|
1273
1484
|
}
|
|
1274
1485
|
),
|
|
1275
1486
|
rightSlot && /* @__PURE__ */ jsxRuntime.jsx(themes.TextField.Slot, { children: rightSlot }),
|
|
1276
|
-
displayInputLength && /* @__PURE__ */ jsxRuntime.jsx(themes.Text, { as: "p", className: styles$
|
|
1487
|
+
displayInputLength && /* @__PURE__ */ jsxRuntime.jsx(themes.Text, { as: "p", className: styles$c.charCount, size: "1", color: "gray", children: rest.maxLength !== void 0 ? `${valueAsString == null ? void 0 : valueAsString.length}/${rest.maxLength}` : `${valueAsString == null ? void 0 : valueAsString.length}` })
|
|
1277
1488
|
]
|
|
1278
1489
|
}
|
|
1279
1490
|
);
|
|
@@ -1289,7 +1500,7 @@
|
|
|
1289
1500
|
() => ({
|
|
1290
1501
|
"data-accent-color": severity && severityColor ? severityColor : color ? color : "gray",
|
|
1291
1502
|
style: {
|
|
1292
|
-
color: "var(--accent-
|
|
1503
|
+
color: "var(--accent-a9)"
|
|
1293
1504
|
}
|
|
1294
1505
|
}),
|
|
1295
1506
|
[color, severity, severityColor]
|
|
@@ -1297,7 +1508,7 @@
|
|
|
1297
1508
|
return React.cloneElement(children, { ...childProps });
|
|
1298
1509
|
});
|
|
1299
1510
|
const wrapper$1 = "_wrapper_tmtz0_1";
|
|
1300
|
-
const styles$
|
|
1511
|
+
const styles$b = {
|
|
1301
1512
|
wrapper: wrapper$1
|
|
1302
1513
|
};
|
|
1303
1514
|
const _Popover = React.forwardRef(function Popover2({ className, trigger, open, onOpenChange, defaultOpen = false, modal = false, children, ...rest }, ref) {
|
|
@@ -1307,7 +1518,7 @@
|
|
|
1307
1518
|
themes.Popover.Content,
|
|
1308
1519
|
{
|
|
1309
1520
|
ref,
|
|
1310
|
-
className: classNames("overmap-popover", className, styles$
|
|
1521
|
+
className: classNames("overmap-popover", className, styles$b.wrapper),
|
|
1311
1522
|
...rest,
|
|
1312
1523
|
children: children(themes.Popover.Close)
|
|
1313
1524
|
}
|
|
@@ -1322,7 +1533,7 @@
|
|
|
1322
1533
|
const resizable = "_resizable_1ssf2_23";
|
|
1323
1534
|
const resizeHandle = "_resizeHandle_1ssf2_28";
|
|
1324
1535
|
const panelMainContent = "_panelMainContent_1ssf2_48";
|
|
1325
|
-
const styles$
|
|
1536
|
+
const styles$a = {
|
|
1326
1537
|
wrapper,
|
|
1327
1538
|
panelContent,
|
|
1328
1539
|
left,
|
|
@@ -1508,7 +1719,7 @@
|
|
|
1508
1719
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1509
1720
|
themes.Flex,
|
|
1510
1721
|
{
|
|
1511
|
-
className: styles$
|
|
1722
|
+
className: styles$a.wrapper,
|
|
1512
1723
|
style: { minWidth: `${leftMinWidth + rightMinWidth}px` },
|
|
1513
1724
|
ref: wrapperRef,
|
|
1514
1725
|
width: "100%",
|
|
@@ -1530,7 +1741,7 @@
|
|
|
1530
1741
|
themes.Box,
|
|
1531
1742
|
{
|
|
1532
1743
|
ref: leftPanelRef,
|
|
1533
|
-
className: classNames(styles$
|
|
1744
|
+
className: classNames(styles$a.panelContent, styles$a.left),
|
|
1534
1745
|
style: leftPanelTransitionStyles[state],
|
|
1535
1746
|
width: "auto",
|
|
1536
1747
|
height: "100%",
|
|
@@ -1539,7 +1750,7 @@
|
|
|
1539
1750
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1540
1751
|
reResizable.Resizable,
|
|
1541
1752
|
{
|
|
1542
|
-
className: styles$
|
|
1753
|
+
className: styles$a.resizable,
|
|
1543
1754
|
size: {
|
|
1544
1755
|
width: leftPanelWidth,
|
|
1545
1756
|
height: "100%"
|
|
@@ -1548,7 +1759,7 @@
|
|
|
1548
1759
|
enable: { right: (resizeable == null ? void 0 : resizeable.left) !== void 0 ? resizeable.left : true },
|
|
1549
1760
|
minWidth: leftMinWidth,
|
|
1550
1761
|
maxWidth: leftPanelMaxWidth,
|
|
1551
|
-
handleClasses: { right: classNames(styles$
|
|
1762
|
+
handleClasses: { right: classNames(styles$a.resizeHandle, styles$a.left) },
|
|
1552
1763
|
handleComponent: {
|
|
1553
1764
|
right: /* @__PURE__ */ jsxRuntime.jsx(reactIcons.DragHandleDots2Icon, { height: "14px", width: "14px" })
|
|
1554
1765
|
},
|
|
@@ -1559,7 +1770,7 @@
|
|
|
1559
1770
|
)
|
|
1560
1771
|
}
|
|
1561
1772
|
),
|
|
1562
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: styles$
|
|
1773
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: styles$a.panelMainContent, children }),
|
|
1563
1774
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1564
1775
|
reactTransitionGroup.Transition,
|
|
1565
1776
|
{
|
|
@@ -1573,7 +1784,7 @@
|
|
|
1573
1784
|
themes.Box,
|
|
1574
1785
|
{
|
|
1575
1786
|
ref: rightPanelRef,
|
|
1576
|
-
className: classNames(styles$
|
|
1787
|
+
className: classNames(styles$a.panelContent, styles$a.right),
|
|
1577
1788
|
style: rightPanelTransitionStyles[state],
|
|
1578
1789
|
width: "auto",
|
|
1579
1790
|
height: "100%",
|
|
@@ -1582,13 +1793,13 @@
|
|
|
1582
1793
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1583
1794
|
reResizable.Resizable,
|
|
1584
1795
|
{
|
|
1585
|
-
className: styles$
|
|
1796
|
+
className: styles$a.resizable,
|
|
1586
1797
|
size: { width: rightPanelWidth, height: "100%" },
|
|
1587
1798
|
onResizeStop: handleResizeRightPanel,
|
|
1588
1799
|
enable: { left: (resizeable == null ? void 0 : resizeable.right) !== void 0 ? resizeable.right : true },
|
|
1589
1800
|
minWidth: rightMinWidth,
|
|
1590
1801
|
maxWidth: rightPanelMaxWidth,
|
|
1591
|
-
handleClasses: { left: classNames(styles$
|
|
1802
|
+
handleClasses: { left: classNames(styles$a.resizeHandle, styles$a.right) },
|
|
1592
1803
|
handleComponent: { left: /* @__PURE__ */ jsxRuntime.jsx(reactIcons.DragHandleDots2Icon, { height: "14px", width: "14px" }) },
|
|
1593
1804
|
children: rightPanel
|
|
1594
1805
|
}
|
|
@@ -1606,7 +1817,7 @@
|
|
|
1606
1817
|
const buttonContainer = "_buttonContainer_spfw7_17";
|
|
1607
1818
|
const optionsButtonContainer = "_optionsButtonContainer_spfw7_22";
|
|
1608
1819
|
const optionsButton = "_optionsButton_spfw7_22";
|
|
1609
|
-
const styles$
|
|
1820
|
+
const styles$9 = {
|
|
1610
1821
|
multiPagePopover,
|
|
1611
1822
|
pageTitle,
|
|
1612
1823
|
buttonContainer,
|
|
@@ -1620,7 +1831,7 @@
|
|
|
1620
1831
|
const optionButtons = popoverOption.options.map((option, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1621
1832
|
Button2,
|
|
1622
1833
|
{
|
|
1623
|
-
className: classNames(styles$
|
|
1834
|
+
className: classNames(styles$9.optionsButton, option.buttonClassName),
|
|
1624
1835
|
variant: "ghost",
|
|
1625
1836
|
radius: "large",
|
|
1626
1837
|
style: {
|
|
@@ -1636,12 +1847,12 @@
|
|
|
1636
1847
|
`${option.value}-page-${page}-button-${i}`
|
|
1637
1848
|
));
|
|
1638
1849
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1639
|
-
popoverOption.title && /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles$
|
|
1850
|
+
popoverOption.title && /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles$9.pageTitle, children: popoverOption.title }),
|
|
1640
1851
|
popoverOption.content,
|
|
1641
1852
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1642
1853
|
"div",
|
|
1643
1854
|
{
|
|
1644
|
-
className: classNames(styles$
|
|
1855
|
+
className: classNames(styles$9.optionsButtonContainer, popoverOption.buttonsContainerClassName),
|
|
1645
1856
|
style: {
|
|
1646
1857
|
flexDirection: direction === "vertical" ? "column" : "row"
|
|
1647
1858
|
},
|
|
@@ -1659,7 +1870,7 @@
|
|
|
1659
1870
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1660
1871
|
Popover,
|
|
1661
1872
|
{
|
|
1662
|
-
className: classNames(styles$
|
|
1873
|
+
className: classNames(styles$9.multiPagePopover, className),
|
|
1663
1874
|
ref,
|
|
1664
1875
|
onOpenAutoFocus: resetPopoverContent,
|
|
1665
1876
|
onCloseAutoFocus: resetPopoverContent,
|
|
@@ -1671,7 +1882,7 @@
|
|
|
1671
1882
|
const MultiPagePopover = React.memo(_MultiPagePopover);
|
|
1672
1883
|
const charCount = "_charCount_1lz28_1";
|
|
1673
1884
|
const ghost = "_ghost_1lz28_5";
|
|
1674
|
-
const styles$
|
|
1885
|
+
const styles$8 = {
|
|
1675
1886
|
charCount,
|
|
1676
1887
|
ghost
|
|
1677
1888
|
};
|
|
@@ -1707,7 +1918,7 @@
|
|
|
1707
1918
|
themes.TextArea,
|
|
1708
1919
|
{
|
|
1709
1920
|
className: classNames("overmap-textarea", className, {
|
|
1710
|
-
[styles$
|
|
1921
|
+
[styles$8.ghost]: variant === "ghost"
|
|
1711
1922
|
}),
|
|
1712
1923
|
style: { resize },
|
|
1713
1924
|
variant: variant !== "ghost" ? variant : void 0,
|
|
@@ -1717,7 +1928,7 @@
|
|
|
1717
1928
|
...rest
|
|
1718
1929
|
}
|
|
1719
1930
|
),
|
|
1720
|
-
displayInputLength && /* @__PURE__ */ jsxRuntime.jsx(themes.Text, { as: "p", className: styles$
|
|
1931
|
+
displayInputLength && /* @__PURE__ */ jsxRuntime.jsx(themes.Text, { as: "p", className: styles$8.charCount, color: infoColor, align: "right", children: displayInputLengthValue })
|
|
1721
1932
|
] });
|
|
1722
1933
|
});
|
|
1723
1934
|
const TextArea = React.memo(_TextArea);
|
|
@@ -1763,7 +1974,7 @@
|
|
|
1763
1974
|
);
|
|
1764
1975
|
});
|
|
1765
1976
|
const ToggleGroup = React.memo(_ToggleGroup);
|
|
1766
|
-
const styles$
|
|
1977
|
+
const styles$7 = {
|
|
1767
1978
|
"default": "_default_xqvoc_1"
|
|
1768
1979
|
};
|
|
1769
1980
|
const Root = React.memo(
|
|
@@ -1771,7 +1982,7 @@
|
|
|
1771
1982
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1772
1983
|
reactToolbar.Root,
|
|
1773
1984
|
{
|
|
1774
|
-
className: classNames(className, "overmap-toolbar", styles$
|
|
1985
|
+
className: classNames(className, "overmap-toolbar", styles$7.default),
|
|
1775
1986
|
ref,
|
|
1776
1987
|
asChild: true,
|
|
1777
1988
|
...rest,
|
|
@@ -1812,7 +2023,7 @@
|
|
|
1812
2023
|
const ToastRoot = "_ToastRoot_1i6bp_24";
|
|
1813
2024
|
const slideIn = "_slideIn_1i6bp_1";
|
|
1814
2025
|
const swipeOut = "_swipeOut_1i6bp_1";
|
|
1815
|
-
const styles$
|
|
2026
|
+
const styles$6 = {
|
|
1816
2027
|
ToastViewport,
|
|
1817
2028
|
actionButton,
|
|
1818
2029
|
ToastRoot,
|
|
@@ -1830,7 +2041,7 @@
|
|
|
1830
2041
|
},
|
|
1831
2042
|
[onClose]
|
|
1832
2043
|
);
|
|
1833
|
-
return /* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Root, { asChild: true, ref, ...rest, open, type: sensitivity, onOpenChange: handleOpenChange, children: /* @__PURE__ */ jsxRuntime.jsx(themes.Callout.Root, { className: styles$
|
|
2044
|
+
return /* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Root, { asChild: true, ref, ...rest, open, type: sensitivity, onOpenChange: handleOpenChange, children: /* @__PURE__ */ jsxRuntime.jsx(themes.Callout.Root, { className: styles$6.ToastRoot, variant: "surface", color, size, children: /* @__PURE__ */ jsxRuntime.jsxs(themes.Flex, { width: "100%", align: "center", gap: "4", justify: "between", children: [
|
|
1834
2045
|
/* @__PURE__ */ jsxRuntime.jsxs(themes.Flex, { align: "center", gap: "3", children: [
|
|
1835
2046
|
/* @__PURE__ */ jsxRuntime.jsx(themes.Callout.Icon, { children: icon }),
|
|
1836
2047
|
/* @__PURE__ */ jsxRuntime.jsxs(themes.Flex, { direction: "column", gap: "2", children: [
|
|
@@ -1838,7 +2049,7 @@
|
|
|
1838
2049
|
/* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Title, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(themes.Callout.Text, { size: "3", weight: "medium", children: title }) }),
|
|
1839
2050
|
/* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Description, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(themes.Callout.Text, { children: description }) })
|
|
1840
2051
|
] }),
|
|
1841
|
-
action && /* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Action, { className: styles$
|
|
2052
|
+
action && /* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Action, { className: styles$6.actionButton, altText: action.altText, asChild: true, children: action.content })
|
|
1842
2053
|
] })
|
|
1843
2054
|
] }),
|
|
1844
2055
|
/* @__PURE__ */ jsxRuntime.jsx(RadixToast__namespace.Close, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(IconButton, { "aria-label": "Close", variant: "ghost", severity, children: /* @__PURE__ */ jsxRuntime.jsx(reactIcons.Cross2Icon, {}) }) })
|
|
@@ -1914,11 +2125,11 @@
|
|
|
1914
2125
|
}, []);
|
|
1915
2126
|
return /* @__PURE__ */ jsxRuntime.jsx(ToastContext.Provider, { value: toastContextValue, children: /* @__PURE__ */ jsxRuntime.jsxs(RadixToast.ToastProvider, { ...rest, children: [
|
|
1916
2127
|
children,
|
|
1917
|
-
/* @__PURE__ */ jsxRuntime.jsx(RadixToast.ToastViewport, { className: classNames(className, styles$
|
|
2128
|
+
/* @__PURE__ */ jsxRuntime.jsx(RadixToast.ToastViewport, { className: classNames(className, styles$6.ToastViewport), hotkey }),
|
|
1918
2129
|
toasts.map(({ id, onClose, ...toastProps }) => /* @__PURE__ */ jsxRuntime.jsx(Toast, { ...toastProps, onClose: () => handleCloseToast(id, 0, onClose) }, id))
|
|
1919
2130
|
] }) });
|
|
1920
2131
|
});
|
|
1921
|
-
const styles$
|
|
2132
|
+
const styles$5 = {
|
|
1922
2133
|
"default": "_default_1odpt_1"
|
|
1923
2134
|
};
|
|
1924
2135
|
const Tooltip = React.memo(
|
|
@@ -1926,7 +2137,7 @@
|
|
|
1926
2137
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1927
2138
|
themes.Tooltip,
|
|
1928
2139
|
{
|
|
1929
|
-
className: classNames("overmap-tooltip", className, styles$
|
|
2140
|
+
className: classNames("overmap-tooltip", className, styles$5.default),
|
|
1930
2141
|
ref,
|
|
1931
2142
|
content: /* @__PURE__ */ jsxRuntime.jsx(themes.Flex, { align: "center", gap: "1", width: "max-content", height: "max-content", justify: "center", children: content }),
|
|
1932
2143
|
...rest,
|
|
@@ -1936,10 +2147,10 @@
|
|
|
1936
2147
|
})
|
|
1937
2148
|
);
|
|
1938
2149
|
const noWrap = "_noWrap_1wpa5_1";
|
|
1939
|
-
const styles$
|
|
2150
|
+
const styles$4 = {
|
|
1940
2151
|
noWrap
|
|
1941
2152
|
};
|
|
1942
|
-
const Text = React.memo(
|
|
2153
|
+
const Text$1 = React.memo(
|
|
1943
2154
|
React.forwardRef(({ className, noWrap: noWrap2, severity, as, ...props }, ref) => {
|
|
1944
2155
|
const color = useSeverityColor(severity);
|
|
1945
2156
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1947,7 +2158,7 @@
|
|
|
1947
2158
|
{
|
|
1948
2159
|
ref,
|
|
1949
2160
|
as,
|
|
1950
|
-
className: classNames(className, { [styles$
|
|
2161
|
+
className: classNames(className, { [styles$4.noWrap]: noWrap2 }),
|
|
1951
2162
|
color,
|
|
1952
2163
|
...props
|
|
1953
2164
|
}
|
|
@@ -1961,6 +2172,60 @@
|
|
|
1961
2172
|
return /* @__PURE__ */ jsxRuntime.jsx(themes.Theme, { panelBackground, radius: radius2, ref, ...rest });
|
|
1962
2173
|
})
|
|
1963
2174
|
);
|
|
2175
|
+
const light = "_light_1u8fs_1";
|
|
2176
|
+
const bold = "_bold_1u8fs_8";
|
|
2177
|
+
const full = "_full_1u8fs_15";
|
|
2178
|
+
const Text = "_Text_1u8fs_22";
|
|
2179
|
+
const styles$3 = {
|
|
2180
|
+
light,
|
|
2181
|
+
bold,
|
|
2182
|
+
full,
|
|
2183
|
+
Text
|
|
2184
|
+
};
|
|
2185
|
+
const SeparatorSizeMapping = {
|
|
2186
|
+
"1": "max-content",
|
|
2187
|
+
"2": "max-content",
|
|
2188
|
+
"3": "max-content",
|
|
2189
|
+
"4": "100%"
|
|
2190
|
+
};
|
|
2191
|
+
const _Separator = React.forwardRef(function Separator2({
|
|
2192
|
+
className,
|
|
2193
|
+
severity = "info",
|
|
2194
|
+
textWeight = "light",
|
|
2195
|
+
gap = "1",
|
|
2196
|
+
text,
|
|
2197
|
+
orientation = "horizontal",
|
|
2198
|
+
size,
|
|
2199
|
+
weight = "medium",
|
|
2200
|
+
...rest
|
|
2201
|
+
}, ref) {
|
|
2202
|
+
const computedSizing = useResponsiveMapping(size, SeparatorSizeMapping);
|
|
2203
|
+
const severityColor = useSeverityColor(severity);
|
|
2204
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2205
|
+
themes.Flex,
|
|
2206
|
+
{
|
|
2207
|
+
className: classNames("overmap-separator", className, {
|
|
2208
|
+
[styles$3.light]: weight === "light",
|
|
2209
|
+
[styles$3.bold]: weight === "bold",
|
|
2210
|
+
[styles$3.full]: weight === "full"
|
|
2211
|
+
}),
|
|
2212
|
+
ref,
|
|
2213
|
+
width: orientation === "horizontal" ? computedSizing : "max-content",
|
|
2214
|
+
height: orientation === "vertical" ? computedSizing : "max-content",
|
|
2215
|
+
direction: orientation === "vertical" ? "column" : "row",
|
|
2216
|
+
align: "center",
|
|
2217
|
+
gap,
|
|
2218
|
+
children: [
|
|
2219
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.Separator, { size, orientation, color: severityColor, ...rest }),
|
|
2220
|
+
text && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2221
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.Text, { className: styles$3.Text, as: "span", size: "1", weight: textWeight, color: severityColor, children: text }),
|
|
2222
|
+
/* @__PURE__ */ jsxRuntime.jsx(themes.Separator, { size, orientation, color: severityColor, ...rest })
|
|
2223
|
+
] })
|
|
2224
|
+
]
|
|
2225
|
+
}
|
|
2226
|
+
);
|
|
2227
|
+
});
|
|
2228
|
+
const Separator = React.memo(_Separator);
|
|
1964
2229
|
function _extends() {
|
|
1965
2230
|
_extends = Object.assign ? Object.assign.bind() : function(target) {
|
|
1966
2231
|
for (var i = 1; i < arguments.length; i++) {
|
|
@@ -2839,9 +3104,6 @@
|
|
|
2839
3104
|
const tableSelect = select.useRowSelect(
|
|
2840
3105
|
tableData,
|
|
2841
3106
|
{
|
|
2842
|
-
// Don't know what the type is for these parameters. Not specified in the React Table Library docs
|
|
2843
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
2844
|
-
// @ts-ignore
|
|
2845
3107
|
onChange: (_action, state) => {
|
|
2846
3108
|
setSelected(state.ids);
|
|
2847
3109
|
}
|
|
@@ -2991,8 +3253,8 @@
|
|
|
2991
3253
|
}, [rowsPerPage, rows.length, numRowsPerPage, pagination$1, showPageNavigation]);
|
|
2992
3254
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: classNames({ [styles$1.tableContainer]: showContainer }), children: [
|
|
2993
3255
|
(!!title || !!description) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles$1.headerContainer, children: [
|
|
2994
|
-
!!title && /* @__PURE__ */ jsxRuntime.jsx(Text, { weight: "bold", size: "7", children: title }),
|
|
2995
|
-
!!description && /* @__PURE__ */ jsxRuntime.jsx(Text, { as: "div", children: description })
|
|
3256
|
+
!!title && /* @__PURE__ */ jsxRuntime.jsx(Text$1, { weight: "bold", size: "7", children: title }),
|
|
3257
|
+
!!description && /* @__PURE__ */ jsxRuntime.jsx(Text$1, { as: "div", children: description })
|
|
2996
3258
|
] }),
|
|
2997
3259
|
showTopBar && /* @__PURE__ */ jsxRuntime.jsxs(themes.Flex, { justify: "between", className: styles$1.tableTopContainer, children: [
|
|
2998
3260
|
/* @__PURE__ */ jsxRuntime.jsxs(themes.Flex, { gap: "2", children: [
|
|
@@ -3076,7 +3338,7 @@
|
|
|
3076
3338
|
cellClassName,
|
|
3077
3339
|
row[column.id].className
|
|
3078
3340
|
),
|
|
3079
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Text, { children: row[column.id].label })
|
|
3341
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Text$1, { children: row[column.id].label })
|
|
3080
3342
|
},
|
|
3081
3343
|
i
|
|
3082
3344
|
))
|
|
@@ -3337,10 +3599,6 @@
|
|
|
3337
3599
|
enumerable: true,
|
|
3338
3600
|
get: () => themes.Container
|
|
3339
3601
|
});
|
|
3340
|
-
Object.defineProperty(exports2, "ContextMenu", {
|
|
3341
|
-
enumerable: true,
|
|
3342
|
-
get: () => themes.ContextMenu
|
|
3343
|
-
});
|
|
3344
3602
|
Object.defineProperty(exports2, "Em", {
|
|
3345
3603
|
enumerable: true,
|
|
3346
3604
|
get: () => themes.Em
|
|
@@ -3437,7 +3695,13 @@
|
|
|
3437
3695
|
exports2.ConfirmEditInput = ConfirmEditInput;
|
|
3438
3696
|
exports2.DefaultTheme = DefaultTheme;
|
|
3439
3697
|
exports2.Dialog = Dialog;
|
|
3698
|
+
exports2.DropdownItemMenu = DropdownItemMenu;
|
|
3440
3699
|
exports2.DropdownMenu = DropdownMenu;
|
|
3700
|
+
exports2.DropdownMenuItemGroup = DropdownMenuItemGroup;
|
|
3701
|
+
exports2.DropdownMenuMultiSelectGroup = DropdownMenuMultiSelectGroup;
|
|
3702
|
+
exports2.DropdownMenuSelectGroup = DropdownMenuSelectGroup;
|
|
3703
|
+
exports2.DropdownMenuSubMenuGroup = DropdownMenuSubMenuGroup;
|
|
3704
|
+
exports2.DropdownMultiSelect = DropdownMultiSelect;
|
|
3441
3705
|
exports2.DropdownSelect = DropdownSelect;
|
|
3442
3706
|
exports2.Flex = Flex;
|
|
3443
3707
|
exports2.HoverUtility = HoverUtility;
|
|
@@ -3457,7 +3721,7 @@
|
|
|
3457
3721
|
exports2.Spinner = Spinner;
|
|
3458
3722
|
exports2.Switch = Switch;
|
|
3459
3723
|
exports2.Table = Table;
|
|
3460
|
-
exports2.Text = Text;
|
|
3724
|
+
exports2.Text = Text$1;
|
|
3461
3725
|
exports2.TextArea = TextArea;
|
|
3462
3726
|
exports2.Toast = Toast;
|
|
3463
3727
|
exports2.ToastContext = ToastContext;
|
|
@@ -3468,9 +3732,13 @@
|
|
|
3468
3732
|
exports2.divButtonProps = divButtonProps;
|
|
3469
3733
|
exports2.useAlertDialog = useAlertDialog;
|
|
3470
3734
|
exports2.useDiscardAlertDialog = useDiscardAlertDialog;
|
|
3735
|
+
exports2.useKeyboardShortcut = useKeyboardShortcut;
|
|
3471
3736
|
exports2.useSeverityColor = useSeverityColor;
|
|
3737
|
+
exports2.useStopEventPropagation = useStopEventPropagation;
|
|
3738
|
+
exports2.useTextFilter = useTextFilter;
|
|
3472
3739
|
exports2.useToast = useToast;
|
|
3473
3740
|
exports2.useViewportSize = useViewportSize;
|
|
3741
|
+
exports2.useWrapCallbackInDialogClose = useWrapCallbackInDialogClose;
|
|
3474
3742
|
Object.keys(colors).forEach((k) => {
|
|
3475
3743
|
if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports2, k))
|
|
3476
3744
|
Object.defineProperty(exports2, k, {
|