Merge pull request #567 from robbieaverill/bugfix/viewport-resizing-width

FIX Ensure field GridField has a 100% relative width rather than fixed
This commit is contained in:
Franco Springveldt 2017-06-16 10:51:29 +12:00 committed by GitHub
commit 431148beb8

View File

@ -47,8 +47,8 @@
// Make sure gridfield buttons stick to top of page when user scrolls down
stickyHeaderInterval = setInterval(function () {
var offsetTop = fieldEditor.offset().top;
$buttonrow.width(self.width());
if (offsetTop > navHeight || offsetTop === 0) {
$buttonrow.width('100%');
if (offsetTop > navHeight || offsetTop === 0) {
$buttonrow.removeClass('stickyButtons');
} else {
$buttonrow.addClass('stickyButtons');