diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts index 53c9d7f..e0ce77a 100644 --- a/src/app/app-routing.module.ts +++ b/src/app/app-routing.module.ts @@ -4,6 +4,7 @@ import { WelcomeComponent } from './welcome/welcome.component'; import { TabsComponent } from './tabs/tabs.component'; import { DetailsComponent } from './tabs/courses/details/details.component'; import { VideoChapterComponent } from './tabs/courses/video-chapter/video-chapter.component'; +import { NotesDetailsComponent } from './tabs/courses/notes-details/notes-details.component'; const routes: Routes = [ { path: '', pathMatch: 'full', redirectTo: 'welcome' }, @@ -12,7 +13,8 @@ const routes: Routes = [ { component: TabsComponent, path: 'tabs/:subpage' }, { component: DetailsComponent, path: 'course-details' }, { component: DetailsComponent, path: 'course-details/:heading' }, - { component: VideoChapterComponent, path: 'video-chapter/:heading' } + { component: VideoChapterComponent, path: 'video-chapter/:heading' }, + { component: NotesDetailsComponent, path: 'notes-details/:heading' } ]; @NgModule({ diff --git a/src/app/app.module.ts b/src/app/app.module.ts index 3cbcdd4..e97f1fa 100644 --- a/src/app/app.module.ts +++ b/src/app/app.module.ts @@ -13,6 +13,7 @@ import { ReportsComponent } from './tabs/reports/reports.component'; import { MoreComponent } from './tabs/more/more.component'; import { DetailsComponent } from './tabs/courses/details/details.component'; import { VideoChapterComponent } from './tabs/courses/video-chapter/video-chapter.component'; +import { NotesDetailsComponent } from './tabs/courses/notes-details/notes-details.component'; @NgModule({ declarations: [ @@ -25,6 +26,7 @@ import { VideoChapterComponent } from './tabs/courses/video-chapter/video-chapte MoreComponent, DetailsComponent, VideoChapterComponent, + NotesDetailsComponent, ], imports: [ BrowserModule, diff --git a/src/app/tabs/courses/notes-details/notes-details.component.html b/src/app/tabs/courses/notes-details/notes-details.component.html new file mode 100644 index 0000000..1742202 --- /dev/null +++ b/src/app/tabs/courses/notes-details/notes-details.component.html @@ -0,0 +1,30 @@ +
+ + +

{{ heading }}

+ +
+

+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Officiis quam sint recusandae ullam culpa enim, atque et? Doloremque sapiente odio, reprehenderit consectetur, suscipit repudiandae quis illum saepe itaque quisquam, maxime! +

+

+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Dolores ipsum dolorem quis omnis fuga, dolor expedita reprehenderit nemo maxime sequi voluptatum enim non, sint, repudiandae soluta cupiditate impedit odit rerum. +

+

+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ipsa eos explicabo soluta voluptatibus fugit expedita omnis optio tempore at iure odio aliquid, quibusdam, voluptas aspernatur harum libero sequi nam quidem. +

+

+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Veniam officiis iusto ipsa, adipisci porro ipsam. Repellendus itaque pariatur rem quia quisquam neque iure amet, deleniti, nesciunt veritatis, fugit ipsam magni. +

+
+ + +
diff --git a/src/app/tabs/courses/notes-details/notes-details.component.scss b/src/app/tabs/courses/notes-details/notes-details.component.scss new file mode 100644 index 0000000..783d0db --- /dev/null +++ b/src/app/tabs/courses/notes-details/notes-details.component.scss @@ -0,0 +1,89 @@ +.page { + background-color: var(--black); + height: 100vh; + padding-bottom: 60px; + overflow: auto; +} + +.nav-header { + background-color: var(--ash-black); + display: flex; + align-items: center; + padding: 0 5%; + height: 60px; + position: sticky; + position: -webkit-sticky; + top: 0; + z-index: 1; + + .close-button { + border: 0px; + background-color: transparent; + .icon { + width: 16px; + height: 16px; + fill: var(--light-grey); + } + } + + h5 { + font-size: 16px; + color: white; + font-weight: 400; + margin-left: 20px; + letter-spacing: 1px; + + .icon { + width: 15px; + height: 15px; + fill: white; + margin-right: 3px; + vertical-align: middle; + position: relative; + top: -1px; + } + } +} + +h2 { + padding: 0 5%; + font-size: 22px; + margin: 20px auto 10px; + color: white; + font-weight: 400; +} + +.description { + width: 90%; + margin: 0 auto; + color: white; + + p { + margin-bottom: 20px; + font-size: 14px; + line-height: 2; + } +} + +.next-button { + position: fixed; + left: 0px; + bottom: 0px; + background-color: var(--ash-black); + color: var(--light-grey); + font-size: 14px; + width: 100%; + height: 50px; + border: 0px; + display: flex; + align-items: center; + justify-content: center; + box-shadow: 0px 0px 5px var(--black); + + .icon { + width: 20px; + height: 20px; + fill: var(--light-grey); + margin-right: 5px; + } +} diff --git a/src/app/tabs/courses/notes-details/notes-details.component.spec.ts b/src/app/tabs/courses/notes-details/notes-details.component.spec.ts new file mode 100644 index 0000000..ea99b0c --- /dev/null +++ b/src/app/tabs/courses/notes-details/notes-details.component.spec.ts @@ -0,0 +1,25 @@ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { NotesDetailsComponent } from './notes-details.component'; + +describe('NotesDetailsComponent', () => { + let component: NotesDetailsComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ NotesDetailsComponent ] + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(NotesDetailsComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/src/app/tabs/courses/notes-details/notes-details.component.ts b/src/app/tabs/courses/notes-details/notes-details.component.ts new file mode 100644 index 0000000..c238d7d --- /dev/null +++ b/src/app/tabs/courses/notes-details/notes-details.component.ts @@ -0,0 +1,34 @@ +import { Component, OnInit } from '@angular/core'; +import { ActivatedRoute } from '@angular/router'; +import { Subscription } from 'rxjs'; +import { Location } from '@angular/common'; + +@Component({ + selector: 'app-notes-details', + templateUrl: './notes-details.component.html', + styleUrls: ['./notes-details.component.scss'] +}) +export class NotesDetailsComponent implements OnInit { + heading: string; + routeSubscription: Subscription; + + constructor( + private route: ActivatedRoute, + private location: Location + ) { } + + ngOnInit(): void { + this.routeSubscription = this.route.params.subscribe((params) => { + this.heading = params['heading']; + }); + } + + ngOnDestroy() { + this.routeSubscription.unsubscribe(); + } + + back() { + this.location.back(); + } + +} diff --git a/src/app/tabs/courses/video-chapter/video-chapter.component.html b/src/app/tabs/courses/video-chapter/video-chapter.component.html index b34291d..42cdfd7 100644 --- a/src/app/tabs/courses/video-chapter/video-chapter.component.html +++ b/src/app/tabs/courses/video-chapter/video-chapter.component.html @@ -60,7 +60,7 @@