@saooti/octopus-sdk 37.0.5 → 37.0.7

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 (263) hide show
  1. package/README.md +2 -2
  2. package/index.html +1 -0
  3. package/index.ts +21 -21
  4. package/package.json +26 -20
  5. package/public/css/fonts/icomoon.eot +0 -0
  6. package/public/css/fonts/icomoon.svg +1 -1
  7. package/public/css/fonts/icomoon.ttf +0 -0
  8. package/public/css/fonts/icomoon.woff +0 -0
  9. package/public/css/fonts/montserrat/Montserrat-Black.ttf +0 -0
  10. package/public/css/fonts/montserrat/Montserrat-BlackItalic.ttf +0 -0
  11. package/public/css/fonts/montserrat/Montserrat-Bold.ttf +0 -0
  12. package/public/css/fonts/montserrat/Montserrat-BoldItalic.ttf +0 -0
  13. package/public/css/fonts/montserrat/Montserrat-ExtraBold.ttf +0 -0
  14. package/public/css/fonts/montserrat/Montserrat-ExtraBoldItalic.ttf +0 -0
  15. package/public/css/fonts/montserrat/Montserrat-ExtraLight.ttf +0 -0
  16. package/public/css/fonts/montserrat/Montserrat-ExtraLightItalic.ttf +0 -0
  17. package/public/css/fonts/montserrat/Montserrat-Italic.ttf +0 -0
  18. package/public/css/fonts/montserrat/Montserrat-Light.ttf +0 -0
  19. package/public/css/fonts/montserrat/Montserrat-LightItalic.ttf +0 -0
  20. package/public/css/fonts/montserrat/Montserrat-Medium.ttf +0 -0
  21. package/public/css/fonts/montserrat/Montserrat-MediumItalic.ttf +0 -0
  22. package/public/css/fonts/montserrat/Montserrat-Regular.ttf +0 -0
  23. package/public/css/fonts/montserrat/Montserrat-SemiBold.ttf +0 -0
  24. package/public/css/fonts/montserrat/Montserrat-SemiBoldItalic.ttf +0 -0
  25. package/public/css/fonts/montserrat/Montserrat-Thin.ttf +0 -0
  26. package/public/css/fonts/montserrat/Montserrat-ThinItalic.ttf +0 -0
  27. package/public/css/fonts/montserrat/style.css +28 -0
  28. package/public/css/fonts/style.css +5 -5
  29. package/src/App.vue +69 -60
  30. package/src/api/classicCrud.ts +12 -12
  31. package/src/api/initialize.ts +1 -1
  32. package/src/assets/bootstrap.scss +9 -0
  33. package/src/assets/general.scss +1 -1
  34. package/src/assets/share.scss +1 -1
  35. package/src/components/display/aggregator/RssSection.vue +3 -3
  36. package/src/components/display/categories/CategoryChooser.vue +73 -60
  37. package/src/components/display/categories/CategoryFilter.vue +134 -90
  38. package/src/components/display/categories/CategoryList.vue +76 -62
  39. package/src/components/display/comments/AddCommentModal.vue +44 -44
  40. package/src/components/display/comments/CommentBasicView.vue +38 -30
  41. package/src/components/display/comments/CommentInput.vue +122 -110
  42. package/src/components/display/comments/CommentItem.vue +144 -102
  43. package/src/components/display/comments/CommentList.vue +117 -85
  44. package/src/components/display/comments/CommentParentInfo.vue +18 -15
  45. package/src/components/display/comments/CommentPlayer.vue +39 -41
  46. package/src/components/display/comments/CommentSection.vue +68 -53
  47. package/src/components/display/edit/EditBox.vue +7 -7
  48. package/src/components/display/edit/EditBoxRadio.vue +3 -4
  49. package/src/components/display/edit/EditCommentBox.vue +34 -36
  50. package/src/components/display/emission/EmissionInlineList.vue +75 -63
  51. package/src/components/display/emission/EmissionItem.vue +47 -35
  52. package/src/components/display/emission/EmissionList.vue +111 -83
  53. package/src/components/display/emission/EmissionPlayerItem.vue +89 -89
  54. package/src/components/display/filter/AdvancedSearch.vue +81 -73
  55. package/src/components/display/filter/CategorySearchFilter.vue +27 -25
  56. package/src/components/display/filter/DateFilter.vue +38 -38
  57. package/src/components/display/filter/MonetizableFilter.vue +16 -14
  58. package/src/components/display/filter/ProductorSearch.vue +55 -47
  59. package/src/components/display/filter/RubriqueChoice.vue +42 -27
  60. package/src/components/display/filter/RubriqueFilter.vue +130 -85
  61. package/src/components/display/filter/SearchOrder.vue +16 -11
  62. package/src/components/display/list/ListPaginate.vue +72 -70
  63. package/src/components/display/list/PaginateParams.vue +29 -30
  64. package/src/components/display/list/PaginateSection.vue +210 -0
  65. package/src/components/display/list/SwiperList.vue +28 -32
  66. package/src/components/display/live/CountDown.vue +12 -14
  67. package/src/components/display/live/LiveHorizontalList.vue +60 -50
  68. package/src/components/display/live/LiveItem.vue +42 -26
  69. package/src/components/display/live/LiveList.vue +92 -65
  70. package/src/components/display/live/RadioCurrently.vue +47 -42
  71. package/src/components/display/live/RadioImage.vue +40 -42
  72. package/src/components/display/live/RadioItem.vue +15 -22
  73. package/src/components/display/live/RadioList.vue +24 -21
  74. package/src/components/display/live/RadioPlanning.vue +105 -68
  75. package/src/components/display/organisation/OrganisationChooser.vue +58 -42
  76. package/src/components/display/organisation/OrganisationChooserLight.vue +27 -19
  77. package/src/components/display/participant/ParticipantItem.vue +89 -76
  78. package/src/components/display/participant/ParticipantList.vue +90 -60
  79. package/src/components/display/playlist/PlaylistItem.vue +32 -35
  80. package/src/components/display/playlist/PlaylistList.vue +70 -52
  81. package/src/components/display/playlist/PodcastList.vue +61 -50
  82. package/src/components/display/playlist/PodcastPlaylistInlineList.vue +47 -38
  83. package/src/components/display/podcasts/AnimatorsItem.vue +17 -15
  84. package/src/components/display/podcasts/ParticipantDescription.vue +21 -22
  85. package/src/components/display/podcasts/PodcastFilterList.vue +28 -26
  86. package/src/components/display/podcasts/PodcastImage.vue +129 -138
  87. package/src/components/display/podcasts/PodcastInlineList.vue +33 -29
  88. package/src/components/display/podcasts/PodcastInlineListClassic.vue +91 -71
  89. package/src/components/display/podcasts/PodcastInlineListTemplate.vue +94 -85
  90. package/src/components/display/podcasts/PodcastItem.vue +96 -90
  91. package/src/components/display/podcasts/PodcastItemInfo.vue +63 -65
  92. package/src/components/display/podcasts/PodcastList.vue +115 -84
  93. package/src/components/display/podcasts/PodcastModuleBox.vue +95 -104
  94. package/src/components/display/podcasts/PodcastPlayBar.vue +45 -32
  95. package/src/components/display/podcasts/PodcastSwiperList.vue +65 -55
  96. package/src/components/display/podcasts/TagList.vue +33 -37
  97. package/src/components/display/rubriques/RubriqueChooser.vue +70 -51
  98. package/src/components/display/rubriques/RubriqueList.vue +117 -89
  99. package/src/components/display/sharing/PlayerParameters.vue +45 -42
  100. package/src/components/display/sharing/QrCode.vue +52 -46
  101. package/src/components/display/sharing/ShareButtons.vue +25 -27
  102. package/src/components/display/sharing/ShareButtonsIntern.vue +182 -155
  103. package/src/components/display/sharing/ShareDistribution.vue +101 -67
  104. package/src/components/display/sharing/SharePlayer.vue +207 -127
  105. package/src/components/display/sharing/SharePlayerColors.vue +15 -15
  106. package/src/components/display/sharing/SharePlayerRadio.vue +62 -39
  107. package/src/components/display/sharing/SharePlayerTypes.vue +93 -55
  108. package/src/components/display/sharing/SubscribeButtons.vue +83 -32
  109. package/src/components/display/studio/RecordingItemButton.vue +3 -3
  110. package/src/components/form/ClassicCheckbox.vue +32 -31
  111. package/src/components/form/ClassicDatePicker.vue +47 -49
  112. package/src/components/form/ClassicInputText.vue +99 -98
  113. package/src/components/form/ClassicLoading.vue +11 -14
  114. package/src/components/form/ClassicMultiselect.vue +125 -126
  115. package/src/components/form/ClassicRadio.vue +15 -18
  116. package/src/components/form/ClassicSearch.vue +17 -23
  117. package/src/components/form/ClassicSelect.vue +35 -27
  118. package/src/components/form/{Wysiwyg.vue → ClassicWysiwyg.vue} +94 -109
  119. package/src/components/misc/AcpmImage.vue +26 -0
  120. package/src/components/misc/ClassicAccordion.vue +69 -0
  121. package/src/components/misc/ClassicNav.vue +117 -0
  122. package/src/components/misc/ClassicPopover.vue +212 -0
  123. package/src/components/misc/{Spinner.vue → ClassicSpinner.vue} +14 -15
  124. package/src/components/misc/ErrorMessage.vue +9 -17
  125. package/src/components/misc/FooterSection.vue +198 -0
  126. package/src/components/misc/HomeDropdown.vue +67 -64
  127. package/src/components/misc/LeftMenu.vue +115 -79
  128. package/src/components/misc/ProgressBar.vue +36 -32
  129. package/src/components/misc/SnackBar.vue +169 -0
  130. package/src/components/misc/TopBar.vue +161 -115
  131. package/src/components/misc/modal/ClassicModal.vue +99 -103
  132. package/src/components/misc/modal/ClipboardModal.vue +21 -23
  133. package/src/components/misc/modal/MessageModal.vue +22 -28
  134. package/src/components/misc/modal/NewsletterModal.vue +139 -113
  135. package/src/components/misc/modal/QrCodeModal.vue +14 -17
  136. package/src/components/misc/modal/ShareModalPlayer.vue +44 -60
  137. package/src/components/misc/player/PlayerCompact.vue +47 -62
  138. package/src/components/misc/player/{Player.vue → PlayerComponent.vue} +54 -46
  139. package/src/components/misc/player/PlayerLarge.vue +66 -62
  140. package/src/components/misc/player/PlayerProgressBar.vue +40 -30
  141. package/src/components/misc/player/PlayerTimeline.vue +32 -36
  142. package/src/components/misc/player/radio/RadioHistory.vue +62 -59
  143. package/src/components/misc/player/radio/RadioProgressBar.vue +44 -35
  144. package/src/components/mixins/cookies.ts +11 -10
  145. package/src/components/mixins/displayMethods.ts +5 -4
  146. package/src/components/mixins/handle403.ts +9 -9
  147. package/src/components/mixins/imageProxy.ts +14 -7
  148. package/src/components/mixins/init.ts +31 -16
  149. package/src/components/mixins/orgaComputed.ts +7 -7
  150. package/src/components/mixins/organisationFilter.ts +36 -22
  151. package/src/components/mixins/player/playerComment.ts +46 -37
  152. package/src/components/mixins/player/playerDisplay.ts +122 -87
  153. package/src/components/mixins/player/playerLive.ts +65 -43
  154. package/src/components/mixins/player/playerLogic.ts +133 -88
  155. package/src/components/mixins/player/playerTranscript.ts +48 -30
  156. package/src/components/mixins/radio/fetchRadioData.ts +40 -23
  157. package/src/components/mixins/selenium.ts +2 -2
  158. package/src/components/mixins/tagOfMixins.ts +11 -11
  159. package/src/components/pages/CategoryPage.vue +43 -0
  160. package/src/components/pages/{Emission.vue → EmissionPage.vue} +98 -67
  161. package/src/components/pages/{Emissions.vue → EmissionsPage.vue} +51 -44
  162. package/src/components/pages/Error403Page.vue +20 -19
  163. package/src/components/pages/HomePage.vue +144 -0
  164. package/src/components/pages/LivesPage.vue +66 -0
  165. package/src/components/pages/PageNotFound.vue +33 -22
  166. package/src/components/pages/{Participant.vue → ParticipantPage.vue} +63 -49
  167. package/src/components/pages/{Participants.vue → ParticipantsPage.vue} +9 -9
  168. package/src/components/pages/PlaylistPage.vue +175 -0
  169. package/src/components/pages/{Playlists.vue → PlaylistsPage.vue} +16 -14
  170. package/src/components/pages/PodcastPage.vue +365 -0
  171. package/src/components/pages/PodcastsPage.vue +152 -0
  172. package/src/components/pages/RadioPage.vue +131 -0
  173. package/src/components/pages/RubriquePage.vue +45 -0
  174. package/src/components/pages/{Search.vue → SearchPage.vue} +19 -19
  175. package/src/helper/dom.ts +1 -1
  176. package/src/helper/duration.ts +10 -4
  177. package/src/helper/useEventListener.ts +7 -8
  178. package/src/i18n.ts +31 -30
  179. package/src/locale/de.ts +263 -257
  180. package/src/locale/educationen.ts +13 -13
  181. package/src/locale/educationfr.ts +1 -1
  182. package/src/locale/en.ts +323 -324
  183. package/src/locale/es.ts +325 -318
  184. package/src/locale/fr.ts +330 -324
  185. package/src/locale/it.ts +332 -328
  186. package/src/locale/messages.ts +9 -9
  187. package/src/locale/sl.ts +315 -319
  188. package/src/main.ts +28 -31
  189. package/src/router/router.ts +218 -198
  190. package/src/shims-tsx.d.ts +1 -1
  191. package/src/shims-vue.d.ts +1 -1
  192. package/src/stores/ApiStore.ts +44 -44
  193. package/src/stores/AuthStore.ts +24 -16
  194. package/src/stores/CommentStore.ts +13 -11
  195. package/src/stores/FilterStore.ts +25 -15
  196. package/src/stores/GeneralStore.ts +15 -15
  197. package/src/stores/ParamSdkStore.ts +179 -137
  198. package/src/stores/PlayerStore.ts +139 -125
  199. package/src/stores/class/adserver/adserverConfig.ts +1 -1
  200. package/src/stores/class/adserver/adserverOtherEmission.ts +9 -9
  201. package/src/stores/class/cartouchier/cartouche.ts +4 -4
  202. package/src/stores/class/cartouchier/cartouchier.ts +2 -2
  203. package/src/stores/class/conference/conference.ts +10 -9
  204. package/src/stores/class/conference/conferenceMessage.ts +2 -2
  205. package/src/stores/class/conference/conferenceParticipant.ts +1 -1
  206. package/src/stores/class/conference/studioCall.ts +6 -6
  207. package/src/stores/class/contract/contractOrganisation.ts +5 -5
  208. package/src/stores/class/ftp/ftpEmission.ts +9 -9
  209. package/src/stores/class/ftp/testFtpEmission.ts +4 -4
  210. package/src/stores/class/general/audioView.ts +19 -19
  211. package/src/stores/class/general/category.ts +1 -1
  212. package/src/stores/class/general/classicSelectType.ts +2 -3
  213. package/src/stores/class/general/customPlayer.ts +8 -8
  214. package/src/stores/class/general/emission.ts +20 -21
  215. package/src/stores/class/general/fetchParam.ts +8 -2
  216. package/src/stores/class/general/initState.ts +31 -31
  217. package/src/stores/class/general/interfacePageable.ts +13 -13
  218. package/src/stores/class/general/ituneCategory.ts +4 -4
  219. package/src/stores/class/general/listReturn.ts +12 -12
  220. package/src/stores/class/general/media.ts +7 -7
  221. package/src/stores/class/general/organisation.ts +9 -10
  222. package/src/stores/class/general/pageable.ts +10 -10
  223. package/src/stores/class/general/participant.ts +7 -7
  224. package/src/stores/class/general/player.ts +30 -28
  225. package/src/stores/class/general/playlist.ts +17 -19
  226. package/src/stores/class/general/podcast.ts +19 -19
  227. package/src/stores/class/general/sortPageable.ts +4 -4
  228. package/src/stores/class/general/soundcastCategory.ts +7 -7
  229. package/src/stores/class/ouestFrance/ofTag.ts +34 -34
  230. package/src/stores/class/ouestFrance/ofTagInfo.ts +9 -9
  231. package/src/stores/class/ouestFrance/ofTagPage.ts +7 -7
  232. package/src/stores/class/ouestFrance/ofTagSeo.ts +7 -7
  233. package/src/stores/class/ouestFrance/ofTagVente.ts +6 -6
  234. package/src/stores/class/ouestFrance/ofTagWithParents.ts +20 -20
  235. package/src/stores/class/radio/canal.ts +4 -4
  236. package/src/stores/class/radio/live.ts +6 -6
  237. package/src/stores/class/radio/mix.ts +16 -16
  238. package/src/stores/class/radio/playlistMedia.ts +7 -7
  239. package/src/stores/class/radio/recurrence.ts +54 -54
  240. package/src/stores/class/rss/rssEmission.ts +13 -13
  241. package/src/stores/class/rss/rssInfo.ts +7 -7
  242. package/src/stores/class/rubrique/rubriquage.ts +2 -2
  243. package/src/stores/class/rubrique/rubrique.ts +1 -1
  244. package/src/stores/class/stat/statArrayIncome.ts +5 -5
  245. package/src/stores/class/stat/statArrayObject.ts +26 -26
  246. package/src/stores/class/stat/statGraph.ts +6 -6
  247. package/src/stores/class/user/person.ts +4 -2
  248. package/src/stores/class/user/profile.ts +4 -2
  249. package/src/stores/class/user/userKeycloak.ts +4 -5
  250. package/src/components/display/list/Paginate.vue +0 -181
  251. package/src/components/misc/Accordion.vue +0 -78
  252. package/src/components/misc/Footer.vue +0 -165
  253. package/src/components/misc/Nav.vue +0 -119
  254. package/src/components/misc/Popover.vue +0 -193
  255. package/src/components/misc/Snackbar.vue +0 -168
  256. package/src/components/pages/Category.vue +0 -41
  257. package/src/components/pages/Home.vue +0 -125
  258. package/src/components/pages/Lives.vue +0 -64
  259. package/src/components/pages/Playlist.vue +0 -164
  260. package/src/components/pages/Podcast.vue +0 -307
  261. package/src/components/pages/Podcasts.vue +0 -146
  262. package/src/components/pages/Radio.vue +0 -122
  263. package/src/components/pages/Rubrique.vue +0 -42
@@ -4,23 +4,19 @@
4
4
  v-model:first="dfirst"
5
5
  v-model:rowsPerPage="dsize"
6
6
  v-model:isMobile="isMobile"
7
- :text-count="displayCount > 1 ? `${$t('Number playlists', { nb: displayCount })}`: undefined"
7
+ :text-count="
8
+ displayCount > 1
9
+ ? `${$t('Number playlists', { nb: displayCount })}`
10
+ : undefined
11
+ "
8
12
  :total-count="totalCount"
9
13
  :loading="loading"
10
- :loading-text="loading?$t('Loading content ...'):undefined"
14
+ :loading-text="loading ? $t('Loading content ...') : undefined"
11
15
  >
12
16
  <template #list>
13
- <div
14
- class="emission-list two-emissions"
15
- >
16
- <template
17
- v-for="p in displayArray"
18
- :key="p.playlistId"
19
- >
20
- <PlaylistItem
21
- v-if="0!==p.playlistId"
22
- :playlist="p"
23
- />
17
+ <div class="emission-list two-emissions">
18
+ <template v-for="p in displayArray" :key="p.playlistId">
19
+ <PlaylistItem v-if="0 !== p.playlistId" :playlist="p" />
24
20
  </template>
25
21
  </div>
26
22
  </template>
@@ -28,21 +24,21 @@
28
24
  </template>
29
25
 
30
26
  <script lang="ts">
31
- import ListPaginate from '../list/ListPaginate.vue';
32
- import { handle403 } from '../../mixins/handle403';
33
- import octopusApi from '@saooti/octopus-api';
34
- import PlaylistItem from './PlaylistItem.vue';
35
- import { Playlist, emptyPlaylistData } from '@/stores/class/general/playlist';
36
- import { useFilterStore } from '@/stores/FilterStore';
37
- import { mapState } from 'pinia';
38
- import { defineComponent } from 'vue';
39
- import { AxiosError } from 'axios';
27
+ import ListPaginate from "../list/ListPaginate.vue";
28
+ import { handle403 } from "../../mixins/handle403";
29
+ import octopusApi from "@saooti/octopus-api";
30
+ import PlaylistItem from "./PlaylistItem.vue";
31
+ import { Playlist, emptyPlaylistData } from "@/stores/class/general/playlist";
32
+ import { useFilterStore } from "@/stores/FilterStore";
33
+ import { mapState } from "pinia";
34
+ import { defineComponent } from "vue";
35
+ import { AxiosError } from "axios";
40
36
  export default defineComponent({
41
- name: 'PlaylistList',
37
+ name: "PlaylistList",
42
38
 
43
39
  components: {
44
40
  PlaylistItem,
45
- ListPaginate
41
+ ListPaginate,
46
42
  },
47
43
 
48
44
  mixins: [handle403],
@@ -50,8 +46,8 @@ export default defineComponent({
50
46
  props: {
51
47
  first: { default: 0, type: Number },
52
48
  size: { default: 30, type: Number },
53
- query: { default: undefined, type: String},
54
- organisationId: { default: undefined, type: String},
49
+ query: { default: undefined, type: String },
50
+ organisationId: { default: undefined, type: String },
55
51
  },
56
52
 
57
53
  data() {
@@ -65,44 +61,50 @@ export default defineComponent({
65
61
  isMobile: false as boolean,
66
62
  };
67
63
  },
68
-
64
+
69
65
  computed: {
70
- ...mapState(useFilterStore, ['filterOrgaId']),
71
- displayArray(): Array<Playlist>{
72
- if(this.isMobile){
66
+ ...mapState(useFilterStore, ["filterOrgaId"]),
67
+ displayArray(): Array<Playlist> {
68
+ if (this.isMobile) {
73
69
  return this.playlists;
74
70
  }
75
- return this.playlists.slice(this.dfirst, Math.min(this.dfirst + this.dsize,this.totalCount));
76
- },
71
+ return this.playlists.slice(
72
+ this.dfirst,
73
+ Math.min(this.dfirst + this.dsize, this.totalCount),
74
+ );
75
+ },
77
76
  changed(): string {
78
77
  return `${this.first}|${this.size}|${this.organisationId}|${this.query}`;
79
78
  },
80
79
  sort(): string {
81
- return !this.query ?'NAME': 'SCORE';
80
+ return !this.query ? "NAME" : "SCORE";
82
81
  },
83
- organisation(): string|undefined {
84
- return this.organisationId ?this.organisationId: this.filterOrgaId;
82
+ organisation(): string | undefined {
83
+ return this.organisationId ? this.organisationId : this.filterOrgaId;
85
84
  },
86
85
  },
87
86
  watch: {
88
87
  changed(): void {
89
88
  this.reloadList();
90
89
  },
91
- dsize():void{
90
+ dsize(): void {
92
91
  this.reloadList();
93
- },
94
- dfirst(): void{
95
- if(!this.playlists[this.dfirst] || 0===this.playlists[this.dfirst].playlistId){
96
- this.fetchContent(false);
97
- }
98
- },
92
+ },
93
+ dfirst(): void {
94
+ if (
95
+ !this.playlists[this.dfirst] ||
96
+ 0 === this.playlists[this.dfirst].playlistId
97
+ ) {
98
+ this.fetchContent(false);
99
+ }
100
+ },
99
101
  },
100
102
 
101
103
  mounted() {
102
104
  this.fetchContent(true);
103
105
  },
104
106
  methods: {
105
- reloadList(){
107
+ reloadList() {
106
108
  this.dfirst = 0;
107
109
  this.fetchContent(true);
108
110
  },
@@ -113,22 +115,33 @@ export default defineComponent({
113
115
  size: this.dsize,
114
116
  query: this.query,
115
117
  organisationId: this.organisation,
116
- type:"NONE",
118
+ type: "NONE",
117
119
  sort: this.sort,
118
120
  };
119
121
  try {
120
- const data = await octopusApi.fetchDataWithParams<{count: number;result:Array<Playlist>;sort: string;}>(0, 'playlist/search',param, true);
122
+ const data = await octopusApi.fetchDataWithParams<{
123
+ count: number;
124
+ result: Array<Playlist>;
125
+ sort: string;
126
+ }>(0, "playlist/search", param, true);
121
127
  this.afterFetching(reset, data);
122
128
  } catch (error) {
123
- this.handle403((error as AxiosError));
129
+ this.handle403(error as AxiosError);
124
130
  }
125
131
  },
126
- afterFetching(reset: boolean, data: {count: number, result: Array<Playlist>, sort: string}): void {
132
+ afterFetching(
133
+ reset: boolean,
134
+ data: { count: number; result: Array<Playlist>; sort: string },
135
+ ): void {
127
136
  if (reset) {
128
137
  this.playlists.length = 0;
129
138
  }
130
- if(this.dfirst > this.playlists.length){
131
- for (let i = this.playlists.length-1, len = this.dfirst + this.dsize; i < len; i++) {
139
+ if (this.dfirst > this.playlists.length) {
140
+ for (
141
+ let i = this.playlists.length - 1, len = this.dfirst + this.dsize;
142
+ i < len;
143
+ i++
144
+ ) {
132
145
  this.playlists.push(emptyPlaylistData());
133
146
  }
134
147
  }
@@ -139,7 +152,12 @@ export default defineComponent({
139
152
  }
140
153
  return null !== e;
141
154
  });
142
- this.playlists = this.playlists.slice(0, this.dfirst).concat(responsePlaylists).concat(this.playlists.slice(this.dfirst+this.dsize, this.playlists.length));
155
+ this.playlists = this.playlists
156
+ .slice(0, this.dfirst)
157
+ .concat(responsePlaylists)
158
+ .concat(
159
+ this.playlists.slice(this.dfirst + this.dsize, this.playlists.length),
160
+ );
143
161
  this.totalCount = data.count;
144
162
  this.loading = false;
145
163
  },
@@ -147,5 +165,5 @@ export default defineComponent({
147
165
  this.fetchContent(false);
148
166
  },
149
167
  },
150
- })
151
- </script>
168
+ });
169
+ </script>
@@ -15,24 +15,24 @@
15
15
  v-model:first="first"
16
16
  v-model:rowsPerPage="size"
17
17
  v-model:isMobile="isMobile"
18
- :text-count="podcasts.length > 1 ? `${$t('Number podcasts', { nb: podcasts.length })}` : undefined"
18
+ :text-count="
19
+ podcasts.length > 1
20
+ ? `${$t('Number podcasts', { nb: podcasts.length })}`
21
+ : undefined
22
+ "
19
23
  :total-count="podcasts.length"
20
24
  :loading="loading"
21
- :loading-text="loading?$t('Loading podcasts ...'):undefined"
22
- :error-text="!loading && !podcasts.length && notEmptyPlaylist?$t(`No podcast match your query`):undefined"
25
+ :loading-text="loading ? $t('Loading podcasts ...') : undefined"
26
+ :error-text="
27
+ !loading && !podcasts.length && notEmptyPlaylist
28
+ ? $t(`No podcast match your query`)
29
+ : undefined
30
+ "
23
31
  >
24
32
  <template #list>
25
- <div
26
- class="podcast-list"
27
- >
28
- <template
29
- v-for="p in podcastsDisplay"
30
- :key="p.podcastId"
31
- >
32
- <PodcastItem
33
- v-if="0!==p.podcastId"
34
- :podcast="p"
35
- />
33
+ <div class="podcast-list">
34
+ <template v-for="p in podcastsDisplay" :key="p.podcastId">
35
+ <PodcastItem v-if="0 !== p.podcastId" :podcast="p" />
36
36
  </template>
37
37
  </div>
38
38
  </template>
@@ -41,30 +41,30 @@
41
41
  </template>
42
42
 
43
43
  <script lang="ts">
44
- import ListPaginate from '../list/ListPaginate.vue';
45
- import { handle403 } from '../../mixins/handle403';
46
- import { orgaComputed } from '../../mixins/orgaComputed';
47
- import octopusApi from '@saooti/octopus-api';
48
- import PodcastItem from '../podcasts/PodcastItem.vue';
49
- import { state } from '../../../stores/ParamSdkStore';
50
- import ClassicSearch from '../../form/ClassicSearch.vue';
51
- import { Podcast } from '@/stores/class/general/podcast';
52
- import { Playlist } from '@/stores/class/general/playlist';
53
- import { defineComponent } from 'vue'
54
- import { AxiosError } from 'axios';
44
+ import ListPaginate from "../list/ListPaginate.vue";
45
+ import { handle403 } from "../../mixins/handle403";
46
+ import { orgaComputed } from "../../mixins/orgaComputed";
47
+ import octopusApi from "@saooti/octopus-api";
48
+ import PodcastItem from "../podcasts/PodcastItem.vue";
49
+ import { state } from "../../../stores/ParamSdkStore";
50
+ import ClassicSearch from "../../form/ClassicSearch.vue";
51
+ import { Podcast } from "@/stores/class/general/podcast";
52
+ import { Playlist } from "@/stores/class/general/playlist";
53
+ import { defineComponent } from "vue";
54
+ import { AxiosError } from "axios";
55
55
  export default defineComponent({
56
- name: 'PodcastList',
56
+ name: "PodcastList",
57
57
 
58
58
  components: {
59
59
  PodcastItem,
60
60
  ClassicSearch,
61
- ListPaginate
61
+ ListPaginate,
62
62
  },
63
63
 
64
64
  mixins: [handle403, orgaComputed],
65
65
 
66
66
  props: {
67
- playlist: { default: ()=>({}), type: Object as ()=>Playlist},
67
+ playlist: { default: () => ({}), type: Object as () => Playlist },
68
68
  },
69
69
 
70
70
  data() {
@@ -74,34 +74,43 @@ export default defineComponent({
74
74
  podcastsQuery: [] as Array<Podcast>,
75
75
  size: 30 as number,
76
76
  first: 0 as number,
77
- searchPattern: '' as string,
77
+ searchPattern: "" as string,
78
78
  isMobile: false as boolean,
79
79
  };
80
80
  },
81
81
 
82
-
83
82
  computed: {
84
- titleList(): string{
85
- return this.notEmptyPlaylist ? this.$t('Podcasts in the playlist') : this.$t('No podcasts in the playlist');
83
+ titleList(): string {
84
+ return this.notEmptyPlaylist
85
+ ? this.$t("Podcasts in the playlist")
86
+ : this.$t("No podcasts in the playlist");
86
87
  },
87
88
  notEmptyPlaylist(): boolean {
88
- return 0 !== Object.keys(this.playlist.samplingViews??[]).length;
89
+ return 0 !== Object.keys(this.playlist.samplingViews ?? []).length;
89
90
  },
90
- podcastsDisplay(): Array<Podcast>{
91
- if(this.isMobile){
92
- return this.podcastsQuery.slice(0, Math.min(this.first + this.size,this.podcasts.length));
91
+ podcastsDisplay(): Array<Podcast> {
92
+ if (this.isMobile) {
93
+ return this.podcastsQuery.slice(
94
+ 0,
95
+ Math.min(this.first + this.size, this.podcasts.length),
96
+ );
93
97
  }
94
- return this.podcastsQuery.slice(this.first, Math.min(this.first + this.size,this.podcasts.length));
95
- },
98
+ return this.podcastsQuery.slice(
99
+ this.first,
100
+ Math.min(this.first + this.size, this.podcasts.length),
101
+ );
102
+ },
96
103
  editRight(): boolean {
97
- return (true===this.authenticated &&
98
- this.myOrganisationId === this.playlist.organisation?.id) ||
99
- true ===state.generalParameters.isAdmin
104
+ return (
105
+ (true === this.authenticated &&
106
+ this.myOrganisationId === this.playlist.organisation?.id) ||
107
+ true === state.generalParameters.isAdmin
108
+ );
100
109
  },
101
110
  },
102
111
  watch: {
103
112
  searchPattern(): void {
104
- if ('' !== this.searchPattern) {
113
+ if ("" !== this.searchPattern) {
105
114
  this.podcastsQuery = this.podcasts.filter((el: Podcast) => {
106
115
  return el.title
107
116
  .toLowerCase()
@@ -118,13 +127,16 @@ export default defineComponent({
118
127
  },
119
128
  methods: {
120
129
  async fetchContent(): Promise<void> {
121
- if (this.notEmptyPlaylist){
130
+ if (this.notEmptyPlaylist) {
122
131
  this.podcasts.length = 0;
123
132
  this.loading = true;
124
133
  try {
125
- this.podcasts = await octopusApi.fetchData<Array<Podcast>>(0, 'playlist/'+this.playlist.playlistId+'/content');
134
+ this.podcasts = await octopusApi.fetchData<Array<Podcast>>(
135
+ 0,
136
+ "playlist/" + this.playlist.playlistId + "/content",
137
+ );
126
138
  if (!this.editRight) {
127
- this.podcasts = this.podcasts.filter((p: Podcast|null) => {
139
+ this.podcasts = this.podcasts.filter((p: Podcast | null) => {
128
140
  return (
129
141
  null !== p &&
130
142
  (!p.availability || true === p.availability.visibility)
@@ -133,18 +145,17 @@ export default defineComponent({
133
145
  }
134
146
  this.podcastsQuery = this.podcasts;
135
147
  } catch (error) {
136
- this.handle403((error as AxiosError));
148
+ this.handle403(error as AxiosError);
137
149
  }
138
150
  }
139
151
  this.loading = false;
140
152
  },
141
153
  },
142
- })
154
+ });
143
155
  </script>
144
156
 
145
-
146
157
  <style lang="scss">
147
- .octopus-app{
158
+ .octopus-app {
148
159
  .width-600 {
149
160
  width: 600px;
150
161
  @media (max-width: 600px) {
@@ -152,4 +163,4 @@ export default defineComponent({
152
163
  }
153
164
  }
154
165
  }
155
- </style>
166
+ </style>
@@ -4,10 +4,7 @@
4
4
  class="d-flex flex-column p-3 playlist-inline-podcast"
5
5
  >
6
6
  <h2>{{ title }}</h2>
7
- <div
8
- v-if="!overflowScroll"
9
- class="d-flex justify-content-end hide-phone"
10
- >
7
+ <div v-if="!overflowScroll" class="d-flex justify-content-end hide-phone">
11
8
  <button
12
9
  class="btn admin-button m-1 saooti-left"
13
10
  :class="{ disabled: !previousAvailable }"
@@ -22,7 +19,7 @@
22
19
  />
23
20
  </div>
24
21
  <ClassicLoading
25
- :loading-text="loading?$t('Loading podcasts ...'):undefined"
22
+ :loading-text="loading ? $t('Loading podcasts ...') : undefined"
26
23
  />
27
24
  <transition-group
28
25
  :name="transitionName"
@@ -49,34 +46,32 @@
49
46
  params: { playlistId: playlistId.toString() },
50
47
  }"
51
48
  >
52
- {{ $t('See more') }}
53
- <div
54
- class="ms-1 saooti-more"
55
- />
49
+ {{ $t("See more") }}
50
+ <div class="ms-1 saooti-more" />
56
51
  </router-link>
57
52
  </div>
58
53
  </template>
59
54
 
60
55
  <script lang="ts">
61
- import octopusApi from '@saooti/octopus-api';
62
- import domHelper from '../../../helper/dom';
63
- import PodcastItem from '../podcasts/PodcastItem.vue';
64
- import ClassicLoading from '../../form/ClassicLoading.vue';
56
+ import octopusApi from "@saooti/octopus-api";
57
+ import domHelper from "../../../helper/dom";
58
+ import PodcastItem from "../podcasts/PodcastItem.vue";
59
+ import ClassicLoading from "../../form/ClassicLoading.vue";
65
60
  const PHONE_WIDTH = 960;
66
- import { state } from '../../../stores/ParamSdkStore';
67
- import { Podcast } from '@/stores/class/general/podcast';
68
- import { Playlist } from '@/stores/class/general/playlist';
69
- import { defineComponent } from 'vue'
61
+ import { state } from "../../../stores/ParamSdkStore";
62
+ import { Podcast } from "@/stores/class/general/podcast";
63
+ import { Playlist } from "@/stores/class/general/playlist";
64
+ import { defineComponent } from "vue";
70
65
  export default defineComponent({
71
- name: 'PodcastPlaylistInlineList',
72
-
66
+ name: "PodcastPlaylistInlineList",
67
+
73
68
  components: {
74
69
  PodcastItem,
75
- ClassicLoading
70
+ ClassicLoading,
76
71
  },
77
72
 
78
73
  props: {
79
- playlistId: { default: undefined, type: Number},
74
+ playlistId: { default: undefined, type: Number },
80
75
  },
81
76
 
82
77
  data() {
@@ -86,27 +81,29 @@ export default defineComponent({
86
81
  first: 0 as number,
87
82
  size: 5 as number,
88
83
  totalCount: 0 as number,
89
- playlist: undefined as Playlist|undefined,
84
+ playlist: undefined as Playlist | undefined,
90
85
  allPodcasts: [] as Array<Podcast>,
91
86
  direction: 1 as number,
92
87
  alignLeft: false as boolean,
93
88
  };
94
89
  },
95
90
  computed: {
96
- title(): string{
97
- return this.playlist?.title??"";
91
+ title(): string {
92
+ return this.playlist?.title ?? "";
98
93
  },
99
94
  podcasts(): Array<Podcast> {
100
95
  return this.allPodcasts.slice(this.index, this.index + this.size);
101
96
  },
102
97
  sizeItem(): number {
103
- return state.generalParameters.podcastItem ? state.generalParameters.podcastItem: 13;
98
+ return state.generalParameters.podcastItem
99
+ ? state.generalParameters.podcastItem
100
+ : 13;
104
101
  },
105
102
  overflowScroll(): boolean {
106
- return (state.emissionPage.overflowScroll as boolean);
103
+ return state.emissionPage.overflowScroll as boolean;
107
104
  },
108
105
  isInlineAnimation(): boolean {
109
- return (state.generalParameters.isInlineAnimation as boolean);
106
+ return state.generalParameters.isInlineAnimation as boolean;
110
107
  },
111
108
  previousAvailable(): boolean {
112
109
  return this.index > 0;
@@ -115,7 +112,7 @@ export default defineComponent({
115
112
  return this.index + this.size < this.totalCount;
116
113
  },
117
114
  transitionName(): string {
118
- return this.direction > 0 ? 'out-left' : 'out-right';
115
+ return this.direction > 0 ? "out-left" : "out-right";
119
116
  },
120
117
  },
121
118
  watch: {
@@ -124,13 +121,13 @@ export default defineComponent({
124
121
  this.fetchContent();
125
122
  },
126
123
  },
127
-
124
+
128
125
  created() {
129
- window.addEventListener('resize', this.handleResize);
126
+ window.addEventListener("resize", this.handleResize);
130
127
  },
131
128
 
132
129
  unmounted() {
133
- window.removeEventListener('resize', this.handleResize);
130
+ window.removeEventListener("resize", this.handleResize);
134
131
  },
135
132
 
136
133
  mounted() {
@@ -141,11 +138,23 @@ export default defineComponent({
141
138
  async fetchContent(): Promise<void> {
142
139
  this.allPodcasts.length = 0;
143
140
  this.loading = true;
144
- this.playlist = await octopusApi.fetchData<Playlist>(0, 'playlist/'+this.playlistId);
145
- this.allPodcasts = await octopusApi.fetchData<Array<Podcast>>(0, 'playlist/'+this.playlistId+'/content');
146
- if (!((state.generalParameters.authenticated && state.generalParameters.organisationId === this.playlist?.organisation?.id) ||
147
- state.generalParameters.isAdmin)) {
148
- this.allPodcasts = this.allPodcasts.filter((p: Podcast|null) => {
141
+ this.playlist = await octopusApi.fetchData<Playlist>(
142
+ 0,
143
+ "playlist/" + this.playlistId,
144
+ );
145
+ this.allPodcasts = await octopusApi.fetchData<Array<Podcast>>(
146
+ 0,
147
+ "playlist/" + this.playlistId + "/content",
148
+ );
149
+ if (
150
+ !(
151
+ (state.generalParameters.authenticated &&
152
+ state.generalParameters.organisationId ===
153
+ this.playlist?.organisation?.id) ||
154
+ state.generalParameters.isAdmin
155
+ )
156
+ ) {
157
+ this.allPodcasts = this.allPodcasts.filter((p: Podcast | null) => {
149
158
  return (
150
159
  null !== p &&
151
160
  (!p.availability || true === p.availability.visibility)
@@ -187,5 +196,5 @@ export default defineComponent({
187
196
  this.allPodcasts.length = 0;
188
197
  },
189
198
  },
190
- })
191
- </script>
199
+ });
200
+ </script>
@@ -18,31 +18,33 @@
18
18
  </template>
19
19
 
20
20
  <script lang="ts">
21
- import { Participant } from '@/stores/class/general/participant';
22
- import { useFilterStore } from '@/stores/FilterStore';
23
- import { mapState } from 'pinia';
24
- import { defineComponent } from 'vue';
21
+ import { Participant } from "@/stores/class/general/participant";
22
+ import { useFilterStore } from "@/stores/FilterStore";
23
+ import { mapState } from "pinia";
24
+ import { defineComponent } from "vue";
25
25
  export default defineComponent({
26
- name: 'AnimatorsItem',
26
+ name: "AnimatorsItem",
27
27
 
28
28
  props: {
29
- animator: { default: undefined, type: Object as ()=> Participant},
29
+ animator: { default: undefined, type: Object as () => Participant },
30
30
  },
31
- computed:{
32
- ...mapState(useFilterStore, ['filterOrgaId']),
33
- animatorName(): string{
34
- return (`${this.animator?.firstName??''} ${this.animator?.lastName??''}`).trim();
35
- }
36
- }
37
- })
31
+ computed: {
32
+ ...mapState(useFilterStore, ["filterOrgaId"]),
33
+ animatorName(): string {
34
+ return `${this.animator?.firstName ?? ""} ${
35
+ this.animator?.lastName ?? ""
36
+ }`.trim();
37
+ },
38
+ },
39
+ });
38
40
  </script>
39
41
 
40
42
  <style lang="scss">
41
- .octopus-app{
43
+ .octopus-app {
42
44
  .podcast-item-animator {
43
45
  font-size: 0.55rem;
44
46
  font-weight: 300;
45
47
  text-transform: capitalize;
46
48
  }
47
49
  }
48
- </style>
50
+ </style>
@@ -1,8 +1,5 @@
1
1
  <template>
2
- <div
3
- v-if="participants.length"
4
- class="comma"
5
- >
2
+ <div v-if="participants.length" class="comma">
6
3
  {{ title }}
7
4
  <span class="mx-1">:</span>
8
5
  <router-link
@@ -23,34 +20,36 @@
23
20
  </template>
24
21
 
25
22
  <script lang="ts">
26
- import { Participant } from '@/stores/class/general/participant';
27
- import { useFilterStore } from '@/stores/FilterStore';
28
- import { mapState } from 'pinia';
29
- import { defineComponent } from 'vue';
23
+ import { Participant } from "@/stores/class/general/participant";
24
+ import { useFilterStore } from "@/stores/FilterStore";
25
+ import { mapState } from "pinia";
26
+ import { defineComponent } from "vue";
30
27
  export default defineComponent({
31
- name: 'ParticipantDescription',
28
+ name: "ParticipantDescription",
32
29
 
33
- components:{
34
- },
30
+ components: {},
35
31
 
36
32
  props: {
37
- participants: { default: () => [], type: Array as ()=> Array<Participant>},
38
- isGuest: { default: false, type: Boolean},
33
+ participants: {
34
+ default: () => [],
35
+ type: Array as () => Array<Participant>,
36
+ },
37
+ isGuest: { default: false, type: Boolean },
39
38
  },
40
39
 
41
- computed:{
42
- ...mapState(useFilterStore, ['filterOrgaId']),
43
- idPopover(): string{
40
+ computed: {
41
+ ...mapState(useFilterStore, ["filterOrgaId"]),
42
+ idPopover(): string {
44
43
  return this.isGuest ? "popover-guests-help" : "popover-animators-help";
45
44
  },
46
- title(): string{
47
- return this.isGuest ? this.$t('Guests') : this.$t('Animated by');
48
- }
45
+ title(): string {
46
+ return this.isGuest ? this.$t("Guests") : this.$t("Animated by");
47
+ },
49
48
  },
50
49
  methods: {
51
50
  getName(person: Participant): string {
52
- return (`${person.firstName??''} ${person.lastName??''}`).trim();
51
+ return `${person.firstName ?? ""} ${person.lastName ?? ""}`.trim();
53
52
  },
54
53
  },
55
- })
56
- </script>
54
+ });
55
+ </script>