Jump to content

Transclude

From Honkai: Nexus Anima Wiki
Revision as of 13:01, 1 September 2025 by Raven.Familiar (talk | contribs) (Taken from HSR)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Documentation icon Template documentation
Note: parts of or the entire template might not be visible without values provided.

Used to Transclude articles and sections of articles by using the parser tags {{#lsth:}} and {{#lst:}}.

Any attempt at invalid transclusion will add the article to Category:Pages with Invalid Transclusions.

For the transclusion of repeated name sections, include lua=1 to use Module:Transclude instead of the aforementioned parser functions.

A tracking category will be added to the page if some specific section is transcluded, which can be one of the following:

Syntax

[edit source]
Header Section Transclusion

{{Transclude|page name|section name}}

Labeled Section Transclusion

{{Transclude|page name|section name|section = 1}}

Examples

[edit source]
Default Transclude

{{Transclude|Nanafey|Description}} yields:


Transclude with main link
{{Transclude|Trait|Known Traits|main = 1}} yields:

Transclude before first heading with link
{{Transclude|Blaster|main = 1}} yields:


Blaster is one of the Traits possessed by Anima in Honkai: Nexus Anima.


Transclude section with main, label, and link to top
{{Transclude|Kiana|Introduction|top = 1|main = 1|section = 1|label = Animaster}} yields:

Advanced Usage

[edit source]

Template and module code can detect whether they are being transcluded by this template by checking the value of {{#var:transclude}}.

From template code

[edit source]
{{#ifeq:{{#var:transclude}}|1|I'm being transcluded!|I'm not being transcluded.}}

From module code

[edit source]
if tonumber(frame:callParserFunction('#var:transclude', '') or '0') == 1 then
	-- special logic for transclusions
end

Example implementation: Module:Shop

Template Data

[edit source]

Used Transclude articles and sections of articles.

Template parameters[Edit template data]

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Page1 page

Page Name

Stringrequired
Heading2 heading

Heading Name

Stringsuggested
Use Sectionsection

Set to 1 to use {{#lst:}}

Booleanoptional
Show Main Linkmain

Set to 1 to use {{Main}}

Booleansuggested
Main Labellabel

Label of the Main Link

Stringoptional
Link to Toptop

Set to 1 to set Main Link to Top of Page

Booleanoptional
Repeated Sectionlua

Include to allow the transclusion of repeated named sections by utilizing the module version instead of the parser function

Booleanoptional