A self-hosted media server and file management system
Vue ffmpegfile-serverjellyfinlaravelmediamedia-playermedia-servermediabrowsermediaservermusicmusic-librarymusic-playermusicplayerself-hostedvuejs
Organise files and change some styling
aminnausina911193a9710
diff --git a/resources/js/components/cards/VideoCard.vue b/resources/js/components/cards/VideoCard.vueindex e34ca3f6..fe9dea0a 100644--- a/resources/js/components/cards/VideoCard.vue+++ b/resources/js/components/cards/VideoCard.vue@@ -15,7 +15,7 @@ const handlePlay = () => {<template><tr :class="{ 'ring-violet-600/50 ring': (props.currentID === props.video.id) }"- class="vid-row w-full rounded-md dark:bg-neutral-800 dark:hover:bg-indigo-900 bg-violet-100 hover:bg-violet-300 odd:bg-violet-200 hover:odd:bg-violet-300 dark:odd:bg-zinc-700 dark:hover:odd:bg-indigo-900 p-3 flex ring-inset flex-wrap flex-col sm:flex-row sm:flex-nowrap"+ class="shadow vid-row w-full rounded-md dark:bg-neutral-800 dark:hover:bg-indigo-900 bg-violet-100 hover:bg-violet-300 odd:bg-violet-200 hover:odd:bg-violet-300 dark:odd:bg-zinc-700 dark:hover:odd:bg-indigo-900 p-3 flex ring-inset flex-wrap flex-col sm:flex-row sm:flex-nowrap":data-id="props.video.id" :data-path="`../${props.video.attributes.path}`" @click="handlePlay"><td class="flex gap-12 w-full"><span class="vid-row-title xl:min-w-48 max-w-1/2 line-clamp-1">{{ props.video.attributes.name }}</span>diff --git a/resources/js/components/user/DropdownLink.vue b/resources/js/components/user/DropdownLink.vueindex a2b55523..88b70dc5 100644--- a/resources/js/components/user/DropdownLink.vue+++ b/resources/js/components/user/DropdownLink.vue@@ -5,12 +5,12 @@<template><a v-if="external":class="{ 'font-bold': selected}" :href="linkData.url"- class="rounded-t-md hover:bg-neutral-100 flex justify-between w-full px-4 py-2 text-sm leading-5 text-left"+ class="first:rounded-t-md hover:bg-neutral-100 dark:hover:bg-neutral-950 flex justify-between w-full px-4 py-2 text-sm leading-5 text-left"role="menuitem" target="_blank"> {{ linkData.text }}</a><RouterLink v-else:class="{ 'font-bold': selected}" :to="linkData.url"- class="rounded-t-md hover:bg-neutral-100 flex justify-between w-full px-4 py-2 text-sm leading-5 text-left"+ class="first:rounded-t-md hover:bg-neutral-100 dark:hover:bg-neutral-950 flex justify-between w-full px-4 py-2 text-sm leading-5 text-left"role="menuitem"> {{ linkData.text }}</RouterLink></template>\ No newline at end of filediff --git a/resources/js/components/user/UserDropdown.vue b/resources/js/components/user/UserDropdown.vueindex bd71d9d0..793bc7b0 100644--- a/resources/js/components/user/UserDropdown.vue+++ b/resources/js/components/user/UserDropdown.vue@@ -24,18 +24,18 @@</script><template>- <div role="menu" id="user_dropdown" aria-orientation="vertical" aria-labelledby="user_options" class="absolute left-0 z-30 mt-4 w-56 origin-top-right rounded-md shadow-lg ring-1 bg-white ring-black ring-opacity-5 focus:outline-none text-gray-700">+ <div role="menu" id="user_dropdown" aria-orientation="vertical" aria-labelledby="user_options" class="absolute left-0 z-30 mt-4 w-56 origin-top-right rounded-md shadow-lg ring-1 bg-white dark:bg-neutral-800 ring-black ring-opacity-5 focus:outline-none text-gray-700 dark:text-neutral-100"><div v-if="userData" class="divide-y divide-gray-300" role="menu" id="user-menu-auth">- <section class="flex flex-wrap gap-1 p-4 justify-between">- <p class="text-sm leading-5 text-orange-500">Logged in as: </p>- <p class="text-sm font-medium leading-5 text-gray-900 truncate">{{ userData.email }}</p>+ <section class="flex flex-col gap-1 p-4 justify-between">+ <p class="text-xs text-orange-500 dark:text-violet-400">Logged in as: </p>+ <p class="text-sm font-medium text-gray-900 dark:text-gray-300 truncate">{{ userData.email }}</p></section><section class="py-1"><DropdownLink v-for="(item, index) in dropDownItemsAuth" :key="index" :linkData="item" :selected="$route.name === item.name" :external="item?.external"/>- <span role="menuitem" tabindex="-1" class="flex justify-between w-full px-4 py-2 text-sm leading-5 text-left text-gray-700 cursor-not-allowed opacity-50" aria-disabled="true">New feature (soon)</span>+ <span role="menuitem" tabindex="-1" class="flex justify-between w-full px-4 py-2 text-sm leading-5 text-left text-gray-700 dark:text-neutral-400 cursor-not-allowed opacity-50" aria-disabled="true">New feature (soon)</span></section><section class="py-1">- <RouterLink class="text-gray-700 flex justify-between w-full px-4 py-2 text-sm leading-5 text-left" role="menuitem" to="/logout">Log out</RouterLink>+ <RouterLink class="flex justify-between w-full px-4 py-2 text-sm leading-5 text-left" role="menuitem" to="/logout">Log out</RouterLink></section></div><div v-else role="menu" id="user-menu-unauth" class="">diff --git a/resources/js/components/VideoPlayer.vue b/resources/js/components/video/VideoPlayer.vuesimilarity index 99%rename from resources/js/components/VideoPlayer.vuerename to resources/js/components/video/VideoPlayer.vueindex b61c8bd1..ca411d11 100644--- a/resources/js/components/VideoPlayer.vue+++ b/resources/js/components/video/VideoPlayer.vue@@ -1,6 +1,6 @@<script setup>import { storeToRefs } from 'pinia';-import { useContentStore } from '../stores/ContentStore';+import { useContentStore } from '../../stores/ContentStore';import { computed, ref, watch } from 'vue';const heatMapData = ref([{ x: 25, y: 60 }, { x: 154, y: 48 }, { x: 266, y: 12 }, { x: 585, y: 18 },{ x: 799, y: 16 }, { x: 1000, y: 100 }]);diff --git a/resources/js/components/VideoTable.vue b/resources/js/components/video/VideoTable.vuesimilarity index 92%rename from resources/js/components/VideoTable.vuerename to resources/js/components/video/VideoTable.vueindex 22010a6a..47909f6b 100644--- a/resources/js/components/VideoTable.vue+++ b/resources/js/components/video/VideoTable.vue@@ -1,11 +1,11 @@<script setup>-import VideoCard from './cards/VideoCard.vue';-import LabelledTextInput from './inputs/LabelledTextInput.vue';+import VideoCard from '../cards/VideoCard.vue';+import LabelledTextInput from '../inputs/LabelledTextInput.vue';-import { useContentStore } from '../stores/ContentStore';+import { useContentStore } from '../../stores/ContentStore';import { storeToRefs } from 'pinia';import { computed, ref } from 'vue';-import TablePagination from './table/TablePagination.vue';+import TablePagination from '../table/TablePagination.vue';const ContentStore = useContentStore();@@ -34,7 +34,7 @@ const tableColumnGroups = [</script><template>- <table class="w-full overflow-clip flex flex-col gap-2">+ <table class="w-full flex flex-col gap-2"><section class="folder-header flex justify-center sm:justify-between p-2"><!-- <h2 class="text-2xl py-4">Episodes</h2> --><LabelledTextInput v-model="searchQuery" :text="'Search'" class="w-80"/>diff --git a/resources/js/views/VideoView.vue b/resources/js/views/VideoView.vueindex a4d984be..3b7247f9 100644--- a/resources/js/views/VideoView.vue+++ b/resources/js/views/VideoView.vue@@ -1,8 +1,8 @@<script setup>import VideoSidebar from '../components/panels/VideoSidebar.vue';import LayoutBase from '../components/layout/LayoutBase.vue';- import VideoPlayer from '../components/VideoPlayer.vue';- import VideoTable from '../components/VideoTable.vue';+ import VideoPlayer from '../components/video/VideoPlayer.vue';+ import VideoTable from '../components/video/VideoTable.vue';import { ref, onMounted, watch } from 'vue';import { useContentStore } from '../stores/ContentStore';@@ -51,47 +51,24 @@<div class="p-6 w-full mx-auto dark:bg-primary-dark-800 bg-primary-800 rounded-xl shadow-lg flex justify-center sm:justify-between gap-4 flex-wrap sm:flex-nowrap overflow-hidden"><div id="mp4-description" class="hidden sm:flex items-center gap-4 md:w-2/3 ">- <div class="shrink-0">- <img id="folder-thumbnail" class="h-28 object-contain rounded-md" src="https://app.test:8080/storage/thumbnails/folders/5.jpg" onerror='this.onerror=null;this.src="https\:\/\/app.test:8080/storage/thumbnails/folders/5.jpg";' alt="Folder Cover Art">- </div>+ <img id="folder-thumbnail" class="h-28 object-contain rounded-md" src="https://app.test:8080/storage/thumbnails/folders/5.jpg" onerror='this.onerror=null;this.src="https\:\/\/app.test:8080/storage/thumbnails/folders/5.jpg";' alt="Folder Cover Art"><div class="h-full flex flex-col gap-2">- <div id="mp4-title" class="text-xl font-medium">{{ stateVideo?.attributes ? stateVideo.attributes.name : ''}}</div>+ <div id="mp4-title" class="text-xl font-medium line">{{ stateVideo?.attributes ? stateVideo.attributes.name : ''}}</div><p class="dark:text-slate-400 text-slate-400 line-clamp-3 text-sm">After defeating the Demon Lord, Himmel the Hero, priest Heiter, dwarf warrior Eisen, and elf mage Frieren return to the royal capital. After their procession, they view a meteor shower and discuss their future plans. Himmel, Heiter, and Eisen are ready to retire from adventuring after their ten-year quest. Frieren, whose lifespan is much longer, considers the ten years to be trivially short and plans to travel and learn new spells. To her colleagues' amusement, she promises to show them a better site to observe the meteor shower at its next occurrence in 50 years. Frieren keeps her word and returns 50 years later to find that Himmel and Heiter have become elderly, and Eisen is middle-aged. The week-long journey to Frieren's viewing site reminds the party of their past adventures. Himmel the Hero dies of old age shortly after the expedition. At his funeral, Frieren tearfully realizes she did not adequately get to know him and decides to learn as much about humans as possible. 20 years later, she visits Heiter to find that he has adopted a war orphan, nine year old Fern. Heiter, suffering from death anxiety in his advanced age, asks Frieren to research life-extending magic and tutor Fern in magic in her spare time. She agrees after seeing Fern is already remarkably skilled despite her youth.</p></div></div><div id="mp4-description-mobile" class="flex sm:hidden items-center gap-4 flex-col "><div id="mp4-title" class="text-xl font-medium w-full">{{ stateVideo?.attributes ? stateVideo.attributes.name : ''}}</div>- <div class="flex items-center gap-4 md:w-2/3">+ <div class="flex items-start gap-4 md:w-2/3"><img id="folder-thumbnail" class="h-28 object-contain rounded-md" src="https://app.test:8080/storage/thumbnails/folders/5.jpg" onerror='this.onerror=null;this.src="https\:\/\/app.test:8080/storage/thumbnails/folders/5.jpg";' alt="Folder Cover Art">- <div class="h-full flex flex-col gap-2">- <p class="dark:text-slate-400 text-slate-400 line-clamp-3 text-sm">After defeating the Demon Lord, Himmel the Hero, priest Heiter, dwarf warrior Eisen, and elf mage Frieren return to the royal capital. After their procession, they view a meteor shower and discuss their future plans. Himmel, Heiter, and Eisen are ready to retire from adventuring after their ten-year quest. Frieren, whose lifespan is much longer, considers the ten years to be trivially short and plans to travel and learn new spells. To her colleagues' amusement, she promises to show them a better site to observe the meteor shower at its next occurrence in 50 years. Frieren keeps her word and returns 50 years later to find that Himmel and Heiter have become elderly, and Eisen is middle-aged. The week-long journey to Frieren's viewing site reminds the party of their past adventures. Himmel the Hero dies of old age shortly after the expedition. At his funeral, Frieren tearfully realizes she did not adequately get to know him and decides to learn as much about humans as possible. 20 years later, she visits Heiter to find that he has adopted a war orphan, nine year old Fern. Heiter, suffering from death anxiety in his advanced age, asks Frieren to research life-extending magic and tutor Fern in magic in her spare time. She agrees after seeing Fern is already remarkably skilled despite her youth.</p>- </div>+ <p class="dark:text-slate-400 text-slate-400 line-clamp-3 text-sm">After defeating the Demon Lord, Himmel the Hero, priest Heiter, dwarf warrior Eisen, and elf mage Frieren return to the royal capital. After their procession, they view a meteor shower and discuss their future plans. Himmel, Heiter, and Eisen are ready to retire from adventuring after their ten-year quest. Frieren, whose lifespan is much longer, considers the ten years to be trivially short and plans to travel and learn new spells. To her colleagues' amusement, she promises to show them a better site to observe the meteor shower at its next occurrence in 50 years. Frieren keeps her word and returns 50 years later to find that Himmel and Heiter have become elderly, and Eisen is middle-aged. The week-long journey to Frieren's viewing site reminds the party of their past adventures. Himmel the Hero dies of old age shortly after the expedition. At his funeral, Frieren tearfully realizes she did not adequately get to know him and decides to learn as much about humans as possible. 20 years later, she visits Heiter to find that he has adopted a war orphan, nine year old Fern. Heiter, suffering from death anxiety in his advanced age, asks Frieren to research life-extending magic and tutor Fern in magic in her spare time. She agrees after seeing Fern is already remarkably skilled despite her youth.</p></div>-</div>- <div id="mp4-details" class="container flex sm:w-auto sm:flex-col justify-between sm:min-w-64 items-center sm:items-end gap-3 flex-wrap" role="group">+ <div id="mp4-details" class="container flex sm:w-auto sm:flex-col justify-between lg:min-w-32 items-center sm:items-end gap-3 flex-wrap" role="group"><section class="flex gap-2"><button class="p-2 bg-button-100 dark:bg-button-900 rounded-lg ring-violet-500 hover:ring-violet-800 hover:bg-violet-400/50 ring-[0.125rem] ring-inset">Edit Details</button><button class="p-2 bg-button-100 dark:bg-button-900 rounded-lg hover:ring-violet-500 hover:bg-violet-400/50 hover:ring-[0.125rem] ring-inset">s</button></section>- <section class="hidden">- <button type="button" class="bg-button-100 dark:bg-button-900 dark:text-white rounded-l-md border-r ring border-indigo-300 py-2 hover:bg-red-700 hover:text-white px-3 shadow-xl" @click="playlistSeek(-1)">- <div class="flex flex-row align-middle">- <svg class="w-5 mr-2" fill="currentColor" viewBox="0 0 20 20" xmlns="https://www.w3.org/2000/svg">- <path fill-rule="evenodd" d="M7.707 14.707a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414l4-4a1 1 0 011.414 1.414L5.414 9H17a1 1 0 110 2H5.414l2.293 2.293a1 1 0 010 1.414z" clip-rule="evenodd"></path>- </svg>- <p class="ml-2">Prev</p>- </div>- </button>- <button type="button" class="bg-button-100 dark:bg-button-900 dark:text-white rounded-r-md py-2 border-l ring border-indigo-300 hover:bg-red-700 hover:text-white px-3 shadow-xl" @click="playlistSeek(1)">- <div class="flex flex-row align-middle">- <span class="mr-2">Next</span>- <svg class="w-5 ml-2" fill="currentColor" viewBox="0 0 20 20" xmlns="https://www.w3.org/2000/svg">- <path fill-rule="evenodd" d="M12.293 5.293a1 1 0 011.414 0l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414-1.414L14.586 11H3a1 1 0 110-2h11.586l-2.293-2.293a1 1 0 010-1.414z" clip-rule="evenodd"></path>- </svg>- </div>- </button>- </section><section class="flex gap flex-col items-end text-sm text-slate-400 justify-between"><p>20 views</p><p class="line-clamp-1 truncate">#atmospheroc #sad #rocky</p>