slidevjs / slidev

Presentation Slides for Developers
https://sli.dev
MIT License
31.94k stars 1.26k forks source link

`nextFrame.value is null` on last slide with click interations on `presenter` mode #1678

Closed FirelightFlagboy closed 2 weeks ago

FirelightFlagboy commented 2 weeks ago

Describe the bug

In presenter mode with the last slide that have click interactions, the last click cannot be performed

To Reproduce Steps to reproduce the behavior:

  1. Create a presentation with the last slide that have click interations:

    
    
    # Foo
    
    <v-click>
    
    - Foo
    - Bar
    
    </v-click>
  2. Go to that last slide

  3. Try to perform the click interations

  4. See the error nextFrame.value is null in the console for the last interation

    Exception details ``` Uncaught (in promise) TypeError: nextFrame.value is null setup presenter.vue:70 callWithErrorHandling runtime-core.esm-bundler.js:195 callWithAsyncErrorHandling runtime-core.esm-bundler.js:202 job runtime-core.esm-bundler.js:6100 flushPreFlushCbs runtime-core.esm-bundler.js:356 updateComponentPreRender runtime-core.esm-bundler.js:5290 componentUpdateFn runtime-core.esm-bundler.js:5203 run reactivity.esm-bundler.js:181 update runtime-core.esm-bundler.js:5270 updateComponent runtime-core.esm-bundler.js:5079 processComponent runtime-core.esm-bundler.js:5013 patch runtime-core.esm-bundler.js:4471 componentUpdateFn runtime-core.esm-bundler.js:5226 run reactivity.esm-bundler.js:181 update runtime-core.esm-bundler.js:5270 callWithErrorHandling runtime-core.esm-bundler.js:195 flushJobs runtime-core.esm-bundler.js:409 promise callback*queueFlush runtime-core.esm-bundler.js:319 queueJob runtime-core.esm-bundler.js:313 scheduler runtime-core.esm-bundler.js:6121 resetScheduling reactivity.esm-bundler.js:266 triggerEffects reactivity.esm-bundler.js:319 triggerRefValue reactivity.esm-bundler.js:1084 set value reactivity.esm-bundler.js:1131 finalizeNavigation vue-router.mjs:3443 pushWithRedirect vue-router.mjs:3308 promise callback*pushWithRedirect vue-router.mjs:3275 push vue-router.mjs:3200 replace vue-router.mjs:3203 set route.ts:28 promise callback*nextTick runtime-core.esm-bundler.js:286 set route.ts:24 set value reactivity.esm-bundler.js:1030 set useNav.ts:307 set value reactivity.esm-bundler.js:1030 next useNav.ts:146 trigger shortcuts.ts:29 callWithErrorHandling runtime-core.esm-bundler.js:195 callWithAsyncErrorHandling runtime-core.esm-bundler.js:202 job runtime-core.esm-bundler.js:6100 resetScheduling reactivity.esm-bundler.js:266 triggerEffects reactivity.esm-bundler.js:319 triggerRefValue reactivity.esm-bundler.js:1084 set value reactivity.esm-bundler.js:1131 setRefs index.mjs:4221 updateRefs index.mjs:4242 useMagicKeys index.mjs:4255 ```

Desktop (please complete the following information):

KermanX commented 2 weeks ago

Sorry, I can't reproduce this. I also checked the code but had no idea why this would happen.

image

FirelightFlagboy commented 2 weeks ago

I myself cannot reproduce this error anymore after refreshing the page :sweat_smile: