trepur_components 0.1.36 → 0.1.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.
|
@@ -74,7 +74,8 @@ const Header = _ref => {
|
|
|
74
74
|
reference: '/'
|
|
75
75
|
}];
|
|
76
76
|
const pathArray = window.location.pathname.split('/');
|
|
77
|
-
|
|
77
|
+
let slug = pathArray[pathArray.length - 1];
|
|
78
|
+
slug = slug === '' ? '/' : slug;
|
|
78
79
|
console.log(pathArray);
|
|
79
80
|
console.log(slug);
|
|
80
81
|
let containerClass = margin ? ' container mx-auto' : '';
|
|
@@ -206,9 +207,9 @@ const Header = _ref => {
|
|
|
206
207
|
return /*#__PURE__*/_react.default.createElement(_index3.default, {
|
|
207
208
|
name: link.name,
|
|
208
209
|
url: link.reference,
|
|
209
|
-
borderColor: slug === link.
|
|
210
|
-
textColor: slug === link.
|
|
211
|
-
bgColor: slug === link.
|
|
210
|
+
borderColor: slug === link.reference ? navItemBorderColor : hoverNavItemBorderColor,
|
|
211
|
+
textColor: slug === link.reference ? navItemTextColor : hoverNavItemTextColor,
|
|
212
|
+
bgColor: slug === link.reference ? navItemBgColor : hoverNavItemBgColor,
|
|
212
213
|
hoverBorderColor: hoverNavItemBorderColor,
|
|
213
214
|
hoverTextColor: hoverNavItemTextColor,
|
|
214
215
|
hoverBgColor: hoverNavItemBgColor,
|