@videojs/html 10.2.0 → 10.4.0
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/dist/default/define/audio/compat-skin.css +161 -41
- package/dist/default/define/audio/compat-skin2.js +1 -1
- package/dist/default/define/audio/neutral-skin.css +73 -34
- package/dist/default/define/audio/neutral-skin2.js +1 -1
- package/dist/default/define/audio/scaffold-skin.css +166 -42
- package/dist/default/define/audio/scaffold-skin2.js +1 -1
- package/dist/default/define/audio/skin.css +72 -34
- package/dist/default/define/audio/skin2.js +1 -1
- package/dist/default/define/extensions/google-analytics.js +6 -0
- package/dist/default/define/live-audio/compat-skin.css +143 -41
- package/dist/default/define/live-audio/compat-skin2.js +1 -1
- package/dist/default/define/live-audio/neutral-skin.css +56 -31
- package/dist/default/define/live-audio/neutral-skin2.js +1 -1
- package/dist/default/define/live-audio/scaffold-skin.css +148 -42
- package/dist/default/define/live-audio/scaffold-skin2.js +1 -1
- package/dist/default/define/live-audio/skin.css +55 -31
- package/dist/default/define/live-audio/skin2.js +1 -1
- package/dist/default/define/live-video/compat-skin.css +234 -51
- package/dist/default/define/live-video/compat-skin2.js +1 -1
- package/dist/default/define/live-video/neutral-skin.css +300 -46
- package/dist/default/define/live-video/neutral-skin2.js +1 -1
- package/dist/default/define/live-video/scaffold-skin.css +231 -53
- package/dist/default/define/live-video/scaffold-skin2.js +1 -1
- package/dist/default/define/live-video/skin.css +314 -49
- package/dist/default/define/live-video/skin2.js +1 -1
- package/dist/default/define/media/dailymotion-video.js +11 -0
- package/dist/default/define/media/mixcloud-audio.js +11 -0
- package/dist/default/define/media/soundcloud-audio.js +11 -0
- package/dist/default/define/ui/time-slider-markers.js +5 -0
- package/dist/default/define/video/compat-skin.css +242 -51
- package/dist/default/define/video/compat-skin2.js +1 -1
- package/dist/default/define/video/neutral-skin.css +382 -57
- package/dist/default/define/video/neutral-skin2.js +1 -1
- package/dist/default/define/video/scaffold-skin.css +240 -53
- package/dist/default/define/video/scaffold-skin2.js +1 -1
- package/dist/default/define/video/skin.css +415 -55
- package/dist/default/define/video/skin2.js +1 -1
- package/dist/default/extensions/google-analytics/extension.js +75 -0
- package/dist/default/extensions/mux-data/extension.js +7 -2
- package/dist/default/index.js +3 -1
- package/dist/default/internal/skins/compat-audio/skin.css +161 -41
- package/dist/default/internal/skins/compat-audio/template.js +1 -1
- package/dist/default/internal/skins/compat-live-audio/skin.css +143 -41
- package/dist/default/internal/skins/compat-live-video/skin.css +234 -51
- package/dist/default/internal/skins/compat-live-video/template.js +2 -0
- package/dist/default/internal/skins/compat-video/skin.css +242 -51
- package/dist/default/internal/skins/compat-video/template.js +2 -0
- package/dist/default/internal/skins/default-audio/skin.css +72 -34
- package/dist/default/internal/skins/default-live-audio/skin.css +55 -31
- package/dist/default/internal/skins/default-live-video/skin.css +314 -49
- package/dist/default/internal/skins/default-live-video/template.js +14 -0
- package/dist/default/internal/skins/default-video/register.js +3 -0
- package/dist/default/internal/skins/default-video/skin.css +415 -55
- package/dist/default/internal/skins/default-video/template.js +33 -5
- package/dist/default/internal/skins/neutral-audio/skin.css +73 -34
- package/dist/default/internal/skins/neutral-live-audio/skin.css +56 -31
- package/dist/default/internal/skins/neutral-live-video/skin.css +300 -46
- package/dist/default/internal/skins/neutral-live-video/template.js +14 -0
- package/dist/default/internal/skins/neutral-video/skin.css +382 -57
- package/dist/default/internal/skins/neutral-video/template.js +25 -11
- package/dist/default/internal/skins/scaffold-audio/skin.css +166 -42
- package/dist/default/internal/skins/scaffold-audio/template.js +1 -1
- package/dist/default/internal/skins/scaffold-live-audio/skin.css +148 -42
- package/dist/default/internal/skins/scaffold-live-video/skin.css +231 -53
- package/dist/default/internal/skins/scaffold-live-video/template.js +2 -0
- package/dist/default/internal/skins/scaffold-video/skin.css +240 -53
- package/dist/default/internal/skins/scaffold-video/template.js +3 -1
- package/dist/default/media/background-video/adapter.js +13 -35
- package/dist/default/media/background-video/base.js +95 -0
- package/dist/default/media/background-video/template.js +13 -20
- package/dist/default/media/dailymotion-video/adapter.js +31 -0
- package/dist/default/media/hls-background-video/adapter.js +23 -35
- package/dist/default/media/mixcloud-audio/adapter.js +16 -0
- package/dist/default/media/soundcloud-audio/adapter.js +16 -0
- package/dist/default/player/element.js +1 -5
- package/dist/default/presets/background/skin.js +2 -2
- package/dist/default/presets/skin.js +4 -3
- package/dist/default/ui/captions-radio-group/element.js +14 -1
- package/dist/default/ui/controls/element.js +6 -3
- package/dist/default/ui/dialog/element.js +13 -1
- package/dist/default/ui/gesture/element.js +3 -0
- package/dist/default/ui/media-button-element.js +10 -1
- package/dist/default/ui/playback-rate-button/element.js +7 -2
- package/dist/default/ui/playback-rate-radio-group/element.js +10 -3
- package/dist/default/ui/radio-options/controller.js +18 -5
- package/dist/default/ui/time-slider/markers.js +160 -0
- package/dist/default/version.js +1 -1
- package/dist/dev/define/audio/compat-skin.css +161 -41
- package/dist/dev/define/audio/compat-skin2.js +1 -1
- package/dist/dev/define/audio/compat-skin2.js.map +1 -1
- package/dist/dev/define/audio/neutral-skin.css +73 -34
- package/dist/dev/define/audio/neutral-skin2.js +1 -1
- package/dist/dev/define/audio/neutral-skin2.js.map +1 -1
- package/dist/dev/define/audio/scaffold-skin.css +166 -42
- package/dist/dev/define/audio/scaffold-skin2.js +1 -1
- package/dist/dev/define/audio/scaffold-skin2.js.map +1 -1
- package/dist/dev/define/audio/skin.css +72 -34
- package/dist/dev/define/audio/skin2.js +1 -1
- package/dist/dev/define/audio/skin2.js.map +1 -1
- package/dist/dev/define/extensions/google-analytics.d.ts +11 -0
- package/dist/dev/define/extensions/google-analytics.js +8 -0
- package/dist/dev/define/extensions/google-analytics.js.map +1 -0
- package/dist/dev/define/live-audio/compat-skin.css +143 -41
- package/dist/dev/define/live-audio/compat-skin2.js +1 -1
- package/dist/dev/define/live-audio/compat-skin2.js.map +1 -1
- package/dist/dev/define/live-audio/neutral-skin.css +56 -31
- package/dist/dev/define/live-audio/neutral-skin2.js +1 -1
- package/dist/dev/define/live-audio/neutral-skin2.js.map +1 -1
- package/dist/dev/define/live-audio/scaffold-skin.css +148 -42
- package/dist/dev/define/live-audio/scaffold-skin2.js +1 -1
- package/dist/dev/define/live-audio/scaffold-skin2.js.map +1 -1
- package/dist/dev/define/live-audio/skin.css +55 -31
- package/dist/dev/define/live-audio/skin2.js +1 -1
- package/dist/dev/define/live-audio/skin2.js.map +1 -1
- package/dist/dev/define/live-video/compat-skin.css +234 -51
- package/dist/dev/define/live-video/compat-skin2.js +1 -1
- package/dist/dev/define/live-video/compat-skin2.js.map +1 -1
- package/dist/dev/define/live-video/neutral-skin.css +300 -46
- package/dist/dev/define/live-video/neutral-skin2.js +1 -1
- package/dist/dev/define/live-video/neutral-skin2.js.map +1 -1
- package/dist/dev/define/live-video/scaffold-skin.css +231 -53
- package/dist/dev/define/live-video/scaffold-skin2.js +1 -1
- package/dist/dev/define/live-video/scaffold-skin2.js.map +1 -1
- package/dist/dev/define/live-video/skin.css +314 -49
- package/dist/dev/define/live-video/skin2.js +1 -1
- package/dist/dev/define/live-video/skin2.js.map +1 -1
- package/dist/dev/define/media/dailymotion-video.d.ts +15 -0
- package/dist/dev/define/media/dailymotion-video.js +13 -0
- package/dist/dev/define/media/dailymotion-video.js.map +1 -0
- package/dist/dev/define/media/mixcloud-audio.d.ts +15 -0
- package/dist/dev/define/media/mixcloud-audio.js +13 -0
- package/dist/dev/define/media/mixcloud-audio.js.map +1 -0
- package/dist/dev/define/media/soundcloud-audio.d.ts +15 -0
- package/dist/dev/define/media/soundcloud-audio.js +13 -0
- package/dist/dev/define/media/soundcloud-audio.js.map +1 -0
- package/dist/dev/define/ui/time-slider-markers.d.ts +8 -0
- package/dist/dev/define/ui/time-slider-markers.js +7 -0
- package/dist/dev/define/ui/time-slider-markers.js.map +1 -0
- package/dist/dev/define/video/compat-skin.css +242 -51
- package/dist/dev/define/video/compat-skin2.js +1 -1
- package/dist/dev/define/video/compat-skin2.js.map +1 -1
- package/dist/dev/define/video/neutral-skin.css +382 -57
- package/dist/dev/define/video/neutral-skin2.js +1 -1
- package/dist/dev/define/video/neutral-skin2.js.map +1 -1
- package/dist/dev/define/video/scaffold-skin.css +240 -53
- package/dist/dev/define/video/scaffold-skin2.js +1 -1
- package/dist/dev/define/video/scaffold-skin2.js.map +1 -1
- package/dist/dev/define/video/skin.css +415 -55
- package/dist/dev/define/video/skin2.js +1 -1
- package/dist/dev/define/video/skin2.js.map +1 -1
- package/dist/dev/extensions/google-analytics/extension.d.ts +52 -0
- package/dist/dev/extensions/google-analytics/extension.js +77 -0
- package/dist/dev/extensions/google-analytics/extension.js.map +1 -0
- package/dist/dev/extensions/google-analytics/index.d.ts +2 -0
- package/dist/dev/extensions/mux-data/extension.d.ts +4 -1
- package/dist/dev/extensions/mux-data/extension.js +7 -2
- package/dist/dev/extensions/mux-data/extension.js.map +1 -1
- package/dist/dev/index.d.ts +5 -4
- package/dist/dev/index.js +3 -1
- package/dist/dev/internal/skins/compat-audio/skin.css +161 -41
- package/dist/dev/internal/skins/compat-audio/template.js +1 -1
- package/dist/dev/internal/skins/compat-audio/template.js.map +1 -1
- package/dist/dev/internal/skins/compat-live-audio/skin.css +143 -41
- package/dist/dev/internal/skins/compat-live-video/skin.css +234 -51
- package/dist/dev/internal/skins/compat-live-video/template.js +2 -0
- package/dist/dev/internal/skins/compat-live-video/template.js.map +1 -1
- package/dist/dev/internal/skins/compat-video/skin.css +242 -51
- package/dist/dev/internal/skins/compat-video/template.js +2 -0
- package/dist/dev/internal/skins/compat-video/template.js.map +1 -1
- package/dist/dev/internal/skins/default-audio/skin.css +72 -34
- package/dist/dev/internal/skins/default-live-audio/skin.css +55 -31
- package/dist/dev/internal/skins/default-live-video/register.js.map +1 -1
- package/dist/dev/internal/skins/default-live-video/skin.css +314 -49
- package/dist/dev/internal/skins/default-live-video/template.js +14 -0
- package/dist/dev/internal/skins/default-live-video/template.js.map +1 -1
- package/dist/dev/internal/skins/default-video/register.d.ts +1 -0
- package/dist/dev/internal/skins/default-video/register.js +3 -0
- package/dist/dev/internal/skins/default-video/register.js.map +1 -1
- package/dist/dev/internal/skins/default-video/skin.css +415 -55
- package/dist/dev/internal/skins/default-video/template.js +33 -5
- package/dist/dev/internal/skins/default-video/template.js.map +1 -1
- package/dist/dev/internal/skins/neutral-audio/skin.css +73 -34
- package/dist/dev/internal/skins/neutral-live-audio/skin.css +56 -31
- package/dist/dev/internal/skins/neutral-live-video/register.js.map +1 -1
- package/dist/dev/internal/skins/neutral-live-video/skin.css +300 -46
- package/dist/dev/internal/skins/neutral-live-video/template.js +14 -0
- package/dist/dev/internal/skins/neutral-live-video/template.js.map +1 -1
- package/dist/dev/internal/skins/neutral-video/register.js.map +1 -1
- package/dist/dev/internal/skins/neutral-video/skin.css +382 -57
- package/dist/dev/internal/skins/neutral-video/template.js +25 -11
- package/dist/dev/internal/skins/neutral-video/template.js.map +1 -1
- package/dist/dev/internal/skins/scaffold-audio/skin.css +166 -42
- package/dist/dev/internal/skins/scaffold-audio/template.js +1 -1
- package/dist/dev/internal/skins/scaffold-audio/template.js.map +1 -1
- package/dist/dev/internal/skins/scaffold-live-audio/skin.css +148 -42
- package/dist/dev/internal/skins/scaffold-live-video/skin.css +231 -53
- package/dist/dev/internal/skins/scaffold-live-video/template.js +2 -0
- package/dist/dev/internal/skins/scaffold-live-video/template.js.map +1 -1
- package/dist/dev/internal/skins/scaffold-video/skin.css +240 -53
- package/dist/dev/internal/skins/scaffold-video/template.js +3 -1
- package/dist/dev/internal/skins/scaffold-video/template.js.map +1 -1
- package/dist/dev/media/background-video/adapter.d.ts +7 -13
- package/dist/dev/media/background-video/adapter.js +13 -35
- package/dist/dev/media/background-video/adapter.js.map +1 -1
- package/dist/dev/media/background-video/base.d.ts +44 -0
- package/dist/dev/media/background-video/base.js +97 -0
- package/dist/dev/media/background-video/base.js.map +1 -0
- package/dist/dev/media/background-video/template.d.ts +3 -0
- package/dist/dev/media/background-video/template.js +13 -20
- package/dist/dev/media/background-video/template.js.map +1 -1
- package/dist/dev/media/dailymotion-video/adapter.d.ts +17 -0
- package/dist/dev/media/dailymotion-video/adapter.js +47 -0
- package/dist/dev/media/dailymotion-video/adapter.js.map +1 -0
- package/dist/dev/media/dailymotion-video/index.d.ts +2 -0
- package/dist/dev/media/hls-background-video/adapter.d.ts +14 -19
- package/dist/dev/media/hls-background-video/adapter.js +23 -35
- package/dist/dev/media/hls-background-video/adapter.js.map +1 -1
- package/dist/dev/media/mixcloud-audio/adapter.d.ts +11 -0
- package/dist/dev/media/mixcloud-audio/adapter.js +52 -0
- package/dist/dev/media/mixcloud-audio/adapter.js.map +1 -0
- package/dist/dev/media/mixcloud-audio/index.d.ts +2 -0
- package/dist/dev/media/soundcloud-audio/adapter.d.ts +11 -0
- package/dist/dev/media/soundcloud-audio/adapter.js +53 -0
- package/dist/dev/media/soundcloud-audio/adapter.js.map +1 -0
- package/dist/dev/media/soundcloud-audio/index.d.ts +2 -0
- package/dist/dev/player/element.js +1 -5
- package/dist/dev/player/element.js.map +1 -1
- package/dist/dev/presets/background/skin.d.ts +2 -1
- package/dist/dev/presets/background/skin.js +2 -2
- package/dist/dev/presets/background/skin.js.map +1 -1
- package/dist/dev/presets/skin.d.ts +4 -3
- package/dist/dev/presets/skin.js +4 -3
- package/dist/dev/presets/skin.js.map +1 -1
- package/dist/dev/ui/captions-button/element.d.ts +2 -0
- package/dist/dev/ui/captions-radio-group/element.d.ts +2 -1
- package/dist/dev/ui/captions-radio-group/element.js +14 -1
- package/dist/dev/ui/captions-radio-group/element.js.map +1 -1
- package/dist/dev/ui/controls/element.d.ts +2 -2
- package/dist/dev/ui/controls/element.js +6 -3
- package/dist/dev/ui/controls/element.js.map +1 -1
- package/dist/dev/ui/dialog/element.js +13 -1
- package/dist/dev/ui/dialog/element.js.map +1 -1
- package/dist/dev/ui/gesture/element.js +3 -0
- package/dist/dev/ui/gesture/element.js.map +1 -1
- package/dist/dev/ui/media-button-element.d.ts +9 -0
- package/dist/dev/ui/media-button-element.js +10 -1
- package/dist/dev/ui/media-button-element.js.map +1 -1
- package/dist/dev/ui/play-button/element.d.ts +2 -0
- package/dist/dev/ui/playback-rate-button/element.d.ts +9 -1
- package/dist/dev/ui/playback-rate-button/element.js +7 -2
- package/dist/dev/ui/playback-rate-button/element.js.map +1 -1
- package/dist/dev/ui/playback-rate-radio-group/element.d.ts +4 -0
- package/dist/dev/ui/playback-rate-radio-group/element.js +10 -3
- package/dist/dev/ui/playback-rate-radio-group/element.js.map +1 -1
- package/dist/dev/ui/radio-options/controller.js +18 -5
- package/dist/dev/ui/radio-options/controller.js.map +1 -1
- package/dist/dev/ui/time-slider/markers.d.ts +48 -0
- package/dist/dev/ui/time-slider/markers.js +165 -0
- package/dist/dev/ui/time-slider/markers.js.map +1 -0
- package/dist/dev/version.js +1 -1
- package/docs/README.md +1 -1
- package/docs/guides/autoplay.md +2 -2
- package/docs/guides/background-video.md +2 -4
- package/docs/guides/browser-support.md +23 -15
- package/docs/guides/build-your-own-skin.md +3 -1
- package/docs/guides/cdn.md +10 -9
- package/docs/guides/content-security-policy.md +3 -0
- package/docs/guides/customize-skins.md +7 -2
- package/docs/guides/features.md +1 -1
- package/docs/guides/google-analytics.md +199 -0
- package/docs/guides/installation-cdn.md +4 -4
- package/docs/guides/installation-shadcn.md +3 -3
- package/docs/guides/installation-svelte.md +4 -4
- package/docs/guides/installation-vue.md +4 -4
- package/docs/guides/installation.md +4 -4
- package/docs/guides/internationalization.md +5 -5
- package/docs/guides/keyboard-shortcuts.md +11 -1
- package/docs/guides/llms.txt +3 -1
- package/docs/guides/media-sources.md +3 -0
- package/docs/guides/migrate-from-media-chrome.md +4 -4
- package/docs/guides/migrate-from-mux-player.md +9 -9
- package/docs/guides/migrate-from-plyr.md +8 -8
- package/docs/guides/migrate-from-video-js-8.md +8 -9
- package/docs/guides/migrate-from-vidstack.md +10 -10
- package/docs/guides/mux-data.md +22 -0
- package/docs/guides/presets.md +5 -5
- package/docs/guides/self-hosting.md +5 -5
- package/docs/guides/skins.md +21 -5
- package/docs/guides/timed-metadata.md +318 -0
- package/docs/guides/ui-components.md +1 -1
- package/docs/llms.txt +25 -6
- package/docs/reference/api/chapters-track.md +71 -0
- package/docs/reference/api/define-text-track.md +113 -0
- package/docs/reference/api/feature-playback-rate.md +54 -3
- package/docs/reference/api/feature-playback.md +5 -1
- package/docs/reference/api/feature-text-cues.md +133 -0
- package/docs/reference/api/feature-text-tracks.md +11 -5
- package/docs/reference/api/get-active-text-cues.md +69 -0
- package/docs/reference/api/get-text-cues.md +69 -0
- package/docs/reference/api/get-text-tracks.md +41 -0
- package/docs/reference/api/hls-metadata-track.md +48 -0
- package/docs/reference/api/html-create-player.md +2 -2
- package/docs/reference/api/llms.txt +13 -1
- package/docs/reference/api/media-capabilities.md +4 -4
- package/docs/reference/api/player-store.md +15 -7
- package/docs/reference/api/preset-audio.md +15 -5
- package/docs/reference/api/preset-background.md +2 -2
- package/docs/reference/api/preset-live-audio.md +15 -5
- package/docs/reference/api/preset-live-video.md +14 -5
- package/docs/reference/api/preset-video.md +14 -5
- package/docs/reference/api/resolve-adapter-type.md +4 -1
- package/docs/reference/api/ui-element.md +2 -2
- package/docs/reference/components/alert-dialog.md +21 -16
- package/docs/reference/components/audio-compat-skin.md +8 -2
- package/docs/reference/components/audio-neutral-skin.md +2 -2
- package/docs/reference/components/audio-scaffold-skin.md +2 -2
- package/docs/reference/components/audio-skin.md +2 -2
- package/docs/reference/components/audio-track-radio-group.md +2 -2
- package/docs/reference/components/audio.md +19 -1
- package/docs/reference/components/background-video-skin.md +1 -1
- package/docs/reference/components/background-video.md +26 -11
- package/docs/reference/components/buffering-indicator.md +2 -2
- package/docs/reference/components/captions-radio-group.md +3 -3
- package/docs/reference/components/cloudflare-video.md +1 -1
- package/docs/reference/components/controls.md +16 -3
- package/docs/reference/components/dailymotion-video.md +192 -0
- package/docs/reference/components/dash-video.md +20 -2
- package/docs/reference/components/dialog.md +49 -22
- package/docs/reference/components/error-dialog.md +13 -10
- package/docs/reference/components/gesture.md +2 -2
- package/docs/reference/components/google-analytics.md +51 -0
- package/docs/reference/components/google-cast.md +1 -1
- package/docs/reference/components/hls-audio.md +56 -2
- package/docs/reference/components/hls-background-video.md +25 -5
- package/docs/reference/components/hls-video.md +99 -7
- package/docs/reference/components/hlsjs-video.md +53 -12
- package/docs/reference/components/hotkey.md +2 -2
- package/docs/reference/components/live-audio-compat-skin.md +8 -2
- package/docs/reference/components/live-audio-neutral-skin.md +2 -2
- package/docs/reference/components/live-audio-scaffold-skin.md +2 -2
- package/docs/reference/components/live-audio-skin.md +2 -2
- package/docs/reference/components/live-video-compat-skin.md +12 -2
- package/docs/reference/components/live-video-neutral-skin.md +6 -2
- package/docs/reference/components/live-video-scaffold-skin.md +6 -2
- package/docs/reference/components/live-video-skin.md +6 -2
- package/docs/reference/components/llms.txt +10 -5
- package/docs/reference/components/mixcloud-audio.md +203 -0
- package/docs/reference/components/mux-audio.md +35 -2
- package/docs/reference/components/mux-background-video.md +1 -1
- package/docs/reference/components/mux-data.md +20 -2
- package/docs/reference/components/mux-video.md +18 -2
- package/docs/reference/components/native-hls-video.md +32 -2
- package/docs/reference/components/play-button.md +7 -5
- package/docs/reference/components/playback-rate-button.md +26 -7
- package/docs/reference/components/playback-rate-radio-group.md +7 -4
- package/docs/reference/components/player.md +3 -3
- package/docs/reference/components/playerjs-video.md +2 -2
- package/docs/reference/components/quality-radio-group.md +2 -2
- package/docs/reference/components/shaka-video.md +2 -2
- package/docs/reference/components/soundcloud-audio.md +227 -0
- package/docs/reference/components/spotify-audio.md +3 -3
- package/docs/reference/components/tiktok-video.md +3 -3
- package/docs/reference/components/time-slider-markers.md +194 -0
- package/docs/reference/components/time-slider.md +14 -0
- package/docs/reference/components/twitch-video.md +2 -3
- package/docs/reference/components/video-compat-skin.md +12 -2
- package/docs/reference/components/video-neutral-skin.md +6 -2
- package/docs/reference/components/video-scaffold-skin.md +6 -2
- package/docs/reference/components/video-skin.md +6 -2
- package/docs/reference/components/video.md +19 -1
- package/docs/reference/components/vimeo-video.md +1 -1
- package/docs/reference/components/wistia-video.md +1 -1
- package/docs/reference/components/youtube-video.md +1 -1
- package/package.json +60 -40
|
@@ -31,8 +31,10 @@ Each feature links to the same entry on its reference page.
|
|
|
31
31
|
| `ended` | `boolean` | [`playbackFeature`](./feature-playback.md#playback-state-ended) | Whether playback has reached the end. |
|
|
32
32
|
| `started` | `boolean` | [`playbackFeature`](./feature-playback.md#playback-state-started) | Whether playback has started (played or seeked). |
|
|
33
33
|
| `waiting` | `boolean` | [`playbackFeature`](./feature-playback.md#playback-state-waiting) | Whether playback is stalled waiting for data. |
|
|
34
|
+
| `autoplay` | `boolean` | [`playbackFeature`](./feature-playback.md#playback-state-autoplay) | Whether the media starts playing on its own once it can. |
|
|
35
|
+
| `autoplaying` | `boolean` | [`playbackFeature`](./feature-playback.md#playback-state-autoplaying) | Whether the media is trying to autoplay: `autoplay` is set, and playback hasn't started yet. Clears when playback starts, when `pause()` cancels it, and when the autoplay is refused. Browsers don't announce a refusal, so it shows as the media being able to play through but staying paused; embeds report one with a `pause` or `error` event. Controls treat it as playback that's about to begin. |
|
|
34
36
|
| `play` | `() => Promise<void>` | [`playbackFeature`](./feature-playback.md#playback-action-play) | Start playback. Updates `paused` immediately when the media starts. |
|
|
35
|
-
| `pause` | `() => void` | [`playbackFeature`](./feature-playback.md#playback-action-pause) | Pause playback. Updates `paused` immediately. |
|
|
37
|
+
| `pause` | `() => void` | [`playbackFeature`](./feature-playback.md#playback-action-pause) | Pause playback. Updates `paused` immediately, and cancels a pending autoplay. |
|
|
36
38
|
| `currentTime` | `number` | [`timeFeature`](./feature-time.md#time-state-currentTime) | Current playback position in seconds. |
|
|
37
39
|
| `duration` | `number` | [`timeFeature`](./feature-time.md#time-state-duration) | Total duration in seconds (0 if unknown). |
|
|
38
40
|
| `seeking` | `boolean` | [`timeFeature`](./feature-time.md#time-state-seeking) | Whether a seek operation is in progress. |
|
|
@@ -53,15 +55,18 @@ Each feature links to the same entry on its reference page.
|
|
|
53
55
|
| `toggleControls` | `(forceShow?: boolean) => boolean` | [`controlsFeature`](./feature-controls.md#controls-action-toggleControls) | Toggle controls visibility, or force it with `forceShow`. Returns the new `controlsVisible` value. |
|
|
54
56
|
| `buffered` | `[number, number][]` | [`bufferFeature`](./feature-buffer.md#buffer-state-buffered) | Buffered time ranges as \[start, end\] tuples. |
|
|
55
57
|
| `seekable` | `[number, number][]` | [`bufferFeature`](./feature-buffer.md#buffer-state-seekable) | Seekable time ranges as \[start, end\] tuples. |
|
|
56
|
-
| `textTrackList` | `MediaTextTrack[]` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-textTrackList) |
|
|
58
|
+
| `textTrackList` | `MediaTextTrack[]` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-textTrackList) | Every text track: the media's, then those the app added through the player. `source` tells them apart. |
|
|
57
59
|
| `subtitlesShowing` | `boolean` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-subtitlesShowing) | Whether a captions/subtitles track is showing. |
|
|
58
|
-
| `chaptersCues` | `MediaTextCue[]` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-chaptersCues) | Cues from the first `kind="chapters"` track, with cue ends clamped to a finite media duration. |
|
|
60
|
+
| `chaptersCues` | `MediaTextCue[]` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-chaptersCues) | Cues from the media's first `kind="chapters"` track, with cue ends clamped to a finite media duration. When the media has none, cues from the first chapters track the app added, where a chapter without an end runs to the next one and the last to the end of the media. |
|
|
59
61
|
| `thumbnailsTrack` | `{ cues: MediaTextCue[]; src: string \| null; crossOrigin: 'anonymous' \| 'use-credentials' \| null } \| null` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-thumbnailsTrack) | The first thumbnails track, or `null` when there is none. |
|
|
62
|
+
| `addTextTrack` | `{ <Cue extends MediaTextCue>(track: TextTrackDefinition<Cue>, content?: TextTrackContent<InferCueValue<Cue>>): TextTrackHandle<InferCueValue<Cue>>; <Value = unknown>(init: TextTrackInit<Value>): TextTrackHandle<Value> }` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-state-addTextTrack) | Add a text track from the app. It works on any media, sits next to the media's tracks in `textTrackList`, and its cues are read like theirs. Like a `<track>` element, it stays until it's removed, through source changes and media swaps. |
|
|
60
63
|
| `toggleSubtitles` | `(forceShow?: boolean) => boolean` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-action-toggleSubtitles) | Toggle captions/subtitles visibility. Showing enables one caption/subtitle track. A track already showing stays selected. Otherwise, selection prefers the last track shown, then a track matching the browser language, then the first available track. Returns whether a track is showing. |
|
|
61
64
|
| `selectSubtitlesTrack` | `(id: string \| null) => void` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-action-selectSubtitlesTrack) | Show the captions/subtitles track with `id`, or turn captions/subtitles off with `null`. |
|
|
62
|
-
| `
|
|
65
|
+
| `removeTextTrack` | `(id: string) => void` | [`textTrackFeature`](./feature-text-tracks.md#textTrack-action-removeTextTrack) | Remove a track the app added. Tracks from the media stay. |
|
|
63
66
|
| `playbackRate` | `number` | [`playbackRateFeature`](./feature-playback-rate.md#playbackRate-state-playbackRate) | Current playback rate. |
|
|
64
|
-
| `
|
|
67
|
+
| `playbackRateAvailability` | `'available' \| 'unavailable' \| 'unsupported'` | [`playbackRateFeature`](./feature-playback-rate.md#playbackRate-state-playbackRateAvailability) | Whether the media can change its playback rate. `unsupported` when the attached media has no `playbackRate` at all, such as an embed whose provider takes no speed command. |
|
|
68
|
+
| `playbackRates` | `readonly number[]` | [`playbackRateFeature`](./feature-playback-rate.md#playbackRate-state-playbackRates) | The default rates that fit the media's range. Set them through the player, not through the store. They are listed even when the media cannot change its rate, so check `playbackRateAvailability` before offering them. |
|
|
69
|
+
| `setPlaybackRate` | `(rate: number) => void` | [`playbackRateFeature`](./feature-playback-rate.md#playbackRate-action-setPlaybackRate) | Set the playback rate, clamped to the rates the media accepts. |
|
|
65
70
|
| `isPictureInPicture` | `boolean` | [`pipFeature`](./feature-pip.md#pip-state-isPictureInPicture) | Whether picture-in-picture mode is currently active. |
|
|
66
71
|
| `pictureInPictureAvailability` | `'available' \| 'unavailable' \| 'unsupported'` | [`pipFeature`](./feature-pip.md#pip-state-pictureInPictureAvailability) | Whether picture-in-picture can be requested on this platform. |
|
|
67
72
|
| `requestPictureInPicture` | `() => Promise<void>` | [`pipFeature`](./feature-pip.md#pip-action-requestPictureInPicture) | Enter picture-in-picture mode, exiting fullscreen first. Rejects before metadata is loaded. |
|
|
@@ -85,6 +90,8 @@ Each feature links to the same entry on its reference page.
|
|
|
85
90
|
| `streamType` | `'on-demand' \| 'live' \| 'unknown'` | [`streamTypeFeature`](./feature-stream-type.md#streamType-state-streamType) | Current stream delivery type. Components use this to show live-specific UI (for example, a live indicator or a "jump to live edge" button) or hide the time display. |
|
|
86
91
|
| `orientationLockType` | `'any' \| 'landscape' \| 'landscape-primary' \| 'landscape-secondary' \| 'natural' \| 'portrait' \| 'portrait-primary' \| 'portrait-secondary'` | [`orientationLockFeature`](./feature-orientation-lock.md#orientationLock-state-orientationLockType) | Screen orientation type locked while fullscreen is active. |
|
|
87
92
|
| `setOrientationLockType` | `(value: 'any' \| 'landscape' \| 'landscape-primary' \| 'landscape-secondary' \| 'natural' \| 'portrait' \| 'portrait-primary' \| 'portrait-secondary' \| null \| undefined) => void` | [`orientationLockFeature`](./feature-orientation-lock.md#orientationLock-action-setOrientationLockType) | Sets the locked orientation type. A missing value, including an empty one, restores the default. |
|
|
93
|
+
| `textCues` | `MediaTrackCues[]` | [`textCuesFeature`](./feature-text-cues.md#textCues-state-textCues) | Cues for the tracks being read: `metadata` and `chapters` tracks that aren't disabled, except the thumbnails track, plus any track a `watchTextCues()` filter matches. In `textTrackList` order. |
|
|
94
|
+
| `watchTextCues` | `(filter: { kind?: TextTrackKind \| readonly TextTrackKind[]; label?: string; language?: string } \| ((track: MediaTextTrack) => boolean)) => (() => void)` | [`textCuesFeature`](./feature-text-cues.md#textCues-action-watchTextCues) | Read cues for more tracks, such as captions for an interactive transcript. Cues are tracked until the returned function is called. |
|
|
88
95
|
|
|
89
96
|
## Features by preset
|
|
90
97
|
|
|
@@ -98,7 +105,7 @@ Each column is a preset's feature bundle. A feature no bundle includes is opt-in
|
|
|
98
105
|
| [`fullscreenFeature`](./feature-fullscreen.md) | ✓ | – | – | ✓ |
|
|
99
106
|
| [`controlsFeature`](./feature-controls.md) | ✓ | – | – | ✓ |
|
|
100
107
|
| [`bufferFeature`](./feature-buffer.md) | ✓ | ✓ | ✓ | ✓ |
|
|
101
|
-
| [`textTrackFeature`](./feature-text-tracks.md) | ✓ |
|
|
108
|
+
| [`textTrackFeature`](./feature-text-tracks.md) | ✓ | ✓ | ✓ | ✓ |
|
|
102
109
|
| [`playbackRateFeature`](./feature-playback-rate.md) | ✓ | ✓ | – | – |
|
|
103
110
|
| [`pipFeature`](./feature-pip.md) | ✓ | – | – | ✓ |
|
|
104
111
|
| [`errorFeature`](./feature-error.md) | ✓ | ✓ | ✓ | ✓ |
|
|
@@ -109,4 +116,5 @@ Each column is a preset's feature bundle. A feature no bundle includes is opt-in
|
|
|
109
116
|
| [`remotePlaybackFeature`](./feature-remote-playback.md) | ✓ | – | – | ✓ |
|
|
110
117
|
| [`liveFeature`](./feature-live.md) | – | – | ✓ | ✓ |
|
|
111
118
|
| [`streamTypeFeature`](./feature-stream-type.md) | – | – | – | – |
|
|
112
|
-
| [`orientationLockFeature`](./feature-orientation-lock.md) | – | – | – | – |
|
|
119
|
+
| [`orientationLockFeature`](./feature-orientation-lock.md) | – | – | – | – |
|
|
120
|
+
| [`textCuesFeature`](./feature-text-cues.md) | ✓ | ✓ | ✓ | ✓ |
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The audio-only preset — a player, feature bundle, skins, and media for on-demand audio
|
|
4
4
|
|
|
5
|
-
`@videojs/html/audio` is the preset for on-demand audio. It bundles the `<audio-player>` element, the `audioFeatures` bundle it is configured with, and
|
|
5
|
+
`@videojs/html/audio` is the preset for on-demand audio. It bundles the `<audio-player>` element, the `audioFeatures` bundle it is configured with, and four skins, and plays through the browser’s native `<audio>`. See [Presets](../../guides/presets.md) for how presets fit together and how to customize one.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -11,13 +11,13 @@ import '@videojs/html/audio/player';
|
|
|
11
11
|
import '@videojs/html/audio/skin';
|
|
12
12
|
```
|
|
13
13
|
|
|
14
|
-
Import `@videojs/html/audio/neutral-skin` instead for
|
|
14
|
+
Import `@videojs/html/audio/neutral-skin`, `compat-skin`, or `scaffold-skin` instead for another skin. Or load one [CDN](../../guides/cdn.md) bundle that registers the player and a skin together:
|
|
15
15
|
|
|
16
16
|
```html
|
|
17
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
17
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/audio.js"></script>
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
-
`audio-neutral.js`
|
|
20
|
+
`audio-neutral.js`, `audio-compat.js`, and `audio-scaffold.js` register the other skins instead, and `audio-player.js` registers `<audio-player>` alone.
|
|
21
21
|
|
|
22
22
|
## Usage
|
|
23
23
|
|
|
@@ -44,7 +44,7 @@ Import `@videojs/html/audio/neutral-skin` instead for the neutral skin. Or load
|
|
|
44
44
|
| --- | --- | --- |
|
|
45
45
|
| `content-title` | `contentTitle` | The title to display. Takes precedence over the title the media reports. |
|
|
46
46
|
| `poster` | `poster` | The poster to display. Takes precedence over the poster the media reports. |
|
|
47
|
-
| `keep-alive` | — | Keeps the player
|
|
47
|
+
| `keep-alive` | — | Keeps the player, its store, and the UI elements inside it alive when the element leaves the DOM. Call `destroy()` when you’re done with it. |
|
|
48
48
|
|
|
49
49
|
`content-title` and `poster` come from the [metadata feature](./feature-metadata.md#player-inputs). The element’s read-only `store` property returns its player store.
|
|
50
50
|
|
|
@@ -62,6 +62,8 @@ The preset root also exports a `PlayerController` bound to the audio player’s
|
|
|
62
62
|
| [`timeFeature`](./feature-time.md) | Playback position and duration state for the player store |
|
|
63
63
|
| [`sourceFeature`](./feature-source.md) | Media source state and actions for the player store |
|
|
64
64
|
| [`bufferFeature`](./feature-buffer.md) | Buffered and seekable time range state for the player store |
|
|
65
|
+
| [`textTrackFeature`](./feature-text-tracks.md) | Subtitles, captions, and chapter track state for the player store |
|
|
66
|
+
| [`textCuesFeature`](./feature-text-cues.md) | Cues and active cues from metadata, chapters, and app text tracks |
|
|
65
67
|
| [`errorFeature`](./feature-error.md) | Media error state and actions for the player store |
|
|
66
68
|
| [`metadataFeature`](./feature-metadata.md) | Resolved title and poster values for the player store |
|
|
67
69
|
|
|
@@ -88,6 +90,10 @@ customElements.define('my-audio-player', PlayerElement);
|
|
|
88
90
|
|
|
89
91
|
- [AudioSkin](../components/audio-skin.md) — the default skin, with the modern, frosted look.
|
|
90
92
|
- [NeutralAudioSkin](../components/audio-neutral-skin.md) — the visually lighter variant, closer to a classic control bar.
|
|
93
|
+
- [CompatAudioSkin](../components/audio-compat-skin.md) — the plain, unbranded variant that avoids newer visual effects, so it looks consistent across browsers.
|
|
94
|
+
- [ScaffoldAudioSkin](../components/audio-scaffold-skin.md) — the minimally styled variant of Compat, a foundation for your own design.
|
|
95
|
+
|
|
96
|
+
See [Choose a skin](../../guides/skins.md#choose-a-skin) to compare them.
|
|
91
97
|
|
|
92
98
|
## Media
|
|
93
99
|
|
|
@@ -104,6 +110,8 @@ The preset root, `@videojs/html/audio`, has no side effects. Importing it never
|
|
|
104
110
|
| `audioFeatures` | The [feature bundle](#feature-bundle). |
|
|
105
111
|
| `AudioSkinElement` | The default [skin](#skins) element class. |
|
|
106
112
|
| `NeutralAudioSkinElement` | The neutral [skin](#skins) element class. |
|
|
113
|
+
| `CompatAudioSkinElement` | The compat [skin](#skins) element class. |
|
|
114
|
+
| `ScaffoldAudioSkinElement` | The scaffold [skin](#skins) element class. |
|
|
107
115
|
|
|
108
116
|
Registration entry points are side-effect-only:
|
|
109
117
|
|
|
@@ -112,5 +120,7 @@ Registration entry points are side-effect-only:
|
|
|
112
120
|
| `@videojs/html/audio/player` | `<audio-player>` |
|
|
113
121
|
| `@videojs/html/audio/skin` | `<audio-skin>`, `<media-container>`, and the UI elements the skin composes |
|
|
114
122
|
| `@videojs/html/audio/neutral-skin` | `<audio-neutral-skin>`, `<media-container>`, and the UI elements the neutral skin composes |
|
|
123
|
+
| `@videojs/html/audio/compat-skin` | `<audio-compat-skin>`, `<media-container>`, and the UI elements the compat skin composes |
|
|
124
|
+
| `@videojs/html/audio/scaffold-skin` | `<audio-scaffold-skin>`, `<media-container>`, and the UI elements the scaffold skin composes |
|
|
115
125
|
| `@videojs/html/audio/ui` | `<media-container>` and the UI elements of the default skin, without the skin, for a layout you write yourself |
|
|
116
126
|
| `@videojs/html/audio/neutral-ui` | `<media-container>` and the UI elements of the neutral skin, without the skin |
|
|
@@ -15,7 +15,7 @@ import '@videojs/html/background/video';
|
|
|
15
15
|
Or load the [CDN](../../guides/cdn.md) bundle that registers all three:
|
|
16
16
|
|
|
17
17
|
```html
|
|
18
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
18
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/background.js"></script>
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
Unlike the other presets, the background preset has one bundle and no player-only bundle.
|
|
@@ -44,7 +44,7 @@ Unlike the other presets, the background preset has one bundle and no player-onl
|
|
|
44
44
|
|
|
45
45
|
| Attribute | Property | Description |
|
|
46
46
|
| --- | --- | --- |
|
|
47
|
-
| `keep-alive` | — | Keeps the player
|
|
47
|
+
| `keep-alive` | — | Keeps the player, its store, and the UI elements inside it alive when the element leaves the DOM. Call `destroy()` when you’re done with it. |
|
|
48
48
|
|
|
49
49
|
The bundle has no feature that takes player inputs, so the element has no player-input attributes such as `content-title` or `poster`; `keep-alive` is the only attribute it reads. Its read-only `store` property returns its player store.
|
|
50
50
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The live audio preset — a player, feature bundle, skins, and media for live audio streams
|
|
4
4
|
|
|
5
|
-
`@videojs/html/live-audio` is the preset for live audio streams. It bundles the `<live-audio-player>` element, the `liveAudioFeatures` bundle it is configured with, and
|
|
5
|
+
`@videojs/html/live-audio` is the preset for live audio streams. It bundles the `<live-audio-player>` element, the `liveAudioFeatures` bundle it is configured with, and four skins that swap the time slider and time displays for a Live button, and plays through the browser’s native `<audio>`. See [Presets](../../guides/presets.md) for how presets fit together and [Live streams](../../guides/live-streams.md) for playing a live source.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -11,13 +11,13 @@ import '@videojs/html/live-audio/player';
|
|
|
11
11
|
import '@videojs/html/live-audio/skin';
|
|
12
12
|
```
|
|
13
13
|
|
|
14
|
-
Import `@videojs/html/live-audio/neutral-skin` instead for
|
|
14
|
+
Import `@videojs/html/live-audio/neutral-skin`, `compat-skin`, or `scaffold-skin` instead for another skin. Or load one [CDN](../../guides/cdn.md) bundle that registers the player and a skin together:
|
|
15
15
|
|
|
16
16
|
```html
|
|
17
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
17
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/live-audio.js"></script>
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
-
`live-audio-neutral.js`
|
|
20
|
+
`live-audio-neutral.js`, `live-audio-compat.js`, and `live-audio-scaffold.js` register the other skins instead, and `live-audio-player.js` registers `<live-audio-player>` alone.
|
|
21
21
|
|
|
22
22
|
## Usage
|
|
23
23
|
|
|
@@ -47,7 +47,7 @@ Live streams are usually HLS, so this example plays through an HLS media compone
|
|
|
47
47
|
| --- | --- | --- |
|
|
48
48
|
| `content-title` | `contentTitle` | The title to display. Takes precedence over the title the media reports. |
|
|
49
49
|
| `poster` | `poster` | The poster to display. Takes precedence over the poster the media reports. |
|
|
50
|
-
| `keep-alive` | — | Keeps the player
|
|
50
|
+
| `keep-alive` | — | Keeps the player, its store, and the UI elements inside it alive when the element leaves the DOM. Call `destroy()` when you’re done with it. |
|
|
51
51
|
|
|
52
52
|
`content-title` and `poster` come from the [metadata feature](./feature-metadata.md#player-inputs). The element’s read-only `store` property returns its player store.
|
|
53
53
|
|
|
@@ -64,6 +64,8 @@ The preset root also exports a `PlayerController` bound to the live audio player
|
|
|
64
64
|
| [`timeFeature`](./feature-time.md) | Playback position and duration state for the player store |
|
|
65
65
|
| [`sourceFeature`](./feature-source.md) | Media source state and actions for the player store |
|
|
66
66
|
| [`bufferFeature`](./feature-buffer.md) | Buffered and seekable time range state for the player store |
|
|
67
|
+
| [`textTrackFeature`](./feature-text-tracks.md) | Subtitles, captions, and chapter track state for the player store |
|
|
68
|
+
| [`textCuesFeature`](./feature-text-cues.md) | Cues and active cues from metadata, chapters, and app text tracks |
|
|
67
69
|
| [`errorFeature`](./feature-error.md) | Media error state and actions for the player store |
|
|
68
70
|
| [`liveFeature`](./feature-live.md) | Live edge state for the player store |
|
|
69
71
|
| [`metadataFeature`](./feature-metadata.md) | Resolved title and poster values for the player store |
|
|
@@ -91,6 +93,10 @@ customElements.define('my-live-audio-player', PlayerElement);
|
|
|
91
93
|
|
|
92
94
|
- [LiveAudioSkin](../components/live-audio-skin.md) — the default skin, which swaps the time controls for a Live button.
|
|
93
95
|
- [NeutralLiveAudioSkin](../components/live-audio-neutral-skin.md) — the visually lighter variant, closer to a classic control bar.
|
|
96
|
+
- [CompatLiveAudioSkin](../components/live-audio-compat-skin.md) — the plain, unbranded variant that avoids newer visual effects, so it looks consistent across browsers.
|
|
97
|
+
- [ScaffoldLiveAudioSkin](../components/live-audio-scaffold-skin.md) — the minimally styled variant of Compat, a foundation for your own design.
|
|
98
|
+
|
|
99
|
+
See [Choose a skin](../../guides/skins.md#choose-a-skin) to compare them.
|
|
94
100
|
|
|
95
101
|
## Media
|
|
96
102
|
|
|
@@ -107,6 +113,8 @@ The preset root, `@videojs/html/live-audio`, has no side effects. Importing it n
|
|
|
107
113
|
| `liveAudioFeatures` | The [feature bundle](#feature-bundle). |
|
|
108
114
|
| `LiveAudioSkinElement` | The default [skin](#skins) element class. |
|
|
109
115
|
| `NeutralLiveAudioSkinElement` | The neutral [skin](#skins) element class. |
|
|
116
|
+
| `CompatLiveAudioSkinElement` | The compat [skin](#skins) element class. |
|
|
117
|
+
| `ScaffoldLiveAudioSkinElement` | The scaffold [skin](#skins) element class. |
|
|
110
118
|
|
|
111
119
|
Registration entry points are side-effect-only:
|
|
112
120
|
|
|
@@ -115,5 +123,7 @@ Registration entry points are side-effect-only:
|
|
|
115
123
|
| `@videojs/html/live-audio/player` | `<live-audio-player>` |
|
|
116
124
|
| `@videojs/html/live-audio/skin` | `<live-audio-skin>`, `<media-container>`, and the UI elements the skin composes |
|
|
117
125
|
| `@videojs/html/live-audio/neutral-skin` | `<live-audio-neutral-skin>`, `<media-container>`, and the UI elements the neutral skin composes |
|
|
126
|
+
| `@videojs/html/live-audio/compat-skin` | `<live-audio-compat-skin>`, `<media-container>`, and the UI elements the compat skin composes |
|
|
127
|
+
| `@videojs/html/live-audio/scaffold-skin` | `<live-audio-scaffold-skin>`, `<media-container>`, and the UI elements the scaffold skin composes |
|
|
118
128
|
| `@videojs/html/live-audio/ui` | `<media-container>` and the UI elements of the default skin, without the skin, for a layout you write yourself |
|
|
119
129
|
| `@videojs/html/live-audio/neutral-ui` | `<media-container>` and the UI elements of the neutral skin, without the skin |
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The live video preset — a player, feature bundle, skins, and media for live video streams
|
|
4
4
|
|
|
5
|
-
`@videojs/html/live-video` is the preset for live video streams. It bundles the `<live-video-player>` element, the `liveVideoFeatures` bundle it is configured with, and
|
|
5
|
+
`@videojs/html/live-video` is the preset for live video streams. It bundles the `<live-video-player>` element, the `liveVideoFeatures` bundle it is configured with, and four skins that swap the time slider and time displays for a Live button, and plays through the browser’s native `<video>`. See [Presets](../../guides/presets.md) for how presets fit together and [Live streams](../../guides/live-streams.md) for playing a live source.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -11,13 +11,13 @@ import '@videojs/html/live-video/player';
|
|
|
11
11
|
import '@videojs/html/live-video/skin';
|
|
12
12
|
```
|
|
13
13
|
|
|
14
|
-
Import `@videojs/html/live-video/neutral-skin` instead for
|
|
14
|
+
Import `@videojs/html/live-video/neutral-skin`, `compat-skin`, or `scaffold-skin` instead for another skin. Or load one [CDN](../../guides/cdn.md) bundle that registers the player and a skin together:
|
|
15
15
|
|
|
16
16
|
```html
|
|
17
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
17
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/live-video.js"></script>
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
-
`live-video-neutral.js`
|
|
20
|
+
`live-video-neutral.js`, `live-video-compat.js`, and `live-video-scaffold.js` register the other skins instead, and `live-video-player.js` registers `<live-video-player>` alone.
|
|
21
21
|
|
|
22
22
|
## Usage
|
|
23
23
|
|
|
@@ -47,7 +47,7 @@ Live streams are usually HLS, so this example plays through an HLS media compone
|
|
|
47
47
|
| --- | --- | --- |
|
|
48
48
|
| `content-title` | `contentTitle` | The title to display. Takes precedence over the title the media reports. |
|
|
49
49
|
| `poster` | `poster` | The poster to display. Takes precedence over the poster the media reports. |
|
|
50
|
-
| `keep-alive` | — | Keeps the player
|
|
50
|
+
| `keep-alive` | — | Keeps the player, its store, and the UI elements inside it alive when the element leaves the DOM. Call `destroy()` when you’re done with it. |
|
|
51
51
|
|
|
52
52
|
`content-title` and `poster` come from the [metadata feature](./feature-metadata.md#player-inputs). The element’s read-only `store` property returns its player store.
|
|
53
53
|
|
|
@@ -69,6 +69,7 @@ The preset root also exports a `PlayerController` bound to the live video player
|
|
|
69
69
|
| [`remotePlaybackFeature`](./feature-remote-playback.md) | Remote playback state and actions for the player store |
|
|
70
70
|
| [`controlsFeature`](./feature-controls.md) | User activity and controls visibility state for the player store |
|
|
71
71
|
| [`textTrackFeature`](./feature-text-tracks.md) | Subtitles, captions, and chapter track state for the player store |
|
|
72
|
+
| [`textCuesFeature`](./feature-text-cues.md) | Cues and active cues from metadata, chapters, and app text tracks |
|
|
72
73
|
| [`errorFeature`](./feature-error.md) | Media error state and actions for the player store |
|
|
73
74
|
| [`liveFeature`](./feature-live.md) | Live edge state for the player store |
|
|
74
75
|
| [`metadataFeature`](./feature-metadata.md) | Resolved title and poster values for the player store |
|
|
@@ -96,6 +97,10 @@ customElements.define('my-live-video-player', PlayerElement);
|
|
|
96
97
|
|
|
97
98
|
- [LiveVideoSkin](../components/live-video-skin.md) — the default skin, which swaps the time controls for a Live button.
|
|
98
99
|
- [NeutralLiveVideoSkin](../components/live-video-neutral-skin.md) — the visually lighter variant, closer to a classic control bar.
|
|
100
|
+
- [CompatLiveVideoSkin](../components/live-video-compat-skin.md) — the plain, unbranded variant that avoids newer visual effects, so it looks consistent across browsers.
|
|
101
|
+
- [ScaffoldLiveVideoSkin](../components/live-video-scaffold-skin.md) — the minimally styled variant of Compat, a foundation for your own design.
|
|
102
|
+
|
|
103
|
+
See [Choose a skin](../../guides/skins.md#choose-a-skin) to compare them.
|
|
99
104
|
|
|
100
105
|
## Media
|
|
101
106
|
|
|
@@ -112,6 +117,8 @@ The preset root, `@videojs/html/live-video`, has no side effects. Importing it n
|
|
|
112
117
|
| `liveVideoFeatures` | The [feature bundle](#feature-bundle). |
|
|
113
118
|
| `LiveVideoSkinElement` | The default [skin](#skins) element class. |
|
|
114
119
|
| `NeutralLiveVideoSkinElement` | The neutral [skin](#skins) element class. |
|
|
120
|
+
| `CompatLiveVideoSkinElement` | The compat [skin](#skins) element class. |
|
|
121
|
+
| `ScaffoldLiveVideoSkinElement` | The scaffold [skin](#skins) element class. |
|
|
115
122
|
|
|
116
123
|
Registration entry points are side-effect-only:
|
|
117
124
|
|
|
@@ -120,5 +127,7 @@ Registration entry points are side-effect-only:
|
|
|
120
127
|
| `@videojs/html/live-video/player` | `<live-video-player>` |
|
|
121
128
|
| `@videojs/html/live-video/skin` | `<live-video-skin>`, `<media-container>`, and the UI elements the skin composes |
|
|
122
129
|
| `@videojs/html/live-video/neutral-skin` | `<live-video-neutral-skin>`, `<media-container>`, and the UI elements the neutral skin composes |
|
|
130
|
+
| `@videojs/html/live-video/compat-skin` | `<live-video-compat-skin>`, `<media-container>`, and the UI elements the compat skin composes |
|
|
131
|
+
| `@videojs/html/live-video/scaffold-skin` | `<live-video-scaffold-skin>`, `<media-container>`, and the UI elements the scaffold skin composes |
|
|
123
132
|
| `@videojs/html/live-video/ui` | `<media-container>` and the UI elements of the default skin, without the skin, for a layout you write yourself |
|
|
124
133
|
| `@videojs/html/live-video/neutral-ui` | `<media-container>` and the UI elements of the neutral skin, without the skin |
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The general-purpose video preset — a player, feature bundle, skins, and media for on-demand video
|
|
4
4
|
|
|
5
|
-
`@videojs/html/video` is the general-purpose preset for on-demand video. It bundles the `<video-player>` element, the `videoFeatures` bundle it is configured with, and
|
|
5
|
+
`@videojs/html/video` is the general-purpose preset for on-demand video. It bundles the `<video-player>` element, the `videoFeatures` bundle it is configured with, and four skins, and plays through the browser’s native `<video>`. See [Presets](../../guides/presets.md) for how presets fit together and how to customize one.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -11,13 +11,13 @@ import '@videojs/html/video/player';
|
|
|
11
11
|
import '@videojs/html/video/skin';
|
|
12
12
|
```
|
|
13
13
|
|
|
14
|
-
Import `@videojs/html/video/neutral-skin` instead for
|
|
14
|
+
Import `@videojs/html/video/neutral-skin`, `compat-skin`, or `scaffold-skin` instead for another skin. Or load one [CDN](../../guides/cdn.md) bundle that registers the player and a skin together:
|
|
15
15
|
|
|
16
16
|
```html
|
|
17
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
17
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/video.js"></script>
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
-
`video-neutral.js`
|
|
20
|
+
`video-neutral.js`, `video-compat.js`, and `video-scaffold.js` register the other skins instead, and `video-player.js` registers `<video-player>` alone.
|
|
21
21
|
|
|
22
22
|
## Usage
|
|
23
23
|
|
|
@@ -44,7 +44,7 @@ Import `@videojs/html/video/neutral-skin` instead for the neutral skin. Or load
|
|
|
44
44
|
| --- | --- | --- |
|
|
45
45
|
| `content-title` | `contentTitle` | The title to display. Takes precedence over the title the media reports. |
|
|
46
46
|
| `poster` | `poster` | The poster to display. Takes precedence over the poster the media reports. |
|
|
47
|
-
| `keep-alive` | — | Keeps the player
|
|
47
|
+
| `keep-alive` | — | Keeps the player, its store, and the UI elements inside it alive when the element leaves the DOM. Call `destroy()` when you’re done with it. |
|
|
48
48
|
|
|
49
49
|
`content-title` and `poster` come from the [metadata feature](./feature-metadata.md#player-inputs). The element’s read-only `store` property returns its player store.
|
|
50
50
|
|
|
@@ -69,6 +69,7 @@ The preset root also exports a `PlayerController` bound to the video player’s
|
|
|
69
69
|
| [`remotePlaybackFeature`](./feature-remote-playback.md) | Remote playback state and actions for the player store |
|
|
70
70
|
| [`controlsFeature`](./feature-controls.md) | User activity and controls visibility state for the player store |
|
|
71
71
|
| [`textTrackFeature`](./feature-text-tracks.md) | Subtitles, captions, and chapter track state for the player store |
|
|
72
|
+
| [`textCuesFeature`](./feature-text-cues.md) | Cues and active cues from metadata, chapters, and app text tracks |
|
|
72
73
|
| [`errorFeature`](./feature-error.md) | Media error state and actions for the player store |
|
|
73
74
|
| [`metadataFeature`](./feature-metadata.md) | Resolved title and poster values for the player store |
|
|
74
75
|
|
|
@@ -95,6 +96,10 @@ customElements.define('my-video-player', PlayerElement);
|
|
|
95
96
|
|
|
96
97
|
- [VideoSkin](../components/video-skin.md) — the default skin, with the modern, frosted look.
|
|
97
98
|
- [NeutralVideoSkin](../components/video-neutral-skin.md) — the visually lighter variant, closer to a classic control bar.
|
|
99
|
+
- [CompatVideoSkin](../components/video-compat-skin.md) — the plain, unbranded variant that avoids newer visual effects, so it looks consistent across browsers.
|
|
100
|
+
- [ScaffoldVideoSkin](../components/video-scaffold-skin.md) — the minimally styled variant of Compat, a foundation for your own design.
|
|
101
|
+
|
|
102
|
+
See [Choose a skin](../../guides/skins.md#choose-a-skin) to compare them.
|
|
98
103
|
|
|
99
104
|
## Media
|
|
100
105
|
|
|
@@ -111,6 +116,8 @@ The preset root, `@videojs/html/video`, has no side effects. Importing it never
|
|
|
111
116
|
| `videoFeatures` | The [feature bundle](#feature-bundle). |
|
|
112
117
|
| `VideoSkinElement` | The default [skin](#skins) element class. |
|
|
113
118
|
| `NeutralVideoSkinElement` | The neutral [skin](#skins) element class. |
|
|
119
|
+
| `CompatVideoSkinElement` | The compat [skin](#skins) element class. |
|
|
120
|
+
| `ScaffoldVideoSkinElement` | The scaffold [skin](#skins) element class. |
|
|
114
121
|
|
|
115
122
|
Registration entry points are side-effect-only:
|
|
116
123
|
|
|
@@ -119,5 +126,7 @@ Registration entry points are side-effect-only:
|
|
|
119
126
|
| `@videojs/html/video/player` | `<video-player>` |
|
|
120
127
|
| `@videojs/html/video/skin` | `<video-skin>`, `<media-container>`, and the UI elements the skin composes |
|
|
121
128
|
| `@videojs/html/video/neutral-skin` | `<video-neutral-skin>`, `<media-container>`, and the UI elements the neutral skin composes |
|
|
129
|
+
| `@videojs/html/video/compat-skin` | `<video-compat-skin>`, `<media-container>`, and the UI elements the compat skin composes |
|
|
130
|
+
| `@videojs/html/video/scaffold-skin` | `<video-scaffold-skin>`, `<media-container>`, and the UI elements the scaffold skin composes |
|
|
122
131
|
| `@videojs/html/video/ui` | `<media-container>` and the UI elements of the default skin, without the skin, for a layout you write yourself |
|
|
123
132
|
| `@videojs/html/video/neutral-ui` | `<media-container>` and the UI elements of the neutral skin, without the skin |
|
|
@@ -47,8 +47,11 @@ Each media module you import adds its engine to your bundle, so import the rarel
|
|
|
47
47
|
| `mux` | `stream.mux.com` stream URLs, with or without `.m3u8` | `<mux-video>` or `<mux-audio>` |
|
|
48
48
|
| `cloudflare` | `cloudflarestream.com` and `videodelivery.net` URLs | `<cloudflare-video>` |
|
|
49
49
|
| `spotify` | `open.spotify.com` URLs and `spotify:` URIs | `<spotify-audio>` |
|
|
50
|
+
| `soundcloud` | `soundcloud.com` track and set URLs, `api.soundcloud.com` tracks and playlists, and `w.soundcloud.com/player/` embed URLs | `<soundcloud-audio>` |
|
|
51
|
+
| `mixcloud` | `mixcloud.com` show URLs and Mixcloud widget embed URLs | `<mixcloud-audio>` |
|
|
50
52
|
| `tiktok` | `tiktok.com` video URLs | `<tiktok-video>` |
|
|
51
53
|
| `twitch` | `twitch.tv` video and channel URLs | `<twitch-video>` |
|
|
54
|
+
| `dailymotion` | `dailymotion.com` video and embed URLs, `dai.ly` short links, and `geo.dailymotion.com` player embed URLs | `<dailymotion-video>` |
|
|
52
55
|
| `hls` | `.m3u8` files and HLS MIME types | `<hls-video>`, `<hlsjs-video>`, or `<native-hls-video>` |
|
|
53
56
|
| `dash` | `.mpd` files and `application/dash+xml` | `<dash-video>` or `<shaka-video>` |
|
|
54
57
|
| `video` | `.mp4`, `.webm`, `.mov`, and `.ogv` files, and `video/*` MIME types | `<video>` |
|
|
@@ -95,4 +98,4 @@ A bare id returns `null`. An 11-character YouTube id and a 10-character Wistia i
|
|
|
95
98
|
|
|
96
99
|
| Type |
|
|
97
100
|
| --- |
|
|
98
|
-
| `'youtube' \| 'vimeo' \| 'wistia' \| 'mux' \| 'cloudflare' \| 'spotify' \| 'tiktok' \| 'twitch' \| 'hls' \| 'dash' \| 'video' \| 'audio' \| null` |
|
|
101
|
+
| `'youtube' \| 'vimeo' \| 'wistia' \| 'mux' \| 'cloudflare' \| 'spotify' \| 'soundcloud' \| 'mixcloud' \| 'tiktok' \| 'twitch' \| 'dailymotion' \| 'hls' \| 'dash' \| 'video' \| 'audio' \| null` |
|
|
@@ -165,7 +165,7 @@ class ClockController implements ReactiveController {
|
|
|
165
165
|
|
|
166
166
|
## Destruction
|
|
167
167
|
|
|
168
|
-
When the element disconnects, it waits two animation frames and then destroys itself if it is still disconnected. Moving the element within the document, or a framework reordering it, therefore keeps it alive. Destruction calls `hostDestroyed()` on every controller. A destroyed element stops updating and ignores later connections.
|
|
168
|
+
When the element disconnects, it waits two animation frames and then destroys itself if it is still disconnected. Moving the element within the document, or a framework reordering it, therefore keeps it alive. Destruction first destroys the UI elements inside the element, including those in its shadow root, then calls `hostDestroyed()` on every controller. A destroyed element stops updating and ignores later connections.
|
|
169
169
|
|
|
170
170
|
| Member | Description |
|
|
171
171
|
| --- | --- |
|
|
@@ -173,7 +173,7 @@ When the element disconnects, it waits two animation frames and then destroys it
|
|
|
173
173
|
| `destroyed` | `true` after destruction. |
|
|
174
174
|
| `destroyCallback()` | Runs once on destruction. Override it, calling `super.destroyCallback()`, to release resources the element owns. |
|
|
175
175
|
|
|
176
|
-
Add the `keep-alive` attribute to skip automatic destruction, for example when you detach an element and insert it again later. Call `destroy()` yourself when you are done with it.
|
|
176
|
+
Add the `keep-alive` attribute to the element or one of its ancestors to skip automatic destruction, for example when you detach an element and insert it again later. Destroying an ancestor still destroys it. Call `destroy()` yourself when you are done with it.
|
|
177
177
|
|
|
178
178
|
Release listeners and observers that the element starts on connection in `disconnectedCallback()`, calling `super.disconnectedCallback()`, because an element can connect and disconnect many times before it is destroyed.
|
|
179
179
|
|
|
@@ -45,6 +45,7 @@ Use the open and transition data attributes to style visibility and animations:
|
|
|
45
45
|
| `data-open` | Present while the dialog is open, including its closing transition |
|
|
46
46
|
| `data-starting-style` | Present at the start of the opening transition |
|
|
47
47
|
| `data-ending-style` | Present during the closing transition |
|
|
48
|
+
| `data-scope` | `player` inside a player, `document` outside one |
|
|
48
49
|
|
|
49
50
|
```css
|
|
50
51
|
media-dialog-backdrop:not([data-open]),
|
|
@@ -62,7 +63,7 @@ media-dialog-popup[data-ending-style] {
|
|
|
62
63
|
|
|
63
64
|
## Accessibility
|
|
64
65
|
|
|
65
|
-
The dialog uses `role="alertdialog"
|
|
66
|
+
The dialog uses `role="alertdialog"`, plus `aria-modal="true"` outside a player. Like [Dialog](./dialog.md), it is confined to its player when rendered inside one and modal for the whole page otherwise. The title and description receive generated IDs that are connected with `aria-labelledby` and `aria-describedby`. Focus moves into the dialog when it opens, stays within it while open, and returns to the previously focused element when it closes. Content outside the dialog, within its player or the page, is inert while it is open. Pressing Escape closes the dialog.
|
|
66
67
|
|
|
67
68
|
## Examples
|
|
68
69
|
|
|
@@ -217,6 +218,7 @@ State is reflected as data attributes for CSS styling.
|
|
|
217
218
|
| `status` | `'idle' \| 'starting' \| 'ending'` | Current phase of the transition lifecycle. |
|
|
218
219
|
| `titleId` | `string \| undefined` | Element ID of the dialog title, used for `aria-labelledby`. |
|
|
219
220
|
| `descriptionId` | `string \| undefined` | Element ID of the dialog description, used for `aria-describedby`. |
|
|
221
|
+
| `scope` | `'player' \| 'document'` | `player` when the dialog is rendered inside a player and confined to it, otherwise `document`. |
|
|
220
222
|
|
|
221
223
|
#### Events
|
|
222
224
|
|
|
@@ -231,11 +233,12 @@ Presentational backdrop that reflects its owning dialog's state.
|
|
|
231
233
|
|
|
232
234
|
#### Data attributes
|
|
233
235
|
|
|
234
|
-
| Attribute | Description |
|
|
235
|
-
| --- | --- |
|
|
236
|
-
| `data-open` | Present when the dialog is open. |
|
|
237
|
-
| `data-starting-style` | Present during the open transition. |
|
|
238
|
-
| `data-ending-style` | Present during the close transition. |
|
|
236
|
+
| Attribute | Type | Description |
|
|
237
|
+
| --- | --- | --- |
|
|
238
|
+
| `data-open` | — | Present when the dialog is open. |
|
|
239
|
+
| `data-starting-style` | — | Present during the open transition. |
|
|
240
|
+
| `data-ending-style` | — | Present during the close transition. |
|
|
241
|
+
| `data-scope` | `'player' \| 'document'` | `player` when the dialog is confined to its player, otherwise `document`. |
|
|
239
242
|
|
|
240
243
|
### media-dialog-close
|
|
241
244
|
|
|
@@ -243,11 +246,12 @@ Button that closes its owning dialog; the element itself takes `role="button"` a
|
|
|
243
246
|
|
|
244
247
|
#### Data attributes
|
|
245
248
|
|
|
246
|
-
| Attribute | Description |
|
|
247
|
-
| --- | --- |
|
|
248
|
-
| `data-open` | Present when the dialog is open. |
|
|
249
|
-
| `data-starting-style` | Present during the open transition. |
|
|
250
|
-
| `data-ending-style` | Present during the close transition. |
|
|
249
|
+
| Attribute | Type | Description |
|
|
250
|
+
| --- | --- | --- |
|
|
251
|
+
| `data-open` | — | Present when the dialog is open. |
|
|
252
|
+
| `data-starting-style` | — | Present during the open transition. |
|
|
253
|
+
| `data-ending-style` | — | Present during the close transition. |
|
|
254
|
+
| `data-scope` | `'player' \| 'document'` | `player` when the dialog is confined to its player, otherwise `document`. |
|
|
251
255
|
|
|
252
256
|
### media-dialog-description
|
|
253
257
|
|
|
@@ -259,11 +263,12 @@ Semantic popup that owns focus management and dialog transition completion.
|
|
|
259
263
|
|
|
260
264
|
#### Data attributes
|
|
261
265
|
|
|
262
|
-
| Attribute | Description |
|
|
263
|
-
| --- | --- |
|
|
264
|
-
| `data-open` | Present when the dialog is open. |
|
|
265
|
-
| `data-starting-style` | Present during the open transition. |
|
|
266
|
-
| `data-ending-style` | Present during the close transition. |
|
|
266
|
+
| Attribute | Type | Description |
|
|
267
|
+
| --- | --- | --- |
|
|
268
|
+
| `data-open` | — | Present when the dialog is open. |
|
|
269
|
+
| `data-starting-style` | — | Present during the open transition. |
|
|
270
|
+
| `data-ending-style` | — | Present during the close transition. |
|
|
271
|
+
| `data-scope` | `'player' \| 'document'` | `player` when the dialog is confined to its player, otherwise `document`. |
|
|
267
272
|
|
|
268
273
|
### media-dialog-title
|
|
269
274
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# audio-compat-skin
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
The audio preset's plain, unbranded skin, a polished step above native controls
|
|
4
4
|
|
|
5
|
-
The Compat skin of the audio preset
|
|
5
|
+
The Compat skin of the audio preset: the same core controls with plain, unbranded surfaces that avoid newer visual effects such as backdrop blur. Its time slider supports chapter segments and thumbnail previews, and it adds captions and AirPlay buttons that the default audio skin leaves out. The preset also provides [AudioSkin](./audio-skin.md), [NeutralAudioSkin](./audio-neutral-skin.md), and [ScaffoldAudioSkin](./audio-scaffold-skin.md). See [Skins](../../guides/skins.md#choose-a-skin) to choose between them and [Customize skins](../../guides/customize-skins.md) to install and edit its source.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -10,6 +10,12 @@ The Compat skin of the audio preset provides basic controls and plain surfaces,
|
|
|
10
10
|
import '@videojs/html/audio/compat-skin';
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
+
The import registers the skin and every UI element it composes. The [CDN](../../guides/cdn.md) player bundle registers this skin together with its player:
|
|
14
|
+
|
|
15
|
+
```html
|
|
16
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/audio-compat.js"></script>
|
|
17
|
+
```
|
|
18
|
+
|
|
13
19
|
## Anatomy
|
|
14
20
|
|
|
15
21
|
The skin goes between the player and the media component. It renders its controls around the media.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The audio preset's visually lighter skin, closer to a classic control bar
|
|
4
4
|
|
|
5
|
-
The neutral skin of the audio preset: the same player and the same controls in a visually lighter design, closer to a classic control bar. [AudioSkin](./audio-skin.md)
|
|
5
|
+
The neutral skin of the audio preset: the same player and the same controls in a visually lighter design, closer to a classic control bar. The preset also provides [AudioSkin](./audio-skin.md), [CompatAudioSkin](./audio-compat-skin.md), and [ScaffoldAudioSkin](./audio-scaffold-skin.md). See [Skins](../../guides/skins.md#choose-a-skin) to choose between them and [Presets](../../guides/presets.md) for what the audio preset ships.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -13,7 +13,7 @@ import '@videojs/html/audio/neutral-skin';
|
|
|
13
13
|
The import registers the skin and every UI element it composes. The [CDN](../../guides/cdn.md) player bundle registers this skin together with its player:
|
|
14
14
|
|
|
15
15
|
```html
|
|
16
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
16
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/audio-neutral.js"></script>
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
## Anatomy
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
An audio skin with minimal styling for custom skins
|
|
4
4
|
|
|
5
|
-
The Scaffold skin of the audio preset provides functional controls with minimal styling and no transitions. It is a starting point for a custom skin, intended to be restyled before use. Its time slider supports chapter segments and thumbnail previews. See [Customize skins](../../guides/customize-skins.md) to install and edit its source.
|
|
5
|
+
The Scaffold skin of the audio preset provides functional controls with minimal styling and no transitions. It is a starting point for a custom skin, intended to be restyled before use. Its time slider supports chapter segments and thumbnail previews. The preset also provides [AudioSkin](./audio-skin.md), [NeutralAudioSkin](./audio-neutral-skin.md), and [CompatAudioSkin](./audio-compat-skin.md). See [Skins](../../guides/skins.md#choose-a-skin) to choose between them and [Customize skins](../../guides/customize-skins.md) to install and edit its source.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -13,7 +13,7 @@ import '@videojs/html/audio/scaffold-skin';
|
|
|
13
13
|
The import registers the skin and every UI element it composes. The [CDN](../../guides/cdn.md) player bundle registers this skin together with its player:
|
|
14
14
|
|
|
15
15
|
```html
|
|
16
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
16
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/audio-scaffold.js"></script>
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
## Usage
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The audio preset's default skin with the modern, frosted look
|
|
4
4
|
|
|
5
|
-
The default skin of the audio preset: the control layout for on-demand audio with the modern, frosted look. [NeutralAudioSkin](./audio-neutral-skin.md)
|
|
5
|
+
The default skin of the audio preset: the control layout for on-demand audio with the modern, frosted look. The preset also provides [NeutralAudioSkin](./audio-neutral-skin.md), [CompatAudioSkin](./audio-compat-skin.md), and [ScaffoldAudioSkin](./audio-scaffold-skin.md). See [Skins](../../guides/skins.md#choose-a-skin) to choose between them and [Presets](../../guides/presets.md) for what the audio preset ships.
|
|
6
6
|
|
|
7
7
|
## Import
|
|
8
8
|
|
|
@@ -13,7 +13,7 @@ import '@videojs/html/audio/skin';
|
|
|
13
13
|
The import registers the skin and every UI element it composes. The [CDN](../../guides/cdn.md) player bundle registers this skin together with its player:
|
|
14
14
|
|
|
15
15
|
```html
|
|
16
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.
|
|
16
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@videojs/cdn@10.4.0/audio.js"></script>
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
## Anatomy
|
|
@@ -204,7 +204,7 @@ State is reflected as data attributes for CSS styling.
|
|
|
204
204
|
| `options` | `readonly Option[]` | Ordered options displayed by platform adapters. |
|
|
205
205
|
| `disabled` | `boolean` | Whether the entire option group is disabled. |
|
|
206
206
|
| `hidden` | `boolean` | Whether the option group is hidden because no meaningful selection is available. |
|
|
207
|
-
| `availability` | `'available' \| 'unavailable'` | Whether the media exposes a meaningful selection. |
|
|
207
|
+
| `availability` | `'available' \| 'unavailable' \| 'unsupported'` | Whether the media exposes a meaningful selection. `unsupported` when the media has no such capability at all. |
|
|
208
208
|
|
|
209
209
|
#### Data attributes
|
|
210
210
|
|
|
@@ -213,7 +213,7 @@ State is reflected as data attributes for CSS styling.
|
|
|
213
213
|
| `data-audio-track` | `string` | Current audio track value. |
|
|
214
214
|
| `data-disabled` | — | Present when audio track selection is disabled. |
|
|
215
215
|
| `data-hidden` | — | Present when audio track selection is unavailable. |
|
|
216
|
-
| `data-availability` | `'available' \| 'unavailable'` | Indicates audio track availability (`available` or `unavailable`). |
|
|
216
|
+
| `data-availability` | `'available' \| 'unavailable' \| 'unsupported'` | Indicates audio track availability (`available` or `unavailable`). |
|
|
217
217
|
|
|
218
218
|
#### Events
|
|
219
219
|
|