From 4c53aa51178dc1aadc3f921ad51a62da44d7f103 Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Thu, 5 Jun 2014 22:42:53 +0200 Subject: [PATCH] Fix chat buttons height on Firefox Also adapt those buttons height to the size of the textarea --- public/js/vroom.js | 7 +++++++ templates/default/join.html.ep | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/public/js/vroom.js b/public/js/vroom.js index eadfee6..23c8cbd 100644 --- a/public/js/vroom.js +++ b/public/js/vroom.js @@ -1827,6 +1827,10 @@ function initVroom(room) { } }); + // Fix height in Firefox + if ($.browser.mozilla){ + $('#saveChat,#sendChat').css('height', '47px'); + } // Adapt the chat input (textarea) size $('#chatBox').on('input', function(){ var h = parseInt($(this).css('height')); @@ -1851,6 +1855,8 @@ function initVroom(room) { } } } + // In any case, adapt height of the buttons + $('#saveChat,#sendChat').css('height', $(this).css('height')); }); // Chat: send to other peers $('#chatForm').submit(function (e){ @@ -1861,6 +1867,7 @@ function initVroom(room) { newChatMessage('local',$('#chatBox').val()); // reset the input box $('#chatBox').val('').prop('rows', 1); + $('#saveChat,#sendChat').css('height', $('#chatBox').css('height')); } }); diff --git a/templates/default/join.html.ep b/templates/default/join.html.ep index fff31d6..2ae9134 100644 --- a/templates/default/join.html.ep +++ b/templates/default/join.html.ep @@ -711,7 +711,7 @@
-