mirror of https://github.com/docker/docs.git
a11y: add aria label to theme switch button
Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
This commit is contained in:
parent
14f905327b
commit
c1cd9f7f84
|
@ -26,7 +26,7 @@
|
|||
</div>
|
||||
<div class="flex items-center gap-6">
|
||||
<div id="docsearch"></div>
|
||||
<button id="theme-switch" class="svg-icon"
|
||||
<button aria-label="Theme switch" id="theme-switch" class="svg-icon"
|
||||
x-data="{ theme: localStorage.getItem('theme-preference') }" x-init="$watch('theme', value => {
|
||||
localStorage.setItem('theme-preference', value);
|
||||
document.firstElementChild.className = value;
|
||||
|
|
Loading…
Reference in New Issue