-
-
Notifications
You must be signed in to change notification settings - Fork 78.9k
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
Add new link utilities, icon link helper, and update colored link helpers #37762
Merged
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
mdo
force-pushed
the
link-utils
branch
2 times, most recently
from
January 2, 2023 19:41
1acdc9e
to
cb06ccf
Compare
For the icon links:
|
For the link utilities:
|
patrickhlauke
requested changes
Jan 2, 2023
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.
See accessibility-related comments
All done, thanks @patrickhlauke! Just pushed an update to address all that. |
patrickhlauke
previously requested changes
Jan 3, 2023
This was referenced Sep 28, 2024
This was referenced Sep 30, 2024
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.
Fun update for links in Bootstrap with a few new changes across the project...
New
.icon-link
helperThis allows you to immediately pair any Bootstrap Icon with a hyperlink and have it spaced, aligned, and styled properly. Includes support for icons before or after the text, and includes a basic hover state. There's opportunity for future hover states here, too. Might make more sense as a component?
Color links are now built with CSS variables
Instead of resetting the
color
property, we reset the--bs-link-color-rgb
values. I've also added a newtext-decoration-color
property to these helpers that defaults to the current link color inrgb
form with--bs-link-underline-opacity
as the alpha layer (defaulting to1
). This leads me to the next update...Introducing several new link utilities
To help modify icon links, colored links, and even regular links, we have new
.link-opacity-*
to change the alpha transparency,.link-offset-*
to change the distance of the underline,.link-underline-*
to change the underline color, and
.link-underline-opacity-*to change the underline alpha transparency. The link opacity and link underline opacity utilities also have a predefined
:hover` variant as well.As a result, this also removes some other custom
.icon-link
instances from the features snippet example and homepage.Live preview