-
-
Notifications
You must be signed in to change notification settings - Fork 86
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
Make icons in alerts optional and use masks instead of FA font #403
Conversation
Really cool 👍 |
I did a bit more testing of this, and honestly can't find anything wrong with it. @crftwrk If you're happy with it, I'm fine with it being merged. |
I love it ;-) But we need icons for .alert-primary,
.alert-secondary,
.alert-light,
.alert-dark {
&::before {
display: none;
}
} Agree? |
Is it also possible to only have the icons when loading WooCommerce alerts and/or with an additional class? I personally think that that having the icons at all times feels like overwriting the functionality of the Bootstrap alerts. |
You're right. Let's do them only in Woo. In this case we can delete |
Already working on an alternative, ready in a few minutes 😉 |
Perfect ;-) While we are here, we can replace |
The changes in a471254 will make the icon in the alert an option for everyone using alerts in bootScore, and extendable to the WooCommerce alerts. |
Now I'm just thinking... Would a471254 be the correct solution, or also having a class |
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.
Looks good 👍
The .alert-[type]-icon
is a nice solution. Has to be written down the docs.
The If users want any alert to have an icon, they can use To add or change an icon, use the following:
|
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.
Looks good 👍
This is still a concept, but already works great. This is an idea I discussed with @crftwrk before to replace the use of the Font Awesome font directly and make use of SVGs. This is because some people use the JS version of Font Awesome (like myself) which doesn't include the fonts anymore. Unfortunately using SVGs directly isn't easy as you can't change the color unless you want to add a fill to the url of the svg (making it less dynamic). Using masks we can get the same result.
The
-webkit
is needed unfortunately, as it is supported by Chrome but needs the-webkit
for it to read it. More info: https://caniuse.com/css-masks