diff --git a/platypush/backend/http/webapp/src/components/panels/Media/Index.vue b/platypush/backend/http/webapp/src/components/panels/Media/Index.vue
index efebfa2b21..b2458cbce8 100644
--- a/platypush/backend/http/webapp/src/components/panels/Media/Index.vue
+++ b/platypush/backend/http/webapp/src/components/panels/Media/Index.vue
@@ -383,6 +383,8 @@ export default {
return await this.downloadTorrent(item, args)
case 'youtube':
return await this.downloadYoutube(item, args)
+ case 'jellyfin':
+ return await this.downloadUrl(item.url)
}
},
diff --git a/platypush/backend/http/webapp/src/components/panels/Media/Info.vue b/platypush/backend/http/webapp/src/components/panels/Media/Info.vue
index 6dd195fbce..ed02db99a2 100644
--- a/platypush/backend/http/webapp/src/components/panels/Media/Info.vue
+++ b/platypush/backend/http/webapp/src/components/panels/Media/Info.vue
@@ -131,7 +131,7 @@
-
-
+
diff --git a/platypush/backend/http/webapp/src/components/panels/Media/Item.vue b/platypush/backend/http/webapp/src/components/panels/Media/Item.vue
index 848c9c3750..44a6441b36 100644
--- a/platypush/backend/http/webapp/src/components/panels/Media/Item.vue
+++ b/platypush/backend/http/webapp/src/components/panels/Media/Item.vue
@@ -28,24 +28,10 @@
-
-
-
-
-
-
-
-
-
+
@@ -145,6 +131,88 @@ export default {
},
},
+ computed: {
+ actions() {
+ const actions = []
+
+ if (this.item.type !== 'torrent' && this.item.item_type !== 'photo') {
+ actions.push({
+ iconClass: 'fa fa-play',
+ text: 'Play',
+ action: () => this.$emit('play'),
+ })
+ }
+
+ if (this.item.type === 'youtube') {
+ actions.push({
+ iconClass: 'fa fa-play',
+ text: 'Play (With Cache)',
+ action: () => this.$emit('play-with-opts', {item: this.item, opts: {cache: true}}),
+ })
+ }
+
+ if (this.item.item_type === 'photo') {
+ actions.push({
+ iconClass: 'fa fa-eye',
+ text: 'View',
+ action: () => this.showPhoto = true,
+ })
+ }
+
+ if (this.item.type === 'file') {
+ actions.push({
+ iconClass: 'fa fa-window-maximize',
+ text: 'View in Browser',
+ action: () => this.$emit('view'),
+ })
+ }
+
+ if ((['torrent', 'youtube', 'jellyfin'].includes(this.item.type)) &&
+ this.item.item_type !== 'channel' &&
+ this.item.item_type !== 'playlist') {
+ actions.push({
+ iconClass: 'fa fa-download',
+ text: 'Download',
+ action: () => this.$emit('download'),
+ })
+ }
+
+ if (this.item.type === 'youtube' &&
+ this.item.item_type !== 'channel' &&
+ this.item.item_type !== 'playlist') {
+ actions.push({
+ iconClass: 'fa fa-volume-high',
+ text: 'Download Audio',
+ action: () => this.$emit('download-audio'),
+ })
+ }
+
+ if (this.item.type === 'youtube') {
+ actions.push({
+ iconClass: 'fa fa-list',
+ text: 'Add to Playlist',
+ action: () => this.$emit('add-to-playlist'),
+ })
+ }
+
+ if (this.item.type === 'youtube' && this.playlist?.length) {
+ actions.push({
+ iconClass: 'fa fa-trash',
+ text: 'Remove from Playlist',
+ action: () => this.$emit('remove-from-playlist'),
+ })
+ }
+
+ actions.push({
+ iconClass: 'fa fa-info-circle',
+ text: 'Info',
+ action: () => this.$emit('select'),
+ })
+
+ return actions
+ },
+ },
+
methods: {
onContextClick(e) {
if (this.item?.item_type === 'photo') {
diff --git a/platypush/backend/http/webapp/src/components/panels/Media/Providers/Jellyfin.vue b/platypush/backend/http/webapp/src/components/panels/Media/Providers/Jellyfin.vue
index 6c2507947d..cab6799abd 100644
--- a/platypush/backend/http/webapp/src/components/panels/Media/Providers/Jellyfin.vue
+++ b/platypush/backend/http/webapp/src/components/panels/Media/Providers/Jellyfin.vue
@@ -1,6 +1,6 @@