From c0f1ea9604da5730fbace3207138b6c09d46707e Mon Sep 17 00:00:00 2001 From: Ephemera Date: Sun, 8 Jun 2014 22:38:16 +0900 Subject: [PATCH] Fix Firefox's issue related to #106 --- src/adapter.github.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/adapter.github.js b/src/adapter.github.js index 16cba0b..cb4d490 100644 --- a/src/adapter.github.js +++ b/src/adapter.github.js @@ -43,7 +43,7 @@ GitHub.prototype.updateLayout = function(sidebarVisible, sidebarWidth) { var containers = $(GH_CONTAINERS) , marginLeft if (containers.length === 3) { - marginLeft = parseInt($('.container').last().css('margin-left')) + marginLeft = parseInt($('body > .container').css('margin-left')) || ($('body').width() - $('body > .container').width()) / 2 containers.css('margin-left', (sidebarVisible && marginLeft <= sidebarWidth + SIDEBAR_SPACE) ? sidebarWidth + SIDEBAR_SPACE : marginLeft)