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

Loading Screen to Welcome Screen #875

Merged
merged 4 commits into from
Nov 10, 2024
Merged

Loading Screen to Welcome Screen #875

merged 4 commits into from
Nov 10, 2024

Conversation

NIDHI2023
Copy link
Contributor

Summary

Building on this Wrapped Frontend PR and this animation PR, creates a loading animation screen that transitions into the welcome screen.

Screen.Recording.2024-10-27.at.1.27.18.PM.mov
  • Made animation faster
  • Fixed some centering issues on different devices

Test Plan

  • Loading animation should look centered on different device widths
  • No lags or delays, and dots and arrows should only show up after the welcome component is rendered

Notes

  • I made the loading animation have a 0.8s delay because shortening this caused some odd CSS flickering, and this was the lowest time I could go without the flickering

Breaking Changes

None

  • I have updated the documentation accordingly.
  • My PR adds a @ts-ignore

@NIDHI2023 NIDHI2023 requested a review from a team as a code owner October 27, 2024 17:29
@dti-github-bot
Copy link
Member

dti-github-bot commented Oct 27, 2024

[diff-counting] Significant lines: 322.

Copy link
Contributor

@rgu0114 rgu0114 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work integrating the animation into the transition into the Wrapped modal. Since we have this, I think we can close the original animation PR. I did notice from testing on my side though that there was a bit longer of a delay (a few seconds) where it seemed a little stuck on the DTI logo. Are you seeing this as well? Could just be slow network speed on my side.

Screen Shot 2024-10-27 at 4 12 32 PM

{showBanner && (
<>
<div className="banner top-right">
loading ? (<> </>) :
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of conditionally rendering an empty component, this is typically done with && in typescript (see line 418 for an example)

className="sec-plus"
alt="second plus"
onAnimationEnd={() => {
const timer = setTimeout(() => {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, the animation looks good. I'm just curious that since this calls an inline-function inside of onAnimationEnd, wouldn't this create a timer every re-render. Would it be better to make declare the function outside? This might be a bit better performance-wise if the component frequently re-renders or updates.

Copy link
Contributor

@rgu0114 rgu0114 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good to merge once changes are addressed

@NIDHI2023 NIDHI2023 merged commit fe0a480 into master Nov 10, 2024
4 checks passed
@NIDHI2023 NIDHI2023 deleted the nidhi/wrapped-intro branch November 10, 2024 02:37
@rgu0114 rgu0114 mentioned this pull request Nov 22, 2024
2 tasks
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

Successfully merging this pull request may close these issues.

4 participants