@aivenio/aquarium 1.53.0 → 1.55.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/system.mjs CHANGED
@@ -4681,7 +4681,7 @@ __export(molecules_exports, {
4681
4681
  InputBase: () => InputBase,
4682
4682
  LineClamp: () => LineClamp2,
4683
4683
  Link: () => Link2,
4684
- List: () => List2,
4684
+ List: () => List,
4685
4685
  ListItem: () => ListItem,
4686
4686
  Modal: () => Modal2,
4687
4687
  ModalTab: () => ModalTab,
@@ -4737,6 +4737,7 @@ __export(molecules_exports, {
4737
4737
  ToastProvider: () => ToastProvider,
4738
4738
  Tooltip: () => Tooltip,
4739
4739
  Typography: () => Typography2,
4740
+ areRowsGrouped: () => areRowsGrouped,
4740
4741
  asButton: () => asButton,
4741
4742
  asCrumb: () => asCrumb,
4742
4743
  asPopoverButton: () => asPopoverButton,
@@ -7378,6 +7379,7 @@ var Banner2 = ({ type, title, children, action, onDismiss }) => {
7378
7379
  }));
7379
7380
  };
7380
7381
  Alert2.Banner = Banner2;
7382
+ Alert2.displayName = "Alert";
7381
7383
  Alert2.Banner.displayName = "Alert.Banner";
7382
7384
 
7383
7385
  // src/molecules/Avatar/Avatar.tsx
@@ -9307,10 +9309,11 @@ var Container2 = ({ maxWidth = "xl", children }) => /* @__PURE__ */ React49.crea
9307
9309
  }, children);
9308
9310
 
9309
9311
  // src/molecules/DataList/DataList.tsx
9310
- import React67 from "react";
9312
+ import React69 from "react";
9311
9313
  import compact from "lodash/compact";
9312
9314
  import groupBy2 from "lodash/groupBy";
9313
- import isFunction from "lodash/isFunction";
9315
+ import isArray3 from "lodash/isArray";
9316
+ import isFunction3 from "lodash/isFunction";
9314
9317
 
9315
9318
  // src/molecules/Accordion/Accordion.tsx
9316
9319
  import React52, { createContext as createContext2, useContext as useContext5, useState as useState6 } from "react";
@@ -9501,17 +9504,14 @@ Accordion.Panel.displayName = "Accordion.Panel";
9501
9504
  Accordion.UnanimatedPanel = AccordionUnanimatedPanel;
9502
9505
  Accordion.UnanimatedPanel.displayName = "Accordion.UnanimatedPanel";
9503
9506
 
9504
- // src/molecules/DropdownMenu/DropdownMenu.tsx
9507
+ // src/molecules/List/List.tsx
9508
+ import React58 from "react";
9509
+ import isObject from "lodash/isObject";
9510
+ import isString from "lodash/isString";
9511
+
9512
+ // src/molecules/Pagination/Pagination.tsx
9505
9513
  import React56 from "react";
9506
- import { useFilter } from "@react-aria/i18n";
9507
- import { PressResponder, usePress } from "@react-aria/interactions";
9508
- import { useMenu, useMenuItem, useMenuSection, useMenuTrigger } from "@react-aria/menu";
9509
- import { useSeparator } from "@react-aria/separator";
9510
- import { mergeProps as mergeProps2 } from "@react-aria/utils";
9511
- import { Item as Item3, Section } from "@react-stately/collections";
9512
- import { useMenuTriggerState } from "@react-stately/menu";
9513
- import { useTreeState } from "@react-stately/tree";
9514
- import omit6 from "lodash/omit";
9514
+ import clamp from "lodash/clamp";
9515
9515
 
9516
9516
  // src/molecules/Input/Input.tsx
9517
9517
  import React54, { forwardRef, useEffect as useEffect7, useImperativeHandle, useState as useState7 } from "react";
@@ -9670,419 +9670,96 @@ Input2.displayName = "Input";
9670
9670
  Input2.Skeleton = () => /* @__PURE__ */ React54.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React54.createElement(InputBase.Skeleton, null));
9671
9671
  Input2.Skeleton.displayName = "Input.Skeleton";
9672
9672
 
9673
- // src/atoms/DropdownMenu/DropdownMenu.tsx
9674
- import React55 from "react";
9675
- var import_tick5 = __toESM(require_tick());
9676
- var DropdownMenu = React55.forwardRef(
9677
- (_a, ref) => {
9678
- var _b = _a, { minHeight, maxHeight = "100%", minWidth = "125px", maxWidth, className, children } = _b, props = __objRest(_b, ["minHeight", "maxHeight", "minWidth", "maxWidth", "className", "children"]);
9679
- return /* @__PURE__ */ React55.createElement("div", __spreadValues({
9680
- ref,
9681
- style: { minHeight, maxHeight, minWidth, maxWidth },
9682
- className: classNames(className, "bg-white w-full flex flex-col overflow-x-hidden typography-small text-grey-70")
9683
- }, props), children);
9684
- }
9685
- );
9686
- var ContentContainer = ({ children }) => /* @__PURE__ */ React55.createElement("div", {
9687
- className: tw("p-3 overflow-y-auto overflow-x-hidden")
9688
- }, children);
9689
- DropdownMenu.ContentContainer = ContentContainer;
9690
- var List = React55.forwardRef(
9691
- (_a, ref) => {
9692
- var _b = _a, { children, className } = _b, props = __objRest(_b, ["children", "className"]);
9693
- return /* @__PURE__ */ React55.createElement("ul", __spreadValues({
9694
- ref,
9695
- className: classNames(className, "outline-none ring-0")
9696
- }, props), children);
9697
- }
9698
- );
9699
- DropdownMenu.List = List;
9700
- var Group2 = React55.forwardRef(
9701
- (_a, ref) => {
9702
- var _b = _a, { className, title, titleProps, children } = _b, props = __objRest(_b, ["className", "title", "titleProps", "children"]);
9703
- return /* @__PURE__ */ React55.createElement("li", __spreadValues({
9704
- ref
9705
- }, props), title && /* @__PURE__ */ React55.createElement("div", __spreadValues({
9706
- className: classNames(className, "p-3 text-grey-40 uppercase cursor-default typography-caption", {
9707
- "text-grey-20": props.disabled
9708
- })
9709
- }, titleProps), title), children);
9710
- }
9711
- );
9712
- DropdownMenu.Group = Group2;
9713
- var Item2 = React55.forwardRef(
9714
- (_a, ref) => {
9715
- var _b = _a, { kind, highlighted, selected, className, icon, showNotification = false, children } = _b, props = __objRest(_b, ["kind", "highlighted", "selected", "className", "icon", "showNotification", "children"]);
9716
- return /* @__PURE__ */ React55.createElement("li", __spreadValues({
9717
- ref,
9718
- className: classNames(className, "flex items-center gap-x-3 p-3 outline-none", {
9719
- "cursor-pointer hover:bg-grey-0": !props.disabled,
9720
- "bg-grey-0": highlighted,
9721
- "text-primary-80": kind === "action",
9722
- "text-grey-20 cursor-not-allowed": props.disabled
9723
- })
9724
- }, props), icon && showNotification && /* @__PURE__ */ React55.createElement(Badge.Notification, null, /* @__PURE__ */ React55.createElement(InlineIcon, {
9725
- icon
9726
- })), icon && !showNotification && /* @__PURE__ */ React55.createElement(InlineIcon, {
9727
- icon
9728
- }), /* @__PURE__ */ React55.createElement("span", {
9729
- className: tw("grow")
9730
- }, children), selected && /* @__PURE__ */ React55.createElement(InlineIcon, {
9731
- icon: import_tick5.default
9732
- }));
9733
- }
9734
- );
9735
- DropdownMenu.Item = Item2;
9736
- var Description = ({ disabled, children }) => /* @__PURE__ */ React55.createElement(Typography2.Caption, {
9737
- color: disabled ? "grey-20" : "grey-40"
9738
- }, children);
9739
- DropdownMenu.Description = Description;
9740
- var Separator = (_a) => {
9741
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
9742
- return /* @__PURE__ */ React55.createElement("li", __spreadProps(__spreadValues({}, props), {
9743
- className: classNames(className, tw("m-3 block bg-grey-5 h-[1px]"))
9744
- }));
9673
+ // src/molecules/Select/Select.tsx
9674
+ import React55, { useRef as useRef6, useState as useState8 } from "react";
9675
+ import { useId as useId7 } from "@react-aria/utils";
9676
+ import { useSelect } from "downshift";
9677
+ import defaults from "lodash/defaults";
9678
+ import isArray from "lodash/isArray";
9679
+ import isNil from "lodash/isNil";
9680
+ import omit6 from "lodash/omit";
9681
+ var hasIconProperty = (val) => {
9682
+ var _a;
9683
+ return typeof val === "string" || ((_a = val == null ? void 0 : val.icon) == null ? void 0 : _a.body) !== void 0;
9745
9684
  };
9746
- DropdownMenu.Separator = Separator;
9747
- var EmptyStateContainer2 = (_a) => {
9748
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
9749
- return /* @__PURE__ */ React55.createElement("div", __spreadValues({
9750
- className: classNames(tw("border border-dashed border-grey-10 p-3"), className)
9751
- }, props), children);
9685
+ var hasOptionGroups = (val) => {
9686
+ return !val.some((opt) => (opt == null ? void 0 : opt.label) === void 0 || !isArray(opt == null ? void 0 : opt.options));
9752
9687
  };
9753
- DropdownMenu.EmptyStateContainer = EmptyStateContainer2;
9754
-
9755
- // src/molecules/DropdownMenu/utils.ts
9756
- import { ListCollection } from "@react-stately/list";
9757
- var filterCollection = (collection, inputValue, filter) => {
9758
- return new ListCollection(filterNodes(collection, inputValue, filter));
9688
+ var defaultRenderOption = (item, props, { selectedItem }, { getOptionKey, getValue, optionToString = getOptionLabelBuiltin }) => {
9689
+ var _a, _b;
9690
+ return /* @__PURE__ */ React55.createElement(Select.Item, __spreadValues({
9691
+ key: (_b = (_a = getOptionKey == null ? void 0 : getOptionKey(item)) != null ? _a : getValue == null ? void 0 : getValue(item)) != null ? _b : optionToString(item),
9692
+ selected: item === selectedItem
9693
+ }, props), hasIconProperty(item) && /* @__PURE__ */ React55.createElement(InlineIcon, {
9694
+ icon: item.icon
9695
+ }), optionToString(item));
9759
9696
  };
9760
- var filterNodes = (nodes, inputValue, filter) => {
9761
- const filteredNode = [];
9762
- for (const node of nodes) {
9763
- const description = Object.hasOwn(node.props, "description") && typeof node.props.description === "string" ? node.props.description : void 0;
9764
- if (node.type === "section" && node.hasChildNodes) {
9765
- const filtered = filterNodes(node.childNodes, inputValue, filter);
9766
- if ([...filtered].length > 0) {
9767
- filteredNode.push(__spreadProps(__spreadValues({}, node), { childNodes: filtered }));
9768
- }
9769
- } else if (node.type !== "section" && (filter(node.textValue, inputValue) || description && filter(description, inputValue))) {
9770
- filteredNode.push(__spreadValues({}, node));
9771
- }
9697
+ var defaultGetValue = (opt) => {
9698
+ if (typeof opt === "string") {
9699
+ return opt;
9772
9700
  }
9773
- return filteredNode;
9701
+ if (typeof opt.value === "string") {
9702
+ return opt.value;
9703
+ }
9704
+ return "";
9774
9705
  };
9775
-
9776
- // src/molecules/DropdownMenu/DropdownMenu.tsx
9777
- var DropdownMenu2 = (_a) => {
9778
- var _b = _a, {
9779
- onAction,
9780
- selectionMode,
9781
- selection,
9782
- onSelectionChange,
9783
- placement = "bottom-left",
9784
- minWidth,
9785
- maxWidth,
9786
- minHeight,
9706
+ var _SelectBase = (props) => {
9707
+ var _b;
9708
+ const withDefaults = defaults({}, props, {
9709
+ disabled: false,
9710
+ valid: true,
9711
+ readOnly: false,
9712
+ required: false,
9713
+ optionToString: getOptionLabelBuiltin,
9714
+ getValue: defaultGetValue,
9715
+ UNSAFE_renderOption: defaultRenderOption,
9716
+ isOptionDisabled: isOptionDisabledBuiltin,
9717
+ actions: []
9718
+ });
9719
+ const _a = withDefaults, {
9720
+ id,
9721
+ name,
9722
+ placeholder,
9723
+ disabled,
9724
+ readOnly,
9787
9725
  maxHeight,
9788
- searchable = false,
9726
+ options,
9727
+ optionToString: itemToString,
9728
+ getValue,
9729
+ getOptionKey,
9730
+ UNSAFE_renderOption,
9731
+ isOptionDisabled,
9732
+ defaultValue,
9733
+ value,
9734
+ onChange,
9735
+ valid,
9789
9736
  emptyState,
9790
- header,
9791
- footer,
9792
- children
9793
- } = _b, props = __objRest(_b, [
9794
- "onAction",
9795
- "selectionMode",
9796
- "selection",
9797
- "onSelectionChange",
9798
- "placement",
9799
- "minWidth",
9800
- "maxWidth",
9801
- "minHeight",
9737
+ actions,
9738
+ required,
9739
+ children,
9740
+ labelWrapper
9741
+ } = _a, rest = __objRest(_a, [
9742
+ "id",
9743
+ "name",
9744
+ "placeholder",
9745
+ "disabled",
9746
+ "readOnly",
9802
9747
  "maxHeight",
9803
- "searchable",
9748
+ "options",
9749
+ "optionToString",
9750
+ "getValue",
9751
+ "getOptionKey",
9752
+ "UNSAFE_renderOption",
9753
+ "isOptionDisabled",
9754
+ "defaultValue",
9755
+ "value",
9756
+ "onChange",
9757
+ "valid",
9804
9758
  "emptyState",
9805
- "header",
9806
- "footer",
9807
- "children"
9808
- ]);
9809
- const triggerRef = React56.useRef(null);
9810
- const [trigger, items] = extractTriggerAndItems(children);
9811
- const state = useMenuTriggerState(props);
9812
- const { menuTriggerProps, menuProps } = useMenuTrigger({}, state, triggerRef);
9813
- return /* @__PURE__ */ React56.createElement("div", null, /* @__PURE__ */ React56.createElement(PressResponder, __spreadValues({
9814
- ref: triggerRef,
9815
- onPress: () => state.toggle()
9816
- }, omit6(menuTriggerProps, ["id", "aria-expanded"])), /* @__PURE__ */ React56.createElement(TriggerWrapper, {
9817
- "aria-expanded": menuTriggerProps["aria-expanded"]
9818
- }, trigger.props.children)), state.isOpen && /* @__PURE__ */ React56.createElement(PopoverOverlay, {
9819
- className: "Aquarium-DropdownMenu",
9820
- triggerRef,
9821
- state,
9822
- placement,
9823
- focusable: false
9824
- }, /* @__PURE__ */ React56.createElement(MenuWrapper, __spreadValues({
9825
- onAction,
9826
- selectionMode,
9827
- selection,
9828
- onSelectionChange,
9829
- searchable,
9830
- emptyState,
9831
- minWidth,
9832
- maxWidth,
9833
- maxHeight,
9834
- minHeight,
9835
- header,
9836
- footer
9837
- }, menuProps), items.props.children)));
9838
- };
9839
- DropdownMenu2.displayName = "DropdownMenu";
9840
- var MenuTrigger = () => null;
9841
- var MenuItems = () => null;
9842
- DropdownMenu2.Trigger = MenuTrigger;
9843
- DropdownMenu2.Trigger.displayName = "DropdownMenu.Trigger";
9844
- DropdownMenu2.Items = MenuItems;
9845
- DropdownMenu2.Items.displayName = "DropdownMenu.Items";
9846
- DropdownMenu2.Item = Item3;
9847
- DropdownMenu2.Item.displayName = "DropdownMenu.Item";
9848
- DropdownMenu2.Section = Section;
9849
- DropdownMenu2.Section.displayName = "DropdownMenu.Section";
9850
- var TriggerWrapper = (_a) => {
9851
- var _b = _a, { children } = _b, props = __objRest(_b, ["children"]);
9852
- const ref = React56.useRef(null);
9853
- const { pressProps } = usePress(__spreadProps(__spreadValues({}, props), { ref }));
9854
- const trigger = React56.Children.only(children);
9855
- if (!trigger || !React56.isValidElement(trigger)) {
9856
- throw new Error("<DropdownMenu.Trigger> must have valid child");
9857
- }
9858
- return React56.cloneElement(trigger, __spreadValues({ ref }, mergeProps2(pressProps, props)));
9859
- };
9860
- var isSectionNode = (item) => item.type === "section";
9861
- var isItemNode = (item) => item.type === "item";
9862
- var MenuWrapper = (_a) => {
9863
- var _b = _a, {
9864
- selection: selectedKeys,
9865
- minWidth,
9866
- maxWidth,
9867
- minHeight,
9868
- maxHeight,
9869
- searchable,
9870
- emptyState,
9871
- header,
9872
- footer
9873
- } = _b, props = __objRest(_b, [
9874
- "selection",
9875
- "minWidth",
9876
- "maxWidth",
9877
- "minHeight",
9878
- "maxHeight",
9879
- "searchable",
9880
- "emptyState",
9881
- "header",
9882
- "footer"
9883
- ]);
9884
- const ref = React56.useRef(null);
9885
- const disabledKeys = getDisabledItemKeys(props.children);
9886
- const state = useTreeState(__spreadValues({
9887
- disabledKeys,
9888
- selectedKeys
9889
- }, props));
9890
- const { menuProps } = useMenu(props, state, ref);
9891
- const { contains } = useFilter({ sensitivity: "base" });
9892
- const [search, setSearch] = React56.useState("");
9893
- const filteredCollection = React56.useMemo(
9894
- () => searchable ? filterCollection(state.collection, search, contains) : state.collection,
9895
- [searchable, state.collection, search, contains]
9896
- );
9897
- return /* @__PURE__ */ React56.createElement(DropdownMenu, {
9898
- minWidth,
9899
- maxWidth,
9900
- minHeight,
9901
- maxHeight
9902
- }, header, /* @__PURE__ */ React56.createElement(DropdownMenu.ContentContainer, null, searchable && /* @__PURE__ */ React56.createElement(SearchInput, {
9903
- "aria-label": "search",
9904
- value: search,
9905
- onChange: (e) => setSearch(e.target.value),
9906
- className: tw("mb-5")
9907
- }), filteredCollection.size === 0 && emptyState && /* @__PURE__ */ React56.createElement(DropdownMenu.EmptyStateContainer, null, emptyState), /* @__PURE__ */ React56.createElement(DropdownMenu.List, __spreadValues({
9908
- ref
9909
- }, menuProps), Array.from(filteredCollection).map((item) => {
9910
- if (isSectionNode(item)) {
9911
- return /* @__PURE__ */ React56.createElement(SectionWrapper, {
9912
- key: item.key,
9913
- section: item,
9914
- state
9915
- });
9916
- } else if (isItemNode(item)) {
9917
- return /* @__PURE__ */ React56.createElement(ItemWrapper, {
9918
- key: item.key,
9919
- item,
9920
- state
9921
- });
9922
- }
9923
- }))), footer);
9924
- };
9925
- var ItemWrapper = ({ item, state }) => {
9926
- const ref = React56.useRef(null);
9927
- const { menuItemProps, descriptionProps, isSelected, isFocused, isDisabled } = useMenuItem(
9928
- { key: item.key, closeOnSelect: item.props.closeOnSelect },
9929
- state,
9930
- ref
9931
- );
9932
- const { icon, description, kind = "default", showNotification = false } = item.props;
9933
- return /* @__PURE__ */ React56.createElement(DropdownMenu.Item, __spreadProps(__spreadValues({
9934
- ref
9935
- }, menuItemProps), {
9936
- kind,
9937
- selected: isSelected,
9938
- highlighted: isFocused,
9939
- disabled: isDisabled,
9940
- icon,
9941
- showNotification
9942
- }), item.rendered, description && /* @__PURE__ */ React56.createElement(DropdownMenu.Description, __spreadValues({
9943
- disabled: isDisabled
9944
- }, descriptionProps), description));
9945
- };
9946
- var SectionWrapper = ({ section, state }) => {
9947
- const { itemProps, headingProps, groupProps } = useMenuSection({
9948
- "heading": section.rendered,
9949
- "aria-label": section["aria-label"]
9950
- });
9951
- const { separatorProps } = useSeparator({
9952
- elementType: "li"
9953
- });
9954
- return /* @__PURE__ */ React56.createElement(React56.Fragment, null, section.key !== state.collection.getFirstKey() && /* @__PURE__ */ React56.createElement(DropdownMenu.Separator, __spreadValues({}, separatorProps)), /* @__PURE__ */ React56.createElement(DropdownMenu.Group, __spreadValues({
9955
- title: section.rendered,
9956
- titleProps: headingProps
9957
- }, itemProps), /* @__PURE__ */ React56.createElement("ul", __spreadValues({}, groupProps), Array.from(section.childNodes).map((node) => /* @__PURE__ */ React56.createElement(ItemWrapper, {
9958
- key: node.key,
9959
- item: node,
9960
- state
9961
- })))));
9962
- };
9963
- var extractTriggerAndItems = (children) => {
9964
- const [trigger, items] = React56.Children.toArray(children);
9965
- if (!isComponentType(trigger, MenuTrigger) || !isComponentType(items, MenuItems)) {
9966
- throw new Error("<DropdownMenu> must have <DropdownMenu.Trigger> and <DropdownMenu.Items> defined");
9967
- }
9968
- return [trigger, items];
9969
- };
9970
- var getDisabledItemKeys = (children) => {
9971
- const keys = React56.Children.map(children, (child) => {
9972
- var _a, _b;
9973
- if (!child || typeof child === "function") {
9974
- return null;
9975
- }
9976
- if (isComponentType(child, Item3) && child.props.disabled) {
9977
- return (_b = (_a = child.key) == null ? void 0 : _a.toString()) != null ? _b : null;
9978
- }
9979
- if (isComponentType(child, Section)) {
9980
- return getDisabledItemKeys(child.props.children);
9981
- }
9982
- return null;
9983
- });
9984
- return keys.flat().filter((key) => key !== null);
9985
- };
9986
-
9987
- // src/molecules/List/List.tsx
9988
- import React60 from "react";
9989
- import isObject from "lodash/isObject";
9990
- import isString from "lodash/isString";
9991
-
9992
- // src/molecules/Pagination/Pagination.tsx
9993
- import React58 from "react";
9994
- import clamp from "lodash/clamp";
9995
-
9996
- // src/molecules/Select/Select.tsx
9997
- import React57, { useRef as useRef6, useState as useState8 } from "react";
9998
- import { useId as useId7 } from "@react-aria/utils";
9999
- import { useSelect } from "downshift";
10000
- import defaults from "lodash/defaults";
10001
- import isArray from "lodash/isArray";
10002
- import isNil from "lodash/isNil";
10003
- import omit7 from "lodash/omit";
10004
- var hasIconProperty = (val) => {
10005
- var _a;
10006
- return typeof val === "string" || ((_a = val == null ? void 0 : val.icon) == null ? void 0 : _a.body) !== void 0;
10007
- };
10008
- var hasOptionGroups = (val) => {
10009
- return !val.some((opt) => (opt == null ? void 0 : opt.label) === void 0 || !isArray(opt == null ? void 0 : opt.options));
10010
- };
10011
- var defaultRenderOption = (item, props, { selectedItem }, { getOptionKey, getValue, optionToString = getOptionLabelBuiltin }) => {
10012
- var _a, _b;
10013
- return /* @__PURE__ */ React57.createElement(Select.Item, __spreadValues({
10014
- key: (_b = (_a = getOptionKey == null ? void 0 : getOptionKey(item)) != null ? _a : getValue == null ? void 0 : getValue(item)) != null ? _b : optionToString(item),
10015
- selected: item === selectedItem
10016
- }, props), hasIconProperty(item) && /* @__PURE__ */ React57.createElement(InlineIcon, {
10017
- icon: item.icon
10018
- }), optionToString(item));
10019
- };
10020
- var defaultGetValue = (opt) => {
10021
- if (typeof opt === "string") {
10022
- return opt;
10023
- }
10024
- if (typeof opt.value === "string") {
10025
- return opt.value;
10026
- }
10027
- return "";
10028
- };
10029
- var _SelectBase = (props) => {
10030
- var _b;
10031
- const withDefaults = defaults({}, props, {
10032
- disabled: false,
10033
- valid: true,
10034
- readOnly: false,
10035
- required: false,
10036
- optionToString: getOptionLabelBuiltin,
10037
- getValue: defaultGetValue,
10038
- UNSAFE_renderOption: defaultRenderOption,
10039
- isOptionDisabled: isOptionDisabledBuiltin,
10040
- actions: []
10041
- });
10042
- const _a = withDefaults, {
10043
- id,
10044
- name,
10045
- placeholder,
10046
- disabled,
10047
- readOnly,
10048
- maxHeight,
10049
- options,
10050
- optionToString: itemToString,
10051
- getValue,
10052
- getOptionKey,
10053
- UNSAFE_renderOption,
10054
- isOptionDisabled,
10055
- defaultValue,
10056
- value,
10057
- onChange,
10058
- valid,
10059
- emptyState,
10060
- actions,
10061
- required,
10062
- children,
10063
- labelWrapper
10064
- } = _a, rest = __objRest(_a, [
10065
- "id",
10066
- "name",
10067
- "placeholder",
10068
- "disabled",
10069
- "readOnly",
10070
- "maxHeight",
10071
- "options",
10072
- "optionToString",
10073
- "getValue",
10074
- "getOptionKey",
10075
- "UNSAFE_renderOption",
10076
- "isOptionDisabled",
10077
- "defaultValue",
10078
- "value",
10079
- "onChange",
10080
- "valid",
10081
- "emptyState",
10082
- "actions",
10083
- "required",
10084
- "children",
10085
- "labelWrapper"
9759
+ "actions",
9760
+ "required",
9761
+ "children",
9762
+ "labelWrapper"
10086
9763
  ]);
10087
9764
  const [hasFocus, setFocus] = useState8(false);
10088
9765
  const targetRef = useRef6(null);
@@ -10133,13 +9810,13 @@ var _SelectBase = (props) => {
10133
9810
  },
10134
9811
  withDefaults
10135
9812
  );
10136
- const renderGroup = (group) => /* @__PURE__ */ React57.createElement(React57.Fragment, {
9813
+ const renderGroup = (group) => /* @__PURE__ */ React55.createElement(React55.Fragment, {
10137
9814
  key: group.label
10138
- }, /* @__PURE__ */ React57.createElement(Select.Group, null, group.label), group.options.map((opt) => renderItem(opt, items.indexOf(opt))));
10139
- const input = /* @__PURE__ */ React57.createElement(Select.InputContainer, __spreadProps(__spreadValues({}, getToggleButtonProps({ disabled: disabled || readOnly, ref: targetRef })), {
9815
+ }, /* @__PURE__ */ React55.createElement(Select.Group, null, group.label), group.options.map((opt) => renderItem(opt, items.indexOf(opt))));
9816
+ const input = /* @__PURE__ */ React55.createElement(Select.InputContainer, __spreadProps(__spreadValues({}, getToggleButtonProps({ disabled: disabled || readOnly, ref: targetRef })), {
10140
9817
  variant: disabled ? "disabled" : !valid ? "error" : readOnly ? "readOnly" : hasFocus ? "focused" : "default",
10141
9818
  tabIndex: 0
10142
- }), /* @__PURE__ */ React57.createElement(Select.Input, __spreadProps(__spreadValues({
9819
+ }), /* @__PURE__ */ React55.createElement(Select.Input, __spreadProps(__spreadValues({
10143
9820
  id,
10144
9821
  name
10145
9822
  }, rest), {
@@ -10151,25 +9828,25 @@ var _SelectBase = (props) => {
10151
9828
  tabIndex: -1,
10152
9829
  onFocus: () => setFocus(true),
10153
9830
  onBlur: () => setFocus(false)
10154
- })), !readOnly && /* @__PURE__ */ React57.createElement(Select.Toggle, {
9831
+ })), !readOnly && /* @__PURE__ */ React55.createElement(Select.Toggle, {
10155
9832
  disabled,
10156
9833
  isOpen,
10157
9834
  tabIndex: -1
10158
9835
  }));
10159
9836
  const menuProps = getMenuProps({ ref: menuRef }, { suppressRefError: !isOpen });
10160
- return /* @__PURE__ */ React57.createElement("div", {
9837
+ return /* @__PURE__ */ React55.createElement("div", {
10161
9838
  className: classNames("Aquarium-SelectBase", tw("relative"))
10162
- }, labelWrapper ? React57.cloneElement(labelWrapper, { children: input }) : input, isOpen && /* @__PURE__ */ React57.createElement(PopoverOverlay, {
9839
+ }, labelWrapper ? React55.cloneElement(labelWrapper, { children: input }) : input, isOpen && /* @__PURE__ */ React55.createElement(PopoverOverlay, {
10163
9840
  state,
10164
9841
  triggerRef: targetRef,
10165
9842
  placement: "bottom-left",
10166
9843
  shouldFlip: true,
10167
9844
  style: { width: (_b = targetRef.current) == null ? void 0 : _b.offsetWidth }
10168
- }, /* @__PURE__ */ React57.createElement(Select.Menu, __spreadValues({
9845
+ }, /* @__PURE__ */ React55.createElement(Select.Menu, __spreadValues({
10169
9846
  maxHeight
10170
- }, menuProps), options.length === 0 && /* @__PURE__ */ React57.createElement(Select.EmptyStateContainer, null, emptyState), options.length > 0 && !hasOptionGroups(options) && options.map(renderItem), options.length > 0 && hasOptionGroups(options) && options.map(renderGroup), actions.length > 0 && /* @__PURE__ */ React57.createElement(React57.Fragment, null, /* @__PURE__ */ React57.createElement(Select.Divider, {
9847
+ }, menuProps), options.length === 0 && /* @__PURE__ */ React55.createElement(Select.EmptyStateContainer, null, emptyState), options.length > 0 && !hasOptionGroups(options) && options.map(renderItem), options.length > 0 && hasOptionGroups(options) && options.map(renderGroup), actions.length > 0 && /* @__PURE__ */ React55.createElement(React55.Fragment, null, /* @__PURE__ */ React55.createElement(Select.Divider, {
10171
9848
  onMouseOver: () => setHighlightedIndex(-1)
10172
- }), actions.map((act, index) => /* @__PURE__ */ React57.createElement(Select.ActionItem, __spreadProps(__spreadValues({
9849
+ }), actions.map((act, index) => /* @__PURE__ */ React55.createElement(Select.ActionItem, __spreadProps(__spreadValues({
10173
9850
  key: `${index}`
10174
9851
  }, act), {
10175
9852
  onMouseOver: () => setHighlightedIndex(-1),
@@ -10179,10 +9856,10 @@ var _SelectBase = (props) => {
10179
9856
  }
10180
9857
  }), act.label))))));
10181
9858
  };
10182
- var SelectBase = (props) => /* @__PURE__ */ React57.createElement(_SelectBase, __spreadProps(__spreadValues({}, props), {
9859
+ var SelectBase = (props) => /* @__PURE__ */ React55.createElement(_SelectBase, __spreadProps(__spreadValues({}, props), {
10183
9860
  labelWrapper: void 0
10184
9861
  }));
10185
- var SelectBaseSkeleton = () => /* @__PURE__ */ React57.createElement(Skeleton, {
9862
+ var SelectBaseSkeleton = () => /* @__PURE__ */ React55.createElement(Skeleton, {
10186
9863
  height: 38
10187
9864
  });
10188
9865
  SelectBase.Skeleton = SelectBaseSkeleton;
@@ -10198,24 +9875,24 @@ var Select2 = (_a) => {
10198
9875
  const errorMessageId = useId7();
10199
9876
  const errorProps = props.valid === false ? { "aria-invalid": true, "aria-describedby": errorMessageId } : {};
10200
9877
  const labelProps = getLabelControlProps(props);
10201
- const baseProps = omit7(props, Object.keys(labelProps));
9878
+ const baseProps = omit6(props, Object.keys(labelProps));
10202
9879
  const legacyError = labelProps.error !== void 0 && labelProps.valid === false;
10203
9880
  const variant = !labelProps.valid || legacyError ? "error" : labelProps.disabled ? "disabled" : "default";
10204
- const label = /* @__PURE__ */ React57.createElement(Label, __spreadValues({
9881
+ const label = /* @__PURE__ */ React55.createElement(Label, __spreadValues({
10205
9882
  id: `${id}-label`,
10206
9883
  htmlFor: `${id}-input`,
10207
9884
  variant,
10208
9885
  messageId: errorMessageId
10209
9886
  }, labelProps));
10210
- return /* @__PURE__ */ React57.createElement(FormControl, {
9887
+ return /* @__PURE__ */ React55.createElement(FormControl, {
10211
9888
  className: "Aquarium-Select"
10212
- }, /* @__PURE__ */ React57.createElement(_SelectBase, __spreadProps(__spreadValues(__spreadValues({}, baseProps), errorProps), {
9889
+ }, /* @__PURE__ */ React55.createElement(_SelectBase, __spreadProps(__spreadValues(__spreadValues({}, baseProps), errorProps), {
10213
9890
  id: `${id}-input`,
10214
9891
  options,
10215
9892
  disabled: props.disabled,
10216
9893
  valid: props.valid,
10217
9894
  labelWrapper: label
10218
- })), /* @__PURE__ */ React57.createElement(HelperText, {
9895
+ })), /* @__PURE__ */ React55.createElement(HelperText, {
10219
9896
  messageId: errorMessageId,
10220
9897
  error: !labelProps.valid,
10221
9898
  helperText: labelProps.helperText,
@@ -10224,7 +9901,7 @@ var Select2 = (_a) => {
10224
9901
  reserveSpaceForError: labelProps.reserveSpaceForError
10225
9902
  }));
10226
9903
  };
10227
- var SelectSkeleton = () => /* @__PURE__ */ React57.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React57.createElement(SelectBase.Skeleton, null));
9904
+ var SelectSkeleton = () => /* @__PURE__ */ React55.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React55.createElement(SelectBase.Skeleton, null));
10228
9905
  Select2.Skeleton = SelectSkeleton;
10229
9906
  Select2.Skeleton.displayName = "Select.Skeleton";
10230
9907
 
@@ -10243,26 +9920,26 @@ var Pagination = ({
10243
9920
  pageSizes,
10244
9921
  onPageSizeChange
10245
9922
  }) => {
10246
- const [value, setValue] = React58.useState(currentPage);
10247
- React58.useEffect(() => {
9923
+ const [value, setValue] = React56.useState(currentPage);
9924
+ React56.useEffect(() => {
10248
9925
  setValue(currentPage);
10249
9926
  }, [currentPage]);
10250
- return /* @__PURE__ */ React58.createElement(Box, {
9927
+ return /* @__PURE__ */ React56.createElement(Box, {
10251
9928
  className: classNames(
10252
9929
  "Aquarium-Pagination",
10253
9930
  tw({ "grid grid-cols-[200px_1fr_200px]": !!pageSizes, "flex flex-nowrap justify-center": !pageSizes })
10254
9931
  ),
10255
9932
  backgroundColor: "grey-0",
10256
9933
  padding: "4"
10257
- }, pageSizes && onPageSizeChange && typeof pageSize === "number" ? /* @__PURE__ */ React58.createElement(Box, {
9934
+ }, pageSizes && onPageSizeChange && typeof pageSize === "number" ? /* @__PURE__ */ React56.createElement(Box, {
10258
9935
  display: "flex",
10259
9936
  alignItems: "center",
10260
9937
  gap: "4"
10261
- }, /* @__PURE__ */ React58.createElement(Typography2.Small, {
9938
+ }, /* @__PURE__ */ React56.createElement(Typography2.Small, {
10262
9939
  color: "grey-50"
10263
- }, "Items per page "), /* @__PURE__ */ React58.createElement("div", {
9940
+ }, "Items per page "), /* @__PURE__ */ React56.createElement("div", {
10264
9941
  className: tw("max-w-[70px]")
10265
- }, /* @__PURE__ */ React58.createElement(SelectBase, {
9942
+ }, /* @__PURE__ */ React56.createElement(SelectBase, {
10266
9943
  "aria-label": "Items per page",
10267
9944
  options: pageSizes.map((size) => size.toString()),
10268
9945
  value: pageSize.toString(),
@@ -10274,26 +9951,26 @@ var Pagination = ({
10274
9951
  }
10275
9952
  }
10276
9953
  }
10277
- }))) : /* @__PURE__ */ React58.createElement("div", null), /* @__PURE__ */ React58.createElement(Box, {
9954
+ }))) : /* @__PURE__ */ React56.createElement("div", null), /* @__PURE__ */ React56.createElement(Box, {
10278
9955
  display: "flex",
10279
9956
  justifyContent: "center",
10280
9957
  alignItems: "center",
10281
9958
  className: tw("grow")
10282
- }, /* @__PURE__ */ React58.createElement(Button.Icon, {
9959
+ }, /* @__PURE__ */ React56.createElement(Button.Icon, {
10283
9960
  "aria-label": "First",
10284
9961
  onClick: () => onPageChange(1),
10285
9962
  icon: import_chevronBackward2.default,
10286
9963
  disabled: !hasPreviousPage
10287
- }), /* @__PURE__ */ React58.createElement(Button.Icon, {
9964
+ }), /* @__PURE__ */ React56.createElement(Button.Icon, {
10288
9965
  "aria-label": "Previous",
10289
9966
  onClick: () => onPageChange(currentPage - 1),
10290
9967
  icon: import_chevronLeft3.default,
10291
9968
  disabled: !hasPreviousPage
10292
- }), /* @__PURE__ */ React58.createElement(Box, {
9969
+ }), /* @__PURE__ */ React56.createElement(Box, {
10293
9970
  paddingX: "4"
10294
- }, /* @__PURE__ */ React58.createElement(Typography2.Small, {
9971
+ }, /* @__PURE__ */ React56.createElement(Typography2.Small, {
10295
9972
  color: "grey-60"
10296
- }, "Page")), /* @__PURE__ */ React58.createElement(InputBase, {
9973
+ }, "Page")), /* @__PURE__ */ React56.createElement(InputBase, {
10297
9974
  "aria-label": "Page",
10298
9975
  className: classNames(tw("text-center max-w-[40px]"), "no-arrows"),
10299
9976
  type: "number",
@@ -10311,21 +9988,21 @@ var Pagination = ({
10311
9988
  const newPage = !isNaN(numberValue) ? clamp(numberValue, 1, totalPages) : 1;
10312
9989
  onPageChange(newPage);
10313
9990
  }
10314
- }), /* @__PURE__ */ React58.createElement(Box, {
9991
+ }), /* @__PURE__ */ React56.createElement(Box, {
10315
9992
  paddingX: "4"
10316
- }, /* @__PURE__ */ React58.createElement(Typography2.Small, {
9993
+ }, /* @__PURE__ */ React56.createElement(Typography2.Small, {
10317
9994
  color: "grey-60"
10318
- }, "of ", totalPages)), /* @__PURE__ */ React58.createElement(Button.Icon, {
9995
+ }, "of ", totalPages)), /* @__PURE__ */ React56.createElement(Button.Icon, {
10319
9996
  "aria-label": "Next",
10320
9997
  onClick: () => onPageChange(currentPage + 1),
10321
9998
  icon: import_chevronRight3.default,
10322
9999
  disabled: !hasNextPage
10323
- }), /* @__PURE__ */ React58.createElement(Button.Icon, {
10000
+ }), /* @__PURE__ */ React56.createElement(Button.Icon, {
10324
10001
  "aria-label": "Last",
10325
10002
  onClick: () => onPageChange(totalPages),
10326
10003
  icon: import_chevronForward2.default,
10327
10004
  disabled: !hasNextPage
10328
- })), pageSizes && /* @__PURE__ */ React58.createElement("div", null));
10005
+ })), pageSizes && /* @__PURE__ */ React56.createElement("div", null));
10329
10006
  };
10330
10007
 
10331
10008
  // src/molecules/Pagination/usePagination.tsx
@@ -10366,7 +10043,7 @@ var usePagination = (items, options) => {
10366
10043
  };
10367
10044
 
10368
10045
  // src/utils/useInView.ts
10369
- import React59 from "react";
10046
+ import React57 from "react";
10370
10047
  var useInView = ({
10371
10048
  onChange,
10372
10049
  skip,
@@ -10374,12 +10051,12 @@ var useInView = ({
10374
10051
  rootMargin,
10375
10052
  threshold = 0
10376
10053
  }) => {
10377
- const ref = React59.useRef(null);
10378
- const [state, setState] = React59.useState({
10054
+ const ref = React57.useRef(null);
10055
+ const [state, setState] = React57.useState({
10379
10056
  inView: false,
10380
10057
  entry: void 0
10381
10058
  });
10382
- React59.useEffect(() => {
10059
+ React57.useEffect(() => {
10383
10060
  const target = ref.current;
10384
10061
  if (skip || !target) {
10385
10062
  return;
@@ -10411,12 +10088,12 @@ var useInView = ({
10411
10088
 
10412
10089
  // src/molecules/List/List.tsx
10413
10090
  var import_loading3 = __toESM(require_loading());
10414
- var List2 = (_a) => {
10091
+ var List = (_a) => {
10415
10092
  var _b = _a, {
10416
10093
  items,
10417
10094
  renderItem,
10418
- container = React60.Fragment,
10419
- paginationContainer = React60.Fragment,
10095
+ container = React58.Fragment,
10096
+ paginationContainer = React58.Fragment,
10420
10097
  pagination,
10421
10098
  loadingIndicator = "Loading more items",
10422
10099
  hasMore,
@@ -10436,7 +10113,7 @@ var List2 = (_a) => {
10436
10113
  const Component = container;
10437
10114
  const PaginationComponent = paginationContainer;
10438
10115
  const paginationProps = isObject(pagination) ? pagination : void 0;
10439
- const onChange = React60.useCallback(
10116
+ const onChange = React58.useCallback(
10440
10117
  (inView) => {
10441
10118
  if (inView && hasMore && !isLoading) {
10442
10119
  next();
@@ -10454,7 +10131,7 @@ var List2 = (_a) => {
10454
10131
  const listItems = pagination ? paginatedItems : items;
10455
10132
  const showLoader = isInfinite && hasMore;
10456
10133
  const showPagination = pagination || showLoader;
10457
- return /* @__PURE__ */ React60.createElement(React60.Fragment, null, /* @__PURE__ */ React60.createElement(Component, null, listItems.map(renderItem)), showPagination && /* @__PURE__ */ React60.createElement(PaginationComponent, null, showLoader && /* @__PURE__ */ React60.createElement("div", {
10134
+ return /* @__PURE__ */ React58.createElement(React58.Fragment, null, /* @__PURE__ */ React58.createElement(Component, null, listItems.map(renderItem)), showPagination && /* @__PURE__ */ React58.createElement(PaginationComponent, null, showLoader && /* @__PURE__ */ React58.createElement("div", {
10458
10135
  ref,
10459
10136
  "aria-hidden": !isLoading,
10460
10137
  "aria-busy": isLoading,
@@ -10463,17 +10140,17 @@ var List2 = (_a) => {
10463
10140
  "flex gap-4 py-3 justify-center items-center transition-opacity duration-200",
10464
10141
  isLoading ? "opacity-100" : "opacity-0"
10465
10142
  )
10466
- }, /* @__PURE__ */ React60.createElement(Icon, {
10143
+ }, /* @__PURE__ */ React58.createElement(Icon, {
10467
10144
  width: 22,
10468
10145
  icon: import_loading3.default,
10469
10146
  className: tw("text-grey-50")
10470
- }), /* @__PURE__ */ React60.createElement(Typography2.Small, {
10147
+ }), /* @__PURE__ */ React58.createElement(Typography2.Small, {
10471
10148
  color: "grey-70"
10472
- }, loadingIndicator)), pagination && /* @__PURE__ */ React60.createElement(Pagination, __spreadValues(__spreadValues({}, paginationState), paginationProps))));
10149
+ }, loadingIndicator)), pagination && /* @__PURE__ */ React58.createElement(Pagination, __spreadValues(__spreadValues({}, paginationState), paginationProps))));
10473
10150
  };
10474
10151
 
10475
10152
  // src/molecules/Template/Template.tsx
10476
- import React61 from "react";
10153
+ import React59 from "react";
10477
10154
  var Template = (_a) => {
10478
10155
  var _b = _a, {
10479
10156
  columns,
@@ -10488,31 +10165,42 @@ var Template = (_a) => {
10488
10165
  "fullHeight",
10489
10166
  "style"
10490
10167
  ]);
10491
- const gridTemplateColumns = typeof columns === "number" ? "1fr ".repeat(columns) : columns.map((column) => typeof column === "number" ? `${column}px` : column === "auto" ? column : `${column}fr`).join(" ");
10168
+ const gridTemplateColumns = typeof columns === "number" ? "1fr ".repeat(columns) : columns.map((column) => {
10169
+ if (typeof column === "number") {
10170
+ return `${column}px`;
10171
+ }
10172
+ if (column === "auto") {
10173
+ return column;
10174
+ }
10175
+ if (column.startsWith("fit-content")) {
10176
+ return column;
10177
+ }
10178
+ return `${column}fr`;
10179
+ }).join(" ");
10492
10180
  const styles = useStyle({
10493
10181
  height: fullHeight ? "100%" : void 0,
10494
10182
  gridTemplateColumns,
10495
10183
  rowGap,
10496
10184
  columnGap
10497
10185
  });
10498
- return /* @__PURE__ */ React61.createElement(Box, __spreadProps(__spreadValues({}, props), {
10186
+ return /* @__PURE__ */ React59.createElement(Box, __spreadProps(__spreadValues({}, props), {
10499
10187
  display: "grid",
10500
10188
  style: __spreadValues(__spreadValues({}, styles), style)
10501
10189
  }));
10502
10190
  };
10503
10191
 
10504
10192
  // src/atoms/DataList/DataList.tsx
10505
- import React64 from "react";
10193
+ import React62 from "react";
10506
10194
 
10507
10195
  // src/atoms/Table/Table.tsx
10508
- import React63 from "react";
10196
+ import React61 from "react";
10509
10197
 
10510
10198
  // src/atoms/RadioButton/RadioButton.tsx
10511
- import React62 from "react";
10512
- var RadioButton = React62.forwardRef(
10199
+ import React60 from "react";
10200
+ var RadioButton = React60.forwardRef(
10513
10201
  (_a, ref) => {
10514
10202
  var _b = _a, { id, children, name, disabled = false, readOnly = false } = _b, props = __objRest(_b, ["id", "children", "name", "disabled", "readOnly"]);
10515
- return /* @__PURE__ */ React62.createElement("input", __spreadProps(__spreadValues({
10203
+ return /* @__PURE__ */ React60.createElement("input", __spreadProps(__spreadValues({
10516
10204
  id,
10517
10205
  ref,
10518
10206
  type: "radio",
@@ -10538,29 +10226,29 @@ var RadioButton = React62.forwardRef(
10538
10226
  // src/atoms/Table/Table.tsx
10539
10227
  var import_chevronDown4 = __toESM(require_chevronDown());
10540
10228
  var import_chevronUp3 = __toESM(require_chevronUp());
10541
- var HeadContext = React63.createContext(null);
10229
+ var HeadContext = React61.createContext(null);
10542
10230
  var tableClassNames = tw("w-full relative typography-default border-spacing-0");
10543
10231
  var Table = (_a) => {
10544
10232
  var _b = _a, { children, ariaLabel, className } = _b, rest = __objRest(_b, ["children", "ariaLabel", "className"]);
10545
- return /* @__PURE__ */ React63.createElement("table", __spreadProps(__spreadValues({}, rest), {
10233
+ return /* @__PURE__ */ React61.createElement("table", __spreadProps(__spreadValues({}, rest), {
10546
10234
  className: classNames(tableClassNames, className),
10547
10235
  "aria-label": ariaLabel
10548
10236
  }), children);
10549
10237
  };
10550
10238
  var TableHead = (_a) => {
10551
10239
  var _b = _a, { children, sticky } = _b, rest = __objRest(_b, ["children", "sticky"]);
10552
- return /* @__PURE__ */ React63.createElement("thead", __spreadValues({}, rest), /* @__PURE__ */ React63.createElement("tr", null, /* @__PURE__ */ React63.createElement(HeadContext.Provider, {
10240
+ return /* @__PURE__ */ React61.createElement("thead", __spreadValues({}, rest), /* @__PURE__ */ React61.createElement("tr", null, /* @__PURE__ */ React61.createElement(HeadContext.Provider, {
10553
10241
  value: { children, sticky }
10554
10242
  }, children)));
10555
10243
  };
10556
10244
  var TableBody = (_a) => {
10557
10245
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
10558
- return /* @__PURE__ */ React63.createElement("tbody", __spreadValues({}, rest), children);
10246
+ return /* @__PURE__ */ React61.createElement("tbody", __spreadValues({}, rest), children);
10559
10247
  };
10560
10248
  var rowClassNames = tw("children:border-grey-10 group children:last:border-b-0 hover:bg-grey-0");
10561
10249
  var TableRow = (_a) => {
10562
10250
  var _b = _a, { children, className, disabled } = _b, rest = __objRest(_b, ["children", "className", "disabled"]);
10563
- return /* @__PURE__ */ React63.createElement("tr", __spreadProps(__spreadValues(__spreadValues({}, rest), { inert: disabled ? "" : void 0 }), {
10251
+ return /* @__PURE__ */ React61.createElement("tr", __spreadProps(__spreadValues(__spreadValues({}, rest), { inert: disabled ? "" : void 0 }), {
10564
10252
  className: classNames(rowClassNames, className, {
10565
10253
  "opacity-70": disabled
10566
10254
  })
@@ -10589,15 +10277,15 @@ var getHeadCellClassNames = (sticky = true, stickyColumn) => {
10589
10277
  };
10590
10278
  var TableCell = (_a) => {
10591
10279
  var _b = _a, { children, className, stickyColumn, align = "left" } = _b, rest = __objRest(_b, ["children", "className", "stickyColumn", "align"]);
10592
- const headContext = React63.useContext(HeadContext);
10593
- return headContext ? /* @__PURE__ */ React63.createElement("th", __spreadProps(__spreadValues({}, rest), {
10280
+ const headContext = React61.useContext(HeadContext);
10281
+ return headContext ? /* @__PURE__ */ React61.createElement("th", __spreadProps(__spreadValues({}, rest), {
10594
10282
  className: classNames(
10595
10283
  cellClassNames,
10596
10284
  getHeadCellClassNames(headContext.sticky, stickyColumn),
10597
10285
  getAlignClassNames(align),
10598
10286
  className
10599
10287
  )
10600
- }), children) : /* @__PURE__ */ React63.createElement("td", __spreadProps(__spreadValues({}, rest), {
10288
+ }), children) : /* @__PURE__ */ React61.createElement("td", __spreadProps(__spreadValues({}, rest), {
10601
10289
  className: classNames(
10602
10290
  cellClassNames,
10603
10291
  getBodyCellClassNames(true, stickyColumn),
@@ -10608,11 +10296,11 @@ var TableCell = (_a) => {
10608
10296
  };
10609
10297
  var TableSelectCell = (_a) => {
10610
10298
  var _b = _a, { ariaLabel } = _b, props = __objRest(_b, ["ariaLabel"]);
10611
- return /* @__PURE__ */ React63.createElement(Table.Cell, {
10299
+ return /* @__PURE__ */ React61.createElement(Table.Cell, {
10612
10300
  className: tw("leading-[0px]")
10613
- }, props.type === "radio" ? /* @__PURE__ */ React63.createElement(RadioButton, __spreadValues({
10301
+ }, props.type === "radio" ? /* @__PURE__ */ React61.createElement(RadioButton, __spreadValues({
10614
10302
  "aria-label": ariaLabel
10615
- }, props)) : /* @__PURE__ */ React63.createElement(Checkbox, __spreadValues({
10303
+ }, props)) : /* @__PURE__ */ React61.createElement(Checkbox, __spreadValues({
10616
10304
  "aria-label": ariaLabel
10617
10305
  }, props)));
10618
10306
  };
@@ -10622,42 +10310,42 @@ var getSortCellIconClassNames = (active) => {
10622
10310
  };
10623
10311
  var TableSortCell = (_a) => {
10624
10312
  var _b = _a, { children, direction = "none", onClick } = _b, rest = __objRest(_b, ["children", "direction", "onClick"]);
10625
- return /* @__PURE__ */ React63.createElement(Table.Cell, __spreadProps(__spreadValues({}, rest), {
10313
+ return /* @__PURE__ */ React61.createElement(Table.Cell, __spreadProps(__spreadValues({}, rest), {
10626
10314
  "aria-sort": direction
10627
- }), /* @__PURE__ */ React63.createElement("span", {
10315
+ }), /* @__PURE__ */ React61.createElement("span", {
10628
10316
  className: getSortCellButtonClassNames(rest.align),
10629
10317
  role: "button",
10630
10318
  tabIndex: -1,
10631
10319
  onClick
10632
- }, children, /* @__PURE__ */ React63.createElement("div", {
10320
+ }, children, /* @__PURE__ */ React61.createElement("div", {
10633
10321
  "data-sort-icons": true,
10634
10322
  className: tw("flex flex-col", {
10635
10323
  "invisible group-hover:visible": direction === "none"
10636
10324
  })
10637
- }, /* @__PURE__ */ React63.createElement(InlineIcon, {
10325
+ }, /* @__PURE__ */ React61.createElement(InlineIcon, {
10638
10326
  icon: import_chevronUp3.default,
10639
10327
  className: getSortCellIconClassNames(direction === "ascending")
10640
- }), /* @__PURE__ */ React63.createElement(InlineIcon, {
10328
+ }), /* @__PURE__ */ React61.createElement(InlineIcon, {
10641
10329
  icon: import_chevronDown4.default,
10642
10330
  className: getSortCellIconClassNames(direction === "descending")
10643
10331
  }))));
10644
10332
  };
10645
- var Caption = ({ children }) => /* @__PURE__ */ React63.createElement(Typography2.Caption, {
10333
+ var Caption = ({ children }) => /* @__PURE__ */ React61.createElement(Typography2.Caption, {
10646
10334
  htmlTag: "caption"
10647
10335
  }, children);
10648
- var Item4 = ({ image, imageAlt, imageSize = 35, title, caption }) => /* @__PURE__ */ React63.createElement("div", {
10336
+ var Item2 = ({ image, imageAlt, imageSize = 35, title, caption }) => /* @__PURE__ */ React61.createElement("div", {
10649
10337
  className: tw("flex gap-4 items-center")
10650
- }, image && /* @__PURE__ */ React63.createElement("img", {
10338
+ }, image && /* @__PURE__ */ React61.createElement("img", {
10651
10339
  src: image,
10652
10340
  alt: imageAlt != null ? imageAlt : "",
10653
10341
  style: { width: imageSize, height: imageSize }
10654
- }), /* @__PURE__ */ React63.createElement("div", null, title, caption && /* @__PURE__ */ React63.createElement(Typography2.Caption, null, caption)));
10655
- Table.Head = React63.memo(TableHead);
10656
- Table.Body = React63.memo(TableBody);
10657
- Table.Row = React63.memo(TableRow);
10658
- Table.Cell = React63.memo(TableCell);
10659
- Table.SortCell = React63.memo(TableSortCell);
10660
- Table.SelectCell = React63.memo(TableSelectCell);
10342
+ }), /* @__PURE__ */ React61.createElement("div", null, title, caption && /* @__PURE__ */ React61.createElement(Typography2.Caption, null, caption)));
10343
+ Table.Head = React61.memo(TableHead);
10344
+ Table.Body = React61.memo(TableBody);
10345
+ Table.Row = React61.memo(TableRow);
10346
+ Table.Cell = React61.memo(TableCell);
10347
+ Table.SortCell = React61.memo(TableSortCell);
10348
+ Table.SelectCell = React61.memo(TableSelectCell);
10661
10349
  Table.Caption = Caption;
10662
10350
 
10663
10351
  // src/atoms/DataList/DataList.tsx
@@ -10670,7 +10358,7 @@ var getAlignClassNames2 = (align) => tw("flex items-center", {
10670
10358
  });
10671
10359
  var DataList = (_a) => {
10672
10360
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
10673
- return /* @__PURE__ */ React64.createElement("div", __spreadValues({}, rest));
10361
+ return /* @__PURE__ */ React62.createElement("div", __spreadValues({}, rest));
10674
10362
  };
10675
10363
  var HeadCell = (_a) => {
10676
10364
  var _b = _a, {
@@ -10684,8 +10372,8 @@ var HeadCell = (_a) => {
10684
10372
  "align",
10685
10373
  "stickyColumn"
10686
10374
  ]);
10687
- return /* @__PURE__ */ React64.createElement("div", __spreadProps(__spreadValues({
10688
- role: "cell"
10375
+ return /* @__PURE__ */ React62.createElement("div", __spreadProps(__spreadValues({
10376
+ role: "columnheader"
10689
10377
  }, rest), {
10690
10378
  className: classNames(
10691
10379
  cellClassNames,
@@ -10705,32 +10393,44 @@ var Cell = (_a) => {
10705
10393
  "align",
10706
10394
  "stickyColumn"
10707
10395
  ]);
10708
- return /* @__PURE__ */ React64.createElement("div", __spreadProps(__spreadValues({}, rest), {
10396
+ return /* @__PURE__ */ React62.createElement("div", __spreadProps(__spreadValues({}, rest), {
10709
10397
  role: "cell",
10710
10398
  className: classNames(
10711
10399
  cellClassNames,
10712
10400
  getBodyCellClassNames(false, stickyColumn),
10713
10401
  getAlignClassNames2(align),
10714
- tw("border-grey-10 group-hover:bg-grey-0 group-last-of-type:border-b-0"),
10402
+ tw("border-grey-10 group-last-of-type:border-b-0"),
10715
10403
  className
10716
10404
  )
10717
10405
  }));
10718
10406
  };
10719
10407
  var Row = (_a) => {
10720
- var _b = _a, { className, disabled, subgroup } = _b, rest = __objRest(_b, ["className", "disabled", "subgroup"]);
10721
- const Component = subgroup ? "span" : "div";
10722
- return /* @__PURE__ */ React64.createElement(Component, __spreadProps(__spreadValues(__spreadValues({}, rest), { inert: disabled ? "" : void 0 }), {
10408
+ var _b = _a, {
10409
+ className,
10410
+ disabled,
10411
+ header,
10412
+ subgroup,
10413
+ active
10414
+ } = _b, rest = __objRest(_b, [
10415
+ "className",
10416
+ "disabled",
10417
+ "header",
10418
+ "subgroup",
10419
+ "active"
10420
+ ]);
10421
+ return /* @__PURE__ */ React62.createElement("div", __spreadProps(__spreadValues(__spreadProps(__spreadValues({}, rest), {
10422
+ role: subgroup ? "rowgroup" : "row"
10423
+ }), { inert: disabled ? "" : void 0 }), {
10723
10424
  className: classNames(tw("contents"), className, {
10724
10425
  "children:opacity-70": disabled,
10725
- "[&>.group>*]:bg-grey-0 [&>.group>*:first-child]:border-b-0 [&:last-child>*:first-child]:border-t": subgroup,
10726
- "group": !subgroup
10727
- }),
10728
- role: !subgroup ? "row" : void 0
10426
+ "[&>*]:bg-primary-5": active,
10427
+ "[&>*]:hover:bg-grey-0": !disabled && !header
10428
+ })
10729
10429
  }));
10730
10430
  };
10731
10431
  var SubGroupSpacing = (_a) => {
10732
10432
  var _b = _a, { className, divider } = _b, rest = __objRest(_b, ["className", "divider"]);
10733
- return /* @__PURE__ */ React64.createElement("span", __spreadProps(__spreadValues({}, rest), {
10433
+ return /* @__PURE__ */ React62.createElement("span", __spreadProps(__spreadValues({}, rest), {
10734
10434
  "aria-hidden": true,
10735
10435
  className: classNames(
10736
10436
  tw("col-span-full h-6 bg-grey-0 border-grey-10", { "border-b": Boolean(divider) }),
@@ -10740,24 +10440,24 @@ var SubGroupSpacing = (_a) => {
10740
10440
  };
10741
10441
  var SortCell = (_a) => {
10742
10442
  var _b = _a, { children, direction = "none", onClick, sticky } = _b, rest = __objRest(_b, ["children", "direction", "onClick", "sticky"]);
10743
- return /* @__PURE__ */ React64.createElement(HeadCell, __spreadProps(__spreadValues({}, rest), {
10443
+ return /* @__PURE__ */ React62.createElement(HeadCell, __spreadProps(__spreadValues({}, rest), {
10744
10444
  "aria-sort": direction,
10745
10445
  role: "columnheader",
10746
10446
  sticky
10747
- }), /* @__PURE__ */ React64.createElement("span", {
10447
+ }), /* @__PURE__ */ React62.createElement("span", {
10748
10448
  className: getSortCellButtonClassNames(rest.align),
10749
10449
  role: "button",
10750
10450
  tabIndex: -1,
10751
10451
  onClick
10752
- }, children, /* @__PURE__ */ React64.createElement("div", {
10452
+ }, children, /* @__PURE__ */ React62.createElement("div", {
10753
10453
  "data-sort-icons": true,
10754
10454
  className: tw("flex flex-col", {
10755
10455
  "invisible group-hover:visible": direction === "none"
10756
10456
  })
10757
- }, /* @__PURE__ */ React64.createElement(InlineIcon, {
10457
+ }, /* @__PURE__ */ React62.createElement(InlineIcon, {
10758
10458
  icon: import_chevronUp4.default,
10759
10459
  className: getSortCellIconClassNames(direction === "ascending")
10760
- }), /* @__PURE__ */ React64.createElement(InlineIcon, {
10460
+ }), /* @__PURE__ */ React62.createElement(InlineIcon, {
10761
10461
  icon: import_chevronDown5.default,
10762
10462
  className: getSortCellIconClassNames(direction === "descending")
10763
10463
  }))));
@@ -10773,17 +10473,14 @@ DataList.SubGroupSpacing.displayName = "DataList.SubGroupSpacing";
10773
10473
  DataList.Row = Row;
10774
10474
  DataList.Row.displayName = "DataList.Row";
10775
10475
 
10776
- // src/utils/object.ts
10777
- var renameProperty = (oldProp, newProp, _a) => {
10778
- var _b = _a, { [oldProp]: oldValue } = _b, rest = __objRest(_b, [__restKey(oldProp)]);
10779
- return __spreadValues({
10780
- [newProp]: oldValue
10781
- }, rest);
10782
- };
10783
-
10784
10476
  // src/utils/table/types.ts
10477
+ import isArray2 from "lodash/isArray";
10478
+ var areRowsGrouped = (rows) => {
10479
+ return !isArray2(rows);
10480
+ };
10785
10481
  var toSortDirection = (direction) => direction === "ascending" ? "asc" : direction === "descending" ? "desc" : false;
10786
10482
  var cellProps = (column) => {
10483
+ var _a;
10787
10484
  let align;
10788
10485
  switch (column.type) {
10789
10486
  case "action":
@@ -10800,7 +10497,7 @@ var cellProps = (column) => {
10800
10497
  }
10801
10498
  }
10802
10499
  return {
10803
- key: column.key || column.headerName,
10500
+ key: (_a = column.key) != null ? _a : column.headerName,
10804
10501
  align,
10805
10502
  stickyColumn: column.sticky
10806
10503
  };
@@ -10811,11 +10508,11 @@ function isOnSortChangedDirection(value) {
10811
10508
  }
10812
10509
 
10813
10510
  // src/utils/table/useTableSort.tsx
10814
- import React65 from "react";
10511
+ import React63 from "react";
10815
10512
  var getDefaultSort = (props) => "defaultSort" in props ? props.defaultSort : "column" in props && "direction" in props && Object.keys(props).length === 2 ? { column: props.column, direction: props.direction } : void 0;
10816
10513
  var useTableSort = (props) => {
10817
10514
  const onSortChanged = props && "onSortChanged" in props ? props.onSortChanged : void 0;
10818
- const [sort, setSort] = React65.useState(props && getDefaultSort(props));
10515
+ const [sort, setSort] = React63.useState(props && getDefaultSort(props));
10819
10516
  const setSortAndEmitOnSortChangedEvent = (sort2) => {
10820
10517
  setSort(sort2);
10821
10518
  if (onSortChanged) {
@@ -10825,60 +10522,619 @@ var useTableSort = (props) => {
10825
10522
  onSortChanged(null);
10826
10523
  }
10827
10524
  }
10828
- };
10829
- const handleSortClick = (column) => {
10830
- if (sort && sort.column.headerName === column.headerName) {
10831
- if (sort.direction === "ascending") {
10832
- setSortAndEmitOnSortChangedEvent({ column, direction: "descending" });
10525
+ };
10526
+ const handleSortClick = (column) => {
10527
+ if (sort && sort.column.headerName === column.headerName) {
10528
+ if (sort.direction === "ascending") {
10529
+ setSortAndEmitOnSortChangedEvent({ column, direction: "descending" });
10530
+ } else {
10531
+ setSortAndEmitOnSortChangedEvent(void 0);
10532
+ }
10533
+ } else {
10534
+ setSortAndEmitOnSortChangedEvent({ column, direction: "ascending" });
10535
+ }
10536
+ };
10537
+ return [sort, handleSortClick];
10538
+ };
10539
+
10540
+ // src/utils/table/utils.ts
10541
+ import orderBy2 from "lodash/orderBy";
10542
+ var sortRowsBy = (rows, sort) => {
10543
+ if (!sort) {
10544
+ return rows;
10545
+ }
10546
+ const sortFunction = sort.column.sort;
10547
+ if (sortFunction) {
10548
+ return [...rows].sort((a, b) => sortFunction(a, b, sort.direction));
10549
+ } else if (columnIsFieldColumn(sort.column)) {
10550
+ return orderBy2(rows, [sort.column.field], [toSortDirection(sort.direction)]);
10551
+ }
10552
+ return rows;
10553
+ };
10554
+
10555
+ // src/molecules/DataList/DataListComponents.tsx
10556
+ import React66 from "react";
10557
+ import isFunction from "lodash/isFunction";
10558
+
10559
+ // src/molecules/DropdownMenu/DropdownMenu.tsx
10560
+ import React65 from "react";
10561
+ import { useFilter } from "@react-aria/i18n";
10562
+ import { PressResponder, usePress } from "@react-aria/interactions";
10563
+ import { useMenu, useMenuItem, useMenuSection, useMenuTrigger } from "@react-aria/menu";
10564
+ import { useSeparator } from "@react-aria/separator";
10565
+ import { mergeProps as mergeProps2 } from "@react-aria/utils";
10566
+ import { Item as Item4, Section } from "@react-stately/collections";
10567
+ import { useMenuTriggerState } from "@react-stately/menu";
10568
+ import { useTreeState } from "@react-stately/tree";
10569
+ import omit7 from "lodash/omit";
10570
+
10571
+ // src/atoms/DropdownMenu/DropdownMenu.tsx
10572
+ import React64 from "react";
10573
+ var import_tick5 = __toESM(require_tick());
10574
+ var DropdownMenu = React64.forwardRef(
10575
+ (_a, ref) => {
10576
+ var _b = _a, { minHeight, maxHeight = "100%", minWidth = "125px", maxWidth, className, children } = _b, props = __objRest(_b, ["minHeight", "maxHeight", "minWidth", "maxWidth", "className", "children"]);
10577
+ return /* @__PURE__ */ React64.createElement("div", __spreadValues({
10578
+ ref,
10579
+ style: { minHeight, maxHeight, minWidth, maxWidth },
10580
+ className: classNames(className, "bg-white w-full flex flex-col overflow-x-hidden typography-small text-grey-70")
10581
+ }, props), children);
10582
+ }
10583
+ );
10584
+ var ContentContainer = ({ children }) => /* @__PURE__ */ React64.createElement("div", {
10585
+ className: tw("p-3 overflow-y-auto overflow-x-hidden")
10586
+ }, children);
10587
+ DropdownMenu.ContentContainer = ContentContainer;
10588
+ var List2 = React64.forwardRef(
10589
+ (_a, ref) => {
10590
+ var _b = _a, { children, className } = _b, props = __objRest(_b, ["children", "className"]);
10591
+ return /* @__PURE__ */ React64.createElement("ul", __spreadValues({
10592
+ ref,
10593
+ className: classNames(className, "outline-none ring-0")
10594
+ }, props), children);
10595
+ }
10596
+ );
10597
+ DropdownMenu.List = List2;
10598
+ var Group2 = React64.forwardRef(
10599
+ (_a, ref) => {
10600
+ var _b = _a, { className, title, titleProps, children } = _b, props = __objRest(_b, ["className", "title", "titleProps", "children"]);
10601
+ return /* @__PURE__ */ React64.createElement("li", __spreadValues({
10602
+ ref
10603
+ }, props), title && /* @__PURE__ */ React64.createElement("div", __spreadValues({
10604
+ className: classNames(className, "p-3 text-grey-40 uppercase cursor-default typography-caption", {
10605
+ "text-grey-20": props.disabled
10606
+ })
10607
+ }, titleProps), title), children);
10608
+ }
10609
+ );
10610
+ DropdownMenu.Group = Group2;
10611
+ var Item3 = React64.forwardRef(
10612
+ (_a, ref) => {
10613
+ var _b = _a, { kind, highlighted, selected, className, icon, showNotification = false, children } = _b, props = __objRest(_b, ["kind", "highlighted", "selected", "className", "icon", "showNotification", "children"]);
10614
+ return /* @__PURE__ */ React64.createElement("li", __spreadValues({
10615
+ ref,
10616
+ className: classNames(className, "flex items-center gap-x-3 p-3 outline-none", {
10617
+ "cursor-pointer hover:bg-grey-0": !props.disabled,
10618
+ "bg-grey-0": highlighted,
10619
+ "text-primary-80": kind === "action",
10620
+ "text-grey-20 cursor-not-allowed": props.disabled
10621
+ })
10622
+ }, props), icon && showNotification && /* @__PURE__ */ React64.createElement(Badge.Notification, null, /* @__PURE__ */ React64.createElement(InlineIcon, {
10623
+ icon
10624
+ })), icon && !showNotification && /* @__PURE__ */ React64.createElement(InlineIcon, {
10625
+ icon
10626
+ }), /* @__PURE__ */ React64.createElement("span", {
10627
+ className: tw("grow")
10628
+ }, children), selected && /* @__PURE__ */ React64.createElement(InlineIcon, {
10629
+ icon: import_tick5.default
10630
+ }));
10631
+ }
10632
+ );
10633
+ DropdownMenu.Item = Item3;
10634
+ var Description = ({ disabled, children }) => /* @__PURE__ */ React64.createElement(Typography2.Caption, {
10635
+ color: disabled ? "grey-20" : "grey-40"
10636
+ }, children);
10637
+ DropdownMenu.Description = Description;
10638
+ var Separator = (_a) => {
10639
+ var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
10640
+ return /* @__PURE__ */ React64.createElement("li", __spreadProps(__spreadValues({}, props), {
10641
+ className: classNames(className, tw("m-3 block bg-grey-5 h-[1px]"))
10642
+ }));
10643
+ };
10644
+ DropdownMenu.Separator = Separator;
10645
+ var EmptyStateContainer2 = (_a) => {
10646
+ var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
10647
+ return /* @__PURE__ */ React64.createElement("div", __spreadValues({
10648
+ className: classNames(tw("border border-dashed border-grey-10 p-3"), className)
10649
+ }, props), children);
10650
+ };
10651
+ DropdownMenu.EmptyStateContainer = EmptyStateContainer2;
10652
+
10653
+ // src/molecules/DropdownMenu/utils.ts
10654
+ import { ListCollection } from "@react-stately/list";
10655
+ var filterCollection = (collection, inputValue, filter) => {
10656
+ return new ListCollection(filterNodes(collection, inputValue, filter));
10657
+ };
10658
+ var filterNodes = (nodes, inputValue, filter) => {
10659
+ const filteredNode = [];
10660
+ for (const node of nodes) {
10661
+ const description = Object.hasOwn(node.props, "description") && typeof node.props.description === "string" ? node.props.description : void 0;
10662
+ if (node.type === "section" && node.hasChildNodes) {
10663
+ const filtered = filterNodes(node.childNodes, inputValue, filter);
10664
+ if ([...filtered].length > 0) {
10665
+ filteredNode.push(__spreadProps(__spreadValues({}, node), { childNodes: filtered }));
10666
+ }
10667
+ } else if (node.type !== "section" && (filter(node.textValue, inputValue) || description && filter(description, inputValue))) {
10668
+ filteredNode.push(__spreadValues({}, node));
10669
+ }
10670
+ }
10671
+ return filteredNode;
10672
+ };
10673
+
10674
+ // src/molecules/DropdownMenu/DropdownMenu.tsx
10675
+ var DropdownMenu2 = (_a) => {
10676
+ var _b = _a, {
10677
+ onAction,
10678
+ selectionMode,
10679
+ selection,
10680
+ onSelectionChange,
10681
+ disabled,
10682
+ placement = "bottom-left",
10683
+ minWidth,
10684
+ maxWidth,
10685
+ minHeight,
10686
+ maxHeight,
10687
+ searchable = false,
10688
+ emptyState,
10689
+ header,
10690
+ footer,
10691
+ children
10692
+ } = _b, props = __objRest(_b, [
10693
+ "onAction",
10694
+ "selectionMode",
10695
+ "selection",
10696
+ "onSelectionChange",
10697
+ "disabled",
10698
+ "placement",
10699
+ "minWidth",
10700
+ "maxWidth",
10701
+ "minHeight",
10702
+ "maxHeight",
10703
+ "searchable",
10704
+ "emptyState",
10705
+ "header",
10706
+ "footer",
10707
+ "children"
10708
+ ]);
10709
+ const triggerRef = React65.useRef(null);
10710
+ const [trigger, items] = extractTriggerAndItems(children);
10711
+ const state = useMenuTriggerState(props);
10712
+ const { menuTriggerProps, menuProps } = useMenuTrigger({}, state, triggerRef);
10713
+ return /* @__PURE__ */ React65.createElement("div", null, /* @__PURE__ */ React65.createElement(PressResponder, __spreadValues({
10714
+ ref: triggerRef,
10715
+ onPress: () => state.toggle()
10716
+ }, omit7(menuTriggerProps, ["id", "aria-expanded"])), /* @__PURE__ */ React65.createElement(TriggerWrapper, {
10717
+ "aria-expanded": menuTriggerProps["aria-expanded"],
10718
+ disabled
10719
+ }, trigger.props.children)), state.isOpen && /* @__PURE__ */ React65.createElement(PopoverOverlay, {
10720
+ className: "Aquarium-DropdownMenu",
10721
+ triggerRef,
10722
+ state,
10723
+ placement,
10724
+ focusable: false
10725
+ }, /* @__PURE__ */ React65.createElement(MenuWrapper, __spreadValues({
10726
+ onAction,
10727
+ selectionMode,
10728
+ selection,
10729
+ onSelectionChange,
10730
+ searchable,
10731
+ emptyState,
10732
+ minWidth,
10733
+ maxWidth,
10734
+ maxHeight,
10735
+ minHeight,
10736
+ header,
10737
+ footer
10738
+ }, menuProps), items.props.children)));
10739
+ };
10740
+ DropdownMenu2.displayName = "DropdownMenu";
10741
+ var MenuTrigger = () => null;
10742
+ var MenuItems = () => null;
10743
+ DropdownMenu2.Trigger = MenuTrigger;
10744
+ DropdownMenu2.Trigger.displayName = "DropdownMenu.Trigger";
10745
+ DropdownMenu2.Items = MenuItems;
10746
+ DropdownMenu2.Items.displayName = "DropdownMenu.Items";
10747
+ DropdownMenu2.Item = Item4;
10748
+ DropdownMenu2.Item.displayName = "DropdownMenu.Item";
10749
+ DropdownMenu2.Section = Section;
10750
+ DropdownMenu2.Section.displayName = "DropdownMenu.Section";
10751
+ var TriggerWrapper = (_a) => {
10752
+ var _b = _a, { children, disabled } = _b, props = __objRest(_b, ["children", "disabled"]);
10753
+ const ref = React65.useRef(null);
10754
+ const { pressProps } = usePress(__spreadProps(__spreadValues({}, props), { isDisabled: disabled, ref }));
10755
+ const trigger = React65.Children.only(children);
10756
+ if (!trigger || !React65.isValidElement(trigger)) {
10757
+ throw new Error("<DropdownMenu.Trigger> must have valid child");
10758
+ }
10759
+ return React65.cloneElement(trigger, __spreadValues({ ref }, mergeProps2(pressProps, props)));
10760
+ };
10761
+ var isSectionNode = (item) => item.type === "section";
10762
+ var isItemNode = (item) => item.type === "item";
10763
+ var MenuWrapper = (_a) => {
10764
+ var _b = _a, {
10765
+ selection: selectedKeys,
10766
+ minWidth,
10767
+ maxWidth,
10768
+ minHeight,
10769
+ maxHeight,
10770
+ searchable,
10771
+ emptyState,
10772
+ header,
10773
+ footer
10774
+ } = _b, props = __objRest(_b, [
10775
+ "selection",
10776
+ "minWidth",
10777
+ "maxWidth",
10778
+ "minHeight",
10779
+ "maxHeight",
10780
+ "searchable",
10781
+ "emptyState",
10782
+ "header",
10783
+ "footer"
10784
+ ]);
10785
+ const ref = React65.useRef(null);
10786
+ const disabledKeys = getDisabledItemKeys(props.children);
10787
+ const state = useTreeState(__spreadValues({
10788
+ disabledKeys,
10789
+ selectedKeys
10790
+ }, props));
10791
+ const { menuProps } = useMenu(props, state, ref);
10792
+ const { contains } = useFilter({ sensitivity: "base" });
10793
+ const [search, setSearch] = React65.useState("");
10794
+ const filteredCollection = React65.useMemo(
10795
+ () => searchable ? filterCollection(state.collection, search, contains) : state.collection,
10796
+ [searchable, state.collection, search, contains]
10797
+ );
10798
+ return /* @__PURE__ */ React65.createElement(DropdownMenu, {
10799
+ minWidth,
10800
+ maxWidth,
10801
+ minHeight,
10802
+ maxHeight
10803
+ }, header, /* @__PURE__ */ React65.createElement(DropdownMenu.ContentContainer, null, searchable && /* @__PURE__ */ React65.createElement(SearchInput, {
10804
+ "aria-label": "search",
10805
+ value: search,
10806
+ onChange: (e) => setSearch(e.target.value),
10807
+ className: tw("mb-5")
10808
+ }), filteredCollection.size === 0 && emptyState && /* @__PURE__ */ React65.createElement(DropdownMenu.EmptyStateContainer, null, emptyState), /* @__PURE__ */ React65.createElement(DropdownMenu.List, __spreadValues({
10809
+ ref
10810
+ }, menuProps), Array.from(filteredCollection).map((item) => {
10811
+ if (isSectionNode(item)) {
10812
+ return /* @__PURE__ */ React65.createElement(SectionWrapper, {
10813
+ key: item.key,
10814
+ section: item,
10815
+ state
10816
+ });
10817
+ } else if (isItemNode(item)) {
10818
+ return /* @__PURE__ */ React65.createElement(ItemWrapper, {
10819
+ key: item.key,
10820
+ item,
10821
+ state
10822
+ });
10823
+ }
10824
+ }))), footer);
10825
+ };
10826
+ var ItemWrapper = ({ item, state }) => {
10827
+ const ref = React65.useRef(null);
10828
+ const { menuItemProps, descriptionProps, isSelected, isFocused, isDisabled } = useMenuItem(
10829
+ { key: item.key, closeOnSelect: item.props.closeOnSelect },
10830
+ state,
10831
+ ref
10832
+ );
10833
+ const { icon, description, kind = "default", showNotification = false } = item.props;
10834
+ return /* @__PURE__ */ React65.createElement(DropdownMenu.Item, __spreadProps(__spreadValues({
10835
+ ref
10836
+ }, menuItemProps), {
10837
+ kind,
10838
+ selected: isSelected,
10839
+ highlighted: isFocused,
10840
+ disabled: isDisabled,
10841
+ icon,
10842
+ showNotification
10843
+ }), item.rendered, description && /* @__PURE__ */ React65.createElement(DropdownMenu.Description, __spreadValues({
10844
+ disabled: isDisabled
10845
+ }, descriptionProps), description));
10846
+ };
10847
+ var SectionWrapper = ({ section, state }) => {
10848
+ const { itemProps, headingProps, groupProps } = useMenuSection({
10849
+ "heading": section.rendered,
10850
+ "aria-label": section["aria-label"]
10851
+ });
10852
+ const { separatorProps } = useSeparator({
10853
+ elementType: "li"
10854
+ });
10855
+ return /* @__PURE__ */ React65.createElement(React65.Fragment, null, section.key !== state.collection.getFirstKey() && /* @__PURE__ */ React65.createElement(DropdownMenu.Separator, __spreadValues({}, separatorProps)), /* @__PURE__ */ React65.createElement(DropdownMenu.Group, __spreadValues({
10856
+ title: section.rendered,
10857
+ titleProps: headingProps
10858
+ }, itemProps), /* @__PURE__ */ React65.createElement("ul", __spreadValues({}, groupProps), Array.from(section.childNodes).map((node) => /* @__PURE__ */ React65.createElement(ItemWrapper, {
10859
+ key: node.key,
10860
+ item: node,
10861
+ state
10862
+ })))));
10863
+ };
10864
+ var extractTriggerAndItems = (children) => {
10865
+ const [trigger, items] = React65.Children.toArray(children);
10866
+ if (!isComponentType(trigger, MenuTrigger) || !isComponentType(items, MenuItems)) {
10867
+ throw new Error("<DropdownMenu> must have <DropdownMenu.Trigger> and <DropdownMenu.Items> defined");
10868
+ }
10869
+ return [trigger, items];
10870
+ };
10871
+ var getDisabledItemKeys = (children) => {
10872
+ const keys = React65.Children.map(children, (child) => {
10873
+ var _a, _b;
10874
+ if (!child || typeof child === "function") {
10875
+ return null;
10876
+ }
10877
+ if (isComponentType(child, Item4) && child.props.disabled) {
10878
+ return (_b = (_a = child.key) == null ? void 0 : _a.toString()) != null ? _b : null;
10879
+ }
10880
+ if (isComponentType(child, Section)) {
10881
+ return getDisabledItemKeys(child.props.children);
10882
+ }
10883
+ return null;
10884
+ });
10885
+ return keys.flat().filter((key) => key !== null);
10886
+ };
10887
+
10888
+ // src/utils/object.ts
10889
+ var renameProperty = (oldProp, newProp, _a) => {
10890
+ var _b = _a, { [oldProp]: oldValue } = _b, rest = __objRest(_b, [__restKey(oldProp)]);
10891
+ return __spreadValues({
10892
+ [newProp]: oldValue
10893
+ }, rest);
10894
+ };
10895
+
10896
+ // src/molecules/DataList/DataListComponents.tsx
10897
+ var import_more2 = __toESM(require_more());
10898
+ var DataListRowMenu = ({
10899
+ row,
10900
+ index,
10901
+ menu,
10902
+ onAction,
10903
+ onMenuOpenChange,
10904
+ menuAriaLabel
10905
+ }) => {
10906
+ if (!menu) {
10907
+ return null;
10908
+ }
10909
+ const menuContent = isFunction(menu) ? menu(row, index) : menu;
10910
+ return /* @__PURE__ */ React66.createElement(DataList.Cell, {
10911
+ align: "right"
10912
+ }, menuContent && /* @__PURE__ */ React66.createElement(DropdownMenu2, {
10913
+ onAction: (action) => onAction == null ? void 0 : onAction(action, row, index),
10914
+ onOpenChange: onMenuOpenChange
10915
+ }, /* @__PURE__ */ React66.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React66.createElement(Button.Icon, {
10916
+ "aria-label": menuAriaLabel,
10917
+ icon: import_more2.default
10918
+ })), menuContent));
10919
+ };
10920
+ var DataListRow = ({
10921
+ columns,
10922
+ row,
10923
+ index,
10924
+ rows,
10925
+ menu,
10926
+ active,
10927
+ disabled,
10928
+ renderFirstColumn,
10929
+ additionalColumnProps = () => ({})
10930
+ }) => {
10931
+ var _a;
10932
+ const isRowDisabled = (_a = disabled == null ? void 0 : disabled(row, index, rows)) != null ? _a : false;
10933
+ return /* @__PURE__ */ React66.createElement(DataList.Row, {
10934
+ key: row.id,
10935
+ disabled: isRowDisabled,
10936
+ active
10937
+ }, renderFirstColumn == null ? void 0 : renderFirstColumn(row, index, rows), /* @__PURE__ */ React66.createElement(List, {
10938
+ items: columns,
10939
+ renderItem: (column, columnIndex) => /* @__PURE__ */ React66.createElement(DataList.Cell, __spreadValues(__spreadValues({}, cellProps(column)), additionalColumnProps(column, columnIndex, columns, row)), /* @__PURE__ */ React66.createElement(DataListCell, {
10940
+ column,
10941
+ row,
10942
+ index,
10943
+ rows
10944
+ }))
10945
+ }), menu);
10946
+ };
10947
+ var DEFAULT_CONTENT = "";
10948
+ var DataListCell = ({
10949
+ column,
10950
+ row,
10951
+ index,
10952
+ rows: _rows
10953
+ }) => {
10954
+ let cellContent = DEFAULT_CONTENT;
10955
+ const rows = areRowsGrouped(_rows) ? void 0 : _rows;
10956
+ switch (column.type) {
10957
+ case "status": {
10958
+ const status = column.status(row, index, rows);
10959
+ if (status) {
10960
+ cellContent = /* @__PURE__ */ React66.createElement(StatusChip, __spreadValues({
10961
+ dense: true
10962
+ }, status));
10963
+ }
10964
+ break;
10965
+ }
10966
+ case "action": {
10967
+ const action = renameProperty("text", "children", column.action(row, index, rows));
10968
+ if (action) {
10969
+ cellContent = /* @__PURE__ */ React66.createElement(Button.Secondary, __spreadValues({
10970
+ dense: true
10971
+ }, action));
10972
+ }
10973
+ break;
10974
+ }
10975
+ case "custom": {
10976
+ cellContent = column.UNSAFE_render(row, index, rows);
10977
+ break;
10978
+ }
10979
+ case "item": {
10980
+ const item = column.item(row, index, rows);
10981
+ if (item) {
10982
+ cellContent = /* @__PURE__ */ React66.createElement(Item2, __spreadValues({}, item));
10983
+ }
10984
+ break;
10985
+ }
10986
+ default:
10987
+ if (column.formatter) {
10988
+ cellContent = column.formatter(row[column.field], row, index, rows);
10833
10989
  } else {
10834
- setSortAndEmitOnSortChangedEvent(void 0);
10990
+ cellContent = row[column.field];
10835
10991
  }
10836
- } else {
10837
- setSortAndEmitOnSortChangedEvent({ column, direction: "ascending" });
10838
- }
10839
- };
10840
- return [sort, handleSortClick];
10992
+ break;
10993
+ }
10994
+ return column.tooltip ? /* @__PURE__ */ React66.createElement(Tooltip, __spreadValues({}, column.tooltip(row, index, rows)), cellContent) : /* @__PURE__ */ React66.createElement(React66.Fragment, null, cellContent);
10841
10995
  };
10842
10996
 
10843
- // src/utils/table/utils.ts
10844
- import orderBy2 from "lodash/orderBy";
10845
- var sortRowsBy = (rows, sort) => {
10846
- if (!sort) {
10847
- return rows;
10997
+ // src/molecules/DataList/DataListGroup.tsx
10998
+ import React67 from "react";
10999
+ import isFunction2 from "lodash/isFunction";
11000
+ var GAP = 8;
11001
+ var INDENTATION = 28;
11002
+ var sortGroupKeys = (groupKeys) => [...groupKeys].sort((a) => a === "undefined" ? -1 : 1);
11003
+ var DataListGroup = (_a) => {
11004
+ var _b = _a, {
11005
+ groups,
11006
+ level = 0
11007
+ } = _b, props = __objRest(_b, [
11008
+ "groups",
11009
+ "level"
11010
+ ]);
11011
+ const {
11012
+ columns,
11013
+ disabled,
11014
+ expandedGroupIds,
11015
+ getGroupRow,
11016
+ menu,
11017
+ menuAriaLabel,
11018
+ onAction,
11019
+ onGroupToggled,
11020
+ onMenuOpenChange,
11021
+ rows
11022
+ } = props;
11023
+ const groupKeys = groups ? Object.keys(groups) : void 0;
11024
+ const hasCustomRowForGroup = isFunction2(getGroupRow);
11025
+ if (!areRowsGrouped(groups)) {
11026
+ return /* @__PURE__ */ React67.createElement(List, {
11027
+ items: groups,
11028
+ renderItem: (row, index) => {
11029
+ return /* @__PURE__ */ React67.createElement(DataListRow, {
11030
+ key: row.id,
11031
+ columns,
11032
+ row,
11033
+ index,
11034
+ rows,
11035
+ menu: /* @__PURE__ */ React67.createElement(DataListRowMenu, {
11036
+ row,
11037
+ index,
11038
+ menu,
11039
+ onAction,
11040
+ onMenuOpenChange,
11041
+ menuAriaLabel
11042
+ }),
11043
+ disabled,
11044
+ additionalColumnProps: (_, columnIndex) => columnIndex === 0 ? {
11045
+ style: {
11046
+ paddingLeft: `${GAP + level * INDENTATION}px`
11047
+ }
11048
+ } : {}
11049
+ });
11050
+ }
11051
+ });
10848
11052
  }
10849
- const sortFunction = sort.column.sort;
10850
- if (sortFunction) {
10851
- return [...rows].sort((a, b) => sortFunction(a, b, sort.direction));
10852
- } else if (columnIsFieldColumn(sort.column)) {
10853
- return orderBy2(rows, [sort.column.field], [toSortDirection(sort.direction)]);
11053
+ if (!groupKeys) {
11054
+ return null;
10854
11055
  }
10855
- return rows;
11056
+ return /* @__PURE__ */ React67.createElement(List, {
11057
+ items: sortGroupKeys(groupKeys),
11058
+ renderItem: (key) => {
11059
+ var _a2;
11060
+ const group = groups[key];
11061
+ if (key === "undefined" || key === void 0) {
11062
+ return /* @__PURE__ */ React67.createElement(DataListGroup, __spreadProps(__spreadValues({
11063
+ key: "undefined",
11064
+ level
11065
+ }, props), {
11066
+ groups: group
11067
+ }));
11068
+ }
11069
+ const openPanelId = expandedGroupIds ? (_a2 = expandedGroupIds.find((id) => id === key)) != null ? _a2 : null : void 0;
11070
+ return /* @__PURE__ */ React67.createElement(Accordion, {
11071
+ key,
11072
+ openPanelId
11073
+ }, hasCustomRowForGroup && /* @__PURE__ */ React67.createElement(DataList.Row, {
11074
+ active: !!openPanelId
11075
+ }, /* @__PURE__ */ React67.createElement(List, {
11076
+ items: columns,
11077
+ renderItem: (column, idx) => /* @__PURE__ */ React67.createElement(DataList.Cell, __spreadProps(__spreadValues({}, cellProps(column)), {
11078
+ className: tw("gap-3"),
11079
+ style: idx === 0 ? { paddingLeft: `${GAP + level * INDENTATION}px` } : void 0
11080
+ }), idx === 0 && /* @__PURE__ */ React67.createElement(Accordion.Toggle, {
11081
+ panelId: key,
11082
+ onChange: onGroupToggled
11083
+ }), /* @__PURE__ */ React67.createElement(DataListCell, {
11084
+ column,
11085
+ row: getGroupRow(key, group),
11086
+ index: -1,
11087
+ rows: []
11088
+ }))
11089
+ }), /* @__PURE__ */ React67.createElement(DataListRowMenu, {
11090
+ row: getGroupRow(key, group),
11091
+ index: -1,
11092
+ menu,
11093
+ onAction,
11094
+ onMenuOpenChange,
11095
+ menuAriaLabel
11096
+ })), !hasCustomRowForGroup && /* @__PURE__ */ React67.createElement(DataList.Row, {
11097
+ active: !!openPanelId
11098
+ }, /* @__PURE__ */ React67.createElement(DataList.Cell, {
11099
+ className: tw("gap-3"),
11100
+ style: { paddingLeft: `${GAP + level * INDENTATION}px`, gridColumn: "1 / -1" }
11101
+ }, /* @__PURE__ */ React67.createElement(Accordion.Toggle, {
11102
+ panelId: key,
11103
+ onChange: onGroupToggled
11104
+ }), "Group: ", /* @__PURE__ */ React67.createElement("b", null, key))), /* @__PURE__ */ React67.createElement(DataList.Row, {
11105
+ subgroup: true
11106
+ }, /* @__PURE__ */ React67.createElement(Accordion.UnanimatedPanel, {
11107
+ panelId: key
11108
+ }, /* @__PURE__ */ React67.createElement(DataListGroup, __spreadProps(__spreadValues({
11109
+ level: level + 1
11110
+ }, props), {
11111
+ groups: group
11112
+ })))));
11113
+ }
11114
+ });
10856
11115
  };
10857
11116
 
10858
- // src/molecules/DataList/DataList.tsx
10859
- var import_more2 = __toESM(require_more());
10860
-
10861
11117
  // src/molecules/DataList/DataListSkeleton.tsx
10862
- import React66 from "react";
11118
+ import React68 from "react";
10863
11119
  var DataListSkeleton = ({ columns = ["1", "2", "2", 52], rows = 5 }) => {
10864
11120
  const columnsAmount = [...Array(typeof columns === "number" ? columns : columns.length).keys()];
10865
- return /* @__PURE__ */ React66.createElement(Template, {
11121
+ return /* @__PURE__ */ React68.createElement(Template, {
10866
11122
  role: "table",
10867
11123
  columns
10868
- }, /* @__PURE__ */ React66.createElement(DataList.Row, null, columnsAmount.map((_, index) => /* @__PURE__ */ React66.createElement(DataList.HeadCell, {
11124
+ }, /* @__PURE__ */ React68.createElement(DataList.Row, null, columnsAmount.map((_, index) => /* @__PURE__ */ React68.createElement(DataList.HeadCell, {
10869
11125
  key: index
10870
- }, /* @__PURE__ */ React66.createElement(Skeleton, {
11126
+ }, /* @__PURE__ */ React68.createElement(Skeleton, {
10871
11127
  width: "100%",
10872
11128
  height: 17.5
10873
- })))), /* @__PURE__ */ React66.createElement(List2, {
11129
+ })))), /* @__PURE__ */ React68.createElement(List, {
10874
11130
  items: [...Array(rows).keys()],
10875
- renderItem: (item) => /* @__PURE__ */ React66.createElement(DataList.Row, {
11131
+ renderItem: (item) => /* @__PURE__ */ React68.createElement(DataList.Row, {
10876
11132
  key: item
10877
- }, /* @__PURE__ */ React66.createElement(List2, {
11133
+ }, /* @__PURE__ */ React68.createElement(List, {
10878
11134
  items: columnsAmount,
10879
- renderItem: (key) => /* @__PURE__ */ React66.createElement(DataList.Cell, {
11135
+ renderItem: (key) => /* @__PURE__ */ React68.createElement(DataList.Cell, {
10880
11136
  key
10881
- }, /* @__PURE__ */ React66.createElement(Skeleton, {
11137
+ }, /* @__PURE__ */ React68.createElement(Skeleton, {
10882
11138
  width: "100%",
10883
11139
  height: 17.5
10884
11140
  }))
@@ -10887,11 +11143,11 @@ var DataListSkeleton = ({ columns = ["1", "2", "2", 52], rows = 5 }) => {
10887
11143
  };
10888
11144
 
10889
11145
  // src/molecules/DataList/DataList.tsx
10890
- var sortGroupKeys = (groupKeys) => [...groupKeys].sort((a) => a === "undefined" ? -1 : 1);
10891
11146
  var DataList2 = (_a) => {
10892
11147
  var _b = _a, {
10893
11148
  columns,
10894
11149
  rows,
11150
+ hideHeader = false,
10895
11151
  sticky,
10896
11152
  menu,
10897
11153
  menuLabel,
@@ -10910,6 +11166,7 @@ var DataList2 = (_a) => {
10910
11166
  } = _b, rest = __objRest(_b, [
10911
11167
  "columns",
10912
11168
  "rows",
11169
+ "hideHeader",
10913
11170
  "sticky",
10914
11171
  "menu",
10915
11172
  "menuLabel",
@@ -10932,202 +11189,121 @@ var DataList2 = (_a) => {
10932
11189
  const [sort, updateSort] = useTableSort(
10933
11190
  onSortChanged ? __spreadProps(__spreadValues({}, initialSortState), { onSortChanged }) : initialSortState
10934
11191
  );
10935
- const sortedRows = sortRowsBy(rows, sort);
10936
- const groups = group ? isFunction(group) ? group(sortedRows) : groupBy2(sortedRows, group) : void 0;
10937
- const groupKeys = groups ? Object.keys(groups) : void 0;
10938
- const hasCustomRenderForGroupRow = isFunction(getGroupRow);
10939
- const isCollapsible = isFunction(rowDetails) || group;
11192
+ const sortedRows = isArray3(rows) ? sortRowsBy(rows, sort) : [];
11193
+ const groups = areRowsGrouped(rows) ? rows : group ? isFunction3(group) ? group(sortedRows) : groupBy2(sortedRows, group) : void 0;
11194
+ const isCollapsible = isFunction3(rowDetails);
10940
11195
  const templateColumns = compact([
10941
- isCollapsible ? 50 : void 0,
11196
+ isCollapsible ? "fit-content(50px)" : void 0,
10942
11197
  ...columns.map((column) => {
10943
11198
  var _a3;
10944
11199
  return (_a3 = column.width) != null ? _a3 : "auto";
10945
11200
  }),
10946
- menu ? "auto" : void 0
11201
+ menu ? "fit-content(28px)" : void 0
10947
11202
  ]);
10948
- const PaginationFooter = React67.useCallback(
10949
- ({ children }) => /* @__PURE__ */ React67.createElement("div", {
11203
+ const PaginationFooter = React69.useCallback(
11204
+ ({ children }) => /* @__PURE__ */ React69.createElement("div", {
10950
11205
  style: { gridColumn: "1 / -1" },
10951
11206
  role: "row"
10952
- }, /* @__PURE__ */ React67.createElement("div", {
11207
+ }, /* @__PURE__ */ React69.createElement("div", {
10953
11208
  role: "cell"
10954
11209
  }, children)),
10955
11210
  []
10956
11211
  );
10957
- return /* @__PURE__ */ React67.createElement(Template, {
11212
+ return /* @__PURE__ */ React69.createElement(Template, {
10958
11213
  className: "Aquarium-DataList",
10959
11214
  columns: templateColumns,
10960
11215
  role: "table"
10961
- }, /* @__PURE__ */ React67.createElement(DataList.Row, null, isCollapsible && /* @__PURE__ */ React67.createElement(DataList.HeadCell, {
11216
+ }, !hideHeader && /* @__PURE__ */ React69.createElement(DataList.Row, {
11217
+ header: true
11218
+ }, isCollapsible && /* @__PURE__ */ React69.createElement(DataList.HeadCell, {
10962
11219
  align: "left",
10963
11220
  sticky
10964
11221
  }), columns.map((column) => {
10965
- const content = column.headerTooltip ? /* @__PURE__ */ React67.createElement(Tooltip, {
11222
+ const content = column.headerTooltip ? /* @__PURE__ */ React69.createElement(Tooltip, {
10966
11223
  placement: column.headerTooltip.placement,
10967
11224
  content: column.headerTooltip.content
10968
11225
  }, column.headerName) : column.headerName;
10969
- return columnIsFieldColumn(column) && column.sortable || column.sort ? /* @__PURE__ */ React67.createElement(DataList.SortCell, __spreadValues({
11226
+ return columnIsFieldColumn(column) && column.sortable || column.sort ? /* @__PURE__ */ React69.createElement(DataList.SortCell, __spreadValues({
10970
11227
  direction: sort && sort.column.headerName === column.headerName ? sort.direction : "none",
10971
11228
  onClick: () => updateSort(column),
10972
11229
  sticky
10973
- }, cellProps(column)), content) : /* @__PURE__ */ React67.createElement(DataList.HeadCell, __spreadProps(__spreadValues({}, cellProps(column)), {
11230
+ }, cellProps(column)), content) : /* @__PURE__ */ React69.createElement(DataList.HeadCell, __spreadProps(__spreadValues({}, cellProps(column)), {
10974
11231
  sticky
10975
11232
  }), content);
10976
- }), menu && /* @__PURE__ */ React67.createElement(DataList.HeadCell, {
11233
+ }), menu && /* @__PURE__ */ React69.createElement(DataList.HeadCell, {
10977
11234
  align: "right",
10978
11235
  "aria-label": menuAriaLabel,
10979
11236
  sticky
10980
- }, menuHeaderName)), groups && groupKeys ? /* @__PURE__ */ React67.createElement(List2, {
10981
- items: sortGroupKeys(groupKeys),
10982
- renderItem: (key) => {
10983
- const groupContent = /* @__PURE__ */ React67.createElement(List2, {
10984
- key,
10985
- items: groups[key],
10986
- renderItem: (row, index) => renderRow(
10987
- columns,
10988
- row,
10989
- index,
10990
- sortedRows,
10991
- renderRowMenu(row, index, { menu, onAction, onMenuOpenChange, menuAriaLabel }),
10992
- disabled,
10993
- () => /* @__PURE__ */ React67.createElement(DataList.Cell, null)
10994
- )
10995
- });
10996
- return key === "undefined" ? groupContent : /* @__PURE__ */ React67.createElement(Accordion, {
10997
- key,
10998
- openPanelId: expandedGroupIds ? expandedGroupIds.find((id) => id === key) || null : void 0
10999
- }, hasCustomRenderForGroupRow ? /* @__PURE__ */ React67.createElement(DataList.Row, null, /* @__PURE__ */ React67.createElement(DataList.Cell, null, /* @__PURE__ */ React67.createElement(Accordion.Toggle, {
11000
- panelId: key,
11001
- onChange: onGroupToggled
11002
- })), /* @__PURE__ */ React67.createElement(List2, {
11003
- items: columns,
11004
- renderItem: (column) => /* @__PURE__ */ React67.createElement(DataList.Cell, __spreadValues({}, cellProps(column)), renderCell(column, getGroupRow(key, groups[key]), -1, []))
11005
- }), renderRowMenu(getGroupRow(key, groups[key]), -1, {
11006
- menu,
11007
- onAction,
11008
- onMenuOpenChange,
11009
- menuAriaLabel
11010
- })) : /* @__PURE__ */ React67.createElement(DataList.Row, null, /* @__PURE__ */ React67.createElement(DataList.Cell, null, /* @__PURE__ */ React67.createElement(Accordion.Toggle, {
11011
- panelId: key,
11012
- onChange: onGroupToggled
11013
- })), /* @__PURE__ */ React67.createElement(DataList.Cell, {
11014
- style: { gridColumn: "2 / -1", gap: 4 }
11015
- }, "Group: ", /* @__PURE__ */ React67.createElement("b", null, key))), /* @__PURE__ */ React67.createElement(DataList.Row, {
11016
- subgroup: true
11017
- }, /* @__PURE__ */ React67.createElement(Accordion.UnanimatedPanel, {
11018
- panelId: key
11019
- }, /* @__PURE__ */ React67.createElement(DataList.SubGroupSpacing, null), groupContent, /* @__PURE__ */ React67.createElement(DataList.SubGroupSpacing, {
11020
- divider: true
11021
- }))));
11022
- }
11023
- }) : /* @__PURE__ */ React67.createElement(List2, __spreadProps(__spreadValues({}, rest), {
11237
+ }, menuHeaderName)), groups && /* @__PURE__ */ React69.createElement(DataListGroup, {
11238
+ columns,
11239
+ disabled,
11240
+ getGroupRow,
11241
+ expandedGroupIds,
11242
+ menu,
11243
+ menuAriaLabel,
11244
+ onAction,
11245
+ onGroupToggled,
11246
+ onMenuOpenChange,
11247
+ rows,
11248
+ groups,
11249
+ level: 0
11250
+ }), !groups && /* @__PURE__ */ React69.createElement(List, __spreadProps(__spreadValues({}, rest), {
11024
11251
  paginationContainer: PaginationFooter,
11025
11252
  items: sortedRows,
11026
11253
  renderItem: (row, index) => {
11027
11254
  const details = rowDetails == null ? void 0 : rowDetails(row, index, sortedRows);
11028
- const content = renderRow(
11255
+ const content = /* @__PURE__ */ React69.createElement(DataListRow, {
11256
+ key: row.id,
11029
11257
  columns,
11030
11258
  row,
11031
11259
  index,
11032
- sortedRows,
11033
- renderRowMenu(row, index, { menu, onAction, onMenuOpenChange, menuAriaLabel }),
11260
+ rows: sortedRows,
11261
+ menu: /* @__PURE__ */ React69.createElement(DataListRowMenu, {
11262
+ row,
11263
+ index,
11264
+ menu,
11265
+ onAction,
11266
+ onMenuOpenChange,
11267
+ menuAriaLabel
11268
+ }),
11034
11269
  disabled,
11035
- () => rowDetails !== void 0 && /* @__PURE__ */ React67.createElement(DataList.Cell, null, details && /* @__PURE__ */ React67.createElement(Accordion.Toggle, {
11270
+ renderFirstColumn: () => rowDetails !== void 0 && /* @__PURE__ */ React69.createElement(DataList.Cell, null, details && /* @__PURE__ */ React69.createElement(Accordion.Toggle, {
11036
11271
  panelId: row.id.toString(),
11037
11272
  onChange: onGroupToggled
11038
11273
  }))
11039
- );
11040
- return details ? /* @__PURE__ */ React67.createElement(Accordion, {
11274
+ });
11275
+ if (!details) {
11276
+ return content;
11277
+ }
11278
+ return /* @__PURE__ */ React69.createElement(Accordion, {
11041
11279
  key: row.id,
11042
11280
  openPanelId: expandedGroupIds ? expandedGroupIds.find((id) => id === row.id) || null : void 0
11043
- }, content, /* @__PURE__ */ React67.createElement(Accordion.Panel, {
11281
+ }, content, /* @__PURE__ */ React69.createElement(Accordion.Panel, {
11044
11282
  role: "row",
11045
11283
  panelId: row.id.toString(),
11046
11284
  className: tw("col-span-full bg-grey-0 border-b border-grey-10"),
11047
11285
  "aria-label": `row ${row.id.toString()} details`
11048
- }, /* @__PURE__ */ React67.createElement("div", {
11286
+ }, /* @__PURE__ */ React69.createElement("div", {
11049
11287
  role: "cell"
11050
- }, details))) : content;
11288
+ }, details)));
11051
11289
  }
11052
11290
  })));
11053
11291
  };
11054
- var renderRowMenu = (row, index, {
11055
- menu,
11056
- onAction,
11057
- onMenuOpenChange,
11058
- menuAriaLabel
11059
- }) => {
11060
- if (menu) {
11061
- const menuContent = isFunction(menu) ? menu(row, index) : menu;
11062
- return /* @__PURE__ */ React67.createElement(DataList.Cell, {
11063
- align: "right"
11064
- }, menuContent && /* @__PURE__ */ React67.createElement(DropdownMenu2, {
11065
- onAction: (action) => onAction == null ? void 0 : onAction(action, row, index),
11066
- onOpenChange: onMenuOpenChange
11067
- }, /* @__PURE__ */ React67.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React67.createElement(Button.Icon, {
11068
- "aria-label": menuAriaLabel,
11069
- icon: import_more2.default
11070
- })), menuContent));
11071
- }
11072
- return void 0;
11073
- };
11074
- var renderRow = (columns, row, index, rows, menu, disabled, renderFirstColumn) => {
11075
- var _a;
11076
- const isRowDisabled = (_a = disabled == null ? void 0 : disabled(row, index, rows)) != null ? _a : false;
11077
- return /* @__PURE__ */ React67.createElement(DataList.Row, {
11078
- key: row.id,
11079
- disabled: isRowDisabled
11080
- }, renderFirstColumn == null ? void 0 : renderFirstColumn(row, index, rows), /* @__PURE__ */ React67.createElement(List2, {
11081
- items: columns,
11082
- renderItem: (column) => /* @__PURE__ */ React67.createElement(DataList.Cell, __spreadValues({}, cellProps(column)), renderCell(column, row, index, rows))
11083
- }), menu);
11084
- };
11085
- var DEFAULT_CONTENT = "";
11086
- var renderCell = (column, row, index, rows) => {
11087
- let cellContent = DEFAULT_CONTENT;
11088
- if (column.type === "status") {
11089
- const status = column.status(row, index, rows);
11090
- if (status) {
11091
- cellContent = /* @__PURE__ */ React67.createElement(StatusChip, __spreadValues({
11092
- dense: true
11093
- }, status));
11094
- }
11095
- } else if (column.type === "action") {
11096
- const action = renameProperty("text", "children", column.action(row, index, rows));
11097
- if (action) {
11098
- cellContent = /* @__PURE__ */ React67.createElement(Button.Secondary, __spreadValues({
11099
- dense: true
11100
- }, action));
11101
- }
11102
- } else if (column.type === "custom") {
11103
- cellContent = column.UNSAFE_render(row, index, rows);
11104
- } else if (column.type === "item") {
11105
- const item = column.item(row, index, rows);
11106
- if (item) {
11107
- cellContent = /* @__PURE__ */ React67.createElement(Item4, __spreadValues({}, item));
11108
- }
11109
- } else if (column.formatter) {
11110
- cellContent = column.formatter(row[column.field], row, index, rows);
11111
- } else {
11112
- cellContent = row[column.field];
11113
- }
11114
- return column.tooltip ? /* @__PURE__ */ React67.createElement(Tooltip, __spreadValues({}, column.tooltip(row, index, rows)), cellContent) : cellContent;
11115
- };
11116
11292
  DataList2.Skeleton = DataListSkeleton;
11117
11293
 
11118
11294
  // src/molecules/DataTable/DataTable.tsx
11119
- import React70 from "react";
11295
+ import React72 from "react";
11120
11296
  import compact2 from "lodash/compact";
11121
- import isFunction2 from "lodash/isFunction";
11297
+ import isFunction4 from "lodash/isFunction";
11122
11298
 
11123
11299
  // src/molecules/Table/Table.tsx
11124
- import React69 from "react";
11300
+ import React71 from "react";
11125
11301
 
11126
11302
  // src/utils/table/useScrollTarget.ts
11127
- import React68 from "react";
11303
+ import React70 from "react";
11128
11304
  var useScrollTarget = (callback) => {
11129
- const targetRef = React68.useRef(null);
11130
- React68.useLayoutEffect(() => {
11305
+ const targetRef = React70.useRef(null);
11306
+ React70.useLayoutEffect(() => {
11131
11307
  const observer = new IntersectionObserver((entries) => entries[0].isIntersecting && callback && callback(), {
11132
11308
  root: null,
11133
11309
  rootMargin: `0px 0px 200px 0px`
@@ -11145,12 +11321,12 @@ var Table2 = (_a) => {
11145
11321
  var _b = _a, { children, onPrev, onNext } = _b, rest = __objRest(_b, ["children", "onPrev", "onNext"]);
11146
11322
  const bottomRef = useScrollTarget(onNext);
11147
11323
  const topRef = useScrollTarget(onPrev);
11148
- return /* @__PURE__ */ React69.createElement("div", {
11324
+ return /* @__PURE__ */ React71.createElement("div", {
11149
11325
  className: classNames("Aquarium-Table", tw("relative w-full"))
11150
- }, /* @__PURE__ */ React69.createElement("div", {
11326
+ }, /* @__PURE__ */ React71.createElement("div", {
11151
11327
  ref: topRef,
11152
11328
  className: tw("absolute top-0 h-1 w-full left-0 bg-transparent")
11153
- }), /* @__PURE__ */ React69.createElement(Table, __spreadValues({}, rest), children), /* @__PURE__ */ React69.createElement("div", {
11329
+ }), /* @__PURE__ */ React71.createElement(Table, __spreadValues({}, rest), children), /* @__PURE__ */ React71.createElement("div", {
11154
11330
  ref: bottomRef,
11155
11331
  className: tw("absolute bottom-0 h-1 w-full left-0 bg-transparent")
11156
11332
  }));
@@ -11211,13 +11387,13 @@ var DataTable = (_a) => {
11211
11387
  );
11212
11388
  const sortedRows = sortRowsBy(rows, sort);
11213
11389
  const amountOfColumns = columns.length + (menu ? 1 : 0);
11214
- const PaginationFooter = React70.useCallback(
11215
- ({ children }) => /* @__PURE__ */ React70.createElement("tfoot", null, /* @__PURE__ */ React70.createElement("tr", null, /* @__PURE__ */ React70.createElement("td", {
11390
+ const PaginationFooter = React72.useCallback(
11391
+ ({ children }) => /* @__PURE__ */ React72.createElement("tfoot", null, /* @__PURE__ */ React72.createElement("tr", null, /* @__PURE__ */ React72.createElement("td", {
11216
11392
  colSpan: amountOfColumns
11217
11393
  }, children))),
11218
11394
  [amountOfColumns]
11219
11395
  );
11220
- return /* @__PURE__ */ React70.createElement(Table2, {
11396
+ return /* @__PURE__ */ React72.createElement(Table2, {
11221
11397
  ariaLabel,
11222
11398
  onNext,
11223
11399
  onPrev,
@@ -11229,30 +11405,30 @@ var DataTable = (_a) => {
11229
11405
  "table-fixed": layout === "fixed"
11230
11406
  })
11231
11407
  )
11232
- }, /* @__PURE__ */ React70.createElement(Table2.Head, {
11408
+ }, /* @__PURE__ */ React72.createElement(Table2.Head, {
11233
11409
  sticky
11234
11410
  }, compact2([
11235
11411
  ...columns.map((column) => {
11236
- const content = column.headerTooltip && !column.headerInvisible ? /* @__PURE__ */ React70.createElement(Tooltip, {
11412
+ const content = column.headerTooltip && !column.headerInvisible ? /* @__PURE__ */ React72.createElement(Tooltip, {
11237
11413
  placement: column.headerTooltip.placement,
11238
11414
  content: column.headerTooltip.content
11239
11415
  }, column.headerName) : !column.headerInvisible && column.headerName;
11240
- return columnIsFieldColumn(column) && column.sortable || column.sort ? /* @__PURE__ */ React70.createElement(Table2.SortCell, __spreadValues({
11416
+ return columnIsFieldColumn(column) && column.sortable || column.sort ? /* @__PURE__ */ React72.createElement(Table2.SortCell, __spreadValues({
11241
11417
  direction: sort && sort.column.headerName === column.headerName ? sort.direction : "none",
11242
11418
  onClick: () => updateSort(column),
11243
11419
  style: { width: column.width },
11244
11420
  "aria-label": column.headerInvisible ? column.headerName : void 0
11245
- }, cellProps(column)), content) : /* @__PURE__ */ React70.createElement(Table2.Cell, __spreadProps(__spreadValues({}, cellProps(column)), {
11421
+ }, cellProps(column)), content) : /* @__PURE__ */ React72.createElement(Table2.Cell, __spreadProps(__spreadValues({}, cellProps(column)), {
11246
11422
  style: { width: column.width },
11247
11423
  "aria-label": column.headerInvisible ? column.headerName : void 0
11248
11424
  }), content);
11249
11425
  }),
11250
- menu ? /* @__PURE__ */ React70.createElement(Table2.Cell, {
11426
+ menu ? /* @__PURE__ */ React72.createElement(Table2.Cell, {
11251
11427
  key: "__contextMenu",
11252
11428
  align: "right",
11253
11429
  "aria-label": menuAriaLabel
11254
11430
  }, menuHeaderName) : null
11255
- ])), /* @__PURE__ */ React70.createElement(List2, __spreadProps(__spreadValues({
11431
+ ])), /* @__PURE__ */ React72.createElement(List, __spreadProps(__spreadValues({
11256
11432
  container: Table2.Body,
11257
11433
  paginationContainer: PaginationFooter
11258
11434
  }, rest), {
@@ -11260,30 +11436,30 @@ var DataTable = (_a) => {
11260
11436
  renderItem: (row, index) => {
11261
11437
  var _a3;
11262
11438
  const isRowDisabled = (_a3 = disabled == null ? void 0 : disabled(row, index, sortedRows)) != null ? _a3 : false;
11263
- return /* @__PURE__ */ React70.createElement(Table2.Row, {
11439
+ return /* @__PURE__ */ React72.createElement(Table2.Row, {
11264
11440
  key: row.id,
11265
11441
  disabled: isRowDisabled
11266
- }, /* @__PURE__ */ React70.createElement(List2, {
11442
+ }, /* @__PURE__ */ React72.createElement(List, {
11267
11443
  items: columns,
11268
- renderItem: (column) => /* @__PURE__ */ React70.createElement(Table2.Cell, __spreadValues({}, cellProps(column)), renderCell2(column, row, index, sortedRows))
11269
- }), renderRowMenu2(row, index, { menu, menuAriaLabel, onAction, onMenuOpenChange }));
11444
+ renderItem: (column) => /* @__PURE__ */ React72.createElement(Table2.Cell, __spreadValues({}, cellProps(column)), renderCell(column, row, index, sortedRows))
11445
+ }), renderRowMenu(row, index, { menu, menuAriaLabel, onAction, onMenuOpenChange }));
11270
11446
  }
11271
11447
  })));
11272
11448
  };
11273
- var renderRowMenu2 = (row, index, {
11449
+ var renderRowMenu = (row, index, {
11274
11450
  menu,
11275
11451
  onAction,
11276
11452
  onMenuOpenChange,
11277
11453
  menuAriaLabel
11278
11454
  }) => {
11279
11455
  if (menu) {
11280
- const menuContent = isFunction2(menu) ? menu(row, index) : menu;
11281
- return /* @__PURE__ */ React70.createElement(Table2.Cell, {
11456
+ const menuContent = isFunction4(menu) ? menu(row, index) : menu;
11457
+ return /* @__PURE__ */ React72.createElement(Table2.Cell, {
11282
11458
  align: "right"
11283
- }, menuContent && /* @__PURE__ */ React70.createElement(DropdownMenu2, {
11459
+ }, menuContent && /* @__PURE__ */ React72.createElement(DropdownMenu2, {
11284
11460
  onAction: (action) => onAction == null ? void 0 : onAction(action, row, index),
11285
11461
  onOpenChange: onMenuOpenChange
11286
- }, /* @__PURE__ */ React70.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React70.createElement(Button.Icon, {
11462
+ }, /* @__PURE__ */ React72.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React72.createElement(Button.Icon, {
11287
11463
  "aria-label": menuAriaLabel,
11288
11464
  icon: import_more3.default
11289
11465
  })), menuContent));
@@ -11291,19 +11467,19 @@ var renderRowMenu2 = (row, index, {
11291
11467
  return void 0;
11292
11468
  };
11293
11469
  var DEFAULT_CONTENT2 = "";
11294
- var renderCell2 = (column, row, index, rows) => {
11470
+ var renderCell = (column, row, index, rows) => {
11295
11471
  let cellContent = DEFAULT_CONTENT2;
11296
11472
  if (column.type === "status") {
11297
11473
  const status = column.status(row, index, rows);
11298
11474
  if (status) {
11299
- cellContent = /* @__PURE__ */ React70.createElement(StatusChip, __spreadValues({
11475
+ cellContent = /* @__PURE__ */ React72.createElement(StatusChip, __spreadValues({
11300
11476
  dense: true
11301
11477
  }, status));
11302
11478
  }
11303
11479
  } else if (column.type === "action") {
11304
11480
  const action = renameProperty("text", "children", column.action(row, index, rows));
11305
11481
  if (action) {
11306
- cellContent = /* @__PURE__ */ React70.createElement(Button.Secondary, __spreadValues({
11482
+ cellContent = /* @__PURE__ */ React72.createElement(Button.Secondary, __spreadValues({
11307
11483
  dense: true
11308
11484
  }, action));
11309
11485
  }
@@ -11312,19 +11488,19 @@ var renderCell2 = (column, row, index, rows) => {
11312
11488
  } else if (column.type === "item") {
11313
11489
  const item = column.item(row, index, rows);
11314
11490
  if (item) {
11315
- cellContent = /* @__PURE__ */ React70.createElement(Item4, __spreadValues({}, item));
11491
+ cellContent = /* @__PURE__ */ React72.createElement(Item2, __spreadValues({}, item));
11316
11492
  }
11317
11493
  } else if (column.formatter) {
11318
11494
  cellContent = column.formatter(row[column.field], row, index, rows);
11319
11495
  } else {
11320
11496
  cellContent = row[column.field];
11321
11497
  }
11322
- return column.tooltip ? /* @__PURE__ */ React70.createElement(Tooltip, __spreadValues({}, column.tooltip(row, index, rows)), cellContent) : cellContent;
11498
+ return column.tooltip ? /* @__PURE__ */ React72.createElement(Tooltip, __spreadValues({}, column.tooltip(row, index, rows)), cellContent) : cellContent;
11323
11499
  };
11324
11500
  DataTable.Skeleton = DataListSkeleton;
11325
11501
 
11326
11502
  // src/molecules/Dialog/Dialog.tsx
11327
- import React72 from "react";
11503
+ import React74 from "react";
11328
11504
  import { useDialog } from "@react-aria/dialog";
11329
11505
  import { Overlay as Overlay2, useModalOverlay } from "@react-aria/overlays";
11330
11506
  import { useId as useId8 } from "@react-aria/utils";
@@ -11351,7 +11527,7 @@ var DIALOG_ICONS_AND_COLORS = {
11351
11527
  };
11352
11528
 
11353
11529
  // src/atoms/Modal/Modal.tsx
11354
- import React71 from "react";
11530
+ import React73 from "react";
11355
11531
  var Modal = (_a) => {
11356
11532
  var _b = _a, {
11357
11533
  children,
@@ -11364,7 +11540,7 @@ var Modal = (_a) => {
11364
11540
  "className",
11365
11541
  "open"
11366
11542
  ]);
11367
- return open ? /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11543
+ return open ? /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11368
11544
  className: classNames(
11369
11545
  tw("inset-0 overflow-y-auto z-modal fixed"),
11370
11546
  {
@@ -11376,11 +11552,11 @@ var Modal = (_a) => {
11376
11552
  };
11377
11553
  Modal.BackDrop = (_a) => {
11378
11554
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
11379
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11555
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11380
11556
  className: classNames(tw("-z-10 fixed min-w-full min-h-full bg-primary-100 opacity-60"), className)
11381
11557
  }));
11382
11558
  };
11383
- Modal.Dialog = React71.forwardRef(
11559
+ Modal.Dialog = React73.forwardRef(
11384
11560
  (_a, ref) => {
11385
11561
  var _b = _a, { kind = "dialog", children, className, size = "sm" } = _b, rest = __objRest(_b, ["kind", "children", "className", "size"]);
11386
11562
  const commonClasses = tw("bg-white max-h-full flex flex-col");
@@ -11394,7 +11570,7 @@ Modal.Dialog = React71.forwardRef(
11394
11570
  "w-[560px]": size === "md",
11395
11571
  "w-[1080px]": size === "full"
11396
11572
  });
11397
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({
11573
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({
11398
11574
  ref,
11399
11575
  "aria-modal": "true"
11400
11576
  }, rest), {
@@ -11404,31 +11580,31 @@ Modal.Dialog = React71.forwardRef(
11404
11580
  );
11405
11581
  Modal.Header = (_a) => {
11406
11582
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
11407
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11583
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11408
11584
  className: classNames(tw("pl-7 pr-[64px] py-6 gap-3 flex items-center"), className)
11409
11585
  }), children);
11410
11586
  };
11411
11587
  Modal.HeaderImage = (_a) => {
11412
11588
  var _b = _a, { backgroundImage, className } = _b, rest = __objRest(_b, ["backgroundImage", "className"]);
11413
11589
  const common = tw("h-[120px] min-h-[120px] w-full ");
11414
- return backgroundImage ? /* @__PURE__ */ React71.createElement("img", __spreadProps(__spreadValues({
11590
+ return backgroundImage ? /* @__PURE__ */ React73.createElement("img", __spreadProps(__spreadValues({
11415
11591
  "aria-hidden": true,
11416
11592
  src: backgroundImage != null ? backgroundImage : void 0
11417
11593
  }, rest), {
11418
11594
  className: classNames(common, tw("object-cover"), className)
11419
- })) : /* @__PURE__ */ React71.createElement("div", {
11595
+ })) : /* @__PURE__ */ React73.createElement("div", {
11420
11596
  className: classNames(common, tw("bg-grey-5"), className)
11421
11597
  });
11422
11598
  };
11423
11599
  Modal.CloseButtonContainer = (_a) => {
11424
11600
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
11425
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11601
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11426
11602
  className: classNames(tw("absolute top-[24px] right-[28px]"), className)
11427
11603
  }));
11428
11604
  };
11429
11605
  Modal.Title = (_a) => {
11430
11606
  var _b = _a, { kind = "dialog", children, className } = _b, rest = __objRest(_b, ["kind", "children", "className"]);
11431
- return /* @__PURE__ */ React71.createElement(Typography, __spreadValues({
11607
+ return /* @__PURE__ */ React73.createElement(Typography, __spreadValues({
11432
11608
  htmlTag: "h2",
11433
11609
  variant: "subheading",
11434
11610
  color: "grey-90",
@@ -11442,52 +11618,52 @@ Modal.Title = (_a) => {
11442
11618
  };
11443
11619
  Modal.Subtitle = (_a) => {
11444
11620
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
11445
- return /* @__PURE__ */ React71.createElement(Typography, __spreadValues({
11621
+ return /* @__PURE__ */ React73.createElement(Typography, __spreadValues({
11446
11622
  variant: "small",
11447
11623
  color: "grey-60"
11448
11624
  }, rest), children);
11449
11625
  };
11450
11626
  Modal.TitleContainer = (_a) => {
11451
11627
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
11452
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11628
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11453
11629
  className: classNames(tw("flex flex-col grow"), className)
11454
11630
  }), children);
11455
11631
  };
11456
11632
  Modal.Body = (_a) => {
11457
11633
  var _b = _a, { children, className, noFooter = false, maxHeight, style } = _b, rest = __objRest(_b, ["children", "className", "noFooter", "maxHeight", "style"]);
11458
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11634
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11459
11635
  className: classNames(tw("px-7 grow overflow-y-auto", { "pb-6": noFooter }), className),
11460
11636
  style: __spreadValues({ maxHeight }, style)
11461
11637
  }), children);
11462
11638
  };
11463
11639
  Modal.Footer = (_a) => {
11464
11640
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
11465
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11641
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11466
11642
  className: classNames(tw("px-7 py-6"), className)
11467
11643
  }), children);
11468
11644
  };
11469
11645
  Modal.Actions = (_a) => {
11470
11646
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
11471
- return /* @__PURE__ */ React71.createElement("div", __spreadProps(__spreadValues({}, rest), {
11647
+ return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11472
11648
  className: classNames(tw("flex gap-4 justify-end"), className)
11473
11649
  }), children);
11474
11650
  };
11475
11651
 
11476
11652
  // src/molecules/Dialog/Dialog.tsx
11477
11653
  var Dialog = (props) => {
11478
- const ref = React72.useRef(null);
11654
+ const ref = React74.useRef(null);
11479
11655
  const state = useOverlayTriggerState2({ isOpen: props.open });
11480
11656
  const { modalProps, underlayProps } = useModalOverlay({}, state, ref);
11481
11657
  if (!state.isOpen) {
11482
11658
  return null;
11483
11659
  }
11484
- return /* @__PURE__ */ React72.createElement(Overlay2, null, /* @__PURE__ */ React72.createElement(Modal, {
11660
+ return /* @__PURE__ */ React74.createElement(Overlay2, null, /* @__PURE__ */ React74.createElement(Modal, {
11485
11661
  className: "Aquarium-Dialog",
11486
11662
  open: true
11487
- }, /* @__PURE__ */ React72.createElement(Modal.BackDrop, __spreadValues({}, underlayProps)), /* @__PURE__ */ React72.createElement(Modal.Dialog, __spreadValues({
11663
+ }, /* @__PURE__ */ React74.createElement(Modal.BackDrop, __spreadValues({}, underlayProps)), /* @__PURE__ */ React74.createElement(Modal.Dialog, __spreadValues({
11488
11664
  ref,
11489
11665
  size: "sm"
11490
- }, modalProps), /* @__PURE__ */ React72.createElement(DialogWrapper, __spreadValues({}, props)))));
11666
+ }, modalProps), /* @__PURE__ */ React74.createElement(DialogWrapper, __spreadValues({}, props)))));
11491
11667
  };
11492
11668
  var DialogWrapper = ({
11493
11669
  title,
@@ -11496,38 +11672,38 @@ var DialogWrapper = ({
11496
11672
  primaryAction,
11497
11673
  secondaryAction
11498
11674
  }) => {
11499
- const ref = React72.useRef(null);
11675
+ const ref = React74.useRef(null);
11500
11676
  const labelledBy = useId8();
11501
11677
  const describedBy = useId8();
11502
11678
  const { dialogProps } = useDialog(
11503
11679
  { "role": "alertdialog", "aria-labelledby": labelledBy, "aria-describedby": describedBy },
11504
11680
  ref
11505
11681
  );
11506
- return /* @__PURE__ */ React72.createElement("div", __spreadProps(__spreadValues({
11682
+ return /* @__PURE__ */ React74.createElement("div", __spreadProps(__spreadValues({
11507
11683
  ref
11508
11684
  }, dialogProps), {
11509
11685
  className: tw("outline-none")
11510
- }), /* @__PURE__ */ React72.createElement(Modal.Header, {
11686
+ }), /* @__PURE__ */ React74.createElement(Modal.Header, {
11511
11687
  className: tw("icon-stroke-2")
11512
- }, /* @__PURE__ */ React72.createElement(Icon, {
11688
+ }, /* @__PURE__ */ React74.createElement(Icon, {
11513
11689
  icon: DIALOG_ICONS_AND_COLORS[type].icon,
11514
11690
  color: DIALOG_ICONS_AND_COLORS[type].color,
11515
11691
  fontSize: 20
11516
- }), /* @__PURE__ */ React72.createElement(Modal.Title, {
11692
+ }), /* @__PURE__ */ React74.createElement(Modal.Title, {
11517
11693
  id: labelledBy,
11518
11694
  variant: "large",
11519
11695
  color: DIALOG_ICONS_AND_COLORS[type].color
11520
- }, title)), /* @__PURE__ */ React72.createElement(Modal.Body, {
11696
+ }, title)), /* @__PURE__ */ React74.createElement(Modal.Body, {
11521
11697
  id: describedBy
11522
- }, /* @__PURE__ */ React72.createElement(Typography2.Default, null, children)), /* @__PURE__ */ React72.createElement(Modal.Footer, null, /* @__PURE__ */ React72.createElement(Modal.Actions, null, secondaryAction && /* @__PURE__ */ React72.createElement(Button.Ghost, __spreadValues({
11698
+ }, /* @__PURE__ */ React74.createElement(Typography2.Default, null, children)), /* @__PURE__ */ React74.createElement(Modal.Footer, null, /* @__PURE__ */ React74.createElement(Modal.Actions, null, secondaryAction && /* @__PURE__ */ React74.createElement(Button.Ghost, __spreadValues({
11523
11699
  key: secondaryAction.text
11524
- }, omit8(secondaryAction, "text")), secondaryAction.text), /* @__PURE__ */ React72.createElement(Button.Secondary, __spreadValues({
11700
+ }, omit8(secondaryAction, "text")), secondaryAction.text), /* @__PURE__ */ React74.createElement(Button.Secondary, __spreadValues({
11525
11701
  key: primaryAction.text
11526
11702
  }, omit8(primaryAction, "text")), primaryAction.text))));
11527
11703
  };
11528
11704
 
11529
11705
  // src/molecules/Drawer/Drawer.tsx
11530
- import React74, { useEffect as useEffect10 } from "react";
11706
+ import React76, { useEffect as useEffect10 } from "react";
11531
11707
  import { useOverlayTriggerState as useOverlayTriggerState3 } from "react-stately";
11532
11708
  import { useDialog as useDialog2 } from "@react-aria/dialog";
11533
11709
  import { Overlay as Overlay3, useModalOverlay as useModalOverlay2 } from "@react-aria/overlays";
@@ -11537,18 +11713,18 @@ import castArray from "lodash/castArray";
11537
11713
  import omit9 from "lodash/omit";
11538
11714
 
11539
11715
  // src/molecules/Tabs/Tabs.tsx
11540
- import React73, { useEffect as useEffect9, useLayoutEffect as useLayoutEffect2, useRef as useRef7, useState as useState10 } from "react";
11716
+ import React75, { useEffect as useEffect9, useLayoutEffect as useLayoutEffect2, useRef as useRef7, useState as useState10 } from "react";
11541
11717
  import isNumber5 from "lodash/isNumber";
11542
11718
  import kebabCase from "lodash/kebabCase";
11543
11719
  var import_chevronLeft4 = __toESM(require_chevronLeft());
11544
11720
  var import_chevronRight4 = __toESM(require_chevronRight());
11545
11721
  var import_warningSign4 = __toESM(require_warningSign());
11546
11722
  var isTabComponent = (c) => {
11547
- return React73.isValidElement(c) && (c.type === Tab || c.type === ModalTab);
11723
+ return React75.isValidElement(c) && (c.type === Tab || c.type === ModalTab);
11548
11724
  };
11549
- var Tab = React73.forwardRef(
11725
+ var Tab = React75.forwardRef(
11550
11726
  ({ className, id, title, children }, ref) => {
11551
- return /* @__PURE__ */ React73.createElement("div", {
11727
+ return /* @__PURE__ */ React75.createElement("div", {
11552
11728
  ref,
11553
11729
  id: `${id != null ? id : kebabCase(title)}-panel`,
11554
11730
  className,
@@ -11560,14 +11736,14 @@ var Tab = React73.forwardRef(
11560
11736
  );
11561
11737
  var TabContainer = (_a) => {
11562
11738
  var _b = _a, { className, children } = _b, rest = __objRest(_b, ["className", "children"]);
11563
- return /* @__PURE__ */ React73.createElement("div", __spreadProps(__spreadValues({}, rest), {
11739
+ return /* @__PURE__ */ React75.createElement("div", __spreadProps(__spreadValues({}, rest), {
11564
11740
  className: classNames("py-6 z-0", className)
11565
11741
  }), children);
11566
11742
  };
11567
11743
  var ModalTab = Tab;
11568
11744
  var ModalTabContainer = TabContainer;
11569
11745
  var asTabItem = (Component, displayName, { defaultUnderlineHidden } = {}) => {
11570
- const Tab2 = React73.forwardRef(
11746
+ const Tab2 = React75.forwardRef(
11571
11747
  (_a, ref) => {
11572
11748
  var _b = _a, {
11573
11749
  id,
@@ -11599,17 +11775,17 @@ var asTabItem = (Component, displayName, { defaultUnderlineHidden } = {}) => {
11599
11775
  const _id = id != null ? id : kebabCase(title);
11600
11776
  let statusIcon = void 0;
11601
11777
  if (status === "warning") {
11602
- statusIcon = /* @__PURE__ */ React73.createElement(InlineIcon, {
11778
+ statusIcon = /* @__PURE__ */ React75.createElement(InlineIcon, {
11603
11779
  icon: import_warningSign4.default,
11604
11780
  color: selected ? void 0 : "warning-80"
11605
11781
  });
11606
11782
  } else if (status === "error") {
11607
- statusIcon = /* @__PURE__ */ React73.createElement(InlineIcon, {
11783
+ statusIcon = /* @__PURE__ */ React75.createElement(InlineIcon, {
11608
11784
  icon: import_warningSign4.default,
11609
11785
  color: selected ? void 0 : "error-50"
11610
11786
  });
11611
11787
  }
11612
- const tab = /* @__PURE__ */ React73.createElement(Component, __spreadValues({
11788
+ const tab = /* @__PURE__ */ React75.createElement(Component, __spreadValues({
11613
11789
  ref,
11614
11790
  id: `${_id}-tab`,
11615
11791
  onClick: () => !disabled && onSelected(value != null ? value : index),
@@ -11626,29 +11802,29 @@ var asTabItem = (Component, displayName, { defaultUnderlineHidden } = {}) => {
11626
11802
  "aria-selected": selected,
11627
11803
  "aria-controls": `${_id}-panel`,
11628
11804
  tabIndex: disabled ? void 0 : 0
11629
- }, rest), /* @__PURE__ */ React73.createElement(Typography2, {
11805
+ }, rest), /* @__PURE__ */ React75.createElement(Typography2, {
11630
11806
  htmlTag: "div",
11631
11807
  variant: "small-strong",
11632
11808
  color: selected ? "primary-80" : disabled ? "grey-20" : "current",
11633
11809
  className: tw("inline-flex items-center gap-3")
11634
- }, showNotification ? /* @__PURE__ */ React73.createElement(Badge.Notification, {
11810
+ }, showNotification ? /* @__PURE__ */ React75.createElement(Badge.Notification, {
11635
11811
  right: "-4px",
11636
11812
  top: "3px"
11637
- }, /* @__PURE__ */ React73.createElement("span", {
11813
+ }, /* @__PURE__ */ React75.createElement("span", {
11638
11814
  className: tw("whitespace-nowrap")
11639
- }, title)) : /* @__PURE__ */ React73.createElement("span", {
11815
+ }, title)) : /* @__PURE__ */ React75.createElement("span", {
11640
11816
  className: tw("whitespace-nowrap")
11641
- }, title), isNumber5(badge) && /* @__PURE__ */ React73.createElement(Typography2, {
11817
+ }, title), isNumber5(badge) && /* @__PURE__ */ React75.createElement(Typography2, {
11642
11818
  htmlTag: "span",
11643
11819
  variant: "small",
11644
11820
  color: selected ? "primary-80" : "grey-5",
11645
11821
  className: "leading-none"
11646
- }, /* @__PURE__ */ React73.createElement(TabBadge, {
11822
+ }, /* @__PURE__ */ React75.createElement(TabBadge, {
11647
11823
  kind: "filled",
11648
11824
  value: badge,
11649
11825
  textClassname: classNames({ "text-white": selected, "text-grey-50": !selected })
11650
11826
  })), statusIcon));
11651
- return tooltip ? /* @__PURE__ */ React73.createElement(Tooltip, {
11827
+ return tooltip ? /* @__PURE__ */ React75.createElement(Tooltip, {
11652
11828
  content: tooltip
11653
11829
  }, tab) : tab;
11654
11830
  }
@@ -11662,7 +11838,7 @@ var createTabsComponent = (TabComponent, TabItemComponent, displayName, renderCh
11662
11838
  const Tabs2 = (props) => {
11663
11839
  var _a, _b;
11664
11840
  const { className, value, defaultValue, onChange, children } = props;
11665
- const childArr = React73.Children.toArray(children);
11841
+ const childArr = React75.Children.toArray(children);
11666
11842
  const firstTab = childArr[0];
11667
11843
  const firstTabValue = isTabComponent(firstTab) ? firstTab.props.value : -1;
11668
11844
  const [selected, setSelected] = useState10((_b = (_a = value != null ? value : defaultValue) != null ? _a : firstTabValue) != null ? _b : 0);
@@ -11675,7 +11851,7 @@ var createTabsComponent = (TabComponent, TabItemComponent, displayName, renderCh
11675
11851
  var _a2, _b2;
11676
11852
  const container = containerRef.current;
11677
11853
  const tabs = tabsRef.current;
11678
- const values = React73.Children.map(
11854
+ const values = React75.Children.map(
11679
11855
  children,
11680
11856
  (tab, i) => {
11681
11857
  var _a3;
@@ -11716,7 +11892,7 @@ var createTabsComponent = (TabComponent, TabItemComponent, displayName, renderCh
11716
11892
  updateCarets();
11717
11893
  setSelected(value);
11718
11894
  revealSelectedTab({ smooth: value !== selected });
11719
- }, [value, React73.Children.count(children)]);
11895
+ }, [value, React75.Children.count(children)]);
11720
11896
  useLayoutEffect2(() => {
11721
11897
  var _a2;
11722
11898
  updateCarets();
@@ -11780,27 +11956,27 @@ var createTabsComponent = (TabComponent, TabItemComponent, displayName, renderCh
11780
11956
  const handleSelected = (key) => {
11781
11957
  (onChange != null ? onChange : setSelected)(key);
11782
11958
  };
11783
- React73.Children.forEach(children, (c) => {
11959
+ React75.Children.forEach(children, (c) => {
11784
11960
  if (c && !isTabComponent(c)) {
11785
11961
  throw new Error("<Tabs> can only have <Tabs.Tab> components as children");
11786
11962
  }
11787
11963
  });
11788
- return /* @__PURE__ */ React73.createElement("div", {
11964
+ return /* @__PURE__ */ React75.createElement("div", {
11789
11965
  ref: parentRef,
11790
11966
  className: classNames("Aquarium-Tabs", tw("h-full"), className)
11791
- }, /* @__PURE__ */ React73.createElement("div", {
11967
+ }, /* @__PURE__ */ React75.createElement("div", {
11792
11968
  className: tw("relative flex items-center border-b-2 border-grey-10")
11793
- }, /* @__PURE__ */ React73.createElement("div", {
11969
+ }, /* @__PURE__ */ React75.createElement("div", {
11794
11970
  ref: containerRef,
11795
11971
  className: tw("overflow-y-auto scrollbar-hide h-full mb-[-2px]")
11796
- }, /* @__PURE__ */ React73.createElement("div", {
11972
+ }, /* @__PURE__ */ React75.createElement("div", {
11797
11973
  ref: tabsRef,
11798
11974
  role: "tablist",
11799
11975
  "aria-label": "tabs",
11800
11976
  className: tw("inline-flex items-center cursor-pointer font-normal h-full")
11801
- }, React73.Children.map(
11977
+ }, React75.Children.map(
11802
11978
  children,
11803
- (tab, index) => tab ? /* @__PURE__ */ React73.createElement(TabItemComponent, __spreadProps(__spreadValues({
11979
+ (tab, index) => tab ? /* @__PURE__ */ React75.createElement(TabItemComponent, __spreadProps(__spreadValues({
11804
11980
  key: tab.props.value
11805
11981
  }, tab.props), {
11806
11982
  index,
@@ -11808,20 +11984,20 @@ var createTabsComponent = (TabComponent, TabItemComponent, displayName, renderCh
11808
11984
  onKeyDown: handleKeyDown,
11809
11985
  onSelected: handleSelected
11810
11986
  })) : void 0
11811
- ))), leftCaret && /* @__PURE__ */ React73.createElement("div", {
11987
+ ))), leftCaret && /* @__PURE__ */ React75.createElement("div", {
11812
11988
  className: tw("absolute left-0 bg-gradient-to-r from-white via-white z-20 py-3 pr-4")
11813
- }, /* @__PURE__ */ React73.createElement("div", {
11989
+ }, /* @__PURE__ */ React75.createElement("div", {
11814
11990
  onClick: () => handleScrollToNext("left"),
11815
11991
  className: tw("hover:bg-grey-0 p-2 leading-none cursor-pointer")
11816
- }, /* @__PURE__ */ React73.createElement(InlineIcon, {
11992
+ }, /* @__PURE__ */ React75.createElement(InlineIcon, {
11817
11993
  icon: import_chevronLeft4.default
11818
- }))), rightCaret && /* @__PURE__ */ React73.createElement("div", {
11994
+ }))), rightCaret && /* @__PURE__ */ React75.createElement("div", {
11819
11995
  onClick: () => handleScrollToNext("right"),
11820
11996
  className: tw("absolute right-0 bg-gradient-to-l from-white via-white z-20 py-3 pl-4")
11821
- }, /* @__PURE__ */ React73.createElement("div", {
11997
+ }, /* @__PURE__ */ React75.createElement("div", {
11822
11998
  onClick: () => handleScrollToNext("right"),
11823
11999
  className: tw("hover:bg-grey-0 p-2 leading-none cursor-pointer")
11824
- }, /* @__PURE__ */ React73.createElement(InlineIcon, {
12000
+ }, /* @__PURE__ */ React75.createElement(InlineIcon, {
11825
12001
  icon: import_chevronRight4.default
11826
12002
  })))), renderChildren(children, selected, props));
11827
12003
  };
@@ -11829,7 +12005,7 @@ var createTabsComponent = (TabComponent, TabItemComponent, displayName, renderCh
11829
12005
  Tabs2.Tab = TabComponent;
11830
12006
  return Tabs2;
11831
12007
  };
11832
- var Tabs = createTabsComponent(Tab, TabItem, "Tabs", (children, selected) => /* @__PURE__ */ React73.createElement(TabContainer, null, children.find(
12008
+ var Tabs = createTabsComponent(Tab, TabItem, "Tabs", (children, selected) => /* @__PURE__ */ React75.createElement(TabContainer, null, children.find(
11833
12009
  (node, index) => (node == null ? void 0 : node.props.value) === selected || index === selected
11834
12010
  )));
11835
12011
 
@@ -11846,8 +12022,8 @@ var WIDTHS = {
11846
12022
  var Drawer = (_a) => {
11847
12023
  var _b = _a, { open, closeOnEsc = true } = _b, props = __objRest(_b, ["open", "closeOnEsc"]);
11848
12024
  const { onClose, size = "sm", portalContainer } = props;
11849
- const [hidden, setHidden] = React74.useState(!open);
11850
- const ref = React74.useRef(null);
12025
+ const [hidden, setHidden] = React76.useState(!open);
12026
+ const ref = React76.useRef(null);
11851
12027
  const state = useOverlayTriggerState3({ isOpen: !hidden, onOpenChange: (isOpen) => !isOpen && onClose() });
11852
12028
  useEffect10(() => {
11853
12029
  if (open && hidden) {
@@ -11876,21 +12052,21 @@ var Drawer = (_a) => {
11876
12052
  if (!state.isOpen) {
11877
12053
  return null;
11878
12054
  }
11879
- return /* @__PURE__ */ React74.createElement(Overlay3, {
12055
+ return /* @__PURE__ */ React76.createElement(Overlay3, {
11880
12056
  portalContainer
11881
- }, /* @__PURE__ */ React74.createElement(Modal, {
12057
+ }, /* @__PURE__ */ React76.createElement(Modal, {
11882
12058
  kind: "drawer",
11883
12059
  className: "Aquarium-Drawer overflow-x-hidden",
11884
12060
  open: true
11885
- }, /* @__PURE__ */ React74.createElement(AnimatedBackDrop, __spreadValues({
12061
+ }, /* @__PURE__ */ React76.createElement(AnimatedBackDrop, __spreadValues({
11886
12062
  style: { opacity }
11887
- }, underlayProps)), /* @__PURE__ */ React74.createElement(DrawerWrapper, __spreadProps(__spreadValues(__spreadValues({
12063
+ }, underlayProps)), /* @__PURE__ */ React76.createElement(DrawerWrapper, __spreadProps(__spreadValues(__spreadValues({
11888
12064
  ref
11889
12065
  }, props), modalProps), {
11890
12066
  spring: { transform }
11891
12067
  }))));
11892
12068
  };
11893
- var DrawerWrapper = React74.forwardRef(
12069
+ var DrawerWrapper = React76.forwardRef(
11894
12070
  (_a, ref) => {
11895
12071
  var _b = _a, {
11896
12072
  title,
@@ -11927,60 +12103,62 @@ var DrawerWrapper = React74.forwardRef(
11927
12103
  ref
11928
12104
  );
11929
12105
  const dialogSize = size === "lg" ? "full" : size;
11930
- const hasTabs = isComponentType(children, Tabs);
11931
- return /* @__PURE__ */ React74.createElement(AnimatedDialog, __spreadProps(__spreadValues(__spreadValues({
12106
+ const childElements = React76.Children.toArray(children).filter(React76.isValidElement);
12107
+ const onlyChild = childElements.length === 1 ? childElements[0] : null;
12108
+ const hasTabs = isComponentType(onlyChild, Tabs);
12109
+ return /* @__PURE__ */ React76.createElement(AnimatedDialog, __spreadProps(__spreadValues(__spreadValues({
11932
12110
  ref,
11933
12111
  kind: "drawer",
11934
12112
  "aria-modal": "true",
11935
12113
  size: dialogSize
11936
12114
  }, props), dialogProps), {
11937
12115
  style: __spreadValues({}, spring)
11938
- }), /* @__PURE__ */ React74.createElement(Modal.CloseButtonContainer, null, /* @__PURE__ */ React74.createElement(Button.Icon, {
12116
+ }), /* @__PURE__ */ React76.createElement(Modal.CloseButtonContainer, null, /* @__PURE__ */ React76.createElement(Button.Icon, {
11939
12117
  "aria-label": "Close",
11940
12118
  icon: import_cross6.default,
11941
12119
  onClick: onClose
11942
- })), /* @__PURE__ */ React74.createElement(Modal.Header, {
12120
+ })), /* @__PURE__ */ React76.createElement(Modal.Header, {
11943
12121
  className: tw({ "pb-3": hasTabs })
11944
- }, /* @__PURE__ */ React74.createElement(Modal.Title, {
12122
+ }, /* @__PURE__ */ React76.createElement(Modal.Title, {
11945
12123
  id: labelledBy,
11946
12124
  kind: "drawer"
11947
- }, title)), hasTabs ? /* @__PURE__ */ React74.createElement(DrawerTabs, __spreadProps(__spreadValues({}, children.props), {
12125
+ }, title)), hasTabs ? /* @__PURE__ */ React76.createElement(DrawerTabs, __spreadProps(__spreadValues({}, onlyChild.props), {
11948
12126
  className: tw("[&>div:first-child]:px-5 grow flex flex-col overflow-y-auto")
11949
- })) : /* @__PURE__ */ React74.createElement(Modal.Body, {
12127
+ })) : /* @__PURE__ */ React76.createElement(Modal.Body, {
11950
12128
  id: describedBy,
11951
12129
  tabIndex: 0,
11952
12130
  noFooter: !(secondaryActions || primaryAction)
11953
- }, children), (secondaryActions || primaryAction) && /* @__PURE__ */ React74.createElement(Modal.Footer, null, /* @__PURE__ */ React74.createElement(Modal.Actions, {
12131
+ }, children), (secondaryActions || primaryAction) && /* @__PURE__ */ React76.createElement(Modal.Footer, null, /* @__PURE__ */ React76.createElement(Modal.Actions, {
11954
12132
  className: size === "sm" ? tw("flex-col") : void 0
11955
- }, size !== "sm" && menu && /* @__PURE__ */ React74.createElement(Box.Flex, {
12133
+ }, size !== "sm" && menu && /* @__PURE__ */ React76.createElement(Box.Flex, {
11956
12134
  alignItems: "center"
11957
- }, /* @__PURE__ */ React74.createElement(DropdownMenu2, {
12135
+ }, /* @__PURE__ */ React76.createElement(DropdownMenu2, {
11958
12136
  onAction: (action) => onAction == null ? void 0 : onAction(action),
11959
12137
  onOpenChange: onMenuOpenChange
11960
- }, /* @__PURE__ */ React74.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React74.createElement(Button.Icon, {
12138
+ }, /* @__PURE__ */ React76.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React76.createElement(Button.Icon, {
11961
12139
  "aria-label": (_a2 = menuAriaLabel != null ? menuAriaLabel : menuLabel) != null ? _a2 : "Context menu",
11962
12140
  icon: import_more4.default
11963
12141
  })), menu)), secondaryActions && castArray(secondaryActions).filter(Boolean).map((_b2) => {
11964
12142
  var _c = _b2, { text } = _c, action = __objRest(_c, ["text"]);
11965
- return /* @__PURE__ */ React74.createElement(Button.Secondary, __spreadValues({
12143
+ return /* @__PURE__ */ React76.createElement(Button.Secondary, __spreadValues({
11966
12144
  key: text
11967
12145
  }, action), text);
11968
- }), primaryAction && /* @__PURE__ */ React74.createElement(Button.Primary, __spreadValues({
12146
+ }), primaryAction && /* @__PURE__ */ React76.createElement(Button.Primary, __spreadValues({
11969
12147
  key: primaryAction.text
11970
12148
  }, omit9(primaryAction, "text")), primaryAction.text))));
11971
12149
  }
11972
12150
  );
11973
- var DrawerTabs = createTabsComponent(ModalTab, TabItem, "DrawerTabs", (children, selected) => /* @__PURE__ */ React74.createElement(Modal.Body, {
12151
+ var DrawerTabs = createTabsComponent(ModalTab, TabItem, "DrawerTabs", (children, selected) => /* @__PURE__ */ React76.createElement(Modal.Body, {
11974
12152
  className: tw("h-full")
11975
- }, /* @__PURE__ */ React74.createElement(ModalTabContainer, null, children.find(
12153
+ }, /* @__PURE__ */ React76.createElement(ModalTabContainer, null, children.find(
11976
12154
  (node, index) => (node == null ? void 0 : node.props.value) === selected || index === selected
11977
12155
  ))));
11978
12156
 
11979
12157
  // src/molecules/Dropdown/Dropdown.tsx
11980
- import React77 from "react";
12158
+ import React79 from "react";
11981
12159
 
11982
12160
  // src/molecules/Popover/Popover.tsx
11983
- import React76, { useRef as useRef8 } from "react";
12161
+ import React78, { useRef as useRef8 } from "react";
11984
12162
  import { PressResponder as PressResponder2, usePress as usePress2 } from "@react-aria/interactions";
11985
12163
  import { useOverlayTrigger } from "@react-aria/overlays";
11986
12164
  import { mergeProps as mergeProps3 } from "@react-aria/utils";
@@ -11989,12 +12167,12 @@ import classNames8 from "classnames";
11989
12167
  import omit10 from "lodash/omit";
11990
12168
 
11991
12169
  // src/molecules/Popover/Dialog.tsx
11992
- import React75 from "react";
12170
+ import React77 from "react";
11993
12171
  import { useDialog as useDialog3 } from "@react-aria/dialog";
11994
12172
  var Dialog2 = ({ children }) => {
11995
- const ref = React75.useRef(null);
12173
+ const ref = React77.useRef(null);
11996
12174
  const { dialogProps } = useDialog3({}, ref);
11997
- return /* @__PURE__ */ React75.createElement("div", __spreadProps(__spreadValues({
12175
+ return /* @__PURE__ */ React77.createElement("div", __spreadProps(__spreadValues({
11998
12176
  ref
11999
12177
  }, dialogProps), {
12000
12178
  className: tw("outline-none")
@@ -12028,22 +12206,22 @@ var Popover2 = (props) => {
12028
12206
  const triggerRef = useRef8(null);
12029
12207
  const state = useOverlayTriggerState4(props);
12030
12208
  const { triggerProps, overlayProps } = useOverlayTrigger({ type: type != null ? type : "dialog" }, state, triggerRef);
12031
- return /* @__PURE__ */ React76.createElement(PopoverContext.Provider, {
12209
+ return /* @__PURE__ */ React78.createElement(PopoverContext.Provider, {
12032
12210
  value: {
12033
12211
  state
12034
12212
  }
12035
- }, React76.Children.map(props.children, (child) => {
12213
+ }, React78.Children.map(props.children, (child) => {
12036
12214
  if (isComponentType(child, Popover2.Trigger)) {
12037
- return /* @__PURE__ */ React76.createElement(PressResponder2, __spreadValues({
12215
+ return /* @__PURE__ */ React78.createElement(PressResponder2, __spreadValues({
12038
12216
  ref: triggerRef
12039
- }, omit10(triggerProps, "aria-expanded")), /* @__PURE__ */ React76.createElement(PopoverTriggerWrapper, {
12217
+ }, omit10(triggerProps, "aria-expanded")), /* @__PURE__ */ React78.createElement(PopoverTriggerWrapper, {
12040
12218
  "data-testid": props["data-testid"],
12041
12219
  "aria-controls": id,
12042
12220
  "aria-expanded": triggerProps["aria-expanded"]
12043
12221
  }, child.props.children));
12044
12222
  }
12045
12223
  if (isComponentType(child, Popover2.Panel)) {
12046
- return state.isOpen && /* @__PURE__ */ React76.createElement(PopoverOverlay, __spreadValues({
12224
+ return state.isOpen && /* @__PURE__ */ React78.createElement(PopoverOverlay, __spreadValues({
12047
12225
  triggerRef: targetRef != null ? targetRef : triggerRef,
12048
12226
  state,
12049
12227
  placement,
@@ -12054,7 +12232,7 @@ var Popover2 = (props) => {
12054
12232
  offset,
12055
12233
  crossOffset,
12056
12234
  shouldFlip
12057
- }, overlayProps), containFocus ? /* @__PURE__ */ React76.createElement(Dialog2, null, child.props.children) : child.props.children);
12235
+ }, overlayProps), containFocus ? /* @__PURE__ */ React78.createElement(Dialog2, null, child.props.children) : child.props.children);
12058
12236
  }
12059
12237
  throw new Error("Invalid children element type");
12060
12238
  }));
@@ -12073,7 +12251,7 @@ var asPopoverButton = (Component, displayName) => {
12073
12251
  state.close();
12074
12252
  onClick == null ? void 0 : onClick(e);
12075
12253
  };
12076
- return /* @__PURE__ */ React76.createElement(Component, __spreadProps(__spreadValues({}, props), {
12254
+ return /* @__PURE__ */ React78.createElement(Component, __spreadProps(__spreadValues({}, props), {
12077
12255
  onClick: handleClick
12078
12256
  }));
12079
12257
  };
@@ -12086,9 +12264,9 @@ var PopoverTriggerWrapper = (_a) => {
12086
12264
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
12087
12265
  var _a2;
12088
12266
  const ref = useRef8(null);
12089
- const trigger = React76.Children.only(children);
12267
+ const trigger = React78.Children.only(children);
12090
12268
  const { pressProps } = usePress2(__spreadProps(__spreadValues({}, rest), { ref }));
12091
- return React76.cloneElement(trigger, __spreadProps(__spreadValues({
12269
+ return React78.cloneElement(trigger, __spreadProps(__spreadValues({
12092
12270
  "ref": ref
12093
12271
  }, mergeProps3(pressProps, trigger.props)), {
12094
12272
  "aria-controls": (_a2 = rest["aria-controls"]) != null ? _a2 : pressProps["aria-controls"]
@@ -12097,10 +12275,10 @@ var PopoverTriggerWrapper = (_a) => {
12097
12275
 
12098
12276
  // src/molecules/Dropdown/Dropdown.tsx
12099
12277
  var Dropdown = ({ children, content, placement = "bottom-left" }) => {
12100
- return /* @__PURE__ */ React77.createElement(Popover2, {
12278
+ return /* @__PURE__ */ React79.createElement(Popover2, {
12101
12279
  type: "menu",
12102
12280
  placement
12103
- }, /* @__PURE__ */ React77.createElement(Popover2.Trigger, null, children), /* @__PURE__ */ React77.createElement(Popover2.Panel, {
12281
+ }, /* @__PURE__ */ React79.createElement(Popover2.Trigger, null, children), /* @__PURE__ */ React79.createElement(Popover2.Panel, {
12104
12282
  className: "Aquarium-Dropdown"
12105
12283
  }, content));
12106
12284
  };
@@ -12111,26 +12289,26 @@ var DropdownMenu3 = ({
12111
12289
  triggerId,
12112
12290
  setClose = () => void 0
12113
12291
  }) => {
12114
- const menuRef = React77.useRef(null);
12115
- React77.useEffect(() => {
12292
+ const menuRef = React79.useRef(null);
12293
+ React79.useEffect(() => {
12116
12294
  const id = setTimeout(() => {
12117
12295
  var _a, _b, _c;
12118
12296
  return (_c = (_b = (_a = menuRef.current) == null ? void 0 : _a.children) == null ? void 0 : _b[0]) == null ? void 0 : _c.focus();
12119
12297
  });
12120
12298
  return () => clearTimeout(id);
12121
12299
  }, [menuRef.current]);
12122
- return /* @__PURE__ */ React77.createElement("div", {
12300
+ return /* @__PURE__ */ React79.createElement("div", {
12123
12301
  style: { minWidth: "250px" },
12124
12302
  className: tw("py-3 bg-white")
12125
- }, !!title && /* @__PURE__ */ React77.createElement("div", {
12303
+ }, !!title && /* @__PURE__ */ React79.createElement("div", {
12126
12304
  className: tw("px-4 py-4 text-left text-grey-100 typography-default-strong")
12127
- }, title), /* @__PURE__ */ React77.createElement("ol", {
12305
+ }, title), /* @__PURE__ */ React79.createElement("ol", {
12128
12306
  role: "menu",
12129
12307
  ref: menuRef,
12130
12308
  id: contentId,
12131
12309
  "aria-labelledby": triggerId
12132
- }, React77.Children.map(children, (child) => {
12133
- return React77.cloneElement(child, { setClose });
12310
+ }, React79.Children.map(children, (child) => {
12311
+ return React79.cloneElement(child, { setClose });
12134
12312
  })));
12135
12313
  };
12136
12314
  var DropdownItem = (_a) => {
@@ -12185,10 +12363,10 @@ var DropdownItem = (_a) => {
12185
12363
  handleSelect();
12186
12364
  }
12187
12365
  };
12188
- const itemContent = /* @__PURE__ */ React77.createElement("div", {
12366
+ const itemContent = /* @__PURE__ */ React79.createElement("div", {
12189
12367
  className: tw("py-3 px-4")
12190
12368
  }, children);
12191
- return /* @__PURE__ */ React77.createElement("li", __spreadProps(__spreadValues({
12369
+ return /* @__PURE__ */ React79.createElement("li", __spreadProps(__spreadValues({
12192
12370
  role: "menuitem",
12193
12371
  tabIndex: -1,
12194
12372
  onClick: handleClick,
@@ -12199,11 +12377,11 @@ var DropdownItem = (_a) => {
12199
12377
  "text-grey-10 cursor-not-allowed": disabled,
12200
12378
  "text-primary-70 hover:text-primary-80": color === "danger" && !disabled
12201
12379
  })
12202
- }), tooltip ? /* @__PURE__ */ React77.createElement(Tooltip, {
12380
+ }), tooltip ? /* @__PURE__ */ React79.createElement(Tooltip, {
12203
12381
  content: tooltip,
12204
12382
  placement: tooltipPlacement,
12205
12383
  inline: false
12206
- }, /* @__PURE__ */ React77.createElement("div", {
12384
+ }, /* @__PURE__ */ React79.createElement("div", {
12207
12385
  tabIndex: 0,
12208
12386
  className: tw("grow")
12209
12387
  }, itemContent)) : itemContent);
@@ -12212,7 +12390,7 @@ Dropdown.Menu = DropdownMenu3;
12212
12390
  Dropdown.Item = DropdownItem;
12213
12391
 
12214
12392
  // src/molecules/EmptyState/EmptyState.tsx
12215
- import React78 from "react";
12393
+ import React80 from "react";
12216
12394
  var EmptyStateLayout = /* @__PURE__ */ ((EmptyStateLayout2) => {
12217
12395
  EmptyStateLayout2["Vertical"] = "vertical";
12218
12396
  EmptyStateLayout2["Horizontal"] = "horizontal";
@@ -12269,7 +12447,7 @@ var EmptyState = ({
12269
12447
  fullHeight = isVerticalLayout(layout) ? true : false
12270
12448
  }) => {
12271
12449
  const template = layoutStyle(layout);
12272
- return /* @__PURE__ */ React78.createElement(Box, {
12450
+ return /* @__PURE__ */ React80.createElement(Box, {
12273
12451
  className: classNames(
12274
12452
  "Aquarium-EmptyState",
12275
12453
  tw("rounded p-[56px]", {
@@ -12282,39 +12460,39 @@ var EmptyState = ({
12282
12460
  ),
12283
12461
  backgroundColor: "transparent",
12284
12462
  borderColor: "grey-10"
12285
- }, /* @__PURE__ */ React78.createElement(Box.Flex, {
12463
+ }, /* @__PURE__ */ React80.createElement(Box.Flex, {
12286
12464
  style: { gap: "56px" },
12287
12465
  flexDirection: template.layout,
12288
12466
  justifyContent: template.justifyContent,
12289
12467
  alignItems: template.layout === "row" ? "center" : template.alignItems,
12290
12468
  height: fullHeight ? "full" : void 0
12291
- }, image && /* @__PURE__ */ React78.createElement("img", {
12469
+ }, image && /* @__PURE__ */ React80.createElement("img", {
12292
12470
  src: image,
12293
12471
  alt: imageAlt,
12294
12472
  style: { width: imageWidth ? `${imageWidth}px` : void 0, height: "auto" }
12295
- }), /* @__PURE__ */ React78.createElement(Box.Flex, {
12473
+ }), /* @__PURE__ */ React80.createElement(Box.Flex, {
12296
12474
  flexDirection: "column",
12297
12475
  justifyContent: template.justifyContent,
12298
12476
  alignItems: template.alignItems
12299
- }, /* @__PURE__ */ React78.createElement(Typography2.Heading, {
12477
+ }, /* @__PURE__ */ React80.createElement(Typography2.Heading, {
12300
12478
  htmlTag: "h2"
12301
- }, title), (description || children) && /* @__PURE__ */ React78.createElement(Box, {
12479
+ }, title), (description || children) && /* @__PURE__ */ React80.createElement(Box, {
12302
12480
  marginTop: "5"
12303
- }, /* @__PURE__ */ React78.createElement(Typography2.Default, null, children || description)), (secondaryAction || primaryAction) && /* @__PURE__ */ React78.createElement(Box.Flex, {
12481
+ }, /* @__PURE__ */ React80.createElement(Typography2.Default, null, children || description)), (secondaryAction || primaryAction) && /* @__PURE__ */ React80.createElement(Box.Flex, {
12304
12482
  marginTop: "7",
12305
12483
  gap: "4",
12306
12484
  justifyContent: "center",
12307
12485
  alignItems: "center",
12308
12486
  flexWrap: "wrap"
12309
- }, primaryAction && renderAction({ kind: "primary", action: primaryAction }), secondaryAction && renderAction({ kind: "secondary", action: secondaryAction })), footer && /* @__PURE__ */ React78.createElement(Box, {
12487
+ }, primaryAction && renderAction({ kind: "primary", action: primaryAction }), secondaryAction && renderAction({ kind: "secondary", action: secondaryAction })), footer && /* @__PURE__ */ React80.createElement(Box, {
12310
12488
  marginTop: "5"
12311
- }, /* @__PURE__ */ React78.createElement(Typography2.Small, {
12489
+ }, /* @__PURE__ */ React80.createElement(Typography2.Small, {
12312
12490
  color: "grey-60"
12313
12491
  }, footer)))));
12314
12492
  };
12315
12493
 
12316
12494
  // src/molecules/Flexbox/FlexboxItem.tsx
12317
- import React79 from "react";
12495
+ import React81 from "react";
12318
12496
  var FlexboxItem = Tailwindify(
12319
12497
  ({ htmlTag = "div", className, style, children, display, flex, grow, shrink, order, alignSelf }) => {
12320
12498
  const hookStyle = useStyle({
@@ -12326,7 +12504,7 @@ var FlexboxItem = Tailwindify(
12326
12504
  alignSelf
12327
12505
  });
12328
12506
  const HtmlElement = htmlTag;
12329
- return /* @__PURE__ */ React79.createElement(HtmlElement, {
12507
+ return /* @__PURE__ */ React81.createElement(HtmlElement, {
12330
12508
  style: __spreadValues(__spreadValues({}, hookStyle), style),
12331
12509
  className
12332
12510
  }, children);
@@ -12334,7 +12512,7 @@ var FlexboxItem = Tailwindify(
12334
12512
  );
12335
12513
 
12336
12514
  // src/molecules/Grid/GridItem.tsx
12337
- import React80 from "react";
12515
+ import React82 from "react";
12338
12516
  var GridItem2 = Tailwindify(
12339
12517
  ({
12340
12518
  htmlTag = "div",
@@ -12365,7 +12543,7 @@ var GridItem2 = Tailwindify(
12365
12543
  gridRowEnd: rowEnd
12366
12544
  });
12367
12545
  const HtmlElement = htmlTag;
12368
- return /* @__PURE__ */ React80.createElement(HtmlElement, {
12546
+ return /* @__PURE__ */ React82.createElement(HtmlElement, {
12369
12547
  style: __spreadValues(__spreadValues({}, hookStyle), style),
12370
12548
  className
12371
12549
  }, children);
@@ -12373,7 +12551,7 @@ var GridItem2 = Tailwindify(
12373
12551
  );
12374
12552
 
12375
12553
  // src/molecules/LineClamp/LineClamp.tsx
12376
- import React81 from "react";
12554
+ import React83 from "react";
12377
12555
  var LineClamp2 = ({
12378
12556
  lines,
12379
12557
  children,
@@ -12382,10 +12560,10 @@ var LineClamp2 = ({
12382
12560
  collapseLabel,
12383
12561
  onClampedChange
12384
12562
  }) => {
12385
- const ref = React81.useRef(null);
12386
- const [clamped, setClamped] = React81.useState(true);
12387
- const [isClampingEnabled, setClampingEnabled] = React81.useState(false);
12388
- React81.useEffect(() => {
12563
+ const ref = React83.useRef(null);
12564
+ const [clamped, setClamped] = React83.useState(true);
12565
+ const [isClampingEnabled, setClampingEnabled] = React83.useState(false);
12566
+ React83.useEffect(() => {
12389
12567
  var _a, _b;
12390
12568
  const el = ref.current;
12391
12569
  setClampingEnabled(((_a = el == null ? void 0 : el.scrollHeight) != null ? _a : 0) > ((_b = el == null ? void 0 : el.clientHeight) != null ? _b : 0));
@@ -12394,28 +12572,28 @@ var LineClamp2 = ({
12394
12572
  setClamped(!clamped);
12395
12573
  onClampedChange == null ? void 0 : onClampedChange(!clamped);
12396
12574
  };
12397
- return /* @__PURE__ */ React81.createElement("div", {
12575
+ return /* @__PURE__ */ React83.createElement("div", {
12398
12576
  className: "Aquarium-LineClamp"
12399
- }, /* @__PURE__ */ React81.createElement(LineClamp, {
12577
+ }, /* @__PURE__ */ React83.createElement(LineClamp, {
12400
12578
  ref,
12401
12579
  lines,
12402
12580
  clamped,
12403
12581
  wordBreak
12404
- }, children), expandLabel && isClampingEnabled && /* @__PURE__ */ React81.createElement(Button.Ghost, {
12582
+ }, children), expandLabel && isClampingEnabled && /* @__PURE__ */ React83.createElement(Button.Ghost, {
12405
12583
  dense: true,
12406
12584
  onClick: handleClampedChange
12407
12585
  }, clamped ? expandLabel : collapseLabel));
12408
12586
  };
12409
12587
 
12410
12588
  // src/molecules/Link/Link.tsx
12411
- import React83 from "react";
12589
+ import React85 from "react";
12412
12590
  import classNames9 from "classnames";
12413
12591
 
12414
12592
  // src/atoms/Link/Link.tsx
12415
- import React82 from "react";
12593
+ import React84 from "react";
12416
12594
  var Link = (_a) => {
12417
12595
  var _b = _a, { children, className } = _b, props = __objRest(_b, ["children", "className"]);
12418
- return /* @__PURE__ */ React82.createElement("a", __spreadValues({
12596
+ return /* @__PURE__ */ React84.createElement("a", __spreadValues({
12419
12597
  className: classNames(className, linkStyle)
12420
12598
  }, props), children);
12421
12599
  };
@@ -12423,27 +12601,27 @@ var Link = (_a) => {
12423
12601
  // src/molecules/Link/Link.tsx
12424
12602
  var Link2 = (_a) => {
12425
12603
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
12426
- return /* @__PURE__ */ React83.createElement(Link, __spreadValues({
12604
+ return /* @__PURE__ */ React85.createElement(Link, __spreadValues({
12427
12605
  className: classNames9("Aquarium-Link", className)
12428
12606
  }, props));
12429
12607
  };
12430
12608
 
12431
12609
  // src/molecules/List/useStaticInfiniteList.ts
12432
- import React84 from "react";
12610
+ import React86 from "react";
12433
12611
  var useStaticInfiniteList = ({
12434
12612
  items,
12435
12613
  pageSize,
12436
12614
  autoReset = true
12437
12615
  }) => {
12438
- const [currentPage, setCurrentPage] = React84.useState(1);
12616
+ const [currentPage, setCurrentPage] = React86.useState(1);
12439
12617
  const numberOfVisible = currentPage * pageSize;
12440
- const next = React84.useCallback(() => {
12618
+ const next = React86.useCallback(() => {
12441
12619
  setCurrentPage((page) => page + 1);
12442
12620
  }, [setCurrentPage]);
12443
- const reset = React84.useCallback(() => {
12621
+ const reset = React86.useCallback(() => {
12444
12622
  setCurrentPage(1);
12445
12623
  }, [setCurrentPage]);
12446
- React84.useEffect(() => {
12624
+ React86.useEffect(() => {
12447
12625
  if (autoReset) {
12448
12626
  setCurrentPage(1);
12449
12627
  }
@@ -12458,17 +12636,17 @@ var useStaticInfiniteList = ({
12458
12636
  };
12459
12637
 
12460
12638
  // src/molecules/ListItem/ListItem.tsx
12461
- import React85 from "react";
12639
+ import React87 from "react";
12462
12640
  var ListItem = ({ name, icon, active = false }) => {
12463
- return /* @__PURE__ */ React85.createElement(Box.Flex, {
12641
+ return /* @__PURE__ */ React87.createElement(Box.Flex, {
12464
12642
  className: "Aquarium-ListItem",
12465
12643
  alignItems: "center"
12466
- }, /* @__PURE__ */ React85.createElement(Typography2, {
12644
+ }, /* @__PURE__ */ React87.createElement(Typography2, {
12467
12645
  variant: active ? "small-strong" : "small",
12468
12646
  color: "grey-70",
12469
12647
  htmlTag: "span",
12470
12648
  className: `px-4 py-2 rounded-full ${active ? "bg-grey-5" : "hover:bg-grey-0"}`
12471
- }, /* @__PURE__ */ React85.createElement("img", {
12649
+ }, /* @__PURE__ */ React87.createElement("img", {
12472
12650
  src: icon,
12473
12651
  alt: "",
12474
12652
  className: "inline mr-4",
@@ -12478,7 +12656,7 @@ var ListItem = ({ name, icon, active = false }) => {
12478
12656
  };
12479
12657
 
12480
12658
  // src/molecules/Modal/Modal.tsx
12481
- import React86 from "react";
12659
+ import React88 from "react";
12482
12660
  import { useDialog as useDialog4 } from "@react-aria/dialog";
12483
12661
  import { Overlay as Overlay4, useModalOverlay as useModalOverlay3 } from "@react-aria/overlays";
12484
12662
  import { useId as useId10 } from "@react-aria/utils";
@@ -12489,7 +12667,7 @@ var import_cross7 = __toESM(require_cross());
12489
12667
  var Modal2 = (_a) => {
12490
12668
  var _b = _a, { closeOnEsc = true } = _b, props = __objRest(_b, ["closeOnEsc"]);
12491
12669
  const { open, onClose, size, portalContainer } = props;
12492
- const ref = React86.useRef(null);
12670
+ const ref = React88.useRef(null);
12493
12671
  const state = useOverlayTriggerState5({ isOpen: open, onOpenChange: (isOpen) => !isOpen && onClose() });
12494
12672
  const { modalProps, underlayProps } = useModalOverlay3(
12495
12673
  { isDismissable: false, isKeyboardDismissDisabled: !closeOnEsc },
@@ -12499,17 +12677,17 @@ var Modal2 = (_a) => {
12499
12677
  if (!state.isOpen) {
12500
12678
  return null;
12501
12679
  }
12502
- return /* @__PURE__ */ React86.createElement(Overlay4, {
12680
+ return /* @__PURE__ */ React88.createElement(Overlay4, {
12503
12681
  portalContainer
12504
- }, /* @__PURE__ */ React86.createElement(Modal, {
12682
+ }, /* @__PURE__ */ React88.createElement(Modal, {
12505
12683
  className: "Aquarium-Modal",
12506
12684
  open: true
12507
- }, /* @__PURE__ */ React86.createElement(Modal.BackDrop, __spreadValues({}, underlayProps)), /* @__PURE__ */ React86.createElement(ModalWrapper, __spreadValues(__spreadValues({
12685
+ }, /* @__PURE__ */ React88.createElement(Modal.BackDrop, __spreadValues({}, underlayProps)), /* @__PURE__ */ React88.createElement(ModalWrapper, __spreadValues(__spreadValues({
12508
12686
  ref,
12509
12687
  size
12510
12688
  }, props), modalProps))));
12511
12689
  };
12512
- var ModalWrapper = React86.forwardRef(
12690
+ var ModalWrapper = React88.forwardRef(
12513
12691
  (_a, ref) => {
12514
12692
  var _b = _a, { title, subtitle, headerImage, primaryAction, secondaryActions, children, onClose } = _b, props = __objRest(_b, ["title", "subtitle", "headerImage", "primaryAction", "secondaryActions", "children", "onClose"]);
12515
12693
  const labelledBy = useId10();
@@ -12518,30 +12696,30 @@ var ModalWrapper = React86.forwardRef(
12518
12696
  { "role": "dialog", "aria-labelledby": labelledBy, "aria-describedby": describedBy },
12519
12697
  ref
12520
12698
  );
12521
- return /* @__PURE__ */ React86.createElement(Modal.Dialog, __spreadProps(__spreadValues(__spreadValues({
12699
+ return /* @__PURE__ */ React88.createElement(Modal.Dialog, __spreadProps(__spreadValues(__spreadValues({
12522
12700
  ref
12523
12701
  }, props), dialogProps), {
12524
12702
  tabIndex: -1
12525
- }), /* @__PURE__ */ React86.createElement(Modal.CloseButtonContainer, null, /* @__PURE__ */ React86.createElement(IconButton, {
12703
+ }), /* @__PURE__ */ React88.createElement(Modal.CloseButtonContainer, null, /* @__PURE__ */ React88.createElement(IconButton, {
12526
12704
  "aria-label": "Close",
12527
12705
  icon: import_cross7.default,
12528
12706
  onClick: onClose
12529
- })), headerImage !== void 0 && /* @__PURE__ */ React86.createElement(Modal.HeaderImage, {
12707
+ })), headerImage !== void 0 && /* @__PURE__ */ React88.createElement(Modal.HeaderImage, {
12530
12708
  backgroundImage: headerImage
12531
- }), /* @__PURE__ */ React86.createElement(Modal.Header, {
12709
+ }), /* @__PURE__ */ React88.createElement(Modal.Header, {
12532
12710
  className: tw({ "pb-3": isComponentType(children, ModalTabs) })
12533
- }, /* @__PURE__ */ React86.createElement(Modal.TitleContainer, null, /* @__PURE__ */ React86.createElement(Modal.Title, {
12711
+ }, /* @__PURE__ */ React88.createElement(Modal.TitleContainer, null, /* @__PURE__ */ React88.createElement(Modal.Title, {
12534
12712
  id: labelledBy
12535
- }, title), subtitle && /* @__PURE__ */ React86.createElement(Modal.Subtitle, null, subtitle))), isComponentType(children, ModalTabs) ? React86.cloneElement(children, { className: tw("[&>div:first-child]:px-5 grow") }) : /* @__PURE__ */ React86.createElement(Modal.Body, {
12713
+ }, title), subtitle && /* @__PURE__ */ React88.createElement(Modal.Subtitle, null, subtitle))), isComponentType(children, ModalTabs) ? React88.cloneElement(children, { className: tw("[&>div:first-child]:px-5 grow") }) : /* @__PURE__ */ React88.createElement(Modal.Body, {
12536
12714
  id: describedBy,
12537
12715
  tabIndex: 0,
12538
12716
  noFooter: !(secondaryActions || primaryAction)
12539
- }, children), (secondaryActions || primaryAction) && /* @__PURE__ */ React86.createElement(Modal.Footer, null, /* @__PURE__ */ React86.createElement(Modal.Actions, null, secondaryActions && castArray2(secondaryActions).filter(Boolean).map((_a2) => {
12717
+ }, children), (secondaryActions || primaryAction) && /* @__PURE__ */ React88.createElement(Modal.Footer, null, /* @__PURE__ */ React88.createElement(Modal.Actions, null, secondaryActions && castArray2(secondaryActions).filter(Boolean).map((_a2) => {
12540
12718
  var _b2 = _a2, { text } = _b2, action = __objRest(_b2, ["text"]);
12541
- return /* @__PURE__ */ React86.createElement(Button.Secondary, __spreadValues({
12719
+ return /* @__PURE__ */ React88.createElement(Button.Secondary, __spreadValues({
12542
12720
  key: text
12543
12721
  }, action), text);
12544
- }), primaryAction && /* @__PURE__ */ React86.createElement(Button.Primary, __spreadValues({
12722
+ }), primaryAction && /* @__PURE__ */ React88.createElement(Button.Primary, __spreadValues({
12545
12723
  key: primaryAction.text
12546
12724
  }, omit11(primaryAction, "text")), primaryAction.text))));
12547
12725
  }
@@ -12550,24 +12728,24 @@ var ModalTabs = createTabsComponent(
12550
12728
  ModalTab,
12551
12729
  TabItem,
12552
12730
  "ModalTabs",
12553
- (children, selected, props) => /* @__PURE__ */ React86.createElement(Modal.Body, {
12731
+ (children, selected, props) => /* @__PURE__ */ React88.createElement(Modal.Body, {
12554
12732
  maxHeight: props.maxHeight
12555
- }, /* @__PURE__ */ React86.createElement(ModalTabContainer, null, children.find(
12733
+ }, /* @__PURE__ */ React88.createElement(ModalTabContainer, null, children.find(
12556
12734
  (node, index) => (node == null ? void 0 : node.props.value) === selected || index === selected
12557
12735
  )))
12558
12736
  );
12559
12737
 
12560
12738
  // src/molecules/MultiInput/MultiInput.tsx
12561
- import React88, { useEffect as useEffect11, useRef as useRef9, useState as useState11 } from "react";
12739
+ import React90, { useEffect as useEffect11, useRef as useRef9, useState as useState11 } from "react";
12562
12740
  import { useId as useId11 } from "@react-aria/utils";
12563
12741
  import castArray3 from "lodash/castArray";
12564
12742
  import identity from "lodash/identity";
12565
12743
  import omit12 from "lodash/omit";
12566
12744
 
12567
12745
  // src/molecules/MultiInput/InputChip.tsx
12568
- import React87 from "react";
12746
+ import React89 from "react";
12569
12747
  var import_smallCross2 = __toESM(require_smallCross());
12570
- var InputChip = React87.forwardRef(
12748
+ var InputChip = React89.forwardRef(
12571
12749
  (_a, ref) => {
12572
12750
  var _b = _a, { invalid = false, disabled, readOnly, className, onClick: _onClick, children } = _b, props = __objRest(_b, ["invalid", "disabled", "readOnly", "className", "onClick", "children"]);
12573
12751
  const onClick = (e) => {
@@ -12575,18 +12753,18 @@ var InputChip = React87.forwardRef(
12575
12753
  _onClick == null ? void 0 : _onClick(e);
12576
12754
  }
12577
12755
  };
12578
- return /* @__PURE__ */ React87.createElement("div", {
12756
+ return /* @__PURE__ */ React89.createElement("div", {
12579
12757
  className: classNames(className, "inline-flex align-middle mx-1 items-stretch rounded-sm break-all", {
12580
12758
  "bg-error-0 ": invalid,
12581
12759
  "bg-grey-0 ": !invalid && !disabled,
12582
12760
  "bg-grey-5": disabled
12583
12761
  })
12584
- }, /* @__PURE__ */ React87.createElement("div", {
12762
+ }, /* @__PURE__ */ React89.createElement("div", {
12585
12763
  className: tw("px-2 py-1")
12586
- }, /* @__PURE__ */ React87.createElement(Typography2, {
12764
+ }, /* @__PURE__ */ React89.createElement(Typography2, {
12587
12765
  variant: "small",
12588
12766
  color: invalid ? "error-80" : disabled ? "grey-40" : "grey-70"
12589
- }, children)), !readOnly && /* @__PURE__ */ React87.createElement("div", __spreadProps(__spreadValues({
12767
+ }, children)), !readOnly && /* @__PURE__ */ React89.createElement("div", __spreadProps(__spreadValues({
12590
12768
  ref
12591
12769
  }, props), {
12592
12770
  onClick,
@@ -12597,7 +12775,7 @@ var InputChip = React87.forwardRef(
12597
12775
  }),
12598
12776
  role: "button",
12599
12777
  "aria-label": `Remove ${String(children)}`
12600
- }), /* @__PURE__ */ React87.createElement(Icon, {
12778
+ }), /* @__PURE__ */ React89.createElement(Icon, {
12601
12779
  icon: import_smallCross2.default,
12602
12780
  className: tw({
12603
12781
  "text-error-70": invalid,
@@ -12738,7 +12916,7 @@ var MultiInputBase = (_a) => {
12738
12916
  };
12739
12917
  const renderChips = () => items == null ? void 0 : items.map((item, index) => {
12740
12918
  var _a3;
12741
- return /* @__PURE__ */ React88.createElement(InputChip, {
12919
+ return /* @__PURE__ */ React90.createElement(InputChip, {
12742
12920
  key: `${itemToString(item)}.${index}`,
12743
12921
  invalid: !((_a3 = isItemValid == null ? void 0 : isItemValid(item, index)) != null ? _a3 : true),
12744
12922
  readOnly,
@@ -12749,13 +12927,13 @@ var MultiInputBase = (_a) => {
12749
12927
  }
12750
12928
  }, itemToString(item));
12751
12929
  });
12752
- return /* @__PURE__ */ React88.createElement("div", {
12930
+ return /* @__PURE__ */ React90.createElement("div", {
12753
12931
  className: "Aquarium-MultiInputBase"
12754
- }, /* @__PURE__ */ React88.createElement(Select.InputContainer, {
12932
+ }, /* @__PURE__ */ React90.createElement(Select.InputContainer, {
12755
12933
  variant: disabled ? "disabled" : !valid ? "error" : readOnly ? "readOnly" : hasFocus ? "focused" : "default"
12756
- }, /* @__PURE__ */ React88.createElement("div", {
12934
+ }, /* @__PURE__ */ React90.createElement("div", {
12757
12935
  className: "grow inline-flex flex-row flex-wrap gap-y-2"
12758
- }, inline && renderChips(), /* @__PURE__ */ React88.createElement(Select.Input, __spreadProps(__spreadValues({
12936
+ }, inline && renderChips(), /* @__PURE__ */ React90.createElement(Select.Input, __spreadProps(__spreadValues({
12759
12937
  ref: inputRef,
12760
12938
  id: id != null ? id : name,
12761
12939
  name,
@@ -12773,11 +12951,11 @@ var MultiInputBase = (_a) => {
12773
12951
  onFocus: handleFocus,
12774
12952
  onBlur: handleBlur,
12775
12953
  autoComplete: "off"
12776
- }))), endAdornment && /* @__PURE__ */ React88.createElement(InputAdornment, null, endAdornment)), !inline && /* @__PURE__ */ React88.createElement("div", {
12954
+ }))), endAdornment && /* @__PURE__ */ React90.createElement(InputAdornment, null, endAdornment)), !inline && /* @__PURE__ */ React90.createElement("div", {
12777
12955
  className: tw("flex flex-row flex-wrap gap-y-2 mt-2")
12778
12956
  }, renderChips()));
12779
12957
  };
12780
- var BaseMultiInputSkeleton = () => /* @__PURE__ */ React88.createElement(Skeleton, {
12958
+ var BaseMultiInputSkeleton = () => /* @__PURE__ */ React90.createElement(Skeleton, {
12781
12959
  height: 38
12782
12960
  });
12783
12961
  MultiInputBase.Skeleton = BaseMultiInputSkeleton;
@@ -12795,7 +12973,7 @@ var MultiInput = (props) => {
12795
12973
  const errorProps = props.valid === false ? { "aria-invalid": true, "aria-describedby": errorMessageId } : {};
12796
12974
  const labelControlProps = getLabelControlProps(props);
12797
12975
  const baseProps = omit12(props, Object.keys(labelControlProps));
12798
- return /* @__PURE__ */ React88.createElement(LabelControl, __spreadProps(__spreadValues({
12976
+ return /* @__PURE__ */ React90.createElement(LabelControl, __spreadProps(__spreadValues({
12799
12977
  id: `${id}-label`,
12800
12978
  htmlFor: `${id}-input`,
12801
12979
  messageId: errorMessageId
@@ -12803,7 +12981,7 @@ var MultiInput = (props) => {
12803
12981
  length: value.length,
12804
12982
  maxLength,
12805
12983
  className: "Aquarium-MultiInput"
12806
- }), /* @__PURE__ */ React88.createElement(MultiInputBase, __spreadProps(__spreadValues(__spreadValues({}, baseProps), errorProps), {
12984
+ }), /* @__PURE__ */ React90.createElement(MultiInputBase, __spreadProps(__spreadValues(__spreadValues({}, baseProps), errorProps), {
12807
12985
  id: `${id}-input`,
12808
12986
  onChange: (value2) => {
12809
12987
  var _a2;
@@ -12815,16 +12993,16 @@ var MultiInput = (props) => {
12815
12993
  valid: props.valid
12816
12994
  })));
12817
12995
  };
12818
- var MultiInputSkeleton = () => /* @__PURE__ */ React88.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React88.createElement(MultiInputBase.Skeleton, null));
12996
+ var MultiInputSkeleton = () => /* @__PURE__ */ React90.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React90.createElement(MultiInputBase.Skeleton, null));
12819
12997
  MultiInput.Skeleton = MultiInputSkeleton;
12820
12998
  MultiInput.Skeleton.displayName = "MultiInput.Skeleton";
12821
12999
 
12822
13000
  // src/molecules/MultiSelect/MultiSelect.tsx
12823
- import React89, { useEffect as useEffect12, useRef as useRef10, useState as useState12 } from "react";
13001
+ import React91, { useEffect as useEffect12, useRef as useRef10, useState as useState12 } from "react";
12824
13002
  import { ariaHideOutside as ariaHideOutside2 } from "@react-aria/overlays";
12825
13003
  import { useId as useId12 } from "@react-aria/utils";
12826
13004
  import { useCombobox as useCombobox2, useMultipleSelection } from "downshift";
12827
- import isArray2 from "lodash/isArray";
13005
+ import isArray4 from "lodash/isArray";
12828
13006
  import isEqual from "lodash/isEqual";
12829
13007
  import isNil2 from "lodash/isNil";
12830
13008
  import isObject2 from "lodash/isObject";
@@ -12832,7 +13010,7 @@ import omit13 from "lodash/omit";
12832
13010
  import omitBy from "lodash/omitBy";
12833
13011
  import { matchSorter as matchSorter2 } from "match-sorter";
12834
13012
  var isOptionGroup = (option) => {
12835
- return isObject2(option) && "options" in option && isArray2(option.options);
13013
+ return isObject2(option) && "options" in option && isArray4(option.options);
12836
13014
  };
12837
13015
  var hasOptionGroups2 = (options) => {
12838
13016
  return options.some(isOptionGroup);
@@ -12980,16 +13158,16 @@ var MultiSelectBase = (_a) => {
12980
13158
  return ariaHideOutside2([inputRef.current, popoverRef.current]);
12981
13159
  }
12982
13160
  }, [state.isOpen, inputRef, popoverRef]);
12983
- const renderItem = (item, index) => /* @__PURE__ */ React89.createElement(Select.Item, __spreadValues({
13161
+ const renderItem = (item, index) => /* @__PURE__ */ React91.createElement(Select.Item, __spreadValues({
12984
13162
  key: itemToString(item),
12985
13163
  highlighted: index === highlightedIndex,
12986
13164
  selected: selectedItems.includes(item)
12987
13165
  }, getItemProps({ item, index })), renderOption(item));
12988
- const renderGroup = (group) => group.options.length ? /* @__PURE__ */ React89.createElement(React89.Fragment, {
13166
+ const renderGroup = (group) => group.options.length ? /* @__PURE__ */ React91.createElement(React91.Fragment, {
12989
13167
  key: group.label
12990
- }, /* @__PURE__ */ React89.createElement(Select.Group, null, group.label), group.options.map((opt) => renderItem(opt, flattenedOptions.indexOf(opt)))) : null;
13168
+ }, /* @__PURE__ */ React91.createElement(Select.Group, null, group.label), group.options.map((opt) => renderItem(opt, flattenedOptions.indexOf(opt)))) : null;
12991
13169
  const renderChips = () => {
12992
- return selectedItems.map((selectedItem, index) => /* @__PURE__ */ React89.createElement(InputChip, __spreadProps(__spreadValues({
13170
+ return selectedItems.map((selectedItem, index) => /* @__PURE__ */ React91.createElement(InputChip, __spreadProps(__spreadValues({
12993
13171
  key: `${itemToString(selectedItem)}.chip`,
12994
13172
  className: tw("mx-0"),
12995
13173
  disabled,
@@ -13007,14 +13185,14 @@ var MultiSelectBase = (_a) => {
13007
13185
  getDropdownProps({ ref: inputRef, disabled: disabled || readOnly, value: inputValue })
13008
13186
  );
13009
13187
  const menuProps = getMenuProps({ ref: menuRef }, { suppressRefError: !isOpen });
13010
- return /* @__PURE__ */ React89.createElement("div", {
13188
+ return /* @__PURE__ */ React91.createElement("div", {
13011
13189
  className: classNames("Aquarium-MultiSelectBase", tw("relative"))
13012
- }, /* @__PURE__ */ React89.createElement(Select.InputContainer, {
13190
+ }, /* @__PURE__ */ React91.createElement(Select.InputContainer, {
13013
13191
  ref: targetRef,
13014
13192
  variant: disabled ? "disabled" : !valid ? "error" : readOnly ? "readOnly" : hasFocus ? "focused" : "default"
13015
- }, /* @__PURE__ */ React89.createElement("div", {
13193
+ }, /* @__PURE__ */ React91.createElement("div", {
13016
13194
  className: "grow inline-flex flex-row flex-wrap gap-2"
13017
- }, !hideChips && inline && renderChips(), /* @__PURE__ */ React89.createElement(Select.Input, __spreadProps(__spreadValues(__spreadValues({
13195
+ }, !hideChips && inline && renderChips(), /* @__PURE__ */ React91.createElement(Select.Input, __spreadProps(__spreadValues(__spreadValues({
13018
13196
  name,
13019
13197
  placeholder: selectedItems.length === 0 && !readOnly ? placeholder : ""
13020
13198
  }, inputProps), props), {
@@ -13033,12 +13211,12 @@ var MultiSelectBase = (_a) => {
13033
13211
  setFocus(false);
13034
13212
  (_a3 = inputProps.onBlur) == null ? void 0 : _a3.call(inputProps, e);
13035
13213
  }
13036
- }))), !readOnly && /* @__PURE__ */ React89.createElement(Select.Toggle, __spreadValues({
13214
+ }))), !readOnly && /* @__PURE__ */ React91.createElement(Select.Toggle, __spreadValues({
13037
13215
  hasFocus,
13038
13216
  isOpen
13039
- }, getToggleButtonProps({ disabled })))), !hideChips && !inline && /* @__PURE__ */ React89.createElement("div", {
13217
+ }, getToggleButtonProps({ disabled })))), !hideChips && !inline && /* @__PURE__ */ React91.createElement("div", {
13040
13218
  className: tw("flex flex-row flex-wrap gap-2 mt-2")
13041
- }, renderChips()), isOpen && /* @__PURE__ */ React89.createElement(PopoverOverlay, {
13219
+ }, renderChips()), isOpen && /* @__PURE__ */ React91.createElement(PopoverOverlay, {
13042
13220
  ref: popoverRef,
13043
13221
  triggerRef: targetRef,
13044
13222
  state,
@@ -13046,13 +13224,13 @@ var MultiSelectBase = (_a) => {
13046
13224
  shouldFlip: true,
13047
13225
  isNonModal: true,
13048
13226
  style: { width: (_a2 = targetRef.current) == null ? void 0 : _a2.offsetWidth }
13049
- }, /* @__PURE__ */ React89.createElement(Select.Menu, __spreadValues({
13227
+ }, /* @__PURE__ */ React91.createElement(Select.Menu, __spreadValues({
13050
13228
  maxHeight
13051
- }, menuProps), hasNoResults && /* @__PURE__ */ React89.createElement(Select.NoResults, null, emptyState), filteredOptions.map(
13229
+ }, menuProps), hasNoResults && /* @__PURE__ */ React91.createElement(Select.NoResults, null, emptyState), filteredOptions.map(
13052
13230
  (option, index) => isOptionGroup(option) ? renderGroup(option) : renderItem(option, index)
13053
13231
  ))));
13054
13232
  };
13055
- var MultiSelectBaseSkeleton = () => /* @__PURE__ */ React89.createElement(Skeleton, {
13233
+ var MultiSelectBaseSkeleton = () => /* @__PURE__ */ React91.createElement(Skeleton, {
13056
13234
  height: 38
13057
13235
  });
13058
13236
  MultiSelectBase.Skeleton = MultiSelectBaseSkeleton;
@@ -13073,13 +13251,13 @@ var MultiSelect = (_a) => {
13073
13251
  const errorProps = props.valid === false ? { "aria-invalid": true, "aria-describedby": errorMessageId } : {};
13074
13252
  const labelControlProps = getLabelControlProps(props);
13075
13253
  const baseProps = omit13(props, Object.keys(labelControlProps));
13076
- return /* @__PURE__ */ React89.createElement(LabelControl, __spreadProps(__spreadValues({
13254
+ return /* @__PURE__ */ React91.createElement(LabelControl, __spreadProps(__spreadValues({
13077
13255
  id: `${id}-label`,
13078
13256
  htmlFor: `${id}-input`,
13079
13257
  messageId: errorMessageId
13080
13258
  }, labelControlProps), {
13081
13259
  className: "Aquarium-MultiSelect"
13082
- }), /* @__PURE__ */ React89.createElement(MultiSelectBase, __spreadProps(__spreadValues(__spreadValues({}, baseProps), errorProps), {
13260
+ }), /* @__PURE__ */ React91.createElement(MultiSelectBase, __spreadProps(__spreadValues(__spreadValues({}, baseProps), errorProps), {
13083
13261
  id,
13084
13262
  options,
13085
13263
  emptyState,
@@ -13087,17 +13265,17 @@ var MultiSelect = (_a) => {
13087
13265
  valid: props.valid
13088
13266
  })));
13089
13267
  };
13090
- var MultiSelectSkeleton = () => /* @__PURE__ */ React89.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React89.createElement(MultiSelectBase.Skeleton, null));
13268
+ var MultiSelectSkeleton = () => /* @__PURE__ */ React91.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React91.createElement(MultiSelectBase.Skeleton, null));
13091
13269
  MultiSelect.Skeleton = MultiSelectSkeleton;
13092
13270
  MultiSelect.Skeleton.displayName = "MultiSelect.Skeleton";
13093
13271
 
13094
13272
  // src/molecules/NativeSelect/NativeSelect.tsx
13095
- import React90 from "react";
13273
+ import React92 from "react";
13096
13274
  import { useId as useId13 } from "@react-aria/utils";
13097
13275
  import omit14 from "lodash/omit";
13098
13276
  import uniqueId from "lodash/uniqueId";
13099
13277
  var import_caretDown2 = __toESM(require_caretDown());
13100
- var NativeSelectBase = React90.forwardRef(
13278
+ var NativeSelectBase = React92.forwardRef(
13101
13279
  (_a, ref) => {
13102
13280
  var _b = _a, { children, disabled = false, required = false, valid = true, readOnly = false } = _b, props = __objRest(_b, ["children", "disabled", "required", "valid", "readOnly"]);
13103
13281
  const placeholderValue = uniqueId("default_value_for_placeholder");
@@ -13114,16 +13292,16 @@ var NativeSelectBase = React90.forwardRef(
13114
13292
  (_b2 = props.onBlur) == null ? void 0 : _b2.call(props, event);
13115
13293
  }
13116
13294
  };
13117
- return /* @__PURE__ */ React90.createElement("span", {
13295
+ return /* @__PURE__ */ React92.createElement("span", {
13118
13296
  className: classNames("Aquarium-NativeSelectBase", tw("relative block"))
13119
- }, !readOnly && /* @__PURE__ */ React90.createElement("span", {
13297
+ }, !readOnly && /* @__PURE__ */ React92.createElement("span", {
13120
13298
  className: tw(
13121
13299
  "absolute right-0 inset-y-0 mr-4 text-grey-40 flex ml-3 pointer-events-none typography-default-strong mt-4"
13122
13300
  )
13123
- }, /* @__PURE__ */ React90.createElement(Icon, {
13301
+ }, /* @__PURE__ */ React92.createElement(Icon, {
13124
13302
  icon: import_caretDown2.default,
13125
13303
  "data-testid": "icon-dropdown"
13126
- })), /* @__PURE__ */ React90.createElement("select", __spreadProps(__spreadValues({
13304
+ })), /* @__PURE__ */ React92.createElement("select", __spreadProps(__spreadValues({
13127
13305
  ref,
13128
13306
  disabled: disabled || readOnly,
13129
13307
  required
@@ -13142,16 +13320,16 @@ var NativeSelectBase = React90.forwardRef(
13142
13320
  ),
13143
13321
  props.className
13144
13322
  )
13145
- }), props.placeholder && /* @__PURE__ */ React90.createElement("option", {
13323
+ }), props.placeholder && /* @__PURE__ */ React92.createElement("option", {
13146
13324
  value: placeholderValue,
13147
13325
  disabled: true
13148
13326
  }, props.placeholder), children));
13149
13327
  }
13150
13328
  );
13151
- NativeSelectBase.Skeleton = () => /* @__PURE__ */ React90.createElement(Skeleton, {
13329
+ NativeSelectBase.Skeleton = () => /* @__PURE__ */ React92.createElement(Skeleton, {
13152
13330
  height: 38
13153
13331
  });
13154
- var NativeSelect = React90.forwardRef(
13332
+ var NativeSelect = React92.forwardRef(
13155
13333
  (_a, ref) => {
13156
13334
  var _b = _a, { readOnly } = _b, props = __objRest(_b, ["readOnly"]);
13157
13335
  var _a2;
@@ -13161,13 +13339,13 @@ var NativeSelect = React90.forwardRef(
13161
13339
  const errorProps = props.valid === false ? { "aria-invalid": true, "aria-describedby": errorMessageId } : {};
13162
13340
  const _b2 = getLabelControlProps(props), { "data-testid": dataTestId } = _b2, labelControlProps = __objRest(_b2, ["data-testid"]);
13163
13341
  const baseProps = omit14(props, Object.keys(labelControlProps));
13164
- return /* @__PURE__ */ React90.createElement(LabelControl, __spreadProps(__spreadValues({
13342
+ return /* @__PURE__ */ React92.createElement(LabelControl, __spreadProps(__spreadValues({
13165
13343
  id: `${id}-label`,
13166
13344
  htmlFor: id,
13167
13345
  messageId: errorMessageId
13168
13346
  }, labelControlProps), {
13169
13347
  className: "Aquarium-NativeSelect"
13170
- }), /* @__PURE__ */ React90.createElement(NativeSelectBase, __spreadProps(__spreadValues(__spreadValues({
13348
+ }), /* @__PURE__ */ React92.createElement(NativeSelectBase, __spreadProps(__spreadValues(__spreadValues({
13171
13349
  ref
13172
13350
  }, baseProps), errorProps), {
13173
13351
  id,
@@ -13181,63 +13359,63 @@ var NativeSelect = React90.forwardRef(
13181
13359
  }
13182
13360
  );
13183
13361
  NativeSelect.displayName = "NativeSelect";
13184
- var Option = React90.forwardRef((_a, ref) => {
13362
+ var Option = React92.forwardRef((_a, ref) => {
13185
13363
  var _b = _a, { children } = _b, props = __objRest(_b, ["children"]);
13186
- return /* @__PURE__ */ React90.createElement("option", __spreadValues({
13364
+ return /* @__PURE__ */ React92.createElement("option", __spreadValues({
13187
13365
  ref
13188
13366
  }, props), children);
13189
13367
  });
13190
13368
  Option.displayName = "Option";
13191
- var NativeSelectSkeleton = () => /* @__PURE__ */ React90.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React90.createElement(NativeSelectBase.Skeleton, null), /* @__PURE__ */ React90.createElement("div", {
13369
+ var NativeSelectSkeleton = () => /* @__PURE__ */ React92.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React92.createElement(NativeSelectBase.Skeleton, null), /* @__PURE__ */ React92.createElement("div", {
13192
13370
  style: { height: "1px" }
13193
13371
  }));
13194
13372
  NativeSelect.Skeleton = NativeSelectSkeleton;
13195
13373
  NativeSelect.Skeleton.displayName = "NativeSelect.Skeleton";
13196
13374
 
13197
13375
  // src/molecules/Navigation/Navigation.tsx
13198
- import React92 from "react";
13376
+ import React94 from "react";
13199
13377
  import classNames10 from "classnames";
13200
13378
 
13201
13379
  // src/atoms/Navigation/Navigation.tsx
13202
- import React91 from "react";
13380
+ import React93 from "react";
13203
13381
  var Navigation = (_a) => {
13204
13382
  var _b = _a, { className, children } = _b, rest = __objRest(_b, ["className", "children"]);
13205
- return /* @__PURE__ */ React91.createElement("nav", {
13383
+ return /* @__PURE__ */ React93.createElement("nav", {
13206
13384
  className: classNames(tw("bg-grey-0 h-full"))
13207
- }, /* @__PURE__ */ React91.createElement("ul", __spreadProps(__spreadValues({}, rest), {
13385
+ }, /* @__PURE__ */ React93.createElement("ul", __spreadProps(__spreadValues({}, rest), {
13208
13386
  className: classNames(tw("flex flex-col h-full"), className),
13209
13387
  role: "menubar"
13210
13388
  }), children));
13211
13389
  };
13212
13390
  var Header = (_a) => {
13213
13391
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
13214
- return /* @__PURE__ */ React91.createElement("li", __spreadProps(__spreadValues({}, rest), {
13392
+ return /* @__PURE__ */ React93.createElement("li", __spreadProps(__spreadValues({}, rest), {
13215
13393
  role: "presentation",
13216
13394
  className: classNames(tw("px-6 py-5"), className)
13217
13395
  }));
13218
13396
  };
13219
13397
  var Footer = (_a) => {
13220
13398
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
13221
- return /* @__PURE__ */ React91.createElement("li", __spreadProps(__spreadValues({}, rest), {
13399
+ return /* @__PURE__ */ React93.createElement("li", __spreadProps(__spreadValues({}, rest), {
13222
13400
  role: "presentation",
13223
13401
  className: classNames(tw("px-6 py-5 mt-auto"), className)
13224
13402
  }));
13225
13403
  };
13226
13404
  var Section2 = (_a) => {
13227
13405
  var _b = _a, { title, className } = _b, rest = __objRest(_b, ["title", "className"]);
13228
- return /* @__PURE__ */ React91.createElement("li", {
13406
+ return /* @__PURE__ */ React93.createElement("li", {
13229
13407
  role: "presentation",
13230
13408
  className: tw("py-5")
13231
- }, title && /* @__PURE__ */ React91.createElement("div", {
13409
+ }, title && /* @__PURE__ */ React93.createElement("div", {
13232
13410
  className: classNames(className, "py-2 px-6 text-grey-40 uppercase cursor-default typography-caption")
13233
- }, title), /* @__PURE__ */ React91.createElement("ul", __spreadProps(__spreadValues({}, rest), {
13411
+ }, title), /* @__PURE__ */ React93.createElement("ul", __spreadProps(__spreadValues({}, rest), {
13234
13412
  role: "group",
13235
13413
  className: classNames(tw("flex flex-col"), className)
13236
13414
  })));
13237
13415
  };
13238
13416
  var Divider3 = (_a) => {
13239
13417
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
13240
- return /* @__PURE__ */ React91.createElement("li", __spreadProps(__spreadValues({
13418
+ return /* @__PURE__ */ React93.createElement("li", __spreadProps(__spreadValues({
13241
13419
  role: "separator"
13242
13420
  }, rest), {
13243
13421
  className: classNames(tw("border-t-2 border-grey-5"), className)
@@ -13245,9 +13423,9 @@ var Divider3 = (_a) => {
13245
13423
  };
13246
13424
  var Item5 = (_a) => {
13247
13425
  var _b = _a, { className, active } = _b, rest = __objRest(_b, ["className", "active"]);
13248
- return /* @__PURE__ */ React91.createElement("li", {
13426
+ return /* @__PURE__ */ React93.createElement("li", {
13249
13427
  role: "presentation"
13250
- }, /* @__PURE__ */ React91.createElement("a", __spreadProps(__spreadValues({}, rest), {
13428
+ }, /* @__PURE__ */ React93.createElement("a", __spreadProps(__spreadValues({}, rest), {
13251
13429
  role: "menuitem",
13252
13430
  className: classNames(
13253
13431
  tw("py-3 px-6 hover:bg-grey-5 cursor-pointer flex gap-4 items-center typography-small focusable", {
@@ -13267,7 +13445,7 @@ Navigation.Divider = Divider3;
13267
13445
  // src/molecules/Navigation/Navigation.tsx
13268
13446
  var Navigation2 = (_a) => {
13269
13447
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
13270
- return /* @__PURE__ */ React92.createElement(Navigation, __spreadValues({
13448
+ return /* @__PURE__ */ React94.createElement(Navigation, __spreadValues({
13271
13449
  className: classNames10("Aquarium-Navigation", className)
13272
13450
  }, props));
13273
13451
  };
@@ -13281,11 +13459,11 @@ var Item6 = (_a) => {
13281
13459
  "icon",
13282
13460
  "showNotification"
13283
13461
  ]);
13284
- return /* @__PURE__ */ React92.createElement(Navigation.Item, __spreadValues({}, rest), icon && showNotification && /* @__PURE__ */ React92.createElement(Badge.Notification, null, /* @__PURE__ */ React92.createElement(InlineIcon, {
13462
+ return /* @__PURE__ */ React94.createElement(Navigation.Item, __spreadValues({}, rest), icon && showNotification && /* @__PURE__ */ React94.createElement(Badge.Notification, null, /* @__PURE__ */ React94.createElement(InlineIcon, {
13285
13463
  icon,
13286
13464
  width: "20px",
13287
13465
  height: "20px"
13288
- })), icon && !showNotification && /* @__PURE__ */ React92.createElement(InlineIcon, {
13466
+ })), icon && !showNotification && /* @__PURE__ */ React94.createElement(InlineIcon, {
13289
13467
  icon,
13290
13468
  width: "20px",
13291
13469
  height: "20px"
@@ -13298,32 +13476,32 @@ Navigation2.Header = Navigation.Header;
13298
13476
  Navigation2.Section = Navigation.Section;
13299
13477
 
13300
13478
  // src/molecules/PageHeader/PageHeader.tsx
13301
- import React94 from "react";
13479
+ import React96 from "react";
13302
13480
  import castArray4 from "lodash/castArray";
13303
13481
 
13304
13482
  // src/atoms/PageHeader/PageHeader.tsx
13305
- import React93 from "react";
13483
+ import React95 from "react";
13306
13484
  var PageHeader = (_a) => {
13307
13485
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13308
- return /* @__PURE__ */ React93.createElement("div", __spreadValues({
13486
+ return /* @__PURE__ */ React95.createElement("div", __spreadValues({
13309
13487
  className: classNames(tw("flex flex-row gap-4 pb-6"), className)
13310
13488
  }, rest), children);
13311
13489
  };
13312
13490
  PageHeader.Container = (_a) => {
13313
13491
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13314
- return /* @__PURE__ */ React93.createElement("div", __spreadValues({
13492
+ return /* @__PURE__ */ React95.createElement("div", __spreadValues({
13315
13493
  className: classNames(tw("flex flex-col grow gap-0"), className)
13316
13494
  }, rest), children);
13317
13495
  };
13318
13496
  PageHeader.TitleContainer = (_a) => {
13319
13497
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13320
- return /* @__PURE__ */ React93.createElement("div", __spreadValues({
13498
+ return /* @__PURE__ */ React95.createElement("div", __spreadValues({
13321
13499
  className: classNames(tw("flex flex-col justify-center gap-2"), className)
13322
13500
  }, rest), children);
13323
13501
  };
13324
13502
  PageHeader.Title = (_a) => {
13325
13503
  var _b = _a, { isSubHeader = false, children } = _b, rest = __objRest(_b, ["isSubHeader", "children"]);
13326
- return /* @__PURE__ */ React93.createElement(Typography2, __spreadProps(__spreadValues({}, rest), {
13504
+ return /* @__PURE__ */ React95.createElement(Typography2, __spreadProps(__spreadValues({}, rest), {
13327
13505
  color: "grey-100",
13328
13506
  variant: isSubHeader ? "subheading" : "heading",
13329
13507
  htmlTag: isSubHeader ? "h2" : "h1"
@@ -13331,19 +13509,19 @@ PageHeader.Title = (_a) => {
13331
13509
  };
13332
13510
  PageHeader.Subtitle = (_a) => {
13333
13511
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
13334
- return /* @__PURE__ */ React93.createElement(Typography2.Small, __spreadProps(__spreadValues({}, rest), {
13512
+ return /* @__PURE__ */ React95.createElement(Typography2.Small, __spreadProps(__spreadValues({}, rest), {
13335
13513
  color: "grey-70"
13336
13514
  }), children);
13337
13515
  };
13338
13516
  PageHeader.Chips = (_a) => {
13339
13517
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13340
- return /* @__PURE__ */ React93.createElement("div", __spreadValues({
13518
+ return /* @__PURE__ */ React95.createElement("div", __spreadValues({
13341
13519
  className: classNames(tw("flex gap-3"), className)
13342
13520
  }, rest), children);
13343
13521
  };
13344
13522
  PageHeader.Actions = (_a) => {
13345
13523
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13346
- return /* @__PURE__ */ React93.createElement("div", __spreadValues({
13524
+ return /* @__PURE__ */ React95.createElement("div", __spreadValues({
13347
13525
  className: classNames(tw("flex flex-row gap-4 self-start"), className)
13348
13526
  }, rest), children);
13349
13527
  };
@@ -13367,63 +13545,63 @@ var CommonPageHeader = ({
13367
13545
  onMenuOpenChange,
13368
13546
  isSubHeader = false
13369
13547
  }) => {
13370
- return /* @__PURE__ */ React94.createElement(PageHeader, {
13548
+ return /* @__PURE__ */ React96.createElement(PageHeader, {
13371
13549
  className: "Aquarium-PageHeader"
13372
- }, /* @__PURE__ */ React94.createElement(PageHeader.Container, null, breadcrumbs && /* @__PURE__ */ React94.createElement(Box, {
13550
+ }, /* @__PURE__ */ React96.createElement(PageHeader.Container, null, breadcrumbs && /* @__PURE__ */ React96.createElement(Box, {
13373
13551
  marginBottom: "3"
13374
- }, /* @__PURE__ */ React94.createElement(Breadcrumbs, null, breadcrumbs)), /* @__PURE__ */ React94.createElement(Spacing, {
13552
+ }, /* @__PURE__ */ React96.createElement(Breadcrumbs, null, breadcrumbs)), /* @__PURE__ */ React96.createElement(Spacing, {
13375
13553
  row: true,
13376
13554
  gap: "5"
13377
- }, image && /* @__PURE__ */ React94.createElement("img", {
13555
+ }, image && /* @__PURE__ */ React96.createElement("img", {
13378
13556
  src: image,
13379
13557
  alt: imageAlt != null ? imageAlt : "",
13380
13558
  className: tw("w-[56px] h-[56px]")
13381
- }), /* @__PURE__ */ React94.createElement(PageHeader.TitleContainer, null, /* @__PURE__ */ React94.createElement(PageHeader.Title, {
13559
+ }), /* @__PURE__ */ React96.createElement(PageHeader.TitleContainer, null, /* @__PURE__ */ React96.createElement(PageHeader.Title, {
13382
13560
  isSubHeader
13383
- }, title), chips.length > 0 && /* @__PURE__ */ React94.createElement(PageHeader.Chips, null, chips.map((chip) => /* @__PURE__ */ React94.createElement(Chip2, {
13561
+ }, title), chips.length > 0 && /* @__PURE__ */ React96.createElement(PageHeader.Chips, null, chips.map((chip) => /* @__PURE__ */ React96.createElement(Chip2, {
13384
13562
  key: chip,
13385
13563
  dense: true,
13386
13564
  text: chip
13387
- }))), subtitle && /* @__PURE__ */ React94.createElement(PageHeader.Subtitle, null, subtitle)))), (secondaryActions || primaryAction || secondaryAction || menu) && /* @__PURE__ */ React94.createElement(PageHeader.Actions, null, menu && /* @__PURE__ */ React94.createElement(Box.Flex, {
13565
+ }))), subtitle && /* @__PURE__ */ React96.createElement(PageHeader.Subtitle, null, subtitle)))), (secondaryActions || primaryAction || secondaryAction || menu) && /* @__PURE__ */ React96.createElement(PageHeader.Actions, null, menu && /* @__PURE__ */ React96.createElement(Box.Flex, {
13388
13566
  alignItems: "center"
13389
- }, /* @__PURE__ */ React94.createElement(DropdownMenu2, {
13567
+ }, /* @__PURE__ */ React96.createElement(DropdownMenu2, {
13390
13568
  onAction: (action) => onAction == null ? void 0 : onAction(action),
13391
13569
  onOpenChange: onMenuOpenChange
13392
- }, /* @__PURE__ */ React94.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React94.createElement(Button.Icon, {
13570
+ }, /* @__PURE__ */ React96.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React96.createElement(Button.Icon, {
13393
13571
  "aria-label": menuAriaLabel,
13394
13572
  icon: import_more5.default
13395
13573
  })), menu)), secondaryActions && castArray4(secondaryActions).filter(Boolean).map((secondaryAction2) => renderAction({ kind: "secondary", action: secondaryAction2 })), primaryAction && renderAction({ kind: "primary", action: primaryAction })));
13396
13574
  };
13397
- var PageHeader2 = (props) => /* @__PURE__ */ React94.createElement(CommonPageHeader, __spreadValues({}, props));
13575
+ var PageHeader2 = (props) => /* @__PURE__ */ React96.createElement(CommonPageHeader, __spreadValues({}, props));
13398
13576
  PageHeader2.displayName = "PageHeader";
13399
- var SubHeader = (props) => /* @__PURE__ */ React94.createElement(CommonPageHeader, __spreadProps(__spreadValues({}, props), {
13577
+ var SubHeader = (props) => /* @__PURE__ */ React96.createElement(CommonPageHeader, __spreadProps(__spreadValues({}, props), {
13400
13578
  isSubHeader: true
13401
13579
  }));
13402
13580
  PageHeader2.SubHeader = SubHeader;
13403
13581
  PageHeader2.SubHeader.displayName = "PageHeader.SubHeader";
13404
13582
 
13405
13583
  // src/molecules/PopoverDialog/PopoverDialog.tsx
13406
- import React96 from "react";
13584
+ import React98 from "react";
13407
13585
  import omit15 from "lodash/omit";
13408
13586
 
13409
13587
  // src/atoms/PopoverDialog/PopoverDialog.tsx
13410
- import React95 from "react";
13588
+ import React97 from "react";
13411
13589
  var Header2 = (_a) => {
13412
13590
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13413
- return /* @__PURE__ */ React95.createElement("div", __spreadProps(__spreadValues({}, rest), {
13591
+ return /* @__PURE__ */ React97.createElement("div", __spreadProps(__spreadValues({}, rest), {
13414
13592
  className: classNames(tw("p-5 gap-3 flex items-center"), className)
13415
13593
  }), children);
13416
13594
  };
13417
13595
  var Title2 = (_a) => {
13418
13596
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13419
- return /* @__PURE__ */ React95.createElement(Typography, __spreadProps(__spreadValues({}, rest), {
13597
+ return /* @__PURE__ */ React97.createElement(Typography, __spreadProps(__spreadValues({}, rest), {
13420
13598
  htmlTag: "h1",
13421
13599
  variant: "small-strong"
13422
13600
  }), children);
13423
13601
  };
13424
13602
  var Body = (_a) => {
13425
13603
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13426
- return /* @__PURE__ */ React95.createElement(Typography, __spreadProps(__spreadValues({}, rest), {
13604
+ return /* @__PURE__ */ React97.createElement(Typography, __spreadProps(__spreadValues({}, rest), {
13427
13605
  htmlTag: "div",
13428
13606
  variant: "caption",
13429
13607
  className: classNames(tw("px-5 overflow-y-auto"), className)
@@ -13431,13 +13609,13 @@ var Body = (_a) => {
13431
13609
  };
13432
13610
  var Footer2 = (_a) => {
13433
13611
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13434
- return /* @__PURE__ */ React95.createElement("div", __spreadProps(__spreadValues({}, rest), {
13612
+ return /* @__PURE__ */ React97.createElement("div", __spreadProps(__spreadValues({}, rest), {
13435
13613
  className: classNames(tw("p-5"), className)
13436
13614
  }), children);
13437
13615
  };
13438
13616
  var Actions2 = (_a) => {
13439
13617
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13440
- return /* @__PURE__ */ React95.createElement("div", __spreadProps(__spreadValues({}, rest), {
13618
+ return /* @__PURE__ */ React97.createElement("div", __spreadProps(__spreadValues({}, rest), {
13441
13619
  className: classNames(tw("flex gap-4"), className)
13442
13620
  }), children);
13443
13621
  };
@@ -13453,13 +13631,13 @@ var PopoverDialog = {
13453
13631
  var PopoverDialog2 = ({ placement, open, title, secondaryAction, primaryAction, children }) => {
13454
13632
  const wrapPromptWithBody = (child) => {
13455
13633
  if (isComponentType(child, PopoverDialog2.Prompt)) {
13456
- return /* @__PURE__ */ React96.createElement(Popover2.Panel, {
13634
+ return /* @__PURE__ */ React98.createElement(Popover2.Panel, {
13457
13635
  className: classNames("Aquarium-PopoverDialog", tw("max-w-[300px]"))
13458
- }, /* @__PURE__ */ React96.createElement(PopoverDialog.Header, null, /* @__PURE__ */ React96.createElement(PopoverDialog.Title, null, title)), child, /* @__PURE__ */ React96.createElement(PopoverDialog.Footer, null, /* @__PURE__ */ React96.createElement(PopoverDialog.Actions, null, secondaryAction && /* @__PURE__ */ React96.createElement(Popover2.Button, __spreadValues({
13636
+ }, /* @__PURE__ */ React98.createElement(PopoverDialog.Header, null, /* @__PURE__ */ React98.createElement(PopoverDialog.Title, null, title)), child, /* @__PURE__ */ React98.createElement(PopoverDialog.Footer, null, /* @__PURE__ */ React98.createElement(PopoverDialog.Actions, null, secondaryAction && /* @__PURE__ */ React98.createElement(Popover2.Button, __spreadValues({
13459
13637
  kind: "secondary-ghost",
13460
13638
  key: secondaryAction.text,
13461
13639
  dense: true
13462
- }, omit15(secondaryAction, "text")), secondaryAction.text), /* @__PURE__ */ React96.createElement(Popover2.Button, __spreadValues({
13640
+ }, omit15(secondaryAction, "text")), secondaryAction.text), /* @__PURE__ */ React98.createElement(Popover2.Button, __spreadValues({
13463
13641
  kind: "ghost",
13464
13642
  key: primaryAction.text,
13465
13643
  dense: true
@@ -13467,15 +13645,15 @@ var PopoverDialog2 = ({ placement, open, title, secondaryAction, primaryAction,
13467
13645
  }
13468
13646
  return child;
13469
13647
  };
13470
- return /* @__PURE__ */ React96.createElement(Popover2, {
13648
+ return /* @__PURE__ */ React98.createElement(Popover2, {
13471
13649
  type: "dialog",
13472
13650
  isOpen: open,
13473
13651
  placement,
13474
13652
  containFocus: true
13475
- }, React96.Children.map(children, wrapPromptWithBody));
13653
+ }, React98.Children.map(children, wrapPromptWithBody));
13476
13654
  };
13477
13655
  PopoverDialog2.Trigger = Popover2.Trigger;
13478
- var Prompt = ({ children }) => /* @__PURE__ */ React96.createElement(PopoverDialog.Body, null, children);
13656
+ var Prompt = ({ children }) => /* @__PURE__ */ React98.createElement(PopoverDialog.Body, null, children);
13479
13657
  Prompt.displayName = "PopoverDialog.Prompt";
13480
13658
  PopoverDialog2.Prompt = Prompt;
13481
13659
 
@@ -13484,14 +13662,14 @@ import { createPortal } from "react-dom";
13484
13662
  var Portal = ({ children, to }) => createPortal(children, to);
13485
13663
 
13486
13664
  // src/molecules/ProgressBar/ProgressBar.tsx
13487
- import React98 from "react";
13665
+ import React100 from "react";
13488
13666
 
13489
13667
  // src/atoms/ProgressBar/ProgressBar.tsx
13490
- import React97 from "react";
13668
+ import React99 from "react";
13491
13669
  import clamp3 from "lodash/clamp";
13492
13670
  var ProgressBar = (_a) => {
13493
13671
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13494
- return /* @__PURE__ */ React97.createElement("div", __spreadProps(__spreadValues({}, rest), {
13672
+ return /* @__PURE__ */ React99.createElement("div", __spreadProps(__spreadValues({}, rest), {
13495
13673
  className: classNames(
13496
13674
  tw("relative flex items-center w-full bg-grey-0 h-2 rounded-full overflow-hidden"),
13497
13675
  className
@@ -13507,7 +13685,7 @@ var STATUS_COLORS = {
13507
13685
  ProgressBar.Indicator = (_a) => {
13508
13686
  var _b = _a, { min, max, value, "aria-label": ariaLabel, status, className } = _b, rest = __objRest(_b, ["min", "max", "value", "aria-label", "status", "className"]);
13509
13687
  const completedPercentage = clamp3((value - min) / (max - min) * 100, 0, 100);
13510
- return /* @__PURE__ */ React97.createElement("div", __spreadProps(__spreadValues({}, rest), {
13688
+ return /* @__PURE__ */ React99.createElement("div", __spreadProps(__spreadValues({}, rest), {
13511
13689
  className: classNames(
13512
13690
  tw("h-2 rounded-full transition-all ease-in-out delay-150"),
13513
13691
  STATUS_COLORS[status],
@@ -13523,11 +13701,11 @@ ProgressBar.Indicator = (_a) => {
13523
13701
  };
13524
13702
  ProgressBar.Labels = (_a) => {
13525
13703
  var _b = _a, { children, startLabel, endLabel, className } = _b, rest = __objRest(_b, ["children", "startLabel", "endLabel", "className"]);
13526
- return /* @__PURE__ */ React97.createElement("div", {
13704
+ return /* @__PURE__ */ React99.createElement("div", {
13527
13705
  className: classNames(tw("flex flex-row"), className)
13528
- }, /* @__PURE__ */ React97.createElement("span", __spreadProps(__spreadValues({}, rest), {
13706
+ }, /* @__PURE__ */ React99.createElement("span", __spreadProps(__spreadValues({}, rest), {
13529
13707
  className: tw("grow text-grey-70 typography-caption")
13530
- }), startLabel), /* @__PURE__ */ React97.createElement("span", __spreadProps(__spreadValues({}, rest), {
13708
+ }), startLabel), /* @__PURE__ */ React99.createElement("span", __spreadProps(__spreadValues({}, rest), {
13531
13709
  className: tw("grow text-grey-70 typography-caption text-right")
13532
13710
  }), endLabel));
13533
13711
  };
@@ -13545,7 +13723,7 @@ var ProgressBar2 = (props) => {
13545
13723
  if (min > max) {
13546
13724
  throw new Error("`min` value provided to `ProgressBar` is greater than `max` value.");
13547
13725
  }
13548
- const progress = /* @__PURE__ */ React98.createElement(ProgressBar, null, /* @__PURE__ */ React98.createElement(ProgressBar.Indicator, {
13726
+ const progress = /* @__PURE__ */ React100.createElement(ProgressBar, null, /* @__PURE__ */ React100.createElement(ProgressBar.Indicator, {
13549
13727
  status: value === max ? completedStatus : progresStatus,
13550
13728
  min,
13551
13729
  max,
@@ -13555,15 +13733,15 @@ var ProgressBar2 = (props) => {
13555
13733
  if (props.dense) {
13556
13734
  return progress;
13557
13735
  }
13558
- return /* @__PURE__ */ React98.createElement("div", {
13736
+ return /* @__PURE__ */ React100.createElement("div", {
13559
13737
  className: "Aquarium-ProgressBar"
13560
- }, progress, /* @__PURE__ */ React98.createElement(ProgressBar.Labels, {
13738
+ }, progress, /* @__PURE__ */ React100.createElement(ProgressBar.Labels, {
13561
13739
  className: tw("py-2"),
13562
13740
  startLabel: props.startLabel,
13563
13741
  endLabel: props.endLabel
13564
13742
  }));
13565
13743
  };
13566
- var ProgressBarSkeleton = () => /* @__PURE__ */ React98.createElement(Skeleton, {
13744
+ var ProgressBarSkeleton = () => /* @__PURE__ */ React100.createElement(Skeleton, {
13567
13745
  height: 4,
13568
13746
  display: "block"
13569
13747
  });
@@ -13571,13 +13749,13 @@ ProgressBar2.Skeleton = ProgressBarSkeleton;
13571
13749
  ProgressBar2.Skeleton.displayName = "ProgressBar.Skeleton";
13572
13750
 
13573
13751
  // src/molecules/RadioButton/RadioButton.tsx
13574
- import React99 from "react";
13575
- var RadioButton2 = React99.forwardRef(
13752
+ import React101 from "react";
13753
+ var RadioButton2 = React101.forwardRef(
13576
13754
  (_a, ref) => {
13577
13755
  var _b = _a, { name, id, readOnly = false, disabled = false, caption, children, "aria-label": ariaLabel } = _b, props = __objRest(_b, ["name", "id", "readOnly", "disabled", "caption", "children", "aria-label"]);
13578
13756
  var _a2;
13579
13757
  const isChecked = (_a2 = props.checked) != null ? _a2 : props.defaultChecked;
13580
- return !readOnly || isChecked ? /* @__PURE__ */ React99.createElement(ControlLabel, {
13758
+ return !readOnly || isChecked ? /* @__PURE__ */ React101.createElement(ControlLabel, {
13581
13759
  htmlFor: id,
13582
13760
  label: children,
13583
13761
  "aria-label": ariaLabel,
@@ -13586,7 +13764,7 @@ var RadioButton2 = React99.forwardRef(
13586
13764
  disabled,
13587
13765
  style: { gap: "0 8px" },
13588
13766
  className: "Aquarium-RadioButton"
13589
- }, !readOnly && /* @__PURE__ */ React99.createElement(RadioButton, __spreadProps(__spreadValues({
13767
+ }, !readOnly && /* @__PURE__ */ React101.createElement(RadioButton, __spreadProps(__spreadValues({
13590
13768
  id,
13591
13769
  ref,
13592
13770
  name
@@ -13597,12 +13775,12 @@ var RadioButton2 = React99.forwardRef(
13597
13775
  }
13598
13776
  );
13599
13777
  RadioButton2.displayName = "RadioButton";
13600
- var RadioButtonSkeleton = () => /* @__PURE__ */ React99.createElement("div", {
13778
+ var RadioButtonSkeleton = () => /* @__PURE__ */ React101.createElement("div", {
13601
13779
  className: tw("flex gap-3")
13602
- }, /* @__PURE__ */ React99.createElement(Skeleton, {
13780
+ }, /* @__PURE__ */ React101.createElement(Skeleton, {
13603
13781
  height: 20,
13604
13782
  width: 20
13605
- }), /* @__PURE__ */ React99.createElement(Skeleton, {
13783
+ }), /* @__PURE__ */ React101.createElement(Skeleton, {
13606
13784
  height: 20,
13607
13785
  width: 150
13608
13786
  }));
@@ -13610,10 +13788,10 @@ RadioButton2.Skeleton = RadioButtonSkeleton;
13610
13788
  RadioButton2.Skeleton.displayName = "RadioButton.Skeleton";
13611
13789
 
13612
13790
  // src/molecules/RadioButtonGroup/RadioButtonGroup.tsx
13613
- import React100 from "react";
13791
+ import React102 from "react";
13614
13792
  import { useId as useId14 } from "@react-aria/utils";
13615
13793
  var isRadioButton = (c) => {
13616
- return React100.isValidElement(c) && c.type === RadioButton2;
13794
+ return React102.isValidElement(c) && c.type === RadioButton2;
13617
13795
  };
13618
13796
  var RadioButtonGroup = (_a) => {
13619
13797
  var _b = _a, {
@@ -13636,7 +13814,7 @@ var RadioButtonGroup = (_a) => {
13636
13814
  "children"
13637
13815
  ]);
13638
13816
  var _a2;
13639
- const [value, setValue] = React100.useState((_a2 = _value != null ? _value : defaultValue) != null ? _a2 : "");
13817
+ const [value, setValue] = React102.useState((_a2 = _value != null ? _value : defaultValue) != null ? _a2 : "");
13640
13818
  const errorMessageId = useId14();
13641
13819
  const errorProps = props.valid === false ? { "aria-invalid": true, "aria-describedby": errorMessageId } : {};
13642
13820
  const labelControlProps = getLabelControlProps(props);
@@ -13647,14 +13825,14 @@ var RadioButtonGroup = (_a) => {
13647
13825
  setValue(e.target.value);
13648
13826
  onChange == null ? void 0 : onChange(e.target.value);
13649
13827
  };
13650
- const content = React100.Children.map(children, (c) => {
13828
+ const content = React102.Children.map(children, (c) => {
13651
13829
  var _a3, _b2, _c;
13652
13830
  if (!isRadioButton(c)) {
13653
13831
  return null;
13654
13832
  }
13655
13833
  const defaultChecked = defaultValue === void 0 ? void 0 : c.props.value === defaultValue;
13656
13834
  const checked = value === void 0 ? void 0 : c.props.value === value;
13657
- return React100.cloneElement(c, {
13835
+ return React102.cloneElement(c, {
13658
13836
  name,
13659
13837
  defaultChecked: (_a3 = c.props.defaultChecked) != null ? _a3 : defaultChecked,
13660
13838
  checked: (_b2 = c.props.checked) != null ? _b2 : checked,
@@ -13663,13 +13841,13 @@ var RadioButtonGroup = (_a) => {
13663
13841
  readOnly
13664
13842
  });
13665
13843
  });
13666
- return /* @__PURE__ */ React100.createElement(LabelControl, __spreadProps(__spreadValues(__spreadValues({
13844
+ return /* @__PURE__ */ React102.createElement(LabelControl, __spreadProps(__spreadValues(__spreadValues({
13667
13845
  fieldset: true
13668
13846
  }, labelControlProps), errorProps), {
13669
13847
  className: "Aquarium-RadioButtonGroup"
13670
- }), cols && /* @__PURE__ */ React100.createElement(InputGroup, {
13848
+ }), cols && /* @__PURE__ */ React102.createElement(InputGroup, {
13671
13849
  cols
13672
- }, content), !cols && /* @__PURE__ */ React100.createElement(Flexbox, {
13850
+ }, content), !cols && /* @__PURE__ */ React102.createElement(Flexbox, {
13673
13851
  direction,
13674
13852
  alignItems: "flex-start",
13675
13853
  colGap: "8",
@@ -13678,12 +13856,12 @@ var RadioButtonGroup = (_a) => {
13678
13856
  }, content));
13679
13857
  };
13680
13858
  var RadioButtonGroupSkeleton = ({ direction = "row", options = 2 }) => {
13681
- return /* @__PURE__ */ React100.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React100.createElement("div", {
13859
+ return /* @__PURE__ */ React102.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React102.createElement("div", {
13682
13860
  className: tw("flex flex-wrap", {
13683
13861
  "flex-row gap-8": direction === "row",
13684
13862
  "flex-col gap-2": direction === "column"
13685
13863
  })
13686
- }, Array.from({ length: options }).map((_, key) => /* @__PURE__ */ React100.createElement(RadioButton2.Skeleton, {
13864
+ }, Array.from({ length: options }).map((_, key) => /* @__PURE__ */ React102.createElement(RadioButton2.Skeleton, {
13687
13865
  key
13688
13866
  }))));
13689
13867
  };
@@ -13691,24 +13869,24 @@ RadioButtonGroup.Skeleton = RadioButtonGroupSkeleton;
13691
13869
  RadioButtonGroup.Skeleton.displayName = "RadioButtonGroup.Skeleton";
13692
13870
 
13693
13871
  // src/molecules/Section/Section.tsx
13694
- import React105 from "react";
13872
+ import React107 from "react";
13695
13873
  import { useId as useId15 } from "@react-aria/utils";
13696
13874
  import { animated as animated5, useSpring as useSpring4 } from "@react-spring/web";
13697
13875
  import castArray5 from "lodash/castArray";
13698
13876
  import isUndefined9 from "lodash/isUndefined";
13699
13877
 
13700
13878
  // src/molecules/Switch/Switch.tsx
13701
- import React102 from "react";
13879
+ import React104 from "react";
13702
13880
 
13703
13881
  // src/atoms/Switch/Switch.tsx
13704
- import React101 from "react";
13882
+ import React103 from "react";
13705
13883
  var import_ban2 = __toESM(require_ban());
13706
- var Switch = React101.forwardRef(
13884
+ var Switch = React103.forwardRef(
13707
13885
  (_a, ref) => {
13708
13886
  var _b = _a, { id, children, name, disabled = false, readOnly = false } = _b, props = __objRest(_b, ["id", "children", "name", "disabled", "readOnly"]);
13709
- return /* @__PURE__ */ React101.createElement("span", {
13887
+ return /* @__PURE__ */ React103.createElement("span", {
13710
13888
  className: tw("relative inline-flex justify-center items-center self-center group")
13711
- }, /* @__PURE__ */ React101.createElement("input", __spreadProps(__spreadValues({
13889
+ }, /* @__PURE__ */ React103.createElement("input", __spreadProps(__spreadValues({
13712
13890
  id,
13713
13891
  ref,
13714
13892
  type: "checkbox",
@@ -13727,7 +13905,7 @@ var Switch = React101.forwardRef(
13727
13905
  ),
13728
13906
  readOnly,
13729
13907
  disabled
13730
- })), /* @__PURE__ */ React101.createElement("span", {
13908
+ })), /* @__PURE__ */ React103.createElement("span", {
13731
13909
  className: tw(
13732
13910
  "pointer-events-none rounded-full absolute inline-flex justify-center items-center transition duration-300 h-4 w-4 transform peer-checked/switch:translate-x-5",
13733
13911
  "bg-white left-2 peer-checked/switch:left-1 text-grey-30 peer-checked/switch:text-primary-60",
@@ -13735,7 +13913,7 @@ var Switch = React101.forwardRef(
13735
13913
  "shadow-4dp": !disabled
13736
13914
  }
13737
13915
  )
13738
- }, disabled && /* @__PURE__ */ React101.createElement(Icon, {
13916
+ }, disabled && /* @__PURE__ */ React103.createElement(Icon, {
13739
13917
  icon: import_ban2.default,
13740
13918
  width: "10px",
13741
13919
  height: "10px"
@@ -13744,7 +13922,7 @@ var Switch = React101.forwardRef(
13744
13922
  );
13745
13923
 
13746
13924
  // src/molecules/Switch/Switch.tsx
13747
- var Switch2 = React102.forwardRef(
13925
+ var Switch2 = React104.forwardRef(
13748
13926
  (_a, ref) => {
13749
13927
  var _b = _a, {
13750
13928
  id,
@@ -13767,7 +13945,7 @@ var Switch2 = React102.forwardRef(
13767
13945
  ]);
13768
13946
  var _a2;
13769
13947
  const isChecked = (_a2 = props.checked) != null ? _a2 : props.defaultChecked;
13770
- return !readOnly || isChecked ? /* @__PURE__ */ React102.createElement(ControlLabel, {
13948
+ return !readOnly || isChecked ? /* @__PURE__ */ React104.createElement(ControlLabel, {
13771
13949
  htmlFor: id,
13772
13950
  label: children,
13773
13951
  "aria-label": ariaLabel,
@@ -13777,7 +13955,7 @@ var Switch2 = React102.forwardRef(
13777
13955
  style: { gap: "0 8px" },
13778
13956
  labelPlacement,
13779
13957
  className: "Aquarium-Switch"
13780
- }, !readOnly && /* @__PURE__ */ React102.createElement(Switch, __spreadProps(__spreadValues({
13958
+ }, !readOnly && /* @__PURE__ */ React104.createElement(Switch, __spreadProps(__spreadValues({
13781
13959
  id,
13782
13960
  ref,
13783
13961
  name
@@ -13788,12 +13966,12 @@ var Switch2 = React102.forwardRef(
13788
13966
  }
13789
13967
  );
13790
13968
  Switch2.displayName = "Switch";
13791
- var SwitchSkeleton = () => /* @__PURE__ */ React102.createElement("div", {
13969
+ var SwitchSkeleton = () => /* @__PURE__ */ React104.createElement("div", {
13792
13970
  className: tw("flex gap-3")
13793
- }, /* @__PURE__ */ React102.createElement(Skeleton, {
13971
+ }, /* @__PURE__ */ React104.createElement(Skeleton, {
13794
13972
  height: 20,
13795
13973
  width: 35
13796
- }), /* @__PURE__ */ React102.createElement(Skeleton, {
13974
+ }), /* @__PURE__ */ React104.createElement(Skeleton, {
13797
13975
  height: 20,
13798
13976
  width: 150
13799
13977
  }));
@@ -13801,7 +13979,7 @@ Switch2.Skeleton = SwitchSkeleton;
13801
13979
  Switch2.Skeleton.displayName = "Switch.Skeleton ";
13802
13980
 
13803
13981
  // src/molecules/TagLabel/TagLabel.tsx
13804
- import React103 from "react";
13982
+ import React105 from "react";
13805
13983
  var getVariantClassNames = (variant = "primary") => {
13806
13984
  switch (variant) {
13807
13985
  case "danger":
@@ -13815,7 +13993,7 @@ var getVariantClassNames = (variant = "primary") => {
13815
13993
  };
13816
13994
  var TagLabel = (_a) => {
13817
13995
  var _b = _a, { title, dense = false, variant } = _b, rest = __objRest(_b, ["title", "dense", "variant"]);
13818
- return /* @__PURE__ */ React103.createElement("span", __spreadProps(__spreadValues({}, rest), {
13996
+ return /* @__PURE__ */ React105.createElement("span", __spreadProps(__spreadValues({}, rest), {
13819
13997
  className: classNames(
13820
13998
  "Aquarium-TagLabel",
13821
13999
  getVariantClassNames(variant),
@@ -13828,11 +14006,11 @@ var TagLabel = (_a) => {
13828
14006
  };
13829
14007
 
13830
14008
  // src/atoms/Section/Section.tsx
13831
- import React104 from "react";
14009
+ import React106 from "react";
13832
14010
  var import_caretUp2 = __toESM(require_caretUp());
13833
14011
  var Section3 = (_a) => {
13834
14012
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
13835
- return /* @__PURE__ */ React104.createElement(Box, __spreadValues({
14013
+ return /* @__PURE__ */ React106.createElement(Box, __spreadValues({
13836
14014
  component: "section",
13837
14015
  borderColor: "grey-5",
13838
14016
  borderWidth: "1px"
@@ -13840,7 +14018,7 @@ var Section3 = (_a) => {
13840
14018
  };
13841
14019
  Section3.Header = (_a) => {
13842
14020
  var _b = _a, { children, className, expanded } = _b, rest = __objRest(_b, ["children", "className", "expanded"]);
13843
- return /* @__PURE__ */ React104.createElement("div", __spreadProps(__spreadValues({}, rest), {
14021
+ return /* @__PURE__ */ React106.createElement("div", __spreadProps(__spreadValues({}, rest), {
13844
14022
  className: classNames(
13845
14023
  tw("px-6 flex gap-5 justify-between items-center h-[72px]", { "bg-grey-0": expanded }),
13846
14024
  className
@@ -13849,21 +14027,21 @@ Section3.Header = (_a) => {
13849
14027
  };
13850
14028
  Section3.TitleContainer = (_a) => {
13851
14029
  var _b = _a, { children, className, collapsible } = _b, rest = __objRest(_b, ["children", "className", "collapsible"]);
13852
- return /* @__PURE__ */ React104.createElement("div", __spreadProps(__spreadValues({}, rest), {
14030
+ return /* @__PURE__ */ React106.createElement("div", __spreadProps(__spreadValues({}, rest), {
13853
14031
  className: classNames(
13854
14032
  tw("grow grid grid-cols-[auto_1fr] gap-x-3 items-center", { "cursor-pointer": collapsible }),
13855
14033
  className
13856
14034
  )
13857
14035
  }), children);
13858
14036
  };
13859
- Section3.Toggle = (props) => /* @__PURE__ */ React104.createElement(Icon, __spreadProps(__spreadValues({}, props), {
14037
+ Section3.Toggle = (props) => /* @__PURE__ */ React106.createElement(Icon, __spreadProps(__spreadValues({}, props), {
13860
14038
  icon: import_caretUp2.default,
13861
14039
  height: 22,
13862
14040
  width: 22
13863
14041
  }));
13864
14042
  Section3.Title = (_a) => {
13865
14043
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
13866
- return /* @__PURE__ */ React104.createElement(Typography2.Large, __spreadProps(__spreadValues({}, rest), {
14044
+ return /* @__PURE__ */ React106.createElement(Typography2.Large, __spreadProps(__spreadValues({}, rest), {
13867
14045
  htmlTag: "h2",
13868
14046
  color: "black",
13869
14047
  className: "flex gap-3 items-center"
@@ -13871,21 +14049,21 @@ Section3.Title = (_a) => {
13871
14049
  };
13872
14050
  Section3.Subtitle = (_a) => {
13873
14051
  var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
13874
- return /* @__PURE__ */ React104.createElement(Typography2.Small, __spreadProps(__spreadValues({}, rest), {
14052
+ return /* @__PURE__ */ React106.createElement(Typography2.Small, __spreadProps(__spreadValues({}, rest), {
13875
14053
  color: "grey-70"
13876
14054
  }), children);
13877
14055
  };
13878
14056
  Section3.Actions = (_a) => {
13879
14057
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13880
- return /* @__PURE__ */ React104.createElement("div", __spreadProps(__spreadValues({}, rest), {
14058
+ return /* @__PURE__ */ React106.createElement("div", __spreadProps(__spreadValues({}, rest), {
13881
14059
  className: classNames(tw("flex gap-4 justify-end"), className)
13882
14060
  }), children);
13883
14061
  };
13884
14062
  Section3.Body = (_a) => {
13885
14063
  var _b = _a, { children, className } = _b, rest = __objRest(_b, ["children", "className"]);
13886
- return /* @__PURE__ */ React104.createElement("div", __spreadProps(__spreadValues({}, rest), {
14064
+ return /* @__PURE__ */ React106.createElement("div", __spreadProps(__spreadValues({}, rest), {
13887
14065
  className: classNames(tw("p-6"), className)
13888
- }), /* @__PURE__ */ React104.createElement(Typography, {
14066
+ }), /* @__PURE__ */ React106.createElement(Typography, {
13889
14067
  htmlTag: "div",
13890
14068
  color: "grey-70"
13891
14069
  }, children));
@@ -13899,7 +14077,7 @@ var Section4 = (props) => {
13899
14077
  const _collapsible = title ? (_a = props.collapsible) != null ? _a : false : false;
13900
14078
  const _collapsed = title ? props.collapsed : void 0;
13901
14079
  const _defaultCollapsed = title ? (_b = props.defaultCollapsed) != null ? _b : false : false;
13902
- const [isCollapsed, setCollapsed] = React105.useState(_collapsed != null ? _collapsed : _defaultCollapsed);
14080
+ const [isCollapsed, setCollapsed] = React107.useState(_collapsed != null ? _collapsed : _defaultCollapsed);
13903
14081
  const [ref, { height }] = useMeasure();
13904
14082
  const menu = title ? (_c = props.menu) != null ? _c : void 0 : void 0;
13905
14083
  const menuAriaLabel = title ? (_e = (_d = props.menuAriaLabel) != null ? _d : props.menuLabel) != null ? _e : "Context menu" : void 0;
@@ -13934,60 +14112,60 @@ var Section4 = (props) => {
13934
14112
  const regionId = useId15();
13935
14113
  const titleId = useId15();
13936
14114
  const hasTabs = isComponentType(children, Tabs);
13937
- return /* @__PURE__ */ React105.createElement(Section3, {
14115
+ return /* @__PURE__ */ React107.createElement(Section3, {
13938
14116
  "aria-label": title,
13939
14117
  className: "Aquarium-Section"
13940
- }, title && /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Section3.Header, {
14118
+ }, title && /* @__PURE__ */ React107.createElement(React107.Fragment, null, /* @__PURE__ */ React107.createElement(Section3.Header, {
13941
14119
  expanded: _collapsible && !isCollapsed
13942
- }, /* @__PURE__ */ React105.createElement(Section3.TitleContainer, {
14120
+ }, /* @__PURE__ */ React107.createElement(Section3.TitleContainer, {
13943
14121
  role: _collapsible ? "button" : void 0,
13944
14122
  id: toggleId,
13945
14123
  collapsible: _collapsible,
13946
14124
  onClick: handleTitleClick,
13947
14125
  "aria-expanded": _collapsible ? !isCollapsed : void 0,
13948
14126
  "aria-controls": _collapsible ? regionId : void 0
13949
- }, _collapsible && /* @__PURE__ */ React105.createElement(animated5.div, {
14127
+ }, _collapsible && /* @__PURE__ */ React107.createElement(animated5.div, {
13950
14128
  style: { transform }
13951
- }, /* @__PURE__ */ React105.createElement(Section3.Toggle, null)), /* @__PURE__ */ React105.createElement(Section3.Title, {
14129
+ }, /* @__PURE__ */ React107.createElement(Section3.Toggle, null)), /* @__PURE__ */ React107.createElement(Section3.Title, {
13952
14130
  id: titleId
13953
- }, /* @__PURE__ */ React105.createElement(LineClamp2, {
14131
+ }, /* @__PURE__ */ React107.createElement(LineClamp2, {
13954
14132
  lines: 1
13955
- }, title), props.tag && /* @__PURE__ */ React105.createElement(TagLabel, __spreadValues({}, props.tag)), props.badge && /* @__PURE__ */ React105.createElement(Chip2, {
14133
+ }, title), props.tag && /* @__PURE__ */ React107.createElement(TagLabel, __spreadValues({}, props.tag)), props.badge && /* @__PURE__ */ React107.createElement(Chip2, {
13956
14134
  text: props.badge
13957
- }), props.chip && /* @__PURE__ */ React105.createElement(StatusChip, __spreadValues({}, props.chip))), subtitle && /* @__PURE__ */ React105.createElement(Section3.Subtitle, {
14135
+ }), props.chip && /* @__PURE__ */ React107.createElement(StatusChip, __spreadValues({}, props.chip))), subtitle && /* @__PURE__ */ React107.createElement(Section3.Subtitle, {
13958
14136
  className: tw("row-start-2", { "col-start-2": _collapsible })
13959
- }, /* @__PURE__ */ React105.createElement(LineClamp2, {
14137
+ }, /* @__PURE__ */ React107.createElement(LineClamp2, {
13960
14138
  lines: 1
13961
- }, subtitle))), !isCollapsed && /* @__PURE__ */ React105.createElement(Section3.Actions, null, menu && /* @__PURE__ */ React105.createElement(Box.Flex, {
14139
+ }, subtitle))), !isCollapsed && /* @__PURE__ */ React107.createElement(Section3.Actions, null, menu && /* @__PURE__ */ React107.createElement(Box.Flex, {
13962
14140
  alignItems: "center"
13963
- }, /* @__PURE__ */ React105.createElement(DropdownMenu2, {
14141
+ }, /* @__PURE__ */ React107.createElement(DropdownMenu2, {
13964
14142
  onAction: (action) => onAction == null ? void 0 : onAction(action),
13965
14143
  onOpenChange: onMenuOpenChange
13966
- }, /* @__PURE__ */ React105.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React105.createElement(Button.Icon, {
14144
+ }, /* @__PURE__ */ React107.createElement(DropdownMenu2.Trigger, null, /* @__PURE__ */ React107.createElement(Button.Icon, {
13967
14145
  "aria-label": menuAriaLabel,
13968
14146
  icon: import_more6.default
13969
- })), menu)), props.actions && castArray5(props.actions).filter(Boolean).map((action) => renderAction({ kind: "secondary", action })), props.switch && /* @__PURE__ */ React105.createElement(Switch2, __spreadValues({}, props.switch)), props.select && /* @__PURE__ */ React105.createElement(SelectBase, __spreadValues({
14147
+ })), menu)), props.actions && castArray5(props.actions).filter(Boolean).map((action) => renderAction({ kind: "secondary", action })), props.switch && /* @__PURE__ */ React107.createElement(Switch2, __spreadValues({}, props.switch)), props.select && /* @__PURE__ */ React107.createElement(SelectBase, __spreadValues({
13970
14148
  "aria-labelledby": titleId
13971
- }, props.select)))), !hasTabs && /* @__PURE__ */ React105.createElement(animated5.div, {
14149
+ }, props.select)))), !hasTabs && /* @__PURE__ */ React107.createElement(animated5.div, {
13972
14150
  className: tw(`h-[1px]`),
13973
14151
  style: { backgroundColor }
13974
- })), /* @__PURE__ */ React105.createElement(animated5.div, {
14152
+ })), /* @__PURE__ */ React107.createElement(animated5.div, {
13975
14153
  id: regionId,
13976
14154
  "aria-hidden": _collapsible ? isCollapsed ? true : void 0 : void 0,
13977
14155
  style: spring,
13978
14156
  className: tw({ "overflow-hidden": _collapsible })
13979
- }, /* @__PURE__ */ React105.createElement("div", {
14157
+ }, /* @__PURE__ */ React107.createElement("div", {
13980
14158
  ref
13981
- }, hasTabs ? /* @__PURE__ */ React105.createElement(SectionTabs, __spreadProps(__spreadValues({}, children.props), {
14159
+ }, hasTabs ? /* @__PURE__ */ React107.createElement(SectionTabs, __spreadProps(__spreadValues({}, children.props), {
13982
14160
  className: tw("[&>div:first-child]:px-3 grow flex flex-col overflow-y-auto")
13983
- })) : /* @__PURE__ */ React105.createElement(Section3.Body, null, children))));
14161
+ })) : /* @__PURE__ */ React107.createElement(Section3.Body, null, children))));
13984
14162
  };
13985
- var SectionTabs = createTabsComponent(ModalTab, TabItem, "SectionTabs", (children, selected) => /* @__PURE__ */ React105.createElement(Section3.Body, null, children.find(
14163
+ var SectionTabs = createTabsComponent(ModalTab, TabItem, "SectionTabs", (children, selected) => /* @__PURE__ */ React107.createElement(Section3.Body, null, children.find(
13986
14164
  (node, index) => (node == null ? void 0 : node.props.value) === selected || index === selected
13987
14165
  )));
13988
14166
 
13989
14167
  // src/molecules/SegmentedControl/SegmentedControl.tsx
13990
- import React106 from "react";
14168
+ import React108 from "react";
13991
14169
  var SegmentedControl = (_a) => {
13992
14170
  var _b = _a, {
13993
14171
  children,
@@ -14004,7 +14182,7 @@ var SegmentedControl = (_a) => {
14004
14182
  "selected",
14005
14183
  "className"
14006
14184
  ]);
14007
- return /* @__PURE__ */ React106.createElement("li", null, /* @__PURE__ */ React106.createElement("button", __spreadProps(__spreadValues({
14185
+ return /* @__PURE__ */ React108.createElement("li", null, /* @__PURE__ */ React108.createElement("button", __spreadProps(__spreadValues({
14008
14186
  type: "button"
14009
14187
  }, rest), {
14010
14188
  className: classNames(
@@ -14038,12 +14216,12 @@ var SegmentedControlGroup = (_a) => {
14038
14216
  "border border-grey-20 text-grey-50": variant === "outlined",
14039
14217
  "bg-grey-0": variant === "raised"
14040
14218
  });
14041
- return /* @__PURE__ */ React106.createElement("ul", __spreadProps(__spreadValues({}, rest), {
14219
+ return /* @__PURE__ */ React108.createElement("ul", __spreadProps(__spreadValues({}, rest), {
14042
14220
  "aria-label": ariaLabel,
14043
14221
  className: classNames("Aquarium-SegmentedControl", classes2, className)
14044
- }), React106.Children.map(
14222
+ }), React108.Children.map(
14045
14223
  children,
14046
- (child) => React106.cloneElement(child, {
14224
+ (child) => React108.cloneElement(child, {
14047
14225
  dense,
14048
14226
  variant,
14049
14227
  onClick: () => onChange(child.props.value),
@@ -14081,14 +14259,14 @@ var getCommonClassNames = (dense, selected) => tw(
14081
14259
  );
14082
14260
 
14083
14261
  // src/molecules/Stepper/Stepper.tsx
14084
- import React108 from "react";
14262
+ import React110 from "react";
14085
14263
 
14086
14264
  // src/atoms/Stepper/Stepper.tsx
14087
- import React107 from "react";
14265
+ import React109 from "react";
14088
14266
  var import_tick6 = __toESM(require_tick());
14089
14267
  var Stepper = (_a) => {
14090
14268
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14091
- return /* @__PURE__ */ React107.createElement("div", __spreadProps(__spreadValues({}, rest), {
14269
+ return /* @__PURE__ */ React109.createElement("div", __spreadProps(__spreadValues({}, rest), {
14092
14270
  className: classNames(className)
14093
14271
  }));
14094
14272
  };
@@ -14102,7 +14280,7 @@ var ConnectorContainer = (_a) => {
14102
14280
  "completed",
14103
14281
  "dense"
14104
14282
  ]);
14105
- return /* @__PURE__ */ React107.createElement("div", __spreadProps(__spreadValues({}, rest), {
14283
+ return /* @__PURE__ */ React109.createElement("div", __spreadProps(__spreadValues({}, rest), {
14106
14284
  className: classNames(
14107
14285
  tw("absolute w-full -left-1/2", {
14108
14286
  "top-[3px] px-[14px]": Boolean(dense),
@@ -14114,7 +14292,7 @@ var ConnectorContainer = (_a) => {
14114
14292
  };
14115
14293
  var Connector = (_a) => {
14116
14294
  var _b = _a, { children, className, completed, dense } = _b, rest = __objRest(_b, ["children", "className", "completed", "dense"]);
14117
- return /* @__PURE__ */ React107.createElement("div", __spreadProps(__spreadValues({}, rest), {
14295
+ return /* @__PURE__ */ React109.createElement("div", __spreadProps(__spreadValues({}, rest), {
14118
14296
  className: classNames(
14119
14297
  tw("w-full", {
14120
14298
  "bg-grey-20": !completed,
@@ -14128,7 +14306,7 @@ var Connector = (_a) => {
14128
14306
  };
14129
14307
  var Step = (_a) => {
14130
14308
  var _b = _a, { className, state } = _b, rest = __objRest(_b, ["className", "state"]);
14131
- return /* @__PURE__ */ React107.createElement("div", __spreadProps(__spreadValues({}, rest), {
14309
+ return /* @__PURE__ */ React109.createElement("div", __spreadProps(__spreadValues({}, rest), {
14132
14310
  className: classNames(
14133
14311
  tw("flex flex-col items-center text-grey-90 relative text-center", {
14134
14312
  "text-grey-20": state === "inactive"
@@ -14149,13 +14327,13 @@ var getDenseClassNames = (state) => tw("h-[8px] w-[8px]", {
14149
14327
  });
14150
14328
  var Indicator = (_a) => {
14151
14329
  var _b = _a, { children, className, state, dense } = _b, rest = __objRest(_b, ["children", "className", "state", "dense"]);
14152
- return /* @__PURE__ */ React107.createElement("div", __spreadProps(__spreadValues({}, rest), {
14330
+ return /* @__PURE__ */ React109.createElement("div", __spreadProps(__spreadValues({}, rest), {
14153
14331
  className: classNames(
14154
14332
  tw("rounded-full flex justify-center items-center mx-2 mb-3"),
14155
14333
  dense ? getDenseClassNames(state) : getClassNames(state),
14156
14334
  className
14157
14335
  )
14158
- }), state === "completed" ? /* @__PURE__ */ React107.createElement(InlineIcon, {
14336
+ }), state === "completed" ? /* @__PURE__ */ React109.createElement(InlineIcon, {
14159
14337
  icon: import_tick6.default
14160
14338
  }) : dense ? null : children);
14161
14339
  };
@@ -14166,26 +14344,26 @@ Stepper.ConnectorContainer = ConnectorContainer;
14166
14344
 
14167
14345
  // src/molecules/Stepper/Stepper.tsx
14168
14346
  var Stepper2 = ({ children, activeIndex, dense }) => {
14169
- const steps = React108.Children.count(children);
14170
- return /* @__PURE__ */ React108.createElement(Stepper, {
14347
+ const steps = React110.Children.count(children);
14348
+ return /* @__PURE__ */ React110.createElement(Stepper, {
14171
14349
  role: "list",
14172
14350
  className: "Aquarium-Stepper"
14173
- }, /* @__PURE__ */ React108.createElement(Template, {
14351
+ }, /* @__PURE__ */ React110.createElement(Template, {
14174
14352
  columns: steps
14175
- }, React108.Children.map(children, (child, index) => {
14353
+ }, React110.Children.map(children, (child, index) => {
14176
14354
  if (!isComponentType(child, Step2)) {
14177
14355
  throw new Error("<Stepper> can only have <Stepper.Step> components as children");
14178
14356
  } else {
14179
14357
  const state = index > activeIndex ? "inactive" : index === activeIndex ? "active" : "completed";
14180
- return /* @__PURE__ */ React108.createElement(Stepper.Step, {
14358
+ return /* @__PURE__ */ React110.createElement(Stepper.Step, {
14181
14359
  state,
14182
14360
  "aria-current": state === "active" ? "step" : false,
14183
14361
  role: "listitem"
14184
- }, index > 0 && index <= steps && /* @__PURE__ */ React108.createElement(Stepper.ConnectorContainer, {
14362
+ }, index > 0 && index <= steps && /* @__PURE__ */ React110.createElement(Stepper.ConnectorContainer, {
14185
14363
  dense
14186
- }, /* @__PURE__ */ React108.createElement(Stepper.ConnectorContainer.Connector, {
14364
+ }, /* @__PURE__ */ React110.createElement(Stepper.ConnectorContainer.Connector, {
14187
14365
  completed: state === "completed" || state === "active"
14188
- })), /* @__PURE__ */ React108.createElement(Stepper.Step.Indicator, {
14366
+ })), /* @__PURE__ */ React110.createElement(Stepper.Step.Indicator, {
14189
14367
  state,
14190
14368
  dense
14191
14369
  }, index + 1), child.props.children);
@@ -14198,7 +14376,7 @@ Step2.displayName = "Stepper.Step";
14198
14376
  Stepper2.Step = Step2;
14199
14377
 
14200
14378
  // src/molecules/SwitchGroup/SwitchGroup.tsx
14201
- import React109, { useState as useState13 } from "react";
14379
+ import React111, { useState as useState13 } from "react";
14202
14380
  import { useId as useId16 } from "@react-aria/utils";
14203
14381
  var SwitchGroup = (_a) => {
14204
14382
  var _b = _a, {
@@ -14230,13 +14408,13 @@ var SwitchGroup = (_a) => {
14230
14408
  setSelectedItems(updated);
14231
14409
  onChange == null ? void 0 : onChange(updated);
14232
14410
  };
14233
- return /* @__PURE__ */ React109.createElement(LabelControl, __spreadProps(__spreadValues(__spreadValues({
14411
+ return /* @__PURE__ */ React111.createElement(LabelControl, __spreadProps(__spreadValues(__spreadValues({
14234
14412
  fieldset: true
14235
14413
  }, labelControlProps), errorProps), {
14236
14414
  className: "Aquarium-SwitchGroup"
14237
- }), /* @__PURE__ */ React109.createElement(InputGroup, {
14415
+ }), /* @__PURE__ */ React111.createElement(InputGroup, {
14238
14416
  cols
14239
- }, React109.Children.map(children, (c) => {
14417
+ }, React111.Children.map(children, (c) => {
14240
14418
  var _a3, _b2, _c, _d;
14241
14419
  if (!isComponentType(c, Switch2)) {
14242
14420
  return null;
@@ -14244,7 +14422,7 @@ var SwitchGroup = (_a) => {
14244
14422
  const str = (_a3 = c.props.value) == null ? void 0 : _a3.toString();
14245
14423
  const defaultChecked = defaultValue === void 0 ? void 0 : str !== void 0 && defaultValue.includes(str);
14246
14424
  const checked = value === void 0 ? void 0 : str !== void 0 && value.includes(str);
14247
- return React109.cloneElement(c, {
14425
+ return React111.cloneElement(c, {
14248
14426
  defaultChecked: (_b2 = c.props.defaultChecked) != null ? _b2 : defaultChecked,
14249
14427
  checked: (_c = c.props.checked) != null ? _c : checked,
14250
14428
  onChange: (_d = c.props.onChange) != null ? _d : handleChange,
@@ -14254,9 +14432,9 @@ var SwitchGroup = (_a) => {
14254
14432
  })));
14255
14433
  };
14256
14434
  var SwitchGroupSkeleton = ({ options = 2 }) => {
14257
- return /* @__PURE__ */ React109.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React109.createElement("div", {
14435
+ return /* @__PURE__ */ React111.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React111.createElement("div", {
14258
14436
  className: tw("flex flex-wrap flex-col gap-2")
14259
- }, Array.from({ length: options }).map((_, key) => /* @__PURE__ */ React109.createElement(Switch2.Skeleton, {
14437
+ }, Array.from({ length: options }).map((_, key) => /* @__PURE__ */ React111.createElement(Switch2.Skeleton, {
14260
14438
  key
14261
14439
  }))));
14262
14440
  };
@@ -14264,14 +14442,14 @@ SwitchGroup.Skeleton = SwitchGroupSkeleton;
14264
14442
  SwitchGroup.Skeleton.displayName = "SwitchGroup.Skeleton";
14265
14443
 
14266
14444
  // src/molecules/Textarea/Textarea.tsx
14267
- import React110, { useState as useState14 } from "react";
14445
+ import React112, { useState as useState14 } from "react";
14268
14446
  import { useId as useId17 } from "@react-aria/utils";
14269
14447
  import omit16 from "lodash/omit";
14270
14448
  import toString2 from "lodash/toString";
14271
- var TextareaBase = React110.forwardRef(
14449
+ var TextareaBase = React112.forwardRef(
14272
14450
  (_a, ref) => {
14273
14451
  var _b = _a, { readOnly = false, valid = true } = _b, props = __objRest(_b, ["readOnly", "valid"]);
14274
- return /* @__PURE__ */ React110.createElement("textarea", __spreadProps(__spreadValues({
14452
+ return /* @__PURE__ */ React112.createElement("textarea", __spreadProps(__spreadValues({
14275
14453
  ref
14276
14454
  }, props), {
14277
14455
  readOnly,
@@ -14279,10 +14457,10 @@ var TextareaBase = React110.forwardRef(
14279
14457
  }));
14280
14458
  }
14281
14459
  );
14282
- TextareaBase.Skeleton = () => /* @__PURE__ */ React110.createElement(Skeleton, {
14460
+ TextareaBase.Skeleton = () => /* @__PURE__ */ React112.createElement(Skeleton, {
14283
14461
  height: 58
14284
14462
  });
14285
- var Textarea = React110.forwardRef((props, ref) => {
14463
+ var Textarea = React112.forwardRef((props, ref) => {
14286
14464
  var _a, _b, _c;
14287
14465
  const [value, setValue] = useState14((_b = (_a = props.value) != null ? _a : props.defaultValue) != null ? _b : "");
14288
14466
  const defaultId = useId17();
@@ -14291,14 +14469,14 @@ var Textarea = React110.forwardRef((props, ref) => {
14291
14469
  const errorProps = props.valid === false ? { "aria-invalid": true, "aria-describedby": errorMessageId } : {};
14292
14470
  const _d = getLabelControlProps(props), { "data-testid": dataTestId } = _d, labelControlProps = __objRest(_d, ["data-testid"]);
14293
14471
  const baseProps = omit16(props, Object.keys(labelControlProps));
14294
- return /* @__PURE__ */ React110.createElement(LabelControl, __spreadProps(__spreadValues({
14472
+ return /* @__PURE__ */ React112.createElement(LabelControl, __spreadProps(__spreadValues({
14295
14473
  id: `${id}-label`,
14296
14474
  htmlFor: id,
14297
14475
  messageId: errorMessageId,
14298
14476
  length: value !== void 0 ? toString2(value).length : void 0
14299
14477
  }, labelControlProps), {
14300
14478
  className: "Aquarium-Textarea"
14301
- }), /* @__PURE__ */ React110.createElement(TextareaBase, __spreadProps(__spreadValues(__spreadValues({
14479
+ }), /* @__PURE__ */ React112.createElement(TextareaBase, __spreadProps(__spreadValues(__spreadValues({
14302
14480
  ref
14303
14481
  }, baseProps), errorProps), {
14304
14482
  id,
@@ -14315,48 +14493,48 @@ var Textarea = React110.forwardRef((props, ref) => {
14315
14493
  })));
14316
14494
  });
14317
14495
  Textarea.displayName = "Textarea";
14318
- var TextAreaSkeleton = () => /* @__PURE__ */ React110.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React110.createElement(TextareaBase.Skeleton, null));
14496
+ var TextAreaSkeleton = () => /* @__PURE__ */ React112.createElement(LabelControl.Skeleton, null, /* @__PURE__ */ React112.createElement(TextareaBase.Skeleton, null));
14319
14497
  Textarea.Skeleton = TextAreaSkeleton;
14320
14498
  Textarea.Skeleton.displayName = "Textarea.Skeleton";
14321
14499
 
14322
14500
  // src/molecules/Timeline/Timeline.tsx
14323
- import React112 from "react";
14501
+ import React114 from "react";
14324
14502
 
14325
14503
  // src/atoms/Timeline/Timeline.tsx
14326
- import React111 from "react";
14504
+ import React113 from "react";
14327
14505
  var Timeline = (_a) => {
14328
14506
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14329
- return /* @__PURE__ */ React111.createElement("div", __spreadProps(__spreadValues({}, rest), {
14507
+ return /* @__PURE__ */ React113.createElement("div", __spreadProps(__spreadValues({}, rest), {
14330
14508
  className: classNames(tw("grid grid-cols-[16px_1fr] gap-x-4"), className)
14331
14509
  }));
14332
14510
  };
14333
14511
  var Content2 = (_a) => {
14334
14512
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14335
- return /* @__PURE__ */ React111.createElement("div", __spreadProps(__spreadValues({}, rest), {
14513
+ return /* @__PURE__ */ React113.createElement("div", __spreadProps(__spreadValues({}, rest), {
14336
14514
  className: classNames(tw("pb-6"), className)
14337
14515
  }));
14338
14516
  };
14339
14517
  var Separator2 = (_a) => {
14340
14518
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14341
- return /* @__PURE__ */ React111.createElement("div", __spreadProps(__spreadValues({}, rest), {
14519
+ return /* @__PURE__ */ React113.createElement("div", __spreadProps(__spreadValues({}, rest), {
14342
14520
  className: classNames(tw("flex items-center justify-center h-5 w-5"), className)
14343
14521
  }));
14344
14522
  };
14345
14523
  var LineContainer = (_a) => {
14346
14524
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14347
- return /* @__PURE__ */ React111.createElement("div", __spreadProps(__spreadValues({}, rest), {
14525
+ return /* @__PURE__ */ React113.createElement("div", __spreadProps(__spreadValues({}, rest), {
14348
14526
  className: classNames(tw("flex justify-center py-1"), className)
14349
14527
  }));
14350
14528
  };
14351
14529
  var Line = (_a) => {
14352
14530
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14353
- return /* @__PURE__ */ React111.createElement("div", __spreadProps(__spreadValues({}, rest), {
14531
+ return /* @__PURE__ */ React113.createElement("div", __spreadProps(__spreadValues({}, rest), {
14354
14532
  className: classNames(tw("w-1 bg-grey-5 h-full justify-self-center"), className)
14355
14533
  }));
14356
14534
  };
14357
14535
  var Dot = (_a) => {
14358
14536
  var _b = _a, { className } = _b, rest = __objRest(_b, ["className"]);
14359
- return /* @__PURE__ */ React111.createElement("div", __spreadProps(__spreadValues({}, rest), {
14537
+ return /* @__PURE__ */ React113.createElement("div", __spreadProps(__spreadValues({}, rest), {
14360
14538
  className: classNames(tw("bg-grey-30 h-[6px] w-[6px] rounded"), className)
14361
14539
  }));
14362
14540
  };
@@ -14371,54 +14549,54 @@ var import_error5 = __toESM(require_error());
14371
14549
  var import_time2 = __toESM(require_time());
14372
14550
  var import_warningSign5 = __toESM(require_warningSign());
14373
14551
  var TimelineItem = () => null;
14374
- var Timeline2 = ({ children }) => /* @__PURE__ */ React112.createElement("div", {
14552
+ var Timeline2 = ({ children }) => /* @__PURE__ */ React114.createElement("div", {
14375
14553
  className: "Aquarium-Timeline"
14376
- }, React112.Children.map(children, (item) => {
14554
+ }, React114.Children.map(children, (item) => {
14377
14555
  if (!isComponentType(item, TimelineItem)) {
14378
14556
  throw new Error("<Timeline> can only have <Timeline.Item> components as children");
14379
14557
  } else {
14380
14558
  const { props, key } = item;
14381
- return /* @__PURE__ */ React112.createElement(Timeline, {
14559
+ return /* @__PURE__ */ React114.createElement(Timeline, {
14382
14560
  key: key != null ? key : props.title
14383
- }, /* @__PURE__ */ React112.createElement(Timeline.Separator, null, props.variant === "error" ? /* @__PURE__ */ React112.createElement(Icon, {
14561
+ }, /* @__PURE__ */ React114.createElement(Timeline.Separator, null, props.variant === "error" ? /* @__PURE__ */ React114.createElement(Icon, {
14384
14562
  icon: import_error5.default,
14385
14563
  color: "error-30"
14386
- }) : props.variant === "warning" ? /* @__PURE__ */ React112.createElement(Icon, {
14564
+ }) : props.variant === "warning" ? /* @__PURE__ */ React114.createElement(Icon, {
14387
14565
  icon: import_warningSign5.default,
14388
14566
  color: "warning-30"
14389
- }) : props.variant === "info" ? /* @__PURE__ */ React112.createElement(Icon, {
14567
+ }) : props.variant === "info" ? /* @__PURE__ */ React114.createElement(Icon, {
14390
14568
  icon: import_time2.default,
14391
14569
  color: "info-30"
14392
- }) : /* @__PURE__ */ React112.createElement(Timeline.Separator.Dot, null)), /* @__PURE__ */ React112.createElement(Typography2.Caption, {
14570
+ }) : /* @__PURE__ */ React114.createElement(Timeline.Separator.Dot, null)), /* @__PURE__ */ React114.createElement(Typography2.Caption, {
14393
14571
  color: "grey-50"
14394
- }, props.title), /* @__PURE__ */ React112.createElement(Timeline.LineContainer, null, /* @__PURE__ */ React112.createElement(Timeline.LineContainer.Line, null)), /* @__PURE__ */ React112.createElement(Timeline.Content, null, /* @__PURE__ */ React112.createElement(Typography2.Small, null, props.children)));
14572
+ }, props.title), /* @__PURE__ */ React114.createElement(Timeline.LineContainer, null, /* @__PURE__ */ React114.createElement(Timeline.LineContainer.Line, null)), /* @__PURE__ */ React114.createElement(Timeline.Content, null, /* @__PURE__ */ React114.createElement(Typography2.Small, null, props.children)));
14395
14573
  }
14396
14574
  }));
14397
- var TimelineItemSkeleton = () => /* @__PURE__ */ React112.createElement(Timeline, null, /* @__PURE__ */ React112.createElement(Timeline.Separator, null, /* @__PURE__ */ React112.createElement(Skeleton, {
14575
+ var TimelineItemSkeleton = () => /* @__PURE__ */ React114.createElement(Timeline, null, /* @__PURE__ */ React114.createElement(Timeline.Separator, null, /* @__PURE__ */ React114.createElement(Skeleton, {
14398
14576
  width: 6,
14399
14577
  height: 6,
14400
14578
  rounded: true
14401
- })), /* @__PURE__ */ React112.createElement(Skeleton, {
14579
+ })), /* @__PURE__ */ React114.createElement(Skeleton, {
14402
14580
  height: 12,
14403
14581
  width: 120
14404
- }), /* @__PURE__ */ React112.createElement(Timeline.LineContainer, null, /* @__PURE__ */ React112.createElement(Skeleton, {
14582
+ }), /* @__PURE__ */ React114.createElement(Timeline.LineContainer, null, /* @__PURE__ */ React114.createElement(Skeleton, {
14405
14583
  width: 2,
14406
14584
  height: "100%"
14407
- })), /* @__PURE__ */ React112.createElement(Timeline.Content, null, /* @__PURE__ */ React112.createElement(Box, {
14585
+ })), /* @__PURE__ */ React114.createElement(Timeline.Content, null, /* @__PURE__ */ React114.createElement(Box, {
14408
14586
  display: "flex",
14409
14587
  flexDirection: "column",
14410
14588
  gap: "3"
14411
- }, /* @__PURE__ */ React112.createElement(Skeleton, {
14589
+ }, /* @__PURE__ */ React114.createElement(Skeleton, {
14412
14590
  height: 32,
14413
14591
  width: "100%"
14414
- }), /* @__PURE__ */ React112.createElement(Skeleton, {
14592
+ }), /* @__PURE__ */ React114.createElement(Skeleton, {
14415
14593
  height: 32,
14416
14594
  width: "73%"
14417
- }), /* @__PURE__ */ React112.createElement(Skeleton, {
14595
+ }), /* @__PURE__ */ React114.createElement(Skeleton, {
14418
14596
  height: 32,
14419
14597
  width: "80%"
14420
14598
  }))));
14421
- var TimelineSkeleton = ({ items = 3 }) => /* @__PURE__ */ React112.createElement("div", null, Array.from({ length: items }).map((_, key) => /* @__PURE__ */ React112.createElement(TimelineItemSkeleton, {
14599
+ var TimelineSkeleton = ({ items = 3 }) => /* @__PURE__ */ React114.createElement("div", null, Array.from({ length: items }).map((_, key) => /* @__PURE__ */ React114.createElement(TimelineItemSkeleton, {
14422
14600
  key
14423
14601
  })));
14424
14602
  Timeline2.Item = TimelineItem;
@@ -14426,9 +14604,9 @@ Timeline2.Skeleton = TimelineSkeleton;
14426
14604
  Timeline2.Skeleton.displayName = "Timeline.Skeleton";
14427
14605
 
14428
14606
  // src/utils/table/useTableSelect.ts
14429
- import React113 from "react";
14607
+ import React115 from "react";
14430
14608
  var useTableSelect = (data, { key }) => {
14431
- const [selected, setSelected] = React113.useState([]);
14609
+ const [selected, setSelected] = React115.useState([]);
14432
14610
  const allSelected = selected.length === data.length;
14433
14611
  const isSelected = (dot) => selected.includes(dot[key]);
14434
14612
  const selectAll = () => setSelected(data.map((dot) => dot[key]));
@@ -14624,7 +14802,7 @@ export {
14624
14802
  LabelControl,
14625
14803
  LineClamp2 as LineClamp,
14626
14804
  Link2 as Link,
14627
- List2 as List,
14805
+ List,
14628
14806
  ListItem,
14629
14807
  Modal2 as Modal,
14630
14808
  ModalTab,
@@ -14681,6 +14859,7 @@ export {
14681
14859
  ToastProvider,
14682
14860
  Tooltip,
14683
14861
  Typography2 as Typography,
14862
+ areRowsGrouped,
14684
14863
  asButton,
14685
14864
  asCrumb,
14686
14865
  asPopoverButton,