@triptease/tt-navbar 0.0.26 → 0.0.28

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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @triptease/tt-navbar v0.0.26
2
+ * @triptease/tt-navbar v0.0.28
3
3
  */
4
4
 
5
5
  // src/triptease-logo.ts
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @triptease/tt-navbar v0.0.26
2
+ * @triptease/tt-navbar v0.0.28
3
3
  */
4
4
  var __defProp = Object.defineProperty;
5
5
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -1806,6 +1806,13 @@ var styles2 = i`
1806
1806
  }
1807
1807
  }
1808
1808
 
1809
+ .sidebar-closed details:has(.current-page) > summary {
1810
+ --nav-item-color: var(--color-primary-400);
1811
+ border-radius: var(--border-radius-100);
1812
+ background-color: var(--color-primary-100);
1813
+ color: var(--nav-item-color);
1814
+ }
1815
+
1809
1816
  .sub-nav-item {
1810
1817
  width: 100%;
1811
1818
  display: flex;
@@ -1837,8 +1844,7 @@ var styles2 = i`
1837
1844
  }
1838
1845
  }
1839
1846
 
1840
- .current-page,
1841
- .sidebar-closed details:has(.current-page) > summary {
1847
+ .current-page {
1842
1848
  --nav-item-color: var(--color-primary-400);
1843
1849
  border-radius: var(--border-radius-100);
1844
1850
  background-color: var(--color-primary-100);
@@ -2121,6 +2127,14 @@ var TtNavbar = class extends i4 {
2121
2127
  firstUpdated() {
2122
2128
  this.setActiveState();
2123
2129
  }
2130
+ connectedCallback() {
2131
+ window.addEventListener("popstate", this.setActiveState);
2132
+ super.connectedCallback();
2133
+ }
2134
+ disconnectedCallback() {
2135
+ window.removeEventListener("popstate", this.setActiveState);
2136
+ super.disconnectedCallback();
2137
+ }
2124
2138
  render() {
2125
2139
  return x`
2126
2140
  <nav id=${this.id} class="${this.sidebarOpen ? "" : "sidebar-closed"}">