Widget:LayoutImage: Difference between revisions
Jump to navigation
Jump to search
Widget to use layouting images. Prototyping this, there should be more checks (srcset, height, width, ...) |
No edit summary |
||
(5 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
<includeonly><img src="<!--{src|escape:' | <includeonly><img src="<!--{$src|escape:'html'}-->" class="<!--{$class|default:''|escape:'html'}-->" style="<!--{$style|default:''|escape:'html'}-->" loading="lazy"/></includeonly><noinclude>== Summary == | ||
Simple widget to display an image as there is no img tag in the MediaWiki Parser anymore. | Simple widget to display an image as there is no img tag in the MediaWiki Parser anymore. | ||
Line 6: | Line 6: | ||
{{Testcase | {{Testcase | ||
|title=Simple call | |title=Simple call | ||
|<pre><nowiki>{{#widget:LayoutImage|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}</nowiki></pre> | |<pre><nowiki>{{#widget:LayoutImage|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}}}</nowiki></pre> | ||
|main={{#widget:LayoutImage|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}}} | |main={{#widget:LayoutImage|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}}} | ||
|sandbox={{#widget:LayoutImage/sandbox|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}}} | |sandbox={{#widget:LayoutImage/sandbox|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}}} |
Latest revision as of 15:18, 23 July 2024
Summary
Simple widget to display an image as there is no img tag in the MediaWiki Parser anymore.
Example usages
Simple call | |
---|---|
Wiki code | {{#widget:LayoutImage|src={{filepath:Icon_{{{2|Holographic Sight}}}.png}}}} |
Main version | ![]() |
Sandbox version | Error in widget LayoutImage/sandbox: Unable to load template 'wiki:LayoutImage/sandbox'
|