FormidableLabs / spectacle

A React-based library for creating sleek presentations using JSX syntax that gives you the ability to live demo your code.
https://commerce.nearform.com/open-source/spectacle/
MIT License
9.7k stars 690 forks source link

Regression: using presenterMode causes slide transition animations not to function on display screen when steps are used #1287

Closed Kingdutch closed 11 months ago

Kingdutch commented 11 months ago

Prerequisites

Describe Your Environment

What version of Spectacle are you using? (can be found by running npm list --depth 0 spectacle) 10.1.4

What version of React are you using? (can be found by running npm list --depth 0 react) 18.2.0

What browser are you using? (e.g., Chrome 105.0.5195.102, Safari 16.0)

What platform are you on? (e.g., Windows, macOS, iOS, Android) macOS

Describe the Problem

  1. Update the default TypeScript codesandbox to 10.1.4 and add a simple sequence component on a new slide such as

    const Sequence = () => {
    const { step, placeholder } = useSteps(2);
    
    return (
    <>
      {placeholder}
      <Heading>{step}</Heading>
    </>
    );
    };
  2. Copy the preview URL to two separate windows (so you're out of the Codesandbox sandbox) a. One in presenter mode b. one in view mode
  3. On the presenter mode transition through the slides

Expected behavior: The slides have a fade transition

Actual behavior: The slides have no transition but just disappear/appear

Additional Information

Interestingly if the transition happens with input provided to the viewing window (rather than the presenter window) then the transition happens correctly and the slides fade.

When testing this in the 9.5.0 version of spectacle (which the sandbox linked is) it works as expected.

carloskelly13 commented 11 months ago

Thanks for raising this, let us check it out!

carloskelly13 commented 11 months ago

What I've noticed is the transitions don't work in the separate view mode, regardless of any steps on the latest release, so we'll look to see what happened in both cases.