Page MenuHomePhabricator

Template arguments providing multiple image options
Open, Needs TriagePublic

Description

From https://bh.wikipedia.org/wiki/%E0%A4%9F%E0%A5%87%E0%A4%AE%E0%A5%8D%E0%A4%AA%E0%A4%B2%E0%A5%87%E0%A4%9F:Comparison_newspaper_size.svg

Example,

[[File:Comparison newspaper size.svg|thumb|{{{1|right{{!}}300px}}}|Comparison of some newspaper sizes with metric paper sizes. Approximate nominal dimensions are in millimetres.]]

Event Timeline

This is an interesting case, and maybe related to T318433#10397735 (#media) and T204366#10772988 (varargs). The semantics of {{!}} are always so dodgy. Presumably it is supposed to be "only evaluated at top level", and so we should accept it as a synonym for | in image option lists (but only at top level).

In theory this could be rewritten as:

{{#media:src=File:Comparison newspaper size.svg|style=thumb|...={{{1|{{#kv:align=right|width=300px}}}}}|caption=Comparison of some newspaper sizes with metric paper sizes. Approximate nominal dimensions are in millimetres.}}

which doesn't require leaning on {{!}}. See https://en.wikipedia.org/wiki/User:Cscott/Ideas/A_Dozen_Visions_for_Wikitext/Varargs