This CSS rule is generalized too much and should target specific images.

.page-admin #content img {
  margin-right: 15px;
}

Every module displaying images in admin pages will probably have to override it.
I can not provide a patch because I'm not sure which images this rule targets actually. It might be the theme screenshots.

CommentFileSizeAuthor
#5 bartik-remove-admin-image-styles.patch903 bytesJeff Burnz

Comments

jensimmons’s picture

Status: Active » Postponed (maintainer needs more info)

Can you provide a specific example of where this is a problem? Are you assuming Bartik is the admin theme?

ufku’s picture

In other words, when bartik theme is active on an admin page this unusual margin applies to all images inside the #content area. That css rule should be targeting specific images. I don't know for which images was it implemented. That was probably for theme screenshots.

Whoever uses images in his/her module's admin UI, will probably want to override the rule because 15px margin is not a usual value.

jensimmons’s picture

Status: Postponed (maintainer needs more info) » Active

.

Jeff Burnz’s picture

Two places I can think of are the Appearance page and the Image Styles pages (when you edit a style), I looked at both and this CSS is not needed for either, perhaps there are more places I don't recall right now. Certainly at the moment this is not breaking anything, but its also not really doing anything either.

Jeff Burnz’s picture

Status: Active » Needs review
StatusFileSize
new903 bytes

This is redundant also:

.page-admin #admin-dblog img {
  margin: 0 5px;
}

Removing this:

.page-admin #content img {
  margin-right: 15px;
}

Would make this redundant as well...

.page-admin #content .simpletest-image img {
  margin: 0;
}

Therefore that's exactly what I think we should do.

ufku’s picture

Yes, dblog table uses bg images. I think this is RTBC.

Status: Needs review » Closed (outdated)

Automatically closed because Drupal 7 security and bugfix support has ended as of 5 January 2025. If the issue verifiably applies to later versions, please reopen with details and update the version.