vidply 1.0.1 → 1.0.3

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/README.md CHANGED
@@ -21,6 +21,9 @@ A modern, feature-rich video player built with vanilla ES6 JavaScript. Combines
21
21
  ### Accessibility Features
22
22
  - **Full Keyboard Navigation** - WCAG 2.1 compliant
23
23
  - **Screen Reader Support** - Complete ARIA labels
24
+ - **Interactive Transcripts** - Click-to-seek transcript window
25
+ - **Sign Language Overlay** - Picture-in-picture sign language video
26
+ - **Audio Description** - Alternate audio track with descriptions
24
27
  - **Customizable Shortcuts** - User-definable hotkeys
25
28
  - **High Contrast Mode** - Windows HCM support
26
29
  - **Focus Indicators** - Clear visual focus states
@@ -29,9 +32,10 @@ A modern, feature-rich video player built with vanilla ES6 JavaScript. Combines
29
32
  ### Captions & Subtitles
30
33
  - **WebVTT Support** - Standard caption format
31
34
  - **Multiple Languages** - Multi-track support
32
- - **Customizable Display** - Font, size, color, opacity
33
- - **Caption Positioning** - Flexible placement
34
- - **Auto-generated Transcripts** - Interactive text
35
+ - **Caption Selector** - Easy track switching with CC button
36
+ - **Caption Styling** - Dedicated styling menu (font, size, color, opacity)
37
+ - **Chapter Navigation** - Jump to video chapters
38
+ - **Interactive Transcripts** - Full-text searchable transcript panel
35
39
 
36
40
  ### Playback Features
37
41
  - **Adjustable Speed** - 0.25x to 2x playback
@@ -198,8 +202,14 @@ const player = new Player('#video', {
198
202
  playPauseButton: true,
199
203
  progressBar: true,
200
204
  volumeControl: true,
205
+ chaptersButton: true,
206
+ qualityButton: true,
207
+ captionStyleButton: true,
201
208
  speedButton: true,
202
209
  captionsButton: true,
210
+ transcriptButton: true,
211
+ audioDescriptionButton: true,
212
+ signLanguageButton: true,
203
213
  fullscreenButton: true,
204
214
  pipButton: true,
205
215
 
@@ -212,6 +222,23 @@ const player = new Player('#video', {
212
222
  captionsBackgroundColor: '#000000',
213
223
  captionsOpacity: 0.8,
214
224
 
225
+ // Audio Description
226
+ audioDescription: true,
227
+ audioDescriptionSrc: null, // URL to audio-described version
228
+ audioDescriptionButton: true,
229
+
230
+ // Sign Language
231
+ signLanguage: true,
232
+ signLanguageSrc: null, // URL to sign language video
233
+ signLanguageButton: true,
234
+ signLanguagePosition: 'bottom-right', // 'bottom-right', 'bottom-left', 'top-right', 'top-left'
235
+
236
+ // Transcripts
237
+ transcript: false,
238
+ transcriptButton: true,
239
+ transcriptPosition: 'external',
240
+ transcriptContainer: null,
241
+
215
242
  // Keyboard
216
243
  keyboard: true,
217
244
  keyboardShortcuts: {
@@ -248,15 +275,18 @@ const player = new Player('#video', {
248
275
 
249
276
  | Key | Action |
250
277
  |-----|--------|
251
- | <kbd>Space</kbd> / <kbd>K</kbd> | Play/Pause |
278
+ | <kbd>Space</kbd> / <kbd>P</kbd> / <kbd>K</kbd> | Play/Pause |
252
279
  | <kbd>F</kbd> | Toggle Fullscreen |
253
280
  | <kbd>M</kbd> | Mute/Unmute |
254
281
  | <kbd>↑</kbd> / <kbd>↓</kbd> | Volume Up/Down |
255
282
  | <kbd>←</kbd> / <kbd>→</kbd> | Seek -10s / +10s |
256
- | <kbd>J</kbd> / <kbd>L</kbd> | Seek -30s / +30s |
257
- | <kbd>C</kbd> | Toggle Captions |
283
+ | <kbd>C</kbd> | Toggle Captions (or open menu if multiple) |
284
+ | <kbd>A</kbd> | Open Caption Style Menu |
258
285
  | <kbd><</kbd> / <kbd>></kbd> | Decrease/Increase Speed |
259
- | <kbd>S</kbd> | Open Settings |
286
+ | <kbd>S</kbd> | Open Speed Menu |
287
+ | <kbd>Q</kbd> | Open Quality Menu |
288
+ | <kbd>J</kbd> | Open Chapters Menu |
289
+ | <kbd>T</kbd> | Toggle Transcript |
260
290
 
261
291
  ## API Reference
262
292
 
@@ -309,6 +339,30 @@ player.captionManager.switchTrack(0) // Switch to first track
309
339
  player.captionManager.getAvailableTracks() // Get all tracks
310
340
  ```
311
341
 
342
+ ### Transcript
343
+
344
+ ```javascript
345
+ player.transcriptManager.showTranscript() // Show transcript window
346
+ player.transcriptManager.hideTranscript() // Hide transcript window
347
+ player.transcriptManager.toggleTranscript() // Toggle transcript
348
+ ```
349
+
350
+ ### Audio Description
351
+
352
+ ```javascript
353
+ player.enableAudioDescription() // Switch to described version
354
+ player.disableAudioDescription() // Switch back to original
355
+ player.toggleAudioDescription() // Toggle audio description
356
+ ```
357
+
358
+ ### Sign Language
359
+
360
+ ```javascript
361
+ player.enableSignLanguage() // Show sign language overlay
362
+ player.disableSignLanguage() // Hide sign language overlay
363
+ player.toggleSignLanguage() // Toggle sign language
364
+ ```
365
+
312
366
  ### Settings
313
367
 
314
368
  ```javascript
@@ -446,7 +500,9 @@ Contributions are welcome! Please feel free to submit a Pull Request.
446
500
  - Getting Started: See [GETTING_STARTED.md](docs/GETTING_STARTED.md)
447
501
  - Usage Examples: See [USAGE.md](docs/USAGE.md)
448
502
  - Playlist Guide: See [PLAYLIST.md](docs/PLAYLIST.md)
503
+ - Transcript Guide: See [TRANSCRIPT.md](docs/TRANSCRIPT.md)
449
504
  - Build Guide: See [BUILD.md](docs/BUILD.md)
505
+ - Changelog: See [CHANGELOG.md](docs/CHANGELOG.md)
450
506
  - Issues: Report on GitHub
451
507
  - Discussions: GitHub Discussions
452
508
 
package/dist/vidply.css CHANGED
@@ -151,6 +151,10 @@
151
151
  height: auto;
152
152
  }
153
153
 
154
+ .vidply-player.vidply-audio .vidply-menu {
155
+ max-height: 150px;
156
+ }
157
+
154
158
  /* Video/Audio Element */
155
159
  .vidply-player video,
156
160
  .vidply-player audio {
@@ -191,7 +195,7 @@
191
195
  overflow: hidden;
192
196
  position: relative;
193
197
  width: 100%;
194
- z-index: 10; /* Above track-info and playlist siblings */
198
+ z-index: 1; /* Base video layer */
195
199
  }
196
200
 
197
201
  /* Mobile: Simplify video wrapper */
@@ -222,7 +226,7 @@
222
226
  top: 50%;
223
227
  transform: translate(-50%, -50%);
224
228
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
225
- z-index: 15;
229
+ z-index: 2;
226
230
  }
227
231
 
228
232
  .vidply-play-overlay:hover {
@@ -287,7 +291,7 @@
287
291
  position: relative;
288
292
  right: 0;
289
293
  width: 100%;
290
- z-index: 100;
294
+ z-index: 10;
291
295
  }
292
296
 
293
297
  /* Allow menus to position within controls */
@@ -524,7 +528,7 @@
524
528
  position: fixed;
525
529
  right: 0;
526
530
  top: 0;
527
- z-index: 999;
531
+ z-index: 19;
528
532
  }
529
533
 
530
534
  .vidply-menu-backdrop.visible {
@@ -568,8 +572,8 @@
568
572
  /* iOS momentum scrolling */
569
573
  transform: translateX(50%);
570
574
 
571
- /* Ensure touch events work on iOS */
572
- z-index: 1000;
575
+ /* Ensure menus appear above all player content including overlays */
576
+ z-index: 20;
573
577
  }
574
578
 
575
579
  /* Menu positioned below button */
@@ -836,7 +840,12 @@
836
840
  text-align: center;
837
841
  transform: translateX(-50%);
838
842
  transition: bottom 0.3s ease;
839
- z-index: 5;
843
+ z-index: 4;
844
+ }
845
+
846
+ .vidply-audio .vidply-captions {
847
+ bottom: auto;
848
+ top: -42px;
840
849
  }
841
850
 
842
851
  .vidply-captions:empty {
@@ -870,7 +879,7 @@
870
879
  position: absolute;
871
880
  right: 0;
872
881
  top: 0;
873
- z-index: 2000;
882
+ z-index: 20;
874
883
  }
875
884
 
876
885
  @keyframes vidply-fade-in {
@@ -1182,7 +1191,7 @@
1182
1191
  top: auto;
1183
1192
  transform: translateX(-50%);
1184
1193
  width: auto;
1185
- z-index: 200;
1194
+ z-index: 15;
1186
1195
  }
1187
1196
 
1188
1197
  .vidply-menu::after {
@@ -1380,7 +1389,7 @@
1380
1389
  position: sticky;
1381
1390
  text-transform: uppercase;
1382
1391
  top: 0;
1383
- z-index: 10;
1392
+ z-index: 2;
1384
1393
  }
1385
1394
 
1386
1395
  .vidply-playlist-list {
@@ -1546,7 +1555,7 @@
1546
1555
  position: absolute;
1547
1556
  top: 0;
1548
1557
  width: 400px;
1549
- z-index: 100;
1558
+ z-index: 5;
1550
1559
  }
1551
1560
 
1552
1561
  /* Minimum height for audio player transcript */
@@ -1680,7 +1689,7 @@
1680
1689
  position: absolute;
1681
1690
  transition: opacity 0.3s ease;
1682
1691
  width: 35% !important;
1683
- z-index: 100;
1692
+ z-index: 3;
1684
1693
  }
1685
1694
 
1686
1695
  .vidply-fullscreen .vidply-sign-language-video {
@@ -1689,15 +1698,25 @@
1689
1698
 
1690
1699
  /* Sign Language Video Positions */
1691
1700
  .vidply-sign-position-bottom-right {
1692
- bottom: 80px; /* Above controls */
1701
+ bottom: 16px; /* Above controls */
1693
1702
  right: 16px;
1694
1703
  }
1695
1704
 
1705
+ .vidply-controls-visible + .vidply-sign-position-bottom-right,
1706
+ .vidply-controls-visible + .vidply-captions + .vidply-sign-position-bottom-right {
1707
+ bottom: 95px; /* Above controls */
1708
+ }
1709
+
1696
1710
  .vidply-sign-position-bottom-left {
1697
- bottom: 80px; /* Above controls */
1711
+ bottom: 16px; /* Above controls */
1698
1712
  left: 16px;
1699
1713
  }
1700
1714
 
1715
+ .vidply-controls-visible + .vidply-sign-position-bottom-left,
1716
+ .vidply-controls-visible + .vidply-captions + .vidply-sign-position-bottom-left {
1717
+ bottom: 95px; /* Above controls */
1718
+ }
1719
+
1701
1720
  .vidply-sign-position-top-right {
1702
1721
  right: 16px;
1703
1722
  top: 16px;
@@ -1712,12 +1731,12 @@
1712
1731
  @media (width <= 640px) {
1713
1732
  .vidply-sign-language-video {
1714
1733
  min-width: 120px;
1715
- width: 30%;
1734
+ width: 35%;
1716
1735
  }
1717
1736
 
1718
1737
  .vidply-sign-position-bottom-right,
1719
1738
  .vidply-sign-position-bottom-left {
1720
- bottom: 70px; /* Adjust for smaller controls */
1739
+ bottom: 126px !important; /* Adjust for smaller controls */
1721
1740
  }
1722
1741
  }
1723
1742
 
@@ -1750,7 +1769,7 @@
1750
1769
  order: 3; /* After controls (which are order: 2) */
1751
1770
  position: relative;
1752
1771
  width: 100%;
1753
- z-index: 50;
1772
+ z-index: 5;
1754
1773
  }
1755
1774
 
1756
1775
  .vidply-transcript-header {