Template:FurnitureGallery/doc/en

From Palia Wiki
Jump to navigation Jump to search

Usage

A basis for including a Gallery of Images for a Furniture page.

By default when using the {{FurnitureGallery/doc}} template, 3 images are included automatically (if they exist):

  • UntranslatedPagename.png The main Icon for the Furniture Item
  • UntranslatedPagename Ingame.png An in-game screenshot of the Furniture Item
  • Furniture Wiki Gallery Placeholder.png As a call-to-action that can be removed from the template later on.

Syntax

{{FurnitureGallery|File:image.png|Description}}
Parameters Description
File Name Name of the File (Must start with File: and be the full file name, eg; File:Caleri's Teapot.png)
Description Optional. Adds a description under the image.

Examples

A number of code styles can be used, whichever may be easier to read and understand in the editor.

Basic File and Description

{{FurnitureGallery
 |File:image1.png|Description 1
 |File:image2.png|Description 2
}}
{{FurnitureGallery
 |File:image.png
   |Description
}}
{{FurnitureGallery
 |File:image1.png
   |Description 1
 |File:image2.png
   |Description 2
 |File:image3.png
   |Description 3
}}
{{FurnitureGallery
 |File:image1.png
 |File:image2.png
 |File:image3.png
   |Description 3
}}


Image Properties

Additional Image properties can be added to each image along with the Galleries description, however due to Template syntax additional care must be used to escape special characters (To prevent weird formatting problems).

  • Each image property following the Description should be separated by {{!}}, which will convert into a pipe character (|)
  • Typing an equal sign (=) will cause the attribute to be treated as a named template parameter. {{=}} should be used in it's place.

Added Alt Text

The alternative text can be overridden in situations where an image fails to load, or a user is making use of a screen reader to assist in reading the page.

{{FurnitureGallery/doc
 |File:image1.png|Description 1{{!}}alt{{=}}Alternative image text
 |File:image2.png|Description 2{{!}}alt{{=}}More alternative text
}}

Added Page Link

Images by default will link to their image page, such as [[:File:image1.png]], this behavior can be overridden by providing a link= to another page.

{{FurnitureGallery/doc
 |File:image1.png|Description 1{{!}}link{{=}}[[Some Other Page]]
 |File:image2.png|Description 2{{!}}link{{=}}[[Also Another Page]]
}}

Related