diff --git a/src/Miscellaneous/IDColor.coffee b/src/Miscellaneous/IDColor.coffee index 9d956c3fe..bb4046c3c 100644 --- a/src/Miscellaneous/IDColor.coffee +++ b/src/Miscellaneous/IDColor.coffee @@ -10,7 +10,7 @@ IDColor = cb: @node node: -> - return if @isClone or !((uid = @info.uniqueID) and (span = $ 'span.hand', @nodes.uniqueID)) + return if @isClone or !((uid = @info.uniqueID) and (span = @nodes.uniqueID)) rgb = IDColor.ids[uid] or IDColor.compute uid diff --git a/src/Miscellaneous/IDHighlight.coffee b/src/Miscellaneous/IDHighlight.coffee index 759a8b607..bf8aaa933 100644 --- a/src/Miscellaneous/IDHighlight.coffee +++ b/src/Miscellaneous/IDHighlight.coffee @@ -9,8 +9,8 @@ IDHighlight = uniqueID: null node: -> - $.on @nodes.uniqueID, 'click', IDHighlight.click @ if @nodes.uniqueID - $.on @nodes.capcode, 'click', IDHighlight.click @ if @nodes.capcode + $.on @nodes.uniqueIDRoot, 'click', IDHighlight.click @ if @nodes.uniqueIDRoot + $.on @nodes.capcode, 'click', IDHighlight.click @ if @nodes.capcode IDHighlight.set @ unless @isClone set: (post) -> diff --git a/src/Miscellaneous/IDPostCount.coffee b/src/Miscellaneous/IDPostCount.coffee index cca9d1abb..5e8896c70 100644 --- a/src/Miscellaneous/IDPostCount.coffee +++ b/src/Miscellaneous/IDPostCount.coffee @@ -10,7 +10,7 @@ IDPostCount = node: -> if @nodes.uniqueID and @thread is IDPostCount.thread - $.on $('span.hand', @nodes.uniqueID), 'mouseover', IDPostCount.count + $.on @nodes.uniqueID, 'mouseover', IDPostCount.count count: -> {uniqueID} = Get.postFromNode(@).info diff --git a/src/classes/Post.coffee b/src/classes/Post.coffee index 272f572be..2f8050a1f 100644 --- a/src/classes/Post.coffee +++ b/src/classes/Post.coffee @@ -27,7 +27,7 @@ class Post subject: @nodes.subject?.textContent or undefined name: @nodes.name?.textContent tripcode: @nodes.tripcode?.textContent - uniqueID: @nodes.uniqueID?.firstElementChild.textContent + uniqueID: @nodes.uniqueID?.textContent capcode: @nodes.capcode?.textContent.replace '## ', '' pass: @nodes.pass?.title.match(/\d*$/)[0] flagCode: @nodes.flag?.className.match(/flag-(\w+)/)?[1].toUpperCase() @@ -65,25 +65,26 @@ class Post post = $ '.post', root info = $ '.postInfo', post nodes = - root: root - post: post - info: info - subject: $ '.subject', info - name: $ '.name', info - email: $ '.useremail', info - tripcode: $ '.postertrip', info - uniqueID: $ '.posteruid', info - capcode: $ '.capcode.hand', info - pass: $ '.n-pu', info - flag: $ '.flag, .countryFlag', info - date: $ '.dateTime', info - nameBlock: $ '.nameBlock', info - quote: $ '.postNum > a:nth-of-type(2)', info - reply: $ '.replylink', info - fileRoot: $ '.file', post - comment: $ '.postMessage', post - links: [] - quotelinks: [] + root: root + post: post + info: info + subject: $ '.subject', info + name: $ '.name', info + email: $ '.useremail', info + tripcode: $ '.postertrip', info + uniqueIDRoot: $ '.posteruid', info + uniqueID: $ '.posteruid > .hand', info + capcode: $ '.capcode.hand', info + pass: $ '.n-pu', info + flag: $ '.flag, .countryFlag', info + date: $ '.dateTime', info + nameBlock: $ '.nameBlock', info + quote: $ '.postNum > a:nth-of-type(2)', info + reply: $ '.replylink', info + fileRoot: $ '.file', post + comment: $ '.postMessage', post + links: [] + quotelinks: [] archivelinks: [] # XXX Edge invalidates HTMLCollections when an ancestor node is inserted into another node.