mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-09 13:56:10 +00:00
13 lines
300 B
JavaScript
13 lines
300 B
JavaScript
document.getElementById('mode').addEventListener('click', () => {
|
|
|
|
document.body.classList.toggle('dark');
|
|
localStorage.setItem('theme', document.body.classList.contains('dark') ? 'dark' : 'light');
|
|
|
|
});
|
|
|
|
if (localStorage.getItem('theme') === 'dark') {
|
|
|
|
document.body.classList.add('dark');
|
|
|
|
}
|