Advertisement
Guest User

Untitled

a guest
Apr 19th, 2017
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.39 KB | None | 0 0
  1. /**
  2. * Created by Ali on 17.04.2017.
  3. */
  4. import {Component } from '@angular/core';
  5.  
  6. @Component({
  7. selector: 'login',
  8. template: `
  9. <!doctype html>
  10. <html lang="de">
  11. <head>
  12. <meta charset="utf-8">
  13. <title>BIG Smart Home - Anmelden</title>
  14. <meta name="viewport" content="width=device-width, initial-scale=1">
  15. <link rel="stylesheet" href="../../styles/style.css">
  16. </head>
  17. <body data-decimal-separator="," data-grouping-separator=".">
  18.  
  19. <div role="navigation" aria-label="jumplinks">
  20. <a href="#formheadline" class="accessibility">Zum Inhalt springen</a>
  21. </div>
  22.  
  23. <header aria-labelledby="bannerheadline">
  24. <a href="login.html">
  25. <img class="title-image" src="../../images/big-logo-small.png" alt="BIG Smart Home logo">
  26. </a>
  27. <h1 class="header-title" id="bannerheadline">
  28. BIG Smart Home
  29. </h1>
  30. <nav aria-labelledby="navigationheadline">
  31. <h2 class="accessibility" id="navigationheadline">Navigation</h2>
  32. <ul class="navigation-list">
  33. </ul>
  34. </nav>
  35. </header>
  36. <div class="main-container">
  37. <main aria-labelledby="formheadline">
  38. <form class="form" method="post" action="overview.html">
  39. <h2 id="formheadline" class="registration-headline">Anmelden</h2>
  40. <div class="form-row">
  41. <label class="form-label" for="username-input">
  42. Benutzername
  43. </label>
  44. <input type="text" name="username" id="username-input" required class="form-input" [(ngModel)]="username">
  45. <span id="username-error" class="error-text"></span>
  46. </div>
  47. <div class="form-row">
  48. <label class="form-label" for="password-input">
  49. Passwort
  50. </label>
  51. <input type="password" name="password" id="password-input" required class="form-input" minlength="4"
  52. maxlength="12" [(ngModel)]="password">
  53. <span id="password-error" class="error-text"></span>
  54. </div>
  55. <div class="form-row form-row-center">
  56. <button class="button button-submit" (click)="anmelden() routerLink = "/options-route" routerLinkActive="active" >
  57. Anmelden
  58. </button>
  59. </div>
  60. </form>
  61. </main>
  62. </div>
  63. <footer>
  64. © 2017 BIG Smart Home
  65. </footer>
  66. </body>
  67. </html>
  68. `
  69. })
  70.  
  71. export class LoginComponent{
  72.  
  73. username: string;
  74. password: string;
  75.  
  76. anmelden(){
  77. console.log("USERNAME: " + this.username + " Password:" + this.password);
  78. }
  79.  
  80.  
  81. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement