From 97d2ff66a738bcf8818caeaf4a83bc56fc3b50e9 Mon Sep 17 00:00:00 2001 From: kj1352 Date: Tue, 16 Jun 2020 11:40:25 +0530 Subject: [PATCH] Add note slideup --- .../notes-details.component.html | 10 +- .../video-chapter.component.html | 39 +++++- .../video-chapter.component.scss | 118 ++++++++++++++++-- .../video-chapter/video-chapter.component.ts | 2 + 4 files changed, 147 insertions(+), 22 deletions(-) diff --git a/src/app/tabs/courses/notes-details/notes-details.component.html b/src/app/tabs/courses/notes-details/notes-details.component.html index 1742202..4509f90 100644 --- a/src/app/tabs/courses/notes-details/notes-details.component.html +++ b/src/app/tabs/courses/notes-details/notes-details.component.html @@ -13,16 +13,10 @@

- 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! + Transcript (2:00) : 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. + Thoughts : 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.

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 42cdfd7..df09091 100644 --- a/src/app/tabs/courses/video-chapter/video-chapter.component.html +++ b/src/app/tabs/courses/video-chapter/video-chapter.component.html @@ -63,6 +63,9 @@
  • +

    + 2:00 +

    quidem minima dolor delectus optio, dicta.

    @@ -73,6 +76,9 @@
  • +

    + 2:00 +

    quidem minima dolor delectus optio, dicta.

    @@ -83,17 +89,42 @@
  • +

    + 2:00 +

    quidem minima dolor delectus optio, dicta.

  • + + + + - - +
    Note
    + + + +

    + Transcript (2:00) +

    +

    + Lorem ipsum dolor sit amet, consectetur adipisicing elit. Quasi repellat voluptates inventore molestias quibusdam ex unde perferendis recusandae placeat itaque? Quos fuga suscipit temporibus. Aperiam ea dolor dolore doloremque voluptatem! +

    + + diff --git a/src/app/tabs/courses/video-chapter/video-chapter.component.scss b/src/app/tabs/courses/video-chapter/video-chapter.component.scss index 8eb8bf0..c4ac0d0 100644 --- a/src/app/tabs/courses/video-chapter/video-chapter.component.scss +++ b/src/app/tabs/courses/video-chapter/video-chapter.component.scss @@ -2,6 +2,7 @@ background-color: var(--black); height: 100vh; overflow: auto; + padding-bottom: 60px; } .nav-header { @@ -152,7 +153,6 @@ .notes-list { list-style: none; - padding-bottom: 60px; li { padding: 15px; @@ -189,27 +189,125 @@ transform: rotate(-45deg); } } +} + +.add-notes-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); + z-index: 0; + + .icon { + width: 20px; + height: 20px; + fill: var(--light-grey); + margin-right: 5px; + } +} - .add-notes-button { - position: fixed; - left: 0px; - bottom: 0px; +.add-note-slideup { + position: fixed; + bottom: 0; + z-index: 1; + left: 0; + background-color: var(--black); + width: 100%; + transform: translateY(100vh); + transition: transform 0.5s; + + &.active { + transform: translateY(calc(0vh + 190px)); + + &.expand { + transform: translateY(0); + + .add-thoughts { + display: none; + } + } + } + + header { + display: flex; + width: 100%; + height: 50px; background-color: var(--ash-black); + color: white; + align-items: center; + justify-content: space-between; + padding: 0 5%; + + h5 { + margin: 0; + font-weight: 400; + font-size: 16px; + flex-grow: 1; + text-align: center; + } + + button { + background-color: transparent; + border: 0px; + font-size: 16px; + color: var(--teal); + } + + .icon { + width: 15px; + height: 15px; + fill: var(--light-grey); + } + } + + p { color: var(--light-grey); + width: 90%; + margin: 20px auto; font-size: 14px; - width: 100%; - height: 50px; - border: 0px; + } + + .add-thoughts { + background-color: transparent; display: flex; align-items: center; justify-content: center; - box-shadow: 0px 0px 5px var(--black); + width: 100%; + border: 0px; + color: var(--light-grey); + height: 50px; + border: 0px; + font-size: 16px; + background-color: var(--black); + border-top: 1px solid var(--dark-grey); .icon { width: 20px; height: 20px; fill: var(--light-grey); - margin-right: 5px; + margin-right: 10px; } } + + textarea { + height: 150px; + color: var(--light-grey); + font-size: 14px; + background-color: transparent; + width: 100%; + display: block; + margin: 20px auto; + padding: 15px 5%; + border: 0px; + border-top: 1px solid var(--dark-grey); + } } diff --git a/src/app/tabs/courses/video-chapter/video-chapter.component.ts b/src/app/tabs/courses/video-chapter/video-chapter.component.ts index 8d7a46b..4768a74 100644 --- a/src/app/tabs/courses/video-chapter/video-chapter.component.ts +++ b/src/app/tabs/courses/video-chapter/video-chapter.component.ts @@ -12,6 +12,8 @@ export class VideoChapterComponent implements OnInit { selectedSegment: string = 'transcript'; heading: string; routeSubscription: Subscription; + showAddNote: boolean = false; + showAddThoughts: boolean = false; constructor( private route: ActivatedRoute,