From: Darren Date: Sun, 4 Sep 2011 10:05:39 +0000 (+0100) Subject: Button/Input styling X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;ds=sidebyside;h=da41bd6b6af2ae460fc4e4d487e3bc36232f55e1;p=KiwiIRC.git Button/Input styling --- diff --git a/css/default.css b/css/default.css index c700bfc..a91d936 100644 --- a/css/default.css +++ b/css/default.css @@ -24,6 +24,7 @@ body, html { } + /* The main app container */ #kiwi { overflow:hidden; position:relative; @@ -65,6 +66,19 @@ body, html { -webkit-border-radius:5px; -khtml-border-radius:5px; behavior: url(border-radius.htc); + +background-image: -webkit-gradient( + linear, + left top, + left bottom, + color-stop(0.38, rgb(238,238,238)), + color-stop(0.68, rgb(209,209,209)) +); +background-image: -moz-linear-gradient( + center top, + rgb(238,238,238) 38%, + rgb(209,209,209) 68% +); } #kiwi .windowlist .active, #kiwi .utilityviewlist .active { padding-right:23px; } #kiwi .windowlist .highlight, #kiwi .utilityviewlist .highlight { diff --git a/css/ui.css b/css/ui.css index 4382d90..1238149 100644 --- a/css/ui.css +++ b/css/ui.css @@ -23,19 +23,22 @@ #kiwi .connectwindow { - background:#1b1b1b; - color: #D4D4D4; - z-index:50; - position:absolute; + background:#1b1b1b; color: #D4D4D4; + z-index:50; position:absolute; top:0px; bottom:0px; + overflow-y:scroll; width:100%; height:100%; } #kiwi h1.logo { display:block; width:264px; height:90px; text-indent:-1000px; margin:70px auto 100px; background:url(../img/logo.png) no-repeat; } #kiwi #login { width:665px; margin:0px auto; } #kiwi #login ul { list-style:none; } -#kiwi #login ul li { overflow:hidden; margin-bottom:10px; } +#kiwi #login ul li { overflow:show; margin-bottom:10px; } #kiwi #login ul li label { float:left; text-align:right; padding-right:.5em; } -#kiwi #login input { border:none; } +#kiwi #login input { + border:none; + box-shadow: inset 0 1px 2px rgba(0,0,0,0.5),0 1px 0px rgba(255,255,255,0.3); + +} #kiwi #login .more { border-top: 1px dotted #888888; } #kiwi #login .more_link { font-size:12px; @@ -56,14 +59,14 @@ width:240px; padding:.2em .5em; font-size:.8em; text-align:center; background:#D4D4D4; - border-radius:8px; -moz-border-radius:8px; + border-radius:4px; -moz-border-radius:4px; } #kiwi #login .content.top a { display:block; text-align:right; font-size:22px; margin-top:30px; } #kiwi #login .content.bottom { width:350px; margin:30px auto; display:none; } #kiwi #login .content.bottom ul { font-size:18px; } #kiwi #login .content.bottom label { width:25%; } -#kiwi #login .content.bottom input { width:216px; font-size:.8em; no-repeat; padding:.2em .5em; background:#D4D4D4; border-radius:8px; -moz-border-radius:8px; } +#kiwi #login .content.bottom input { width:216px; font-size:.8em; no-repeat; padding:.2em .5em; background:#D4D4D4; border-radius:4px; -moz-border-radius:4px; } #kiwi #login .content.bottom a { display:block; text-align:right; font-size:16px; margin-top:30px; } diff --git a/node/app.js b/node/app.js index bb581a3..88ac244 100644 --- a/node/app.js +++ b/node/app.js @@ -484,23 +484,25 @@ this.httpHandler = function (request, response) { kiwi.fileServer.serve(request, response); }); } else if (uri.pathname === '/') { - useragent = (response.headers) ? response.headers['user-agent'] : ''; - if (useragent.indexOf('android') !== -1) { + useragent = (request.headers) ? request.headers['user-agent'] : ''; + if (useragent.match(/android/i) !== -1) { agent = 'android'; touchscreen = true; - } else if (useragent.indexOf('iphone') !== -1) { + } else if (useragent.match(/iphone/) !== -1) { agent = 'iphone'; touchscreen = true; - } else if (useragent.indexOf('ipad') !== -1) { + } else if (useragent.match(/ipad/) !== -1) { agent = 'ipad'; touchscreen = true; - } else if (useragent.indexOf('ipod') !== -1) { + } else if (useragent.match(/ipod/) !== -1) { agent = 'ipod'; touchscreen = true; } else { agent = 'normal'; touchscreen = false; } + agent = 'normal'; + touchscreen = false; if (uri.query) { server_set = ((typeof uri.query.server !== 'undefined') && (uri.query.server !== ''));