diff --git a/builds/4chan-X.js b/builds/4chan-X.js index 87cd5781c..79b439161 100644 --- a/builds/4chan-X.js +++ b/builds/4chan-X.js @@ -209,6 +209,7 @@ 'Quote Highlighting': [true, 'Highlight the previewed post.'], 'Resurrect Quotes': [true, 'Link dead quotes to the archives.'], 'Mark Quotes of You': [true, 'Add \'(You)\' to quotes linking to your posts.'], + 'Quoted Title': ['Change the page title to reflect you\'ve been quoted.', false], 'Highlight Posts Quoting You': [false, 'Highlights any posts that contain a quote to your post.'], 'Highlight Own Posts': [false, 'Highlights own posts if Mark Quotes of You is enabled.'], 'Mark OP Quotes': [true, 'Add \'(OP)\' to OP quotes.'], @@ -7748,7 +7749,7 @@ count = Unread.posts.length; if (Conf['Unread Count']) { - d.title = "" + (count || !Conf['Hide Unread Count at (0)'] ? "(" + count + ") " : '') + (g.DEAD ? "/" + g.BOARD + "/ - 404" : "" + Unread.title); + d.title = "" + (Conf['Quoted Title'] && Unread.postsQuotingYou.length ? '(!) ' : '') + (count || !Conf['Hide Unread Count at (0)'] ? "(" + count + ") " : '') + (g.DEAD ? "/" + g.BOARD + "/ - 404" : "" + Unread.title); } if (!Conf['Unread Favicon']) { return; @@ -9764,7 +9765,7 @@ return $.on(ta, 'change', $.cb.value); }, advanced: function(section) { - var archive, boardID, boardOptions, boardSelect, boards, data, event, input, inputs, items, name, row, rows, ta, table, _i, _j, _k, _len, _len1, _len2, _ref, _ref1, _ref2, _ref3; + var archive, boardID, boardOptions, boardSelect, boards, data, event, input, inputs, item, items, name, row, rows, ta, table, _i, _j, _k, _l, _len, _len1, _len2, _len3, _ref, _ref1, _ref2, _ref3, _ref4; section.innerHTML = "
Archiver
404 Redirect is disabled.
Thread redirectionPost fetchingFile redirection
Disabled selections indicate that only one archive is available for that board and redirection type.
Custom Board Navigation
New lines will be converted into spaces.

In the following, board can translate to a board ID (a, b, etc...), the current board (current), or the Status/Twitter link (status, @).
\n For example:
[ toggle-all ] [current-title] [g-title / a-title / jp-title] [x / wsg / h] [t-text:\"Piracy\"]
\n will give you
[ + ] [Technology] [Technology / Anime & Manga / Otaku Culture] [x / wsg / h] [Piracy]
\n if you are on /g/.\n
Board link: board
Title link: board-title
Board link (Replace with title when on that board): board-replace
Full text link: board-full
Custom text link: board-text:\"VIP Board\"
Index-only link: board-index
Catalog-only link: board-catalog
External link: external-text:\"Google\",\"http://www.google.com\"
Combinations are possible: board-index-text:\"VIP Index\"
Full board list toggle: toggle-all
Time Formatting is disabled.
:
Supported format specifiers:
Day: %a, %A, %d, %e
Month: %m, %b, %B
Year: %y, %Y
Hour: %k, %H, %l, %I, %p, %P
Minute: %M
Second: %S
Quote Backlinks formatting is disabled.
:
File Info Formatting is disabled.
:
Link: %l (truncated), %L (untruncated), %T (Unix timestamp)
Original file name: %n (truncated), %N (untruncated), %t (Unix timestamp)
Spoiler indicator: %p
Size: %B (Bytes), %K (KB), %M (MB), %s (4chan default)
Resolution: %r (Displays 'PDF' for PDF files)
Quick Reply Personas is disabled.

\n One item per line.
\n Items will be added in the relevant input's auto-completion list.
\n Password items will always be used, since there is no password input.
\n Lines starting with a # will be ignored.\n

Unread Favicon is disabled.
Emoji is disabled.
\n Sage Icon:
\n Position:
Thread Updater is disabled.
\n Interval:
"; items = {}; @@ -9833,14 +9834,18 @@ className: "board-" + boardID }); row.hidden = boardID !== g.BOARD.ID; - rows.push(row); boardOptions.push($.el('option', { textContent: "/" + boardID + "/", value: "board-" + boardID, selected: boardID === g.BOARD.ID })); data = boards[boardID]; - $.add(row, [Settings.addArchiveCell(boardID, data, 'thread'), Settings.addArchiveCell(boardID, data, 'post'), Settings.addArchiveCell(boardID, data, 'file')]); + _ref4 = ['thread', 'post', 'file']; + for (_l = 0, _len3 = _ref4.length; _l < _len3; _l++) { + item = _ref4[_l]; + $.add(row, Settings.addArchiveCell(boardID, data, item)); + } + rows.push(row); } $.add($('tbody', section), rows); boardSelect = $('#archive-board-select', section); diff --git a/builds/4chan-X.user.js b/builds/4chan-X.user.js index 056299b26..e3fadd634 100644 --- a/builds/4chan-X.user.js +++ b/builds/4chan-X.user.js @@ -210,6 +210,7 @@ 'Quote Highlighting': [true, 'Highlight the previewed post.'], 'Resurrect Quotes': [true, 'Link dead quotes to the archives.'], 'Mark Quotes of You': [true, 'Add \'(You)\' to quotes linking to your posts.'], + 'Quoted Title': ['Change the page title to reflect you\'ve been quoted.', false], 'Highlight Posts Quoting You': [false, 'Highlights any posts that contain a quote to your post.'], 'Highlight Own Posts': [false, 'Highlights own posts if Mark Quotes of You is enabled.'], 'Mark OP Quotes': [true, 'Add \'(OP)\' to OP quotes.'], @@ -7757,7 +7758,7 @@ count = Unread.posts.length; if (Conf['Unread Count']) { - d.title = "" + (count || !Conf['Hide Unread Count at (0)'] ? "(" + count + ") " : '') + (g.DEAD ? "/" + g.BOARD + "/ - 404" : "" + Unread.title); + d.title = "" + (Conf['Quoted Title'] && Unread.postsQuotingYou.length ? '(!) ' : '') + (count || !Conf['Hide Unread Count at (0)'] ? "(" + count + ") " : '') + (g.DEAD ? "/" + g.BOARD + "/ - 404" : "" + Unread.title); } if (!Conf['Unread Favicon']) { return; @@ -9775,7 +9776,7 @@ return $.on(ta, 'change', $.cb.value); }, advanced: function(section) { - var archive, boardID, boardOptions, boardSelect, boards, data, event, input, inputs, items, name, row, rows, ta, table, _i, _j, _k, _len, _len1, _len2, _ref, _ref1, _ref2, _ref3; + var archive, boardID, boardOptions, boardSelect, boards, data, event, input, inputs, item, items, name, row, rows, ta, table, _i, _j, _k, _l, _len, _len1, _len2, _len3, _ref, _ref1, _ref2, _ref3, _ref4; section.innerHTML = "
Archiver
404 Redirect is disabled.
Thread redirectionPost fetchingFile redirection
Disabled selections indicate that only one archive is available for that board and redirection type.
Custom Board Navigation
New lines will be converted into spaces.

In the following, board can translate to a board ID (a, b, etc...), the current board (current), or the Status/Twitter link (status, @).
\n For example:
[ toggle-all ] [current-title] [g-title / a-title / jp-title] [x / wsg / h] [t-text:\"Piracy\"]
\n will give you
[ + ] [Technology] [Technology / Anime & Manga / Otaku Culture] [x / wsg / h] [Piracy]
\n if you are on /g/.\n
Board link: board
Title link: board-title
Board link (Replace with title when on that board): board-replace
Full text link: board-full
Custom text link: board-text:\"VIP Board\"
Index-only link: board-index
Catalog-only link: board-catalog
External link: external-text:\"Google\",\"http://www.google.com\"
Combinations are possible: board-index-text:\"VIP Index\"
Full board list toggle: toggle-all
Time Formatting is disabled.
:
Supported format specifiers:
Day: %a, %A, %d, %e
Month: %m, %b, %B
Year: %y, %Y
Hour: %k, %H, %l, %I, %p, %P
Minute: %M
Second: %S
Quote Backlinks formatting is disabled.
:
File Info Formatting is disabled.
:
Link: %l (truncated), %L (untruncated), %T (Unix timestamp)
Original file name: %n (truncated), %N (untruncated), %t (Unix timestamp)
Spoiler indicator: %p
Size: %B (Bytes), %K (KB), %M (MB), %s (4chan default)
Resolution: %r (Displays 'PDF' for PDF files)
Quick Reply Personas is disabled.

\n One item per line.
\n Items will be added in the relevant input's auto-completion list.
\n Password items will always be used, since there is no password input.
\n Lines starting with a # will be ignored.\n

Unread Favicon is disabled.
Emoji is disabled.
\n Sage Icon:
\n Position:
Thread Updater is disabled.
\n Interval:
"; items = {}; @@ -9844,14 +9845,18 @@ className: "board-" + boardID }); row.hidden = boardID !== g.BOARD.ID; - rows.push(row); boardOptions.push($.el('option', { textContent: "/" + boardID + "/", value: "board-" + boardID, selected: boardID === g.BOARD.ID })); data = boards[boardID]; - $.add(row, [Settings.addArchiveCell(boardID, data, 'thread'), Settings.addArchiveCell(boardID, data, 'post'), Settings.addArchiveCell(boardID, data, 'file')]); + _ref4 = ['thread', 'post', 'file']; + for (_l = 0, _len3 = _ref4.length; _l < _len3; _l++) { + item = _ref4[_l]; + $.add(row, Settings.addArchiveCell(boardID, data, item)); + } + rows.push(row); } $.add($('tbody', section), rows); boardSelect = $('#archive-board-select', section); diff --git a/builds/crx/script.js b/builds/crx/script.js index b98ba229a..58128291b 100644 --- a/builds/crx/script.js +++ b/builds/crx/script.js @@ -191,6 +191,7 @@ 'Quote Highlighting': [true, 'Highlight the previewed post.'], 'Resurrect Quotes': [true, 'Link dead quotes to the archives.'], 'Mark Quotes of You': [true, 'Add \'(You)\' to quotes linking to your posts.'], + 'Quoted Title': ['Change the page title to reflect you\'ve been quoted.', false], 'Highlight Posts Quoting You': [false, 'Highlights any posts that contain a quote to your post.'], 'Highlight Own Posts': [false, 'Highlights own posts if Mark Quotes of You is enabled.'], 'Mark OP Quotes': [true, 'Add \'(OP)\' to OP quotes.'], @@ -7735,7 +7736,7 @@ count = Unread.posts.length; if (Conf['Unread Count']) { - d.title = "" + (count || !Conf['Hide Unread Count at (0)'] ? "(" + count + ") " : '') + (g.DEAD ? "/" + g.BOARD + "/ - 404" : "" + Unread.title); + d.title = "" + (Conf['Quoted Title'] && Unread.postsQuotingYou.length ? '(!) ' : '') + (count || !Conf['Hide Unread Count at (0)'] ? "(" + count + ") " : '') + (g.DEAD ? "/" + g.BOARD + "/ - 404" : "" + Unread.title); if (!dontrepeat) { setTimeout(function() { d.title = ''; @@ -9756,7 +9757,7 @@ return $.on(ta, 'change', $.cb.value); }, advanced: function(section) { - var archive, boardID, boardOptions, boardSelect, boards, data, event, input, inputs, items, name, row, rows, ta, table, _i, _j, _k, _len, _len1, _len2, _ref, _ref1, _ref2, _ref3; + var archive, boardID, boardOptions, boardSelect, boards, data, event, input, inputs, item, items, name, row, rows, ta, table, _i, _j, _k, _l, _len, _len1, _len2, _len3, _ref, _ref1, _ref2, _ref3, _ref4; section.innerHTML = "
Archiver
404 Redirect is disabled.
Thread redirectionPost fetchingFile redirection
Disabled selections indicate that only one archive is available for that board and redirection type.
Custom Board Navigation
New lines will be converted into spaces.

In the following, board can translate to a board ID (a, b, etc...), the current board (current), or the Status/Twitter link (status, @).
\n For example:
[ toggle-all ] [current-title] [g-title / a-title / jp-title] [x / wsg / h] [t-text:\"Piracy\"]
\n will give you
[ + ] [Technology] [Technology / Anime & Manga / Otaku Culture] [x / wsg / h] [Piracy]
\n if you are on /g/.\n
Board link: board
Title link: board-title
Board link (Replace with title when on that board): board-replace
Full text link: board-full
Custom text link: board-text:\"VIP Board\"
Index-only link: board-index
Catalog-only link: board-catalog
External link: external-text:\"Google\",\"http://www.google.com\"
Combinations are possible: board-index-text:\"VIP Index\"
Full board list toggle: toggle-all
Time Formatting is disabled.
:
Supported format specifiers:
Day: %a, %A, %d, %e
Month: %m, %b, %B
Year: %y, %Y
Hour: %k, %H, %l, %I, %p, %P
Minute: %M
Second: %S
Quote Backlinks formatting is disabled.
:
File Info Formatting is disabled.
:
Link: %l (truncated), %L (untruncated), %T (Unix timestamp)
Original file name: %n (truncated), %N (untruncated), %t (Unix timestamp)
Spoiler indicator: %p
Size: %B (Bytes), %K (KB), %M (MB), %s (4chan default)
Resolution: %r (Displays 'PDF' for PDF files)
Quick Reply Personas is disabled.

\n One item per line.
\n Items will be added in the relevant input's auto-completion list.
\n Password items will always be used, since there is no password input.
\n Lines starting with a # will be ignored.\n

Unread Favicon is disabled.
Emoji is disabled.
\n Sage Icon:
\n Position:
Thread Updater is disabled.
\n Interval:
"; items = {}; @@ -9825,14 +9826,18 @@ className: "board-" + boardID }); row.hidden = boardID !== g.BOARD.ID; - rows.push(row); boardOptions.push($.el('option', { textContent: "/" + boardID + "/", value: "board-" + boardID, selected: boardID === g.BOARD.ID })); data = boards[boardID]; - $.add(row, [Settings.addArchiveCell(boardID, data, 'thread'), Settings.addArchiveCell(boardID, data, 'post'), Settings.addArchiveCell(boardID, data, 'file')]); + _ref4 = ['thread', 'post', 'file']; + for (_l = 0, _len3 = _ref4.length; _l < _len3; _l++) { + item = _ref4[_l]; + $.add(row, Settings.addArchiveCell(boardID, data, item)); + } + rows.push(row); } $.add($('tbody', section), rows); boardSelect = $('#archive-board-select', section); diff --git a/src/General/Config.coffee b/src/General/Config.coffee index 294dfc5aa..f8d3424ec 100644 --- a/src/General/Config.coffee +++ b/src/General/Config.coffee @@ -331,6 +331,10 @@ Config = true 'Add \'(You)\' to quotes linking to your posts.' ] + 'Quoted Title': [ + 'Change the page title to reflect you\'ve been quoted.' + false + ] 'Highlight Posts Quoting You': [ false 'Highlights any posts that contain a quote to your post.' diff --git a/src/General/Settings.coffee b/src/General/Settings.coffee index 885f67339..cc971b805 100644 --- a/src/General/Settings.coffee +++ b/src/General/Settings.coffee @@ -311,7 +311,7 @@ Settings = section.innerHTML = """ <%= grunt.file.read('src/General/html/Settings/Advanced.html').replace(/>\s+<').trim() %> """ - items = {} + items = {} inputs = {} for name in ['boardnav', 'time', 'backlink', 'fileInfo', 'favicon', 'sageEmoji', 'emojiPos', 'usercss'] input = $ "[name=#{name}]", section @@ -346,14 +346,13 @@ Settings = boards = {} for name, archive of Redirect.archives for boardID in archive.boards - data = boards[boardID] or= { + data = boards[boardID] or= thread: [] post: [] file: [] - } data.thread.push name - data.post.push name if archive.software is 'foolfuuka' - data.file.push name if archive.files.contains boardID + data.post.push name if archive.software is 'foolfuuka' + data.file.push name if archive.files.contains boardID rows = [] boardOptions = [] @@ -361,7 +360,6 @@ Settings = row = $.el 'tr', className: "board-#{boardID}" row.hidden = boardID isnt g.BOARD.ID - rows.push row boardOptions.push $.el 'option', textContent: "/#{boardID}/" @@ -369,11 +367,9 @@ Settings = selected: boardID is g.BOARD.ID data = boards[boardID] - $.add row, [ - Settings.addArchiveCell boardID, data, 'thread' - Settings.addArchiveCell boardID, data, 'post' - Settings.addArchiveCell boardID, data, 'file' - ] + $.add row, Settings.addArchiveCell boardID, data, item for item in ['thread', 'post', 'file'] + rows.push row + $.add $('tbody', section), rows boardSelect = $('#archive-board-select', section) diff --git a/src/Monitoring/Unread.coffee b/src/Monitoring/Unread.coffee index 75415b7e5..286656056 100644 --- a/src/Monitoring/Unread.coffee +++ b/src/Monitoring/Unread.coffee @@ -151,7 +151,7 @@ Unread = count = Unread.posts.length if Conf['Unread Count'] - d.title = "#{if count or !Conf['Hide Unread Count at (0)'] then "(#{count}) " else ''}#{if g.DEAD then "/#{g.BOARD}/ - 404" else "#{Unread.title}"}" + d.title = "#{if Conf['Quoted Title'] and Unread.postsQuotingYou.length then '(!) ' else ''}#{if count or !Conf['Hide Unread Count at (0)'] then "(#{count}) " else ''}#{if g.DEAD then "/#{g.BOARD}/ - 404" else "#{Unread.title}"}" <% if (type === 'crx') { %> # XXX Chrome bug where it doesn't always update the tab title. # crbug.com/124381