Skip to content

ActivityPub-federated video streaming platform using P2P directly in your web browser

respect video history on explicit playlist click

Rigel Kent96f6278f3e5b
diff --git a/client/src/app/shared/video-playlist/video-playlist-element-miniature.component.ts b/client/src/app/shared/video-playlist/video-playlist-element-miniature.component.ts
index cd592eab08..bb2fe7da38 100644
--- a/client/src/app/shared/video-playlist/video-playlist-element-miniature.component.ts
+++ b/client/src/app/shared/video-playlist/video-playlist-element-miniature.component.ts
@@ -86,7 +86,8 @@ export class VideoPlaylistElementMiniatureComponent implements OnInit {
return {
videoId: this.playlistElement.video.uuid,
start: this.playlistElement.startTimestamp,
- stop: this.playlistElement.stopTimestamp
+ stop: this.playlistElement.stopTimestamp,
+ resume: true
}
}
diff --git a/client/src/app/videos/+video-watch/video-watch-playlist.component.html b/client/src/app/videos/+video-watch/video-watch-playlist.component.html
index a04081d35b..d43dcec933 100644
--- a/client/src/app/videos/+video-watch/video-watch-playlist.component.html
+++ b/client/src/app/videos/+video-watch/video-watch-playlist.component.html
@@ -29,7 +29,7 @@
iconName="repeat"
[class.active]="loopPlaylist"
(click)="switchLoopPlaylist()"
- [ngbTooltip]="'Loop playlist videos'"
+ [ngbTooltip]="loopPlaylistSwitchText"
placement="bottom auto"
container="body"
></my-global-icon>
diff --git a/client/src/app/videos/+video-watch/video-watch.component.ts b/client/src/app/videos/+video-watch/video-watch.component.ts
index 9eae45fed9..dbd75b35a5 100644
--- a/client/src/app/videos/+video-watch/video-watch.component.ts
+++ b/client/src/app/videos/+video-watch/video-watch.component.ts
@@ -619,7 +619,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
const { video, videoCaptions, urlOptions, user } = params
const getStartTime = () => {
const byUrl = urlOptions.startTime !== undefined
- const byHistory = video.userHistory && !this.playlist
+ const byHistory = video.userHistory && (!this.playlist || urlOptions.resume !== undefined)
if (byUrl) {
return timeToInt(urlOptions.startTime)
diff --git a/client/src/assets/player/bezels/bezels-plugin.ts b/client/src/assets/player/bezels/bezels-plugin.ts
index 4317d60f95..c2c2519617 100644
--- a/client/src/assets/player/bezels/bezels-plugin.ts
+++ b/client/src/assets/player/bezels/bezels-plugin.ts
@@ -43,7 +43,7 @@ class PauseBezel extends Component {
this.options_ = options
player.on('pause', (_: any) => {
- if (player.seeking()) return
+ if (player.seeking() || player.ended()) return
this.container.innerHTML = getPauseBezel()
this.showBezel()
})
diff --git a/client/src/assets/player/peertube-player-manager.ts b/client/src/assets/player/peertube-player-manager.ts
index ac3609c04c..27aa360e66 100644
--- a/client/src/assets/player/peertube-player-manager.ts
+++ b/client/src/assets/player/peertube-player-manager.ts
@@ -52,6 +52,7 @@ export interface CustomizationOptions {
muted?: boolean
loop?: boolean
subtitle?: string
+ resume?: string
peertubeLink: boolean
}
diff --git a/client/src/sass/application.scss b/client/src/sass/application.scss
index 463aeec5b9..751f101ed6 100644
--- a/client/src/sass/application.scss
+++ b/client/src/sass/application.scss
@@ -142,12 +142,12 @@ label {
@include disable-default-a-behaviour;
&.active, &.title-page-single {
- font-weight: $font-bold;
margin-top: 30px;
margin-bottom: 25px;
}
&.active {
+ font-weight: $font-bold;
border-bottom: 2px solid var(--mainColor);
}