@saooti/octopus-sdk 41.0.20 → 41.0.21

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,15 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## 41.0.21 (25/11/2025)
4
+
5
+ **Fixes**
6
+
7
+ - Correction affichage durée quand il n'y a pas de décimales
8
+
9
+ **Misc**
10
+
11
+ - Amélioration affichage bouton PlayPodcast
12
+
3
13
  ## 41.0.20 (21/11/2025)
4
14
 
5
15
  **Features**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@saooti/octopus-sdk",
3
- "version": "41.0.20",
3
+ "version": "41.0.21",
4
4
  "private": false,
5
5
  "description": "Javascript SDK for using octopus",
6
6
  "author": "Saooti",
@@ -33,7 +33,7 @@
33
33
  <PodcastIsPlaying v-if="playingPodcast && !playerStore.playerVideo" />
34
34
  <time
35
35
  v-if="!isVideoPodcast"
36
- class="ms-1"
36
+ class="ms-1 me-2"
37
37
  :datetime="durationIso"
38
38
  >
39
39
  {{ durationString }}
@@ -53,7 +53,7 @@
53
53
  />
54
54
  <PodcastIsPlaying v-if="playingPodcast && playerStore.playerVideo" />
55
55
  <time
56
- class="ms-2"
56
+ class="ms-2 me-2"
57
57
  :datetime="durationIso"
58
58
  >
59
59
  {{ durationString }}
@@ -32,11 +32,17 @@ function formatDuration(
32
32
  const hours = Math.floor(totalSeconds / 3600);
33
33
  const minutes = Math.floor((totalSeconds - hours * 3600) / 60);
34
34
  const seconds = totalSeconds - hours * 3600 - minutes * 60;
35
+
36
+ // In case seconds have decimal, round to 3 decimals, otherwise do not use decimals
37
+ const secondsStr = Math.round(seconds) == seconds ?
38
+ this.formatToString(seconds) :
39
+ this.formatToString(seconds.toFixed(3));
40
+
35
41
  return (
36
42
  (hours > 0 ? this.formatToString(hours) + separator : "") +
37
43
  this.formatToString(minutes) +
38
44
  separator +
39
- this.formatToString(seconds.toFixed(2)) +
45
+ secondsStr +
40
46
  (isLast ? separator : "")
41
47
  );
42
48
  }