-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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: move reveal-centered into foundation-reveal mixin #11087
Conversation
Let's continue the discussion in the right PR:
Yes it makes sense, but it breaks Again I don't understand: did you test it ? Does it generate code when importing Foundation without calling any mixin ? I did that for testing for a long (for example to test the breakpoint mixin) and never seen that piece of code being generated. |
Sure, if you mean https://github.com/zurb/foundation-sites/blob/develop/dist/css/foundation.css#L8 |
Then it should be only in |
Does it generate code when importing Foundation without calling any mixin. @import "foundation-sites';
// and that's all |
The following does add the code at the top:
|
Without calling anything else it is not added. |
But imo the current way how it works (added at the top) is not a very clean solution as it pollutes the statements at the top and changes the order of meaning (between normalize and the foundation-sites header) a bit. |
Let's hear from @kball and @SassNinja what they think about the current code and my proposed solution. So far imo the code should be at the right position to keep the context. |
Does it make more sense to have this piece of code next to the Reveal codeYes, obviously. Not because we would like to have the generated code more beautiful (we don't care, it will be minified anyway) but because CSS rules generated first are overriden by the next ones. Can we make this being generated at the right placeAs said previously, we can't without introducing a bug. As The only solution is to move it to a dedicated mixin that must be called first but does not generate anything. That's an initialization step, and the current Foundation Sass architecture does not have it (only configuration, import and execution). Is this code being generated at the wrong place a bug (or shoud it be resolved)It would if it introduced a specificity issue, or if code was generated at the import step (this is what I understood from #11086 (comment)). Actually it does not that. So it's not a bug, just not perfect and a bit ugly in the distribution files. So it's a much too minor issue to change the Sass architecture for it (but we can keep it in mind for v7). What do you think ? |
That's what would have been my next question and step: Shouldn't we isolate this in a separate mixin? |
Yes, something like |
Agreed. |
left: auto; | ||
margin: 0 auto; | ||
} | ||
} |
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.
Introduce a bug when reveal-modal-width
is called without foundation-reveal
.
See #10101 |
I saw it already but we still need to wrap this in a mixin imho. |
Agreed but #11087 (comment) ;) |
No description provided.