aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+admin
diff options
context:
space:
mode:
authorRigel Kent <sendmemail@rigelk.eu>2020-05-02 22:38:18 +0200
committerRigel Kent <par@rigelk.eu>2020-05-04 15:01:44 +0200
commit0d3a2982a9b29bd66a05e4b36e606518d4c09959 (patch)
tree13bdc0886216a3bcf1cbaaf63d2c030237f871ca /client/src/app/+admin
parentc2a89b70ce75c4955cbdb1ced6fd20a5010a8c9b (diff)
downloadPeerTube-0d3a2982a9b29bd66a05e4b36e606518d4c09959.tar.gz
PeerTube-0d3a2982a9b29bd66a05e4b36e606518d4c09959.tar.zst
PeerTube-0d3a2982a9b29bd66a05e4b36e606518d4c09959.zip
Switching to a named filters/single input on video-abuse
Diffstat (limited to 'client/src/app/+admin')
-rw-r--r--client/src/app/+admin/moderation/moderation.component.scss1
-rw-r--r--client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.html40
-rw-r--r--client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.scss8
-rw-r--r--client/src/app/+admin/users/user-edit/user-password.component.scss4
4 files changed, 40 insertions, 13 deletions
diff --git a/client/src/app/+admin/moderation/moderation.component.scss b/client/src/app/+admin/moderation/moderation.component.scss
index cf06401cf..26c2a30d4 100644
--- a/client/src/app/+admin/moderation/moderation.component.scss
+++ b/client/src/app/+admin/moderation/moderation.component.scss
@@ -12,6 +12,7 @@
12 12
13 input { 13 input {
14 @include peertube-input-text(250px); 14 @include peertube-input-text(250px);
15 flex-grow: 1;
15 } 16 }
16} 17}
17 18
diff --git a/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.html b/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.html
index 2f6e12d1c..b55b18333 100644
--- a/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.html
+++ b/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.html
@@ -7,10 +7,32 @@
7 <ng-template pTemplate="caption"> 7 <ng-template pTemplate="caption">
8 <div class="caption"> 8 <div class="caption">
9 <div class="ml-auto"> 9 <div class="ml-auto">
10 <input 10 <div class="input-group">
11 type="text" name="table-filter" id="table-filter" i18n-placeholder placeholder="Filter..." 11 <div class="input-group-prepend c-hand" ngbDropdown placement="bottom-left auto" container="body">
12 (keyup)="onSearch($event)" 12 <div class="input-group-text" ngbDropdownToggle>
13 > 13 <span class="caret" aria-haspopup="menu" role="button"></span>
14 </div>
15
16 <div role="menu" ngbDropdownMenu>
17 <h6 class="dropdown-header" i18n>Filter reports</h6>
18
19 <!-- TODO:
20 <div class="dropdown-item" i18n>Reports opened by admins</div>
21 <div class="dropdown-item" i18n>Reports on videos with multiple reports</div>
22 <div class="dropdown-item" i18n>Unassigned reports</div>
23 -->
24 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'state:pending' }" class="dropdown-item" i18n>Unsolved reports</a>
25 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'state:accepted' }" class="dropdown-item" i18n>Accepted reports</a>
26 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'state:rejected' }" class="dropdown-item" i18n>Refused reports</a>
27 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'is:blocked' }" class="dropdown-item" i18n>Reports with blocked videos</a>
28 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'is:deleted' }" class="dropdown-item" i18n>Reports with deleted videos</a>
29 </div>
30 </div>
31 <input
32 type="text" name="table-filter" id="table-filter" i18n-placeholder placeholder="Filter..."
33 (keyup)="onSearch($event)"
34 >
35 </div>
14 </div> 36 </div>
15 </div> 37 </div>
16 </ng-template> 38 </ng-template>
@@ -100,7 +122,7 @@
100 122
101 <td class="action-cell"> 123 <td class="action-cell">
102 <my-action-dropdown 124 <my-action-dropdown
103 [ngClass]="{ 'show': expanded }" placement="bottom-right auto" container="body" 125 [ngClass]="{ 'show': expanded }" placement="bottom-right top-right left auto" container="body"
104 i18n-label label="Actions" [actions]="videoAbuseActions" [entry]="videoAbuse" 126 i18n-label label="Actions" [actions]="videoAbuseActions" [entry]="videoAbuse"
105 ></my-action-dropdown> 127 ></my-action-dropdown>
106 </td> 128 </td>
@@ -118,7 +140,7 @@
118 <div class="d-flex"> 140 <div class="d-flex">
119 <span class="col-3 moderation-expanded-label" i18n>Reporter</span> 141 <span class="col-3 moderation-expanded-label" i18n>Reporter</span>
120 <span class="col-9 moderation-expanded-text"> 142 <span class="col-9 moderation-expanded-text">
121 <div class="chip"> 143 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'reporter:&quot;' + videoAbuse.reporterAccount.displayName + '&quot;' }" class="chip">
122 <img 144 <img
123 class="avatar" 145 class="avatar"
124 [src]="videoAbuse.reporterAccount.avatar.path" 146 [src]="videoAbuse.reporterAccount.avatar.path"
@@ -128,8 +150,8 @@
128 <div> 150 <div>
129 <span class="text-muted">{{ createByString(videoAbuse.reporterAccount) }}</span> 151 <span class="text-muted">{{ createByString(videoAbuse.reporterAccount) }}</span>
130 </div> 152 </div>
131 </div> 153 </a>
132 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': videoAbuse.reporterAccount.displayName }" class="ml-auto text-muted video-details-links" i18n> 154 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'reportee:&quot;' + videoAbuse.reporterAccount.displayName + '&quot;' }" class="ml-auto text-muted video-details-links" i18n>
133 {videoAbuse.countReportsForReporter, plural, =1 {1 report} other {{{ videoAbuse.countReportsForReporter }} reports}}<span class="ml-1 glyphicon glyphicon-flag"></span> 155 {videoAbuse.countReportsForReporter, plural, =1 {1 report} other {{{ videoAbuse.countReportsForReporter }} reports}}<span class="ml-1 glyphicon glyphicon-flag"></span>
134 </a> 156 </a>
135 </span> 157 </span>
@@ -149,7 +171,7 @@
149 <span class="text-muted">{{ videoAbuse.video.channel.ownerAccount ? createByString(videoAbuse.video.channel.ownerAccount) : '' }}</span> 171 <span class="text-muted">{{ videoAbuse.video.channel.ownerAccount ? createByString(videoAbuse.video.channel.ownerAccount) : '' }}</span>
150 </div> 172 </div>
151 </div> 173 </div>
152 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': videoAbuse.video.channel.ownerAccount.displayName }" class="ml-auto text-muted video-details-links" i18n> 174 <a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'reportee:&quot;' +videoAbuse.video.channel.ownerAccount.displayName + '&quot;' }" class="ml-auto text-muted video-details-links" i18n>
153 {videoAbuse.countReportsForReportee, plural, =1 {1 report} other {{{ videoAbuse.countReportsForReportee }} reports}}<span class="ml-1 glyphicon glyphicon-flag"></span> 175 {videoAbuse.countReportsForReportee, plural, =1 {1 report} other {{{ videoAbuse.countReportsForReportee }} reports}}<span class="ml-1 glyphicon glyphicon-flag"></span>
154 </a> 176 </a>
155 </span> 177 </span>
diff --git a/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.scss b/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.scss
index d6bc34935..8eee15b64 100644
--- a/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.scss
+++ b/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.scss
@@ -13,3 +13,11 @@
13.video-abuse-states .glyphicon-comment { 13.video-abuse-states .glyphicon-comment {
14 margin-left: 0.5rem; 14 margin-left: 0.5rem;
15} 15}
16
17.input-group {
18 @include peertube-input-group(300px);
19
20 .dropdown-toggle::after {
21 margin-left: 0;
22 }
23}
diff --git a/client/src/app/+admin/users/user-edit/user-password.component.scss b/client/src/app/+admin/users/user-edit/user-password.component.scss
index 217d585af..5cd93f6af 100644
--- a/client/src/app/+admin/users/user-edit/user-password.component.scss
+++ b/client/src/app/+admin/users/user-edit/user-password.component.scss
@@ -16,7 +16,3 @@ input[type=submit] {
16 16
17 margin-top: 10px; 17 margin-top: 10px;
18} 18}
19
20.input-group-append {
21 height: 30px;
22}