Conditionally disable text-shadow on chrome v61 and v62.

This commit is contained in:
Paulo Reis 2017-09-28 14:01:03 +01:00
parent 13628f82ec
commit e41a48de72

View file

@ -185,6 +185,21 @@ define [
if ide.browserIsSafari
ide.safariScrollPatcher = new SafariScrollPatcher($scope)
# Fix Chrome 61 and 62 text-shadow rendering
browserIsChrome61or62 = false
try
chromeVersion = parseFloat(navigator.userAgent.split(" Chrome/")[1]) || null;
browserIsChrome61or62 = (
chromeVersion? &&
(chromeVersion == 61 || chromeVersion == 62)
)
console.log chromeVersion, browserIsChrome61or62
if browserIsChrome61or62
document.styleSheets[0].insertRule(".ace_editor.ace_autocomplete .ace_completion-highlight { text-shadow: none !important; }", 1)
catch err
console.error err
# User can append ?ft=somefeature to url to activate a feature toggle
ide.featureToggle = location?.search?.match(/^\?ft=(\w+)$/)?[1]