-
Notifications
You must be signed in to change notification settings - Fork 8
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!: Replace ‘on background’ props with ‘inverseColor’ and ‘contrastColor’ for Link, Link List Link, and Icon Button #1448
Merged
VincentSmedinga
merged 15 commits into
develop
from
feature/DES-776-1-refactor-on-background-prop
Jul 26, 2024
Merged
feat!: Replace ‘on background’ props with ‘inverseColor’ and ‘contrastColor’ for Link, Link List Link, and Icon Button #1448
VincentSmedinga
merged 15 commits into
develop
from
feature/DES-776-1-refactor-on-background-prop
Jul 26, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
VincentSmedinga
changed the title
feat! Replace ‘on background’ props with ‘inverseColor’ and ‘contrastColor’ for Link, Link List Link, and Icon Button
feat!: Replace ‘on background’ props with ‘inverseColor’ and ‘contrastColor’ for Link, Link List Link, and Icon Button
Jul 22, 2024
github-actions
bot
temporarily deployed
to
demo-DES-776-1-refactor-on-background-prop
July 24, 2024 23:00
Destroyed
alimpens
reviewed
Jul 26, 2024
Co-authored-by: Aram <[email protected]>
github-actions
bot
temporarily deployed
to
demo-DES-776-1-refactor-on-background-prop
July 26, 2024 09:50
Destroyed
…prop # Conflicts: # storybook/config/preview-body.html
github-actions
bot
temporarily deployed
to
demo-DES-776-1-refactor-on-background-prop
July 26, 2024 11:36
Destroyed
github-actions
bot
temporarily deployed
to
demo-DES-776-1-refactor-on-background-prop
July 26, 2024 11:41
Destroyed
github-actions
bot
temporarily deployed
to
demo-DES-776-1-refactor-on-background-prop
July 26, 2024 12:34
Destroyed
alimpens
approved these changes
Jul 26, 2024
github-actions
bot
temporarily deployed
to
demo-DES-776-1-refactor-on-background-prop
July 26, 2024 13:29
Destroyed
alimpens
approved these changes
Jul 26, 2024
VincentSmedinga
deleted the
feature/DES-776-1-refactor-on-background-prop
branch
July 26, 2024 14:22
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Describe the pull request
Thank you for contributing to the project!
Please use this template to help us handle your PR smoothly.
What
This replaces
onBackground="light"
withcontrastColor={true}
andonBackground="dark"
withinverseColor={true}
for Link, Link List Link, and Icon Button. Related tokens and class names are affected.Why
We had an inconsistency between this
onBackground
prop and theinverseColor
prop of many other components. We’ve analyzed that and found that adding aconstrastColor
prop allows us to use theinverseColor
prop consistently.Shortly, the ‘contrast color’ is an alternative foreground colour for a text or icon component if they are on a light (not white) background. The ‘inverse color’ is the same for a dark background.
How
This is largely a ‘find and replace’ refactoring.
I chose not to add
visited
colours to these components, even thought the tokens for it are available in thelink-appearance
layer.Checklist
Before submitting your pull request, please ensure you have done the following. Check each checkmark if you have done so or if it wasn't necessary:
Additional notes