Actually, let's keep listening to 4chanMainInit, it guarantees that we don't get FOUC'd on the index/in
threads.
This commit is contained in:
parent
f072e68f6e
commit
ebfa224fe3
@ -18,6 +18,7 @@ Main =
|
||||
Conf['archives'] = Redirect.archives
|
||||
$.get Conf, Main.initFeatures
|
||||
|
||||
$.on d, '4chanMainInit', Main.initStyle
|
||||
$.asap (-> d.head and $('link[rel="shortcut icon"]', d.head) or d.readyState in ['interactive', 'complete']),
|
||||
Main.initStyle
|
||||
|
||||
@ -119,7 +120,8 @@ Main =
|
||||
$.ready Main.initReady
|
||||
|
||||
initStyle: ->
|
||||
return unless Main.isThisPageLegit()
|
||||
$.off d, '4chanMainInit', Main.initStyle
|
||||
return if !Main.isThisPageLegit() or $.hasClass doc, 'fourchan-x'
|
||||
# disable the mobile layout
|
||||
$('link[href*=mobile]', d.head)?.disabled = true
|
||||
<% if (type === 'crx') { %>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user