[wp-trac] [WordPress Trac] #63553: Administration: Color Schemes are not properly applied on individual attachment within media views

WordPress Trac noreply at wordpress.org
Tue Jun 10 09:40:40 UTC 2025


#63553: Administration: Color Schemes are not properly applied on individual
attachment within media views
-------------------------------------+-----------------------------
 Reporter:  yogeshbhutkar            |      Owner:  (none)
     Type:  defect (bug)             |     Status:  new
 Priority:  normal                   |  Milestone:  Awaiting Review
Component:  Administration           |    Version:
 Severity:  normal                   |   Keywords:
  Focuses:  ui, css, administration  |
-------------------------------------+-----------------------------
 In the Media Library dialog, where users select from listed attachments,
 individual attachments do not fully reflect the user's selected color
 scheme. This is often due to CSS specificity issues, that is, styles in
 `media-views.css` have higher specificity and override the selected color
 scheme styles. Ideally, the specificity of styles within `media-views.css`
 should match that of the color scheme styles to allow proper theming
 overrides.


 Ref:
 https://github.com/WordPress/wordpress-
 develop/blob/20e4872868780fd9246d8a7ec5ae3072b69483ea/src/wp-includes/css
 /media-views.css#L1128

 https://github.com/WordPress/wordpress-
 develop/blob/20e4872868780fd9246d8a7ec5ae3072b69483ea/src/wp-
 admin/css/colors/_admin.scss#L572

 In the snippets above, notice that the `.wp-core-ui` is omitted from
 `_admin.scss`, which leads to lower CSS specificity, and the color scheme
 styles do not get properly applied. Also, notice the extra theme-related
 styles (example: for the `:focus` pseudo-selector) which are also omitted
 altogether from `_admin.scss`.

 This bug is quite noticeable for users using administration color schemes
 other than the default within the Gutenberg Editor.

 To reproduce, perform the following steps:
 1. Set a different administration color scheme (preferably Midnight).
 2. Create a new post and insert a `core/file` block.
 3. Click on `Media Library` and click on a particular attachment.
 4. Notice that the attachment selection styles do not comply with the
 selected administration color scheme.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/63553>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list