mirror of
https://github.com/zulip/zulip.git
synced 2025-11-15 19:31:58 +00:00
Resize main_div to exactly take up remaining vertical space
Unfortunately, it's not so easy to do this with CSS only. (imported from commit 93b58a53e20aae9ee651aa66b3163f68549a3982)
This commit is contained in:
@@ -1,3 +1,14 @@
|
||||
function resize_main_div() {
|
||||
// Resize main_div to exactly take up remaining vertical space.
|
||||
var div = $('#main_div');
|
||||
div.height(div.height() + $(window).height() - $('body').height());
|
||||
}
|
||||
$(function () {
|
||||
resize_main_div();
|
||||
$(window).resize(resize_main_div);
|
||||
$('#zephyr-type-tabs a').on('shown', function (e) { resize_main_div(); });
|
||||
});
|
||||
|
||||
$.ajaxSetup({
|
||||
beforeSend: function(xhr, settings) {
|
||||
function getCookie(name) {
|
||||
|
||||
Reference in New Issue
Block a user