This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
h1 { | |
color: #838383; | |
margin-bottom: 50px; | |
} | |
.container { | |
align-items: center; | |
display: flex; | |
flex-direction: column; | |
justify-content: center; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="form-container"> | |
<h1>Welcome to NgBytes Login</h1> | |
<h5>Sign in with your email</h5> | |
<ngbytes-login-form (formData)="login($event)"></ngbytes-login-form> | |
</div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
button { | |
background-color: #5eccd6; | |
border-radius: 20px; | |
color: #fff; | |
padding: 0 50px; | |
} | |
form { | |
align-items: center; | |
display: flex; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form class="form" [formGroup]="form" (ngSubmit)="onSubmit()"> | |
<mat-form-field class="form-control"> | |
<mat-label>Email</mat-label> | |
<input matInput formControlName="email" type="text" required /> | |
<mat-error *ngIf="email?.hasError('required')"> | |
Email is required | |
</mat-error> | |
<mat-error *ngIf="email?.hasError('email')"> | |
Email isn't valid. Please enter a valid email. | |
</mat-error> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { AuthRoutingModule } from './auth-routing.module'; | |
import { CommonModule } from '@angular/common'; | |
import { LoginFormComponent } from './components/login-form/login-form.component'; | |
import { LoginPageComponent } from './pages/login-page/login-page.component'; | |
import { MatButtonModule } from '@angular/material/button'; | |
import { MatFormFieldModule } from '@angular/material/form-field'; | |
import { MatInputModule } from '@angular/material/input'; | |
import { NgModule } from '@angular/core'; | |
import { ReactiveFormsModule } from '@angular/forms'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Component, EventEmitter, OnInit, Output } from '@angular/core'; | |
import { FormBuilder, FormGroup, Validators } from '@angular/forms'; | |
@Component({ | |
selector: 'ngbytes-login-form', | |
templateUrl: './login-form.component.html', | |
styleUrls: ['./login-form.component.css'], | |
}) | |
export class LoginFormComponent implements OnInit { | |
@Output() formData: EventEmitter<{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { RouterModule, Routes } from '@angular/router'; | |
import { NgModule } from '@angular/core'; | |
const routes: Routes = [ | |
{ | |
path: '', | |
loadChildren: () => | |
import('./features/auth/auth.module').then((m) => m.AuthModule), | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { RouterModule, Routes } from '@angular/router'; | |
import { LoginPageComponent } from './pages/login-page/login-page.component'; | |
import { NgModule } from '@angular/core'; | |
const routes: Routes = [{ path: '', component: LoginPageComponent }]; | |
@NgModule({ | |
imports: [RouterModule.forChild(routes)], | |
exports: [RouterModule], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div cdkDropList class="todo-list" (cdkDropListDropped)="drop($event)"> | |
<h3>TO DO</h3> | |
<div class="awesome-todo" *ngFor="let todo of todos" cdkDrag>{{todo}}</div> | |
</div> | |
<div cdkDropList class="todo-list" (cdkDropListDropped)="drop($event)"> | |
<h3>IN PROGRESS</h3> | |
<div class="awesome-todo" *ngFor="let item of inProgress" cdkDrag>{{item}}</div> | |
</div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { CdkDragDrop, moveItemInArray } from '@angular/cdk/drag-drop'; | |
import { Component, OnInit } from '@angular/core'; | |
@Component({ | |
selector: 'app-todo-list', | |
templateUrl: './todo-list.component.html', | |
styleUrls: ['./todo-list.component.css'], | |
}) | |
export class TodoListComponent implements OnInit { | |
constructor() {} |