Opened 11 years ago
Closed 11 years ago
#27376 closed enhancement (fixed)
Gallery Live Preview img width css
Reported by: | cramdesign | Owned by: | azaozz |
---|---|---|---|
Milestone: | 3.9 | Priority: | normal |
Severity: | normal | Version: | 3.9 |
Component: | Editor | Keywords: | has-patch |
Focuses: | ui, administration | Cc: |
Description (last modified by )
The live preview for galleries uses percentages to define the width of .gallery-item. It would be more elegant if .gallery img used:
max-width: 100%; height: auto;
Looks like this should be in wp-content.css around line 337.
The widths of gallery-items could also be more precisely set if padding were used for separation rather than margin. This would require the use of border-box sizing however.
I have these changes tested and they work. A side benefit is that a horizontal scrollbar is no longer triggered by the gallery images when they overflow.
The captions in galleries with high column counts can get super narrow and the type distinctly ugly at narrow sizes but the only fix would be to reflow the columns in a responsive fashion and this is not the intent of the preview.
I would love to submit a patch but I haven't a clue with svn and barely a clue with git.
Take a look at http://make.wordpress.org/core/handbook/working-with-trac/submitting-a-patch/.