@vocasync/astro 1.0.0 → 1.0.1

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.
@@ -889,6 +889,11 @@ const audioDataJson = audioEntry ? JSON.stringify({
889
889
  clearHighlights();
890
890
  } else {
891
891
  updateHighlighting();
892
+ // Toggling off stops the rAF loop; restart it so highlighting resumes
893
+ // following the audio when re-enabled mid-playback.
894
+ if (!audio.paused && !audio.ended) {
895
+ startHighlightLoop();
896
+ }
892
897
  }
893
898
  }
894
899
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vocasync/astro",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "VocaSync integration for Astro - Text-to-speech synthesis and word-level alignment for static sites",
5
5
  "type": "module",
6
6
  "types": "./dist/index.d.ts",
@@ -889,6 +889,11 @@ const audioDataJson = audioEntry ? JSON.stringify({
889
889
  clearHighlights();
890
890
  } else {
891
891
  updateHighlighting();
892
+ // Toggling off stops the rAF loop; restart it so highlighting resumes
893
+ // following the audio when re-enabled mid-playback.
894
+ if (!audio.paused && !audio.ended) {
895
+ startHighlightLoop();
896
+ }
892
897
  }
893
898
  }
894
899