-
Notifications
You must be signed in to change notification settings - Fork 906
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
md-icon in md-dialog can not show up if with bootstrap 5 #5182
Comments
This seems to be due to the quite aggressive css rebooting of bootstrap. In particular, this rule: *, ::after, ::before {
box-sizing: border-box;
} It alters the positioning of the icon, which is then hidden behind the dialog header. |
I'm a newborn in font-end works and I just know basics. @christophe-g could you advice me some solutions or searching directions for solving this problem? |
A very quick / dirty patch for this case could to reset the default md-icon {
box-sizing: initial;
} Ideally, use as less dependencies as possible (jquery/bootstrap) ; ) |
I think this might be a subtle bug. The icon has 24px of top padding added to it from the dialog, but I think that should actually be margin-top. The space being added by the dialog to the icon is intended to be external space, not internal space. |
I'll give it a try on workdays, thank you. |
That's a great idea. After changing what you have said, it works. I might make a PR later. |
I'm unable to submit a PR at the moment, so I've made adjustments to my code in this way. md-dialog > md-icon {
padding-top: initial;
margin-top: 24px;
} |
What is affected?
Component
Description
I want to add delete icon at top of dialog.
By following the demo on website, the icon didn't show up.
Here's website's demo code snap and its demo pic:
Reproduction
lit playground
Workaround
I haven't found a workaround. But to found out when disabling bootstrap, it works.
Is this a regression?
No or unsure. This never worked, or I haven't tried before.
Affected versions
Failing in 1.0.1
Browser/OS/Node environment
Browser: Firefox 119.0.1, Chrome 119.0.6045.123
OS: macOS 14.1 (m2)
Bootstrap: 5.0.2
The text was updated successfully, but these errors were encountered: