# Player-Controls Contract This document is the canonical reference for IPTVnator's additive, engine-agnostic player-controls contract and shared default controls. Embedded MPV rendering and native-view bounds behavior remain documented in [embedded-mpv-native.md](./embedded-mpv-native.md). ## Current status The shared-controls preference checkbox is visible only when HTML5, Video.js or ArtPlayer is selected in Settings → Playback. The shared-controls foundation supports four runtime consumers and includes: - the `PlayerController` contract, default state, and capability presets; - the standalone `app-player-controls` presentation component and its transient-state collaborators; - a generic `WebVideoControlsAdapter` plus small host helpers; - standard element picture-in-picture through that adapter for the guarded web consumers; - a persisted, default-on web-player preference (opt-out) resolved through an immutable per-host rollout token; - the component-scoped `EmbeddedMpvControlsAdapter`; - an `EmbeddedMpvPlayerComponent` host integration for the frame-copy engine; - a preference-guarded `HtmlVideoPlayerComponent` integration backed by `WebVideoControlsAdapter` and a player-local engine bridge; - a preference-guarded `VjsPlayerComponent` integration backed by a component-scoped `WebVideoControlsAdapter` and Video.js bridge; - a preference-guarded `ArtPlayerComponent` integration backed by a component-scoped `WebVideoControlsAdapter`, neutral web-video source bridge, and player-local source/video sessions; and - focused unit/component tests. When Embedded MPV reports `engine: 'frame-copy'`, the component mounts `app-player-controls` over the DOM canvas and routes state and commands through `EmbeddedMpvControlsAdapter`. When it reports the native-view engine, the component keeps the existing compositor-safe controls dock. Exactly one of those control systems is active at a time. When `WEB_PLAYER_SHARED_CONTROLS` is enabled, the built-in HTML5 player mounts the same presentation component over its real player shell and disables the native video controls. Its neutral source bridge supplies HLS/Shaka/native tracks, corrected MPEG-TS VOD duration, and authoritative live/VOD metadata to the generic web adapter. When the host token resolves to false, the native controls and legacy series navigation remain unchanged and the adapter is not attached. Video.js consumes the same token and shared presentation atomically. Its bridge binds the adapter to the current Video.js Tech `