aboutsummaryrefslogtreecommitdiffhomepage
path: root/client
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-11-16 14:26:50 +0100
committerChocobozzz <me@florianbigard.com>2020-11-16 14:26:50 +0100
commit7706b3703aeb2bea686b12089959b963a7dd89f4 (patch)
treef0b42ccf01563de7ee7e936c3716ab7a8e149a38 /client
parent9be63f123e23d9622b5250511cf8f21e463c3ee5 (diff)
downloadPeerTube-7706b3703aeb2bea686b12089959b963a7dd89f4.tar.gz
PeerTube-7706b3703aeb2bea686b12089959b963a7dd89f4.tar.zst
PeerTube-7706b3703aeb2bea686b12089959b963a7dd89f4.zip
Put admin actions on the left
Diffstat (limited to 'client')
-rw-r--r--client/src/app/+admin/moderation/video-block-list/video-block-list.component.html16
-rw-r--r--client/src/app/+admin/moderation/video-comment-list/video-comment-list.component.html16
-rw-r--r--client/src/app/+admin/users/user-list/user-list.component.html2
-rw-r--r--client/src/app/shared/shared-abuse-list/abuse-list-table.component.html18
-rw-r--r--client/src/sass/include/_variables.scss2
-rw-r--r--client/src/sass/primeng-custom.scss2
6 files changed, 28 insertions, 28 deletions
diff --git a/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html b/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html
index d39aacb76..96293ae5e 100644
--- a/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html
+++ b/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html
@@ -39,11 +39,11 @@
39 <ng-template pTemplate="header"> 39 <ng-template pTemplate="header">
40 <tr> 40 <tr>
41 <th style="width: 40px"></th> 41 <th style="width: 40px"></th>
42 <th style="width: 150px;"></th>
42 <th i18n pSortableColumn="name">Video <p-sortIcon field="name"></p-sortIcon></th> 43 <th i18n pSortableColumn="name">Video <p-sortIcon field="name"></p-sortIcon></th>
43 <th style="width: 100px;" i18n>Sensitive</th> 44 <th style="width: 100px;" i18n>Sensitive</th>
44 <th style="width: 120px;" i18n>Unfederated</th> 45 <th style="width: 120px;" i18n>Unfederated</th>
45 <th style="width: 150px;" i18n pSortableColumn="createdAt">Date <p-sortIcon field="createdAt"></p-sortIcon></th> 46 <th style="width: 150px;" i18n pSortableColumn="createdAt">Date <p-sortIcon field="createdAt"></p-sortIcon></th>
46 <th style="width: 150px;"></th>
47 </tr> 47 </tr>
48 </ng-template> 48 </ng-template>
49 49
@@ -56,6 +56,13 @@
56 </span> 56 </span>
57 </td> 57 </td>
58 58
59 <td class="action-cell">
60 <my-action-dropdown
61 [ngClass]="{ 'show': expanded }" placement="bottom-right" container="body"
62 i18n-label label="Actions" [actions]="videoBlocklistActions" [entry]="videoBlock"
63 ></my-action-dropdown>
64 </td>
65
59 <td> 66 <td>
60 <a [href]="getVideoUrl(videoBlock)" class="table-video-link" [title]="videoBlock.video.name" target="_blank" rel="noopener noreferrer"> 67 <a [href]="getVideoUrl(videoBlock)" class="table-video-link" [title]="videoBlock.video.name" target="_blank" rel="noopener noreferrer">
61 <div class="table-video"> 68 <div class="table-video">
@@ -83,13 +90,6 @@
83 <td>{{ booleanToText(videoBlock.unfederated) }}</td> 90 <td>{{ booleanToText(videoBlock.unfederated) }}</td>
84 <td>{{ videoBlock.createdAt | date: 'short' }}</td> 91 <td>{{ videoBlock.createdAt | date: 'short' }}</td>
85 </ng-container> 92 </ng-container>
86
87 <td class="action-cell">
88 <my-action-dropdown
89 [ngClass]="{ 'show': expanded }" placement="bottom-right" container="body"
90 i18n-label label="Actions" [actions]="videoBlocklistActions" [entry]="videoBlock"
91 ></my-action-dropdown>
92 </td>
93 </tr> 93 </tr>
94 </ng-template> 94 </ng-template>
95 95
diff --git a/client/src/app/+admin/moderation/video-comment-list/video-comment-list.component.html b/client/src/app/+admin/moderation/video-comment-list/video-comment-list.component.html
index 45c5fe28f..5c932739b 100644
--- a/client/src/app/+admin/moderation/video-comment-list/video-comment-list.component.html
+++ b/client/src/app/+admin/moderation/video-comment-list/video-comment-list.component.html
@@ -43,11 +43,11 @@
43 <ng-template pTemplate="header"> 43 <ng-template pTemplate="header">
44 <tr> 44 <tr>
45 <th style="width: 40px"></th> 45 <th style="width: 40px"></th>
46 <th style="width: 150px;"></th>
46 <th style="width: 300px" i18n>Account</th> 47 <th style="width: 300px" i18n>Account</th>
47 <th style="width: 300px" i18n>Video</th> 48 <th style="width: 300px" i18n>Video</th>
48 <th i18n>Comment</th> 49 <th i18n>Comment</th>
49 <th style="width: 150px;" i18n pSortableColumn="createdAt">Date <p-sortIcon field="createdAt"></p-sortIcon></th> 50 <th style="width: 150px;" i18n pSortableColumn="createdAt">Date <p-sortIcon field="createdAt"></p-sortIcon></th>
50 <th style="width: 150px;"></th>
51 </tr> 51 </tr>
52 </ng-template> 52 </ng-template>
53 53
@@ -59,6 +59,13 @@
59 </span> 59 </span>
60 </td> 60 </td>
61 61
62 <td class="action-cell">
63 <my-action-dropdown
64 [ngClass]="{ 'show': expanded }" placement="bottom-right" container="body"
65 i18n-label label="Actions" [actions]="videoCommentActions" [entry]="videoComment"
66 ></my-action-dropdown>
67 </td>
68
62 <td> 69 <td>
63 <a [href]="videoComment.account.localUrl" i18n-title title="Open account in a new tab" target="_blank" rel="noopener noreferrer"> 70 <a [href]="videoComment.account.localUrl" i18n-title title="Open account in a new tab" target="_blank" rel="noopener noreferrer">
64 <div class="chip two-lines"> 71 <div class="chip two-lines">
@@ -86,13 +93,6 @@
86 </td> 93 </td>
87 94
88 <td>{{ videoComment.createdAt | date: 'short' }}</td> 95 <td>{{ videoComment.createdAt | date: 'short' }}</td>
89
90 <td class="action-cell">
91 <my-action-dropdown
92 [ngClass]="{ 'show': expanded }" placement="bottom-right" container="body"
93 i18n-label label="Actions" [actions]="videoCommentActions" [entry]="videoComment"
94 ></my-action-dropdown>
95 </td>
96 </tr> 96 </tr>
97 </ng-template> 97 </ng-template>
98 98
diff --git a/client/src/app/+admin/users/user-list/user-list.component.html b/client/src/app/+admin/users/user-list/user-list.component.html
index 003fbd323..63144502c 100644
--- a/client/src/app/+admin/users/user-list/user-list.component.html
+++ b/client/src/app/+admin/users/user-list/user-list.component.html
@@ -86,7 +86,7 @@
86 <ng-template pTemplate="body" let-expanded="expanded" let-user> 86 <ng-template pTemplate="body" let-expanded="expanded" let-user>
87 87
88 <tr [pSelectableRow]="user" [ngClass]="{ banned: highlightBannedUsers && user.blocked }"> 88 <tr [pSelectableRow]="user" [ngClass]="{ banned: highlightBannedUsers && user.blocked }">
89 <td> 89 <td class="checkbox-cell">
90 <p-tableCheckbox [value]="user"></p-tableCheckbox> 90 <p-tableCheckbox [value]="user"></p-tableCheckbox>
91 </td> 91 </td>
92 92
diff --git a/client/src/app/shared/shared-abuse-list/abuse-list-table.component.html b/client/src/app/shared/shared-abuse-list/abuse-list-table.component.html
index d8fe8b2d3..90638d176 100644
--- a/client/src/app/shared/shared-abuse-list/abuse-list-table.component.html
+++ b/client/src/app/shared/shared-abuse-list/abuse-list-table.component.html
@@ -37,24 +37,31 @@
37 <ng-template pTemplate="header"> 37 <ng-template pTemplate="header">
38 <tr> <!-- header --> 38 <tr> <!-- header -->
39 <th style="width: 40px;"></th> 39 <th style="width: 40px;"></th>
40 <th style="width: 150px;"></th>
40 <th *ngIf="isAdminView()" style="width: 20%;" pResizableColumn i18n>Reporter</th> 41 <th *ngIf="isAdminView()" style="width: 20%;" pResizableColumn i18n>Reporter</th>
41 <th i18n>Video/Comment/Account</th> 42 <th i18n>Video/Comment/Account</th>
42 <th style="width: 150px;" i18n pSortableColumn="createdAt">Created <p-sortIcon field="createdAt"></p-sortIcon></th> 43 <th style="width: 150px;" i18n pSortableColumn="createdAt">Created <p-sortIcon field="createdAt"></p-sortIcon></th>
43 <th i18n pSortableColumn="state" style="width: 80px;">State <p-sortIcon field="state"></p-sortIcon></th> 44 <th i18n pSortableColumn="state" style="width: 80px;">State <p-sortIcon field="state"></p-sortIcon></th>
44 <th i18n style="width: 80px;">Messages</th> 45 <th i18n style="width: 80px;">Messages</th>
45 <th i18n *ngIf="isAdminView()" style="width: 100px;">Internal note</th> 46 <th i18n *ngIf="isAdminView()" style="width: 100px;">Internal note</th>
46 <th style="width: 150px;"></th>
47 </tr> 47 </tr>
48 </ng-template> 48 </ng-template>
49 49
50 <ng-template pTemplate="body" let-expanded="expanded" let-abuse> 50 <ng-template pTemplate="body" let-expanded="expanded" let-abuse>
51 <tr> 51 <tr>
52 <td class="c-hand" [pRowToggler]="abuse" i18n-ngbTooltip ngbTooltip="More information" placement="top-left" container="body"> 52 <td class="expand-cell c-hand" [pRowToggler]="abuse" i18n-ngbTooltip ngbTooltip="More information" placement="top-left" container="body">
53 <span class="expander"> 53 <span class="expander">
54 <i [ngClass]="expanded ? 'glyphicon glyphicon-menu-down' : 'glyphicon glyphicon-menu-right'"></i> 54 <i [ngClass]="expanded ? 'glyphicon glyphicon-menu-down' : 'glyphicon glyphicon-menu-right'"></i>
55 </span> 55 </span>
56 </td> 56 </td>
57 57
58 <td class="action-cell">
59 <my-action-dropdown
60 [ngClass]="{ 'show': expanded }" placement="bottom-right top-right left auto" container="body"
61 i18n-label label="Actions" [actions]="abuseActions" [entry]="abuse"
62 ></my-action-dropdown>
63 </td>
64
58 <td *ngIf="isAdminView()"> 65 <td *ngIf="isAdminView()">
59 <a *ngIf="abuse.reporterAccount" [href]="abuse.reporterAccount.url" i18n-title title="Open account in a new tab" target="_blank" rel="noopener noreferrer"> 66 <a *ngIf="abuse.reporterAccount" [href]="abuse.reporterAccount.url" i18n-title title="Open account in a new tab" target="_blank" rel="noopener noreferrer">
60 <div class="chip two-lines"> 67 <div class="chip two-lines">
@@ -163,13 +170,6 @@
163 <td *ngIf="isAdminView()" class="internal-note" container="body" placement="left auto" [ngbTooltip]="abuse.moderationComment"> 170 <td *ngIf="isAdminView()" class="internal-note" container="body" placement="left auto" [ngbTooltip]="abuse.moderationComment">
164 {{ abuse.moderationComment }} 171 {{ abuse.moderationComment }}
165 </td> 172 </td>
166
167 <td class="action-cell">
168 <my-action-dropdown
169 [ngClass]="{ 'show': expanded }" placement="bottom-right top-right left auto" container="body"
170 i18n-label label="Actions" [actions]="abuseActions" [entry]="abuse"
171 ></my-action-dropdown>
172 </td>
173 </tr> 173 </tr>
174 </ng-template> 174 </ng-template>
175 175
diff --git a/client/src/sass/include/_variables.scss b/client/src/sass/include/_variables.scss
index b1e0431bb..7fe6efe32 100644
--- a/client/src/sass/include/_variables.scss
+++ b/client/src/sass/include/_variables.scss
@@ -127,6 +127,7 @@ $variables: (
127$zindex: ( 127$zindex: (
128 miniature : 10, 128 miniature : 10,
129 privacymsg : 20, 129 privacymsg : 20,
130 dropdown : 12000,
130 sub-menu : 12500, 131 sub-menu : 12500,
131 menu : 12600, 132 menu : 12600,
132 search-typeahead: 12650, 133 search-typeahead: 12650,
@@ -135,7 +136,6 @@ $zindex: (
135 tooltip : 14000, 136 tooltip : 14000,
136 loadbar : 15000, 137 loadbar : 15000,
137 modal : 16000, 138 modal : 16000,
138 dropdown : 17000,
139 help-popover : 17000, 139 help-popover : 17000,
140 notification : 18000, 140 notification : 18000,
141 hotkeys : 19000 141 hotkeys : 19000
diff --git a/client/src/sass/primeng-custom.scss b/client/src/sass/primeng-custom.scss
index 750c433b5..2ffa2d3ff 100644
--- a/client/src/sass/primeng-custom.scss
+++ b/client/src/sass/primeng-custom.scss
@@ -54,7 +54,7 @@ p-table {
54 td { 54 td {
55 padding-left: 15px !important; 55 padding-left: 15px !important;
56 56
57 &:not(.action-cell):not(.expand-cell) { 57 &:not(.action-cell):not(.expand-cell):not(.checkbox-cell) {
58 overflow: hidden !important; 58 overflow: hidden !important;
59 text-overflow: ellipsis !important; 59 text-overflow: ellipsis !important;
60 white-space: nowrap !important; 60 white-space: nowrap !important;