Merge pull request #137 from reuters-graphics/scrolly-slide-safari-bug
Fix scroller bug not updating on Safari
This commit is contained in:
commit
77f1f47fec
1 changed files with 8 additions and 2 deletions
|
|
@ -14,7 +14,7 @@
|
|||
<div
|
||||
class="step-background step-{i + 1} w-full absolute"
|
||||
class:visible="{stackBackground ? i <= index : i === index}"
|
||||
class:hidden="{stackBackground ? i > index : i !== index}"
|
||||
class:invisible="{stackBackground ? i > index : i !== index}"
|
||||
>
|
||||
<svelte:component
|
||||
this="{step.background}"
|
||||
|
|
@ -26,9 +26,15 @@
|
|||
|
||||
<style lang="scss">
|
||||
.step-background {
|
||||
opacity: 0;
|
||||
will-change: opacity;
|
||||
transition: 0.35s opacity ease;
|
||||
|
||||
&.hidden {
|
||||
&.visible {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
&.invisible {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue