mirror of
https://github.com/wukko/cobalt.git
synced 2024-11-15 12:50:01 +00:00
web/SettingsCategory: rename state from animate to focus
This commit is contained in:
parent
913beda417
commit
0f51b22d99
1 changed files with 5 additions and 5 deletions
|
@ -8,19 +8,19 @@
|
||||||
export let disabled = false;
|
export let disabled = false;
|
||||||
export let beta = false;
|
export let beta = false;
|
||||||
|
|
||||||
let animate = false;
|
let focus = false;
|
||||||
|
|
||||||
$: hash = $page.url.hash.replace("#", "");
|
$: hash = $page.url.hash.replace("#", "");
|
||||||
|
|
||||||
$: if (hash === sectionId) {
|
$: if (hash === sectionId) {
|
||||||
animate = true;
|
focus = true;
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<section
|
<section
|
||||||
id={sectionId}
|
id={sectionId}
|
||||||
class="settings-content"
|
class="settings-content"
|
||||||
class:animate
|
class:focus
|
||||||
class:disabled
|
class:disabled
|
||||||
aria-hidden={disabled}
|
aria-hidden={disabled}
|
||||||
>
|
>
|
||||||
|
@ -47,11 +47,11 @@
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
}
|
}
|
||||||
|
|
||||||
.settings-content.animate {
|
.settings-content.focus {
|
||||||
animation: highlight 2s;
|
animation: highlight 2s;
|
||||||
}
|
}
|
||||||
|
|
||||||
:global([data-reduce-motion="true"]) .settings-content.animate {
|
:global([data-reduce-motion="true"]) .settings-content.focus {
|
||||||
animation: highlight-lite 2s !important;
|
animation: highlight-lite 2s !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue