Merge pull request #65 from torhve/master

CSS + layout
This commit is contained in:
Vivien Didelot 2013-10-25 13:39:41 -07:00
commit 934c5ce742
3 changed files with 15 additions and 20 deletions

View file

@ -92,23 +92,17 @@ body {
} }
input#sendMessage { input#sendMessage {
border: 0;
width: 100%; width: 100%;
font-size: large;
}
#footer button {
border-radius: 0;
} }
.panel input, .panel .input-group { .panel input, .panel .input-group {
max-width: 300px; max-width: 300px;
} }
input[type=text], input[type=password], .badge { input[type=text], input[type=password], .badge {
border: 0; border: 0;
-webkit-box-shadow:
inset 0 0 8px rgba(0,0,0,0.4),
0 0 16px rgba(0,0,0,0.4);
-moz-box-shadow:
inset 0 0 8px rgba(0,0,0,0.4),
0 0 16px rgba(0,0,0,0.4);
box-shadow:
inset 0 0 8px rgba(0,0,0,0.4),
0 0 16px rgba(0,0,0,0.4);
border-radius: 0; border-radius: 0;
color: #6e6e6e; color: #6e6e6e;
box-shadow: 0px 1px 0px rgba(255, 255, 255, 0.1), 0px 1px 7px 0px rgba(0, 0, 0, 0.8) inset; box-shadow: 0px 1px 0px rgba(255, 255, 255, 0.1), 0px 1px 7px 0px rgba(0, 0, 0, 0.8) inset;
@ -180,16 +174,16 @@ input[type=text], input[type=password], .badge {
min-height: 100%; min-height: 100%;
} }
.bufferlines { #bufferlines {
font-family: 'Terminus', 'Inconsolata', 'Consolas', 'Monaco', 'Ubuntu Mono', monospace; font-family: 'Terminus', 'Inconsolata', 'Consolas', 'Monaco', 'Ubuntu Mono', monospace;
position: relative;
height: 99%;
overflow-y: auto; overflow-y: auto;
margin-left: 14%; margin-left: 14%;
width: auto; width: auto;
position: relative; top: 25px; /* topbar */
padding-bottom: 60px; /* bottom input */
padding-top: 35px; /* topbar */
} }
.bufferlines .btn { #bufferlines .btn {
font-family: sans-serif; font-family: sans-serif;
} }
@ -197,7 +191,7 @@ input[type=text], input[type=password], .badge {
margin: 0 5px 0 14%; margin: 0 5px 0 14%;
} }
@media (max-width: 968px) { @media (max-width: 968px) {
#sidebar, .bufferlines { #sidebar, #bufferlines {
position: relative; position: relative;
min-height: 0; min-height: 0;
margin-left: 0; margin-left: 0;

View file

@ -211,7 +211,7 @@
</li> </li>
</ul> </ul>
</div> </div>
<div class="bufferlines"> <div id="bufferlines">
<table> <table>
<tbody> <tbody>
<tr class="bufferline" ng-repeat-start="bufferline in activeBuffer().lines"> <tr class="bufferline" ng-repeat-start="bufferline in activeBuffer().lines">

View file

@ -427,10 +427,11 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
if(readmarker) { if(readmarker) {
readmarker.scrollIntoView(); readmarker.scrollIntoView();
}else{ }else{
var sTop = document.documentElement.scrollTop; var bl = document.getElementById('bufferlines');
var sVal = document.documentElement.scrollHeight - document.documentElement.clientHeight; var sTop = bl.scrollTop;
var sVal = bl.scrollHeight - bl.clientHeight;
if(sTop < sVal) { if(sTop < sVal) {
document.documentElement.scrollTop = sVal; bl.scrollTop = sVal;
} }
} }
} }