Template:Location Tooltip: Difference between revisions
From HorizonXI Wiki
(added more styling options for custom markers and made code more readable) |
(added documentation and an example) |
||
| Line 32: | Line 32: | ||
-->background:{{default|{{{marker background|}}}|#FF0000}}; <!-- | -->background:{{default|{{{marker background|}}}|#FF0000}}; <!-- | ||
-->opacity:{{default|{{{marker opacity|}}}|1}}; <!-- | -->opacity:{{default|{{{marker opacity|}}}|1}}; <!-- | ||
-->border-radius:{{default|{{{border radius|{{{marker size|}}}}}}|5}}px; | -->border-radius:{{default|{{{marker border radius|{{{marker size|}}}}}}|5}}px; | ||
}}}}<!-- | }}}}<!-- | ||
| Line 57: | Line 57: | ||
-->background:{{default|{{{marker background 2|}}}|#FF0000}}; <!-- | -->background:{{default|{{{marker background 2|}}}|#FF0000}}; <!-- | ||
-->opacity:{{default|{{{marker opacity 2|}}}|1}}; <!-- | -->opacity:{{default|{{{marker opacity 2|}}}|1}}; <!-- | ||
-->border-radius:{{default|{{{border radius 2|{{{marker size 2|}}}}}}|5}}px; | -->border-radius:{{default|{{{marker border radius 2|{{{marker size 2|}}}}}}|5}}px; | ||
}}}}<!-- | }}}}<!-- | ||
| Line 82: | Line 82: | ||
-->background:{{default|{{{marker background 3|}}}|#FF0000}}; <!-- | -->background:{{default|{{{marker background 3|}}}|#FF0000}}; <!-- | ||
-->opacity:{{default|{{{marker opacity 3|}}}|1}}; <!-- | -->opacity:{{default|{{{marker opacity 3|}}}|1}}; <!-- | ||
-->border-radius:{{default|{{{border radius 3|{{{marker size 3|}}}}}}|5}}px; | -->border-radius:{{default|{{{marker border radius 3|{{{marker size 3|}}}}}}|5}}px; | ||
}}}}<!-- | }}}}<!-- | ||
| Line 107: | Line 107: | ||
-->background:{{default|{{{marker background 4|}}}|#FF0000}}; <!-- | -->background:{{default|{{{marker background 4|}}}|#FF0000}}; <!-- | ||
-->opacity:{{default|{{{marker opacity 4|}}}|1}}; <!-- | -->opacity:{{default|{{{marker opacity 4|}}}|1}}; <!-- | ||
-->border-radius:{{default|{{{border radius 4|{{{marker size 4|}}}}}}|5}}px; | -->border-radius:{{default|{{{marker border radius 4|{{{marker size 4|}}}}}}|5}}px; | ||
}}}}<!-- | }}}}<!-- | ||
| Line 132: | Line 132: | ||
-->background:{{default|{{{marker background 5|}}}|#FF0000}}; <!-- | -->background:{{default|{{{marker background 5|}}}|#FF0000}}; <!-- | ||
-->opacity:{{default|{{{marker opacity 5|}}}|1}}; <!-- | -->opacity:{{default|{{{marker opacity 5|}}}|1}}; <!-- | ||
-->border-radius:{{default|{{{border radius 5|{{{marker size 5|}}}}}}|5}}px; | -->border-radius:{{default|{{{marker border radius 5|{{{marker size 5|}}}}}}|5}}px; | ||
}}}}<!-- | }}}}<!-- | ||
| Line 157: | Line 157: | ||
-->background:{{default|{{{marker background 6|}}}|#FF0000}}; <!-- | -->background:{{default|{{{marker background 6|}}}|#FF0000}}; <!-- | ||
-->opacity:{{default|{{{marker opacity 6|}}}|1}}; <!-- | -->opacity:{{default|{{{marker opacity 6|}}}|1}}; <!-- | ||
-->border-radius:{{default|{{{border radius 6|{{{marker size 6|}}}}}}|5}}px; | -->border-radius:{{default|{{{marker border radius 6|{{{marker size 6|}}}}}}|5}}px; | ||
}}}}<!-- | }}}}<!-- | ||
| Line 178: | Line 178: | ||
[[Category:Templates|{{PAGENAMEE}}]] | [[Category:Templates|{{PAGENAMEE}}]] | ||
==Usage== | ==Usage== | ||
<pre> | Note: {2...6} means that additional parameters exist with numbers 2 to 6. E.g. pos {2...6} means that pos, pos 2, pos 3, pos 4, pos 5, pos 6 all can be used<pre> | ||
{{Location Tooltip | {{Location Tooltip | ||
| area = | | area = | ||
| pos | | pos {2...6} = | ||
| map = | | map = | ||
| id = | | id = | ||
| Line 193: | Line 188: | ||
| tooltip = | | tooltip = | ||
| opacity = | | opacity = | ||
| highlight offset x = | | highlight offset {2...6} x = | ||
| highlight offset y = | | highlight offset {2...6} y = | ||
| highlight background = | | highlight background {2...6} = | ||
| highlight opacity = | | highlight opacity {2...6} = | ||
| | | highlight width {2...6} = | ||
| | | highlight height {2...6} = | ||
| marker pos 2 x = | | marker pos {2...6} x = | ||
| marker pos 2 y = | | marker pos {2...6} y = | ||
| marker | | marker background {2...6} = | ||
| marker | | marker opacity {2...6} = | ||
| marker | | marker size {2...6} = | ||
| marker border radius {2...6} = | |||
| marker | |||
}} | }} | ||
</pre> | </pre> | ||
| Line 217: | Line 205: | ||
*'''area''': The map's [[:Category:Areas|area]]. Required. | *'''area''': The map's [[:Category:Areas|area]]. Required. | ||
*'''pos''': The position within the map, such as H-6 or B-5. | *'''pos''': The position within the map, such as H-6 or B-5. | ||
**Optional: '''pos 2''', '''pos 3''', '''pos 4''', '''pos 5''', '''pos 6''' | **Optional: '''pos 2''', '''pos 3''', '''pos 4''', '''pos 5''', '''pos 6''' with their respective stylings | ||
*'''map''': The specific map to be used, such as "Map 2". | *'''map''': The specific map to be used, such as "Map 2". | ||
*'''id''': A unique id to give to the tooltip. Use if the same location is repeated on the same page. | *'''id''': A unique id to give to the tooltip. Use if the same location is repeated on the same page. | ||
| Line 226: | Line 214: | ||
*'''highlight offset x''': An offset to correct the x positioning of the highlight box. | *'''highlight offset x''': An offset to correct the x positioning of the highlight box. | ||
*'''highlight offset y''': An offset to correct the y positioning of the highlight box. | *'''highlight offset y''': An offset to correct the y positioning of the highlight box. | ||
*'''highlight width''': Width of the highlight box | |||
*'''highlight height''': Heigh of the highlight box | |||
*'''highlight background''': The background styling of the highlight box. | *'''highlight background''': The background styling of the highlight box. | ||
*'''highlight opacity ''': The opacity of the highlight box. | *'''highlight opacity ''': The opacity of the highlight box. | ||
*'''marker pos x''': The x position of the marker within the highlight box. | *'''marker pos x''': The x position of the marker within the highlight box. | ||
**Optional: '''marker pos 2 x''', '''marker pos 3 x''', '''marker pos 4 x''', '''marker pos 5 x''', '''marker pos 6 x''' | **Optional: '''marker pos 2 x''', '''marker pos 3 x''', '''marker pos 4 x''', '''marker pos 5 x''', '''marker pos 6 x''' with their respective stylings | ||
*'''marker pos y''': The y position of the marker within the highlight box. | *'''marker pos y''': The y position of the marker within the highlight box. | ||
**Optional: '''marker pos 2 y''', '''marker pos 3 y''', '''marker pos 4 y''', '''marker pos 5 y''', '''marker pos 6 y''' | **Optional: '''marker pos 2 y''', '''marker pos 3 y''', '''marker pos 4 y''', '''marker pos 5 y''', '''marker pos 6 y''' with their respective stylings | ||
*'''marker background''': The background styling of the marker. | *'''marker background''': The background styling of the marker. | ||
*'''marker opacity''': The opacity of the marker. | *'''marker opacity''': The opacity of the marker. | ||
*'''marker size''': The size of the marker. | *'''marker size''': The size of the marker. | ||
*'''marker border radius''': The 'roundness' of the marker. | |||
===Examples=== | ===Examples=== | ||
| Line 398: | Line 389: | ||
| pos 3 = M-10 | | pos 3 = M-10 | ||
| pos 4 = M-11 | | pos 4 = M-11 | ||
}} | |||
|- | |||
| | |||
<pre> | |||
{{Location Tooltip | |||
| area = Pso'Xja | |||
| map = Map 2 | |||
| pos = J-7 | |||
| highlight background = transparent | |||
| marker pos x = 2 | |||
| marker pos y = 16 | |||
| marker size = 14 | |||
| marker opacity = 0.4 | |||
| marker border radius = 0 | |||
| text = Drop "L" | |||
}} | |||
</pre> | |||
| | |||
{{Location Tooltip | |||
| area = Pso'Xja | |||
| map = Map 2 | |||
| pos = J-7 | |||
| highlight background = transparent | |||
| marker pos x = 2 | |||
| marker pos y = 16 | |||
| marker size = 14 | |||
| marker opacity = 0.4 | |||
| marker border radius = 0 | |||
| text = Drop "L" | |||
}} | }} | ||
|} | |} | ||
Revision as of 12:19, 27 June 2025
Usage
Note: {2...6} means that additional parameters exist with numbers 2 to 6. E.g. pos {2...6} means that pos, pos 2, pos 3, pos 4, pos 5, pos 6 all can be used
{{Location Tooltip
| area =
| pos {2...6} =
| map =
| id =
| text =
| link =
| tooltip =
| opacity =
| highlight offset {2...6} x =
| highlight offset {2...6} y =
| highlight background {2...6} =
| highlight opacity {2...6} =
| highlight width {2...6} =
| highlight height {2...6} =
| marker pos {2...6} x =
| marker pos {2...6} y =
| marker background {2...6} =
| marker opacity {2...6} =
| marker size {2...6} =
| marker border radius {2...6} =
}}
Displays a tooltip map of the area.
- area: The map's area. Required.
- pos: The position within the map, such as H-6 or B-5.
- Optional: pos 2, pos 3, pos 4, pos 5, pos 6 with their respective stylings
- map: The specific map to be used, such as "Map 2".
- id: A unique id to give to the tooltip. Use if the same location is repeated on the same page.
- text: The text to display. Defaults to the pos if it is provided or the area and map if the pos is not provided.
- link: Option to change the clickable link of the text.
- tooltip: The tooltip to display. Defaults to the labeled section in of the area maps subpage.
- opacity: The opacity of the tooltip.
- highlight offset x: An offset to correct the x positioning of the highlight box.
- highlight offset y: An offset to correct the y positioning of the highlight box.
- highlight width: Width of the highlight box
- highlight height: Heigh of the highlight box
- highlight background: The background styling of the highlight box.
- highlight opacity : The opacity of the highlight box.
- marker pos x: The x position of the marker within the highlight box.
- Optional: marker pos 2 x, marker pos 3 x, marker pos 4 x, marker pos 5 x, marker pos 6 x with their respective stylings
- marker pos y: The y position of the marker within the highlight box.
- Optional: marker pos 2 y, marker pos 3 y, marker pos 4 y, marker pos 5 y, marker pos 6 y with their respective stylings
- marker background: The background styling of the marker.
- marker opacity: The opacity of the marker.
- marker size: The size of the marker.
- marker border radius: The 'roundness' of the marker.
Examples
| Code | Result |
|---|---|
{{Location Tooltip
| area = Windurst Walls
}}
|
|
{{Location Tooltip
| area = Windurst Waters
| map = South
}}
|
|
{{Location Tooltip
| area = Northern San d'Oria
| pos = L-10
}}
|
|
{{Location Tooltip
| tooltip = [[File:RuAunGardensMain.png]]
| area = Ru'Aun Gardens
| pos = H-10
}}
|
|
{{Location Tooltip
| tooltip = [[File:GarlaigeCitadel2.png]]
| area = Garlaige Citadel
| map = Map 2
| pos = G-6
}}
|
|
{{Location Tooltip
| tooltip = [[File:SouthernSandOria.png]]
| area = Southern San d'Oria
| pos = J-9
| marker pos x = 3
| marker pos y = 7
}}
|
|
{{Location Tooltip
| id = Derfland Regional Merchant
| tooltip = [[File:SouthernSandOria.png]]
| area = Southern San d'Oria
| pos = J-9
| highlight background = transparent
| marker pos x = 3
| marker pos y = 7
}}
|
|
{{Location Tooltip
| text = Valkurm Emperor
| tooltip = [[File:Valkurm Dunes.png]]
| area = Valkurm Dunes
| pos = E-8
| highlight background = transparent
| marker pos x = 2
| marker pos y = -7
| marker size = 35
| marker opacity = 0.4
| marker background = #5555ff
}}
|
|
{{Location Tooltip
| area = Northern San d'Oria
| pos = L-10
| pos 2 = L-11
| pos 3 = M-10
| pos 4 = M-11
}}
|
|
{{Location Tooltip
| area = Pso'Xja
| map = Map 2
| pos = J-7
| highlight background = transparent
| marker pos x = 2
| marker pos y = 16
| marker size = 14
| marker opacity = 0.4
| marker border radius = 0
| text = Drop "L"
}}
|








