From 261065058fe67f7dbf393fa63c8dc77572601f09 Mon Sep 17 00:00:00 2001 From: ccd0 Date: Sun, 5 Jun 2016 02:47:50 -0700 Subject: [PATCH] Prefix user-agent-specific workaround classes with 'ua-'. #937 --- src/css/style.css | 8 ++++---- src/main/Main.coffee | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/css/style.css b/src/css/style.css index bb468fd86..360f07a22 100644 --- a/src/css/style.css +++ b/src/css/style.css @@ -1077,7 +1077,7 @@ span.hide-announcement { :root.fit-width .full-image { max-width: 100%; } -:root.gecko.fit-width .full-image { +:root.ua-gecko.fit-width .full-image { width: 100%; } .fileThumb > .warning { @@ -1403,10 +1403,10 @@ input.field.tripped:not(:hover):not(:focus) { width: 304px; } /* scrollable with scroll bar hidden; prevents scroll on space press */ -:root.blink #qr .captcha-container > div { +:root.ua-blink #qr .captcha-container > div { overflow: hidden; } -:root.blink #qr .captcha-container > div > div:first-of-type { +:root.ua-blink #qr .captcha-container > div > div:first-of-type { overflow-y: scroll; overflow-x: hidden; padding-right: 15px; @@ -1727,7 +1727,7 @@ a:only-of-type > .remove { display: -webkit-flex; display: flex; } -:root.webkit .textarea { +:root.ua-webkit .textarea { margin-bottom: -2px; } #char-count { diff --git a/src/main/Main.coffee b/src/main/Main.coffee index 8eef3ff38..adec62d66 100644 --- a/src/main/Main.coffee +++ b/src/main/Main.coffee @@ -194,7 +194,7 @@ Main = $('link[href*=mobile]', d.head)?.disabled = true $.addClass doc, 'fourchan-x', 'seaweedchan' $.addClass doc, if g.VIEW is 'thread' then 'thread-view' else g.VIEW - $.addClass doc, $.engine if $.engine + $.addClass doc, "ua-#{$.engine}", $.engine if $.engine $.onExists doc, '.ad-cnt', (ad) -> $.onExists ad, 'img', -> $.addClass doc, 'ads-loaded' $.addClass doc, 'autohiding-scrollbar' if Conf['Autohiding Scrollbar'] $.ready ->