mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-06-22 06:50:33 -04:00
Renaming links to slugs
This commit is contained in:
parent
82dfe99c68
commit
0c966ed49e
@ -2,7 +2,7 @@
|
||||
<div class="episodes" #scrollView (scroll)="onScroll()">
|
||||
<div class="episode" *ngFor="let episode of this.episodes" #episodeDom >
|
||||
<button mat-icon-button class="moreBtn" [matMenuTriggerFor]="more" [matMenuTriggerData]="{episode: episode}"><i class="material-icons">more_vert</i></button>
|
||||
<a routerLink="/watch/{{episode.link}}" href="/watch/{{episode.link}}">
|
||||
<a routerLink="/watch/{{episode.slug}}" href="/watch/{{episode.slug}}">
|
||||
<div matRipple class="img" [style.background-image]="sanitize(episode.thumb)">
|
||||
<button mat-icon-button class="playBtn"><i class="material-icons playIcon">play_circle_outline</i></button>
|
||||
</div>
|
||||
|
@ -414,11 +414,11 @@ export class PlayerComponent implements OnInit
|
||||
|
||||
if (this.playMethod == method.direct)
|
||||
{
|
||||
this.player.src = "/video/" + this.item.link;
|
||||
this.player.src = "/video/" + this.item.slug;
|
||||
}
|
||||
else if (this.playMethod == method.transmux)
|
||||
{
|
||||
this.hlsPlayer.loadSource("/video/transmux/" + this.item.link + "/");
|
||||
this.hlsPlayer.loadSource("/video/transmux/" + this.item.slug + "/");
|
||||
this.hlsPlayer.attachMedia(this.player);
|
||||
this.hlsPlayer.on(Hls.Events.MANIFEST_LOADED, () =>
|
||||
{
|
||||
@ -427,7 +427,7 @@ export class PlayerComponent implements OnInit
|
||||
}
|
||||
else
|
||||
{
|
||||
this.hlsPlayer.loadSource("/video/transcode/" + this.item.link + "/");
|
||||
this.hlsPlayer.loadSource("/video/transcode/" + this.item.slug + "/");
|
||||
this.hlsPlayer.attachMedia(this.player);
|
||||
this.hlsPlayer.on(Hls.Events.MANIFEST_LOADED, () =>
|
||||
{
|
||||
@ -444,7 +444,7 @@ export class PlayerComponent implements OnInit
|
||||
next()
|
||||
{
|
||||
if (this.item.nextEpisode != null)
|
||||
this.router.navigate(["/watch/" + this.item.nextEpisode.link], { queryParamsHandling: "merge", replaceUrl: true });
|
||||
this.router.navigate(["/watch/" + this.item.nextEpisode.slug], { queryParamsHandling: "merge", replaceUrl: true });
|
||||
}
|
||||
|
||||
previous()
|
||||
|
@ -6,7 +6,7 @@ export interface Episode
|
||||
episodeNumber: number;
|
||||
title: string;
|
||||
thumb: string;
|
||||
link: string;
|
||||
slug: string;
|
||||
overview: string;
|
||||
releaseDate;
|
||||
runtime: number;
|
||||
|
@ -7,7 +7,7 @@ export interface WatchItem
|
||||
seasonNumber: number;
|
||||
episodeNumber: number;
|
||||
title: string;
|
||||
link: string;
|
||||
slug: string;
|
||||
duration: number;
|
||||
releaseDate;
|
||||
isMovie: boolean;
|
||||
|
Loading…
x
Reference in New Issue
Block a user