Category:Includes raw templates: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
m (→‎top: clean up, replaced: {{ModernNote| → {{note|)
 
(8 intermediate revisions by one other user not shown)
Line 1: Line 1:
This category contains pages that, due to a limitation of the engine, use template styles and tags instead of using templates themselves.
This category contains pages that, due to a limitation of the engine, use template content instead of using templates themselves. Below are small examples of what it looks like.


For example, you wanted to insert an Markdown Quote template for a prettier view of the list of various functions and their descriptions, but the engine, due to its limitations, does not allow you to use this template on a huge amount of One-Line Code. After that you go to the Markdown Quote template page, take the basis in the form of {{MdCode|outline|<nowiki>div</nowiki>}} elements and insert into the article, thereby creating a raw template.
 
'''Template:'''
 
{{CodeBlock|style=1|<nowiki>{{MdCodeBlock|outline|Hello World}}</nowiki>}}
 
 
'''Raw Template:'''
 
{{CodeBlock|style=1|<nowiki><div id="Template:MdCodeBlock" style="background-color: rgba(0,0,0,.3); border-radius: 4px; overflow: auto; font-family: monospace; font-size: 1.2em; line-height: 1.125rem; text-indent: 0; white-space: pre-wrap; padding: .5em; margin-top: 6px;">Hello World</div></nowiki>}}
 
{{note|{{Code|style=1|select=1|<nowiki>id="Template:<Name>"</nowiki>}} can be used to identify the template from which the code was taken. A completely optional atribute, but desirable if you used the raw version of the template.}}

Latest revision as of 11:52, 6 January 2024

This category contains pages that, due to a limitation of the engine, use template content instead of using templates themselves. Below are small examples of what it looks like.


Template:

{{MdCodeBlock|outline|Hello World}}


Raw Template:

<div id="Template:MdCodeBlock" style="background-color: rgba(0,0,0,.3); border-radius: 4px; overflow: auto; font-family: monospace; font-size: 1.2em; line-height: 1.125rem; text-indent: 0; white-space: pre-wrap; padding: .5em; margin-top: 6px;">Hello World</div>
Note.pngNote:id="Template:<Name>" can be used to identify the template from which the code was taken. A completely optional atribute, but desirable if you used the raw version of the template.

Pages in category "Includes raw templates"

This category contains only the following page.