-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from sefatanam/3-user-should-be-able-to-make-p…
…rivate-playlist chore(UI): user interactive issue fixed
- Loading branch information
Showing
10 changed files
with
201 additions
and
111 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
90 changes: 60 additions & 30 deletions
90
src/app/components/mobile-menus/mobile-menus.component.html
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,74 @@ | ||
<div tabindex="0" class="menus-wrapper"> | ||
<ul class="mobile__menus" (click)="onMenuItemClick.emit()"> | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<h1 class="title animated-text ">Re.Tube</h1> | ||
</app-button> | ||
</li> | ||
<div class="pb-4"></div> | ||
@if (authService.authUser();as authUser) { | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<a routerLink="/personal" [queryParams]="{uid: authUser?.uid}">Personal</a> | ||
</app-button> | ||
</li> | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="w-6 h-6"> | ||
<path fill-rule="evenodd" | ||
d="M17.834 6.166a8.25 8.25 0 1 0 0 11.668.75.75 0 0 1 1.06 1.06c-3.807 3.808-9.98 3.808-13.788 0-3.808-3.807-3.808-9.98 0-13.788 3.807-3.808 9.98-3.808 13.788 0A9.722 9.722 0 0 1 21.75 12c0 .975-.296 1.887-.809 2.571-.514.685-1.28 1.179-2.191 1.179-.904 0-1.666-.487-2.18-1.164a5.25 5.25 0 1 1-.82-6.26V8.25a.75.75 0 0 1 1.5 0V12c0 .682.208 1.27.509 1.671.3.401.659.579.991.579.332 0 .69-.178.991-.579.3-.4.509-.99.509-1.671a8.222 8.222 0 0 0-2.416-5.834ZM15.75 12a3.75 3.75 0 1 0-7.5 0 3.75 3.75 0 0 0 7.5 0Z" | ||
clip-rule="evenodd" /> | ||
</svg> | ||
|
||
<a routerLink="/personal" [queryParams]="{uid: authUser?.uid}">Personal Playlist</a> | ||
</app-button> | ||
</li> | ||
} | ||
@for (item of menus.routeMenus;track $index) { | ||
@if(item.isAvailable){ | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<a [routerLink]="item.route">{{ item.name }}</a> | ||
</app-button> | ||
</li> | ||
} | ||
@if(item.isAvailable){ | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" | ||
class="w-6 h-6"> | ||
<path stroke-linecap="round" stroke-linejoin="round" | ||
d="M12.75 19.5v-.75a7.5 7.5 0 0 0-7.5-7.5H4.5m0-6.75h.75c7.87 0 14.25 6.38 14.25 14.25v.75M6 18.75a.75.75 0 1 1-1.5 0 .75.75 0 0 1 1.5 0Z" /> | ||
</svg> | ||
|
||
|
||
<a [routerLink]="item.route">{{ item.name }}</a> | ||
</app-button> | ||
</li> | ||
} | ||
} @empty { | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<a routerLink="#">No Permission's Menu 😕</a> | ||
</app-button> | ||
</li> | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<a routerLink="#">No Permission's Menu 😕</a> | ||
</app-button> | ||
</li> | ||
} | ||
</ul> | ||
|
||
<ul class="mobile__menus"> | ||
@if (!authService.authUser()) { | ||
@for (item of menus.routeButtons;track $index) { | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<a [routerLink]="item.route">{{ item.name }}</a> | ||
</app-button> | ||
</li> | ||
} | ||
@for (item of menus.routeButtons;track $index) { | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" | ||
class="w-6 h-6"> | ||
<path stroke-linecap="round" stroke-linejoin="round" | ||
d="M18 7.5v3m0 0v3m0-3h3m-3 0h-3m-2.25-4.125a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0ZM3 19.235v-.11a6.375 6.375 0 0 1 12.75 0v.109A12.318 12.318 0 0 1 9.374 21c-2.331 0-4.512-.645-6.374-1.766Z" /> | ||
</svg> | ||
<a [routerLink]="item.route">{{ item.name }}</a> | ||
</app-button> | ||
</li> | ||
} | ||
} @else if (authService.authUser()) { | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<a (click)="kickOut()">Log Out {{ authService.authUser()?.displayName }} </a> | ||
</app-button> | ||
</li> | ||
<li class="mobile__menus--item"> | ||
<app-button> | ||
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" | ||
class="w-6 h-6"> | ||
<path stroke-linecap="round" stroke-linejoin="round" | ||
d="M8.25 9V5.25A2.25 2.25 0 0 1 10.5 3h6a2.25 2.25 0 0 1 2.25 2.25v13.5A2.25 2.25 0 0 1 16.5 21h-6a2.25 2.25 0 0 1-2.25-2.25V15m-3 0-3-3m0 0 3-3m-3 3H15" /> | ||
</svg> | ||
|
||
<a (click)="kickOut()">Log Out</a> | ||
</app-button> | ||
</li> | ||
} | ||
</ul> | ||
</div> | ||
</div> |
22 changes: 15 additions & 7 deletions
22
src/app/components/mobile-menus/mobile-menus.component.scss
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,17 @@ | ||
.menus-wrapper{ | ||
@apply h-dvh flex flex-col justify-between; | ||
.menus-wrapper { | ||
@apply h-dvh flex flex-col justify-between py-8; | ||
} | ||
.mobile__menus{ | ||
@apply flex flex-col; | ||
&--item{ | ||
@apply flex items-center p-2; | ||
} | ||
.mobile__menus { | ||
@apply flex flex-col; | ||
&--item { | ||
@apply flex items-center p-2; | ||
} | ||
} | ||
|
||
.title { | ||
overflow-wrap: break-word; | ||
font-size: 1.875rem; | ||
line-height: 2.25rem; | ||
font-weight: 700; | ||
--tw-text-opacity: 1; | ||
} |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
@import "../../../styles/media.scss"; | ||
|
||
// Temporary | ||
|
||
.player-limited { | ||
@apply grid gap-4 row-start-2 mt-10; | ||
&-text { | ||
@apply text-xs italic; | ||
} | ||
&-title { | ||
@apply font-semibold; | ||
} | ||
form { | ||
@apply grid gap-2; | ||
} | ||
} | ||
|
||
@include for-web { | ||
.player-limited { | ||
@apply bg-greenish dark:bg-black rounded-xl p-4 w-2/3; | ||
form { | ||
button { | ||
@apply w-1/5; | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.