@design.estate/dees-wcctools 3.6.1 → 3.6.2

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.
@@ -42053,6 +42053,12 @@ var WccSidebar = class extends (_a3 = DeesElement, _selectedItem_dec = [n5({ att
42053
42053
  document.addEventListener("mouseup", onMouseUp);
42054
42054
  });
42055
42055
  }
42056
+ /**
42057
+ * Returns the scrollable container element (.menu) for external scroll management
42058
+ */
42059
+ get scrollableContainer() {
42060
+ return this.shadowRoot?.querySelector(".menu");
42061
+ }
42056
42062
  render() {
42057
42063
  return b2`
42058
42064
  <link href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" rel="stylesheet" />
@@ -45544,10 +45550,13 @@ var WccDashboard2 = class extends (_a7 = DeesElement, _sections_dec = [n5()], _s
45544
45550
  this.scrollListenersAttached = true;
45545
45551
  }
45546
45552
  if (wccSidebar) {
45547
- wccSidebar.addEventListener("scroll", () => {
45548
- this.sidebarScrollY = wccSidebar.scrollTop;
45549
- this.debouncedScrollUpdate();
45550
- });
45553
+ const scrollContainer = wccSidebar.scrollableContainer;
45554
+ if (scrollContainer) {
45555
+ scrollContainer.addEventListener("scroll", () => {
45556
+ this.sidebarScrollY = scrollContainer.scrollTop;
45557
+ this.debouncedScrollUpdate();
45558
+ });
45559
+ }
45551
45560
  }
45552
45561
  }
45553
45562
  debouncedScrollUpdate() {
@@ -45589,7 +45598,10 @@ var WccDashboard2 = class extends (_a7 = DeesElement, _sections_dec = [n5()], _s
45589
45598
  wccFrame.scrollTop = this.frameScrollY;
45590
45599
  }
45591
45600
  if (wccSidebar && this.sidebarScrollY > 0) {
45592
- wccSidebar.scrollTop = this.sidebarScrollY;
45601
+ const scrollContainer = wccSidebar.scrollableContainer;
45602
+ if (scrollContainer) {
45603
+ scrollContainer.scrollTop = this.sidebarScrollY;
45604
+ }
45593
45605
  }
45594
45606
  this.scrollPositionsApplied = true;
45595
45607
  }