aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+admin
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-10-10 15:39:27 +0200
committerChocobozzz <me@florianbigard.com>2022-10-10 15:39:27 +0200
commit8347f8a429ceb98b068fac577a0321bd67ae1b07 (patch)
treed63ded024832b8f3c490c97cd472f522d4b351d1 /client/src/app/+admin
parent5cc2f0ea0a0af82333d673db1ad6461ed5cb4233 (diff)
downloadPeerTube-8347f8a429ceb98b068fac577a0321bd67ae1b07.tar.gz
PeerTube-8347f8a429ceb98b068fac577a0321bd67ae1b07.tar.zst
PeerTube-8347f8a429ceb98b068fac577a0321bd67ae1b07.zip
Add auto complete to user edit password
Diffstat (limited to 'client/src/app/+admin')
-rw-r--r--client/src/app/+admin/overview/users/user-edit/user-edit.ts3
-rw-r--r--client/src/app/+admin/overview/users/user-edit/user-password.component.html4
2 files changed, 5 insertions, 2 deletions
diff --git a/client/src/app/+admin/overview/users/user-edit/user-edit.ts b/client/src/app/+admin/overview/users/user-edit/user-edit.ts
index 21e9629ab..5428f6ce9 100644
--- a/client/src/app/+admin/overview/users/user-edit/user-edit.ts
+++ b/client/src/app/+admin/overview/users/user-edit/user-edit.ts
@@ -62,7 +62,8 @@ export abstract class UserEdit extends FormReactive implements OnInit {
62 62
63 displayDangerZone () { 63 displayDangerZone () {
64 if (this.isCreation()) return false 64 if (this.isCreation()) return false
65 if (this.user?.pluginAuth) return false 65 if (!this.user) return false
66 if (this.user.pluginAuth) return false
66 if (this.auth.getUser().id === this.user.id) return false 67 if (this.auth.getUser().id === this.user.id) return false
67 68
68 return true 69 return true
diff --git a/client/src/app/+admin/overview/users/user-edit/user-password.component.html b/client/src/app/+admin/overview/users/user-edit/user-password.component.html
index 13f57024b..173825957 100644
--- a/client/src/app/+admin/overview/users/user-edit/user-password.component.html
+++ b/client/src/app/+admin/overview/users/user-edit/user-password.component.html
@@ -1,8 +1,10 @@
1<form role="form" (ngSubmit)="formValidated()" [formGroup]="form"> 1<form role="form" (ngSubmit)="formValidated()" [formGroup]="form">
2 2
3 <div class="input-group"> 3 <div class="input-group">
4 <input id="password" [attr.type]="showPassword ? 'text' : 'password'" class="form-control" 4 <input id="password"
5 [attr.type]="showPassword ? 'text' : 'password'" class="form-control"
5 formControlName="password" [ngClass]="{ 'input-error': formErrors['password'] }" 6 formControlName="password" [ngClass]="{ 'input-error': formErrors['password'] }"
7 autocomplete="new-password"
6 > 8 >
7 <button class="btn btn-sm btn-outline-secondary" (click)="togglePasswordVisibility()" type="button"> 9 <button class="btn btn-sm btn-outline-secondary" (click)="togglePasswordVisibility()" type="button">
8 <ng-container *ngIf="!showPassword" i18n>Show</ng-container> 10 <ng-container *ngIf="!showPassword" i18n>Show</ng-container>