@saooti/octopus-sdk 41.10.9 → 41.11.0-beta2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## 41.11.0 (En cours)
4
+
5
+ **Features**
6
+
7
+ - **14327** - Ajout droits pour éléments médiathèque
8
+ - Revue du système de droits
9
+ - Propose maintenant des fonction `get*Right`, permettant d'obtenir la raison
10
+ du rejet
11
+ - Les anciennes fonctions `can*` existent toujours et sont dérivées des
12
+ nouvelles
13
+ - Ajout du composant `RightsIndicator` pour faciliter l'affichage des droits
14
+ de l'utilisateur sur un élément particulier
15
+ - Ajout du composant `ClassicTabs` pour simplifier la gestion d'onglets
16
+ - `ClassicNav` est déprécié en conséquence
17
+ - Ajout de l'api `mediathequeApi`
18
+
19
+ **Fixes**
20
+
21
+ - Correction des problèmes de placement de `ClassicPopover`
22
+ - Les props `constraintHeight` & `relativeClass` sont maintenant dépréciés
23
+
24
+ **Misc**
25
+
26
+ - Mise à jour eslint
27
+ - Déplacement de diverses dépendances dans `peerDependencies`
28
+ - Suppression des propriétés liées aux media dans `FilterStore`
29
+
3
30
  ## 41.10.9 (01/06/2026)
4
31
 
5
32
  **Fixes**
package/index.ts CHANGED
@@ -41,9 +41,11 @@ export const getClassicModalInBody = () => import("./src/components/misc/modal/C
41
41
  export const getClassicHelpButton = () => import("./src/components/misc/ClassicHelpButton.vue");
42
42
  export const getClassicAlert = () => import("./src/components/misc/ClassicAlert.vue");
43
43
  export const getClassicBigChip = () => import("./src/components/misc/ClassicBigChip.vue");
44
+ export const getClassicTabs = () => import("./src/components/misc/ClassicTabs.vue");
44
45
 
45
46
  import ClassicDataTable, { type ClassicDataTableHeader } from "./src/components/misc/ClassicDataTable.vue";
46
47
  import ClassicNotifications from "./src/components/misc/ClassicNotifications.vue";
48
+ export { type Tab } from "./src/components/misc/ClassicTabs.vue";
47
49
 
48
50
  export {
49
51
  ClassicDataTable,
@@ -76,6 +78,7 @@ export const getShareNewsletter = () => import("./src/components/display/sharing
76
78
  export const getQrCode = () => import("./src/components/display/sharing/QrCode.vue");
77
79
  export const SubscribeButtons = defineAsyncComponent(() => import("./src/components/display/sharing/SubscribeButtons.vue"));
78
80
  export const PodcastSeasonInfo = defineAsyncComponent(() => import("./src/components/display/podcasts/PodcastSeasonInfo.vue"));
81
+ export const RightsIndicator = defineAsyncComponent(() => import("./src/components/display/RightsIndicator.vue"));
79
82
 
80
83
 
81
84
  export const getEmissionInlineList = () => import("./src/components/display/emission/EmissionInlineList.vue");
@@ -122,7 +125,7 @@ export const getClassicTagInput = () => import("./src/components/form/ClassicTag
122
125
  export const getClassicWysiwyg = () => import("./src/components/form/ClassicWysiwyg.vue");
123
126
 
124
127
  //Composable
125
- import { useRights, EditRight } from "./src/components/composable/useRights.ts";
128
+ import { useRights, ActionRight } from "./src/components/composable/useRights.ts";
126
129
  import {useResizePhone} from "./src/components/composable/useResizePhone";
127
130
  import {useTagOf} from "./src/components/composable/useTagOf.ts";
128
131
  import {useSelenium} from "./src/components/composable/useSelenium.ts";
@@ -166,14 +169,7 @@ import {getApiUrl, ModuleApi} from "./src/api/apiConnection.ts";
166
169
  import classicApi from "./src/api/classicApi.ts";
167
170
 
168
171
  // API
169
- export { emissionApi } from "./src/api/emissionApi.ts";
170
- export { transcriptionApi, type TranslationData, TranslationState } from "./src/api/transcriptionApi.ts";
171
- export * from "./src/api/groupsApi.ts";
172
- export { organisationApi } from "./src/api/organisationApi.ts";
173
- export { playlistApi } from "./src/api/playlistApi.ts";
174
- export { podcastApi, PodcastSort, type PodcastSearchOptions } from "./src/api/podcastApi.ts";
175
- export { radioApi } from "./src/api/radioApi.ts";
176
- export * from "./src/api/aggregatorsApi.ts";
172
+ export * from "./src/api";
177
173
 
178
174
  // Types
179
175
  export { type Emission, SeasonMode, emptyEmissionData } from "./src/stores/class/general/emission.ts";
@@ -195,6 +191,9 @@ export {
195
191
  type Voice
196
192
  } from "./src/stores/class/transcript/transcriptParams.ts";
197
193
  export { type Canal } from "./src/stores/class/radio/canal.ts";
194
+ export { type Cartouchier } from "./src/stores/class/cartouchier/cartouchier.ts";
195
+ export { type Cartouche, emptyCartouche } from "./src/stores/class/cartouchier/cartouche.ts";
196
+ export { type PlaylistMedia } from "./src/stores/class/radio/playlistMedia";
198
197
 
199
198
  //Icons
200
199
  export const getAmazonMusicIcon = () => import("./src/components/icons/AmazonMusicIcon.vue");
@@ -228,7 +227,7 @@ import { defineAsyncComponent } from "vue";
228
227
 
229
228
  export {
230
229
  useRights,
231
- EditRight,
230
+ ActionRight,
232
231
  useResizePhone,
233
232
  useTagOf,
234
233
  useSelenium,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@saooti/octopus-sdk",
3
- "version": "41.10.9",
3
+ "version": "41.11.0-beta2",
4
4
  "private": false,
5
5
  "description": "Javascript SDK for using octopus",
6
6
  "author": "Saooti",
@@ -54,11 +54,8 @@
54
54
  "videojs-quality-selector-hls": "^1.1.1",
55
55
  "vite": "^6.4.1",
56
56
  "vite-bundle-visualizer": "^1.2.1",
57
- "vue": "^3.5.24",
58
- "vue-i18n": "^11.1.12",
59
57
  "vue-material-design-icons": "^5.3.1",
60
58
  "vue-recaptcha": "^2.0.3",
61
- "vue-router": "^4.6.3",
62
59
  "vue-select": "^4.0.0-beta.6",
63
60
  "vue3-lazyload": "^0.3.8",
64
61
  "vue3-swatches": "^1.2.4"
@@ -70,7 +67,7 @@
70
67
  "@vitejs/plugin-vue": "^5.2.4",
71
68
  "@vue/test-utils": "^2.4.6",
72
69
  "eslint": "^9.39.1",
73
- "eslint-plugin-vue": "^9.33.0",
70
+ "eslint-plugin-vue": "10.9.1",
74
71
  "happy-dom": "^20.1.0",
75
72
  "typescript": "^5.9.3",
76
73
  "vitest": "^4.0.16"
@@ -94,7 +91,11 @@
94
91
  "url": "git+https://github.com/saooti/octopus-sdk.git"
95
92
  },
96
93
  "peerDependencies": {
97
- "pinia": ">=2.3.0"
94
+ "eslint-plugin-vue": "^10.9.1",
95
+ "pinia": ">=2.3.0",
96
+ "vue": "^3.5.0",
97
+ "vue-i18n": "^11.1.0",
98
+ "vue-router": "^4.6.0"
98
99
  },
99
100
  "exports": {
100
101
  ".": {
@@ -0,0 +1,9 @@
1
+ export { emissionApi } from "./emissionApi";
2
+ export { transcriptionApi, type TranslationData, TranslationState } from "./transcriptionApi";
3
+ export * from "./groupsApi";
4
+ export { organisationApi } from "./organisationApi";
5
+ export { playlistApi } from "./playlistApi";
6
+ export { podcastApi, PodcastSort, type PodcastSearchOptions } from "./podcastApi";
7
+ export { radioApi } from "./radioApi";
8
+ export * from "./aggregatorsApi";
9
+ export * from "./mediathequeApi";
@@ -0,0 +1,75 @@
1
+ import { PlaylistMedia } from "../stores/class/radio/playlistMedia";
2
+ import { Mix } from "../stores/class/radio/mix";
3
+ import { ModuleApi } from "./apiConnection";
4
+ import classicApi from "./classicApi";
5
+ import { Cartouchier } from "@/stores/class/cartouchier/cartouchier";
6
+
7
+ /**
8
+ * Retrieve all cartouchier from the given organisation
9
+ * @param organisationId The ID of the organisation
10
+ * @param options Filtering options
11
+ * @returns List of cartouchier belonging to the organisation
12
+ */
13
+ async function getAllCartouchiers(organisationId: string, options?: { ownerId?: string }): Promise<Array<Cartouchier>> {
14
+ return classicApi.fetchData<Array<Cartouchier>>({
15
+ api: ModuleApi.MEDIA,
16
+ path: `cartouchier/list/${organisationId}`,
17
+ parameters: options
18
+ });
19
+ }
20
+
21
+ /**
22
+ * Retrieve all mix from the given organisation
23
+ * @param organisationId The ID of the organisation
24
+ * @returns List of mix belonging to the organisation
25
+ */
26
+ async function getAllMix(organisationId: string): Promise<Array<Mix>> {
27
+ return classicApi.fetchData<Array<Mix>>({
28
+ api: ModuleApi.MEDIA,
29
+ path: `mix/${organisationId}`
30
+ });
31
+ }
32
+
33
+ /**
34
+ * Delete mix with the given id
35
+ * @param mixId The ID of the mix to delete
36
+ */
37
+ async function deleteMix(mixId: number): Promise<void> {
38
+ await classicApi.deleteData({
39
+ api: ModuleApi.MEDIA,
40
+ path: `mix/${mixId}`
41
+ });
42
+ }
43
+
44
+ /**
45
+ * Retrieve all playlist from the given organisation
46
+ * @param organisationId The ID of the organisation
47
+ * @param options Filtering options
48
+ * @returns List of playlist belonging to the organisation
49
+ */
50
+ async function getAllPlaylists(organisationId: string, options?: { ownerId?: string }): Promise<Array<PlaylistMedia>> {
51
+ return classicApi.fetchData<Array<PlaylistMedia>>({
52
+ api: ModuleApi.MEDIA,
53
+ path: `playlist/${organisationId}`,
54
+ parameters: options
55
+ });
56
+ }
57
+
58
+ /**
59
+ * Delete playlist with the given id
60
+ * @param playlistId The ID of the playlist to delete
61
+ */
62
+ async function deletePlaylist(playlistId: number): Promise<void> {
63
+ await classicApi.deleteData({
64
+ api: ModuleApi.MEDIA,
65
+ path: `playlist/${playlistId}`
66
+ });
67
+ }
68
+
69
+ export const mediathequeApi = {
70
+ getAllCartouchiers,
71
+ getAllMix,
72
+ deleteMix,
73
+ getAllPlaylists,
74
+ deletePlaylist
75
+ }