get rid of animations on theme switcher
This commit is contained in:
@@ -38,26 +38,15 @@ button {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* hide by default, i.e. if JS isn't enabled and the data-theme attribute didn't get set, */
|
/* hide by default, i.e. if JS isn't enabled and the data-theme attribute didn't get set, */
|
||||||
visibility: hidden;
|
display: none;
|
||||||
opacity: 0;
|
|
||||||
transition:
|
|
||||||
color 0.2s ease,
|
|
||||||
opacity 0.5s ease,
|
|
||||||
transform 0.5s ease;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:global(html[data-theme="light"]) button#switch-to-dark {
|
:global(html[data-theme="light"]) button#switch-to-dark {
|
||||||
opacity: 1;
|
display: block;
|
||||||
visibility: visible;
|
|
||||||
transform: rotate(360deg);
|
|
||||||
/* whichever one is currently active should be on top */
|
|
||||||
z-index: 10;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:global(html[data-theme="dark"]) button#switch-to-light {
|
:global(html[data-theme="dark"]) button#switch-to-light {
|
||||||
opacity: 1;
|
display: block;
|
||||||
visibility: visible;
|
|
||||||
transform: rotate(-360deg);
|
|
||||||
z-index: 10;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user