login.component.ts 831 Bytes
Newer Older
Lukas Burgey's avatar
Lukas Burgey committed
1 2 3 4 5 6
import { Component } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';

import { ProfileComponent } from '../profile/profile.component';
import { SshKeysComponent } from '../ssh-keys/ssh-keys.component';
import { UserService } from '../user.service';
Lukas Burgey's avatar
Lukas Burgey committed
7 8 9 10 11 12

@Component({
  selector: 'app-login',
  templateUrl: './login.component.html',
  styleUrls: ['./login.component.css']
})
Lukas Burgey's avatar
Lukas Burgey committed
13 14
export class LoginComponent {
  private profileDialog;
Lukas Burgey's avatar
Lukas Burgey committed
15

Lukas Burgey's avatar
Lukas Burgey committed
16 17 18 19
  constructor(
    public userService: UserService,
    public dialog: MatDialog,
  ) { }
Lukas Burgey's avatar
Lukas Burgey committed
20

Lukas Burgey's avatar
Lukas Burgey committed
21 22 23 24 25 26 27 28
  public openProfile() {
    this.profileDialog = this.dialog.open(
      ProfileComponent,
      {
        width: '80%',
      }
    );
  }
Lukas Burgey's avatar
Lukas Burgey committed
29

Lukas Burgey's avatar
Lukas Burgey committed
30 31 32 33 34 35 36 37
  public openSshKeys() {
    this.profileDialog = this.dialog.open(
      SshKeysComponent,
      {
        width: '80%',
      }
    );
  }
Lukas Burgey's avatar
Lukas Burgey committed
38
}