Skip to content

Commit

Permalink
changes in dark/light mode button
Browse files Browse the repository at this point in the history
  • Loading branch information
Monica-Gullapalli committed Aug 7, 2024
1 parent 5246ed5 commit 9290dea
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions _includes/header.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -55,16 +55,6 @@
<i class="fab fa-github"></i>
</a>
</li>
{% if site.enable_darkmode %}
<!-- Toggle theme mode -->
<li class="nav-item toggle-container">
<button id="light-toggle" title="Change theme">
<i class="ti ti-sun-moon" id="light-toggle-system"></i>
<i class="ti ti-moon-filled" id="light-toggle-dark"></i>
<i class="ti ti-sun-filled" id="light-toggle-light"></i>
</button>
</li>
{% endif %}
</ul>
</div>
</div>
Expand All @@ -79,13 +69,3 @@
{% endif %}
</header>

<script>
document.addEventListener('DOMContentLoaded', function() {
const darkModeEnabled = /* logic to determine if dark mode is enabled */;
if (darkModeEnabled) {
document.body.classList.add('dark-mode');
} else {
document.body.classList.remove('dark-mode');
}
});
</script>

0 comments on commit 9290dea

Please sign in to comment.