diff --git a/public/js/components/ChannelList.js b/public/js/components/ChannelList.js index 88989a6..525ba75 100644 --- a/public/js/components/ChannelList.js +++ b/public/js/components/ChannelList.js @@ -9,6 +9,7 @@ class ChannelList { this.searchInput = document.getElementById('channel-search'); this.sourceSelect = document.getElementById('source-select'); this.showHiddenCheckbox = document.getElementById('show-hidden'); + this.toggleGroupsBtn = document.getElementById('toggle-groups'); this.contextMenu = document.getElementById('context-menu'); this.channels = []; @@ -70,6 +71,12 @@ class ChannelList { this.collapsedGroups.clear(); this.saveCollapsedState(); this.container.querySelectorAll('.group-header.collapsed').forEach(h => h.classList.remove('collapsed')); + + // Update toggle button + if (this.toggleGroupsBtn) { + this.toggleGroupsBtn.innerHTML = Icons.collapseAll; + this.toggleGroupsBtn.title = 'Collapse All'; + } } /** @@ -82,6 +89,12 @@ class ChannelList { h.classList.add('collapsed'); }); this.saveCollapsedState(); + + // Update toggle button + if (this.toggleGroupsBtn) { + this.toggleGroupsBtn.innerHTML = Icons.expandAll; + this.toggleGroupsBtn.title = 'Expand All'; + } } /** diff --git a/public/js/icons.js b/public/js/icons.js index e02c564..b7dd72b 100644 --- a/public/js/icons.js +++ b/public/js/icons.js @@ -19,7 +19,8 @@ const Icons = { star: ``, chevronDown: ``, chevronRight: ``, - collapseAll: ``, // Minus + expandAll: ``, // Unfold More + collapseAll: ``, // Unfold Less close: ``, };