A self-hosted media server and file management system
Vue ffmpegfile-serverjellyfinlaravelmediamedia-playermedia-servermediabrowsermediaservermusicmusic-librarymusic-playermusicplayerself-hostedvuejs
fix: video card should show subtitle and codec
aminnausin1fade52a4776
diff --git a/package-lock.json b/package-lock.jsonindex 93dc646a..5bf1a9da 100755--- a/package-lock.json+++ b/package-lock.json@@ -75,7 +75,7 @@"tailwind-scrollbar-hide": "^4.0.0","tailwindcss": "^4.1.17","typescript": "~5.8.0",- "unplugin-icons": "^22.1.0",+ "unplugin-icons": "^23.0.1","vite": "^6.2.6","vite-plugin-compression": "^0.5.1","vitest": "^3.1.4",@@ -218,16 +218,6 @@"url": "https://github.com/sponsors/antfu"}},- "node_modules/@antfu/utils": {- "version": "9.3.0",- "resolved": "https://registry.npmjs.org/@antfu/utils/-/utils-9.3.0.tgz",- "integrity": "sha512-9hFT4RauhcUzqOE4f1+frMKLZrgNog5b06I7VmZQV1BkvwvqrbC8EBZf3L1eEL2AKb6rNKjER0sEvJiSP1FXEA==",- "dev": true,- "license": "MIT",- "funding": {- "url": "https://github.com/sponsors/antfu"- }- },"node_modules/@asamuzakjp/css-color": {"version": "3.2.0","resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz",@@ -1293,33 +1283,15 @@"license": "MIT"},"node_modules/@iconify/utils": {- "version": "3.0.2",- "resolved": "https://registry.npmjs.org/@iconify/utils/-/utils-3.0.2.tgz",- "integrity": "sha512-EfJS0rLfVuRuJRn4psJHtK2A9TqVnkxPpHY6lYHiB9+8eSuudsxbwMiavocG45ujOo6FJ+CIRlRnlOGinzkaGQ==",+ "version": "3.1.0",+ "resolved": "https://registry.npmjs.org/@iconify/utils/-/utils-3.1.0.tgz",+ "integrity": "sha512-Zlzem1ZXhI1iHeeERabLNzBHdOa4VhQbqAcOQaMKuTuyZCpwKbC2R4Dd0Zo3g9EAc+Y4fiarO8HIHRAth7+skw==","dev": true,"license": "MIT","dependencies": {"@antfu/install-pkg": "^1.1.0",- "@antfu/utils": "^9.2.0","@iconify/types": "^2.0.0",- "debug": "^4.4.1",- "globals": "^15.15.0",- "kolorist": "^1.8.0",- "local-pkg": "^1.1.1",- "mlly": "^1.7.4"- }- },- "node_modules/@iconify/utils/node_modules/globals": {- "version": "15.15.0",- "resolved": "https://registry.npmjs.org/globals/-/globals-15.15.0.tgz",- "integrity": "sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==",- "dev": true,- "license": "MIT",- "engines": {- "node": ">=18"- },- "funding": {- "url": "https://github.com/sponsors/sindresorhus"+ "mlly": "^1.8.0"}},"node_modules/@isaacs/cliui": {@@ -5840,13 +5812,6 @@"json-buffer": "3.0.1"}},- "node_modules/kolorist": {- "version": "1.8.0",- "resolved": "https://registry.npmjs.org/kolorist/-/kolorist-1.8.0.tgz",- "integrity": "sha512-Y+60/zizpJ3HRH8DCss+q95yr6145JXZo46OTpFvDZWLfRCE4qChOyk1b26nMaNpfHHgxagk9dXT5OP0Tfe+dQ==",- "dev": true,- "license": "MIT"- },"node_modules/laravel-echo": {"version": "1.19.0","resolved": "https://registry.npmjs.org/laravel-echo/-/laravel-echo-1.19.0.tgz",@@ -6515,6 +6480,17 @@"dev": true,"license": "MIT"},+ "node_modules/obug": {+ "version": "2.1.1",+ "resolved": "https://registry.npmjs.org/obug/-/obug-2.1.1.tgz",+ "integrity": "sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==",+ "dev": true,+ "funding": [+ "https://github.com/sponsors/sxzz",+ "https://opencollective.com/debug"+ ],+ "license": "MIT"+ },"node_modules/once": {"version": "1.4.0","resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",@@ -6614,9 +6590,9 @@"license": "BlueOak-1.0.0"},"node_modules/package-manager-detector": {- "version": "1.5.0",- "resolved": "https://registry.npmjs.org/package-manager-detector/-/package-manager-detector-1.5.0.tgz",- "integrity": "sha512-uBj69dVlYe/+wxj8JOpr97XfsxH/eumMt6HqjNTmJDf/6NO9s+0uxeOneIz3AsPt2m6y9PqzDzd3ATcU17MNfw==",+ "version": "1.6.0",+ "resolved": "https://registry.npmjs.org/package-manager-detector/-/package-manager-detector-1.6.0.tgz",+ "integrity": "sha512-61A5ThoTiDG/C8s8UMZwSorAGwMJ0ERVGj2OjoW5pAalsNOg15+iQiPzrLJ4jhZ1HJzmC2PIHT2oEiH3R5fzNA==","dev": true,"license": "MIT"},@@ -8569,9 +8545,9 @@}},"node_modules/ufo": {- "version": "1.6.1",- "resolved": "https://registry.npmjs.org/ufo/-/ufo-1.6.1.tgz",- "integrity": "sha512-9a4/uxlTWJ4+a5i0ooc1rU7C7YOw3wT+UGqdeNNHWnOF9qcMBgLRS+4IYUqbczewFx4mLEig6gawh7X6mFlEkA==",+ "version": "1.6.3",+ "resolved": "https://registry.npmjs.org/ufo/-/ufo-1.6.3.tgz",+ "integrity": "sha512-yDJTmhydvl5lJzBmy/hyOAA0d+aqCBuwl818haVdYCRrWV84o7YyeVm4QlVHStqNrrJSTb6jKuFAVqAFsr+K3Q==","dev": true,"license": "MIT"},@@ -8593,9 +8569,9 @@}},"node_modules/unplugin": {- "version": "2.3.10",- "resolved": "https://registry.npmjs.org/unplugin/-/unplugin-2.3.10.tgz",- "integrity": "sha512-6NCPkv1ClwH+/BGE9QeoTIl09nuiAt0gS28nn1PvYXsGKRwM2TCbFA2QiilmehPDTXIe684k4rZI1yl3A1PCUw==",+ "version": "2.3.11",+ "resolved": "https://registry.npmjs.org/unplugin/-/unplugin-2.3.11.tgz",+ "integrity": "sha512-5uKD0nqiYVzlmCRs01Fhs2BdkEgBS3SAVP6ndrBsuK42iC2+JHyxM05Rm9G8+5mkmRtzMZGY8Ct5+mliZxU/Ww==","dev": true,"license": "MIT","dependencies": {@@ -8609,17 +8585,17 @@}},"node_modules/unplugin-icons": {- "version": "22.5.0",- "resolved": "https://registry.npmjs.org/unplugin-icons/-/unplugin-icons-22.5.0.tgz",- "integrity": "sha512-MBlMtT5RuMYZy4TZgqUL2OTtOdTUVsS1Mhj6G1pEzMlFJlEnq6mhUfoIt45gBWxHcsOdXJDWLg3pRZ+YmvAVWQ==",+ "version": "23.0.1",+ "resolved": "https://registry.npmjs.org/unplugin-icons/-/unplugin-icons-23.0.1.tgz",+ "integrity": "sha512-rv0XEJepajKzDLvRUWASM8K+8+/CCfZn2jtogXqg6RIp7kpatRc/aFrVJn8ANQA09e++lPEEv9yX8cC9enc+QQ==","dev": true,"license": "MIT","dependencies": {"@antfu/install-pkg": "^1.1.0",- "@iconify/utils": "^3.0.2",- "debug": "^4.4.3",+ "@iconify/utils": "^3.1.0","local-pkg": "^1.1.2",- "unplugin": "^2.3.10"+ "obug": "^2.1.1",+ "unplugin": "^2.3.11"},"funding": {"url": "https://github.com/sponsors/antfu"@@ -8627,10 +8603,8 @@"peerDependencies": {"@svgr/core": ">=7.0.0","@svgx/core": "^1.0.1",- "@vue/compiler-sfc": "^3.0.2 || ^2.7.0",- "svelte": "^3.0.0 || ^4.0.0 || ^5.0.0",- "vue-template-compiler": "^2.6.12",- "vue-template-es2015-compiler": "^1.9.0"+ "@vue/compiler-sfc": "^3.0.2",+ "svelte": "^3.0.0 || ^4.0.0 || ^5.0.0"},"peerDependenciesMeta": {"@svgr/core": {@@ -8644,12 +8618,6 @@},"svelte": {"optional": true- },- "vue-template-compiler": {- "optional": true- },- "vue-template-es2015-compiler": {- "optional": true}}},diff --git a/package.json b/package.jsonindex 3a2b47c6..aea18316 100755--- a/package.json+++ b/package.json@@ -87,7 +87,7 @@"tailwind-scrollbar-hide": "^4.0.0","tailwindcss": "^4.1.17","typescript": "~5.8.0",- "unplugin-icons": "^22.1.0",+ "unplugin-icons": "^23.0.1","vite": "^6.2.6","vite-plugin-compression": "^0.5.1","vitest": "^3.1.4",diff --git a/resources/js/components/cards/data/VideoCard.vue b/resources/js/components/cards/data/VideoCard.vueindex 46779d20..a1d6504f 100644--- a/resources/js/components/cards/data/VideoCard.vue+++ b/resources/js/components/cards/data/VideoCard.vue@@ -12,6 +12,7 @@ import { RouterLink } from 'vue-router';import { HoverCard } from '@/components/cedar-ui/hover-card';import { MediaType } from '@/types/types';+import TablerSubtitles from '@/components/icons/TablerSubtitles.vue';import useMetaData from '@/composables/useMetaData';import MediaTag from '@/components/labels/MediaTag.vue';@@ -97,13 +98,25 @@ const contextMenuItems = computed(() => {</h3><HoverCardclass="-ms-2 hidden flex-1 items-end sm:block"- v-if="isAudio && videoData.metadata?.lyrics"+ v-if="videoData.metadata?.lyrics":content-title="'Has Lyrics'":hover-card-delay="400":hover-card-leave-delay="300"><template #trigger>- <TablerMicrophone2 class="size-5 shrink-0 opacity-100 transition-opacity duration-300 *:stroke-[1.4px] hover:opacity-20" title="Has Lyrics" v-if="isAudio" />+ <TablerMicrophone2 class="size-5 shrink-0 opacity-100 transition-opacity duration-300 *:stroke-[1.4px] hover:opacity-20" title="Has Lyrics" />+ </template>+ </HoverCard>++ <HoverCard+ class="-ms-2 hidden flex-1 items-end sm:block"+ v-if="videoData.subtitles.length > 0 && !isAudio"+ :content-title="'Has Subtitles'"+ :hover-card-delay="400"+ :hover-card-leave-delay="300"+ >+ <template #trigger>+ <TablerSubtitles class="size-5 shrink-0 opacity-100 transition-opacity duration-300 *:stroke-[1.4px] hover:opacity-20" title="Has Subtitles" /></template></HoverCard>diff --git a/resources/js/components/icons/TablerSubtitles.vue b/resources/js/components/icons/TablerSubtitles.vuenew file mode 100644index 00000000..0b814250--- /dev/null+++ b/resources/js/components/icons/TablerSubtitles.vue@@ -0,0 +1,12 @@+<template>+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">+ <path+ fill="none"+ stroke="currentColor"+ stroke-linecap="round"+ stroke-linejoin="round"+ stroke-width="2"+ d="M18 5a3 3 0 0 1 3 3v8a3 3 0 0 1-3 3H6a3 3 0 0 1-3-3V8a3 3 0 0 1 3-3zM7 15h5m3 0h2m0-3h-3m-3 0h-1"+ />+ </svg>+</template>diff --git a/resources/js/components/icons/TablerSubtitlesOff.vue b/resources/js/components/icons/TablerSubtitlesOff.vuenew file mode 100644index 00000000..8db251ba--- /dev/null+++ b/resources/js/components/icons/TablerSubtitlesOff.vue@@ -0,0 +1,5 @@+<template>+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">+ <path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5h9a3 3 0 0 1 3 3v8a3 3 0 0 1-.13.874m-2.006 2A3 3 0 0 1 18 19H6a3 3 0 0 1-3-3V8c0-1.35.893-2.493 2.12-2.869M7 15h5m5-3h-1m-4 0h-2M3 3l18 18" />+ </svg>+</template>diff --git a/resources/js/stores/ContentStore.ts b/resources/js/stores/ContentStore.tsindex 6fe473ff..16ffcbe2 100644--- a/resources/js/stores/ContentStore.ts+++ b/resources/js/stores/ContentStore.ts@@ -37,6 +37,7 @@ export const useContentStore = defineStore('Content', () => {const stateFilteredPlaylist = computed<VideoResource[]>(() => {if (!stateFolder.value?.videos) return [];+ // TODO: pre-generate this search string on load and on update per video instead of regenerating all videos on every changeconst searchTerm = searchQuery.value.toLowerCase().trim();const filteredResult = searchTerm? stateFolder.value.videos.filter((video) => {@@ -52,6 +53,7 @@ export const useContentStore = defineStore('Content', () => {toFormattedDuration(video.duration) ?? 'N/A',video.video_tags?.map((tag) => tag?.name).join(' ') ?? '',video.file_size ? formatFileSize(video.file_size) : '',+ video.metadata?.codec ?? '',video.album ?? '',video.artist ?? '',];