@boomerang-io/carbon-addons-boomerang-react 4.6.21-beta.4 → 4.6.21-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -38,7 +38,7 @@ function AdvantageSideNav(props) {
|
|
|
38
38
|
const [activeMenu, setActiveMenu] = React__default.default.useState(false);
|
|
39
39
|
const isMenuOpen = isOpen || activeMenu;
|
|
40
40
|
const windowLocation = window.location;
|
|
41
|
-
const
|
|
41
|
+
const historyy = reactRouterDom.useHistory();
|
|
42
42
|
const isPartnerUser = user?.type === UserType.USER_PLATFORM_ROLE.Partner;
|
|
43
43
|
const joinButtontitle = showSelectTeamPurpose ? "Create Team" : "Create or Join Team";
|
|
44
44
|
const hamburguerMenu = document.getElementById("header-sidenav-menu-button");
|
|
@@ -230,18 +230,11 @@ function AdvantageSideNav(props) {
|
|
|
230
230
|
handleDocumentCollectionsClick();
|
|
231
231
|
} }, "Document Collections")) : null,
|
|
232
232
|
showSecondDivider ? React__default.default.createElement(react.SideNavDivider, null) : null,
|
|
233
|
-
catalogNavlink ? (React__default.default.createElement(
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
// isActive={windowLocation.href.includes(`${baseEnvUrl}/catalog`)}
|
|
239
|
-
// // href={catalogNavlink}
|
|
240
|
-
// renderIcon={Catalog}
|
|
241
|
-
// >
|
|
242
|
-
// Catalog
|
|
243
|
-
// </SideNavLink>
|
|
244
|
-
) : null,
|
|
233
|
+
catalogNavlink ? (React__default.default.createElement(react.SideNavLink, { "data-testid": "sidenav-catalog-link", isActive: location.pathname.includes("/catalog"), renderIcon: icons.Catalog, href: catalogNavlink, onClick: (e) => {
|
|
234
|
+
console.log("sfsf");
|
|
235
|
+
e.preventDefault();
|
|
236
|
+
historyy.push(catalogNavlink);
|
|
237
|
+
} }, "Catalog")) : null,
|
|
245
238
|
settingsLink ? (React__default.default.createElement(react.SideNavLink, { "data-testid": "sidenav-settings-link", renderIcon: icons.Settings, href: settingsLink, onClick: (e) => {
|
|
246
239
|
handleSettingsClick();
|
|
247
240
|
} }, "Settings")) : null,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { useHistory } from 'react-router-dom';
|
|
3
3
|
import cx from 'classnames';
|
|
4
4
|
import { SideNavLink, SideNav, SideNavItems, SideNavDivider, Tag } from '@carbon/react';
|
|
5
5
|
import TooltipHover from '../TooltipHover/TooltipHover.js';
|
|
@@ -29,7 +29,7 @@ function AdvantageSideNav(props) {
|
|
|
29
29
|
const [activeMenu, setActiveMenu] = React.useState(false);
|
|
30
30
|
const isMenuOpen = isOpen || activeMenu;
|
|
31
31
|
const windowLocation = window.location;
|
|
32
|
-
const
|
|
32
|
+
const historyy = useHistory();
|
|
33
33
|
const isPartnerUser = user?.type === USER_PLATFORM_ROLE.Partner;
|
|
34
34
|
const joinButtontitle = showSelectTeamPurpose ? "Create Team" : "Create or Join Team";
|
|
35
35
|
const hamburguerMenu = document.getElementById("header-sidenav-menu-button");
|
|
@@ -221,18 +221,11 @@ function AdvantageSideNav(props) {
|
|
|
221
221
|
handleDocumentCollectionsClick();
|
|
222
222
|
} }, "Document Collections")) : null,
|
|
223
223
|
showSecondDivider ? React.createElement(SideNavDivider, null) : null,
|
|
224
|
-
catalogNavlink ? (React.createElement(
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
// isActive={windowLocation.href.includes(`${baseEnvUrl}/catalog`)}
|
|
230
|
-
// // href={catalogNavlink}
|
|
231
|
-
// renderIcon={Catalog}
|
|
232
|
-
// >
|
|
233
|
-
// Catalog
|
|
234
|
-
// </SideNavLink>
|
|
235
|
-
) : null,
|
|
224
|
+
catalogNavlink ? (React.createElement(SideNavLink, { "data-testid": "sidenav-catalog-link", isActive: location.pathname.includes("/catalog"), renderIcon: Catalog, href: catalogNavlink, onClick: (e) => {
|
|
225
|
+
console.log("sfsf");
|
|
226
|
+
e.preventDefault();
|
|
227
|
+
historyy.push(catalogNavlink);
|
|
228
|
+
} }, "Catalog")) : null,
|
|
236
229
|
settingsLink ? (React.createElement(SideNavLink, { "data-testid": "sidenav-settings-link", renderIcon: Settings, href: settingsLink, onClick: (e) => {
|
|
237
230
|
handleSettingsClick();
|
|
238
231
|
} }, "Settings")) : null,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@boomerang-io/carbon-addons-boomerang-react",
|
|
3
3
|
"description": "Carbon Addons for Boomerang apps",
|
|
4
|
-
"version": "4.6.21-beta.
|
|
4
|
+
"version": "4.6.21-beta.7",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Tim Bula",
|
|
7
7
|
"email": "timrbula@gmail.com"
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"react": "^17.0.0 || ^16.14.0",
|
|
74
74
|
"react-dom": "^17.0.0 || ^16.14.0",
|
|
75
75
|
"react-query": "^3.34.12",
|
|
76
|
-
"react-router-dom": "^
|
|
76
|
+
"react-router-dom": "^6.0.0",
|
|
77
77
|
"yup": ">=0.32.11"
|
|
78
78
|
},
|
|
79
79
|
"devDependencies": {
|