Fix loading cloned images

This commit is contained in:
Vadim
2021-01-26 10:13:03 +03:00
parent 52ca762010
commit b04e20543e
2 changed files with 4 additions and 1 deletions

View File

@@ -116,6 +116,9 @@
currentPageIndex = value.currentPageIndex
})
if (pagesElement && pageWindowElement) {
// load first and last child to clone them
loaded = [0, pagesElement.children.length - 1]
await tick()
infinite && addClones()
applyPageSizes()
}

View File

@@ -1,7 +1,7 @@
<script>
export let src
export let alt
export let loaded
export let loaded = false
</script>
<div class="image-container">