Open transmissions11 opened 3 years ago
@sharad-s you mind if I take a look at this?
@sharad-s you mind if I take a look at this?
That'd be awesome! Sharad's working on our redesign atm so this is free for the taking :)
So I think what's happening here is that we are using nested animations when using the Flip component from react-awesome-reveal. We do this when generating icons in https://github.com/Rari-Capital/rari-dApp/blob/d1d618ad9a22322ac68fe31831debddf574d7903/src/components/shared/Logos.tsx#L38.
There's a similar open issue already logged in the react-awesome-reveal repo for the Fade component https://github.com/morellodev/react-awesome-reveal/issues/57, and one of the devs explained that it's because of how an internal dependency they use is causing it. I tried a couple of different dependency combinations with emotion and react-awesome-reveal, but it wasn't able to get the flip component to render without the error.
It's a warning, so it's probably not the end of the world. IF you wanted to remove the warning, you could remove the flip entirely (which you can see in this pull request https://github.com/Rari-Capital/rari-dApp/pull/429#issuecomment-872428374), and you would probably want to remove it for the other icons in that file. There might be a way we could manually create the flip with CSS, but I'm not 100% sure (we could probably look further into the source code of the flip component to see what they're doing).
I think we should probably keep the issue open, but let me know if there is anything else I can do about this one. The last thing I will probably poke into is what parent or grandparent component that eventually renders the icons is causing the discrepancy. @TransmissionsDev
So I think what's happening here is that we are using nested animations when using the Flip component from react-awesome-reveal. We do this when generating icons in
Wow great analysis, really appreciate it!
Do you know what other animation the Logo is nested in besides the Flip?
Overall I'd probs lean on the side of leaving it atm, but if we can remove another animation to get this to stop, I'm cool with that.
I'm not specifically sure why it's causing it, but the Column component we have in our utilities https://github.com/Rari-Capital/rari-dApp/blob/85e4bbf77b4fc98f0b1e62823c4350b930e6279c/src/utils/chakraUtils.tsx#L156
which we create here https://github.com/Rari-Capital/rari-dApp/blob/85e4bbf77b4fc98f0b1e62823c4350b930e6279c/src/components/pages/MultiPoolPortal.tsx#L82
renders whatever children components we put inside of it (which eventually renders a
Odd. Could be because Column renders a Flex?
btw if you'd like to help develop this webapp full or part time with us feel free to reach out on Discord: t11s#1559
😉