Template:AdvancedTooltip: Difference between revisions
From MalveraWiki
Created page with "<noinclude> {{Documentation}} </noinclude> <div class="tooltip-wrapper"> <span class="tooltip-title">{{{title}}}</span> <div class="custom-tooltip"> <div style="display: flex; justify-content: space-between;"> <table style="width: 48%;"> <tr> <th>Attribute</th> <th>Chance</th> </tr> <tr> <td>Value 1</td> <td>{{{chance..." |
No edit summary |
||
| Line 1: | Line 1: | ||
<div class="tooltip-wrapper"> | <div class="tooltip-wrapper"> | ||
<span style="border-bottom: 1px dotted #e2d8ff; cursor: help;">{{{1|Hover Me}}}</span> | |||
<div class="custom-tooltip" style="width: auto; max-width: 600px; min-width: 300px;"> | |||
{{#if:{{{name|}}}|<div style="text-align: center; font-weight: bold; font-size: 1.2em; margin-bottom: 8px; border-bottom: 1px solid rgba(255,255,255,0.15); padding-bottom: 5px;">{{{name}}}</div>}} | |||
<div style="display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;"> | |||
{{#if:{{{attr1|}}}| | |||
<div style="flex: 1 1 140px; min-width: 140px;"> | |||
<table class="wikitable" style="margin: 0; width: 100%; text-align: center;"> | |||
<tr> | |||
<th style="text-align: center; color: #cbb4ff;">{{{attr1}}}</th> | |||
<th style="text-align: center; width: 40%; font-size: 0.85em; color: #a89ad1;">Chance</th> | |||
</tr> | |||
<tr> | |||
<td style="text-align: center; vertical-align: top;">{{{val1}}}</td> | |||
<td style="text-align: center; vertical-align: top; color: #ccc;">{{{chance1}}}</td> | |||
</tr> | |||
</table> | |||
</div> | |||
}} | |||
{{#if:{{{attr2|}}}| | |||
<div style="flex: 1 1 140px; min-width: 140px;"> | |||
<table class="wikitable" style="margin: 0; width: 100%; text-align: center;"> | |||
<tr> | |||
<th style="text-align: center; color: #cbb4ff;">{{{attr2}}}</th> | |||
<th style="text-align: center; width: 40%; font-size: 0.85em; color: #a89ad1;">Chance</th> | |||
</tr> | |||
<tr> | |||
<td style="text-align: center; vertical-align: top;">{{{val2}}}</td> | |||
<td style="text-align: center; vertical-align: top; color: #ccc;">{{{chance2}}}</td> | |||
</tr> | |||
</table> | |||
</div> | |||
}} | |||
{{#if:{{{attr3|}}}| | |||
<div style="flex: 1 1 140px; min-width: 140px;"> | |||
<table class="wikitable" style="margin: 0; width: 100%; text-align: center;"> | |||
<tr> | |||
<th style="text-align: center; color: #cbb4ff;">{{{attr3}}}</th> | |||
<th style="text-align: center; width: 40%; font-size: 0.85em; color: #a89ad1;">Chance</th> | |||
</tr> | |||
<tr> | |||
<td style="text-align: center; vertical-align: top;">{{{val3}}}</td> | |||
<td style="text-align: center; vertical-align: top; color: #ccc;">{{{chance3}}}</td> | |||
</tr> | |||
</table> | |||
</div> | |||
}} | |||
{{#if:{{{attr4|}}}| | |||
<div style="flex: 1 1 140px; min-width: 140px;"> | |||
<table class="wikitable" style="margin: 0; width: 100%; text-align: center;"> | |||
<tr> | |||
<th style="text-align: center; color: #cbb4ff;">{{{attr4}}}</th> | |||
<th style="text-align: center; width: 40%; font-size: 0.85em; color: #a89ad1;">Chance</th> | |||
</tr> | |||
<tr> | |||
<td style="text-align: center; vertical-align: top;">{{{val4}}}</td> | |||
<td style="text-align: center; vertical-align: top; color: #ccc;">{{{chance4}}}</td> | |||
</tr> | |||
</table> | |||
</div> | |||
}} | |||
</div> | |||
</div> | |||
</div> | </div> | ||
Revision as of 19:43, 2 February 2026
Hover Me
{{#if:|
{{{name}}}
}}
{{#if:|
| {{{attr1}}} | Chance |
|---|---|
| {{{val1}}} | {{{chance1}}} |
}}
{{#if:|
| {{{attr2}}} | Chance |
|---|---|
| {{{val2}}} | {{{chance2}}} |
}}
{{#if:|
| {{{attr3}}} | Chance |
|---|---|
| {{{val3}}} | {{{chance3}}} |
}}
{{#if:|
| {{{attr4}}} | Chance |
|---|---|
| {{{val4}}} | {{{chance4}}} |
}}
