Jump to content

Template:Link Label/doc

From The Petit Planet Wiki
This is the documentation page for Link Label.
It contains usage information, categories, and other content not part of the original template page.
This template uses Module:Link Label, a script written in Lua.

Creates a link from the input text in first argument.

If the input is already a link and has a label ([[link|label]]), then the unmodified input is returned.

If the input contains multiple links, then the unmodified input is returned.

If the input text contains any of the following, including a single space before, then a label is added with the text removed.

  • (Quest)
  • (Chapter)
  • (Act)
  • (Archon Quest)
  • (Story Quest)
  • (World Quest)
  • (Hangout Event)
  • (Event Quest)
  • (Event Chapter)
  • (Event Act)
  • (Commission)
  • (Soundtrack)
  • (Album)
  • (Event)
  • (NPC)
  • (Furnishing)
  • (Subarea)
  • (Area)
  • (Subregion)
  • (Domain)
  • (Quest Domain)
  • (Instance)
  • (Footprint)
  • (Character Card)
  • (Character Card Skill)
  • (Event Card)
  • (Equipment Card)
  • (Material)

Syntax

[edit source]

{{Link Label|text}}

  • nolink — insert as 1 to return as plain text
  • 2 — insert as , or . to append it to the text, while following American English rules
  • comma — insert as 1 to append a comma to the text, while following American English rules
  • dot — insert as 1 to append a dot to the text, while following American English rules
  • commaspc — insert as 1 to append a comma and a space to the text, while following American English rules
  • dotspc — insert as 1 to append a dot and a space to the text, while following American English rules

Examples

[edit source]

{{Link Label}} yields:
{{Link Label|Genshin Impact Wiki}} yields: Genshin Impact Wiki
{{Link Label|[[Genshin Impact Wiki]]}} yields: Genshin Impact Wiki
{{Link Label|[[Genshin Impact Wiki|Main Page]]}} yields: Main Page
{{Link Label|[[Characters]], [[Weapons]], and [[Artifacts]]}} yields: Characters, Weapons, and Artifacts
{{Link Label|Wishes (Quest)}} yields: Wishes
{{Link Label|Liyue (Soundtrack)}} yields: Liyue
{{Link Label|"Page with Quotes"|dotspc = 1}} yields: "Page with Quotes." (ending text)
{{Link Label|"Page with Quotes"|commaspc = 1}} yields: "Page with Quotes," (ending text)
{{Link Label|"Page with Quotes"|dot = 1}} yields: "Page with Quotes."
{{Link Label|"Page with Quotes"|comma = 1}} yields: "Page with Quotes,"
{{Link Label|"Page with Quotes"|,}} yields: "Page with Quotes,"
{{Link Label|"Page with Quotes"|.}} yields: "Page with Quotes."
{{Link Label|Trixie|dot = 1}} yields: Trixie.
{{Link Label|Trixie|comma = 1}} yields: Trixie,
{{Link Label|Trixie|,}} yields: Trixie,
{{Link Label|Trixie|.}} yields: Trixie.
{{Link Label|Trixie|.|nolink = 1}} yields: Trixie.

Template Data

[edit source]

Creates a link from the input text.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Text1

Text to add link and label with terms replaced.

Stringrequired
Suffix2

Append a comma (,) or a dot (.) to the end of the link, by inserting which is wanted, while following American English rules.

Example
,
Stringoptional
Suffix commacomma

Append a comma to the end of the link, while following American English rules.

Booleanoptional
Suffix comma and spacecommaspc

Append a comma and a space to the link while following American English rules

Booleanoptional
Suffix dotdot

Append a dot to the end of the link, while following American English rules.

Booleanoptional
Suffix dot and spacedotspc

Append a dot and a space to the link while following American English rules

Booleanoptional