Skip to content
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 FastBoot rendering of opened modals #884

Merged
merged 1 commit into from
Aug 23, 2019
Merged

Conversation

simonihmig
Copy link
Contributor

Previously an inline display: block (to override a default display: none) was set in JavaScript (CSSOM) to not cause strict CSP violations (see #746). But in FastBoot that code would not run (there is no real DOM to set styles to), so an opened modal rendered in FastBoot would show only the backdrop, the actual modals would still be hidden.

This change applies the default BS classes that apply display: block in a normal Ember-only way, so they get rendered in FastBoot. That is happening additionally to setting inline display: block, as I thought that maybe users might have omitted those utility classes from their CSS bundle, in which case modals wouldn't show up at all.

Previously an inline `display: block` (to override a default `display: none`) was set in JavaScript (CSSOM) to not cause strict CSP violations (see #746). But in FastBoot that code would not run (there is no real DOM to set styles to), so an opened modal rendered in FastBoot would show only the backdrop, the actual modals would still be hidden.

This change applies the default BS classes that apply `display: block` in a normal Ember-only way, so they get rendered in FastBoot. That is happening *additionally* to setting inline `display: block`, as I thought that maybe users might have omitted those utility classes from their CSS bundle, in which case modals wouldn't show up at all.
@simonihmig simonihmig merged commit ad8bf37 into master Aug 23, 2019
@simonihmig simonihmig deleted the fastboot-modal branch August 23, 2019 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants