Template:META Message: Difference between revisions
Appearance
imported>Samueldr m Fix issue with floats |
m Add support for dark mode. |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
<noinclude> | <noinclude>{{Template}} | ||
== About == | |||
A templated message. | A templated message. | ||
Use of <code><table></code> is to allow vertical centering. | Use of <code><table></code> is to allow vertical centering. | ||
== | == Usage == | ||
<pre><nowiki> | <pre><nowiki> | ||
{{Template:META Message}} | {{Template:META Message}} | ||
</nowiki></pre> | </nowiki></pre> | ||
<pre><nowiki> | <pre><nowiki> | ||
Line 16: | Line 17: | ||
</nowiki></pre> | </nowiki></pre> | ||
{{Template: | {{Template:Warning|Please note that using a custom border and background may cause the text of the message to become unreadable!}} | ||
<pre><nowiki> | <pre><nowiki> | ||
{{Template:META Message | {{Template:META Message | ||
Line 24: | Line 24: | ||
}} | }} | ||
</nowiki></pre> | </nowiki></pre> | ||
== Example == | |||
{{Template:META Message}} | |||
{{Template:META Message|heading=heading}} | |||
{{Template:META Message | {{Template:META Message | ||
Line 32: | Line 38: | ||
</noinclude><includeonly><div class="nixos-template-message"><table class="message-box" role="presentation" | </noinclude><includeonly><div class="nixos-template-message"><table class="message-box" role="presentation" | ||
style=" | style=" | ||
border: 1px solid {{{border| | border: 1px solid {{{border|var(--color-progressive)}}}; | ||
border-left-width: 5px; | border-left-width: 5px; | ||
background: {{{background| | background: {{{background|var(--background-color-neutral)}}}; | ||
margin-bottom: 1ex; | margin-bottom: 1ex; | ||
" | " | ||
> | > | ||
<tr> | <tr> | ||
<td style="padding-left: 0.5em; padding-right: 0.5em;">{{{signal}}}</td> | <td style="padding-left: 0.5em; padding-right: 0.5em; min-width: 64px;">{{{signal}}}</td> | ||
<td style="padding-right: 1em; width:100%;"> | <td style="padding-right: 1em; width:100%;"> | ||
{{#if: {{{heading|}}}|<div>'''{{{heading}}}'''</div>|}} | {{#if: {{{heading|}}}|<div>'''{{{heading}}}'''</div>|}} |
Latest revision as of 16:44, 12 April 2025
This page is a template. It should be used as part of other articles. For more information, see Help:Template.
Please do not experiment with this template; you could ruin all pages using this template. If you want to edit this template, copy the text to Template:Sandbox, edit and test it there, and copy it back when it works.
Feel free to discuss this template in the talk page.
If you wanted to create a new page instead, use the search box to search for the title of the new page you want to create and follow the linkCreate the page "XYZ" on this wiki!
in the results page. An alternative is to create a dangling link to the new page from an existing page. A final option is to directly visit the expected URL of the page.About
A templated message.
Use of <table>
is to allow vertical centering.
Usage
{{Template:META Message}}
{{Template:META Message|heading=heading}}
{{Template:META Message |border = #ff0000 |background = #00ff00 }}
Example