Merge pull request #33 from zhongke-wang/zhongke-wang-patch-1
Update SlideAlbum.vue
This commit is contained in:
commit
c2418f8365
@ -66,7 +66,7 @@
|
|||||||
import enums from "../../utils/enums";
|
import enums from "../../utils/enums";
|
||||||
import Utils from '../../utils'
|
import Utils from '../../utils'
|
||||||
import {mat4} from 'gl-matrix'
|
import {mat4} from 'gl-matrix'
|
||||||
import {onMounted, onBeforeUpdate, reactive, ref, watch, computed, provide} from "vue";
|
import {onMounted, onBeforeUpdate, reactive, ref, watch, computed, provide, nextTick} from "vue";
|
||||||
import {
|
import {
|
||||||
getSlideDistance,
|
getSlideDistance,
|
||||||
slideInit,
|
slideInit,
|
||||||
@ -239,7 +239,9 @@ const state = reactive({
|
|||||||
localItem: props.item,
|
localItem: props.item,
|
||||||
})
|
})
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(async () => {
|
||||||
|
await nextTick();
|
||||||
|
|
||||||
slideInit(wrapperEl.value, state, SlideType.HORIZONTAL)
|
slideInit(wrapperEl.value, state, SlideType.HORIZONTAL)
|
||||||
|
|
||||||
state.cycleFn = () => {
|
state.cycleFn = () => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user