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

feat: landing - animate hero #197

Merged
merged 27 commits into from
Nov 30, 2021
Merged

feat: landing - animate hero #197

merged 27 commits into from
Nov 30, 2021

Conversation

olarclara
Copy link
Contributor

@olarclara olarclara commented Nov 29, 2021

Closes CSB-1862.

What kind of change does this pull request introduce?

Animates the landing page hero on desktop.

What is the current behavior?

What is the new behavior?

What steps did you take to test this? This is required before we can merge, make sure to test the flow you've updated.

Verified animations on the following browsers:

  1. Chrome
  2. Safari
  3. Firefox

Performance verification on Chrome.

Checklist

  • Ready to be merged

@olarclara olarclara self-assigned this Nov 29, 2021
@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 29, 2021 18:06 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 29, 2021 18:06 Inactive
@olarclara olarclara force-pushed the olarclara/feat/landing-hero branch from e6f7b34 to da3d15c Compare November 29, 2021 18:14
@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 29, 2021 18:14 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 29, 2021 18:15 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 29, 2021 18:48 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 29, 2021 18:48 Inactive
@olarclara olarclara changed the title Olarclara/feat/landing hero feat: landing - animate hero Nov 29, 2021
@linear
Copy link

linear bot commented Nov 29, 2021

@zehfernandes
Copy link
Contributor

Awesome work @olarclara! Pretty smooth, and the FPS is not dropping below 30. Thanks for all the effort 🎉👏👏

I have two comments that are important to fix:

  1. The Sandpack component is flicking on the screen before the hero. We should prioritize the first paint to be the full hero:

    flick.mp4

  2. If I stop scrolling earlier and edit the code, I can't see my changes. Maybe we can force the swap or force a scrollTo to the position that the editing is fully working.

    edit.mp4

@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 29, 2021 21:54 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 29, 2021 21:54 Inactive
@olarclara olarclara force-pushed the olarclara/feat/landing-hero branch from 03f5982 to a894b3f Compare November 29, 2021 23:01
@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 29, 2021 23:01 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 29, 2021 23:02 Inactive
@olarclara
Copy link
Contributor Author

@zehfernandes thank you! the fouc shold be fixed now. I'll take a shot at fixing the latter issue tomorrow, probably in another PR.

hero_fouc_fix.mov

Copy link
Member

@danilowoz danilowoz left a comment

Choose a reason for hiding this comment

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

Very impressive work @olarclara!

@@ -27,10 +27,56 @@ export const globalStyles = globalCss({
boxSizing: "border-box",
},

body: {
// Remove when we replace scrollbar styling in the sandpack library
Copy link
Member

Choose a reason for hiding this comment

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

It should have been fixed in another PR, so feel free to remove it

id="container"
style={
{
"--progress": isMounted ? progress : 0,
Copy link
Member

Choose a reason for hiding this comment

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

Love this approach

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it was @marcovincit's idea to define all the variables in a single place, it looks super neat and improves perceived performance 🙌🏽

@vercel
Copy link

vercel bot commented Nov 30, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployments, click below or on the icon next to each commit.

sandpack-theme – ./website/theme

🔍 Inspect: https://vercel.com/codesandbox/sandpack-theme/FhC1Fr6H51sgM435mm1mmVAd33V2
✅ Preview: Failed

@vercel vercel bot temporarily deployed to Preview – sandpack-theme November 30, 2021 13:44 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 30, 2021 13:44 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 30, 2021 13:44 Inactive
@olarclara olarclara force-pushed the olarclara/feat/landing-hero branch from 86ffb49 to 44f496e Compare November 30, 2021 15:19
@vercel vercel bot temporarily deployed to Preview – sandpack-docs November 30, 2021 15:19 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-theme November 30, 2021 15:19 Inactive
@vercel vercel bot temporarily deployed to Preview – sandpack-landing November 30, 2021 15:19 Inactive
@olarclara olarclara merged commit 6ba7ea1 into main Nov 30, 2021
@olarclara olarclara deleted the olarclara/feat/landing-hero branch November 30, 2021 15:28
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.

3 participants