@saooti/octopus-sdk 36.0.5 → 36.0.6
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 -2
- package/package.json +3 -2
- package/src/assets/bootstrap.scss +11 -1
- package/src/components/display/categories/CategoryChooser.vue +79 -171
- package/src/components/display/categories/CategoryFilter.vue +10 -4
- package/src/components/display/emission/EmissionPlayerItem.vue +4 -1
- package/src/components/display/filter/CategorySearchFilter.vue +1 -1
- package/src/components/display/filter/ProductorSearch.vue +6 -16
- package/src/components/display/filter/RubriqueChoice.vue +1 -1
- package/src/components/display/filter/RubriqueFilter.vue +2 -1
- package/src/components/display/list/Paginate.vue +4 -1
- package/src/components/display/organisation/OrganisationChooser.vue +72 -200
- package/src/components/display/podcasts/PodcastFilterList.vue +5 -3
- package/src/components/display/podcasts/PodcastImage.vue +3 -1
- package/src/components/display/podcasts/PodcastModuleBox.vue +17 -5
- package/src/components/display/podcasts/TagList.vue +2 -2
- package/src/components/display/rubriques/RubriqueChooser.vue +87 -181
- package/src/components/display/rubriques/RubriqueList.vue +8 -5
- package/src/components/display/sharing/PlayerParameters.vue +3 -1
- package/src/components/display/sharing/ShareButtons.vue +5 -3
- package/src/components/display/sharing/ShareButtonsIntern.vue +24 -8
- package/src/components/display/sharing/ShareDistribution.vue +3 -1
- package/src/components/display/sharing/SharePlayer.vue +3 -1
- package/src/components/display/sharing/SharePlayerColors.vue +6 -2
- package/src/components/form/ClassicCheckbox.vue +1 -1
- package/src/components/form/ClassicMultiselect.vue +155 -0
- package/src/components/misc/TopBar.vue +8 -4
- package/src/components/misc/modal/NewsletterModal.vue +1 -1
- package/src/components/pages/Emission.vue +5 -2
- package/src/components/pages/Home.vue +3 -3
- package/src/components/pages/Playlist.vue +4 -1
- package/src/components/pages/Podcast.vue +4 -1
- package/src/stores/ParamSdkStore.ts +13 -13
- package/src/stores/class/general/organisation.ts +8 -0
- package/src/assets/multiselect.scss +0 -518
- package/src/components/display/emission/EmissionChooser.vue +0 -187
|
@@ -1,139 +1,87 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
:aria-expanded="false"
|
|
20
|
-
:placeholder="$t('Type string to filter by rubrics')"
|
|
21
|
-
:options="rubriques"
|
|
22
|
-
:multiple="multiple"
|
|
23
|
-
:searchable="true"
|
|
24
|
-
:loading="isLoading"
|
|
25
|
-
:internal-search="false"
|
|
26
|
-
:clear-on-select="false"
|
|
27
|
-
:close-on-select="true"
|
|
28
|
-
:options-limit="rubriqueLimit"
|
|
29
|
-
:max-height="600"
|
|
30
|
-
:show-no-results="true"
|
|
31
|
-
:hide-selected="true"
|
|
32
|
-
:show-labels="false"
|
|
33
|
-
@open="onOpen"
|
|
34
|
-
@search-change="onSearchRubrique"
|
|
35
|
-
@select="onRubriqueSelected"
|
|
36
|
-
>
|
|
37
|
-
<template #singleLabel="{ option }">
|
|
38
|
-
<div class="multiselect-octopus-proposition">
|
|
39
|
-
<span class="option__title">
|
|
40
|
-
{{ option.name }}
|
|
41
|
-
</span>
|
|
42
|
-
</div>
|
|
43
|
-
</template>
|
|
44
|
-
<template
|
|
45
|
-
#option="{ option }"
|
|
46
|
-
>
|
|
47
|
-
<div
|
|
48
|
-
v-if="undefined!==option"
|
|
49
|
-
class="multiselect-octopus-proposition"
|
|
50
|
-
:class="option.rubriqueId <= 0 ? 'text-primary' : ''"
|
|
51
|
-
:data-selenium="'rubric-chooser-' + seleniumFormat(option.name)"
|
|
52
|
-
>
|
|
53
|
-
<span class="option__title">{{ option.name }}</span>
|
|
54
|
-
</div>
|
|
55
|
-
</template>
|
|
56
|
-
<template #noOptions>
|
|
57
|
-
{{ $t('List is empty') }}
|
|
58
|
-
</template>
|
|
59
|
-
<template #noResult>
|
|
60
|
-
{{ $t('No elements found. Consider changing the search query.') }}
|
|
61
|
-
</template>
|
|
62
|
-
<template #caret>
|
|
63
|
-
<span class="saooti-down octopus-arrow-down-absolute" />
|
|
64
|
-
</template>
|
|
65
|
-
<template #afterList="">
|
|
66
|
-
<div
|
|
67
|
-
v-if="rubriques.length > rubriqueLimit"
|
|
68
|
-
class="multiselect-remaining-elements"
|
|
69
|
-
>
|
|
70
|
-
{{
|
|
71
|
-
$t(
|
|
72
|
-
'Count more elements matched your query, please make a more specific search.',
|
|
73
|
-
{ count: rubriques.length - rubriqueLimit }
|
|
74
|
-
)
|
|
75
|
-
}}
|
|
76
|
-
</div>
|
|
77
|
-
</template>
|
|
78
|
-
</VueMultiselect>
|
|
79
|
-
</div>
|
|
2
|
+
<ClassicMultiselect
|
|
3
|
+
:id="idClassicMultiselect"
|
|
4
|
+
ref="selectRubrique"
|
|
5
|
+
:option-chosen="model"
|
|
6
|
+
option-label="name"
|
|
7
|
+
:label="$t('By rubric')"
|
|
8
|
+
:placeholder="$t('Type string to filter by categories')"
|
|
9
|
+
:max-element="maxElement"
|
|
10
|
+
:multiple="multiple"
|
|
11
|
+
:min-search-length="1"
|
|
12
|
+
:width="width"
|
|
13
|
+
:in-modal="inModal"
|
|
14
|
+
:is-disabled="isDisabled"
|
|
15
|
+
:no-deselect="noDeselect"
|
|
16
|
+
@onSearch="onSearchRubrique"
|
|
17
|
+
@selected="onRubriqueSelected"
|
|
18
|
+
/>
|
|
80
19
|
</template>
|
|
81
20
|
|
|
82
21
|
<script lang="ts">
|
|
83
22
|
import selenium from '../../mixins/selenium';
|
|
84
|
-
//@ts-ignore
|
|
85
|
-
import VueMultiselect from 'vue-multiselect';
|
|
86
23
|
import { Rubrique } from '@/stores/class/rubrique/rubrique';
|
|
87
|
-
|
|
88
|
-
if ('' === defaultName){
|
|
89
|
-
return undefined;
|
|
90
|
-
}
|
|
91
|
-
return { name: defaultName, rubriqueId: 0 } as Rubrique;
|
|
92
|
-
};
|
|
93
|
-
|
|
24
|
+
import ClassicMultiselect from '../../form/ClassicMultiselect.vue';
|
|
94
25
|
import { defineComponent } from 'vue'
|
|
95
26
|
export default defineComponent({
|
|
96
27
|
components: {
|
|
97
|
-
|
|
28
|
+
ClassicMultiselect,
|
|
98
29
|
},
|
|
99
30
|
mixins:[selenium],
|
|
100
31
|
props: {
|
|
101
|
-
width: { default: '100%', type: String },
|
|
102
32
|
defaultanswer: { default: '', type: String },
|
|
103
|
-
|
|
33
|
+
width: { default: '100%', type: String },
|
|
104
34
|
multiple: { default: false, type: Boolean },
|
|
105
|
-
rubriqueArray: { default: undefined, type: Object as ()=>Array<number> },
|
|
106
|
-
rubriquageId: { default: undefined, type: Number },
|
|
107
|
-
allRubriques: { default: () => [], type: Array as ()=> Array<Rubrique> },
|
|
108
35
|
reset: { default: false, type: Boolean },
|
|
36
|
+
allRubriques: { default: () => [], type: Array as ()=> Array<Rubrique> },
|
|
37
|
+
rubriqueSelected: { default: undefined, type: Number },
|
|
38
|
+
rubriqueSelectedArray: { default: undefined, type: Object as ()=>Array<number> },
|
|
39
|
+
rubriquageId: { default: undefined, type: Number },
|
|
109
40
|
withoutRubrique: { default: false, type: Boolean },
|
|
110
41
|
isDisabled: { default: false, type: Boolean },
|
|
111
|
-
|
|
42
|
+
noDeselect: {default: false, type: Boolean},
|
|
43
|
+
inModal:{default: false, type: Boolean},
|
|
112
44
|
},
|
|
113
|
-
emits: ['update:rubriqueSelected', 'selected'],
|
|
45
|
+
emits: ['update:rubriqueSelected', 'update:rubriqueSelectedArray', 'selected'],
|
|
114
46
|
|
|
115
47
|
data() {
|
|
116
48
|
return {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
rubriqueForArray: [] as Array<Rubrique>,
|
|
121
|
-
isLoading: false as boolean,
|
|
49
|
+
maxElement: 250 as number,
|
|
50
|
+
rubrique: undefined as Rubrique|undefined,
|
|
51
|
+
rubriqueForArray: [] as Array<Rubrique>|undefined,
|
|
122
52
|
withoutItem: { name: this.$t('Without rubric'), rubriqueId: -1 } as {name: string, rubriqueId:number},
|
|
123
53
|
};
|
|
124
54
|
},
|
|
125
55
|
computed: {
|
|
126
|
-
|
|
56
|
+
idClassicMultiselect(): string {
|
|
127
57
|
return this.rubriquageId? 'rubriqueChooser' + this.rubriquageId : 'rubriqueChooser';
|
|
128
58
|
},
|
|
59
|
+
getDefaultRubrique(): Rubrique|undefined{
|
|
60
|
+
if(''===this.defaultanswer){
|
|
61
|
+
return undefined;
|
|
62
|
+
}
|
|
63
|
+
return { name: this.defaultanswer, rubriqueId: 0 };
|
|
64
|
+
},
|
|
65
|
+
rubriques(): Array<Rubrique>{
|
|
66
|
+
let rubriques = this.allRubriques;
|
|
67
|
+
if (!this.getDefaultRubrique) {
|
|
68
|
+
return rubriques;
|
|
69
|
+
}
|
|
70
|
+
if (this.withoutRubrique) {
|
|
71
|
+
rubriques.unshift(this.withoutItem);
|
|
72
|
+
}
|
|
73
|
+
rubriques.unshift(this.getDefaultRubrique);
|
|
74
|
+
|
|
75
|
+
return rubriques;
|
|
76
|
+
},
|
|
129
77
|
model: {
|
|
130
78
|
get(): Rubrique| Array<Rubrique>|undefined{
|
|
131
|
-
return
|
|
79
|
+
return !this.multiple ? this.rubrique:this.rubriqueForArray;
|
|
132
80
|
},
|
|
133
81
|
set(value: Rubrique| Array<Rubrique>|undefined): void{
|
|
134
|
-
if(
|
|
82
|
+
if(!this.multiple){
|
|
135
83
|
this.rubrique = (value as Rubrique|undefined);
|
|
136
|
-
return
|
|
84
|
+
return;
|
|
137
85
|
}
|
|
138
86
|
this.rubriqueForArray = (value as Array<Rubrique>);
|
|
139
87
|
}
|
|
@@ -141,102 +89,60 @@ export default defineComponent({
|
|
|
141
89
|
}
|
|
142
90
|
},
|
|
143
91
|
watch: {
|
|
144
|
-
model:{
|
|
145
|
-
deep: true,
|
|
146
|
-
handler(){
|
|
147
|
-
if(false===this.multiple){
|
|
148
|
-
return;
|
|
149
|
-
}
|
|
150
|
-
const selected: Array<Rubrique> = JSON.parse(JSON.stringify(this.model));
|
|
151
|
-
const idsArray: Array<number> = [];
|
|
152
|
-
selected.forEach((el: Rubrique) => {
|
|
153
|
-
if(el.rubriqueId){
|
|
154
|
-
idsArray.push(el.rubriqueId);
|
|
155
|
-
}
|
|
156
|
-
});
|
|
157
|
-
this.$emit('selected', idsArray);
|
|
158
|
-
}
|
|
159
|
-
},
|
|
160
92
|
rubriqueSelected: {
|
|
161
|
-
|
|
93
|
+
immediate:true,
|
|
162
94
|
handler(){
|
|
163
|
-
if (
|
|
164
|
-
this.initRubriqueSelected(
|
|
95
|
+
if (this.rubriqueSelected) {
|
|
96
|
+
this.initRubriqueSelected();
|
|
97
|
+
}else{
|
|
98
|
+
this.rubrique = this.getDefaultRubrique;
|
|
165
99
|
}
|
|
166
100
|
}
|
|
167
101
|
},
|
|
168
102
|
reset(): void {
|
|
169
|
-
this.rubrique =
|
|
103
|
+
this.rubrique = this.getDefaultRubrique;
|
|
170
104
|
}
|
|
171
105
|
},
|
|
172
106
|
mounted() {
|
|
173
|
-
|
|
174
|
-
this.initRubriqueSelected(this.rubriqueSelected);
|
|
175
|
-
}
|
|
176
|
-
if (undefined !== this.rubriqueArray) {
|
|
177
|
-
this.initRubriqueArray(this.rubriqueArray);
|
|
178
|
-
}
|
|
107
|
+
this.initRubriqueArray();
|
|
179
108
|
},
|
|
180
109
|
methods: {
|
|
181
|
-
initRubriquesArray(): Array<Rubrique>{
|
|
182
|
-
if ('' === this.defaultanswer) {
|
|
183
|
-
return this.allRubriques;
|
|
184
|
-
}
|
|
185
|
-
const rubriqueDefault = getDefaultRubrique(this.defaultanswer);
|
|
186
|
-
if(!rubriqueDefault){
|
|
187
|
-
return this.allRubriques;
|
|
188
|
-
}
|
|
189
|
-
if (this.withoutRubrique) {
|
|
190
|
-
return [
|
|
191
|
-
rubriqueDefault,
|
|
192
|
-
this.withoutItem,
|
|
193
|
-
].concat(this.allRubriques);
|
|
194
|
-
}
|
|
195
|
-
return [rubriqueDefault].concat(this.allRubriques);
|
|
196
|
-
},
|
|
197
|
-
onOpen(): void {
|
|
198
|
-
(this.$refs.multiselectRef as VueMultiselect).$refs.search.setAttribute(
|
|
199
|
-
'autocomplete',
|
|
200
|
-
'off'
|
|
201
|
-
);
|
|
202
|
-
this.rubriques = this.initRubriquesArray();
|
|
203
|
-
},
|
|
204
|
-
onClose(): void {
|
|
205
|
-
if (this.rubrique || undefined !== this.rubriqueArray) return;
|
|
206
|
-
if(this.cannotBeUndefined && undefined !== this.rubriqueSelected){
|
|
207
|
-
this.initRubriqueSelected(this.rubriqueSelected);
|
|
208
|
-
return;
|
|
209
|
-
}
|
|
210
|
-
this.rubrique ='' !== this.defaultanswer? getDefaultRubrique(this.defaultanswer): undefined;
|
|
211
|
-
this.onRubriqueSelected(this.rubrique);
|
|
212
|
-
},
|
|
213
110
|
onSearchRubrique(query: string): void {
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
},
|
|
220
|
-
onRubriqueSelected(rubrique: Rubrique|undefined): void {
|
|
221
|
-
if (undefined !== this.rubriqueSelected && rubrique) {
|
|
222
|
-
this.$emit('update:rubriqueSelected', rubrique.rubriqueId);
|
|
111
|
+
let rubriques = this.rubriques;
|
|
112
|
+
if(query){
|
|
113
|
+
rubriques = rubriques.filter((item: Rubrique) => {
|
|
114
|
+
return item.name.toUpperCase().includes(query.toUpperCase());
|
|
115
|
+
});
|
|
223
116
|
}
|
|
224
|
-
|
|
117
|
+
(this.$refs.selectRubrique as InstanceType<typeof ClassicMultiselect>).afterSearch(rubriques,rubriques.length);
|
|
118
|
+
},
|
|
119
|
+
onRubriqueSelected(rubrique: Rubrique| Array<Rubrique>): void {
|
|
120
|
+
if (undefined !== this.rubriqueSelected) {
|
|
121
|
+
this.$emit('update:rubriqueSelected', (rubrique as Rubrique).rubriqueId);
|
|
122
|
+
} else if (undefined !== this.categorySelectedArray) {
|
|
123
|
+
const idsArray: Array<number> = [];
|
|
124
|
+
(rubrique as Array<Rubrique>).forEach((el: Rubrique) => {
|
|
125
|
+
idsArray.push(el.rubriqueId??0);
|
|
126
|
+
});
|
|
127
|
+
this.$emit('update:rubriqueSelectedArray', idsArray);
|
|
128
|
+
}else{
|
|
225
129
|
this.$emit('selected', rubrique);
|
|
226
130
|
}
|
|
227
131
|
},
|
|
228
|
-
initRubriqueSelected(
|
|
229
|
-
this.rubrique = this.
|
|
230
|
-
return el.rubriqueId ===
|
|
231
|
-
});
|
|
132
|
+
initRubriqueSelected(): void {
|
|
133
|
+
this.rubrique = this.rubriques.find((el: Rubrique) => {
|
|
134
|
+
return el.rubriqueId === this.rubriqueSelected;
|
|
135
|
+
}) ?? this.getDefaultRubrique;
|
|
232
136
|
},
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
137
|
+
|
|
138
|
+
initRubriqueArray(): void {
|
|
139
|
+
if(!this.rubriqueForArray || !this.rubriqueSelectedArray){return; }
|
|
140
|
+
this.rubriqueForArray.length = 0;
|
|
141
|
+
this.rubriqueSelectedArray.forEach((element: number) => {
|
|
142
|
+
const item = this.rubriques.find((el: Rubrique) => {
|
|
237
143
|
return el.rubriqueId === element;
|
|
238
144
|
});
|
|
239
|
-
if(
|
|
145
|
+
if(this.rubriqueForArray && item){
|
|
240
146
|
this.rubriqueForArray.push(item);
|
|
241
147
|
}
|
|
242
148
|
});
|
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
:title="$t('See more')"
|
|
40
40
|
/>
|
|
41
41
|
<Popover
|
|
42
|
+
ref="popoverRubrique"
|
|
42
43
|
target="rubriques-dropdown"
|
|
43
44
|
:only-click="true"
|
|
44
45
|
:is-fixed="true"
|
|
@@ -46,22 +47,20 @@
|
|
|
46
47
|
>
|
|
47
48
|
<RubriqueChooser
|
|
48
49
|
v-if="hidenRubriques.length"
|
|
49
|
-
:multiple="false"
|
|
50
50
|
:rubriquage-id="rubriquage.rubriquageId"
|
|
51
51
|
:all-rubriques="hidenRubriques"
|
|
52
|
-
:cannot-be-undefined="true"
|
|
53
52
|
class="mb-3"
|
|
54
53
|
width="auto"
|
|
55
|
-
@selected="
|
|
54
|
+
@selected="addFilterFromPopover($event)"
|
|
56
55
|
/>
|
|
57
|
-
<button
|
|
56
|
+
<!-- <button
|
|
58
57
|
v-for="rubrique in hidenRubriques"
|
|
59
58
|
:key="rubrique.rubriqueId"
|
|
60
59
|
class="me-3 octopus-dropdown-item"
|
|
61
60
|
@mousedown="addFilter(rubrique)"
|
|
62
61
|
>
|
|
63
62
|
{{ rubrique.name }}
|
|
64
|
-
</button>
|
|
63
|
+
</button> -->
|
|
65
64
|
</Popover>
|
|
66
65
|
</div>
|
|
67
66
|
</template>
|
|
@@ -138,6 +137,10 @@ export default defineComponent({
|
|
|
138
137
|
this.resizeWindow();
|
|
139
138
|
});
|
|
140
139
|
},
|
|
140
|
+
addFilterFromPopover(rubrique: Rubrique): void{
|
|
141
|
+
(this.$refs.popoverRubrique as InstanceType<typeof Popover>).clearClick();
|
|
142
|
+
this.addFilter(rubrique);
|
|
143
|
+
},
|
|
141
144
|
addFilter(rubrique: Rubrique): void{
|
|
142
145
|
if(!this.rubriquage){ return ;}
|
|
143
146
|
const filterToAdd = {
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="module-box">
|
|
3
3
|
<div class="d-flex align-items-center mb-3">
|
|
4
|
-
<h2 class="big-h2 mb-0">
|
|
4
|
+
<h2 class="big-h2 mb-0">
|
|
5
|
+
{{ $t('Share') }}
|
|
6
|
+
</h2>
|
|
5
7
|
<span
|
|
6
8
|
v-if="authenticated"
|
|
7
9
|
id="popover-share-help"
|
|
@@ -14,8 +16,8 @@
|
|
|
14
16
|
target="popover-share-help"
|
|
15
17
|
:title="$t('Help')"
|
|
16
18
|
:content="$t('Share this page without edit and share blocks')"
|
|
17
|
-
|
|
18
|
-
:
|
|
19
|
+
relative-class="page-element"
|
|
20
|
+
:is-fixed="true"
|
|
19
21
|
/>
|
|
20
22
|
</div>
|
|
21
23
|
<div class="d-flex align-items-center justify-content-between">
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="d-flex flex-column me-2">
|
|
3
|
-
<div class="h4 mb-2">
|
|
3
|
+
<div class="h4 mb-2">
|
|
4
|
+
{{ $t('Social networks') }}
|
|
5
|
+
</div>
|
|
4
6
|
<div class="d-flex align-items-center">
|
|
5
7
|
<template
|
|
6
8
|
v-for="button in arrayShareButtons"
|
|
@@ -20,8 +22,13 @@
|
|
|
20
22
|
</template>
|
|
21
23
|
</div>
|
|
22
24
|
</div>
|
|
23
|
-
<div
|
|
24
|
-
|
|
25
|
+
<div
|
|
26
|
+
v-if="podcast || emission ||playlist"
|
|
27
|
+
class="d-flex flex-column me-2"
|
|
28
|
+
>
|
|
29
|
+
<div class="h4 mb-2">
|
|
30
|
+
{{ $t('Newsletter') }}
|
|
31
|
+
</div>
|
|
25
32
|
<div class="d-flex align-items-center justify-content-center">
|
|
26
33
|
<button
|
|
27
34
|
:class="getClass()"
|
|
@@ -33,19 +40,23 @@
|
|
|
33
40
|
</div>
|
|
34
41
|
|
|
35
42
|
<div class="d-flex flex-column me-2">
|
|
36
|
-
<div class="h4 mb-2">
|
|
43
|
+
<div class="h4 mb-2">
|
|
44
|
+
{{ $t('QR Code') }}
|
|
45
|
+
</div>
|
|
37
46
|
<div class="d-flex align-items-center justify-content-center">
|
|
38
47
|
<button
|
|
39
48
|
:class="getClass()"
|
|
40
49
|
:title="$t('Share QR Code')"
|
|
41
|
-
@click="qrCode = true"
|
|
42
50
|
class="saooti-qrcode"
|
|
51
|
+
@click="qrCode = true"
|
|
43
52
|
/>
|
|
44
53
|
</div>
|
|
45
54
|
</div>
|
|
46
55
|
|
|
47
56
|
<div class="d-flex flex-column me-2">
|
|
48
|
-
<div class="h4 mb-2">
|
|
57
|
+
<div class="h4 mb-2">
|
|
58
|
+
{{ $t('Copy this page URL') }}
|
|
59
|
+
</div>
|
|
49
60
|
<div class="d-flex align-items-center justify-content-center">
|
|
50
61
|
<button
|
|
51
62
|
:class="getClass()"
|
|
@@ -56,8 +67,13 @@
|
|
|
56
67
|
</div>
|
|
57
68
|
</div>
|
|
58
69
|
|
|
59
|
-
<div
|
|
60
|
-
|
|
70
|
+
<div
|
|
71
|
+
v-if="''!==rssUrl && displayRss"
|
|
72
|
+
class="d-flex flex-column me-2"
|
|
73
|
+
>
|
|
74
|
+
<div class="h4 mb-2">
|
|
75
|
+
{{ $t('Rss feed') }}
|
|
76
|
+
</div>
|
|
61
77
|
<div class="d-flex align-items-center justify-content-center">
|
|
62
78
|
<a
|
|
63
79
|
rel="noopener"
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="module-box">
|
|
3
|
-
<h2 class="big-h2 mb-3">
|
|
3
|
+
<h2 class="big-h2 mb-3">
|
|
4
|
+
{{ $t('Distribute') }}
|
|
5
|
+
</h2>
|
|
4
6
|
<div class="sharing-distribution-container">
|
|
5
7
|
{{ $t('Rss feed:') }}
|
|
6
8
|
<div class="text-primary hide-small-screen text-break">
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="module-box overflow-visible">
|
|
3
3
|
<div class="d-flex justify-content-between align-items-center">
|
|
4
|
-
<h2 class="big-h2 mb-3 height-40">
|
|
4
|
+
<h2 class="big-h2 mb-3 height-40">
|
|
5
|
+
{{ $t('Embed') }}
|
|
6
|
+
</h2>
|
|
5
7
|
<div
|
|
6
8
|
v-if="noAd && !isEducation"
|
|
7
9
|
class="sticker"
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="d-flex mt-3">
|
|
3
3
|
<div class="d-flex flex-column align-items-center flex-shrink-0 me-4">
|
|
4
|
-
<div class="h4 mb-2">
|
|
4
|
+
<div class="h4 mb-2">
|
|
5
|
+
{{ $t('Choose color') }}
|
|
6
|
+
</div>
|
|
5
7
|
<VSwatches
|
|
6
8
|
:model-value="color"
|
|
7
9
|
class="c-hand "
|
|
@@ -13,7 +15,9 @@
|
|
|
13
15
|
/>
|
|
14
16
|
</div>
|
|
15
17
|
<div class="d-flex flex-column align-items-center">
|
|
16
|
-
<div class="h4 mb-2">
|
|
18
|
+
<div class="h4 mb-2">
|
|
19
|
+
{{ $t('Choose theme') }}
|
|
20
|
+
</div>
|
|
17
21
|
<VSwatches
|
|
18
22
|
:model-value="theme"
|
|
19
23
|
class="c-hand "
|
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
class="default-multiselect-width"
|
|
4
|
+
:class="{'multiselect-in-modal' : inModal,
|
|
5
|
+
'multiselect-no-deselect': noDeselect}"
|
|
6
|
+
:style="{ width: width }"
|
|
7
|
+
>
|
|
8
|
+
<label
|
|
9
|
+
:for="id"
|
|
10
|
+
:title="label"
|
|
11
|
+
/>
|
|
12
|
+
<vSelect
|
|
13
|
+
:id="id"
|
|
14
|
+
v-model="optionSelected"
|
|
15
|
+
:label="optionLabel"
|
|
16
|
+
:append-to-body="inModal"
|
|
17
|
+
:multiple="multiple"
|
|
18
|
+
:options="options"
|
|
19
|
+
:disabled="isDisabled"
|
|
20
|
+
:loading="isLoading"
|
|
21
|
+
:placeholder="placeholder"
|
|
22
|
+
@open="onSearch"
|
|
23
|
+
@search="onSearch"
|
|
24
|
+
@option:selected="onOptionSelected"
|
|
25
|
+
>
|
|
26
|
+
<template
|
|
27
|
+
v-if="optionCustomTemplating"
|
|
28
|
+
#option="option"
|
|
29
|
+
>
|
|
30
|
+
<slot
|
|
31
|
+
name="optionTemplating"
|
|
32
|
+
:option="option"
|
|
33
|
+
/>
|
|
34
|
+
</template>
|
|
35
|
+
<template
|
|
36
|
+
v-if="optionCustomTemplating"
|
|
37
|
+
#selected-option="option"
|
|
38
|
+
>
|
|
39
|
+
<slot
|
|
40
|
+
name="optionTemplating"
|
|
41
|
+
:option="option"
|
|
42
|
+
/>
|
|
43
|
+
</template>
|
|
44
|
+
<template #no-options="{ searching }">
|
|
45
|
+
<span v-if="searching">{{ $t('No elements found. Consider changing the search query.') }}</span>
|
|
46
|
+
<span v-else>{{ $t('List is empty') }}</span>
|
|
47
|
+
</template>
|
|
48
|
+
<template #list-footer>
|
|
49
|
+
<li
|
|
50
|
+
v-if="remainingElements"
|
|
51
|
+
class="vs__dropdown-option"
|
|
52
|
+
>
|
|
53
|
+
{{
|
|
54
|
+
$t('Count more elements matched your query, please make a more specific search.',{ count: remainingElements })
|
|
55
|
+
}}
|
|
56
|
+
</li>
|
|
57
|
+
</template>
|
|
58
|
+
</vSelect>
|
|
59
|
+
</div>
|
|
60
|
+
</template>
|
|
61
|
+
|
|
62
|
+
<script lang="ts">
|
|
63
|
+
import vSelect from "vue-select";
|
|
64
|
+
export default {
|
|
65
|
+
components: {
|
|
66
|
+
vSelect,
|
|
67
|
+
},
|
|
68
|
+
props: {
|
|
69
|
+
id:{default: '', type: String},
|
|
70
|
+
label:{default: '', type: String},
|
|
71
|
+
placeholder:{default: '', type: String},
|
|
72
|
+
optionLabel:{default: '', type: String},
|
|
73
|
+
inModal:{default: false, type: Boolean},
|
|
74
|
+
multiple:{default: false, type: Boolean},
|
|
75
|
+
isDisabled:{default: false, type: Boolean},
|
|
76
|
+
width: { default: '100%', type: String },
|
|
77
|
+
maxElement: { default: 50, type: Number },
|
|
78
|
+
minSearchLength: { default: 3, type: Number },
|
|
79
|
+
optionChosen: { default: undefined, type: Object as ()=>unknown},
|
|
80
|
+
noDeselect:{default: false, type: Boolean},
|
|
81
|
+
optionCustomTemplating:{default: false, type: Boolean},
|
|
82
|
+
},
|
|
83
|
+
|
|
84
|
+
emits: ['onSearch','selected'],
|
|
85
|
+
|
|
86
|
+
data() {
|
|
87
|
+
return {
|
|
88
|
+
optionSelected: undefined as unknown|undefined,
|
|
89
|
+
options: [] as Array<unknown>,
|
|
90
|
+
remainingElements: 0 as number,
|
|
91
|
+
isLoading: false as boolean,
|
|
92
|
+
};
|
|
93
|
+
},
|
|
94
|
+
|
|
95
|
+
watch: {
|
|
96
|
+
optionChosen: {
|
|
97
|
+
deep: true,
|
|
98
|
+
immediate:true,
|
|
99
|
+
handler(){
|
|
100
|
+
this.optionSelected = this.optionChosen;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
|
|
105
|
+
methods:{
|
|
106
|
+
onSearch(search: string): void{
|
|
107
|
+
if(search && search.length < this.minSearchLength){return;}
|
|
108
|
+
this.isLoading = true;
|
|
109
|
+
this.$emit('onSearch', search);
|
|
110
|
+
},
|
|
111
|
+
afterSearch(optionsFetched: Array<unknown>, count: number):void{
|
|
112
|
+
this.options = optionsFetched;
|
|
113
|
+
this.remainingElements = Math.max(0, count - this.maxElement);
|
|
114
|
+
this.isLoading = false;
|
|
115
|
+
},
|
|
116
|
+
onOptionSelected(optionSelected: unknown):void{
|
|
117
|
+
this.$emit('selected', optionSelected);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
</script>
|
|
122
|
+
<style lang="scss">
|
|
123
|
+
@import "vue-select/dist/vue-select.css";
|
|
124
|
+
.octopus-app{
|
|
125
|
+
--vs-border-radius: 0.2rem;
|
|
126
|
+
--vs-dropdown-option--active-bg: #ddd;
|
|
127
|
+
--vs-dropdown-option--active-color: black;
|
|
128
|
+
.default-multiselect-width {
|
|
129
|
+
width: 100%;
|
|
130
|
+
font-size: 1rem;
|
|
131
|
+
}
|
|
132
|
+
.vs__dropdown-option{
|
|
133
|
+
white-space: initial;
|
|
134
|
+
}
|
|
135
|
+
.vs__search:focus{
|
|
136
|
+
min-width: 150px;
|
|
137
|
+
}
|
|
138
|
+
.multiselect-in-modal .vs__dropdown-menu{
|
|
139
|
+
z-index: 9999;
|
|
140
|
+
}
|
|
141
|
+
.multiselect-no-deselect .vs__clear{
|
|
142
|
+
display: none;
|
|
143
|
+
}
|
|
144
|
+
.multiselect-transparent{
|
|
145
|
+
--vs-border-color: transparent;
|
|
146
|
+
}
|
|
147
|
+
.multiselect-white{
|
|
148
|
+
--vs-selected-color: white;
|
|
149
|
+
--vs-dropdown-bg: black;
|
|
150
|
+
.vs__actions path{
|
|
151
|
+
fill: white;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
</style>
|