diff --git a/Kyoo/ClientApp/src/app/app.component.ts b/Kyoo/ClientApp/src/app/app.component.ts index 3cf0e54d..e6041d56 100644 --- a/Kyoo/ClientApp/src/app/app.component.ts +++ b/Kyoo/ClientApp/src/app/app.component.ts @@ -4,52 +4,46 @@ import { Event, Router, NavigationStart, NavigationEnd, NavigationCancel, Naviga import * as $ from "jquery"; @Component({ - selector: 'app-root', - templateUrl: './app.component.html', - styleUrls: ['./app.component.scss'] + selector: 'app-root', + templateUrl: './app.component.html', + styleUrls: ['./app.component.scss'] }) export class AppComponent { - libraries: Library[]; - isLoading: boolean = false; + libraries: Library[]; + isLoading: boolean = false; - constructor(http: HttpClient, private router: Router) - { - http.get("api/libraries").subscribe(result => - { - this.libraries = result; - }, error => console.error(error)); + constructor(http: HttpClient, private router: Router) + { + http.get("api/libraries").subscribe(result => + { + this.libraries = result; + }, error => console.error(error)); - this.router.events.subscribe((event: Event) => - { - switch (true) - { - case event instanceof NavigationStart: - { - this.isLoading = true; - break; - } + this.router.events.subscribe((event: Event) => + { + switch (true) + { + case event instanceof NavigationStart: + this.isLoading = true; + break; - case event instanceof NavigationEnd: - case event instanceof NavigationCancel: - case event instanceof NavigationError: - { - this.isLoading = false; - break; - } - default: - { - this.isLoading = false; - break; - } - } - }); - } + case event instanceof NavigationEnd: + case event instanceof NavigationCancel: + case event instanceof NavigationError: + this.isLoading = false; + break; + default: + this.isLoading = false; + break; + } + }); + } } interface Library { - id: number; - slug: string; - name: string; + id: number; + slug: string; + name: string; } diff --git a/Kyoo/ClientApp/src/app/app.module.ts b/Kyoo/ClientApp/src/app/app.module.ts index 985bcbb7..7da5b16d 100644 --- a/Kyoo/ClientApp/src/app/app.module.ts +++ b/Kyoo/ClientApp/src/app/app.module.ts @@ -1,6 +1,7 @@ import { HttpClientModule } from '@angular/common/http'; import { NgModule } from '@angular/core'; import { MatButtonModule } from '@angular/material/button'; +import { MatRippleModule } from '@angular/material/core'; import { MatIconModule } from '@angular/material/icon'; import { MatMenuModule } from '@angular/material/menu'; import { MatProgressBarModule } from '@angular/material/progress-bar'; @@ -13,11 +14,11 @@ import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { AppRoutingModule } from './app-routing.module'; import { AppComponent } from './app.component'; import { BrowseComponent } from './browse/browse.component'; +import { CollectionComponent } from './collection/collection.component'; import { EpisodesListComponent } from './episodes-list/episodes-list.component'; import { NotFoundComponent } from './not-found/not-found.component'; import { PlayerComponent } from './player/player.component'; import { ShowDetailsComponent } from './show-details/show-details.component'; -import { CollectionComponent } from './collection/collection.component'; @NgModule({ @@ -42,7 +43,8 @@ import { CollectionComponent } from './collection/collection.component'; MatSelectModule, MatMenuModule, MatSliderModule, - MatTooltipModule + MatTooltipModule, + MatRippleModule ], providers: [], bootstrap: [AppComponent] diff --git a/Kyoo/ClientApp/src/app/browse/browse.component.html b/Kyoo/ClientApp/src/app/browse/browse.component.html index 9463805f..891f5109 100644 --- a/Kyoo/ClientApp/src/app/browse/browse.component.html +++ b/Kyoo/ClientApp/src/app/browse/browse.component.html @@ -22,7 +22,7 @@
- +

{{show.title}}

{{show.startYear}} - {{show.endYear}}

{{show.startYear}}

diff --git a/Kyoo/ClientApp/src/app/browse/browse.component.scss b/Kyoo/ClientApp/src/app/browse/browse.component.scss index 4d0d1e82..54c6ce9e 100644 --- a/Kyoo/ClientApp/src/app/browse/browse.component.scss +++ b/Kyoo/ClientApp/src/app/browse/browse.component.scss @@ -53,7 +53,7 @@ button &:focus, &:hover { - > img + > div { outline: solid var(--accentColor); } @@ -64,7 +64,7 @@ button } } - > img + > div { width: 100%; height: 0; diff --git a/Kyoo/ClientApp/src/app/episodes-list/episodes-list.component.html b/Kyoo/ClientApp/src/app/episodes-list/episodes-list.component.html index 11480529..61d44d5b 100644 --- a/Kyoo/ClientApp/src/app/episodes-list/episodes-list.component.html +++ b/Kyoo/ClientApp/src/app/episodes-list/episodes-list.component.html @@ -1,7 +1,7 @@
-
+
S{{episode.seasonNumber}}:E{{episode.episodeNumber}} - {{episode.title}}
diff --git a/Kyoo/ClientApp/src/app/player/player.component.ts b/Kyoo/ClientApp/src/app/player/player.component.ts index ac3bdca4..d6e5e980 100644 --- a/Kyoo/ClientApp/src/app/player/player.component.ts +++ b/Kyoo/ClientApp/src/app/player/player.component.ts @@ -202,17 +202,26 @@ export class PlayerComponent implements OnInit }, 1000); document.addEventListener("fullscreenchange", () => - { - if (document.fullscreenElement != null) - { - this.fullscreenIcon = "fullscreen_exit"; - this.fullscreenTooltip = "Exit fullscreen"; - } - else - { - this.fullscreenIcon = "fullscreen"; - this.fullscreenTooltip = "Fullscreen"; - } + { + if (navigator.userAgent.match(/Mobi/)) + { + if (document.fullscreenElement == null) + this.router.navigate(["/show/" + this.item.showSlug]); + } + else + { + if (document.fullscreenElement != null) + { + this.fullscreenIcon = "fullscreen_exit"; + this.fullscreenTooltip = "Exit fullscreen"; + } + else + { + this.fullscreenIcon = "fullscreen"; + this.fullscreenTooltip = "Fullscreen"; + } + } + }); $(window).keydown((e) => diff --git a/Kyoo/ClientApp/src/app/show-details/show-details.component.html b/Kyoo/ClientApp/src/app/show-details/show-details.component.html index 03febefb..c1db358e 100644 --- a/Kyoo/ClientApp/src/app/show-details/show-details.component.html +++ b/Kyoo/ClientApp/src/app/show-details/show-details.component.html @@ -81,7 +81,7 @@
- +
{{people.name}}

{{people.role}}

diff --git a/Kyoo/ClientApp/src/app/show-details/show-details.component.scss b/Kyoo/ClientApp/src/app/show-details/show-details.component.scss index 126b761e..ba3ada49 100644 --- a/Kyoo/ClientApp/src/app/show-details/show-details.component.scss +++ b/Kyoo/ClientApp/src/app/show-details/show-details.component.scss @@ -249,7 +249,7 @@ hr width: 10%; } - > img + > div { width: 100%; height: 0; diff --git a/Kyoo/ClientApp/src/index.html b/Kyoo/ClientApp/src/index.html index e8a13f0c..b0196e0c 100644 --- a/Kyoo/ClientApp/src/index.html +++ b/Kyoo/ClientApp/src/index.html @@ -6,6 +6,7 @@ + diff --git a/Kyoo/ClientApp/src/styles.scss b/Kyoo/ClientApp/src/styles.scss index 283cc9f4..bba28dc0 100644 --- a/Kyoo/ClientApp/src/styles.scss +++ b/Kyoo/ClientApp/src/styles.scss @@ -41,6 +41,10 @@ $theme: mat-dark-theme($primary, $accent); // Include the default theme styles. @include angular-material-theme($theme); +.mat-ripple-element +{ + background-color: rgba(255, 255, 255, .3) !important; +} //Material Icons @font-face {