@saooti/octopus-sdk 39.0.46 → 39.0.48
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/index.ts +1 -1
- package/package.json +1 -1
- package/src/components/display/emission/EmissionPresentationItem.vue +69 -0
- package/src/components/display/emission/EmissionPresentationList.vue +160 -0
- package/src/components/display/list/SwiperList.vue +1 -1
- package/src/components/display/podcasts/PodcastModuleBox.vue +15 -12
- package/src/components/display/podcasts/PodcastRawTranscript.vue +158 -0
- package/src/components/display/podcasts/PodcastSwiperList.vue +4 -2
- package/src/components/display/sharing/SharePlayer.vue +11 -4
- package/src/components/display/sharing/SharePlayerTypes.vue +25 -14
- package/src/components/form/ClassicMultiselect.vue +8 -4
- package/src/components/misc/player/PlayerCompact.vue +3 -0
- package/src/components/misc/player/elements/PlayerPlayButton.vue +3 -1
- package/src/components/misc/player/elements/PlayerSpeedButton.vue +43 -0
- package/src/components/misc/player/video/PlayerVideoHls.vue +2 -2
- package/src/locale/de.ts +3 -0
- package/src/locale/en.ts +3 -0
- package/src/locale/es.ts +3 -0
- package/src/locale/fr.ts +3 -0
- package/src/locale/it.ts +3 -0
- package/src/locale/sl.ts +3 -0
package/index.ts
CHANGED
|
@@ -49,7 +49,7 @@ export const getCommentList = () => import("./src/components/display/comments/Co
|
|
|
49
49
|
export const getCommentInput = () => import("./src/components/display/comments/CommentInput.vue");
|
|
50
50
|
export const getPodcastPlaylistInlineList = () => import("./src/components/display/playlist/PodcastPlaylistInlineList.vue");
|
|
51
51
|
export const getLiveList = () => import("./src/components/display/live/LiveList.vue");
|
|
52
|
-
|
|
52
|
+
export const getEmissionPresentationList = () => import("./src/components/display/emission/EmissionPresentationList.vue");
|
|
53
53
|
|
|
54
54
|
//Radio
|
|
55
55
|
export const getRadioCurrently = () => import("./src/components/display/live/RadioCurrently.vue");
|
package/package.json
CHANGED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
class="emission-item-container emission-presentation-container mt-3"
|
|
4
|
+
:class="isVertical ? 'emission-vertical-item' : ''"
|
|
5
|
+
>
|
|
6
|
+
<router-link
|
|
7
|
+
:to="{
|
|
8
|
+
name: 'emission',
|
|
9
|
+
params: { emissionId: emission.emissionId },
|
|
10
|
+
query: { productor: filterOrgaId },
|
|
11
|
+
}"
|
|
12
|
+
:title="$t('Emission')"
|
|
13
|
+
class="d-flex-column flex-grow-1 text-dark"
|
|
14
|
+
:class="isVertical ? 'flex-column' : ''"
|
|
15
|
+
>
|
|
16
|
+
<img
|
|
17
|
+
v-lazy="proxyImageUrl(emission.imageUrl, isVertical ? '400' : '250')"
|
|
18
|
+
:width="isVertical ? '400' : '250'"
|
|
19
|
+
:height="isVertical ? '400' : '250'"
|
|
20
|
+
:class="isVertical ? 'img-box-bigger' : ''"
|
|
21
|
+
class="img-box"
|
|
22
|
+
:title="$t('Emission name image', { name: emission.name })"
|
|
23
|
+
:alt="$t('Emission name image', { name: emission.name })"
|
|
24
|
+
/>
|
|
25
|
+
<div class="emission-item-text">
|
|
26
|
+
<div class="d-flex align-items-center emission-name">
|
|
27
|
+
{{ emission.name }}
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|
|
30
|
+
</router-link>
|
|
31
|
+
</div>
|
|
32
|
+
</template>
|
|
33
|
+
|
|
34
|
+
<script lang="ts">
|
|
35
|
+
import { orgaComputed } from "../../mixins/orgaComputed";
|
|
36
|
+
import { Emission } from "@/stores/class/general/emission";
|
|
37
|
+
import imageProxy from "../../mixins/imageProxy";
|
|
38
|
+
import displayMethods from "../../mixins/displayMethods";
|
|
39
|
+
import { defineComponent } from "vue";
|
|
40
|
+
export default defineComponent({
|
|
41
|
+
name: "EmissionItem",
|
|
42
|
+
|
|
43
|
+
mixins: [displayMethods, orgaComputed, imageProxy],
|
|
44
|
+
|
|
45
|
+
props: {
|
|
46
|
+
emission: { default: () => ({}), type: Object as () => Emission },
|
|
47
|
+
isVertical: { default: false, type: Boolean },
|
|
48
|
+
},
|
|
49
|
+
});
|
|
50
|
+
</script>
|
|
51
|
+
<style lang="scss">
|
|
52
|
+
.octopus-app {
|
|
53
|
+
.emission-presentation-container {
|
|
54
|
+
@media (max-width: 960px) {
|
|
55
|
+
width: 250px !important;
|
|
56
|
+
margin-right: 0.5rem;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
.emission-item-container.emission-vertical-item {
|
|
60
|
+
flex-grow: 0;
|
|
61
|
+
width: 400px;
|
|
62
|
+
flex-shrink: 0;
|
|
63
|
+
}
|
|
64
|
+
.img-box-bigger {
|
|
65
|
+
width: 400px;
|
|
66
|
+
height: 400px;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
</style>
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="d-flex flex-column p-3">
|
|
3
|
+
<h2 class="mb-3">{{ title }}</h2>
|
|
4
|
+
<ClassicLoading
|
|
5
|
+
:loading-text="loading ? $t('Loading emissions ...') : undefined"
|
|
6
|
+
:error-text="error ? $t(`Error`) : undefined"
|
|
7
|
+
/>
|
|
8
|
+
<template v-if="!loading && !error">
|
|
9
|
+
<div class="d-flex flex-nowrap align-items-stretch overflow-phone-auto">
|
|
10
|
+
<EmissionItemPresentation
|
|
11
|
+
v-if="allEmissions[0]"
|
|
12
|
+
:class="!isPhone ? 'me-3' : ''"
|
|
13
|
+
:emission="allEmissions[0]"
|
|
14
|
+
:is-vertical="!isPhone"
|
|
15
|
+
/>
|
|
16
|
+
<div
|
|
17
|
+
v-if="allEmissions.length > 1"
|
|
18
|
+
class="emission-column emission-column-margin d-flex-row flex-nowrap"
|
|
19
|
+
>
|
|
20
|
+
<EmissionItemPresentation
|
|
21
|
+
v-if="allEmissions[1]"
|
|
22
|
+
:emission="allEmissions[1]"
|
|
23
|
+
/>
|
|
24
|
+
<EmissionItemPresentation
|
|
25
|
+
v-if="allEmissions[2]"
|
|
26
|
+
:emission="allEmissions[2]"
|
|
27
|
+
/>
|
|
28
|
+
</div>
|
|
29
|
+
<div
|
|
30
|
+
v-if="allEmissions.length > 3"
|
|
31
|
+
class="emission-column d-flex-row flex-nowrap show-emission-column"
|
|
32
|
+
>
|
|
33
|
+
<EmissionItemPresentation
|
|
34
|
+
v-if="allEmissions[3]"
|
|
35
|
+
:emission="allEmissions[3]"
|
|
36
|
+
/>
|
|
37
|
+
<EmissionItemPresentation
|
|
38
|
+
v-if="allEmissions[4]"
|
|
39
|
+
:emission="allEmissions[4]"
|
|
40
|
+
/>
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
<router-link
|
|
44
|
+
v-if="buttonText && href"
|
|
45
|
+
:to="href"
|
|
46
|
+
class="btn btn-primary align-self-center width-fit-content m-4"
|
|
47
|
+
>
|
|
48
|
+
{{ buttonText }}
|
|
49
|
+
</router-link>
|
|
50
|
+
</template>
|
|
51
|
+
</div>
|
|
52
|
+
</template>
|
|
53
|
+
|
|
54
|
+
<script lang="ts">
|
|
55
|
+
import octopusApi from "@saooti/octopus-api";
|
|
56
|
+
import { handle403 } from "../../mixins/handle403";
|
|
57
|
+
import ClassicLoading from "../../form/ClassicLoading.vue";
|
|
58
|
+
import { Emission } from "@/stores/class/general/emission";
|
|
59
|
+
import { defineAsyncComponent, defineComponent } from "vue";
|
|
60
|
+
import { AxiosError } from "axios";
|
|
61
|
+
import imageProxy from "../../mixins/imageProxy";
|
|
62
|
+
import resizePhone from "../../mixins/resizePhone";
|
|
63
|
+
const EmissionItemPresentation = defineAsyncComponent(
|
|
64
|
+
() => import("./EmissionPresentationItem.vue"),
|
|
65
|
+
);
|
|
66
|
+
export default defineComponent({
|
|
67
|
+
name: "EmissionPresentationList",
|
|
68
|
+
components: {
|
|
69
|
+
ClassicLoading,
|
|
70
|
+
EmissionItemPresentation,
|
|
71
|
+
},
|
|
72
|
+
|
|
73
|
+
mixins: [handle403, imageProxy, resizePhone],
|
|
74
|
+
|
|
75
|
+
props: {
|
|
76
|
+
organisationId: { default: undefined, type: String },
|
|
77
|
+
title: { default: "", type: String },
|
|
78
|
+
href: { default: undefined, type: String },
|
|
79
|
+
buttonText: { default: undefined, type: String },
|
|
80
|
+
},
|
|
81
|
+
data() {
|
|
82
|
+
return {
|
|
83
|
+
loading: true as boolean,
|
|
84
|
+
error: false as boolean,
|
|
85
|
+
allEmissions: [] as Array<Emission>,
|
|
86
|
+
isPhone: false as boolean,
|
|
87
|
+
windowWidth: 0 as number,
|
|
88
|
+
};
|
|
89
|
+
},
|
|
90
|
+
|
|
91
|
+
mounted() {
|
|
92
|
+
this.fetchNext();
|
|
93
|
+
},
|
|
94
|
+
methods: {
|
|
95
|
+
async fetchNext(): Promise<void> {
|
|
96
|
+
this.loading = true;
|
|
97
|
+
try {
|
|
98
|
+
const data = await octopusApi.fetchDataWithParams<{
|
|
99
|
+
count: number;
|
|
100
|
+
result: Array<Emission>;
|
|
101
|
+
sort: string;
|
|
102
|
+
}>(
|
|
103
|
+
0,
|
|
104
|
+
"emission/search",
|
|
105
|
+
{
|
|
106
|
+
first: 0,
|
|
107
|
+
size: 5,
|
|
108
|
+
organisationId: this.organisationId,
|
|
109
|
+
sort: "LAST_PODCAST_DESC",
|
|
110
|
+
},
|
|
111
|
+
true,
|
|
112
|
+
);
|
|
113
|
+
this.allEmissions = this.allEmissions.concat(
|
|
114
|
+
data.result.filter((em: Emission | null) => null !== em),
|
|
115
|
+
);
|
|
116
|
+
this.loading = false;
|
|
117
|
+
} catch (error) {
|
|
118
|
+
this.handle403(error as AxiosError);
|
|
119
|
+
this.error = true;
|
|
120
|
+
}
|
|
121
|
+
this.loading = false;
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
});
|
|
125
|
+
</script>
|
|
126
|
+
<style lang="scss">
|
|
127
|
+
.octopus-app {
|
|
128
|
+
.overflow-phone-auto {
|
|
129
|
+
@media (max-width: 960px) {
|
|
130
|
+
overflow-y: auto;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
.emission-column {
|
|
134
|
+
flex-shrink: 0;
|
|
135
|
+
width: calc((100% - 420px) / 2);
|
|
136
|
+
@media (max-width: 1550px) {
|
|
137
|
+
width: calc((100% - 420px));
|
|
138
|
+
}
|
|
139
|
+
@media (max-width: 960px) {
|
|
140
|
+
width: auto;
|
|
141
|
+
flex-direction: row !important;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
.emission-column-margin {
|
|
145
|
+
margin-right: 1rem;
|
|
146
|
+
@media (max-width: 960px) {
|
|
147
|
+
margin-right: 0;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
.show-emission-column {
|
|
151
|
+
display: flex;
|
|
152
|
+
@media (max-width: 1550px) {
|
|
153
|
+
display: none !important;
|
|
154
|
+
}
|
|
155
|
+
@media (max-width: 960px) {
|
|
156
|
+
display: flex !important;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
</style>
|
|
@@ -116,6 +116,19 @@
|
|
|
116
116
|
</div>
|
|
117
117
|
</div>
|
|
118
118
|
</div>
|
|
119
|
+
<TagList
|
|
120
|
+
v-if="undefined !== podcast.tags && 0 !== podcast.tags.length && !isPhone"
|
|
121
|
+
:tag-list="podcast.tags"
|
|
122
|
+
:podcast-annotations="podcast.annotations"
|
|
123
|
+
/>
|
|
124
|
+
<PodcastRawTranscript :podcast-id="podcast.podcastId" />
|
|
125
|
+
<SubscribeButtons
|
|
126
|
+
v-if="isPodcastmaker"
|
|
127
|
+
class="mt-4"
|
|
128
|
+
:emission="podcast.emission"
|
|
129
|
+
:window-width="1000"
|
|
130
|
+
:justify-center="false"
|
|
131
|
+
/>
|
|
119
132
|
<RecordingItemButton
|
|
120
133
|
v-if="!!fetchConference && isLiveReadyToRecord && isOctopusAndAnimator"
|
|
121
134
|
:podcast="podcast"
|
|
@@ -130,24 +143,13 @@
|
|
|
130
143
|
:display-studio-access="isDebriefing"
|
|
131
144
|
@validate-podcast="$emit('updatePodcast', $event)"
|
|
132
145
|
/>
|
|
133
|
-
<TagList
|
|
134
|
-
v-if="undefined !== podcast.tags && 0 !== podcast.tags.length && !isPhone"
|
|
135
|
-
:tag-list="podcast.tags"
|
|
136
|
-
:podcast-annotations="podcast.annotations"
|
|
137
|
-
/>
|
|
138
|
-
<SubscribeButtons
|
|
139
|
-
v-if="isPodcastmaker"
|
|
140
|
-
class="mt-4"
|
|
141
|
-
:emission="podcast.emission"
|
|
142
|
-
:window-width="1000"
|
|
143
|
-
:justify-center="false"
|
|
144
|
-
/>
|
|
145
146
|
</div>
|
|
146
147
|
</template>
|
|
147
148
|
|
|
148
149
|
<script lang="ts">
|
|
149
150
|
import PodcastImage from "./PodcastImage.vue";
|
|
150
151
|
import ParticipantDescription from "./ParticipantDescription.vue";
|
|
152
|
+
import PodcastRawTranscript from "./PodcastRawTranscript.vue";
|
|
151
153
|
import { state } from "../../../stores/ParamSdkStore";
|
|
152
154
|
import dayjs from "dayjs";
|
|
153
155
|
// @ts-ignore
|
|
@@ -188,6 +190,7 @@ export default defineComponent({
|
|
|
188
190
|
RecordingItemButton,
|
|
189
191
|
SubscribeButtons,
|
|
190
192
|
Countdown,
|
|
193
|
+
PodcastRawTranscript,
|
|
191
194
|
},
|
|
192
195
|
|
|
193
196
|
mixins: [displayMethods, orgaComputed, resizePhone],
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<button
|
|
4
|
+
class="btn btn-transcript"
|
|
5
|
+
:class="{ open: isOpen }"
|
|
6
|
+
@click="isOpen = !isOpen"
|
|
7
|
+
>
|
|
8
|
+
{{ buttonText }}
|
|
9
|
+
</button>
|
|
10
|
+
<div v-if="isOpen" class="transcription-body">
|
|
11
|
+
<ClassicLoading
|
|
12
|
+
:loading-text="!firstLoaded ? $t('Loading content ...') : undefined"
|
|
13
|
+
/>
|
|
14
|
+
<div class="transcription-text">
|
|
15
|
+
<template v-if="firstLoaded && transcript?.length">{{
|
|
16
|
+
transcript
|
|
17
|
+
}}</template>
|
|
18
|
+
<template v-if="firstLoaded && !transcript?.length">{{
|
|
19
|
+
$t("Transcript does not yet exist for this episode")
|
|
20
|
+
}}</template>
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
</template>
|
|
25
|
+
|
|
26
|
+
<script lang="ts">
|
|
27
|
+
import octopusApi from "@saooti/octopus-api";
|
|
28
|
+
import ClassicLoading from "../../form/ClassicLoading.vue";
|
|
29
|
+
import { defineComponent } from "vue";
|
|
30
|
+
export default defineComponent({
|
|
31
|
+
name: "PodcastRawTranscript",
|
|
32
|
+
|
|
33
|
+
components: {
|
|
34
|
+
ClassicLoading,
|
|
35
|
+
},
|
|
36
|
+
|
|
37
|
+
props: {
|
|
38
|
+
podcastId: { default: undefined, type: Number },
|
|
39
|
+
},
|
|
40
|
+
data() {
|
|
41
|
+
return {
|
|
42
|
+
isOpen: false as boolean,
|
|
43
|
+
firstLoaded: false as boolean,
|
|
44
|
+
transcript: undefined as string | undefined,
|
|
45
|
+
};
|
|
46
|
+
},
|
|
47
|
+
|
|
48
|
+
computed: {
|
|
49
|
+
buttonText() {
|
|
50
|
+
return this.isOpen
|
|
51
|
+
? this.$t("Hide transcript")
|
|
52
|
+
: this.$t("View transcript");
|
|
53
|
+
},
|
|
54
|
+
},
|
|
55
|
+
watch: {
|
|
56
|
+
async isOpen() {
|
|
57
|
+
if (this.isOpen && !this.firstLoaded) {
|
|
58
|
+
this.fetchTranscript();
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
},
|
|
62
|
+
methods: {
|
|
63
|
+
async fetchTranscript() {
|
|
64
|
+
if (!this.podcastId) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
try {
|
|
68
|
+
this.transcript = await octopusApi.fetchData(
|
|
69
|
+
11,
|
|
70
|
+
`transcription/text/${this.podcastId}`,
|
|
71
|
+
);
|
|
72
|
+
} catch {
|
|
73
|
+
//Do nothing
|
|
74
|
+
}
|
|
75
|
+
this.firstLoaded = true;
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
});
|
|
79
|
+
</script>
|
|
80
|
+
<style lang="scss">
|
|
81
|
+
@import "@scss/_variables.scss";
|
|
82
|
+
.octopus-app {
|
|
83
|
+
.btn-transcript {
|
|
84
|
+
position: relative;
|
|
85
|
+
border-radius: $octopus-borderradius;
|
|
86
|
+
overflow: hidden;
|
|
87
|
+
background: $octopus-secondary-color;
|
|
88
|
+
transition: all 0.2s linear 0s;
|
|
89
|
+
|
|
90
|
+
&:not(.open):before,
|
|
91
|
+
&.open:after {
|
|
92
|
+
content: "➤";
|
|
93
|
+
display: flex;
|
|
94
|
+
align-items: center;
|
|
95
|
+
justify-content: center;
|
|
96
|
+
position: absolute;
|
|
97
|
+
top: 0;
|
|
98
|
+
height: 100%;
|
|
99
|
+
width: 30px;
|
|
100
|
+
border-radius: 0 50% 50% 0;
|
|
101
|
+
background-color: rgba(#fff, 0.4);
|
|
102
|
+
transform: scale(0, 1);
|
|
103
|
+
transition: all 0.2s linear 0s;
|
|
104
|
+
}
|
|
105
|
+
&:not(.open):before {
|
|
106
|
+
left: 0px;
|
|
107
|
+
transform-origin: left center;
|
|
108
|
+
}
|
|
109
|
+
&.open:after {
|
|
110
|
+
right: -30px;
|
|
111
|
+
transform-origin: center left;
|
|
112
|
+
}
|
|
113
|
+
&.open {
|
|
114
|
+
direction: rtl;
|
|
115
|
+
}
|
|
116
|
+
&:hover {
|
|
117
|
+
text-indent: 30px;
|
|
118
|
+
}
|
|
119
|
+
&:not(.open):hover:before,
|
|
120
|
+
&.open:hover:after {
|
|
121
|
+
text-indent: 0;
|
|
122
|
+
}
|
|
123
|
+
&:not(.open):hover:before {
|
|
124
|
+
transform: scale(1, 1);
|
|
125
|
+
}
|
|
126
|
+
&.open:hover:after {
|
|
127
|
+
transform: scale(-1, 1);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
.transcription-body {
|
|
131
|
+
position: relative;
|
|
132
|
+
padding: 1rem;
|
|
133
|
+
max-height: 250px;
|
|
134
|
+
display: flex;
|
|
135
|
+
justify-content: center;
|
|
136
|
+
.transcription-text {
|
|
137
|
+
overflow-y: auto;
|
|
138
|
+
}
|
|
139
|
+
&::before {
|
|
140
|
+
content: "";
|
|
141
|
+
position: absolute;
|
|
142
|
+
inset: 0;
|
|
143
|
+
padding: 3px;
|
|
144
|
+
background: repeating-conic-gradient(
|
|
145
|
+
$octopus-secondary-color 0 25%,
|
|
146
|
+
$octopus-primary-color 0 50%
|
|
147
|
+
)
|
|
148
|
+
0 0/30px 30px round;
|
|
149
|
+
-webkit-mask:
|
|
150
|
+
linear-gradient(#000 0 0) content-box,
|
|
151
|
+
linear-gradient(#000 0 0);
|
|
152
|
+
-webkit-mask-composite: xor;
|
|
153
|
+
mask-composite: exclude;
|
|
154
|
+
pointer-events: none;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
</style>
|
|
@@ -138,7 +138,9 @@ export default defineComponent({
|
|
|
138
138
|
true,
|
|
139
139
|
);
|
|
140
140
|
this.loading = true;
|
|
141
|
-
this.allPodcasts = data.result.filter(
|
|
141
|
+
this.allPodcasts = data.result.filter(
|
|
142
|
+
(pod: Podcast | null) => null !== pod,
|
|
143
|
+
);
|
|
142
144
|
this.loading = false;
|
|
143
145
|
},
|
|
144
146
|
sortPopular(): void {
|
|
@@ -150,7 +152,7 @@ export default defineComponent({
|
|
|
150
152
|
if (!this.popularSort) return;
|
|
151
153
|
this.popularSort = false;
|
|
152
154
|
this.fetchNext();
|
|
153
|
-
}
|
|
155
|
+
},
|
|
154
156
|
},
|
|
155
157
|
});
|
|
156
158
|
</script>
|
|
@@ -166,7 +166,7 @@ export default defineComponent({
|
|
|
166
166
|
displayWaveParam(): boolean {
|
|
167
167
|
return "default" === this.iFrameModel || "emission" === this.iFrameModel;
|
|
168
168
|
},
|
|
169
|
-
choseNumberEpisodes():boolean{
|
|
169
|
+
choseNumberEpisodes(): boolean {
|
|
170
170
|
return this.displayChoiceAllEpisodes || this.isTypeSuggestion;
|
|
171
171
|
},
|
|
172
172
|
displayArticleParam(): boolean {
|
|
@@ -222,10 +222,17 @@ export default defineComponent({
|
|
|
222
222
|
return "emissionLarge" === this.iFrameModel;
|
|
223
223
|
},
|
|
224
224
|
isTypeSuggestion(): boolean {
|
|
225
|
-
return
|
|
225
|
+
return (
|
|
226
|
+
"largeSuggestion" === this.iFrameModel ||
|
|
227
|
+
"SUGGESTION" === this.typeCustomPlayer
|
|
228
|
+
);
|
|
226
229
|
},
|
|
227
|
-
isTypeEmission():boolean{
|
|
228
|
-
return
|
|
230
|
+
isTypeEmission(): boolean {
|
|
231
|
+
return (
|
|
232
|
+
this.isEmission ||
|
|
233
|
+
this.isLargeEmission ||
|
|
234
|
+
"EMISSION" === this.typeCustomPlayer
|
|
235
|
+
);
|
|
229
236
|
},
|
|
230
237
|
titleStillAvailable(): string {
|
|
231
238
|
return this.isPodcastNotVisible
|
|
@@ -120,24 +120,26 @@ export default defineComponent({
|
|
|
120
120
|
this.initCustomPlayers();
|
|
121
121
|
},
|
|
122
122
|
methods: {
|
|
123
|
-
isNumeric(value: string):boolean {
|
|
123
|
+
isNumeric(value: string): boolean {
|
|
124
124
|
return /^-?\d+$/.test(value);
|
|
125
125
|
},
|
|
126
|
-
selectChange($event: any){
|
|
126
|
+
selectChange($event: any) {
|
|
127
127
|
const val = $event.target.value;
|
|
128
|
-
if(!val){
|
|
128
|
+
if (!val) {
|
|
129
129
|
return;
|
|
130
130
|
}
|
|
131
|
-
if(this.isNumeric(val)){
|
|
132
|
-
var customPlayer = this.customPlayersDisplay.find((p) => {
|
|
133
|
-
|
|
131
|
+
if (this.isNumeric(val)) {
|
|
132
|
+
var customPlayer = this.customPlayersDisplay.find((p) => {
|
|
133
|
+
return p.customId.toString() === val;
|
|
134
|
+
});
|
|
135
|
+
if (customPlayer) {
|
|
134
136
|
this.selectCustomPlayer(customPlayer);
|
|
135
137
|
}
|
|
136
|
-
}else{
|
|
137
|
-
this.$emit(
|
|
138
|
+
} else {
|
|
139
|
+
this.$emit("update:iFrameModel", val);
|
|
138
140
|
}
|
|
139
141
|
},
|
|
140
|
-
async fetchPlayerPaginate(type: string): Promise<CustomPlayer[]>{
|
|
142
|
+
async fetchPlayerPaginate(type: string): Promise<CustomPlayer[]> {
|
|
141
143
|
let players = await octopusApi.fetchDataPublic<
|
|
142
144
|
InterfacePageable<CustomPlayer>
|
|
143
145
|
>(6, "customPlayer/type/" + this.organisationId + "/" + type);
|
|
@@ -161,11 +163,14 @@ export default defineComponent({
|
|
|
161
163
|
}
|
|
162
164
|
return playersContent;
|
|
163
165
|
},
|
|
164
|
-
selectCustomPlayer(customPlayer: CustomPlayer){
|
|
166
|
+
selectCustomPlayer(customPlayer: CustomPlayer) {
|
|
165
167
|
this.$emit("update:typeCustomPlayer", customPlayer.typePlayer);
|
|
166
|
-
this.$emit("update:iFrameModel",customPlayer.customId.toString());
|
|
168
|
+
this.$emit("update:iFrameModel", customPlayer.customId.toString());
|
|
167
169
|
},
|
|
168
|
-
async fetchCustomPlayers(
|
|
170
|
+
async fetchCustomPlayers(
|
|
171
|
+
type: string,
|
|
172
|
+
selectIfPossible = true,
|
|
173
|
+
): Promise<boolean> {
|
|
169
174
|
let customPlayersForType = await this.fetchPlayerPaginate(type);
|
|
170
175
|
this.customPlayers = this.customPlayers.concat(customPlayersForType);
|
|
171
176
|
if (
|
|
@@ -186,8 +191,14 @@ export default defineComponent({
|
|
|
186
191
|
this.fetchCustomPlayers("EMISSION");
|
|
187
192
|
} else {
|
|
188
193
|
const episodeSelected = await this.fetchCustomPlayers("EPISODE");
|
|
189
|
-
const emissionSelected = await this.fetchCustomPlayers(
|
|
190
|
-
|
|
194
|
+
const emissionSelected = await this.fetchCustomPlayers(
|
|
195
|
+
"EMISSION",
|
|
196
|
+
!episodeSelected,
|
|
197
|
+
);
|
|
198
|
+
await this.fetchCustomPlayers(
|
|
199
|
+
"SUGGESTION",
|
|
200
|
+
!episodeSelected && !emissionSelected,
|
|
201
|
+
);
|
|
191
202
|
}
|
|
192
203
|
},
|
|
193
204
|
},
|
|
@@ -20,7 +20,11 @@
|
|
|
20
20
|
:disabled="isDisabled"
|
|
21
21
|
:loading="isLoading"
|
|
22
22
|
:placeholder="placeholder"
|
|
23
|
-
:
|
|
23
|
+
:clear-search-on-blur="
|
|
24
|
+
() => {
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
"
|
|
24
28
|
:filter="fakeSearch"
|
|
25
29
|
:selectable="() => !maxOptionsSelected"
|
|
26
30
|
@open="onSearch"
|
|
@@ -101,7 +105,7 @@ export default {
|
|
|
101
105
|
remainingElements: 0 as number,
|
|
102
106
|
isLoading: false as boolean,
|
|
103
107
|
nbOptionsSelected: 0 as number,
|
|
104
|
-
searchInput: "" as string
|
|
108
|
+
searchInput: "" as string,
|
|
105
109
|
};
|
|
106
110
|
},
|
|
107
111
|
computed: {
|
|
@@ -141,13 +145,13 @@ export default {
|
|
|
141
145
|
onSearch(search?: string): void {
|
|
142
146
|
if (search && search.length < this.minSearchLength) {
|
|
143
147
|
return;
|
|
144
|
-
}else if(search){
|
|
148
|
+
} else if (search) {
|
|
145
149
|
this.searchInput = search;
|
|
146
150
|
}
|
|
147
151
|
this.isLoading = true;
|
|
148
152
|
this.$emit("onSearch", search);
|
|
149
153
|
},
|
|
150
|
-
onClose(){
|
|
154
|
+
onClose() {
|
|
151
155
|
this.$emit("onClose", this.searchInput);
|
|
152
156
|
this.searchInput = "";
|
|
153
157
|
},
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
/>
|
|
29
29
|
</div>
|
|
30
30
|
<!-- <AdsSkipButton/> -->
|
|
31
|
+
<PlayerSpeedButton />
|
|
31
32
|
<button
|
|
32
33
|
:title="'' != transcriptText ? $t('View transcript') : $t('Enlarge')"
|
|
33
34
|
class="btn play-button-box btn-transparent text-light saooti-up me-0"
|
|
@@ -55,6 +56,7 @@ import PlayerChaptering from "./chaptering/PlayerChaptering.vue";
|
|
|
55
56
|
/* import AdsSkipButton from "./ads/AdsSkipButton.vue"; */
|
|
56
57
|
import PlayerImage from "./elements/PlayerImage.vue";
|
|
57
58
|
import PlayerPlayButton from "./elements/PlayerPlayButton.vue";
|
|
59
|
+
import PlayerSpeedButton from "./elements/PlayerSpeedButton.vue";
|
|
58
60
|
import { defineAsyncComponent, defineComponent } from "vue";
|
|
59
61
|
const PlayerProgressBar = defineAsyncComponent(
|
|
60
62
|
() => import("./progressbar/PlayerProgressBar.vue"),
|
|
@@ -69,6 +71,7 @@ export default defineComponent({
|
|
|
69
71
|
PlayerImage,
|
|
70
72
|
PlayerPlayButton,
|
|
71
73
|
PlayerTitle,
|
|
74
|
+
PlayerSpeedButton,
|
|
72
75
|
/* AdsSkipButton */
|
|
73
76
|
},
|
|
74
77
|
mixins: [playerDisplayTime, imageProxy],
|
|
@@ -124,10 +124,12 @@ export default defineComponent({
|
|
|
124
124
|
justify-content: center;
|
|
125
125
|
margin: 0 0.5rem;
|
|
126
126
|
border-radius: 50% !important;
|
|
127
|
-
font-size: 1rem !important;
|
|
128
127
|
flex-shrink: 0;
|
|
129
128
|
cursor: pointer;
|
|
130
129
|
}
|
|
130
|
+
.play-button-box:not(.small-font) {
|
|
131
|
+
font-size: 1rem !important;
|
|
132
|
+
}
|
|
131
133
|
.play-big-button-box {
|
|
132
134
|
height: 5rem;
|
|
133
135
|
width: 5rem;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<button
|
|
3
|
+
:title="$t('Change speed')"
|
|
4
|
+
class="btn play-button-box small-font btn-transparent text-light me-0"
|
|
5
|
+
@click="changeSpeed"
|
|
6
|
+
>
|
|
7
|
+
{{ "×" + speedArray[speedIndex] }}
|
|
8
|
+
</button>
|
|
9
|
+
</template>
|
|
10
|
+
<script lang="ts">
|
|
11
|
+
import { defineComponent } from "vue";
|
|
12
|
+
export default defineComponent({
|
|
13
|
+
name: "PlayerSpeedButton",
|
|
14
|
+
|
|
15
|
+
data() {
|
|
16
|
+
return {
|
|
17
|
+
audioPlayer: null as HTMLAudioElement | null,
|
|
18
|
+
speedIndex: 2 as number,
|
|
19
|
+
speedArray: [0.5, 0.75, 1, 1.25, 1.5, 1.75],
|
|
20
|
+
};
|
|
21
|
+
},
|
|
22
|
+
mounted() {
|
|
23
|
+
this.audioPlayer = document.querySelector("#audio-player");
|
|
24
|
+
},
|
|
25
|
+
methods: {
|
|
26
|
+
changeSpeed() {
|
|
27
|
+
this.speedIndex += 1;
|
|
28
|
+
if (this.speedIndex > this.speedArray.length - 1) {
|
|
29
|
+
this.speedIndex = 0;
|
|
30
|
+
}
|
|
31
|
+
if (this.audioPlayer) {
|
|
32
|
+
this.audioPlayer.playbackRate = this.speedArray[this.speedIndex];
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
});
|
|
37
|
+
</script>
|
|
38
|
+
|
|
39
|
+
<style lang="scss">
|
|
40
|
+
@import "@scss/_variables.scss";
|
|
41
|
+
.octopus-app {
|
|
42
|
+
}
|
|
43
|
+
</style>
|
|
@@ -15,7 +15,7 @@ import { mapActions } from "pinia";
|
|
|
15
15
|
import { playerLogicProgress } from "../../../mixins/player/playerLogicProgress";
|
|
16
16
|
import videojs, { VideoJsPlayer } from "video.js";
|
|
17
17
|
import qualitySelectorHls from "videojs-quality-selector-hls";
|
|
18
|
-
if (undefined===videojs.getPlugin("qualitySelectorHls")) {
|
|
18
|
+
if (undefined === videojs.getPlugin("qualitySelectorHls")) {
|
|
19
19
|
videojs.registerPlugin("qualitySelectorHls", qualitySelectorHls);
|
|
20
20
|
}
|
|
21
21
|
import { defineComponent } from "vue";
|
|
@@ -104,7 +104,7 @@ export default defineComponent({
|
|
|
104
104
|
document.getElementById("video-element-hls") as Element,
|
|
105
105
|
this.videoOptions,
|
|
106
106
|
() => {
|
|
107
|
-
this.player.qualitySelectorHls(
|
|
107
|
+
this.player.qualitySelectorHls({ displayCurrentQuality: true });
|
|
108
108
|
/*console.log(this.player.tech(true).vhs.playlistController_); */
|
|
109
109
|
this.errorPlay = "";
|
|
110
110
|
this.playing = true;
|
package/src/locale/de.ts
CHANGED
|
@@ -363,4 +363,7 @@ export default {
|
|
|
363
363
|
"Afternoon":"Nachmittag",
|
|
364
364
|
"Evening":"Abend",
|
|
365
365
|
"Now":"Jetzt",
|
|
366
|
+
"Change speed":"Geschwindigkeit ändern",
|
|
367
|
+
"Hide transcript":"Transkript ausblenden",
|
|
368
|
+
"Transcript does not yet exist for this episode":"Für diese Episode existiert noch kein Transkript",
|
|
366
369
|
}
|
package/src/locale/en.ts
CHANGED
|
@@ -364,4 +364,7 @@ export default {
|
|
|
364
364
|
"Afternoon":"Afternoon",
|
|
365
365
|
"Evening":"Evening",
|
|
366
366
|
"Now":"Now",
|
|
367
|
+
"Change speed":"Change speed",
|
|
368
|
+
"Hide transcript":"Hide transcript",
|
|
369
|
+
"Transcript does not yet exist for this episode":"Transcript does not yet exist for this episode",
|
|
367
370
|
};
|
package/src/locale/es.ts
CHANGED
|
@@ -364,4 +364,7 @@ export default {
|
|
|
364
364
|
"Afternoon":"Tarde",
|
|
365
365
|
"Evening":"Noche",
|
|
366
366
|
"Now":"Ahora",
|
|
367
|
+
"Change speed":"Cambiar velocidad",
|
|
368
|
+
"Hide transcript":"Ocultar transcripción",
|
|
369
|
+
"Transcript does not yet exist for this episode":"La transcripción aún no existe para este episodio",
|
|
367
370
|
}
|
package/src/locale/fr.ts
CHANGED
|
@@ -371,4 +371,7 @@ export default {
|
|
|
371
371
|
"Afternoon":"Après-midi",
|
|
372
372
|
"Evening":"Soirée",
|
|
373
373
|
"Now":"Maintenant",
|
|
374
|
+
"Change speed":"Changer la vitesse",
|
|
375
|
+
"Hide transcript":"Cacher la transcription",
|
|
376
|
+
"Transcript does not yet exist for this episode":"La transcription n'existe pas encore pour cet épisode",
|
|
374
377
|
};
|
package/src/locale/it.ts
CHANGED
|
@@ -357,4 +357,7 @@ export default{
|
|
|
357
357
|
"Afternoon":"Pomeriggio",
|
|
358
358
|
"Evening":"Sera",
|
|
359
359
|
"Now":"Ora",
|
|
360
|
+
"Change speed":"Cambia velocità",
|
|
361
|
+
"Hide transcript":"Nascondi trascrizione",
|
|
362
|
+
"Transcript does not yet exist for this episode":"La trascrizione di questo episodio non esiste ancora",
|
|
360
363
|
};
|
package/src/locale/sl.ts
CHANGED
|
@@ -354,4 +354,7 @@ export default {
|
|
|
354
354
|
"Afternoon":"Popoldan",
|
|
355
355
|
"Evening":"Večer",
|
|
356
356
|
"Now":"Zdaj",
|
|
357
|
+
"Change speed":"Spremenite hitrost",
|
|
358
|
+
"Hide transcript":"Skrij prepis",
|
|
359
|
+
"Transcript does not yet exist for this episode":"Prepis za to epizodo še ne obstaja",
|
|
357
360
|
}
|