Difference between revisions of "Template:Word Bubble"

From Nookipedia, the Animal Crossing wiki
m (Fixing wikicode error)
(removing deprecated html)
 
(6 intermediate revisions by 4 users not shown)
Line 2: Line 2:
 
| valign="center" | [[File:{{{image}}}|50px]]
 
| valign="center" | [[File:{{{image}}}|50px]]
 
|
 
|
{| width="100%" border="0" cellpadding="0" cellspacing="0"
+
{| style="width:100%" border="0" cellpadding="0" cellspacing="0"
| colspan="9" width="9" height="1" |  
+
| colspan="9" style="width:9" height="1" |  
| style="background:gray;" height="1" width="1" |   
+
| style="background:gray; height:1; width:"1" |   
| style="background:gray;" height="1" |  
+
| style="background:gray; height:1" |  
| style="background:gray;" width="1" height="1"  |  
+
| style="background:gray; width:1; height:1"  |  
| colspan="4" width="4" height="1" |
+
| colspan="4" style="width:4; height:1" |
 
|-
 
|-
| colspan="8" width="8" height="1" |
+
| colspan="8" style="width:8; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color}}};" width="1" height="1" |  
+
| style="background:{{{color}}}; width:1; height:1" |  
| style="background:{{{color}}};" height="1" |  
+
| style="background:{{{color}}}; height:1" |  
| style="background:{{{color}}};" width="1" height="1" |
+
| style="background:{{{color}}}; width:1; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| colspan="3" width="3" height="1" |
+
| colspan="3" style="width:3; height:1" |
 
|-
 
|-
| colspan="7" width="7" height="1" |
+
| colspan="7" style="width:7; height:1" |
| style="background:gray;" width="1" height="1"|
+
| style="background:gray;" style="width:1; height:1"|
| style="background:{{{color}}};" colspan="2" width="2" height="1" |
+
| style="background:{{{color}}}; width:2; height:1" colspan="2" |
| style="background:{{{color}}};" height="1" |  
+
| style="background:{{{color}}}; height:1" |  
| style="background:{{{color}}};" colspan="2" width="2" height="1" |
+
| style="background:{{{color}}}; width:2; height:1" colspan="2" |
| style="background:gray;" width="1" "height="1"" |
+
| style="background:gray; width:1; "height:1" |
| colspan="2" width="2" height="1" |
+
| colspan="2" style="width:2; height:1" |
 
|-
 
|-
| colspan="6" width="6" height="1" |
+
| colspan="6" style="width:6; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color}}};" colspan="3" width="3" height="1" |
+
| style="background:{{{color}}}; width:3 height:1" colspan="3" |
| style="background:{{{color}}};" height="1" |  
+
| style="background:{{{color}}}; height:1" |  
| style="background:{{{color}}};" colspan="3" width="3" height="1" |
+
| style="background:{{{color}}}; width:3; height:1" colspan="3" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| width="1" height="1" |
+
| style="width:1; height:1" |
 
|-
 
|-
| colspan="5" width="5" |
+
| colspan="5" style="width:5" |
| style="background:gray;" width="1"  |
+
| style="background:gray; width:1"  |
| style="background:{{{color}}};" colspan="4" width="4" |
+
| style="background:{{{color}}}; width:4" colspan="4" |
 
| style="background:{{{color}}};" | '''[[User:{{{name}}}|<span style="color:{{{textcolor}}}; font-family:{{{fonttype}}};">{{{name}}}</span>]] <span style="color:{{{textcolor}}}; font-family:{{{fonttype}}};">– {{{sig}}}'''</span><br />[[User talk:{{{name}}}|<span style="color:{{{textcolor}}}; font-size:xx-small; font-family:{{{fonttype}}};">TALK</span>]]{{#if:{{{time|}}}|&nbsp;<span style="color:{{{textcolor}}}; font-size:xx-small; font-family:{{{fonttype}}};">– {{{time}}}</span>|}}
 
| style="background:{{{color}}};" | '''[[User:{{{name}}}|<span style="color:{{{textcolor}}}; font-family:{{{fonttype}}};">{{{name}}}</span>]] <span style="color:{{{textcolor}}}; font-family:{{{fonttype}}};">– {{{sig}}}'''</span><br />[[User talk:{{{name}}}|<span style="color:{{{textcolor}}}; font-size:xx-small; font-family:{{{fonttype}}};">TALK</span>]]{{#if:{{{time|}}}|&nbsp;<span style="color:{{{textcolor}}}; font-size:xx-small; font-family:{{{fonttype}}};">– {{{time}}}</span>|}}
| style="background:{{{color}}};" colspan="4" width="4" |
+
| style="background:{{{color}}}; width:4" colspan="4" |
| style="background:gray;" width="1" |
+
| style="background:gray; width:1" |
 
|-
 
|-
| colspan="4" width="4" |
+
| colspan="4" style="width:4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color}}};" colspan="5" width="5" |
+
| style="background:{{{color}}}; width:5" colspan="5" |
| style="background:{{{color}}};" height="1" |
+
| style="background:{{{color}}}; height:1" |
| style="background:{{{color}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| colspan="3" width="3" height="1" |
+
| colspan="3" style="width:3; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color}}};" colspan="6" width="6" height="1" |
+
| style="background:{{{color}}}; width:6; height:1" colspan="6" |
| style="background:{{{color}}};" height="1" |
+
| style="background:{{{color}}}; height:1" |
| style="background:{{{color}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| colspan="2" width="2" height="1" |
+
| colspan="2" style="width:2; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color}}};" colspan="7" width="7" height="1" |
+
| style="background:{{{color}}}; width:7; height:1" colspan="7" |
| style="background:{{{color}}};" height="1" |
+
| style="background:{{{color}}}; height:1" |
| style="background:{{{color}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| width="1" height="1" |
+
| style="width:1; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color}}};" colspan="8" width="8" height="1" |
+
| style="background:{{{color}}}; width:8; height:1" colspan="8" |
| style="background:{{{color}}};" height="1" |
+
| style="background:{{{color}}}; height:1" |
| style="background:{{{color}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" colspan="9" width="9" height="1" |
+
| style="background:{{{color2}}}; width:9; height:1" colspan="9" |
| style="background:{{{color2}}};" height="1" style="background:{{{line}}};" |
+
| style="background:{{{color2}}}; height:1" style="background:{{{line}}};" |
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| width="1" height="1" |
+
| style="width:1; height:1" |
| style="background:gray;" width="1" height="1"  |
+
| style="background:gray; width:1; height:1"  |
| style="background:{{{color2}}};" colspan="8" width="8" height="1" |
+
| style="background:{{{color2}}}; width:8; height:1" colspan="8" |
| style="background:{{{color2}}};" height="1" |
+
| style="background:{{{color2}}}; height:1" |
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| colspan="2" width="2" height="1" |
+
| colspan="2" style="width:2; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" colspan="7" width="7" height="1" |
+
| style="background:{{{color2}}}; width:7" height:1" colspan="7" |
| style="background:{{{color2}}};" height="1" |
+
| style="background:{{{color2}}}; height:1" |
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4" height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| colspan="3" width="3" height="1" |
+
| colspan="3" style="width:3; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" colspan="6" width="6" height="1" |
+
| style="background:{{{color2}}}; width:6; height:1" colspan="6" |
| style="background:{{{color2}}};" height="1" |
+
| style="background:{{{color2}}}; height:1" |
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1"  |
+
| style="background:gray; width:1; height:1"  |
 
|-
 
|-
| colspan="4" width="4" height="1" |
+
| colspan="4" style="width:4; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" colspan="5" width="5" |
+
| style="background:{{{color2}}}; width:5" colspan="5" |
| style="background:{{{color2}}};" height="1" |
+
| style="background:{{{color2}}}; height:1" |
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
 
|-
 
|-
| colspan="5" width="5" |
+
| colspan="5" style="width:5" |
| style="background:gray;" width="1" |
+
| style="background:gray; width:1" |
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4; height:1" colspan="4" |
| style="background:{{{color2}}};" height="1" | <span style="color:{{{textcolor2}}}; font-family:{{{fonttype}}};"> {{{text}}}</span>
+
| style="background:{{{color2}}}; height:1" | <span style="color:{{{textcolor2}}}; font-family:{{{fonttype}}};"> {{{text}}}</span>
| style="background:{{{color2}}};" colspan="4" width="4" height="1" |
+
| style="background:{{{color2}}}; width:4; height:1" colspan="4" |
| style="background:gray;" width="1" |
+
| style="background:gray; width:1" |
 
|-
 
|-
| colspan="6" width="6" height="1" |
+
| colspan="6" style="width:6; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" colspan="3" width="3" height="1" |
+
| style="background:{{{color2}}}; width:3; height:1" colspan="3" |
| style="background:{{{color2}}};" height="1" |
+
| style="background:{{{color2}}}; height:1" |
| style="background:{{{color2}}};" colspan="3" width="3" height="1" |
+
| style="background:{{{color2}}}; width:3; height:1" colspan="3" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| width="1" height="1" |
+
| style="width:1; height:1" |
 
|-
 
|-
| colspan="7" width="7" height="1" |
+
| colspan="7" style="width:7; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" colspan="2" width="2" height="1" |
+
| style="background:{{{color2}}}; width:2; height:1" colspan="2" |
 
| style="background:{{{color2}}};" height="1" |
 
| style="background:{{{color2}}};" height="1" |
| style="background:{{{color2}}};" colspan="2" width="2" height="1" |
+
| style="background:{{{color2}}}; width:2; height:1" colspan="2" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| colspan="2" width="2" height="1" |
+
| colspan="2" style="width:2; height:1" |
 
|-
 
|-
| colspan="8" width="8" height="1" |
+
| colspan="8" style="width:8; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| style="background:{{{color2}}};" width="1" height="1" |
+
| style="background:{{{color2}}}; width:1; height:1" |
| style="background:{{{color2}}};" height="1" |
+
| style="background:{{{color2}}}; height:1" |
| style="background:{{{color2}}};" width="1" height="1" |
+
| style="background:{{{color2}}}; width:1; height:1" |
| style="background:gray;" width="1" height="1" |
+
| style="background:gray; width:1; height:1" |
| colspan="3" width="3" height="1" |
+
| colspan="3" style="width:3; height:1" |
 
|-
 
|-
| colspan="9" width="9" height="1" |
+
| colspan="9" style="width:9; height:1" |
| style="background:{{{color2}}};" style="background:gray;" height="1" width="1" |
+
| style="background:{{{color2}}};" style="background:gray; height:1; width:1" |
 
| style="background:{{{color2}}};" height="1" style="background:gray;" |
 
| style="background:{{{color2}}};" height="1" style="background:gray;" |
| style="background:{{{color2}}};" width="1" height="1" style="background:gray;" |
+
| style="background:{{{color2}}};" style="width: 1" height="1" background:gray;" |
| colspan="4" width="4" height="1" |
+
| colspan="4" style="width:4; height:1" |
 
|}
 
|}
 
|}
 
|}
Line 143: Line 143:
 
This template creates a "word bubble" that you can use on talk pages and wherever else discussions take place. An example can be seen both above and below.
 
This template creates a "word bubble" that you can use on talk pages and wherever else discussions take place. An example can be seen both above and below.
 
==Usage==
 
==Usage==
To make your own version of this template you first must create a template with your username in it. For example, if your username is "User", then you make your word bubble at "Template:User". Next, on your template page ("Template:User"), add the following code.
+
To make your own version of this template you first must create a template '''in your userspace''' (usually the subpage <tt>TalkBubble</tt>). For example, if your username is "Username", then you make your word bubble at <tt>User:ExampleUser/TalkBubble</tt>. On that page, add the following code:
 
<pre>
 
<pre>
 
{{Word Bubble  
 
{{Word Bubble  
Line 159: Line 159:
 
}}
 
}}
 
</pre>
 
</pre>
You can fill in the fields to whatever you want, with the colors either being in hexadecimal notation (e.g. #FFF) or in words (e.g. white); a list of colors can be found at Wikipedia's [[wikipedia:List of colors|List of colors]] article. Note that for the image field, you have to leave out the "File:" part of the filename. Once you have filled in the fields, your word bubble is ready to be used. On talk pages, you can now include it with this code:
+
You can fill in the fields to whatever you want, with the colors either being in hexadecimal notation (e.g. #FFF) or in words (e.g. white). Note that for the image field, you have to leave out the "File:" part of the filename. Once you have filled in the fields, your word bubble is ready to be used. On talk pages, you can now include it with this code:
 
<pre>
 
<pre>
{{<name of template>|text=Blah blah blah.|time=~~~~~}}
+
{{subst:User:ExampleUser/TalkBubble|text=Blah blah blah.|time=~~~~~}}
</pre>
 
 
 
Alternatively, if you don't want to always add the "text" field whenever you use your template on talk pages, go to your template and change <code>{{{text}}}</code> to <code>{{{1}}}</code>, which does not require the "text=" field. Instead, you just need to use the following code:
 
<pre>
 
{{<name of template>|Blah blah blah.|time=~~~~~}}
 
</pre>
 
 
 
== Advanced ==
 
It is also possible to use a [[w:c:help:Help:Custom edit buttons|custom edit button]] to automatically insert your Word Bubble. To do this, add this code to [[Special:MyPage/monaco.js]].
 
<pre>
 
if (mwCustomEditButtons) {
 
  mwCustomEditButtons[mwCustomEditButtons.length] = {
 
    "imageFile": "http://images3.wikia.nocookie.net/central/images/f/fc/Button_user_talk.png",
 
    "speedTip": "Insert Word Bubble",
 
    "tagOpen": "{{<name of template>|text=",
 
    "tagClose": "<nowiki>|time=~~~~~}}",
 
    "sampleText": "Blah blah blah"};
 
}
 
</pre>
 
 
 
Note that this will only work if you are using the Monaco skin; if you are using the Monobook skin, you must add the code above to <code>User:Username/monobook.js</code>, replacing "Username" with your username. Once you have put the code at your personal js subpage, replace "<name of template>" with the name of the template you use for your Word Bubble.
 
 
 
After doing a hard refresh, when you edit, you will now see an image (http://images3.wikia.nocookie.net/central/images/f/fc/Button_user_talk.png) appear in the edit toolbar. Clicking this image will put this code in an article:
 
<pre>
 
{{<name of template>|text=Blah blah blah<nowiki>|time=~~~~~}}
 
</pre>
 
 
 
Replace <nowiki>"Blah blah blah<nowiki>"</nowiki> with the text you want to use, save the page, and you are finished. The <nowiki>"<nowiki>"</nowiki> is included in the code so that the 21:38, 27 June 2009 (UTC) is not implemented your personal javascript subpage, would would ruin the function of the "time" field. Also note that if your Word Bubble does not have the "text" field in it, you must remove the "text=" field in your personal javascript subpage so that when you click the custom edit button, the following code will be placed in an article:
 
<pre>
 
{{<name of template>|Blah blah blah<nowiki>|time=~~~~~}}
 
 
</pre>
 
</pre>
  
 
== Example ==
 
== Example ==
More examples can be found by looking through [[:Category:UserTalk templates]].
+
[[User:ExampleUser/TalkBubble]] contains the following:
 
<pre>
 
<pre>
 
{{Word Bubble
 
{{Word Bubble
 
|image      = Wiki.png
 
|image      = Wiki.png
|color      = black
+
|color      = #dc143c
|color2    = red
+
|color2    = #143
 
|textcolor  = white
 
|textcolor  = white
|textcolor2 = blue
+
|textcolor2 = lavender
 
|line      = yellow
 
|line      = yellow
|fonttype  = Times New Roman
+
|fonttype  = Coustard
 
|name      = User
 
|name      = User
|sig        = Hey how's it going?
+
|sig        = This is a signature
|time      = ~~~~~
+
|time      = {{{time}}}
|text      = Hi. My name is User.
+
|text      = {{{text}}}
 
}}
 
}}
 
</pre>
 
</pre>
  
 +
Running <tt><nowiki>{{subst:User:ExampleUser/TalkBubble|text=Hello World|time=~~~~~}}</nowiki></tt> will create the following:
 +
<!-- For those who will edit this template in the future, please replace the substituted template below with
 +
    {{subst:User:ExampleUser/TalkBubble|text=Hello World|time=~~~~~}} -->
 
{{Word Bubble
 
{{Word Bubble
 
|image      = Wiki.png
 
|image      = Wiki.png
|color      = black
+
|color      = #dc143c
|color2    = red
+
|color2    = #143
 
|textcolor  = white
 
|textcolor  = white
|textcolor2 = blue
+
|textcolor2 = lavender
 
|line      = yellow
 
|line      = yellow
|fonttype  = Times New Roman
+
|fonttype  = Coustard
 
|name      = User
 
|name      = User
|sig        = Hey how's it going?
+
|sig        = This is a signature
|time      = 20:50, April 28, 2010 (UTC)
+
|time      = 23:08, March 14, 2019 (EDT)
|text      = Hi. My name is User.
+
|text      = Hello World
 
}}
 
}}
  
[[Category:UserTalk templates]]
+
[[Category:Message templates]]
 
</noinclude>
 
</noinclude>

Latest revision as of 03:41, May 10, 2022

[[File:{{{image}}}|50px]]
[[User:{{{name}}}|{{{name}}}]] – {{{sig}}}
[[User talk:{{{name}}}|TALK]]
{{{text}}}

This template creates a "word bubble" that you can use on talk pages and wherever else discussions take place. An example can be seen both above and below.

Usage

To make your own version of this template you first must create a template in your userspace (usually the subpage TalkBubble). For example, if your username is "Username", then you make your word bubble at User:ExampleUser/TalkBubble. On that page, add the following code:

{{Word Bubble 
|image      = 
|color      = 
|color2     = 
|textcolor  = 
|textcolor2 = 
|line       = 
|fonttype   = 
|name       = 
|sig        = 
|time       = {{{time}}}
|text       = {{{text}}}
}}

You can fill in the fields to whatever you want, with the colors either being in hexadecimal notation (e.g. #FFF) or in words (e.g. white). Note that for the image field, you have to leave out the "File:" part of the filename. Once you have filled in the fields, your word bubble is ready to be used. On talk pages, you can now include it with this code:

{{subst:User:ExampleUser/TalkBubble|text=Blah blah blah.|time=~~~~~}}

Example

User:ExampleUser/TalkBubble contains the following:

{{Word Bubble
|image      = Wiki.png
|color      = #dc143c
|color2     = #143
|textcolor  = white
|textcolor2 = lavender
|line       = yellow
|fonttype   = Coustard
|name       = User
|sig        = This is a signature
|time       = {{{time}}}
|text       = {{{text}}}
}}

Running {{subst:User:ExampleUser/TalkBubble|text=Hello World|time=~~~~~}} will create the following:

Wiki.png
User – This is a signature
TALK – 23:08, March 14, 2019 (EDT)
Hello World