1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-30 09:20:58 +01:00
phorge-phorge/webroot/rsrc/css/application/base
epriestley 87ccca32b6 Add printable support to CSS
Summary:
Fixes T2146. This is a really simple approach, you just do:

  !print .rule {
    whatever: blah;
  }

And it transforms it into:

  .printable .rule {
    whatever: blah;
  }

  @media print {
    .rule {
      whatever: blah;
    }
  }

So we end up with these rules twice, but they should compress well and we shouldn't need that many of them, and this fix is way way simpler than all the nonsense I discussed in T2146.

Test Plan:
  - Added a unit test.
  - Added a simple rule to throw away the menubar when printing.
  - Checked the latter with `/?__print__=1`.

Reviewers: chad, btrahan

Reviewed By: chad

CC: chad, aran

Maniphest Tasks: T2146

Differential Revision: https://secure.phabricator.com/D7363
2013-10-19 14:23:19 -07:00
..
main-menu-view.css Add printable support to CSS 2013-10-19 14:23:19 -07:00
notification-menu.css Move #888 and #999 to $lightgreytext 2013-09-02 08:12:18 -07:00
phabricator-application-launch-view.css Fix hovers on mobile menus. 2013-06-12 10:30:15 -07:00
standard-page-view.css Distinguish between invalid/broken handles and filtered handles 2013-10-17 10:49:21 -07:00