function toggleViewMoreTOCLt($this) { var $container = $this.closest('#ez-toc-container'); if ($container.classList.contains('expanded')) { $container.classList.remove('expanded'); $this.querySelector(".view-more").style.display = 'inline-block'; $this.querySelector(".view-less").style.display = 'none'; } else { $container.classList.add('expanded'); $this.querySelector(".view-more").style.display = 'none'; $this.querySelector(".view-less").style.display = 'inline-block'; } }