Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

react-transition-group adding new classes instead of adding suffix #3

Open
tanpld opened this issue Apr 18, 2020 · 0 comments
Open

Comments

@tanpld
Copy link

tanpld commented Apr 18, 2020

I'm not sure this is an issue, but when I try to code along with the tutorial on youtube. I ran into this problem.
Classes added to my element look like this: "menu-primary enter enter-active" instead of "menu-primary-enter-active".
So I have to change my css to this in order to make it works:

.menu-primary.enter {
  position: absolute;
  transform: translateX(-110%);
}

.menu-primary.enter.enter-active {
  transform: translateX(0%);
  transition: all var(--speed) ease;
}

.menu-primary.exit {
  position: absolute;
}

.menu-primary.exit.exit-active {
  transform: translateX(-110%);
  transition: all var(--speed) ease;
}

.menu-secondary.enter {
  transform: translateX(110%);
}

.menu-secondary.enter.enter-active {
  transform: translateX(0%);
  transition: all var(--speed) ease;
}

.menu-secondary.exit.exit-active {
  transform: translateX(110%);
  transition: all var(--speed) ease;
}

I have checked the version of react-transition-group and it is the same with this repo (4.3.0). Can anyone explain why this happened? Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant