Skip to content

Commit 647d6fb

Browse files
committed
Add the media session and audio session APIs
1 parent df7185d commit 647d6fb

File tree

4 files changed

+94
-0
lines changed

4 files changed

+94
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Generated from: audio-session.yml
2+
# Do not edit this file by hand. Edit the source file instead!
3+
4+
name: Audio session
5+
description: The `navigator.audioSession` object controls how audio playback interacts with other applications. For example, playing music can pause audio from other applications, while ambient audio can play at the same time.
6+
spec: https://w3c.github.io/audio-session/
7+
status:
8+
baseline: false
9+
support:
10+
safari: "16.4"
11+
safari_ios: "16.4"
12+
compat_features:
13+
- api.AudioSession
14+
- api.AudioSession.type
15+
- api.Navigator.audioSession
16+
# The state property and statechange event are not shipping in any browser,
17+
# but are behind a flag in WebKit:
18+
# https://github.com/WebKit/WebKit/blob/28c4f3c12025bbe9f6c44e48b72c112c4c115bc3/Source/WebCore/Modules/audiosession/DOMAudioSession.idl#L50-L51
19+
# - api.AudioSession.state
20+
# - api.AudioSession.statechange_event
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: Audio session
2+
description: The `navigator.audioSession` object controls how audio playback interacts with other applications. For example, playing music can pause audio from other applications, while ambient audio can play at the same time.
3+
spec: https://w3c.github.io/audio-session/
4+
compat_features:
5+
- api.AudioSession
6+
- api.AudioSession.type
7+
- api.Navigator.audioSession
8+
# The state property and statechange event are not shipping in any browser,
9+
# but are behind a flag in WebKit:
10+
# https://github.com/WebKit/WebKit/blob/28c4f3c12025bbe9f6c44e48b72c112c4c115bc3/Source/WebCore/Modules/audiosession/DOMAudioSession.idl#L50-L51
11+
# - api.AudioSession.state
12+
# - api.AudioSession.statechange_event
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Generated from: media-session.yml
2+
# Do not edit this file by hand. Edit the source file instead!
3+
4+
name: Media session
5+
description: The `navigator.mediaSession` object integrates with platform UI for media playback. It can be used to set metadata such as title and artwork, and to handle user actions like playing, pausing, or seeking.
6+
spec: https://w3c.github.io/mediasession/
7+
usage_stats: https://chromestatus.com/metrics/feature/timeline/popularity/1789
8+
status:
9+
baseline: false
10+
support:
11+
chrome: "73"
12+
chrome_android: "57"
13+
edge: "79"
14+
firefox: "82"
15+
safari: "15"
16+
safari_ios: "15"
17+
compat_features:
18+
# This is the subset of what was initially supported. Newer parts could be
19+
# included with editorial override, or as new features.
20+
- api.MediaMetadata
21+
- api.MediaMetadata.album
22+
- api.MediaMetadata.artist
23+
- api.MediaMetadata.artwork
24+
- api.MediaMetadata.MediaMetadata
25+
- api.MediaMetadata.title
26+
- api.MediaSession
27+
- api.MediaSession.metadata
28+
- api.MediaSession.playbackState
29+
# TODO: include after https://github.com/mdn/browser-compat-data/pull/22793
30+
# - api.MediaSession.setActionHandler
31+
- api.MediaSession.setActionHandler.nexttrack_type
32+
- api.MediaSession.setActionHandler.pause_type
33+
- api.MediaSession.setActionHandler.play_type
34+
- api.MediaSession.setActionHandler.previoustrack_type
35+
- api.MediaSession.setActionHandler.seekbackward_type
36+
- api.MediaSession.setActionHandler.seekforward_type
37+
- api.Navigator.mediaSession
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Media session
2+
description: The `navigator.mediaSession` object integrates with platform UI for media playback. It can be used to set metadata such as title and artwork, and to handle user actions like playing, pausing, or seeking.
3+
spec: https://w3c.github.io/mediasession/
4+
usage_stats: https://chromestatus.com/metrics/feature/timeline/popularity/1789
5+
compat_features:
6+
# This is the subset of what was initially supported. Newer parts could be
7+
# included with editorial override, or as new features.
8+
- api.MediaMetadata
9+
- api.MediaMetadata.album
10+
- api.MediaMetadata.artist
11+
- api.MediaMetadata.artwork
12+
- api.MediaMetadata.MediaMetadata
13+
- api.MediaMetadata.title
14+
- api.MediaSession
15+
- api.MediaSession.metadata
16+
- api.MediaSession.playbackState
17+
# TODO: include after https://github.com/mdn/browser-compat-data/pull/22793
18+
# - api.MediaSession.setActionHandler
19+
- api.MediaSession.setActionHandler.nexttrack_type
20+
- api.MediaSession.setActionHandler.pause_type
21+
- api.MediaSession.setActionHandler.play_type
22+
- api.MediaSession.setActionHandler.previoustrack_type
23+
- api.MediaSession.setActionHandler.seekbackward_type
24+
- api.MediaSession.setActionHandler.seekforward_type
25+
- api.Navigator.mediaSession

0 commit comments

Comments
 (0)