Template

Collapsible Map

From Dogcraft Wiki

No edit summary
No edit summary
Line 2: Line 2:
<templatestyles src="Template:Collapsible_Map/styles.css"/>
<templatestyles src="Template:Collapsible_Map/styles.css"/>


<div id="collapsible-container" class="toccolours mw-collapsible {{#ifeq:{{{collapsed|}}}|true|mw-collapsed}}">
<div id="collapsible-container" class="toccolours mw-collapsible {{#ifeq:{{{collapsed|}}}|true|mw-collapsed}}" {{#if:{{{width|}}}|style="max-width: {{{width|}}};"}}>
  <div id="collapsible-container-header" style="text-align: center;"><i class="fa-solid fa-chevron-down" style="color: inherit;"></i><i class="fa-solid fa-chevron-up" style="color: inherit;"></i> {{{name|Map}}}</div>
  <div id="collapsible-container-header" style="text-align: center;"><i class="fa-solid fa-chevron-down" style="color: inherit;"></i><i class="fa-solid fa-chevron-up" style="color: inherit;"></i> {{{name|Map}}}</div>
  <div class="mw-collapsible-content">
  <div class="mw-collapsible-content">
Line 54: Line 54:
<noinclude>
<noinclude>
{{Collapsible Map
{{Collapsible Map
|name      = East Station
|name      = East Station (Scale 1)
|world      = sheltie
|world      = sheltie
|xCoord    = 1434
|xCoord    = 1434
Line 63: Line 63:


{{Collapsible Map
{{Collapsible Map
|name      = East Station
|name      = East Station (Scale 0)
|world      = sheltie
|world      = sheltie
|xCoord    = 1434
|xCoord    = 1434
Line 108: Line 108:
             "default": "0",
             "default": "0",
             "description": "The scale of the map. 0 - 500x500 block map, 1 - 1500x1500 map"
             "description": "The scale of the map. 0 - 500x500 block map, 1 - 1500x1500 map"
        },
        "width": {
            "type": "string",
            "default": "500px",
            "description": "The max width of the map on a wiki page. This is a CSS value. To make the map cover the entire width of the page, set this to '100%'."
         }
         }
     },
     },
Line 118: Line 123:
         "collapsed",
         "collapsed",
         "showCoords",
         "showCoords",
         "scale"
         "scale",
        "width"
]
]
}
}
</templatedata>
</templatedata>
</noinclude>
</noinclude>

Revision as of 11:53, 27 March 2024


East Station (Scale 1)

X:1434, Z:-294 on Sheltie



East Station (Scale 0)

X:1434, Z:-294 on Sheltie


Map Location, shows a part of the map with the given location marked on it

Template parameters

ParameterDescriptionTypeStatus
namename

Name of the location. Used only in the heading

Default
Map
Stringoptional
worldworld

The world the location is on. This needs to match the world name used on the dynmap!

Default
sheltie
Stringoptional
xCoordxCoord

The x coordinate of the location

Default
0
Numberoptional
zCoordzCoord

The z coordinate of the location

Default
0
Numberoptional
collapsedcollapsed

If true, the map is collapsed by default, otherwise it is expanded by default

Default
false
Booleanoptional
showCoordsshowCoords

If true, will display the coordinates and world below the map

Default
false
Booleanoptional
scalescale

The scale of the map. 0 - 500x500 block map, 1 - 1500x1500 map

Default
0
Numberoptional
widthwidth

The max width of the map on a wiki page. This is a CSS value. To make the map cover the entire width of the page, set this to '100%'.

Default
500px
Stringoptional
This page was last modified on 27 March 2024, at 11:53. (30 days ago)