-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
fix: replace magic number with spacing token in Button component #3978
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
fix: replace magic number with spacing token in Button component #3978
Conversation
|
Hello @karanmonu, thank you for this contribution! Can you please clarify how this PR fixes issue #3625? It looks like this PR is related to the Button component, while that referenced issue is related to EDIT: Removed link issue manually, as this is a small refactor I will merge in |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## next #3978 +/- ##
=======================================
Coverage 79.29% 79.29%
=======================================
Files 90 90
Lines 2144 2144
Branches 959 957 -2
=======================================
Hits 1700 1700
Misses 442 442
Partials 2 2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
fix: replace magic number with spacing token in Button component
fix: replace magic number with spacing token in Button component
theianmay
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Merged, thank you!
Motivation
This PR replaces the hardcoded
+2value inpaddingHorizontalof theButtoncomponent with a token-based valuetheme.spacing.xs. This improves design consistency and removes magic numbers.Fixes #
Type of change
How Has This Been Tested?
exampleapp manuallyChecklist
yarn docs-build-api(Not applicable)Additional context
This is a small change but helps with tokenized styling and removes design inconsistency due to hardcoded spacing.