Skip to content

Commit

Permalink
Removed sticky position workaround for Chrome Dev
Browse files Browse the repository at this point in the history
Signed-off-by: Philipp <p.koenig@blockbyte.de>
  • Loading branch information
Philipp committed Jul 25, 2018
1 parent 71425ed commit 7424873
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 15 deletions.
2 changes: 1 addition & 1 deletion dist/js/extension.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/js/settings.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"html-minifier": "^3.5.19",
"jsonminify": "^0.4.1",
"node-sass": "^4.9.2",
"npm-check-updates": "2.14.2",
"npm-check-updates": "^2.14.2",
"read-file": "^0.2.0",
"request": "^2.87.0",
"uglify-es": "^3.3.10"
Expand Down
7 changes: 1 addition & 6 deletions src/js/helper/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -382,12 +382,7 @@
box.css("padding-top", filterBoxHeight);
});

// @deprecated sticky positioning seems to have changed with Chrome 68 -> this workaround can be removed as soon as v68 is the min required version
let versionRaw = navigator.userAgent.match(/Chrom(e|ium)\/([0-9]+)\./);
let version = versionRaw ? parseInt(versionRaw[2], 10) : null;
if (version < 68) {
ext.elm.pinnedBox.css("top", ext.helper.model.getData("u/lockPinned") ? -filterBoxHeight : 0);
}
ext.elm.pinnedBox.css("top", ext.helper.model.getData("u/lockPinned") ? -filterBoxHeight : 0);
};

/**
Expand Down
7 changes: 1 addition & 6 deletions src/js/settings/translation.js
Original file line number Diff line number Diff line change
Expand Up @@ -408,12 +408,7 @@

$("<span />").addClass($.cl.settings.translation.amountInfo).html("<span>" + varsAmount[key].filled + "</span>&thinsp;/&thinsp;" + varsAmount[key].total).appendTo(header);

// @deprecated sticky positioning seems to have changed with Chrome 68 -> this workaround can be removed as soon as v68 is the min required version
let versionRaw = navigator.userAgent.match(/Chrom(e|ium)\/([0-9]+)\./);
let version = versionRaw ? parseInt(versionRaw[2], 10) : null;
if (version < 68) {
header.css("top", "-35px");
}
header.css("top", "-35px");
}

s.elm.translation.langvars.removeClass($.cl.visible);
Expand Down

0 comments on commit 7424873

Please sign in to comment.