diff --git a/js/views/conversation_view.js b/js/views/conversation_view.js index dc3aaaff..9dbe2f0a 100644 --- a/js/views/conversation_view.js +++ b/js/views/conversation_view.js @@ -40,10 +40,7 @@ this.$el.find('.discussion-container').append(this.view.el); this.view.render(); - window.addEventListener('resize', this.view.resize.bind(this.view)); - setTimeout(function() { - this.view.resize(); this.view.scrollToBottom(); }.bind(this), 10); }, diff --git a/js/views/inbox_view.js b/js/views/inbox_view.js index 04c5c5b4..7ae22908 100644 --- a/js/views/inbox_view.js +++ b/js/views/inbox_view.js @@ -34,7 +34,6 @@ collection : bg.inbox }).render(); - window.addEventListener('resize', this.inbox.resize.bind(this.inbox)); window.addEventListener('beforeunload', function () { this.inbox.stopListening(); }.bind(this)); diff --git a/js/views/list_view.js b/js/views/list_view.js index 25606a27..f6cb4316 100644 --- a/js/views/list_view.js +++ b/js/views/list_view.js @@ -41,12 +41,6 @@ var Whisper = Whisper || {}; addAll: function() { this.$el.html(''); this.collection.each(this.addOne, this); - this.resize(); - }, - - resize: function() { - var height = window.innerHeight - $('#header').height() - $('#footer').height(); - this.$el.css('height', height + 'px'); }, render: function() { diff --git a/stylesheets/_conversation.scss b/stylesheets/_conversation.scss index e5220fae..475ce184 100644 --- a/stylesheets/_conversation.scss +++ b/stylesheets/_conversation.scss @@ -1,3 +1,10 @@ +.conversation { + padding: $header-height 0; +} + +.conversation, .discussion-container, .message-list { + height: 100%; +} .group-update { font-size: smaller; diff --git a/stylesheets/_global.scss b/stylesheets/_global.scss index fe3a0e01..016b743f 100644 --- a/stylesheets/_global.scss +++ b/stylesheets/_global.scss @@ -2,10 +2,14 @@ box-sizing: border-box; } +html { + height: 100%; +} + body { height: 100%; width: 100%; - margin: $header-height 0 0; + margin: 0; font-family: $roboto; font-size: 14px; } diff --git a/stylesheets/_index.scss b/stylesheets/_index.scss index 9a743318..d579b9c5 100644 --- a/stylesheets/_index.scss +++ b/stylesheets/_index.scss @@ -1,9 +1,12 @@ .gutter { - margin-top: 36px; + padding: $header-height 0 0; } +.gutter, #contacts { + height: 100%; +} #contacts { - overflow-y: scroll; + overflow: auto; } .loading .gutter { diff --git a/stylesheets/manifest.css b/stylesheets/manifest.css index 4038ab9a..73e81c27 100644 --- a/stylesheets/manifest.css +++ b/stylesheets/manifest.css @@ -16,10 +16,13 @@ * { box-sizing: border-box; } +html { + height: 100%; } + body { height: 100%; width: 100%; - margin: 36px 0 0; + margin: 0; font-family: Roboto, "Helvetica Neue", Arial, Helvetica, sans-serif; font-size: 14px; } @@ -105,10 +108,13 @@ body { text-align: center; } .gutter { - margin-top: 36px; } + padding: 36px 0 0; } + +.gutter, #contacts { + height: 100%; } #contacts { - overflow-y: scroll; } + overflow: auto; } .contact .number, .contact .checkbox { display: none; } @@ -259,6 +265,12 @@ input.new-message { .settings-open .settings { display: block; } +.conversation { + padding: 36px 0; } + +.conversation, .discussion-container, .message-list { + height: 100%; } + .group-update { font-size: smaller; }