summaryrefslogtreecommitdiffstats
path: root/webchat
diff options
context:
space:
mode:
Diffstat (limited to 'webchat')
-rw-r--r--webchat/hello_web.js4
-rw-r--r--webchat/public/reset.css10
2 files changed, 9 insertions, 5 deletions
diff --git a/webchat/hello_web.js b/webchat/hello_web.js
index 6f658901..45f6fc56 100644
--- a/webchat/hello_web.js
+++ b/webchat/hello_web.js
@@ -49,8 +49,8 @@ var echo = sockjs.createServer();
echo.on('connection', function(conn) {
var origin = '['+conn.remoteAddress+':'+conn.remotePort+']';
Clients.push(conn);
- irc_client.say("#krebs", name + ' has joined');
Clients.broadcast({from: 'system', message: origin + ' has joined'})
+ irc_client.say("#krebs", origin + ' has joined');
conn.write(JSON.stringify({from: 'system', message: 'hello'}))
conn.on('data', function(data) {
console.log('data:',data);
@@ -73,8 +73,8 @@ echo.on('connection', function(conn) {
});
conn.on('close', function() {
Clients.splice(Clients.indexOf(conn));
- irc_client.say("#krebs", name + ' has quit');
Clients.broadcast({from: 'system', message: origin + ' has quit'})
+ irc_client.say("#krebs", origin + ' has quit');
});
});
diff --git a/webchat/public/reset.css b/webchat/public/reset.css
index 46b52478..17e10567 100644
--- a/webchat/public/reset.css
+++ b/webchat/public/reset.css
@@ -47,16 +47,17 @@ q:before, q:after {
#chatbox {
border-collapse: collapse;
border-spacing: 0;
- border: solid 2px black;
- background-color: white;
- color: black;
+ background-color: black;
+ color: white;
}
.chat_from {
+ color:grey;
font-weight: bold;
text-align: right;
}
.chat_from:after {
content: ":";
+ padding-right: 6px;
}
#bg {
background-image: url(krebs.png);
@@ -66,3 +67,6 @@ q:before, q:after {
left: 0;
right: 0;
}
+a {
+ color: red;
+}