@christianriedl/media 1.0.108 → 1.0.109
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -71,15 +71,20 @@
|
|
|
71
71
|
const video = item as IVideoFile;
|
|
72
72
|
const as = mediaService.splitAudioStreams(video.AudioStreams);
|
|
73
73
|
audioStreams.splice(0, audioStreams.length, ...as);
|
|
74
|
-
|
|
75
|
-
paramsText.value = params.text;
|
|
74
|
+
paramsText.value = `${video.Width}x${video.Height}, ${Math.floor(video.BitRate / 1000)} kbit/s`;
|
|
76
75
|
return;
|
|
77
76
|
}
|
|
78
77
|
}
|
|
79
78
|
function onQualityChange() {
|
|
80
79
|
const video = selected.value as IVideoFile;
|
|
81
|
-
|
|
82
|
-
|
|
80
|
+
if (quality.value > 0) {
|
|
81
|
+
params = mediaService.getTranscodeParams(true, video.Width, video.Height, window.innerWidth, quality.value);
|
|
82
|
+
paramsText.value = params.text;
|
|
83
|
+
}
|
|
84
|
+
else {
|
|
85
|
+
params = null;
|
|
86
|
+
paramsText.value = `${video.Width}x${video.Height}, ${Math.floor(video.BitRate / 1000)} kbit/s`;
|
|
87
|
+
}
|
|
83
88
|
}
|
|
84
89
|
function listBack() {
|
|
85
90
|
router.back();
|
|
@@ -91,6 +96,11 @@
|
|
|
91
96
|
items.splice(0, items.length, ...root.Files);
|
|
92
97
|
computeListHeight();
|
|
93
98
|
}
|
|
99
|
+
async function onShare(item: IVideoFile) {
|
|
100
|
+
const url = `https://www.christian-riedl.com/photos/video?media=${item.Url}&width=${item.Width}&height=${item.Height}&videobitrate=`;
|
|
101
|
+
await window.navigator.clipboard.writeText(url);
|
|
102
|
+
window.alert(`Created and Pasted : ${url} !`);
|
|
103
|
+
}
|
|
94
104
|
</script>
|
|
95
105
|
|
|
96
106
|
<template>
|
|
@@ -129,7 +139,10 @@
|
|
|
129
139
|
<v-card :max-height="listHeight" class="overflow-y-auto bg-media">
|
|
130
140
|
<v-list lines="two" class="bg-media">
|
|
131
141
|
<v-list-item-group v-model="itemIndex" color="primary">
|
|
132
|
-
<v-list-item v-for="item in items" :key="item.DLNAID" :title="item.title" :subtitle="item.subTitle"
|
|
142
|
+
<v-list-item v-for="item in items" :key="item.DLNAID" :title="item.title" :subtitle="item.subTitle" @click="listItem(item)">
|
|
143
|
+
<template v-if="item.Url" v-slot:append>
|
|
144
|
+
<v-btn color="grey" variant="tonal" icon="$share" @click.stop.prevent="onShare(item)"></v-btn>
|
|
145
|
+
</template>
|
|
133
146
|
</v-list-item>
|
|
134
147
|
</v-list-item-group>
|
|
135
148
|
</v-list>
|
package/src/views/VideosPage.vue
CHANGED
|
@@ -121,7 +121,7 @@
|
|
|
121
121
|
const video = item as IVideoFile;
|
|
122
122
|
const as = mediaService.splitAudioStreams(video.AudioStreams);
|
|
123
123
|
audioStreams.splice(0, audioStreams.length, ...as);
|
|
124
|
-
paramsText.value = `${video.Width}x${video.Height} ${Math.floor(video.
|
|
124
|
+
paramsText.value = `${video.Width}x${video.Height}, ${Math.floor(video.BitRate / 1000)} kbit/s`;
|
|
125
125
|
return;
|
|
126
126
|
}
|
|
127
127
|
const folder = item as IMediaFolder;
|
|
@@ -143,7 +143,7 @@
|
|
|
143
143
|
}
|
|
144
144
|
else {
|
|
145
145
|
params = null;
|
|
146
|
-
paramsText.value = `${video.Width}x${video.Height} ${Math.floor(video.
|
|
146
|
+
paramsText.value = `${video.Width}x${video.Height}, ${Math.floor(video.BitRate / 1000)} kbit/s`;
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
149
|
function listBack() {
|