Fixed mismatched comment generation.
This commit is contained in:
parent
3fc0c05b28
commit
8d58bdb40e
1 changed files with 1 additions and 9 deletions
|
@ -223,9 +223,7 @@ function commentConstruct(comment: CommentPostInfo, layer: number = 0): HTMLElem
|
|||
commentUser.className = 'comment__user comment__user--link';
|
||||
commentUser.textContent = comment.username;
|
||||
commentUser.href = '/profile?u=' + comment.user_id;
|
||||
commentUser.style.color = comment.user_colour == null || (comment.user_colour & 0x40000000) > 0
|
||||
? 'inherit'
|
||||
: '#' + (comment.user_colour & 0xFFFFFF).toString(16);
|
||||
commentUser.style.setProperty('--user-colour', colourGetCSS(comment.user_colour));
|
||||
|
||||
const commentLink: HTMLAnchorElement = commentInfo.appendChild(document.createElement('a'));
|
||||
commentLink.className = 'comment__link';
|
||||
|
@ -309,12 +307,6 @@ function commentConstruct(comment: CommentPostInfo, layer: number = 0): HTMLElem
|
|||
const replyInfo: HTMLDivElement = replyContent.appendChild(document.createElement('div'));
|
||||
replyInfo.className = 'comment__info';
|
||||
|
||||
const replyUser: HTMLDivElement = document.createElement('div');
|
||||
replyUser.className = 'comment__user';
|
||||
replyUser.textContent = comment.username;
|
||||
replyUser.style.color = colourGetCSS(comment.user_colour);
|
||||
replyInfo.appendChild(replyUser);
|
||||
|
||||
const replyText: HTMLTextAreaElement = replyContent.appendChild(document.createElement('textarea'));
|
||||
replyText.className = 'comment__text input__textarea comment__text--input';
|
||||
replyText.name = 'comment[text]';
|
||||
|
|
Loading…
Add table
Reference in a new issue