Β |
Β |
| (10 intermediate revisions by the same user not shown) |
| Line 1: |
Line 1: |
| <includeonly><div id="tutorial" style="display:flex; justify-content:center; align-items:center; margin:10px 0;"> | | <includeonly>{{#ifeq: {{NAMESPACE}} | {{ns:Template}} | {{#ifeq: {{#sub:{{ROOTPAGENAME}}|0|8}} | Tutorial | [[Category:Tutorials]] |}} |}}<templatestyles src="Tutorial/styles.css" /><div id="tutorial" style="display:flex; justify-content:center; align-items:center; margin:10px 0;"> |
| <div style="border-bottom:3px solid {{{border|#8b0024}}}; background:{{{background|#e9edef}}}; padding:0.3em 1rem; text-align:center; min-width:{{{min_width|50%}}}; {{{style|}}}"> | | <div style="border-{{#if:{{{nav|}}}|top|bottom}}:3px solid {{{border|#8b0024}}}; background:{{{background|#e9edef}}}; padding:0.3em 1rem; text-align:center; min-width:{{{min_width|50%}}}; {{{style|}}}"> |
| <div style="font-size:20px; font-weight:bold;"><div style="color:gray; font-size:small; margin-bottom:-5px;">{{{name|Tutorial}}}</div>{{{title|Title}}}</div> | | <div style="font-size:20px; font-weight:bold;"><div style="color:gray; font-size:small; margin-bottom:-5px;">{{{name|{{#if:{{{nav|}}}|Tutorial navigation|Tutorial}}}}}</div>{{#if:{{{nav|}}}||{{{title|Title}}}}}</div> |
| <div style="font-style:italic; font-size:14px; color:darkgray;">{{{description|}}}</div> | | <div style="font-style:italic; font-size:14px; color:darkgray;">{{#if:{{{nav|}}}||{{{description|}}}}}</div> |
| <div id="tutorial-nav" style="display:flex; flex-direction:row; align-items:center; justify-content:space-between; text-align:center; padding-top:0.6em;"> | | <div id="tutorial-nav" class="flex-mobile-wrap slim" style="display:flex; flex-direction:row; align-items:center; justify-content:space-between; text-align:center; padding-top:0.3em;"> |
| <span style="font-weight:600; white-space:nowrap;">[[{{{previous}}}|Β« Previous]]</span> | | <span style="font-weight:600; white-space:nowrap;">[[{{{previous}}}|{{Clickable button|Β« Previous||disabled={{#if:{{{start|}}}|1}}}}]]</span> |
| <div id="tutorial-chapters" style="flex-grow:1; margin:0 10px; font-size:85%; word-wrap:anywhere;">{{{chapters|}}}</div> | | <div id="tutorial-chapters" style="flex-grow:1; margin:0 10px; font-size:85%; word-wrap:anywhere;">{{{chapters|}}}</div> |
| <span style="font-weight: 600; white-space:nowrap;">[[{{{next}}}|Next Β»]]</span> | | <span style="font-weight: 600; white-space:nowrap;">[[{{{next}}}|{{Clickable button|Next Β»|color=blue|disabled={{#if:{{{end|}}}|1}}}}]]</span> |
| </div></div></div></includeonly><noinclude>
| | </div></div></div></includeonly><noinclude>{{documentation2}}[[Category:Navigation templates]] {{Interface template}} |
| Β | |
| ==Tutorial template==
| |
| This template is for tying together multiple guide pages into a single tutorial one can step through.
| |
| Β | |
| ==Example==
| |
| <pre style="white-space:pre-line;">{{Tutorial
| |
| |titleΒ Β Β = Starting on Dogcraft | |
| |description = A guide to your first few days on the Dogcraft server & community.<br />Feel free to ask any {{Rank|Helper}}s or staff for assistance! | |
| |previousΒ Β = Rules
| |
| |nextΒ Β Β Β = Features beyond Vanilla
| |
| |chaptersΒ Β = [[Guide:Linking|Account linking]] ([[Guide:Bedrock Account Linking|Bedrock]]) {{*}} [[Rules]] {{*}} [[Worlds]] {{*}} [[Features beyond Vanilla|Server information & features]]
| |
| }}</pre> generates:
| |
| {{Tutorial
| |
| |titleΒ Β Β = Starting on Dogcraft
| |
| |description = A guide to your first few days on the Dogcraft server & community.<br />Feel free to ask any {{Rank|Helper}}s or staff for assistance!
| |
| |previousΒ Β = Rules
| |
| |nextΒ Β Β Β = Features beyond Vanilla
| |
| |chaptersΒ Β = [[Guide:Linking|Account linking]] ([[Guide:Bedrock Account Linking|Bedrock]]) {{*}} [[Rules]] {{*}} '''Worlds''' {{*}} [[Features beyond Vanilla|Server information & features]]
| |
| }}
| |
| Β | |
| ==Template data==
| |
| <noinclude> | |
| <templatedata> | |
| {
| |
| "params": {
| |
| "border": {
| |
| "label": "Border color",
| |
| "description": "The color of the line at the box's bottom",
| |
| "example": "crimson",
| |
| "type": "string"
| |
| },
| |
| "background": {
| |
| "label": "Background color",
| |
| "description": "The box's background color",
| |
| "example": "yellow",
| |
| "type": "string"
| |
| },
| |
| "min_width": {
| |
| "label": "Minimum width",
| |
| "description": "The box's minimum width",
| |
| "type": "string",
| |
| "default": "50%"
| |
| },
| |
| "style": {
| |
| "label": "Further styles",
| |
| "description": "Free-form parameter for adding further CSS styles to the box.",
| |
| "type": "string"
| |
| },
| |
| "name": {
| |
| "label": "(Optional) Name",
| |
| "description": "An alternative name to the gray 'Tutorial' line at the template's top. This should mostly be unused.",
| |
| "type": "string",
| |
| "suggested": true
| |
| },
| |
| "title": {
| |
| "label": "Title",
| |
| "description": "The tutorial's title",
| |
| "example": "Server economy",
| |
| "type": "string",
| |
| "required": true,
| |
| "suggested": true
| |
| },
| |
| "description": {
| |
| "label": "(Optional) Description",
| |
| "description": "A short description of the entire tutorial's purpose.",
| |
| "example": "A guide to your first few days on Dogcraft.",
| |
| "type": "string",
| |
| "suggested": true
| |
| },
| |
| "previous": {
| |
| "label": "Previous chapter",
| |
| "description": "Page name of the previous chapter (guide) for linking",
| |
| "example": "Guide:Account_Linking",
| |
| "type": "wiki-page-name",
| |
| "required": true,
| |
| "suggested": true
| |
| },
| |
| "chapters": {
| |
| "label": "Chapters",
| |
| "description": "A list of links to all the pages which are tied together into the tutorial, usually separated with {{*}}s.",
| |
| "example": "[[Guide:Account Linking]] {{*}} [[Rules]] {{*}} [[Guide:Claiming land]]",
| |
| "type": "string",
| |
| "suggested": true
| |
| },
| |
| "next": {
| |
| "label": "Next chapter",
| |
| "description": "Page name of the next chapter (guide) for linking",
| |
| "example": "Guide:Claiming_land",
| |
| "type": "wiki-page-name",
| |
| "required": true,
| |
| "suggested": true
| |
| }
| |
| },
| |
| "description": "For tying together multiple guide pages into a single step-through tutorial. ",
| |
| "paramOrder": [
| |
| "title",
| |
| "previous",
| |
| "next",
| |
| "chapters",
| |
| "description",
| |
| "name",
| |
| "min_width",
| |
| "border",
| |
| "background",
| |
| "style"
| |
| ],
| |
| "format": "block"
| |
| } | |
| </templatedata>
| |
| </noinclude>
| |