Difference between revisions of "Template:Notice"

From A3! Wiki
(Created page with "<noinclude> Category:Template Creates a notice containing information or a spoiler warning. ==How to Use== <pre>{{Notice|Whatever is here will be the text of the page unl...")
 
(remove extra space around notice)
 
(9 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
<noinclude>
 
<noinclude>
 
[[Category:Template]]
 
[[Category:Template]]
Creates a notice containing information or a spoiler warning.
+
{{Template:Notice/Docs}}
 
+
</noinclude><includeonly> {{#css:
==How to Use==
+
.notice {
<pre>{{Notice|Whatever is here will be the text of the page unless the contents is the word spoiler, in which case it will create a yellow spoiler warning.}}</pre>
 
 
 
{{Notice|Whatever is here will be the text of the page unless the contents is the word spoiler, in which case it will create a yellow spoiler warning.}}
 
 
 
<pre>{{Notice|spoiler}}</pre>
 
 
 
{{Notice|spoiler}}
 
</noinclude>
 
 
 
<includeonly>
 
{{#css:
 
.noticeInner {
 
 
     padding: .75rem 1.25rem;
 
     padding: .75rem 1.25rem;
     margin-bottom: 1rem;
+
     margin: 1em auto;
 
     border: 1px solid transparent;
 
     border: 1px solid transparent;
 
     border-radius: .25rem;
 
     border-radius: .25rem;
 +
    display: inline-block;
 +
    text-align: center;
 
}
 
}
  
Line 34: Line 24:
 
}
 
}
  
.noticeOuter {
+
.noticeWarning {
     text-align: center;
+
     color: #721c24;
}
+
    background-color: #f8d7da;
}}
+
    border-color: #f5c6cb;
 
+
} }} <div style="text-align: center"><div class="notice {{#if: {{{1|}}}|{{#switch: {{{1}}}|Spoiler|spoiler=noticeSpoiler|Warning|warning=noticeWarning|#default=noticeInfo}}|}}">{{#switch: {{{1}}}|Spoiler|spoiler=<b>Warning!</b> The following text may contain spoilers for aspects of the story. Proceed with caution.|Warning|warning={{{2}}}|#default={{{1}}} }}</div></div> </includeonly>
<div class="noticeOuter"><span class="noticeInner {{#if: {{{1|}}}|{{#switch: {{{1}}}|Spoiler|spoiler=noticeSpoiler|#default=noticeInfo}}|}}">{{#switch: {{{1}}}|Spoiler|spoiler=<b>Warning!</b> The following text may contain spoilers for aspects of the story. Proceed with caution.|#default={{{1}}} }}
 
</span></div>
 
</includeonly>
 

Latest revision as of 08:48, 28 February 2020


Creates 1 of 3 types of Notice boxes: general (blue), spoiler (yellow), and warning (red). Note that at the moment, all 3 Notice types will appear as the same yellow to users with the A3! Wiki Dark Mode Theme™️ enabled.

How to Use[edit]

Click the respective header links to see live examples of each Notice box.

General[edit]

{{Notice|Whatever is here will be the notice text. There is no need to state a 'type', unlike for the other 2 Notice boxes.}}

would generate this:

Whatever is here will be the notice text. There is no need to state a 'type', unlike for the other 2 Notice boxes.

Spoiler[edit]

{{Notice|spoiler}}

would automatically generate this standard spoiler tag:

Warning! The following text may contain spoilers for aspects of the story. Proceed with caution.

Warning[edit]

{{Notice|warning|<b>Trigger warning</b>: A section of the performance in this episode depicts [insert topics here]. Reader discretion is advised.}}

would generate this:

Trigger warning: A section of the performance in this episode depicts [insert topics here]. Reader discretion is advised.

Note that the use of this box is not restricted to trigger warnings only, and may be used for any other important warnings for story readers or wiki visitors.