Template:MP box: Difference between revisions
From Portals of Phereon Wiki
Content added Content deleted
(Created page with "<div class="fp-box" {{#if:{{{id|}}}|id="{{{id}}}"}}> {{#if:{{{heading|test}}}|<div class="fp-heading"><h2>{{{heading|test}}}</h2></div>}} <div class="fp-content"><span>{{{cont...") |
(Clearfix stuff) |
||
(15 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<div class=" |
<includeonly><div class="mp-box" {{#if:{{{id|}}}|id="{{{id}}}"}} {{#if:{{{style|}}}|style="{{{style}}}"}}> |
||
{{#if:{{{heading| |
{{#if:{{{heading|}}}|<div class="mp-heading">{{{heading}}}</div>}} |
||
<div class=" |
<div class="mp-content clearfix cf-fix">{{{content|}}}</div> |
||
{{#if:{{{footer| |
<!--{{#if:{{{footer|}}}|<div class="mp-footer">{{{footer}}}</div>}}--> |
||
</div> |
</div></includeonly><!-- |
||
--><noinclude> |
|||
<!-- |
|||
{{doc}} |
|||
.fp-box { |
|||
</noinclude> |
|||
display: flex; |
|||
flex-flow: row wrap; |
|||
border: 1px solid #e4eaee; |
|||
background: #ffffff; |
|||
box-shadow: 0 0.25rem 0.35rem -0.25rem rgba(0, 0, 0, 0.1); |
|||
} |
|||
.fp-box > * { |
|||
width: 100%; |
|||
padding: 0.5em 2em; |
|||
} |
|||
.fp-box > *:first-child { |
|||
padding-top: 1.5rem; |
|||
} |
|||
.fp-box > *:last-child { |
|||
padding-bottom: 1rem; |
|||
} |
|||
.fp-box h2 { |
|||
font-size: 1.4em; |
|||
font-weight: bold; |
|||
border: none; |
|||
margin: 0 0 0.4em; |
|||
} |
|||
.fp-footer.fp-footer { |
|||
background: #f9fafa; |
|||
transition: 0.3s ease-out; |
|||
align-self: flex-end; |
|||
padding: 0; |
|||
} |
|||
.fp-footer:hover { |
|||
background: #f2f4f4; |
|||
}--> |
Latest revision as of 01:42, 12 September 2020
Usage[]
Using this:
{{MP box |id = mybox1 |heading = Title |content = Content stuff here }}
Gets you this:
Title
Content stuff here
Template data[]
A box designed for the main page
Parameter | Description | Type | Status | |
---|---|---|---|---|
id | id | A unique ID for this box, to be referenced in CSS or JS
| String | optional |
Heading | heading | What shows up in the heading section
| String | suggested |
Content | content | Content goes here | Content | suggested |
Style | style | Set wrapper css style | Unknown | optional |
[view | edit | purge]The above documentation is transcluded fromTemplate:MP box/doc.