Skip to content

Conversation

mostafaegouda
Copy link

@mostafaegouda mostafaegouda commented Aug 2, 2025

This PR refactors the Switch component from shadcn/ui to leverage CSS variables for all critical sizing and spacing logic. Key improvements include:

This update improves the scalability and maintainability of the Switch component, especially for design systems needing adaptable UI components.

This PR can be further extended to add a size prop to the switch component as discussed in #4098 as it simplifies the idea to just chaning the with css variable.

Copy link

vercel bot commented Aug 2, 2025

@mostafaegouda is attempting to deploy a commit to the shadcn-pro Team on Vercel.

A member of the Team first needs to authorize it.

@mostafaegouda mostafaegouda changed the title Refactor Switch component to use CSS variables for improved sizing flexibility refactor(switch): Refactor switch component to use CSS variables for improved sizing flexibility Aug 2, 2025
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.

1 participant