Skip to:
Content

bbPress.org

Opened 8 years ago

Closed 8 years ago

#3012 closed enhancement (fixed)

Use of media='screen'

Reported by: destac's profile Destac Owned by: johnjamesjacoby's profile johnjamesjacoby
Milestone: 2.6 Priority: low
Severity: minor Version: 2.5.10
Component: Appearance - Theme Compatibility Keywords: has-patch has-screenshots
Cc:

Description

There doesn't appear to be any reasoning from my testing to make use of media='screen'. The reason I found this issue was while working with Autoptimize it was combining the CSS except for the bbPress file (because as the author highlighted it combines by the media type) So naturally I had 2 files as opposed to one and it caused display issues.

I managed to fix this issue by changing the default media type to screen and everything appears to still be functional.

How To Fix

Line 151 in bbpress/templates/default/bbpress-functions.php changing that to all solves the issue.

A second time this appears is around line 218 of the same file for a js file.

It makes more sense for these to all be set to "all" because it's simply not needed from my understanding screen applies to all phones, computers, etc etc.

Any thoughts?

Links Referenced
Blog Post: http://blog.futtta.be/2016/10/04/how-to-fix-css-media-types-impacting-autoptimized-css-order/

Autoptimize: https://wordpress.org/plugins/autoptimize/

Attachments (1)

3012.diff (589 bytes) - added by thebrandonallen 8 years ago.

Download all attachments as: .zip

Change History (4)

@thebrandonallen
8 years ago

#1 @thebrandonallen
8 years ago

  • Component changed from General to Appearance - Theme Compatibility
  • Keywords has-patch has-screenshots added
  • Milestone changed from Awaiting Review to 2.6

This seems reasonable. The side benefit being that we greatly improve styling when printing.

Current behavior when printing: https://cloudup.com/c7pQXv1rzlo
Printing after patch: https://cloudup.com/chjzCe8K_wn

Both of these were printed while using the Twenty Ten theme.

#3 @johnjamesjacoby
8 years ago

  • Owner set to johnjamesjacoby
  • Resolution set to fixed
  • Status changed from new to closed

In 6261:

Assets: Remove screen restriction on default template pack styling.

Improves styling when printing and third-party plugins (like Autoptimize.)

Props thebrandonallen. Fixes #3012.

Note: See TracTickets for help on using tickets.