Difference between revisions of "Template:Fanart/Doc"

From questden
(Document other version of template (currently a redirect))
(Document/test case new feature)
Line 10: Line 10:
 
;board:Specify the board on which to find the post, e.g. <code>|board=quest</code>. The default is ''questdis''.
 
;board:Specify the board on which to find the post, e.g. <code>|board=quest</code>. The default is ''questdis''.
 
;caption:Put a caption below the image. Captions can contain limited markup, but shouldn't be too long.
 
;caption:Put a caption below the image. Captions can contain limited markup, but shouldn't be too long.
 +
;by:Attribute the image's artist. Will be linked automatically.
  
 
= Example =
 
= Example =
Line 16: Line 17:
 
<tr>
 
<tr>
 
<td><pre style="white-space: pre-wrap;"><nowiki>= Fanart =
 
<td><pre style="white-space: pre-wrap;"><nowiki>= Fanart =
{{fanart|857|caption=Why [[Lohrke]]s are known for their hips.}}
+
{{fanart|857|caption=Why [[Lohrke]]s are known for their hips.|by=Lucid}}
 
{{fanart|798}}
 
{{fanart|798}}
 
{{fanart|515|caption=Deme encounters [[Deep|Ven]]}}</nowiki></pre></td>
 
{{fanart|515|caption=Deme encounters [[Deep|Ven]]}}</nowiki></pre></td>
Line 22: Line 23:
  
 
= Fanart =
 
= Fanart =
{{fanart|857|caption=Why [[Lohrke]]s are known for their hips.}}
+
{{fanart|857|caption=Why [[Lohrke]]s are known for their hips.|by=Lucid}}
 
{{fanart|798}}
 
{{fanart|798}}
 
{{fanart|515|caption=Deme encounters [[Deep|Ven]]}}
 
{{fanart|515|caption=Deme encounters [[Deep|Ven]]}}

Revision as of 12:49, 15 October 2011

This is a template documentation page. It is transcluded into place.

This template inlines posts from fanart threads nicely with links to the post. (If you want to inline so other art from the board, use questart, which is otherwise exactly the same.) In short, just pass the post number:

{{fanart|857}}

Which gives:

857.png
LinkToBoard.gif

In practice you probably want to put a whole bunch of these under a = Fanart = heading toward the bottom of the quest's page.


Advanced usage

board
Specify the board on which to find the post, e.g. |board=quest. The default is questdis.
caption
Put a caption below the image. Captions can contain limited markup, but shouldn't be too long.
by
Attribute the image's artist. Will be linked automatically.

Example

MarkupResult
= Fanart =
{{fanart|857|caption=Why [[Lohrke]]s are known for their hips.|by=Lucid}}
{{fanart|798}}
{{fanart|515|caption=Deme encounters [[Deep|Ven]]}}

Fanart

857.png
Why Lohrkes are known for their hips.
By Lucid
LinkToBoard.gif
798.png
LinkToBoard.gif
515.png
Deme encounters VenLinkToBoard.gif

Maintenance notes

  • It depends on the set of redirects that let you look up kusaba resources by post number:
    • …kusaba/thumb-for/board/post…kusaba/board/thumb/thumbnail-filename
    • …kusaba/image-for/board/post…kusaba/board/src/fullsize-image-filename
    • …kusaba/thread-for/board/post…kusaba/board/res/thread.html#post
    • And because MediaWiki is kind of dumb, a hack that lets it ignore a .png extension on these and let the browser sort out the details with Content-Type.
  • It makes assumptions about the maximum size of thumbnail images, namely that they'll never exceed 250px width.
  • It doesn't play nice with galleries because Mediawiki syntax doesn't allow for external images in them.