Skip to content

refactor(SplashViz): migrate from SCSS to Tailwind CSS#8095

Closed
mr-baraiya wants to merge 14 commits intowebpack:mainfrom
mr-baraiya:feature/splashviz-tailwind
Closed

refactor(SplashViz): migrate from SCSS to Tailwind CSS#8095
mr-baraiya wants to merge 14 commits intowebpack:mainfrom
mr-baraiya:feature/splashviz-tailwind

Conversation

@mr-baraiya
Copy link
Copy Markdown
Contributor

Part of #8047

Changes

  • Migrated SplashViz component from SCSS to Tailwind CSS
  • Removed SplashViz.scss file
  • Preserved existing UI and behavior

Notes

  • No functional changes introduced
  • Continues incremental migration away from SCSS

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
webpack-js-org Ready Ready Preview, Comment Mar 26, 2026 6:43pm

Request Review

Copy link
Copy Markdown
Contributor

@rahul-kr-rai rahul-kr-rai left a comment

Choose a reason for hiding this comment

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

The current h1 heading appears to visually merge with the navbar
Please fix it.

Copy link
Copy Markdown
Member

@alexander-akait alexander-akait left a comment

Choose a reason for hiding this comment

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

Please fix the above problem

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

Adjusted layout spacing by adding top padding to the section instead of margin on the heading. This ensures proper separation from the navbar.

@alexander-akait
Copy link
Copy Markdown
Member

@rahul-kr-rai please take a look too

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

Adjusted layout spacing by adding top padding to the section instead of margin on the heading. This ensures proper separation from the navbar.

But size of h1 is diffrent form Webpack.js.org see the difference ( https://webpack-js-org-git-fork-mr-baraiya-feature-splash-74c8ba-openjs.vercel.app/ and https://webpack.js.org/)

Please fix it.

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

Updated the heading font size using exact pixel values from the original webpack.js.org design and aligned spacing with the original SCSS by using margin on the heading instead of section padding.

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

Adjusted layout spacing by adding top padding to the section instead of margin on the heading. This ensures proper separation from the navbar.

Good, but the style is still different. You can open both links and see the exact difference by switching the tabs.

Visit Here: ( https://webpack-js-org-git-fork-mr-baraiya-feature-splash-74c8ba-openjs.vercel.app/ and https://webpack.js.org/ )

Please fix it.

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

I’ve worked on aligning the SplashViz section with the original Webpack design and was able to match most of the styling and behavior.

However, the text rotation animation still shows a slight flicker/crack during transitions. I investigated multiple approaches (layout fixes, animation changes, font adjustments), but it appears to be caused by browser rendering limitations with text animations rather than implementation issues.

Given this, I’m unable to fully eliminate the glitch while keeping the original behavior intact. I’d suggest either accepting the minor visual difference or switching to a fade-based animation for complete smoothness.

Let me know how you’d like to proceed.

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

I’ve worked on aligning the SplashViz section with the original Webpack design and was able to match most of the styling and behavior.

However, the text rotation animation still shows a slight flicker/crack during transitions. I investigated multiple approaches (layout fixes, animation changes, font adjustments), but it appears to be caused by browser rendering limitations with text animations rather than implementation issues.

Given this, I’m unable to fully eliminate the glitch while keeping the original behavior intact. I’d suggest either accepting the minor visual difference or switching to a fade-based animation for complete smoothness.

Let me know how you’d like to proceed.

The text rotation twitch problem was solved by PR #8117.
Please focus on the SplashViz Component only.

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

I’ve focused only on the SplashViz component and updated the styling to better match the original design.

@alexander-akait
Copy link
Copy Markdown
Member

@rahul-kr-rai can you take a look too on these changes

Comment thread src/components/SplashViz/SplashViz.jsx Outdated
<span> images </span>
<span> styles </span>
</TextRotator>
<section className="relative grid grid-rows-[auto_1fr] overflow-hidden p-4 pb-16 bg-[#2b3a42] dark:bg-gray-900 h-[clamp(35rem,calc(100vh-80px),45rem)] md:h-[clamp(30rem,calc(100vh-80px),35rem)] sm:min-h-[clamp(40rem,calc(100vh-80px),50rem)]">
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can we use Clsx here?

Suggested change
<section className="relative grid grid-rows-[auto_1fr] overflow-hidden p-4 pb-16 bg-[#2b3a42] dark:bg-gray-900 h-[clamp(35rem,calc(100vh-80px),45rem)] md:h-[clamp(30rem,calc(100vh-80px),35rem)] sm:min-h-[clamp(40rem,calc(100vh-80px),50rem)]">
className={clsx(
"relative grid grid-rows-[auto_1fr] overflow-hidden p-4 pb-16",
"bg-[#2b3a42] dark:bg-gray-900",
// height utilities
"h-[clamp(35rem,calc(100vh-80px),45rem)]",
"md:h-[clamp(30rem,calc(100vh-80px),35rem)]",
"sm:min-h-[clamp(40rem,calc(100vh-80px),50rem)]"
)}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should use clsx only when our classes are conditional, for example:

<section className={clsx(["foo", isOpen ? "open" : "close", isBig ? "big" : "small"])}>

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

rahul-kr-rai commented Mar 26, 2026

@alexander-akait

I have verified it locally all look good. If clsx not required then Redy to merged.

Comment thread src/components/SplashViz/SplashViz.jsx Outdated
"md:h-[clamp(30rem,calc(100vh-80px),35rem)]",
"sm:min-h-[clamp(40rem,calc(100vh-80px),50rem)]",
)}
>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@mr-baraiya let's remove clsx from here, no conditional classes and we can merge

@alexander-akait
Copy link
Copy Markdown
Member

@mr-baraiya please rebase main

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

Rebased on latest main

@alexander-akait
Copy link
Copy Markdown
Member

@mr-baraiya Please look at https://webpack-js-org-git-fork-mr-baraiya-feature-splash-74c8ba-openjs.vercel.app/ and you will find that cube is not in center, to be honestly I tired to recheck everything every time, please verify your changes before pinging me, respect time of other developers

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

Fixed and verified.
image

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

See the difference:

SplashViz.Review.mp4

Please follow the instructions:
You can open both links and see the exact difference by switching the tabs.

Visit Here: ( https://webpack-js-org-git-fork-mr-baraiya-feature-splash-74c8ba-openjs.vercel.app/ and https://webpack.js.org/ )

Please fix it.

@mr-baraiya
Copy link
Copy Markdown
Contributor Author

Apologies for the earlier issues. I’ve tried to align the layout as closely as possible and verified the changes. Please let me know if this looks good, otherwise I understand if the PR needs to be closed.

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

Apologies for the earlier issues. I’ve tried to align the layout as closely as possible and verified the changes. Please let me know if this looks good, otherwise I understand if the PR needs to be closed.

The same issue is still occurring. As per @mr-baraiya, he has been unable to resolve this, so I kindly request @alexander-akait to review and consider closing the PR.

@alexander-akait
Copy link
Copy Markdown
Member

@rahul-kr-rai feel free to send your own solution, I will close this when merge the working migration in our main branch

@rahul-kr-rai
Copy link
Copy Markdown
Contributor

@rahul-kr-rai feel free to send your own solution, I will close this when merge the working migration in our main branch

I have raised a PR #8127 to solve this issue.

@alexander-akait
Copy link
Copy Markdown
Member

Fixed by #8127

@mr-baraiya mr-baraiya deleted the feature/splashviz-tailwind branch March 27, 2026 15:38
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