@boomerang-io/carbon-addons-boomerang-react 4.6.5-beta.30 → 4.6.5-beta.32

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.
@@ -59,7 +59,6 @@ function Header(props) {
59
59
  const { productName, baseEnvUrl, baseServicesUrl, carbonTheme = "g10", className, navLinks, platform, prefixName = "", rightPanel, skipToContentProps, templateMeteringEvent, triggerEvent, userTeams, } = props;
60
60
  console.log("platform", platform);
61
61
  console.log("enabled", platform?.instanceSwitcherEnabled);
62
- console.log("instances", platform?.instances);
63
62
  return (React__default.default.createElement(React__default.default.Fragment, null,
64
63
  React__default.default.createElement(react.Theme, { theme: carbonTheme },
65
64
  React__default.default.createElement(react.Header, { "aria-label": "App navigation header", className: className },
@@ -83,8 +82,9 @@ function Header(props) {
83
82
  function InstanceSwitcherMenu(props) {
84
83
  // const currentURL= window.location.href;
85
84
  const currentURL = "https://canada.ica.ibm.com";
86
- console.log("currentURL.includes(item.instanceName)-1", currentURL.includes("Canada"));
87
- console.log("currentURL.includes(item.instanceName)-2", currentURL.includes("canada"));
85
+ console.log("currentURL.includes((item.instanceName).toLowerCase())", currentURL.includes(("Canada").toLowerCase()));
86
+ console.log("lowerCase", "Canada".toLowerCase());
87
+ console.log("string lowercase", String("Canada").toLowerCase());
88
88
  const { isOpen, toggleActive, ref } = useHeaderMenu.default(MenuButtonId.InstanceSwitcher);
89
89
  if (!props.enabled) {
90
90
  return null;
@@ -96,7 +96,7 @@ function InstanceSwitcherMenu(props) {
96
96
  ? props.menuItems.map((item) => (React__default.default.createElement(react.HeaderMenuItem, { "aria-label": `Instance Switcher for ${item.instanceName}`, "data-testid": "header-menu-instance-switcher", href: item.url, isCurrentPage: window?.location?.href && item.url ? window.location.href.startsWith(item.url) : false, key: item.instanceName, target: "_self", rel: "noopener noreferrer" },
97
97
  React__default.default.createElement("div", null,
98
98
  React__default.default.createElement("span", null, item.instanceName),
99
- currentURL.includes(item.instanceName) ? React__default.default.createElement("span", { className: instanceCheckMarkStyle },
99
+ currentURL.includes((item.instanceName).toLowerCase()) ? React__default.default.createElement("span", { className: instanceCheckMarkStyle },
100
100
  React__default.default.createElement(icons.Checkmark, null),
101
101
  " ") : ""))))
102
102
  : null)) : null));
@@ -51,7 +51,6 @@ function Header(props) {
51
51
  const { productName, baseEnvUrl, baseServicesUrl, carbonTheme = "g10", className, navLinks, platform, prefixName = "", rightPanel, skipToContentProps, templateMeteringEvent, triggerEvent, userTeams, } = props;
52
52
  console.log("platform", platform);
53
53
  console.log("enabled", platform?.instanceSwitcherEnabled);
54
- console.log("instances", platform?.instances);
55
54
  return (React.createElement(React.Fragment, null,
56
55
  React.createElement(Theme, { theme: carbonTheme },
57
56
  React.createElement(Header$1, { "aria-label": "App navigation header", className: className },
@@ -75,8 +74,9 @@ function Header(props) {
75
74
  function InstanceSwitcherMenu(props) {
76
75
  // const currentURL= window.location.href;
77
76
  const currentURL = "https://canada.ica.ibm.com";
78
- console.log("currentURL.includes(item.instanceName)-1", currentURL.includes("Canada"));
79
- console.log("currentURL.includes(item.instanceName)-2", currentURL.includes("canada"));
77
+ console.log("currentURL.includes((item.instanceName).toLowerCase())", currentURL.includes(("Canada").toLowerCase()));
78
+ console.log("lowerCase", "Canada".toLowerCase());
79
+ console.log("string lowercase", String("Canada").toLowerCase());
80
80
  const { isOpen, toggleActive, ref } = useHeaderMenu(MenuButtonId.InstanceSwitcher);
81
81
  if (!props.enabled) {
82
82
  return null;
@@ -88,7 +88,7 @@ function InstanceSwitcherMenu(props) {
88
88
  ? props.menuItems.map((item) => (React.createElement(HeaderMenuItem, { "aria-label": `Instance Switcher for ${item.instanceName}`, "data-testid": "header-menu-instance-switcher", href: item.url, isCurrentPage: window?.location?.href && item.url ? window.location.href.startsWith(item.url) : false, key: item.instanceName, target: "_self", rel: "noopener noreferrer" },
89
89
  React.createElement("div", null,
90
90
  React.createElement("span", null, item.instanceName),
91
- currentURL.includes(item.instanceName) ? React.createElement("span", { className: instanceCheckMarkStyle },
91
+ currentURL.includes((item.instanceName).toLowerCase()) ? React.createElement("span", { className: instanceCheckMarkStyle },
92
92
  React.createElement(Checkmark, null),
93
93
  " ") : ""))))
94
94
  : null)) : 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.5-beta.30",
4
+ "version": "4.6.5-beta.32",
5
5
  "author": {
6
6
  "name": "Tim Bula",
7
7
  "email": "timrbula@gmail.com"