Skip to content

refactor(Print): migrate Print component styles from SCSS to Tailwind CSS #8047#8105

Closed
Deven14125 wants to merge 2 commits intowebpack:mainfrom
Deven14125:refactor-print-section
Closed

refactor(Print): migrate Print component styles from SCSS to Tailwind CSS #8047#8105
Deven14125 wants to merge 2 commits intowebpack:mainfrom
Deven14125:refactor-print-section

Conversation

@Deven14125
Copy link
Copy Markdown
Contributor

@Deven14125 Deven14125 commented Mar 23, 2026

Part of #8047

Description

This PR migrates the Print component styles from SCSS to Tailwind CSS.

Changes Made

  • Replaced SCSS styles with Tailwind utility classes
  • Removed Print.scss file and its import
  • Used Tailwind classes for layout and spacing.
  • Maintained existing class structure to avoid breaking global styles

Testing

  • Verified that the Print section renders correctly
  • Checked alignment and spacing of icon and text
  • Ensured no visual regression in sidebar UI

Notes

  • This change is part of the gradual migration from SCSS to Tailwind CSS
  • Focused only on the Print component for this PR

Remove the Print.scss stylesheet and its import, switching the Print component to utility CSS classes instead. Replaced the sidebar-link__print class with 'flex flex-nowrap items-center' and added image classes ('h-20 mr-0.5') to preserve layout/spacing. This migrates styling to utility-first classes (e.g., Tailwind) and deletes the now-unused SCSS file.
Copilot AI review requested due to automatic review settings March 23, 2026 10:49
@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 23, 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 23, 2026 1:05pm

Request Review

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR migrates the Print sidebar component’s styling from a dedicated SCSS file to inline Tailwind utility classes, as part of the broader SCSS → Tailwind migration across the codebase.

Changes:

  • Removed Print.scss and its import from the Print component.
  • Replaced the previous .sidebar-link__print SCSS-driven layout with Tailwind flex/alignment/spacing utilities.
  • Added Tailwind sizing/spacing utilities to the print icon <img>.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/components/Print/Print.scss Deletes the component-specific SCSS rules for the print sidebar link.
src/components/Print/Print.jsx Removes the SCSS import and applies Tailwind classes for layout and icon spacing/sizing.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/components/Print/Print.jsx Outdated
Comment on lines +49 to +54
<img
className="h-20 mr-0.5"
src={icon}
width={27}
height={20}
alt="Printer Icon"
Copy link

Copilot AI Mar 23, 2026

Choose a reason for hiding this comment

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

The Tailwind class h-20 sets height to 5rem (80px), which doesn’t match the previous SCSS height: 20px and also conflicts with the height={20} attribute. Use a 20px-equivalent utility (e.g., h-5 or an arbitrary value like h-[20px]) to avoid oversized/distorted rendering.

Copilot uses AI. Check for mistakes.
Comment on lines 41 to 43
<a
className="sidebar-item__title sidebar-link__print"
className="sidebar-item__title flex flex-nowrap items-center"
href={printUrl}
Copy link

Copilot AI Mar 23, 2026

Choose a reason for hiding this comment

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

PR description mentions maintaining the existing class structure to avoid breaking global styles, but this change removes the sidebar-link__print class from the anchor. If backward compatibility is still a goal, consider keeping that class (even if styling moves to Tailwind), or update the PR description to reflect the change.

Copilot uses AI. Check for mistakes.
@Deven14125 Deven14125 changed the title refactor(Print): migrate Print component styles from SCSS to Tailwind CSS refactor(Print): migrate Print component styles from SCSS to Tailwind CSS #8047 Mar 23, 2026
@alexander-akait
Copy link
Copy Markdown
Member

Looks like already fixed

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