2 <div class=
"title-block">
3 <h2 class=
"title-page title-page-single">
4 <ng-container *
ngIf=
"componentPagination.totalItems > 0; then hasComments; else noComments"></ng-container>
5 <ng-template #hasComments
>
6 <ng-container i18n *
ngIf=
"componentPagination.totalItems === 1; else manyComments">1 Comment
</ng-container>
7 <ng-template i18n #manyComments
>{{ componentPagination.totalItems }} Comments
</ng-template>
9 <ng-template i18n #noComments
>Comments
</ng-template>
12 <my-feed [syndicationItems]=
"syndicationItems"></my-feed>
14 <div ngbDropdown
class=
"d-inline-block ml-4">
15 <button class=
"btn btn-sm btn-outline-secondary" id=
"dropdown-sort-comments" ngbDropdownToggle i18n
>
18 <div ngbDropdownMenu
aria-labelledby=
"dropdown-sort-comments">
19 <button (click)=
"handleSortChange('-createdAt')" ngbDropdownItem i18n
>Most recent first (default)
</button>
20 <button (click)=
"handleSortChange('-totalReplies')" ngbDropdownItem i18n
>Most replies first
</button>
25 <ng-template [ngIf]=
"video.commentsEnabled === true">
29 (commentCreated)=
"onCommentThreadCreated($event)"
30 ></my-video-comment-add>
32 <div *
ngIf=
"componentPagination.totalItems === 0 && comments.length === 0" i18n
>No comments.
</div>
35 class=
"comment-threads"
38 (nearOfBottom)=
"onNearOfBottom()"
39 [dataObservable]=
"onDataSubject.asObservable()"
42 <div class=
"anchor" #commentHighlightBlock
id=
"highlighted-comment"></div>
44 *
ngIf=
"highlightedThread"
45 [comment]=
"highlightedThread"
47 [inReplyToCommentId]=
"inReplyToCommentId"
48 [commentTree]=
"threadComments[highlightedThread.id]"
49 [highlightedComment]=
"true"
50 [firstInThread]=
"true"
51 (wantedToReply)=
"onWantedToReply($event)"
52 (wantedToDelete)=
"onWantedToDelete($event)"
53 (threadCreated)=
"onThreadCreated($event)"
54 (resetReply)=
"onResetReply()"
55 (timestampClicked)=
"handleTimestampClicked($event)"
59 <div *
ngFor=
"let comment of comments; index as i">
61 *
ngIf=
"!highlightedThread || comment.id !== highlightedThread.id"
64 [inReplyToCommentId]=
"inReplyToCommentId"
65 [commentTree]=
"threadComments[comment.id]"
66 [firstInThread]=
"i + 1 !== comments.length"
67 (wantedToReply)=
"onWantedToReply($event)"
68 (wantedToDelete)=
"onWantedToDelete($event)"
69 (threadCreated)=
"onThreadCreated($event)"
70 (resetReply)=
"onResetReply()"
71 (timestampClicked)=
"handleTimestampClicked($event)"
73 <div *
ngIf=
"comment.totalReplies !== 0 && !threadComments[comment.id]" (click)=
"viewReplies(comment.id)" class=
"view-replies mb-2">
74 <span class=
"glyphicon glyphicon-menu-down"></span>
76 <ng-container *
ngIf=
"comment.totalRepliesFromVideoAuthor > 0; then hasAuthorComments; else noAuthorComments"></ng-container>
77 <ng-template #hasAuthorComments
>
78 <ng-container *
ngIf=
"comment.totalReplies !== comment.totalRepliesFromVideoAuthor; else onlyAuthorComments" i18n
>
79 View {{ comment.totalReplies }} replies from {{ video?.account?.displayName || 'the author' }} and others
81 <ng-template i18n #onlyAuthorComments
>
82 View {{ comment.totalReplies }} replies from {{ video?.account?.displayName || 'the author' }}
85 <ng-template i18n #noAuthorComments
>View {{ comment.totalReplies }} replies
</ng-template>
87 <my-small-loader class=
"comment-thread-loading ml-1" [loading]=
"threadLoading[comment.id]"></my-small-loader>
95 <div *
ngIf=
"video.commentsEnabled === false" i18n
>
96 Comments are disabled.