-
Notifications
You must be signed in to change notification settings - Fork 7
Closed
Description
Update core/dom features to use PlayerTarget pattern with availability states.
Ref #320
Scope
| Component | Description |
|---|---|
PlayerTarget type |
{ media: Media, container: MediaContainer | null } |
FeatureAvailability |
'available' | 'unavailable' | 'unsupported' |
| Update features | All features use PlayerTarget instead of HTMLMediaElement |
| Volume availability | Add volumeAvailability state with iOS Safari check |
| Feature bundles | video and audio feature arrays |
| Pre-built selectors | selectPlayback, selectVolume, selectTime, selectSource, selectBuffer |
Key Types
interface PlayerTarget {
media: Media;
container: MediaContainer | null;
}
type FeatureAvailability = 'available' | 'unavailable' | 'unsupported';Files
packages/core/src/dom/types.ts(new)packages/core/src/dom/store/features/playback.tspackages/core/src/dom/store/features/volume.tspackages/core/src/dom/store/features/time.tspackages/core/src/dom/store/features/source.tspackages/core/src/dom/store/features/buffer.tspackages/core/src/dom/store/features/bundles.ts(new)packages/core/src/dom/store/selectors.ts(new)- Tests for all above
Acceptance Criteria
-
PlayerTargetandFeatureAvailabilitytypes exported from@videojs/core/dom - All features updated to use
target.mediainstead oftarget - Volume feature exposes
volumeAvailabilitystate -
features.videoandfeatures.audiobundles exported - Pre-built selectors exported:
selectPlayback,selectVolume, etc. - All tests pass
SP: 2
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Done