Compare commits

...

7 Commits

Author SHA1 Message Date
CodeDevMLH
e12a5b56a2 Update manifest.json for release v1.6.5.2 [skip ci] 2026-02-16 23:57:58 +00:00
CodeDevMLH
51ff0f2623 Bump version to 1.6.5.2
All checks were successful
Auto Release Plugin / build-and-release (push) Successful in 51s
2026-02-17 00:57:07 +01:00
CodeDevMLH
2c907debc8 Enhance video handling: release HTTP connections and manage lazy loading for trailers 2026-02-17 00:56:47 +01:00
CodeDevMLH
7b30f8c9e9 typos [skip ci] 2026-02-16 23:06:45 +01:00
CodeDevMLH
3a90605112 Update manifest.json for release v1.6.5.1 [skip ci] 2026-02-16 21:49:25 +00:00
CodeDevMLH
5772d670ff Bump version to 1.6.5.1
All checks were successful
Auto Release Plugin / build-and-release (push) Successful in 53s
2026-02-16 22:48:33 +01:00
CodeDevMLH
e558594c52 Enhance seasonal section layout and adjust input field width in configuration 2026-02-16 22:48:14 +01:00
4 changed files with 50 additions and 16 deletions

View File

@@ -146,7 +146,7 @@
Example:
<code>https://your-jellyfin-url/web/#/details?id=<b style="color:red;">your-item-id</b>&serverId=your-server-id</code><br><br>
You can also insert a name of a collection or playlist to fetch the IDs of all items in
it (will take the first hit.<br><b>Note:</b> there is currently no feedback if the name
it (will take the first hit.<br><b>Note:</b> There is currently no feedback if the name
resolution succeeded, you will have to look if the bar displays the correct items).
</p>
</div>
@@ -167,7 +167,7 @@
<div style="background-color: rgba(255, 255, 255, 0.05); border-left: 4px solid #00a4dc; border-radius: 4px; padding: 1em 1.5em; margin: 1.5em 0; display: flex; align-items: center; gap: 1em;">
<i class="material-icons" style="color: #00a4dc; font-size: 24px;">info</i>
<div>Define rules to automatically select a seasonal selection of items based on the date. Rules are evaluated from top to bottom. The first matching rule wins.</div>
<div>Define seasonal rules to automatically select a selection of items based on the date. Rules are evaluated from top to bottom. The first matching rule wins.</div>
</div>
<div id="seasonalSectionsList"></div>
@@ -627,7 +627,7 @@
' </div>' +
' </div>' +
' <div class="inputContainer">' +
' <input is="emby-input" type="text" class="emby-input section-name" value="' + (data.Name || '') + '" />' +
' <input is="emby-input" type="text" class="emby-input section-name" style="width: 60%;" value="' + (data.Name || '') + '" />' +
' <div class="fieldDescription">Name of the season</div>' +
' </div>' +
'</div>' +

View File

@@ -12,7 +12,7 @@
<!-- <TreatWarningsAsErrors>false</TreatWarningsAsErrors> -->
<Title>Jellyfin Media Bar Enhanced Plugin</Title>
<Authors>CodeDevMLH</Authors>
<Version>1.6.5.0</Version>
<Version>1.6.5.2</Version>
<RepositoryUrl>https://github.com/CodeDevMLH/jellyfin-plugin-media-bar-enhanced</RepositoryUrl>
</PropertyGroup>

View File

@@ -1853,11 +1853,12 @@ const SlideCreator = {
} else if (!isYoutube) {
isVideo = true;
const videoSrc = (typeof trailerUrl === 'object' ? trailerUrl.url : trailerUrl);
const videoAttributes = {
className: "backdrop video-backdrop",
src: (typeof trailerUrl === 'object' ? trailerUrl.url : trailerUrl),
preload: "auto",
preload: "none",
disablePictureInPicture: true,
"data-src": videoSrc,
style: "object-fit: cover; object-position: center center; width: 100%; height: 100%; position: absolute; top: 0; left: 0; pointer-events: none;"
};
@@ -2356,7 +2357,7 @@ const SlideshowManager = {
currentSlide.classList.add("active");
// Manage Video Playback: Stop others, Play current
// 1. Stop all other YouTube players and local video elements
// 1. Stop all other YouTube players and local video elements, release connections
if (STATE.slideshow.videoPlayers) {
Object.keys(STATE.slideshow.videoPlayers).forEach(id => {
if (id !== currentItemId) {
@@ -2366,11 +2367,17 @@ const SlideshowManager = {
if (typeof p.pauseVideo === 'function') {
p.pauseVideo();
}
// HTML5 <video> element (local trailers)
// HTML5 <video> element (local trailers), release HTTP connection
if (p instanceof HTMLVideoElement) {
p.pause();
p.muted = true;
p.currentTime = 0;
// Save src to data-src and release the HTTP streaming connection
if (p.src && !p.getAttribute('data-src')) {
p.setAttribute('data-src', p.src);
}
p.removeAttribute('src');
p.load();
}
}
});
@@ -2407,6 +2414,12 @@ const SlideshowManager = {
if (videoBackdrop) {
if (videoBackdrop.tagName === 'VIDEO') {
// Restore src from data-src if it was deactivated to release connections
const lazySrc = videoBackdrop.getAttribute('data-src');
if (lazySrc && !videoBackdrop.src) {
videoBackdrop.src = lazySrc;
}
videoBackdrop.currentTime = 0;
videoBackdrop.muted = STATE.slideshow.isMuted;
@@ -2605,7 +2618,7 @@ const SlideshowManager = {
*/
pruneSlideCache() {
const currentIndex = STATE.slideshow.currentSlideIndex;
const keepRange = 5;
const keepRange = CONFIG.preloadCount + 1;
let prunedAny = false;
Object.keys(STATE.slideshow.createdSlides).forEach((itemId) => {
@@ -2623,7 +2636,17 @@ const SlideshowManager = {
if (STATE.slideshow.videoPlayers[itemId]) {
const player = STATE.slideshow.videoPlayers[itemId];
if (typeof player.destroy === 'function') {
// YouTube player
player.destroy();
} else if (player instanceof HTMLVideoElement) {
// HTML5 video, release HTTP streaming connection
player.pause();
// Save src to data-src and release the HTTP streaming connection
if (player.src && !player.getAttribute('data-src')) {
player.setAttribute('data-src', player.src);
}
player.removeAttribute('src');
player.load();
}
delete STATE.slideshow.videoPlayers[itemId];
}
@@ -2802,7 +2825,7 @@ const SlideshowManager = {
});
}
// 2. Stop and mute all HTML5 videos
// 2. Stop and mute all HTML5 videos, release connections
const container = document.getElementById("slides-container");
if (container) {
container.querySelectorAll('video').forEach(video => {
@@ -2810,6 +2833,12 @@ const SlideshowManager = {
video.pause();
video.muted = true;
video.currentTime = 0;
// Save src and release HTTP streaming connection
if (video.src && !video.getAttribute('data-src')) {
video.setAttribute('data-src', video.src);
}
video.removeAttribute('src');
video.load();
} catch (e) {
console.warn("Error stopping HTML5 video:", e);
}
@@ -2842,9 +2871,14 @@ const SlideshowManager = {
return;
}
// HTML5 video: just resume, don't reset currentTime
// HTML5 video: restore src if needed, then resume
const html5Video = currentSlide.querySelector('video.video-backdrop');
if (html5Video) {
// Restore src from data-src if it was cleared to release connections
const lazySrc = html5Video.getAttribute('data-src');
if (lazySrc && !html5Video.src) {
html5Video.src = lazySrc;
}
html5Video.muted = STATE.slideshow.isMuted;
if (!STATE.slideshow.isMuted) html5Video.volume = 0.4;
html5Video.play().catch(e => console.warn("Error resuming HTML5 video:", e));

View File

@@ -9,12 +9,12 @@
"imageUrl": "https://git.mahom03-spacecloud.de/CodeDevMLH/jellyfin-plugin-media-bar-enhanced/raw/branch/main/logo.png",
"versions": [
{
"version": "1.6.5.0",
"version": "1.6.5.2",
"changelog": "- refactored seasonal UI settings",
"targetAbi": "10.11.0.0",
"sourceUrl": "https://git.mahom03-spacecloud.de/CodeDevMLH/jellyfin-plugin-media-bar-enhanced/releases/download/v1.6.5.0/Jellyfin.Plugin.MediaBarEnhanced.zip",
"checksum": "378a8465c281c315ed6ad0e683da4755",
"timestamp": "2026-02-16T18:38:40Z"
"sourceUrl": "https://git.mahom03-spacecloud.de/CodeDevMLH/jellyfin-plugin-media-bar-enhanced/releases/download/v1.6.5.2/Jellyfin.Plugin.MediaBarEnhanced.zip",
"checksum": "552cb3376c77ede5a0664ced56bf7d1e",
"timestamp": "2026-02-16T23:57:57Z"
},
{
"version": "1.6.4.1",