@saooti/octopus-sdk 31.0.26 → 31.0.27

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.
Files changed (38) hide show
  1. package/README.md +5 -1
  2. package/package.json +2 -1
  3. package/src/components/display/podcasts/PodcastImage.vue +15 -9
  4. package/src/components/display/podcasts/PodcastInlineList.vue +43 -309
  5. package/src/components/display/podcasts/PodcastInlineListClassic.vue +246 -0
  6. package/src/components/display/podcasts/PodcastInlineListTemplate.vue +158 -0
  7. package/src/components/display/podcasts/PodcastModuleBox.vue +3 -26
  8. package/src/components/display/podcasts/PodcastSwiperList.vue +209 -0
  9. package/src/components/display/sharing/SharePlayer.vue +42 -81
  10. package/src/components/display/sharing/SharePlayerColors.vue +17 -15
  11. package/src/components/display/sharing/SharePlayerTypes.vue +15 -32
  12. package/src/components/display/sharing/SubscribeButtons.vue +44 -200
  13. package/src/components/form/ClassicCheckbox.vue +8 -8
  14. package/src/components/form/ClassicRadio.vue +9 -9
  15. package/src/components/form/ClassicSearch.vue +29 -29
  16. package/src/components/form/ClassicSelect.vue +12 -15
  17. package/src/components/misc/ErrorMessage.vue +6 -8
  18. package/src/components/misc/Footer.vue +63 -95
  19. package/src/components/misc/LeftMenu.vue +41 -89
  20. package/src/components/misc/Snackbar.vue +1 -1
  21. package/src/components/misc/TopBar.vue +41 -82
  22. package/src/components/misc/modal/ClipboardModal.vue +1 -8
  23. package/src/components/misc/modal/MessageModal.vue +1 -2
  24. package/src/components/misc/modal/QrCodeModal.vue +1 -11
  25. package/src/components/mixins/orgaComputed.ts +15 -0
  26. package/src/components/pages/Emission.vue +43 -86
  27. package/src/components/pages/Emissions.vue +27 -73
  28. package/src/components/pages/Home.vue +5 -12
  29. package/src/components/pages/Lives.vue +1 -6
  30. package/src/components/pages/Participant.vue +34 -48
  31. package/src/components/pages/Participants.vue +10 -28
  32. package/src/components/pages/Playlist.vue +20 -31
  33. package/src/components/pages/Playlists.vue +5 -15
  34. package/src/components/pages/Podcast.vue +95 -115
  35. package/src/components/pages/Podcasts.vue +34 -93
  36. package/src/components/pages/Rubrique.vue +6 -17
  37. package/src/components/pages/Search.vue +16 -36
  38. package/src/store/paramStore.ts +13 -11
@@ -3,19 +3,14 @@
3
3
  <div
4
4
  class="d-flex"
5
5
  :class="
6
- isEmissionChooser ? 'justify-content-between' : 'justify-content-center'
6
+ pageParameters.isEmissionChooser ? 'justify-content-between' : 'justify-content-center'
7
7
  "
8
8
  >
9
9
  <h1 class="flex-shrink-0">
10
- <template v-if="undefined === titlePage">
11
- {{ $t('All podcasts') }}
12
- </template>
13
- <template v-else>
14
- {{ titlePage }}
15
- </template>
10
+ {{ titleDisplay }}
16
11
  </h1>
17
12
  <EmissionChooser
18
- v-if="isEmissionChooser"
13
+ v-if="pageParameters.isEmissionChooser"
19
14
  :defaultanswer="$t('No emission filter')"
20
15
  width="auto"
21
16
  class="ms-3"
@@ -23,7 +18,7 @@
23
18
  />
24
19
  </div>
25
20
  <ProductorSearch
26
- v-if="isProductorSearch"
21
+ v-if="pageParameters.isProductorSearch"
27
22
  :organisation-id="organisationId"
28
23
  :search-pattern="searchPattern"
29
24
  @updateOrganisationId="updateOrganisationId"
@@ -33,18 +28,18 @@
33
28
  :is-education="isEducation"
34
29
  :is-emission="false"
35
30
  :reset-rubriquage="resetRubriquage"
36
- :is-search-bar="isProductorSearch"
31
+ :is-search-bar="pageParameters.isProductorSearch"
37
32
  :sort-criteria="sortCriteria"
38
- :includeHidden="includeHidden"
33
+ :include-hidden="includeHidden"
39
34
  :organisation-id="organisationId"
40
- @updateCategory="updateCategory"
35
+ @updateCategory="iabId=$event"
41
36
  @updateRubriquageFilter="updateRubriquageFilter"
42
- @updateMonetization="updateMonetization"
43
- @updateFromDate="updateFromDate"
44
- @updateToDate="updateToDate"
45
- @updateSortCriteria="updateSortCriteria"
46
- @includeHidden="updateHidden"
47
- @notValid="updateNotValid"
37
+ @updateMonetization="monetization = $event"
38
+ @updateFromDate="fromDate = $event"
39
+ @updateToDate="toDate = $event"
40
+ @updateSortCriteria="sortCriteria=$event"
41
+ @includeHidden="includeHidden = $event"
42
+ @notValid="notValid = $event"
48
43
  />
49
44
  <PodcastList
50
45
  :show-count="true"
@@ -68,32 +63,30 @@
68
63
  </template>
69
64
 
70
65
  <script lang="ts">
66
+ import { orgaComputed } from '../mixins/orgaComputed';
71
67
  import PodcastList from '../display/podcasts/PodcastList.vue';
72
68
  import { state } from '../../store/paramStore';
73
69
  import ProductorSearch from '../display/filter/ProductorSearch.vue';
74
70
  import AdvancedSearch from '../display/filter/AdvancedSearch.vue';
75
71
  import { Emission } from '@/store/class/general/emission';
76
- import { Category } from '@/store/class/general/category';
77
72
  import { RubriquageFilter } from '@/store/class/rubrique/rubriquageFilter';
78
73
 
79
74
  import { defineComponent, defineAsyncComponent } from 'vue';
80
75
  const EmissionChooser = defineAsyncComponent(() => import('../display/emission/EmissionChooser.vue'));
81
76
  export default defineComponent({
82
77
  name:"Podcasts",
83
-
84
78
  components: {
85
79
  PodcastList,
86
80
  ProductorSearch,
87
81
  EmissionChooser,
88
82
  AdvancedSearch,
89
83
  },
90
-
84
+ mixins:[orgaComputed],
91
85
  props: {
92
86
  productor: { default: undefined, type: String},
93
87
  isEducation: { default: false, type: Boolean},
94
88
  searchInit: { default: "", type: String}
95
89
  },
96
-
97
90
  data() {
98
91
  return {
99
92
  first: 0 as number,
@@ -116,17 +109,11 @@ export default defineComponent({
116
109
  },
117
110
 
118
111
  computed: {
119
- rubriqueFilter(): Array<RubriquageFilter>{
120
- return this.$store.state.filter.rubriqueFilter;
121
- },
122
- categoryFilter(): Category|undefined{
123
- return this.$store.state.filter.iab;
124
- },
125
- authenticated(): boolean {
126
- return (state.generalParameters.authenticated as boolean);
127
- },
128
- myOrganisationId(): string|undefined {
129
- return state.generalParameters.organisationId;
112
+ titleDisplay(): string{
113
+ if(undefined === state.podcastsPage.titlePage){
114
+ return this.$t('All podcasts');
115
+ }
116
+ return state.podcastsPage.titlePage;
130
117
  },
131
118
  organisationRight(): boolean {
132
119
  if (
@@ -136,62 +123,30 @@ export default defineComponent({
136
123
  return true;
137
124
  return false;
138
125
  },
139
- filterOrga(): string|undefined {
140
- return this.$store.state.filter.organisationId;
141
- },
142
126
  organisation(): string|undefined {
143
127
  if (this.organisationId) return this.organisationId;
144
128
  if (this.filterOrga) return this.filterOrga;
145
129
  return undefined;
146
130
  },
147
- isProductorSearch(): boolean {
148
- return (state.podcastsPage.ProductorSearch as boolean);
149
- },
150
- titlePage(): string|undefined {
151
- return state.podcastsPage.titlePage;
152
- },
153
- isEmissionChooser(): boolean {
154
- return (state.podcastsPage.emissionChooser as boolean);
155
- },
131
+ pageParameters(){
132
+ return {
133
+ isProductorSearch: state.podcastsPage.ProductorSearch,
134
+ isEmissionChooser: state.podcastsPage.emissionChooser
135
+ }
136
+ }
156
137
  },
157
138
 
158
139
  created() {
159
- if(this.searchInit){
160
- this.searchPattern = this.searchInit;
161
- }
162
- if (this.productor) {
163
- this.organisationId = this.productor;
164
- } else if (this.$store.state.filter.organisationId) {
165
- this.organisationId = this.$store.state.filter.organisationId;
166
- }
167
- if (this.organisation && this.organisationRight) {
168
- this.includeHidden = true;
169
- }
170
- if(this.categoryFilter){
171
- this.iabId = this.categoryFilter.id;
172
- }
173
- if(this.rubriqueFilter.length){
174
- this.updateRubriquageFilter(this.rubriqueFilter);
140
+ this.searchPattern = this.searchInit ? this.searchInit : '';
141
+ this.organisationId = this.productor ? this.productor : this.filterOrga;
142
+ this.includeHidden = this.organisation && this.organisationRight ? true : false;
143
+ this.iabId = this.$store.state.filter.iab ? this.$store.state.filter.iab.id : undefined;
144
+ if(this.$store.state.filter.rubriqueFilter.length){
145
+ this.updateRubriquageFilter(this.$store.state.filter.rubriqueFilter);
175
146
  }
176
147
  },
177
148
 
178
-
179
149
  methods: {
180
- updateCategory(value: number|undefined){
181
- this.iabId = value;
182
- },
183
- updateSortCriteria(value: string): void {
184
- this.sortCriteria = value;
185
- },
186
- updateHidden(value: boolean): void {
187
- this.includeHidden = value;
188
- },
189
- updateToDate(value: string): void {
190
- this.toDate = value;
191
- },
192
- updateFromDate(value: string): void {
193
- this.fromDate = value;
194
- },
195
150
  updateRubriquageFilter(value: Array<RubriquageFilter>){
196
151
  const length = value.length;
197
152
  const allRubriquageId: Array<number>= [];
@@ -218,25 +173,11 @@ export default defineComponent({
218
173
  this.organisationId = value;
219
174
  },
220
175
  updateSearchPattern(value: string): void {
221
- if ('' !== value) {
222
- this.sortCriteria = 'SCORE';
223
- } else {
224
- this.sortCriteria = 'DATE';
225
- }
176
+ this.sortCriteria = '' !== value ? 'SCORE' : 'DATE';
226
177
  this.searchPattern = value;
227
178
  },
228
- updateMonetization(value: string): void {
229
- this.monetization = value;
230
- },
231
- updateNotValid(value: boolean): void {
232
- this.notValid = value;
233
- },
234
179
  emissionSelected(emission: Emission): void {
235
- if (emission && emission.emissionId) {
236
- this.emissionId = emission.emissionId;
237
- } else {
238
- this.emissionId = undefined;
239
- }
180
+ this.emissionId = emission && emission.emissionId ? emission.emissionId : undefined;
240
181
  },
241
182
  },
242
183
  })
@@ -15,37 +15,26 @@ import PodcastList from '../display/podcasts/PodcastList.vue';
15
15
  import { defineComponent } from 'vue'
16
16
  export default defineComponent({
17
17
  name:"Rubrique",
18
-
19
18
  components: {
20
19
  PodcastList,
21
20
  },
22
-
23
21
  props: {
24
22
  firstRoute: { default: 0, type: Number},
25
23
  sizeRoute: { default: 12, type: Number},
26
24
  rubriqueId: { default: undefined, type: [ Number ]},
27
25
  },
28
-
29
26
  data() {
30
27
  return {
31
28
  title: '' as string,
32
29
  };
33
30
  },
34
-
35
31
  watch: {
36
- rubriqueId(): void {
37
- this.extractTitle();
38
- },
39
- },
40
-
41
- mounted() {
42
- this.extractTitle();
43
- },
44
-
45
- methods: {
46
- async extractTitle(): Promise<void> {
47
- const data = await octopusApi.fetchRubric(this.rubriqueId);
48
- this.title = data.name;
32
+ rubriqueId: {
33
+ immediate: true,
34
+ async handler() {
35
+ const data = await octopusApi.fetchRubric(this.rubriqueId);
36
+ this.title = data.name;
37
+ },
49
38
  },
50
39
  },
51
40
  })
@@ -1,16 +1,6 @@
1
1
  <template>
2
2
  <div class="page-box">
3
- <h1>
4
- <template v-if="!hideBar">
5
- {{ $t('Podcast search') }}
6
- </template>
7
- <template v-else-if="!noResult">
8
- {{ $t('Search results', { query: rawQuery }) }}
9
- </template>
10
- <template v-else>
11
- {{ $t('Search - no results', { query: rawQuery }) }}
12
- </template>
13
- </h1>
3
+ <h1>{{ titlePage }}</h1>
14
4
  <ClassicSearch
15
5
  v-if="!hideBar"
16
6
  v-model:textInit="rawQuery"
@@ -23,7 +13,7 @@
23
13
  :query="query"
24
14
  :first="0"
25
15
  :size="20"
26
- @emptyList="onListEmpty"
16
+ @emptyList="noResult = true"
27
17
  />
28
18
  </div>
29
19
  </template>
@@ -35,24 +25,29 @@ import PodcastList from '../display/podcasts/PodcastList.vue';
35
25
  import { defineComponent } from 'vue';
36
26
  export default defineComponent({
37
27
  name: "Search",
38
-
39
28
  components: {
40
29
  PodcastList,
41
30
  ClassicSearch
42
31
  },
43
-
44
32
  props: {
45
33
  queryRoute: { default: '', type: String },
46
34
  },
47
-
48
35
  data() {
49
36
  return {
50
37
  rawQuery: '' as string,
51
38
  noResult: false as boolean,
52
39
  };
53
40
  },
54
-
55
41
  computed: {
42
+ titlePage():string{
43
+ if(!this.hideBar){
44
+ return this.$t('Podcast search');
45
+ }
46
+ if(!this.noResult){
47
+ return this.$t('Search results', { query: this.rawQuery })
48
+ }
49
+ return this.$t('Search - no results', { query: this.rawQuery });
50
+ },
56
51
  query(): string {
57
52
  if (this.rawQuery && this.rawQuery.length >= 3) return this.rawQuery;
58
53
  return '';
@@ -61,32 +56,17 @@ export default defineComponent({
61
56
  return (state.searchPage.hideBar as boolean);
62
57
  },
63
58
  },
64
-
65
59
  watch: {
66
60
  rawQuery(): void{
67
61
  if (this.hideBar) {
68
62
  this.noResult = false;
69
63
  }
70
64
  },
71
- query(): void{
72
- this.rawQuery = this.query;
73
- },
74
- queryRoute(): void{
75
- this.rawQuery = this.queryRoute;
76
- }
77
- },
78
-
79
- mounted() {
80
- if (this.queryRoute) {
81
- this.rawQuery = this.queryRoute;
82
- }
83
- },
84
-
85
- methods: {
86
- onListEmpty(): void {
87
- if (this.hideBar) {
88
- this.noResult = true;
89
- }
65
+ queryRoute: {
66
+ immediate: true,
67
+ handler() {
68
+ this.rawQuery = this.queryRoute;
69
+ },
90
70
  },
91
71
  },
92
72
  })
@@ -12,7 +12,7 @@ const state:paramStore = {
12
12
  isPlaylist: false,
13
13
  isProduction: true,
14
14
  isContribution: true,
15
- ApiUri: 'https://api.dev2.saooti.org/',
15
+ ApiUri: 'https://api.preprod.saooti.org/',
16
16
  podcastmaker: false,
17
17
  buttonPlus: true,
18
18
  allCategories: [],
@@ -27,11 +27,13 @@ const state:paramStore = {
27
27
  ShareButtons: true,
28
28
  ShareDistribution: true,
29
29
  MiniplayerUri: 'https://playerbeta.dev2.saooti.org/',
30
- ouestFranceStyle: false,
31
30
  downloadButton: false,
32
- hlsUri: 'https://hls.dev2.saooti.org/',
31
+ hlsUri: 'https://hls.preprod.saooti.org/',
33
32
  mainRubrique: 0,
34
- resourceUrl: undefined
33
+ resourceUrl: undefined,
34
+ podcastItemShowEmission: false,
35
+ clickPlayGoPage:false,
36
+ listTypeClassic: true,
35
37
  },
36
38
  podcastsPage: {
37
39
  ProductorSearch: true,
@@ -54,7 +56,6 @@ const state:paramStore = {
54
56
  progressBar:false
55
57
  },
56
58
  emissionPage: {
57
- ouestFranceStyle: false,
58
59
  rssButton: false,
59
60
  isDisplayPodcasts:true,
60
61
  overflowScroll:false
@@ -83,10 +84,10 @@ const state:paramStore = {
83
84
  userName: '',
84
85
  },
85
86
  octopusApi: {
86
- url: 'http://api.dev2.saooti.org/',
87
- commentsUrl: 'http://comments.dev2.saooti.org/',
88
- studioUrl: 'http://studio.dev2.saooti.org/',
89
- playerUrl: 'https://playerbeta.dev2.saooti.org/',
87
+ url: 'http://api.preprod.saooti.org/',
88
+ commentsUrl: 'http://comments.preprod.saooti.org/',
89
+ studioUrl: 'http://studio.preprod.saooti.org/',
90
+ playerUrl: 'https://playerbeta.preprod.saooti.org/',
90
91
  organisationId: undefined,
91
92
  rubriqueIdFilter: undefined,
92
93
  },
@@ -117,11 +118,13 @@ export interface PodcastPage{
117
118
  ShareButtons?: boolean,
118
119
  ShareDistribution?: boolean,
119
120
  MiniplayerUri?: string,
120
- ouestFranceStyle?: boolean,
121
121
  downloadButton?: boolean,
122
122
  hlsUri?: string,
123
123
  mainRubrique?: number,
124
124
  resourceUrl?: string |undefined,
125
+ podcastItemShowEmission?: boolean,
126
+ clickPlayGoPage?:boolean,
127
+ listTypeClassic?:boolean
125
128
  }
126
129
  export interface PodcastsPage{
127
130
  ProductorSearch?: boolean,
@@ -144,7 +147,6 @@ export interface EmissionsPage{
144
147
  progressBar?:boolean
145
148
  }
146
149
  export interface EmissionPage{
147
- ouestFranceStyle?: boolean,
148
150
  rssButton?: boolean,
149
151
  isDisplayPodcasts?:boolean,
150
152
  overflowScroll?: boolean,