Page MenuHomePhabricator

UI elements appear in the printing view
Closed, DuplicatePublic

Description

What I did

i wanted to print a wikidata item page ,

What I expected to happen

i expected to see only things that make sense on paper

What happened instead

there are elements which the user cant use on paper

  • edit liks
  • add reference
  • more languages
  • configure

printing wikidata.png (532×1 px, 95 KB)

Event Timeline

We briefly discussed the reasons for the UI being shown. One hypothesis was that the printing view is different than what you get if you print the page directly because javascript does not run.

While I did not check the JavaScript hypothesis directly there are indeed differences

In-Wiki Print view:

Screenshot from 2016-06-06 14-55-19.png (171×1 px, 10 KB)

Browser Print Preview:

Screenshot from 2016-06-06 14-55-56.png (135×892 px, 5 KB)

In the browser the GUI elements like the edit-pencil are absent but useless links are still shown

Why ever these differences exists, it is probably the best to solve these via the printing stylesheet, so no matter how the elements are drawn they are displayed (or not displayed) properly.

Jan_Dittrich renamed this task from UI elements are appeared in the printing view to UI elements appeare in the printing view.Jun 9 2016, 7:44 AM

@aude: It seems that wikibase just applies the normal Mediawiki print style and does not add anything on its own. Is this right? If we want to change this, do you know which file would get the @media:print (I assume adding the styles to get rid of printed buttons is easy, but I don't know where I would make this change)

Addshore renamed this task from UI elements appeare in the printing view to UI elements appear in the printing view.Jun 22 2016, 1:03 PM