-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
GalleryBlock: remove unused CSS and cleanup front-end. #2291
Conversation
Maybe @aduth knows :) |
Styling issues could indeed be related to #2160 because the "Portals" implementation there intentionally removes popover content from the CSS cascade, which is nice in that it avoids styles from a parent from affecting the popover content, but not so great for "global" styles. One option is to render the portal into the base of the Gutenberg editor rather than the |
58294ff
to
bb010d2
Compare
blocks/library/gallery/index.js
Outdated
@@ -168,6 +168,7 @@ registerBlockType( 'core/gallery', { | |||
|
|||
save( { attributes } ) { | |||
const { images, columns = defaultColumnsNumber( attributes ), align = 'none', imageCrop = true, linkTo = 'none' } = attributes; | |||
|
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.
This is probably going to cause a conflict for me in #1905 😬
.blocks-gallery__placeholder-instructions { | ||
margin: 1.8em 0; | ||
.wp-block-gallery:not( .components-placeholder ) { | ||
margin-right: -16px; |
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.
Sorta feel the excess margin on gallery images could be better handled by an :nth-of-type( 2n ) { margin-right: 0; }
etc.
047b88a
to
88deabd
Compare
Codecov Report
@@ Coverage Diff @@
## master #2291 +/- ##
==========================================
- Coverage 24.78% 24.66% -0.13%
==========================================
Files 151 152 +1
Lines 4721 4744 +23
Branches 799 800 +1
==========================================
Hits 1170 1170
- Misses 2997 3019 +22
- Partials 554 555 +1
Continue to review full report at Codecov.
|
Closes #2272.