Merge pull request #36 from vadimkorr/feature/#34_Prevent-initial-page-reset-on-resize
feature/#34 Prevent initial page reset on resize
This commit is contained in:
@@ -109,7 +109,6 @@
|
||||
children[pageIndex].style.maxWidth = `${pageWidth}px`
|
||||
}
|
||||
|
||||
store.init(initialPageIndex + Number(infinite))
|
||||
offsetPage(false)
|
||||
}
|
||||
|
||||
@@ -145,6 +144,8 @@
|
||||
loaded = [0, pagesElement.children.length - 1]
|
||||
await tick()
|
||||
infinite && addClones()
|
||||
|
||||
store.init(initialPageIndex + Number(infinite))
|
||||
applyPageSizes()
|
||||
}
|
||||
applyAutoplay()
|
||||
|
||||
Reference in New Issue
Block a user