wcz-test 4.6.1 → 4.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1042,7 +1042,7 @@ var TypographyWithIcon = ({ startIcon, endIcon, children, sx, gutterBottom, ...p
1042
1042
  import { Box, Stack as Stack2, Typography as Typography2 } from "@mui/material";
1043
1043
  import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
1044
1044
  var PageHeader = ({ title, action, sx }) => {
1045
- return /* @__PURE__ */ jsxs2(Stack2, { direction: "row", justifyContent: "space-between", alignItems: "center", sx: { ...sx }, children: [
1045
+ return /* @__PURE__ */ jsxs2(Stack2, { direction: "row", justifyContent: "space-between", alignItems: "center", sx: { py: 2, ...sx }, children: [
1046
1046
  /* @__PURE__ */ jsx2(Typography2, { variant: "h4", fontWeight: 600, children: title }),
1047
1047
  action && /* @__PURE__ */ jsx2(Box, { children: action })
1048
1048
  ] });
@@ -2813,7 +2813,7 @@ var MiniPopover = ({ open, anchorEl, children }) => /* @__PURE__ */ jsx23(
2813
2813
  )
2814
2814
  }
2815
2815
  );
2816
- var NavigationListItem = ({ item, isOpen, selected, disabled, collapsed, isSidebarFullyExpanded = true, isSidebarFullyCollapsed, onClick, renderNested }) => {
2816
+ var NavigationListItem = ({ item, isOpen, selected, disabled, collapsed, isSidebarFullyExpanded = true, isSidebarFullyCollapsed, onClick, renderNested, onClose }) => {
2817
2817
  const [hoveredPopoverItem, setHoveredPopoverItem] = useState7(null);
2818
2818
  const [anchorElement, setAnchorElement] = useState7(null);
2819
2819
  const chevronSx = useMemo4(() => {
@@ -2874,6 +2874,7 @@ var NavigationListItem = ({ item, isOpen, selected, disabled, collapsed, isSideb
2874
2874
  href: item.href,
2875
2875
  params: item.params,
2876
2876
  search: item.search,
2877
+ onClick: onClose,
2877
2878
  children: buttonContent
2878
2879
  }
2879
2880
  ),
@@ -2892,7 +2893,7 @@ import { jsx as jsx24 } from "react/jsx-runtime";
2892
2893
  var isPageItem = (item) => !("kind" in item);
2893
2894
  var isDivider = (item) => "kind" in item && item.kind === "divider";
2894
2895
  var isHeader = (item) => "kind" in item && item.kind === "header";
2895
- var NavigationList = ({ subNavigation, depth = 0, collapsed, isPopover, isSidebarFullyExpanded = true, isSidebarFullyCollapsed, expandedWidth, renderItem, activePath, onNavigate }) => {
2896
+ var NavigationList = ({ subNavigation, depth = 0, collapsed, isPopover, isSidebarFullyExpanded = true, isSidebarFullyCollapsed, expandedWidth, renderItem, activePath, onNavigate, onClose }) => {
2896
2897
  const [openKeys, setOpenKeys] = useState8([]);
2897
2898
  useEffect5(() => {
2898
2899
  if (collapsed) setOpenKeys([]);
@@ -2906,7 +2907,8 @@ var NavigationList = ({ subNavigation, depth = 0, collapsed, isPopover, isSideba
2906
2907
  isPopover: collapsed,
2907
2908
  expandedWidth,
2908
2909
  activePath,
2909
- onNavigate
2910
+ onNavigate,
2911
+ onClose
2910
2912
  }
2911
2913
  );
2912
2914
  const filteredNavigation = subNavigation.filter((nav) => !nav.hidden);
@@ -2962,7 +2964,8 @@ var NavigationList = ({ subNavigation, depth = 0, collapsed, isPopover, isSideba
2962
2964
  isSidebarFullyExpanded,
2963
2965
  isSidebarFullyCollapsed,
2964
2966
  onClick: navItem.children && !collapsed ? () => toggleKey(uniqueItemKey) : void 0,
2965
- renderNested
2967
+ renderNested,
2968
+ onClose
2966
2969
  },
2967
2970
  key
2968
2971
  );
@@ -2975,7 +2978,7 @@ var NavigationList = ({ subNavigation, depth = 0, collapsed, isPopover, isSideba
2975
2978
  import { jsx as jsx25 } from "react/jsx-runtime";
2976
2979
  var MINI_WIDTH = 84;
2977
2980
  var EXPANDED_WIDTH = 320;
2978
- var TOOLBAR_HEIGHT = 65;
2981
+ var TOOLBAR_HEIGHT = 64;
2979
2982
  var NavigationRail = ({ navigation, expanded, setExpanded }) => {
2980
2983
  const navigate = useNavigate();
2981
2984
  const routerState = useRouterState2();
@@ -3004,7 +3007,8 @@ var NavigationRail = ({ navigation, expanded, setExpanded }) => {
3004
3007
  isSidebarFullyCollapsed: !expanded,
3005
3008
  expandedWidth: EXPANDED_WIDTH,
3006
3009
  activePath: routerState.location.pathname,
3007
- onNavigate: navigate
3010
+ onNavigate: navigate,
3011
+ onClose: !showPermanent ? () => setExpanded(false) : void 0
3008
3012
  }
3009
3013
  )
3010
3014
  }
@@ -3020,7 +3024,9 @@ var NavigationRail = ({ navigation, expanded, setExpanded }) => {
3020
3024
  position: "absolute",
3021
3025
  top: `${TOOLBAR_HEIGHT}px`,
3022
3026
  height: `calc(100% - ${TOOLBAR_HEIGHT}px)`,
3023
- width: expanded ? EXPANDED_WIDTH : MINI_WIDTH
3027
+ width: expanded ? EXPANDED_WIDTH : MINI_WIDTH,
3028
+ borderTop: "1px solid",
3029
+ borderColor: theme.vars?.palette.divider
3024
3030
  }
3025
3031
  },
3026
3032
  children: drawerContent(!expanded)