ChatTags

Chattags (source) is a mark-up parser for Special:Chat.

It allows users to add formatting to their in-chat messages. Such formatting includes the ability to add colors to their messages, change the font of their messages, alter the font size, alter the font weight, and the background of their messages.

This gives users the creative freedom to better express themselves while in chat.

Users are now able to bold important sections of their messages or even highlight them using colors and backgrounds instead of using all caps. They are also able to italicize quotes and what ever else they deem necessary.

Put together this script enhances chats of all purposes.

Installation
Chattags can easily be installed by editing the following line into your wiki's MediaWiki:Chat.js page.

Or if your wiki is already using an  statement you can add the following line to your   section.

Additionally, if you would like to enable the image or YouTube tag you will need to add the following line ABOVE the script import.

Usage
To use Chattags on your wiki after installation one must only wrap their text in the designated tags that you will find below. Chattags functions much like HTML in that it requires a beginning tag that shows where you wish to start formatting and and ending tag to show when to stop formatting. If you do not include both of these tags then your text will be ignored by the script.

Tags must end in the order that they start

For example:

Tags

 * Text color
 * Background color
 * Font
 * Code tag
 * Bold text
 * Italicize text
 * Big text
 * Small text
 * Subscript
 * Superscript
 * Strike through
 * Underline
 * Image
 * Note: Leave the http:// off of the link
 * Youtube
 * Note:
 * Subscript
 * Superscript
 * Strike through
 * Underline
 * Image
 * Note: Leave the http:// off of the link
 * Youtube
 * Note:
 * Image
 * Note: Leave the http:// off of the link
 * Youtube
 * Note:
 * Note:

Developers
Chattags is very much extensible and allows developers to easily add and remove tags as they see fit.

In order to add a tag you must first import Chattags using the following line.

After doing this you must add an entry to the tags object in order to do this you must pick a name that has not been previously chosen. All default tags are listed above. After selecting the name for your tag you must then decide whether it is stand-alone or a pair.

A stand alone tag only require and opening tag (see: img, yt).

A pair tag requires both an opening and closing tag (see: c, u, bg)

After deciding the structure of your tag you must decide if you want it to accept a parameter or not. After deciding this you want to create your object entry. For example purposes we will be creating a user tag that turns their text color purple.

To add an entry we must do the following below our import.

Now, let's say that we want to let the user enter their own color, we'd need to do something like the following.

When dealing with user input you must always use  to escape the input to prevent script injection.