Commit 3384b8f5 authored by Janik Münzenberger's avatar Janik Münzenberger
Browse files

Added autocompletes

parent c9541d4d
......@@ -6,28 +6,16 @@ import {NotificationService} from './services/notification.service';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
styleUrls: ['./app.component.css'],
})
export class AppComponent {
readonly VAPID_PUBLIC_KEY = 'BNaGf2POUom9qpnI45OSE8gmzjeqdvk-4HoV7Is-3RjPeCWMtgcukwEVPp0K2xMdfmSrGCS2be5rFIYX2qRwoEc';
constructor(translate: TranslateService) {
constructor(translate: TranslateService,
private notificationService: NotificationService) {
translate.setDefaultLang('en');
translate.use('en');
// this.subscribeToNotifications();
}
subscribeToNotifications() {
this.swPush.requestSubscription({
serverPublicKey: this.VAPID_PUBLIC_KEY
})
.then(sub => {
this.notificationservice.addPushSubscriber(sub).subscribe();
console.log(sub);
})
.catch(err => console.error('Could not subscribe to notifications', err));
}
}
......@@ -9,25 +9,25 @@
<div class="form-group row">
<label for="name" class="col-sm-2 col-form-label">{{"PROFILE.NAME" | translate}}:</label>
<div class="col-sm-10">
<input type="name" readonly class="form-control-plaintext" id="name" [value]="user.name">
<input type="name" autocomplete="name" readonly class="form-control-plaintext" id="name" [value]="user.name">
</div>
</div>
<div class="form-group row">
<label for="email" class="col-sm-2 col-form-label">{{"PROFILE.EMAIL" | translate}}:</label>
<div class="col-sm-10">
<input type="email" readonly class="form-control-plaintext" id="email" [value]="user.email">
<input type="email" autocomplete="email" readonly class="form-control-plaintext" id="email" [value]="user.email">
</div>
</div>
<div class="form-group row">
<label for="passwordOld" class="col-sm-2 col-form-label">{{"PROFILE.OLD_PASSWORD" | translate}}:</label>
<div class="col-sm-10">
<input type="password" class="form-control" id="passwordOld" name="password" [placeholder]="'PROFILE.OLD_PASSWORD' | translate" [(ngModel)]="update.password">
<input type="password" autocomplete="current-password" class="form-control" id="passwordOld" name="password" [placeholder]="'PROFILE.OLD_PASSWORD' | translate" [(ngModel)]="update.password">
</div>
</div>
<div class="form-group row">
<label for="passwordNew" class="col-sm-2 col-form-label">{{"PROFILE.NEW_PASSWORD" | translate}}:</label>
<div class="col-sm-10">
<input type="password" class="form-control" id="passwordNew" name="new_password" [placeholder]="'PROFILE.NEW_PASSWORD' | translate" [(ngModel)]="update.new_password">
<input type="password" autocomplete="new-password" class="form-control" id="passwordNew" name="new_password" [placeholder]="'PROFILE.NEW_PASSWORD' | translate" [(ngModel)]="update.new_password">
</div>
</div>
<div class="form-group row">
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment