@saooti/octopus-sdk 37.0.56 → 37.0.57
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 +1 -1
- package/src/components/misc/FooterSection.vue +3 -2
- package/src/components/mixins/imageProxy.ts +1 -1
- package/src/components/pages/EmissionPage.vue +2 -5
- package/src/components/pages/PlaylistPage.vue +2 -5
- package/src/components/pages/PodcastPage.vue +3 -2
- package/src/components/pages/RadioPage.vue +1 -1
- package/src/i18n.ts +3 -2
- package/src/main.ts +1 -1
package/package.json
CHANGED
|
@@ -66,6 +66,7 @@ import cookies from "../mixins/cookies";
|
|
|
66
66
|
import ClassicSelect from "../form/ClassicSelect.vue";
|
|
67
67
|
import AcpmImage from "./AcpmImage.vue";
|
|
68
68
|
import { state } from "../../stores/ParamSdkStore";
|
|
69
|
+
import { orgaComputed } from "../mixins/orgaComputed";
|
|
69
70
|
import { loadLocaleMessages } from "@/i18n";
|
|
70
71
|
import octopusApi from "@saooti/octopus-api";
|
|
71
72
|
import { useFilterStore } from "@/stores/FilterStore";
|
|
@@ -82,7 +83,7 @@ export default defineComponent({
|
|
|
82
83
|
AcpmImage,
|
|
83
84
|
},
|
|
84
85
|
|
|
85
|
-
mixins: [cookies],
|
|
86
|
+
mixins: [cookies, orgaComputed],
|
|
86
87
|
data() {
|
|
87
88
|
return {
|
|
88
89
|
language: this.$i18n.locale,
|
|
@@ -152,7 +153,7 @@ export default defineComponent({
|
|
|
152
153
|
},
|
|
153
154
|
changeLanguage(): void {
|
|
154
155
|
this.setCookie("octopus-language", this.language);
|
|
155
|
-
loadLocaleMessages(this.$i18n, this.language, this.platformEducation);
|
|
156
|
+
loadLocaleMessages(this.$i18n, this.language, this.authenticated, this.platformEducation);
|
|
156
157
|
octopusApi
|
|
157
158
|
.fetchDataWithParams<Array<Category>>(
|
|
158
159
|
0,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { state } from "../../stores/ParamSdkStore";
|
|
2
2
|
export default {
|
|
3
3
|
methods: {
|
|
4
|
-
proxyImageUrl(url: string, width: string, height?: string): string {
|
|
4
|
+
proxyImageUrl(url: string|undefined, width: string, height?: string): string {
|
|
5
5
|
if (!url) {
|
|
6
6
|
return "";
|
|
7
7
|
}
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
<div class="module-box">
|
|
12
12
|
<div class="mb-5 descriptionText">
|
|
13
13
|
<img
|
|
14
|
-
v-lazy="proxyImageUrl(imageUrl, '250')"
|
|
14
|
+
v-lazy="proxyImageUrl(emission.imageUrl, '250')"
|
|
15
15
|
width="250"
|
|
16
16
|
height="250"
|
|
17
17
|
:alt="$t('Emission name image', { name: name })"
|
|
@@ -158,9 +158,6 @@ export default defineComponent({
|
|
|
158
158
|
name(): string {
|
|
159
159
|
return this.emission?.name ?? "";
|
|
160
160
|
},
|
|
161
|
-
imageUrl(): string {
|
|
162
|
-
return this.emission ? `${this.emission.imageUrl}` : "";
|
|
163
|
-
},
|
|
164
161
|
description(): string {
|
|
165
162
|
return this.emission?.description ?? "";
|
|
166
163
|
},
|
|
@@ -196,7 +193,7 @@ export default defineComponent({
|
|
|
196
193
|
if (!this.emission) {
|
|
197
194
|
return "";
|
|
198
195
|
}
|
|
199
|
-
return `background-image: url('${this.emission.imageUrl}');`;
|
|
196
|
+
return `background-image: url('${this.proxyImageUrl(this.emission.imageUrl, '250')}');`;
|
|
200
197
|
},
|
|
201
198
|
},
|
|
202
199
|
watch: {
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
<div class="module-box">
|
|
12
12
|
<div class="mb-5 mt-3 descriptionText">
|
|
13
13
|
<img
|
|
14
|
-
v-lazy="proxyImageUrl(imageUrl, '250')"
|
|
14
|
+
v-lazy="proxyImageUrl(playlist.imageUrl, '250')"
|
|
15
15
|
width="250"
|
|
16
16
|
height="250"
|
|
17
17
|
:alt="$t('Playlist name image', { name: name })"
|
|
@@ -114,9 +114,6 @@ export default defineComponent({
|
|
|
114
114
|
name(): string {
|
|
115
115
|
return this.playlist?.title ?? "";
|
|
116
116
|
},
|
|
117
|
-
imageUrl(): string {
|
|
118
|
-
return this.playlist?.imageUrl ?? "";
|
|
119
|
-
},
|
|
120
117
|
description(): string {
|
|
121
118
|
return this.playlist?.description ?? "";
|
|
122
119
|
},
|
|
@@ -131,7 +128,7 @@ export default defineComponent({
|
|
|
131
128
|
if (!this.playlist) {
|
|
132
129
|
return "";
|
|
133
130
|
}
|
|
134
|
-
return `background-image: url('${this.playlist.imageUrl}');`;
|
|
131
|
+
return `background-image: url('${this.proxyImageUrl(this.playlist.imageUrl, '250')}');`;
|
|
135
132
|
},
|
|
136
133
|
},
|
|
137
134
|
watch: {
|
|
@@ -72,6 +72,7 @@
|
|
|
72
72
|
</template>
|
|
73
73
|
|
|
74
74
|
<script lang="ts">
|
|
75
|
+
import imageProxy from "../mixins/imageProxy";
|
|
75
76
|
import { orgaComputed } from "../mixins/orgaComputed";
|
|
76
77
|
import PodcastInlineList from "../display/podcasts/PodcastInlineList.vue";
|
|
77
78
|
import PodcastModuleBox from "../display/podcasts/PodcastModuleBox.vue";
|
|
@@ -117,7 +118,7 @@ export default defineComponent({
|
|
|
117
118
|
ClassicLoading,
|
|
118
119
|
},
|
|
119
120
|
|
|
120
|
-
mixins: [handle403, orgaComputed],
|
|
121
|
+
mixins: [handle403, orgaComputed, imageProxy],
|
|
121
122
|
|
|
122
123
|
props: {
|
|
123
124
|
updateStatus: { default: undefined, type: String },
|
|
@@ -145,7 +146,7 @@ export default defineComponent({
|
|
|
145
146
|
if (!this.podcast) {
|
|
146
147
|
return "";
|
|
147
148
|
}
|
|
148
|
-
return `background-image: url('${this.podcast.imageUrl}');`;
|
|
149
|
+
return `background-image: url('${this.proxyImageUrl(this.podcast.imageUrl, '270')}');`;
|
|
149
150
|
},
|
|
150
151
|
isPodcastmaker(): boolean {
|
|
151
152
|
return state.generalParameters.podcastmaker as boolean;
|
|
@@ -99,7 +99,7 @@ export default defineComponent({
|
|
|
99
99
|
backgroundDisplay(): string {
|
|
100
100
|
return !this.radio
|
|
101
101
|
? ""
|
|
102
|
-
: `background-image: url('${this.radio.imageUrl}');`;
|
|
102
|
+
: `background-image: url('${this.proxyImageUrl(this.radio.imageUrl, '270')}');`;
|
|
103
103
|
},
|
|
104
104
|
},
|
|
105
105
|
watch: {
|
package/src/i18n.ts
CHANGED
|
@@ -7,9 +7,9 @@ import "dayjs/locale/fr";
|
|
|
7
7
|
import "dayjs/locale/it";
|
|
8
8
|
import "dayjs/locale/sl";
|
|
9
9
|
|
|
10
|
-
export function setupI18n(options: { locale: string }, isEducation: boolean) {
|
|
10
|
+
export function setupI18n(options: { locale: string }, isAuthenticated: boolean, isEducation: boolean) {
|
|
11
11
|
const i18n = createI18n(options);
|
|
12
|
-
loadLocaleMessages(i18n.global, options.locale, isEducation);
|
|
12
|
+
loadLocaleMessages(i18n.global, options.locale, isAuthenticated, isEducation);
|
|
13
13
|
return i18n;
|
|
14
14
|
}
|
|
15
15
|
|
|
@@ -25,6 +25,7 @@ export function setI18nLanguage(i18n: any, locale: string) {
|
|
|
25
25
|
export async function loadLocaleMessages(
|
|
26
26
|
i18n: any,
|
|
27
27
|
locale: string,
|
|
28
|
+
isAuthenticated: boolean,
|
|
28
29
|
isEducation: boolean,
|
|
29
30
|
) {
|
|
30
31
|
if (
|