]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - client/src/app/+admin/overview/comments/video-comment-list.component.html
Migrate to bootstrap 5
[github/Chocobozzz/PeerTube.git] / client / src / app / +admin / overview / comments / video-comment-list.component.html
1 <h1>
2 <my-global-icon iconName="message-circle" aria-hidden="true"></my-global-icon>
3 <ng-container i18n>Video comments</ng-container>
4
5 <my-feed [syndicationItems]="syndicationItems"></my-feed>
6 </h1>
7
8 <em i18n>This view also shows comments from muted accounts.</em>
9
10 <p-table
11 [value]="comments" [paginator]="totalRecords > 0" [totalRecords]="totalRecords" [rows]="rowsPerPage" [rowsPerPageOptions]="rowsPerPageOptions"
12 [sortField]="sort.field" [sortOrder]="sort.order" dataKey="id"
13 [lazy]="true" (onLazyLoad)="loadLazy($event)" [lazyLoadOnInit]="false" [selectionPageOnly]="true"
14 [showCurrentPageReport]="true" i18n-currentPageReportTemplate
15 currentPageReportTemplate="Showing {{'{first}'}} to {{'{last}'}} of {{'{totalRecords}'}} comments"
16 [expandedRowKeys]="expandedRows" [(selection)]="selectedComments"
17 >
18 <ng-template pTemplate="caption">
19 <div class="caption">
20 <div>
21 <my-action-dropdown
22 *ngIf="isInSelectionMode()" i18n-label label="Batch actions" theme="orange"
23 [actions]="bulkCommentActions" [entry]="selectedComments"
24 >
25 </my-action-dropdown>
26 </div>
27
28 <div class="ms-auto right-form">
29 <my-advanced-input-filter [filters]="inputFilters" (search)="onSearch($event)"></my-advanced-input-filter>
30
31 <my-button i18n-label label="Refresh" icon="refresh" (click)="reloadData()"></my-button>
32 </div>
33 </div>
34 </ng-template>
35
36 <ng-template pTemplate="header">
37 <tr>
38 <th style="width: 40px;">
39 <p-tableHeaderCheckbox ariaLabel="Select all rows" i18n-ariaLabel></p-tableHeaderCheckbox>
40 </th>
41 <th style="width: 40px;"></th>
42 <th style="width: 150px;"></th>
43 <th style="width: 300px;" i18n>Account</th>
44 <th style="width: 300px;" i18n>Video</th>
45 <th i18n>Comment</th>
46 <th style="width: 150px;" i18n pSortableColumn="createdAt">Date <p-sortIcon field="createdAt"></p-sortIcon></th>
47 </tr>
48 </ng-template>
49
50 <ng-template pTemplate="body" let-videoComment let-expanded="expanded">
51 <tr [pSelectableRow]="videoComment">
52
53 <td class="checkbox-cell">
54 <p-tableCheckbox [value]="videoComment" ariaLabel="Select this row" i18n-ariaLabel></p-tableCheckbox>
55 </td>
56
57 <td class="expand-cell" [pRowToggler]="videoComment">
58 <my-table-expander-icon i18n-ngbTooltip ngbTooltip="See full comment" [expanded]="expanded"></my-table-expander-icon>
59 </td>
60
61 <td class="action-cell">
62 <my-action-dropdown
63 [ngClass]="{ 'show': expanded }" placement="bottom-right" container="body"
64 i18n-label label="Actions" [actions]="videoCommentActions" [entry]="videoComment"
65 ></my-action-dropdown>
66 </td>
67
68 <td>
69 <a [href]="videoComment.account.localUrl" i18n-title title="Open account in a new tab" target="_blank" rel="noopener noreferrer">
70 <div class="chip two-lines">
71 <my-actor-avatar [account]="videoComment.account" size="32"></my-actor-avatar>
72 <div>
73 {{ videoComment.account.displayName }}
74 <span>{{ videoComment.by }}</span>
75 </div>
76 </div>
77 </a>
78 </td>
79
80 <td class="video">
81 <em i18n>Commented video</em>
82
83 <a [href]="videoComment.localUrl" target="_blank" rel="noopener noreferrer">{{ videoComment.video.name }}</a>
84 </td>
85
86 <td class="comment-html c-hand" [pRowToggler]="videoComment">
87 <div [innerHTML]="videoComment.textHtml"></div>
88 </td>
89
90 <td class="c-hand" [pRowToggler]="videoComment">{{ videoComment.createdAt | date: 'short' }}</td>
91 </tr>
92 </ng-template>
93
94 <ng-template pTemplate="rowexpansion" let-videoComment>
95 <tr>
96 <td class="expand-cell" colspan="5">
97 <div [innerHTML]="videoComment.textHtml"></div>
98 </td>
99 </tr>
100 </ng-template>
101
102 <ng-template pTemplate="emptymessage">
103 <tr>
104 <td colspan="7">
105 <div class="no-results">
106 <ng-container *ngIf="search" i18n>No comments found matching current filters.</ng-container>
107 <ng-container *ngIf="!search" i18n>No comments found.</ng-container>
108 </div>
109 </td>
110 </tr>
111 </ng-template>
112 </p-table>
113