]> git.scottworley.com Git - reliable-chat/blobdiff - webclient/rc.html
Better visibility for the server status indicators
[reliable-chat] / webclient / rc.html
index a896281f0247abfebcf20b46f87b637dfdaa0a2a..9097323a9b013c8b20262aa6dc30883b5e7d300c 100644 (file)
        img { width: 1px; height: 1px; }
        iframe { display: none }
        #status span { margin-right: 2em }
-       #status span.sad { background-color: #fee }
-       #status span.happy { background-color: #efe }
+       #status span.sad {
+               background-color: #f00;
+               color: #fff;
+               border: 1px solid black;
+               border-radius: 5px;
+               padding-left: 5px;
+               padding-right: 5px;
+       }
+       #status span.happy {
+               background-color: #0f0;
+               color: #000;
+               border: 1px solid black;
+               border-radius: 5px;
+               padding-left: 5px;
+               padding-right: 5px;
+       }
   /*]]>*/--></style>
   <script type="text/javascript"><!--//--><![CDATA[//><!--
        var servers = ['chkno.net', 'rc2.chkno.net', 'echto.net', 'the-wes.com', 'vibrantlogic.com'];
                                message = "<" + rcnick() + "> " + input;
                        }
 
+                       // /me support
+                       var message;
+                       var re = /^\/me (.*)/;
+                       var match = re.exec(input);
+                       var inputme = input.substring(4);
+                       if (match) {
+                               message = "* " + rcnick() + "  " + inputme;
+                       } else {
+                               message = "<" + rcnick() + "> " + input;
+                       }
+
                        // Remind people to set their nick
                        if (rcnick() == 'anonymous') {
                                rcaddmessagetohistory("-!- Set your nick with /nick");
                <tr><td id="history"></td></tr>
                <tr><td id="status">&nbsp;</td></tr>
                <tr><td><form name="input" onsubmit="return false" autocomplete="off">
-                       <input id="say" onkeydown="return rckeydown(event)" autocomplete="off"></input>
+                       <input id="say" onkeydown="return rckeydown(event)" autocomplete="off" autofocus="autofocus"></input>
                        </form></td></tr>
        </table>
 </body>