sevago-sso-fe 1.0.35 → 1.0.37
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.
|
@@ -10,7 +10,9 @@ export interface AppGridProps {
|
|
|
10
10
|
iconShadow?: string;
|
|
11
11
|
gap?: number | string;
|
|
12
12
|
titleVariant?: "subtitle1" | "body1" | "caption";
|
|
13
|
+
captionVariant?: "caption" | "body2";
|
|
13
14
|
titleColor?: string;
|
|
15
|
+
captionColor?: string;
|
|
14
16
|
selectedAppId?: string;
|
|
15
17
|
showPagination?: boolean;
|
|
16
18
|
}
|
package/dist/index.cjs.js
CHANGED
|
@@ -27674,7 +27674,8 @@ const TimeAgoContentComponent = ({ time: time2, content, height: height2 = HEIGH
|
|
|
27674
27674
|
const AppsSidebar = ({
|
|
27675
27675
|
isOpen,
|
|
27676
27676
|
onClose,
|
|
27677
|
-
position = "left"
|
|
27677
|
+
position = "left",
|
|
27678
|
+
blacklist
|
|
27678
27679
|
}) => {
|
|
27679
27680
|
const theme = useTheme();
|
|
27680
27681
|
const navigate = reactRouterDom.useNavigate();
|
|
@@ -27684,6 +27685,16 @@ const AppsSidebar = ({
|
|
|
27684
27685
|
const { setActiveExpandMenu } = useSidebar();
|
|
27685
27686
|
const { palette } = useTheme();
|
|
27686
27687
|
if (!isOpen) return null;
|
|
27688
|
+
const displayApps = React.useMemo(() => {
|
|
27689
|
+
if (!blacklist || blacklist.length === 0) return allApps;
|
|
27690
|
+
const matched = allApps.filter(
|
|
27691
|
+
(a) => a.path ? blacklist.includes(a.path) : false
|
|
27692
|
+
);
|
|
27693
|
+
return matched.length > 0 ? matched : allApps;
|
|
27694
|
+
}, [allApps, blacklist]);
|
|
27695
|
+
const groups = React.useMemo(() => {
|
|
27696
|
+
return Array.from(new Set(displayApps.map((v) => v.group)));
|
|
27697
|
+
}, [displayApps]);
|
|
27687
27698
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
27688
27699
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
27689
27700
|
material.Box,
|
|
@@ -27760,43 +27771,7 @@ const AppsSidebar = ({
|
|
|
27760
27771
|
]
|
|
27761
27772
|
}
|
|
27762
27773
|
),
|
|
27763
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
27764
|
-
material.Box,
|
|
27765
|
-
{
|
|
27766
|
-
sx: {
|
|
27767
|
-
gap: PADDING_GAP_ITEM,
|
|
27768
|
-
display: "flex",
|
|
27769
|
-
flexDirection: "column"
|
|
27770
|
-
},
|
|
27771
|
-
children: [
|
|
27772
|
-
/* @__PURE__ */ jsxRuntime.jsx(material.Typography, { variant: "subtitle2", children: "Workflow Engine" }),
|
|
27773
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
27774
|
-
AppGrid,
|
|
27775
|
-
{
|
|
27776
|
-
apps: allApps.filter(
|
|
27777
|
-
(app) => app.group === AppGroup.WORKFLOW_ENGINE
|
|
27778
|
-
),
|
|
27779
|
-
columns: 4,
|
|
27780
|
-
iconSize: 60,
|
|
27781
|
-
iconRadius: 5.5,
|
|
27782
|
-
gap: PADDING_GAP_ITEM,
|
|
27783
|
-
titleVariant: "body1",
|
|
27784
|
-
titleColor: theme.palette.grey[800],
|
|
27785
|
-
captionColor: theme.palette.grey[600],
|
|
27786
|
-
selectedAppId: currentApp?.path,
|
|
27787
|
-
onClickItem: async (app) => {
|
|
27788
|
-
await dispatch(
|
|
27789
|
-
ACTION_ACCOUNT.updateCurrentAccess(app.path)
|
|
27790
|
-
).unwrap();
|
|
27791
|
-
setActiveExpandMenu(null);
|
|
27792
|
-
onClose();
|
|
27793
|
-
}
|
|
27794
|
-
}
|
|
27795
|
-
)
|
|
27796
|
-
]
|
|
27797
|
-
}
|
|
27798
|
-
),
|
|
27799
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
27774
|
+
groups.map((group) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
27800
27775
|
material.Box,
|
|
27801
27776
|
{
|
|
27802
27777
|
sx: {
|
|
@@ -27805,16 +27780,17 @@ const AppsSidebar = ({
|
|
|
27805
27780
|
flexDirection: "column"
|
|
27806
27781
|
},
|
|
27807
27782
|
children: [
|
|
27808
|
-
/* @__PURE__ */ jsxRuntime.jsx(material.Typography, { variant: "subtitle2", children: "
|
|
27783
|
+
/* @__PURE__ */ jsxRuntime.jsx(material.Typography, { variant: "subtitle2", children: group === AppGroup.PLATFORM_AND_INFO ? "Platform & Info" : group }),
|
|
27809
27784
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
27810
27785
|
AppGrid,
|
|
27811
27786
|
{
|
|
27812
|
-
apps:
|
|
27787
|
+
apps: displayApps.filter((app) => app.group === group),
|
|
27813
27788
|
columns: 4,
|
|
27814
27789
|
iconSize: 60,
|
|
27815
27790
|
iconRadius: 5.5,
|
|
27816
27791
|
gap: PADDING_GAP_ITEM,
|
|
27817
27792
|
titleVariant: "body1",
|
|
27793
|
+
captionVariant: "caption",
|
|
27818
27794
|
titleColor: theme.palette.grey[800],
|
|
27819
27795
|
captionColor: theme.palette.grey[600],
|
|
27820
27796
|
selectedAppId: currentApp?.path,
|
|
@@ -27828,44 +27804,9 @@ const AppsSidebar = ({
|
|
|
27828
27804
|
}
|
|
27829
27805
|
)
|
|
27830
27806
|
]
|
|
27831
|
-
}
|
|
27832
|
-
|
|
27833
|
-
|
|
27834
|
-
material.Box,
|
|
27835
|
-
{
|
|
27836
|
-
sx: {
|
|
27837
|
-
gap: PADDING_GAP_ITEM,
|
|
27838
|
-
display: "flex",
|
|
27839
|
-
flexDirection: "column"
|
|
27840
|
-
},
|
|
27841
|
-
children: [
|
|
27842
|
-
/* @__PURE__ */ jsxRuntime.jsx(material.Typography, { variant: "subtitle2", children: "Platform Info" }),
|
|
27843
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
27844
|
-
AppGrid,
|
|
27845
|
-
{
|
|
27846
|
-
apps: allApps.filter(
|
|
27847
|
-
(app) => app.group === AppGroup.PLATFORM_AND_INFO
|
|
27848
|
-
),
|
|
27849
|
-
columns: 4,
|
|
27850
|
-
iconSize: 60,
|
|
27851
|
-
iconRadius: 5.5,
|
|
27852
|
-
gap: PADDING_GAP_ITEM,
|
|
27853
|
-
titleVariant: "body1",
|
|
27854
|
-
titleColor: theme.palette.grey[800],
|
|
27855
|
-
captionColor: theme.palette.grey[600],
|
|
27856
|
-
selectedAppId: currentApp?.path,
|
|
27857
|
-
onClickItem: async (app) => {
|
|
27858
|
-
await dispatch(
|
|
27859
|
-
ACTION_ACCOUNT.updateCurrentAccess(app.path)
|
|
27860
|
-
).unwrap();
|
|
27861
|
-
setActiveExpandMenu(null);
|
|
27862
|
-
onClose();
|
|
27863
|
-
}
|
|
27864
|
-
}
|
|
27865
|
-
)
|
|
27866
|
-
]
|
|
27867
|
-
}
|
|
27868
|
-
)
|
|
27807
|
+
},
|
|
27808
|
+
group
|
|
27809
|
+
))
|
|
27869
27810
|
]
|
|
27870
27811
|
}
|
|
27871
27812
|
)
|