preview file from storage path

This commit is contained in:
jb-alvarado 2023-10-30 23:04:37 +01:00
parent 50bee93c85
commit d00ffcabea
4 changed files with 464 additions and 820 deletions

1268
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
{
"name": "ffplayout-frontend",
"version": "0.4.2",
"version": "0.5.0",
"description": "Web GUI for ffplayout",
"author": "Jonathan Baecker",
"private": true,
@ -13,7 +13,7 @@
"postinstall": "nuxt prepare"
},
"dependencies": {
"@nuxt/types": "^2.17.1",
"@nuxt/types": "^2.17.2",
"@pinia/nuxt": "^0.5.1",
"@popperjs/core": "^2.11.8",
"@vueuse/core": "^10.5.0",
@ -26,9 +26,9 @@
"mpegts.js": "^1.7.3",
"pinia": "^2.1.7",
"sortablejs": "^1.15.0",
"sortablejs-vue3": "^1.2.9",
"sortablejs-vue3": "^1.2.10",
"splitpanes": "^3.1.5",
"video.js": "^8.6.0",
"video.js": "^8.6.1",
"vuedraggable": "^4.1.0"
},
"devDependencies": {
@ -37,13 +37,13 @@
"@types/lodash": "^4.14.200",
"@types/splitpanes": "^2.2.4",
"@types/video.js": "^7.3.55",
"eslint": "^8.51.0",
"eslint": "^8.52.0",
"eslint-plugin-nuxt": "^4.0.0",
"fibers": "^5.0.3",
"nuxt": "3.8.0",
"postcss": "^8.4.31",
"postcss-loader": "^7.3.3",
"sass": "^1.69.4",
"sass": "^1.69.5",
"sass-loader": "^13.3.2"
}
}

View File

@ -488,7 +488,7 @@ function setPreviewData(path: string) {
}
previewName.value = fullPath.split('/').slice(-1)[0]
previewUrl.value = encodeURIComponent(`${fullPath}`).replace(/%2F/g, '/')
previewUrl.value = encodeURIComponent(`/file/${configStore.configGui[configStore.configID].id}${fullPath}`).replace(/%2F/g, '/')
const ext = previewName.value.split('.').slice(-1)[0].toLowerCase()
const fileType = (mediaType(previewName.value) === 'audio') ? `audio/${ext}` : `video/${ext}`

View File

@ -987,7 +987,7 @@ function setPreviewData(path: string) {
}
previewName.value = fullPath.split('/').slice(-1)[0]
previewUrl.value = encodeURIComponent(`${fullPath}`).replace(/%2F/g, '/')
previewUrl.value = encodeURIComponent(`/file/${configStore.configGui[configStore.configID].id}${fullPath}`).replace(/%2F/g, '/')
const ext = previewName.value.split('.').slice(-1)[0].toLowerCase()