sixseconds-modules 1.6.15 → 1.6.17
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/components/header/appMenus.d.ts +1 -0
- package/dist/index.cjs.js +15 -5
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +15 -5
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -8838,7 +8838,7 @@ const UserProfile = ({ t: t2, userData, setInitialState, extraMenuOptions, route
|
|
|
8838
8838
|
direction: "row",
|
|
8839
8839
|
spacing: 1,
|
|
8840
8840
|
alignItems: "center",
|
|
8841
|
-
onClick: () => handleRedirection2(userData?.appName, SSO_ROUTES().editProfile),
|
|
8841
|
+
onClick: () => handleRedirection2(userData?.appName, SSO_ROUTES(userData?.appName).editProfile),
|
|
8842
8842
|
sx: { color: "#1A1919", textDecoration: "none" },
|
|
8843
8843
|
children: [
|
|
8844
8844
|
/* @__PURE__ */ jsx(SVG.UserEdit, {}),
|
|
@@ -10302,13 +10302,22 @@ const Notification = ({ setInitialState, notificationAccessApps, initialState, t
|
|
|
10302
10302
|
}
|
|
10303
10303
|
) });
|
|
10304
10304
|
};
|
|
10305
|
-
const AppMenus = ({ menuItems, setInitialState, t: t2, appName }) => {
|
|
10305
|
+
const AppMenus = ({ menuItems, setInitialState, t: t2, appName, router }) => {
|
|
10306
|
+
const handleRedirection2 = (appName2, url2, type) => {
|
|
10307
|
+
if (router && appName2 === APP_NAMES.sso) {
|
|
10308
|
+
router.push(url2);
|
|
10309
|
+
} else {
|
|
10310
|
+
if (type === "app") {
|
|
10311
|
+
window.open(`${url2}?source=${appName2}`, "_blank");
|
|
10312
|
+
} else {
|
|
10313
|
+
router.push(`${url2}?source=${appName2}`);
|
|
10314
|
+
}
|
|
10315
|
+
}
|
|
10316
|
+
};
|
|
10306
10317
|
return /* @__PURE__ */ jsx(ClickAwayListener, { onClickAway: () => handleCloseUtil(setInitialState), children: /* @__PURE__ */ jsx(Box, { sx: { p: 2 }, children: /* @__PURE__ */ jsx(Grid, { container: true, rowGap: 3, children: menuItems.map((item, index) => /* @__PURE__ */ jsx(
|
|
10307
10318
|
Grid,
|
|
10308
10319
|
{
|
|
10309
|
-
|
|
10310
|
-
href: item.link + (appName === APP_NAMES.sso ? "" : `?source=${appName}`),
|
|
10311
|
-
target: item.type === "tab" ? "_self" : "_blank",
|
|
10320
|
+
onClick: () => handleRedirection2(appName, item.link, item.type),
|
|
10312
10321
|
item: true,
|
|
10313
10322
|
md: 4,
|
|
10314
10323
|
xs: 6,
|
|
@@ -10541,6 +10550,7 @@ const Header = ({
|
|
|
10541
10550
|
state.toggles.appMenus && userData?.appAccess?.length && /* @__PURE__ */ jsx(Box, { className: "profile headerMenu", sx: { width: "400px !important", p: 1 }, children: /* @__PURE__ */ jsx(
|
|
10542
10551
|
AppMenus,
|
|
10543
10552
|
{
|
|
10553
|
+
router,
|
|
10544
10554
|
t,
|
|
10545
10555
|
appName: userData?.appName,
|
|
10546
10556
|
menuItems: userData?.appAccess,
|