From e0ca096dbec144904ab17910d5a4f1a1974f9c89 Mon Sep 17 00:00:00 2001 From: Jordan Bates Date: Fri, 3 May 2013 18:22:05 -0700 Subject: [PATCH] Add catalog, index, and thread classes --- CHANGELOG.md | 1 + builds/4chan-X.js | 1 + builds/4chan-X.user.js | 1 + builds/crx/script.js | 1 + src/General/Main.coffee | 1 + 5 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8f04caff7..9518b5765 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,6 @@ seaweedchan: - Add `Highlight Posts Quoting You` option +- Add 'catalog', 'index', or 'thread' classes to document depending on what's open ### 1.1.10 - 2013-05-03 seaweedchan: diff --git a/builds/4chan-X.js b/builds/4chan-X.js index 98ac5734b..4321c3065 100644 --- a/builds/4chan-X.js +++ b/builds/4chan-X.js @@ -9840,6 +9840,7 @@ } $.addClass(doc, 'presto'); $.addClass(doc, 'fourchan-x'); + $.addClass(doc, g.VIEW); $.addStyle(Main.css); if (g.VIEW === 'catalog') { $.addClass(doc, $.id('base-css').href.match(/catalog_(\w+)/)[1].replace('_new', '').replace(/_+/g, '-')); diff --git a/builds/4chan-X.user.js b/builds/4chan-X.user.js index cfe21379b..2dbf4ca21 100644 --- a/builds/4chan-X.user.js +++ b/builds/4chan-X.user.js @@ -9863,6 +9863,7 @@ } $.addClass(doc, 'gecko'); $.addClass(doc, 'fourchan-x'); + $.addClass(doc, g.VIEW); $.addStyle(Main.css); if (g.VIEW === 'catalog') { $.addClass(doc, $.id('base-css').href.match(/catalog_(\w+)/)[1].replace('_new', '').replace(/_+/g, '-')); diff --git a/builds/crx/script.js b/builds/crx/script.js index 75242dd48..681171890 100644 --- a/builds/crx/script.js +++ b/builds/crx/script.js @@ -9844,6 +9844,7 @@ } $.addClass(doc, 'webkit'); $.addClass(doc, 'fourchan-x'); + $.addClass(doc, g.VIEW); $.addStyle(Main.css); if (g.VIEW === 'catalog') { $.addClass(doc, $.id('base-css').href.match(/catalog_(\w+)/)[1].replace('_new', '').replace(/_+/g, '-')); diff --git a/src/General/Main.coffee b/src/General/Main.coffee index 49b505598..6d364be0b 100644 --- a/src/General/Main.coffee +++ b/src/General/Main.coffee @@ -132,6 +132,7 @@ Main = $('link[href*=mobile]', d.head)?.disabled = true $.addClass doc, '<% if (type === 'crx') { %>webkit<% } else if (type === 'userjs') { %>presto<% } else { %>gecko<% } %>' $.addClass doc, 'fourchan-x' + $.addClass doc, g.VIEW $.addStyle Main.css if g.VIEW is 'catalog'