 smileys = []
 
 for smiley in smileys_definition
-    smileys.push([RegExp(escapeRegExp(smiley[0]), 'g'), smiley[1]])
+    s = escapeRegExp(smiley[0])
+    if smiley[2]?
+        s = smiley[2] + s
+    if smiley[3]?
+        s = s + smiley[3]
+    smileys.push([RegExp(s, 'g'), smiley[1]])
 
 exports.smiley = (opts) ->
     opts = exports.defaults opts,

_ = underscore

exports.smiley_strings = () ->
    return _.map(smileys_definition, _.first)

# converts an array to a "human readable" array
exports.to_human_list = (arr) ->

smileys_definition = [
    [':-)',          "😁"],
    [':-(',          "😞"],
    ['<3',           "♡",             null, '\\b'],
    [':shrug:',      "¯\\\\_(ツ)_/¯"],
    ['o_o',          "סּ_\סּ",         '\\b', '\\b'],
    [':-p',          "😛",            null, '\\b'],
    ['>_<',          "😆"],
    ['^^',           "😄",            '^',   '\S'],
    ['^^ ',          "😄 "],
    [' ^^',          " 😄"],
    [';-)',          "😉"],
    ['-_-',          "😔"],
    [':-\\',         "😏"],
