diff --git a/src/js/Comment.js b/src/js/Comment.js index 03f54cff2..0d20aabe6 100644 --- a/src/js/Comment.js +++ b/src/js/Comment.js @@ -159,6 +159,13 @@ export default class Comment extends CommentSkeleton { * @type {?boolean} */ this.isFlashNewOnSightSet = false; + + /** + * Whether the comment (or its signature) is inside a table containing only one comment. + * + * @type {boolean} + */ + this.isInSingleCommentTable = false; } /** diff --git a/src/js/commentLinks.js b/src/js/commentLinks.js index fa2a0da15..f1dc6eca9 100644 --- a/src/js/commentLinks.js +++ b/src/js/commentLinks.js @@ -81,8 +81,9 @@ async function prepare({ dataRequest }) { [moveFromBeginning] = cd.s('es-move-from').match(/^[^[$]+/) || []; [moveToBeginning] = cd.s('es-move-to').match(/^[^[$]+/) || []; - goToCommentToYou = `${cd.s('lp-comment-tooltip')} ${cd.mws('parentheses', cd.s('lp-comment-toyou'))}`; - goToCommentWatchedSection = `${cd.s('lp-comment-tooltip')} ${cd.mws('parentheses', cd.s('lp-comment-watchedsection'))}`; + goToCommentToYou = goToCommentWatchedSection = cd.s('lp-comment-tooltip') + ' '; + goToCommentToYou += cd.mws('parentheses', cd.s('lp-comment-toyou')); + goToCommentWatchedSection += cd.mws('parentheses', cd.s('lp-comment-watchedsection')); const $aRegularPrototype = $('') .text(cd.s('lp-comment')) diff --git a/src/js/processPage.js b/src/js/processPage.js index d5f1db53c..821480a07 100644 --- a/src/js/processPage.js +++ b/src/js/processPage.js @@ -328,15 +328,6 @@ function processComments(parser, feivData) { .querySelectorAll('table.cd-commentPart .cd-signature') .forEach((signature) => { const commentId = signature.closest('.cd-commentPart').dataset.commentId; - - /** - * Whether the comment (or its signature) is inside a table containing only one comment. - * - * @name isInSingleCommentTable - * @type {boolean} - * @memberof module:Comment - * @instance - */ cd.comments[commentId].isInSingleCommentTable = true; });