fugu-api-data 1.10.0 → 1.12.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.
Files changed (3) hide show
  1. package/package.json +2 -2
  2. package/patterns.js +456 -454
  3. package/patterns.mjs +456 -454
package/patterns.js CHANGED
@@ -1,41 +1,19 @@
1
1
  const patterns = {
2
- 'Service Worker': {
3
- regEx: /navigator\.serviceWorker\.register\s*\(/g,
4
- where: 'JavaScript',
5
- supported: (async () => 'serviceWorker' in navigator)(),
6
- featureDetection: `(async () => 'serviceWorker' in navigator)()`,
7
- documentation:
8
- 'https://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API',
9
- blinkFeatureID: 990,
10
- },
11
- 'Cache Storage': {
12
- regEx: /caches\.open\s*\(/g,
13
- where: 'JavaScript',
14
- supported: (async () => 'serviceWorker' in navigator && 'caches' in self)(),
15
- featureDetection: `(async () => 'serviceWorker' in navigator && 'caches' in self)()`,
16
- documentation:
17
- 'https://developer.mozilla.org/en-US/docs/Web/API/CacheStorage',
18
- blinkFeatureID: 3022,
19
- },
20
- 'Push': {
21
- regEx: /\.pushManager\.subscribe\s*\(/g,
2
+ 'Absolute Orientation Sensor': {
3
+ regEx: /new\s+AbsoluteOrientationSensor\s*\(/g,
22
4
  where: 'JavaScript',
23
- supported: (async () =>
24
- 'serviceWorker' in navigator &&
25
- 'pushManager' in
26
- ((await navigator.serviceWorker?.ready) || self.registration))(),
27
- featureDetection: `(async () => 'serviceWorker' in navigator && 'pushManager' in (await navigator.serviceWorker?.ready || self.registration))()`,
28
- documentation: 'https://developer.mozilla.org/en-US/docs/Web/API/Push_API',
29
- blinkFeatureID: 769,
5
+ supported: (async () => 'AbsoluteOrientationSensor' in self)(),
6
+ featureDetection: `(async () => 'AbsoluteOrientationSensor' in self)()`,
7
+ documentation: 'https://web.dev/generic-sensor/',
8
+ blinkFeatureID: 1900,
30
9
  },
31
- 'HapticsDevice': {
32
- regEx: /\.haptics\.play\s*\(/g,
10
+ 'Accelerometer': {
11
+ regEx: /new\s+Accelerometer\s*\(/g,
33
12
  where: 'JavaScript',
34
- supported: (async () => 'HapticsDevice' in self)(),
35
- featureDetection: `(async () => 'HapticsDevice' in self)()`,
36
- documentation:
37
- 'https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/HapticsDevice/explainer.md',
38
- blinkFeatureID: undefined,
13
+ supported: (async () => 'Accelerometer' in self)(),
14
+ featureDetection: `(async () => 'Accelerometer' in self)()`,
15
+ documentation: 'https://web.dev/generic-sensor/',
16
+ blinkFeatureID: 1899,
39
17
  },
40
18
  'Add to Home Screen': {
41
19
  regEx: /["']beforeinstallprompt["']|\.onbeforeinstallprompt/g,
@@ -46,17 +24,31 @@ const patterns = {
46
24
  'https://developer.mozilla.org/en-US/docs/Web/API/BeforeInstallPromptEvent',
47
25
  blinkFeatureID: 1436,
48
26
  },
49
- 'Background Sync': {
50
- regEx: /\.sync\.register\s*\(["']/g,
27
+ 'Ambient Light Sensor': {
28
+ regEx: /new\s+AmbientLightSensor\s*\(\)/g,
29
+ where: 'JavaScript',
30
+ supported: (async () => 'AmbientLightSensor' in self)(),
31
+ featureDetection: `(async () => 'AmbientLightSensor' in self)()`,
32
+ documentation: 'https://web.dev/generic-sensor/',
33
+ blinkFeatureID: 1901,
34
+ },
35
+ 'Async Clipboard': {
36
+ regEx: /navigator\.clipboard\.writeText\s*\(/g,
51
37
  where: 'JavaScript',
52
38
  supported: (async () =>
53
- 'serviceWorker' in navigator &&
54
- 'sync' in
55
- ((await navigator.serviceWorker?.ready) || self.registration))(),
56
- featureDetection: `(async () => 'serviceWorker' in navigator && 'sync' in (await navigator.serviceWorker?.ready || self.registration))()`,
57
- documentation:
58
- 'https://developer.mozilla.org/en-US/docs/Web/API/Background_Synchronization_API',
59
- blinkFeatureID: 745,
39
+ 'clipboard' in navigator && 'writeText' in navigator.clipboard)(),
40
+ featureDetection: `(async () => 'clipboard' in navigator && 'writeText' in navigator.clipboard)()`,
41
+ documentation: 'https://web.dev/async-clipboard/',
42
+ blinkFeatureID: 2372,
43
+ },
44
+ 'Async Clipboard (Images)': {
45
+ regEx: /navigator\.clipboard\.write\s*\(/g,
46
+ where: 'JavaScript',
47
+ supported: (async () =>
48
+ 'clipboard' in navigator && 'write' in navigator.clipboard)(),
49
+ featureDetection: `(async () => 'clipboard' in navigator && 'write' in navigator.clipboard)()`,
50
+ documentation: 'https://web.dev/async-clipboard/',
51
+ blinkFeatureID: 2370,
60
52
  },
61
53
  'Background Fetch': {
62
54
  regEx: /\.backgroundFetch\.fetch\s*\(["']/g,
@@ -67,56 +59,78 @@ const patterns = {
67
59
  'https://developer.mozilla.org/en-US/docs/Web/API/Background_Fetch_API',
68
60
  blinkFeatureID: 2549,
69
61
  },
70
- 'Navigation Preload': {
71
- regEx: /\.navigationPreload\.enable\s*\(\)/g,
62
+ 'Background Sync': {
63
+ regEx: /\.sync\.register\s*\(["']/g,
72
64
  where: 'JavaScript',
73
65
  supported: (async () =>
74
66
  'serviceWorker' in navigator &&
75
- 'navigationPreload' in
67
+ 'sync' in
76
68
  ((await navigator.serviceWorker?.ready) || self.registration))(),
77
- featureDetection: `(async () => 'serviceWorker' in navigator && 'navigationPreload' in (await navigator.serviceWorker?.ready || self.registration))()`,
69
+ featureDetection: `(async () => 'serviceWorker' in navigator && 'sync' in (await navigator.serviceWorker?.ready || self.registration))()`,
78
70
  documentation:
79
- 'https://developer.mozilla.org/en-US/docs/Web/API/NavigationPreloadManager',
80
- blinkFeatureID: 1803,
71
+ 'https://developer.mozilla.org/en-US/docs/Web/API/Background_Synchronization_API',
72
+ blinkFeatureID: 745,
81
73
  },
82
- 'Storage Estimation': {
83
- regEx: /navigator\.storage\.estimate\s*\(\)/g,
74
+ 'Badging': {
75
+ regEx: /navigator\.setAppBadge\s*\(/g,
84
76
  where: 'JavaScript',
85
- supported: (async () =>
86
- 'storage' in navigator && 'estimate' in navigator.storage)(),
87
- featureDetection: `(async () => 'storage' in navigator && 'estimate' in navigator.storage)()`,
88
- documentation:
89
- 'https://developer.mozilla.org/en-US/docs/Web/API/StorageManager/estimate',
90
- blinkFeatureID: 1371,
77
+ supported: (async () => 'setAppBadge' in navigator)(),
78
+ featureDetection: `(async () => 'setAppBadge' in navigator)()`,
79
+ documentation: 'https://web.dev/badging-api/',
80
+ blinkFeatureID: 2726,
91
81
  },
92
- 'Persistent Storage': {
93
- regEx: /navigator\.storage\.persist\s*\(\)/g,
82
+ 'Cache Storage': {
83
+ regEx: /caches\.open\s*\(/g,
94
84
  where: 'JavaScript',
95
- supported: (async () =>
96
- 'storage' in navigator && 'persist' in navigator.storage)(),
97
- featureDetection: `(async () => 'storage' in navigator && 'persist' in navigator.storage)()`,
85
+ supported: (async () => 'serviceWorker' in navigator && 'caches' in self)(),
86
+ featureDetection: `(async () => 'serviceWorker' in navigator && 'caches' in self)()`,
98
87
  documentation:
99
- 'https://developer.mozilla.org/en-US/docs/Web/API/StorageManager/persist',
100
- blinkFeatureID: 1369,
88
+ 'https://developer.mozilla.org/en-US/docs/Web/API/CacheStorage',
89
+ blinkFeatureID: 3022,
101
90
  },
102
- 'Media Session': {
103
- regEx:
104
- /navigator\.mediaSession\.setActionHandler|navigator\.mediaSession\.metadata/g,
91
+ 'Compression Streams': {
92
+ regEx: /new\s+CompressionStream\s*\(/g,
105
93
  where: 'JavaScript',
106
- supported: (async () => 'mediaSession' in navigator)(),
107
- featureDetection: `(async () => 'mediaSession' in navigator)()`,
108
- documentation:
109
- 'https://developer.mozilla.org/en-US/docs/Web/API/Media_Session_API',
110
- blinkFeatureID: 1792,
94
+ supported: (async () => 'CompressionStream' in self)(),
95
+ featureDetection: `(async () => 'CompressionStream' in self)()`,
96
+ documentation: 'https://wicg.github.io/compression/',
97
+ blinkFeatureID: 3060,
111
98
  },
112
- 'Media Capabilities': {
113
- regEx: /navigator\.mediaCapabilities\.decodingInfo\s*\(/g,
99
+ 'Compute Pressure': {
100
+ regEx: /new\s+ComputePressureObserver\s*\(/g,
114
101
  where: 'JavaScript',
115
- supported: (async () => 'mediaCapabilities' in navigator)(),
116
- featureDetection: `(async () => 'mediaCapabilities' in navigator)()`,
102
+ supported: (async () => 'ComputePressureObserver' in self)(),
103
+ featureDetection: `(async () => 'ComputePressureObserver' in self)()`,
104
+ documentation: 'https://web.dev/compute-pressure/',
105
+ blinkFeatureID: 3899,
106
+ },
107
+ 'Contact Picker': {
108
+ regEx: /navigator\.contacts\.select\s*\(/g,
109
+ where: 'JavaScript',
110
+ supported: (async () => 'contacts' in navigator)(),
111
+ featureDetection: `(async () => 'contacts' in navigator)()`,
112
+ documentation: 'https://web.dev/contact-picker/',
113
+ blinkFeatureID: 2993,
114
+ },
115
+ 'Content Index': {
116
+ regEx: /index\.getAll\s*\(/g,
117
+ where: 'JavaScript',
118
+ supported: (async () =>
119
+ 'serviceWorker' in navigator &&
120
+ 'index' in
121
+ ((await navigator.serviceWorker?.ready) || self.registration))(),
122
+ featureDetection: `(async () => 'serviceWorker' in navigator && 'index' in (await navigator.serviceWorker?.ready || self.registration))()`,
123
+ documentation: 'https://web.dev/content-indexing-api/',
124
+ blinkFeatureID: 2985,
125
+ },
126
+ 'Credential Management': {
127
+ regEx: /navigator\.credentials\.get\s*\(/g,
128
+ where: 'JavaScript',
129
+ supported: (async () => 'credentials' in navigator)(),
130
+ featureDetection: `(async () => 'credentials' in navigator)()`,
117
131
  documentation:
118
- 'https://developer.mozilla.org/en-US/docs/Web/API/Media_Capabilities_API',
119
- blinkFeatureID: 2239,
132
+ 'https://developers.google.com/web/updates/2016/04/credential-management-api',
133
+ blinkFeatureID: 960,
120
134
  },
121
135
  'Device Memory': {
122
136
  regEx: /navigator\.deviceMemory/g,
@@ -127,89 +141,57 @@ const patterns = {
127
141
  'https://developer.mozilla.org/en-US/docs/Web/API/Device_Memory_API',
128
142
  blinkFeatureID: 2121,
129
143
  },
130
- 'Payment Request': {
131
- regEx: /new\s+PaymentRequest\s*\(/g,
144
+ 'Device Posture': {
145
+ regEx: /navigator\.devicePosture/g,
132
146
  where: 'JavaScript',
133
- supported: (async () => 'PaymentRequest' in self)(),
134
- featureDetection: `(async () => 'PaymentRequest' in self)()`,
147
+ supported: (async () => 'devicePosture' in navigator)(),
148
+ featureDetection: `(async () => 'devicePosture' in navigator)()`,
135
149
  documentation:
136
- 'https://developer.mozilla.org/en-US/docs/Web/API/Payment_Request_API',
137
- blinkFeatureID: 2894,
138
- },
139
- 'Payment Handler': {
140
- regEx: /\.paymentManager\.instruments\.set\s*\(/g,
141
- where: 'JavaScript',
142
- supported: (async () => 'PaymentInstruments' in self)(),
143
- featureDetection: `(async () => 'PaymentInstruments' in self)()`,
144
- documentation: 'https://web.dev/registering-a-web-based-payment-app/',
145
- blinkFeatureID: 2397,
150
+ 'https://github.com/w3c/device-posture/blob/gh-pages/README.md',
151
+ blinkFeatureID: undefined,
146
152
  },
147
- 'WebMIDI': {
148
- regEx: /navigator\.requestMIDIAccess\s*\(/g,
153
+ 'Digital Goods': {
154
+ regEx: /getDigitalGoodsService\s*\(/g,
149
155
  where: 'JavaScript',
150
- supported: (async () => 'requestMIDIAccess' in navigator)(),
151
- featureDetection: `(async () => 'requestMIDIAccess' in navigator)()`,
156
+ supported: (async () => 'getDigitalGoodsService' in self)(),
157
+ featureDetection: `(async () => 'getDigitalGoodsService' in self)()`,
152
158
  documentation:
153
- 'https://developer.mozilla.org/en-US/docs/Web/API/Web_MIDI_API',
154
- blinkFeatureID: 2029,
159
+ 'https://developer.chrome.com/docs/android/trusted-web-activity/receive-payments-play-billing/',
160
+ blinkFeatureID: 3397,
155
161
  },
156
- 'WebBluetooth': {
157
- regEx: /navigator\.bluetooth\.requestDevice\s*\(/g,
162
+ 'EyeDropper': {
163
+ regEx: /new\s+EyeDropper\s*\(\)/g,
158
164
  where: 'JavaScript',
159
- supported: (async () => 'bluetooth' in navigator)(),
160
- featureDetection: `(async () => 'bluetooth' in navigator)()`,
161
- documentation: 'https://web.dev/bluetooth/',
162
- blinkFeatureID: 1670,
165
+ supported: (async () => 'EyeDropper' in self)(),
166
+ featureDetection: `(async () => 'EyeDropper' in self)()`,
167
+ documentation: 'https://github.com/WICG/eyedropper-api/blob/main/README.md',
168
+ blinkFeatureID: undefined,
163
169
  },
164
- 'WebUSB': {
165
- regEx: /navigator\.usb\.requestDevice\s*\(/g,
166
- where: 'JavaScript',
167
- supported: (async () => 'usb' in navigator)(),
168
- featureDetection: `(async () => 'usb' in navigator)()`,
169
- documentation: 'https://web.dev/usb/',
170
- blinkFeatureID: 1520,
170
+ 'File Handling': {
171
+ regEx: /"file_handlers"/g,
172
+ where: 'Web App Manifest',
173
+ supported: (async () =>
174
+ 'launchQueue' in self && 'files' in LaunchParams.prototype)(),
175
+ featureDetection: `(async () => 'launchQueue' in self && 'files' in LaunchParams.prototype)()`,
176
+ documentation: 'https://web.dev/file-handling/',
177
+ blinkFeatureID: 3875,
171
178
  },
172
- 'Web Share': {
173
- regEx: /navigator\.share\s*\(/g,
179
+ 'File System Access': {
180
+ regEx:
181
+ /showOpenFilePicker\s*\(|showSaveFilePicker\s*\(|showDirectoryPicker\s*\(/g,
174
182
  where: 'JavaScript',
175
- supported: (async () => 'share' in navigator)(),
176
- featureDetection: `(async () => 'share' in navigator)()`,
177
- documentation: 'https://web.dev/web-share/',
178
- blinkFeatureID: 1501,
183
+ supported: (async () => 'showOpenFilePicker' in self)(),
184
+ featureDetection: `(async () => 'showOpenFilePicker' in self)()`,
185
+ documentation: 'https://web.dev/file-system-access/',
186
+ blinkFeatureID: 3340,
179
187
  },
180
- 'Web Share (Files)': {
181
- regEx: /navigator\.canShare\s*\(/g,
188
+ 'Gamepad': {
189
+ regEx: /navigator\.getGamepads\s*\(/g,
182
190
  where: 'JavaScript',
183
- supported: (async () => 'canShare' in navigator)(),
184
- featureDetection: `(async () => 'canShare' in navigator)()`,
185
- documentation: 'https://web.dev/web-share/',
186
- blinkFeatureID: 2737,
187
- },
188
- 'Async Clipboard': {
189
- regEx: /navigator\.clipboard\.writeText\s*\(/g,
190
- where: 'JavaScript',
191
- supported: (async () =>
192
- 'clipboard' in navigator && 'writeText' in navigator.clipboard)(),
193
- featureDetection: `(async () => 'clipboard' in navigator && 'writeText' in navigator.clipboard)()`,
194
- documentation: 'https://web.dev/async-clipboard/',
195
- blinkFeatureID: 2372,
196
- },
197
- 'Async Clipboard (Images)': {
198
- regEx: /navigator\.clipboard\.write\s*\(/g,
199
- where: 'JavaScript',
200
- supported: (async () =>
201
- 'clipboard' in navigator && 'write' in navigator.clipboard)(),
202
- featureDetection: `(async () => 'clipboard' in navigator && 'write' in navigator.clipboard)()`,
203
- documentation: 'https://web.dev/async-clipboard/',
204
- blinkFeatureID: 2370,
205
- },
206
- 'Contact Picker': {
207
- regEx: /navigator\.contacts\.select\s*\(/g,
208
- where: 'JavaScript',
209
- supported: (async () => 'contacts' in navigator)(),
210
- featureDetection: `(async () => 'contacts' in navigator)()`,
211
- documentation: 'https://web.dev/contact-picker/',
212
- blinkFeatureID: 2993,
191
+ supported: (async () => 'getGamepads' in navigator)(),
192
+ featureDetection: `(async () => 'getGamepads' in navigator)()`,
193
+ documentation: 'https://web.dev/gamepad/',
194
+ blinkFeatureID: 1916,
213
195
  },
214
196
  'getInstalledRelatedApps': {
215
197
  regEx: /navigator\.getInstalledRelatedApps\s*\(/g,
@@ -219,204 +201,211 @@ const patterns = {
219
201
  documentation: 'https://web.dev/get-installed-related-apps/',
220
202
  blinkFeatureID: 1870,
221
203
  },
222
- 'Compression Streams': {
223
- regEx: /new\s+CompressionStream\s*\(/g,
224
- where: 'JavaScript',
225
- supported: (async () => 'CompressionStream' in self)(),
226
- featureDetection: `(async () => 'CompressionStream' in self)()`,
227
- documentation: 'https://wicg.github.io/compression/',
228
- blinkFeatureID: 3060,
229
- },
230
- 'Periodic Background Sync': {
231
- regEx: /periodicSync\.register\s*\(/g,
204
+ 'Gravity Sensor': {
205
+ regEx: /new\s+GravitySensor\s*\(/g,
232
206
  where: 'JavaScript',
233
- supported: (async () => 'PeriodicSyncManager' in self)(),
234
- featureDetection: `(async () => 'PeriodicSyncManager' in self)()`,
235
- documentation: 'https://web.dev/periodic-background-sync/',
236
- blinkFeatureID: 2931,
207
+ supported: (async () => 'GravitySensor' in self)(),
208
+ featureDetection: `(async () => 'GravitySensor' in self)()`,
209
+ documentation: 'https://web.dev/generic-sensor/',
210
+ blinkFeatureID: 3795,
237
211
  },
238
- 'Badging': {
239
- regEx: /navigator\.setAppBadge\s*\(/g,
212
+ 'Gyroscope': {
213
+ regEx: /new\s+Gyroscope\s*\(/g,
240
214
  where: 'JavaScript',
241
- supported: (async () => 'setAppBadge' in navigator)(),
242
- featureDetection: `(async () => 'setAppBadge' in navigator)()`,
243
- documentation: 'https://web.dev/badging-api/',
244
- blinkFeatureID: 2726,
215
+ supported: (async () => 'Gyroscope' in self)(),
216
+ featureDetection: `(async () => 'Gyroscope' in self)()`,
217
+ documentation: 'https://web.dev/generic-sensor/',
218
+ blinkFeatureID: 1906,
245
219
  },
246
- 'Shape Detection (Barcodes)': {
247
- regEx: /new\s+BarcodeDetector\s*\(/g,
220
+ 'Handwriting Recognition': {
221
+ regEx: /navigator\.queryHandwritingRecognizerSupport\s*\(/g,
248
222
  where: 'JavaScript',
249
- supported: (async () => 'BarcodeDetector' in self)(),
250
- featureDetection: `(async () => 'BarcodeDetector' in self)()`,
251
- documentation: 'https://web.dev/shape-detection/',
252
- blinkFeatureID: 3711,
223
+ supported: (async () => 'queryHandwritingRecognizerSupport' in navigator)(),
224
+ featureDetection: `(async () => 'queryHandwritingRecognizerSupport' in navigator)()`,
225
+ documentation: 'https://web.dev/handwriting-recognition/',
226
+ blinkFeatureID: 3893,
253
227
  },
254
- 'Shape Detection (Faces)': {
255
- regEx: /new\s+FaceDetector\s*\(/g,
228
+ 'HapticsDevice': {
229
+ regEx: /\.haptics\.play\s*\(/g,
256
230
  where: 'JavaScript',
257
- supported: (async () => 'FaceDetector' in self)(),
258
- featureDetection: `(async () => 'FaceDetector' in self)()`,
259
- documentation: 'https://web.dev/shape-detection/',
260
- blinkFeatureID: 3712,
231
+ supported: (async () => 'HapticsDevice' in self)(),
232
+ featureDetection: `(async () => 'HapticsDevice' in self)()`,
233
+ documentation:
234
+ 'https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/HapticsDevice/explainer.md',
235
+ blinkFeatureID: undefined,
261
236
  },
262
- 'Shape Detection (Texts)': {
263
- regEx: /new\s+TextDetector\s*\(/g,
237
+ 'Idle Detection': {
238
+ regEx: /new\s+IdleDetector\s*\(/g,
264
239
  where: 'JavaScript',
265
- supported: (async () => 'TextDetector' in self)(),
266
- featureDetection: `(async () => 'TextDetector' in self)()`,
267
- documentation: 'https://web.dev/shape-detection/',
268
- blinkFeatureID: 3713,
240
+ supported: (async () => 'IdleDetector' in self)(),
241
+ featureDetection: `(async () => 'IdleDetector' in self)()`,
242
+ documentation: 'https://web.dev/idle-detection/',
243
+ blinkFeatureID: 2834,
269
244
  },
270
- 'Screen Wake Lock': {
271
- regEx: /navigator\.wakeLock\.request\s*\(/g,
245
+ 'Ink': {
246
+ regEx: /navigator\.ink\.requestPresenter\s*\(/g,
272
247
  where: 'JavaScript',
273
- supported: (async () => 'wakeLock' in navigator)(),
274
- featureDetection: `(async () => 'wakeLock' in navigator)()`,
275
- documentation: 'https://web.dev/wake-lock/',
276
- blinkFeatureID: 3005,
248
+ supported: (async () => 'ink' in navigator)(),
249
+ featureDetection: `(async () => 'ink' in navigator)()`,
250
+ documentation:
251
+ 'https://blogs.windows.com/msedgedev/2021/08/18/enhancing-inking-on-the-web/',
252
+ blinkFeatureID: undefined,
277
253
  },
278
- 'Content Index': {
279
- regEx: /index\.getAll\s*\(/g,
254
+ 'Insertable streams for MediaStreamTrack': {
255
+ regEx: /MediaStreamTrackProcessor\s*\(/g,
280
256
  where: 'JavaScript',
281
257
  supported: (async () =>
282
- 'serviceWorker' in navigator &&
283
- 'index' in
284
- ((await navigator.serviceWorker?.ready) || self.registration))(),
285
- featureDetection: `(async () => 'serviceWorker' in navigator && 'index' in (await navigator.serviceWorker?.ready || self.registration))()`,
286
- documentation: 'https://web.dev/content-indexing-api/',
287
- blinkFeatureID: 2985,
288
- },
289
- 'Credential Management': {
290
- regEx: /navigator\.credentials\.get\s*\(/g,
291
- where: 'JavaScript',
292
- supported: (async () => 'credentials' in navigator)(),
293
- featureDetection: `(async () => 'credentials' in navigator)()`,
258
+ 'MediaStreamTrackProcessor' in self &&
259
+ 'MediaStreamTrackGenerator' in self)(),
260
+ featureDetection: `(async () => 'MediaStreamTrackProcessor' in self && 'MediaStreamTrackGenerator' in self)()`,
294
261
  documentation:
295
- 'https://developers.google.com/web/updates/2016/04/credential-management-api',
296
- blinkFeatureID: 960,
262
+ 'https://web.dev/mediastreamtrack-insertable-media-processing/',
263
+ blinkFeatureID: 3729,
297
264
  },
298
- 'WebOTP': {
299
- regEx: /transport\s*\:\s*\[["']sms["']\]/g,
300
- where: 'JavaScript',
301
- supported: (async () => 'OTPCredential' in self)(),
302
- featureDetection: `(async () => 'OTPCredential' in self)()`,
303
- documentation: 'https://web.dev/web-otp/',
304
- blinkFeatureID: 2880,
265
+ 'Launch Handler': {
266
+ regEx: /"launch_handler"/g,
267
+ where: 'Web App Manifest',
268
+ supported: (async () =>
269
+ 'launchQueue' in self && 'targetURL' in LaunchParams.prototype)(),
270
+ featureDetection: `(async () => 'launchQueue' in self && 'targetURL' in LaunchParams.prototype)()`,
271
+ documentation: 'https://web.dev/launch-handler/',
272
+ blinkFeatureID: undefined,
305
273
  },
306
- 'File System Access': {
307
- regEx:
308
- /showOpenFilePicker\s*\(|showSaveFilePicker\s*\(|showDirectoryPicker\s*\(/g,
274
+ 'Linear Acceleration Sensor': {
275
+ regEx: /new\s+LinearAccelerationSensor\s*\(/g,
309
276
  where: 'JavaScript',
310
- supported: (async () => 'showOpenFilePicker' in self)(),
311
- featureDetection: `(async () => 'showOpenFilePicker' in self)()`,
312
- documentation: 'https://web.dev/file-system-access/',
313
- blinkFeatureID: 3340,
277
+ supported: (async () => 'LinearAccelerationSensor' in self)(),
278
+ featureDetection: `(async () => 'LinearAccelerationSensor' in self)()`,
279
+ documentation: 'https://web.dev/generic-sensor/',
280
+ blinkFeatureID: 2051,
314
281
  },
315
- 'Pointer Lock (unadjustedMovement)': {
316
- regEx: /unadjustedMovement\s*\:\s*/g,
282
+ 'Local Font Access': {
283
+ regEx: /queryLocalFonts\s*\(/g,
317
284
  where: 'JavaScript',
318
- supported: (async () =>
319
- await (async () => {
320
- try {
321
- return !!(await document
322
- .createElement('p')
323
- .requestPointerLock({ unadjustedMovement: true }));
324
- } catch {
325
- return true;
326
- }
327
- })())(),
328
- featureDetection: `(async () => await (async () => { try { return !!await document.createElement("p").requestPointerLock({ unadjustedMovement: true }) } catch { return true } })())()`,
329
- documentation: 'https://web.dev/disable-mouse-acceleration/',
330
- blinkFeatureID: 3027,
285
+ supported: (async () => 'queryLocalFonts' in self)(),
286
+ featureDetection: `(async () => 'queryLocalFonts' in self)()`,
287
+ documentation: 'https://web.dev/local-fonts/',
288
+ blinkFeatureID: 4211,
331
289
  },
332
- 'WebHID': {
333
- regEx: /navigator\.hid\.requestDevice\s*\(/g,
290
+ 'Magnetometer': {
291
+ regEx: /new\s+Magnetometer\s*\(/g,
334
292
  where: 'JavaScript',
335
- supported: (async () => 'hid' in navigator)(),
336
- featureDetection: `(async () => 'hid' in navigator)()`,
337
- documentation: 'https://web.dev/hid/',
338
- blinkFeatureID: 2866,
293
+ supported: (async () => 'Magnetometer' in self)(),
294
+ featureDetection: `(async () => 'Magnetometer' in self)()`,
295
+ documentation: 'https://web.dev/generic-sensor/',
296
+ blinkFeatureID: 1907,
339
297
  },
340
- 'WebSerial': {
341
- regEx: /navigator\.serial\.requestPort\s*\(/g,
298
+ 'Media Capabilities': {
299
+ regEx: /navigator\.mediaCapabilities\.decodingInfo\s*\(/g,
342
300
  where: 'JavaScript',
343
- supported: (async () => 'serial' in navigator)(),
344
- featureDetection: `(async () => 'serial' in navigator)()`,
345
- documentation: 'https://web.dev/serial/',
346
- blinkFeatureID: 2546,
301
+ supported: (async () => 'mediaCapabilities' in navigator)(),
302
+ featureDetection: `(async () => 'mediaCapabilities' in navigator)()`,
303
+ documentation:
304
+ 'https://developer.mozilla.org/en-US/docs/Web/API/Media_Capabilities_API',
305
+ blinkFeatureID: 2239,
347
306
  },
348
- 'WebNFC': {
349
- regEx: /new\s+NDEFReader\s*\(/g,
307
+ 'Media Session': {
308
+ regEx:
309
+ /navigator\.mediaSession\.setActionHandler|navigator\.mediaSession\.metadata/g,
350
310
  where: 'JavaScript',
351
- supported: (async () => 'NDEFReader' in self)(),
352
- featureDetection: `(async () => 'NDEFReader' in self)()`,
353
- documentation: 'https://web.dev/nfc/',
354
- blinkFeatureID: 3094,
311
+ supported: (async () => 'mediaSession' in navigator)(),
312
+ featureDetection: `(async () => 'mediaSession' in navigator)()`,
313
+ documentation:
314
+ 'https://developer.mozilla.org/en-US/docs/Web/API/Media_Session_API',
315
+ blinkFeatureID: 1792,
355
316
  },
356
- 'WebCodecs': {
357
- regEx: /new\s+MediaStreamTrackProcessor\s*\(/g,
317
+ 'Multi-Screen Window Placement': {
318
+ regEx: /getScreens\s*\(\)/g,
358
319
  where: 'JavaScript',
359
- supported: (async () => 'MediaStreamTrackProcessor' in self)(),
360
- featureDetection: `(async () => 'MediaStreamTrackProcessor' in self)()`,
361
- documentation: 'https://web.dev/webcodecs/',
362
- blinkFeatureID: 3728,
320
+ supported: (async () => 'getScreens' in self)(),
321
+ featureDetection: `(async () => 'getScreens' in self)()`,
322
+ documentation: 'https://web.dev/multi-screen-window-placement/',
323
+ blinkFeatureID: 3388,
363
324
  },
364
- 'Digital Goods': {
365
- regEx: /getDigitalGoodsService\s*\(/g,
325
+ 'Navigation Preload': {
326
+ regEx: /\.navigationPreload\.enable\s*\(\)/g,
366
327
  where: 'JavaScript',
367
- supported: (async () => 'getDigitalGoodsService' in self)(),
368
- featureDetection: `(async () => 'getDigitalGoodsService' in self)()`,
328
+ supported: (async () =>
329
+ 'serviceWorker' in navigator &&
330
+ 'navigationPreload' in
331
+ ((await navigator.serviceWorker?.ready) || self.registration))(),
332
+ featureDetection: `(async () => 'serviceWorker' in navigator && 'navigationPreload' in (await navigator.serviceWorker?.ready || self.registration))()`,
369
333
  documentation:
370
- 'https://developer.chrome.com/docs/android/trusted-web-activity/receive-payments-play-billing/',
371
- blinkFeatureID: 3397,
334
+ 'https://developer.mozilla.org/en-US/docs/Web/API/NavigationPreloadManager',
335
+ blinkFeatureID: 1803,
372
336
  },
373
- 'Idle Detection': {
374
- regEx: /new\s+IdleDetector\s*\(/g,
337
+ 'Payment Handler': {
338
+ regEx: /\.paymentManager\.instruments\.set\s*\(/g,
375
339
  where: 'JavaScript',
376
- supported: (async () => 'IdleDetector' in self)(),
377
- featureDetection: `(async () => 'IdleDetector' in self)()`,
378
- documentation: 'https://web.dev/idle-detection/',
379
- blinkFeatureID: 2834,
340
+ supported: (async () => 'PaymentInstruments' in self)(),
341
+ featureDetection: `(async () => 'PaymentInstruments' in self)()`,
342
+ documentation: 'https://web.dev/registering-a-web-based-payment-app/',
343
+ blinkFeatureID: 2397,
380
344
  },
381
- 'Handwriting Recognition': {
382
- regEx: /navigator\.queryHandwritingRecognizerSupport\s*\(/g,
345
+ 'Payment Request': {
346
+ regEx: /new\s+PaymentRequest\s*\(/g,
383
347
  where: 'JavaScript',
384
- supported: (async () => 'queryHandwritingRecognizerSupport' in navigator)(),
385
- featureDetection: `(async () => 'queryHandwritingRecognizerSupport' in navigator)()`,
386
- documentation: 'https://web.dev/handwriting-recognition/',
387
- blinkFeatureID: 3893,
348
+ supported: (async () => 'PaymentRequest' in self)(),
349
+ featureDetection: `(async () => 'PaymentRequest' in self)()`,
350
+ documentation:
351
+ 'https://developer.mozilla.org/en-US/docs/Web/API/Payment_Request_API',
352
+ blinkFeatureID: 2894,
388
353
  },
389
- 'Compute Pressure': {
390
- regEx: /new\s+ComputePressureObserver\s*\(/g,
354
+ 'Periodic Background Sync': {
355
+ regEx: /periodicSync\.register\s*\(/g,
391
356
  where: 'JavaScript',
392
- supported: (async () => 'ComputePressureObserver' in self)(),
393
- featureDetection: `(async () => 'ComputePressureObserver' in self)()`,
394
- documentation: 'https://web.dev/compute-pressure/',
395
- blinkFeatureID: 3899,
357
+ supported: (async () => 'PeriodicSyncManager' in self)(),
358
+ featureDetection: `(async () => 'PeriodicSyncManager' in self)()`,
359
+ documentation: 'https://web.dev/periodic-background-sync/',
360
+ blinkFeatureID: 2931,
396
361
  },
397
- 'Accelerometer': {
398
- regEx: /new\s+Accelerometer\s*\(/g,
362
+ 'Persistent Storage': {
363
+ regEx: /navigator\.storage\.persist\s*\(\)/g,
399
364
  where: 'JavaScript',
400
- supported: (async () => 'Accelerometer' in self)(),
401
- featureDetection: `(async () => 'Accelerometer' in self)()`,
402
- documentation: 'https://web.dev/generic-sensor/',
403
- blinkFeatureID: 1899,
365
+ supported: (async () =>
366
+ 'storage' in navigator && 'persist' in navigator.storage)(),
367
+ featureDetection: `(async () => 'storage' in navigator && 'persist' in navigator.storage)()`,
368
+ documentation:
369
+ 'https://developer.mozilla.org/en-US/docs/Web/API/StorageManager/persist',
370
+ blinkFeatureID: 1369,
404
371
  },
405
- 'Gyroscope': {
406
- regEx: /new\s+Gyroscope\s*\(/g,
372
+ 'Pointer Lock (unadjustedMovement)': {
373
+ regEx: /unadjustedMovement\s*\:\s*/g,
407
374
  where: 'JavaScript',
408
- supported: (async () => 'Gyroscope' in self)(),
409
- featureDetection: `(async () => 'Gyroscope' in self)()`,
410
- documentation: 'https://web.dev/generic-sensor/',
411
- blinkFeatureID: 1906,
375
+ supported: (async () =>
376
+ 'HTMLParagraphElement' in self
377
+ ? await (async () => {
378
+ try {
379
+ return !!(await document
380
+ .createElement('p')
381
+ .requestPointerLock({ unadjustedMovement: true }));
382
+ } catch {
383
+ return 'requestPointerLock' in HTMLParagraphElement.prototype;
384
+ }
385
+ })()
386
+ : undefined)(),
387
+ featureDetection: `(async () => 'HTMLParagraphElement' in self ? await (async () => { try { return !!await document.createElement("p").requestPointerLock({ unadjustedMovement: true }) } catch { return 'requestPointerLock' in HTMLParagraphElement.prototype } })() : undefined)()`,
388
+ documentation: 'https://web.dev/disable-mouse-acceleration/',
389
+ blinkFeatureID: 3027,
412
390
  },
413
- 'Absolute Orientation Sensor': {
414
- regEx: /new\s+AbsoluteOrientationSensor\s*\(/g,
391
+ 'Protocol Handlers': {
392
+ regEx: /"protocol_handlers"/g,
393
+ where: 'Web App Manifest',
394
+ supported: (async () => undefined)(),
395
+ featureDetection: `(async () => undefined)()`,
396
+ documentation: 'https://web.dev/url-protocol-handler/',
397
+ blinkFeatureID: 3884,
398
+ },
399
+ 'Push': {
400
+ regEx: /\.pushManager\.subscribe\s*\(/g,
415
401
  where: 'JavaScript',
416
- supported: (async () => 'AbsoluteOrientationSensor' in self)(),
417
- featureDetection: `(async () => 'AbsoluteOrientationSensor' in self)()`,
418
- documentation: 'https://web.dev/generic-sensor/',
419
- blinkFeatureID: 1900,
402
+ supported: (async () =>
403
+ 'serviceWorker' in navigator &&
404
+ 'pushManager' in
405
+ ((await navigator.serviceWorker?.ready) || self.registration))(),
406
+ featureDetection: `(async () => 'serviceWorker' in navigator && 'pushManager' in (await navigator.serviceWorker?.ready || self.registration))()`,
407
+ documentation: 'https://developer.mozilla.org/en-US/docs/Web/API/Push_API',
408
+ blinkFeatureID: 769,
420
409
  },
421
410
  'Relative Orientation Sensor': {
422
411
  regEx: /new\s+RelativeOrientationSensor\s*\(/g,
@@ -426,85 +415,72 @@ const patterns = {
426
415
  documentation: 'https://web.dev/generic-sensor/',
427
416
  blinkFeatureID: 2019,
428
417
  },
429
- 'Gravity Sensor': {
430
- regEx: /new\s+GravitySensor\s*\(/g,
431
- where: 'JavaScript',
432
- supported: (async () => 'GravitySensor' in self)(),
433
- featureDetection: `(async () => 'GravitySensor' in self)()`,
434
- documentation: 'https://web.dev/generic-sensor/',
435
- blinkFeatureID: 3795,
436
- },
437
- 'Linear Acceleration Sensor': {
438
- regEx: /new\s+LinearAccelerationSensor\s*\(/g,
439
- where: 'JavaScript',
440
- supported: (async () => 'LinearAccelerationSensor' in self)(),
441
- featureDetection: `(async () => 'LinearAccelerationSensor' in self)()`,
442
- documentation: 'https://web.dev/generic-sensor/',
443
- blinkFeatureID: 2051,
444
- },
445
- 'Magnetometer': {
446
- regEx: /new\s+Magnetometer\s*\(/g,
447
- where: 'JavaScript',
448
- supported: (async () => 'Magnetometer' in self)(),
449
- featureDetection: `(async () => 'Magnetometer' in self)()`,
450
- documentation: 'https://web.dev/generic-sensor/',
451
- blinkFeatureID: 1907,
452
- },
453
- 'Ambient Light Sensor': {
454
- regEx: /new\s+AmbientLightSensor\s*\(\)/g,
455
- where: 'JavaScript',
456
- supported: (async () => 'AmbientLightSensor' in self)(),
457
- featureDetection: `(async () => 'AmbientLightSensor' in self)()`,
458
- documentation: 'https://web.dev/generic-sensor/',
459
- blinkFeatureID: 1901,
460
- },
461
- 'Local Font Access': {
462
- regEx: /queryLocalFonts\s*\(/g,
418
+ 'Screen Wake Lock': {
419
+ regEx: /navigator\.wakeLock\.request\s*\(/g,
463
420
  where: 'JavaScript',
464
- supported: (async () => 'queryLocalFonts' in self)(),
465
- featureDetection: `(async () => 'queryLocalFonts' in self)()`,
466
- documentation: 'https://web.dev/local-fonts/',
467
- blinkFeatureID: 4211,
421
+ supported: (async () => 'wakeLock' in navigator)(),
422
+ featureDetection: `(async () => 'wakeLock' in navigator)()`,
423
+ documentation: 'https://web.dev/wake-lock/',
424
+ blinkFeatureID: 3005,
468
425
  },
469
- 'Multi-Screen Window Placement': {
470
- regEx: /getScreens\s*\(\)/g,
426
+ 'Service Worker': {
427
+ regEx: /navigator\.serviceWorker\.register\s*\(/g,
471
428
  where: 'JavaScript',
472
- supported: (async () => 'getScreens' in self)(),
473
- featureDetection: `(async () => 'getScreens' in self)()`,
474
- documentation: 'https://web.dev/multi-screen-window-placement/',
475
- blinkFeatureID: 3388,
429
+ supported: (async () => 'serviceWorker' in navigator)(),
430
+ featureDetection: `(async () => 'serviceWorker' in navigator)()`,
431
+ documentation:
432
+ 'https://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API',
433
+ blinkFeatureID: 990,
476
434
  },
477
- 'WebSocketStream': {
478
- regEx: /new\s+WebSocketStream\s*\(/g,
435
+ 'Shape Detection (Barcodes)': {
436
+ regEx: /new\s+BarcodeDetector\s*\(/g,
479
437
  where: 'JavaScript',
480
- supported: (async () => 'WebSocketStream' in self)(),
481
- featureDetection: `(async () => 'WebSocketStream' in self)()`,
482
- documentation: 'https://web.dev/websocketstream/',
483
- blinkFeatureID: 3018,
438
+ supported: (async () => 'BarcodeDetector' in self)(),
439
+ featureDetection: `(async () => 'BarcodeDetector' in self)()`,
440
+ documentation: 'https://web.dev/shape-detection/',
441
+ blinkFeatureID: 3711,
484
442
  },
485
- 'WebTransport': {
486
- regEx: /new\s+WebTransport\s*\(/g,
443
+ 'Shape Detection (Faces)': {
444
+ regEx: /new\s+FaceDetector\s*\(/g,
487
445
  where: 'JavaScript',
488
- supported: (async () => 'WebTransport' in self)(),
489
- featureDetection: `(async () => 'WebTransport' in self)()`,
490
- documentation: 'https://web.dev/webtransport/',
491
- blinkFeatureID: 3472,
446
+ supported: (async () => 'FaceDetector' in self)(),
447
+ featureDetection: `(async () => 'FaceDetector' in self)()`,
448
+ documentation: 'https://web.dev/shape-detection/',
449
+ blinkFeatureID: 3712,
492
450
  },
493
- 'Gamepad': {
494
- regEx: /navigator\.getGamepads\s*\(/g,
451
+ 'Shape Detection (Texts)': {
452
+ regEx: /new\s+TextDetector\s*\(/g,
495
453
  where: 'JavaScript',
496
- supported: (async () => 'getGamepads' in navigator)(),
497
- featureDetection: `(async () => 'getGamepads' in navigator)()`,
498
- documentation: 'https://web.dev/gamepad/',
499
- blinkFeatureID: 1916,
454
+ supported: (async () => 'TextDetector' in self)(),
455
+ featureDetection: `(async () => 'TextDetector' in self)()`,
456
+ documentation: 'https://web.dev/shape-detection/',
457
+ blinkFeatureID: 3713,
500
458
  },
501
- 'WebGPU': {
502
- regEx: /navigator\.gpu\.requestAdapter\s*\(/g,
459
+ 'Shortcuts': {
460
+ regEx: /"shortcuts"/g,
461
+ where: 'Web App Manifest',
462
+ supported: (async () => undefined)(),
463
+ featureDetection: `(async () => undefined)()`,
464
+ documentation: 'https://web.dev/app-shortcuts/',
465
+ blinkFeatureID: undefined,
466
+ },
467
+ 'Storage Estimation': {
468
+ regEx: /navigator\.storage\.estimate\s*\(\)/g,
503
469
  where: 'JavaScript',
504
- supported: (async () => 'gpu' in navigator)(),
505
- featureDetection: `(async () => 'gpu' in navigator)()`,
506
- documentation: 'https://web.dev/webgpu',
507
- blinkFeatureID: 3888,
470
+ supported: (async () =>
471
+ 'storage' in navigator && 'estimate' in navigator.storage)(),
472
+ featureDetection: `(async () => 'storage' in navigator && 'estimate' in navigator.storage)()`,
473
+ documentation:
474
+ 'https://developer.mozilla.org/en-US/docs/Web/API/StorageManager/estimate',
475
+ blinkFeatureID: 1371,
476
+ },
477
+ 'Tabbed Application Mode': {
478
+ regEx: /"tabbed"/g,
479
+ where: 'Web App Manifest',
480
+ supported: (async () => undefined)(),
481
+ featureDetection: `(async () => undefined)()`,
482
+ documentation: 'https://web.dev/tabbed-application-mode/',
483
+ blinkFeatureID: undefined,
508
484
  },
509
485
  'VirtualKeyboard': {
510
486
  regEx: /navigator\.virtualKeyboard/g,
@@ -515,50 +491,30 @@ const patterns = {
515
491
  'https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/VirtualKeyboardAPI/explainer.md',
516
492
  blinkFeatureID: undefined,
517
493
  },
518
- 'EyeDropper': {
519
- regEx: /new\s+EyeDropper\s*\(\)/g,
520
- where: 'JavaScript',
521
- supported: (async () => 'EyeDropper' in self)(),
522
- featureDetection: `(async () => 'EyeDropper' in self)()`,
523
- documentation: 'https://github.com/WICG/eyedropper-api/blob/main/README.md',
524
- blinkFeatureID: undefined,
525
- },
526
- 'Device Posture': {
527
- regEx: /navigator\.devicePosture/g,
528
- where: 'JavaScript',
529
- supported: (async () => 'devicePosture' in navigator)(),
530
- featureDetection: `(async () => 'devicePosture' in navigator)()`,
494
+ 'Web App Link Handling': {
495
+ regEx: /"handle_links"/g,
496
+ where: 'Web App Manifest',
497
+ supported: (async () => undefined)(),
498
+ featureDetection: `(async () => undefined)()`,
531
499
  documentation:
532
- 'https://github.com/w3c/device-posture/blob/gh-pages/README.md',
500
+ 'https://github.com/WICG/pwa-url-handler/blob/main/handle_links/explainer.md',
533
501
  blinkFeatureID: undefined,
534
502
  },
535
- 'Insertable streams for MediaStreamTrack': {
536
- regEx: /MediaStreamTrackProcessor\s*\(/g,
503
+ 'Web Share': {
504
+ regEx: /navigator\.share\s*\(/g,
537
505
  where: 'JavaScript',
538
- supported: (async () =>
539
- 'MediaStreamTrackProcessor' in self &&
540
- 'MediaStreamTrackGenerator' in self)(),
541
- featureDetection: `(async () => 'MediaStreamTrackProcessor' in self && 'MediaStreamTrackGenerator' in self)()`,
542
- documentation:
543
- 'https://web.dev/mediastreamtrack-insertable-media-processing/',
544
- blinkFeatureID: 3729,
506
+ supported: (async () => 'share' in navigator)(),
507
+ featureDetection: `(async () => 'share' in navigator)()`,
508
+ documentation: 'https://web.dev/web-share/',
509
+ blinkFeatureID: 1501,
545
510
  },
546
- 'Ink': {
547
- regEx: /navigator\.ink\.requestPresenter\s*\(/g,
511
+ 'Web Share (Files)': {
512
+ regEx: /navigator\.canShare\s*\(/g,
548
513
  where: 'JavaScript',
549
- supported: (async () => 'ink' in navigator)(),
550
- featureDetection: `(async () => 'ink' in navigator)()`,
551
- documentation:
552
- 'https://blogs.windows.com/msedgedev/2021/08/18/enhancing-inking-on-the-web/',
553
- blinkFeatureID: undefined,
554
- },
555
- 'Window Controls Overlay': {
556
- regEx: /"window\-controls\-overlay"/g,
557
- where: 'Web App Manifest',
558
- supported: (async () => 'windowControlsOverlay' in navigator)(),
559
- featureDetection: `(async () => 'windowControlsOverlay' in navigator)()`,
560
- documentation: 'https://web.dev/window-controls-overlay/',
561
- blinkFeatureID: 3902,
514
+ supported: (async () => 'canShare' in navigator)(),
515
+ featureDetection: `(async () => 'canShare' in navigator)()`,
516
+ documentation: 'https://web.dev/web-share/',
517
+ blinkFeatureID: 2737,
562
518
  },
563
519
  'Web Share Target': {
564
520
  regEx: /"share_target"/g,
@@ -576,55 +532,101 @@ const patterns = {
576
532
  documentation: 'https://web.dev/web-share-target/',
577
533
  blinkFeatureID: undefined,
578
534
  },
579
- 'Shortcuts': {
580
- regEx: /"shortcuts"/g,
581
- where: 'Web App Manifest',
582
- supported: (async () => undefined)(),
583
- featureDetection: `(async () => undefined)()`,
584
- documentation: 'https://web.dev/app-shortcuts/',
585
- blinkFeatureID: undefined,
535
+ 'WebBluetooth': {
536
+ regEx: /navigator\.bluetooth\.requestDevice\s*\(/g,
537
+ where: 'JavaScript',
538
+ supported: (async () => 'bluetooth' in navigator)(),
539
+ featureDetection: `(async () => 'bluetooth' in navigator)()`,
540
+ documentation: 'https://web.dev/bluetooth/',
541
+ blinkFeatureID: 1670,
586
542
  },
587
- 'Tabbed Application Mode': {
588
- regEx: /"tabbed"/g,
589
- where: 'Web App Manifest',
590
- supported: (async () => undefined)(),
591
- featureDetection: `(async () => undefined)()`,
592
- documentation: 'https://web.dev/tabbed-application-mode/',
593
- blinkFeatureID: undefined,
543
+ 'WebCodecs': {
544
+ regEx: /new\s+MediaStreamTrackProcessor\s*\(/g,
545
+ where: 'JavaScript',
546
+ supported: (async () => 'MediaStreamTrackProcessor' in self)(),
547
+ featureDetection: `(async () => 'MediaStreamTrackProcessor' in self)()`,
548
+ documentation: 'https://web.dev/webcodecs/',
549
+ blinkFeatureID: 3728,
594
550
  },
595
- 'Protocol Handlers': {
596
- regEx: /"protocol_handlers"/g,
597
- where: 'Web App Manifest',
598
- supported: (async () => undefined)(),
599
- featureDetection: `(async () => undefined)()`,
600
- documentation: 'https://web.dev/url-protocol-handler/',
601
- blinkFeatureID: 3884,
551
+ 'WebGPU': {
552
+ regEx: /navigator\.gpu\.requestAdapter\s*\(/g,
553
+ where: 'JavaScript',
554
+ supported: (async () => 'gpu' in navigator)(),
555
+ featureDetection: `(async () => 'gpu' in navigator)()`,
556
+ documentation: 'https://web.dev/webgpu',
557
+ blinkFeatureID: 3888,
602
558
  },
603
- 'File Handling': {
604
- regEx: /"file_handlers"/g,
605
- where: 'Web App Manifest',
606
- supported: (async () =>
607
- 'launchQueue' in self && 'files' in LaunchParams.prototype)(),
608
- featureDetection: `(async () => 'launchQueue' in self && 'files' in LaunchParams.prototype)()`,
609
- documentation: 'https://web.dev/file-handling/',
610
- blinkFeatureID: 3875,
559
+ 'WebHID': {
560
+ regEx: /navigator\.hid\.requestDevice\s*\(/g,
561
+ where: 'JavaScript',
562
+ supported: (async () => 'hid' in navigator)(),
563
+ featureDetection: `(async () => 'hid' in navigator)()`,
564
+ documentation: 'https://web.dev/hid/',
565
+ blinkFeatureID: 2866,
611
566
  },
612
- 'Launch Handler': {
613
- regEx: /"launch_handler"/g,
614
- where: 'Web App Manifest',
615
- supported: (async () =>
616
- 'launchQueue' in self && 'targetURL' in LaunchParams.prototype)(),
617
- featureDetection: `(async () => 'launchQueue' in self && 'targetURL' in LaunchParams.prototype)()`,
618
- documentation: 'https://web.dev/launch-handler/',
619
- blinkFeatureID: undefined,
567
+ 'WebMIDI': {
568
+ regEx: /navigator\.requestMIDIAccess\s*\(/g,
569
+ where: 'JavaScript',
570
+ supported: (async () => 'requestMIDIAccess' in navigator)(),
571
+ featureDetection: `(async () => 'requestMIDIAccess' in navigator)()`,
572
+ documentation:
573
+ 'https://developer.mozilla.org/en-US/docs/Web/API/Web_MIDI_API',
574
+ blinkFeatureID: 2029,
620
575
  },
621
- 'Web App Link Handling': {
622
- regEx: /"handle_links"/g,
576
+ 'WebNFC': {
577
+ regEx: /new\s+NDEFReader\s*\(/g,
578
+ where: 'JavaScript',
579
+ supported: (async () => 'NDEFReader' in self)(),
580
+ featureDetection: `(async () => 'NDEFReader' in self)()`,
581
+ documentation: 'https://web.dev/nfc/',
582
+ blinkFeatureID: 3094,
583
+ },
584
+ 'WebOTP': {
585
+ regEx: /transport\s*\:\s*\[["']sms["']\]/g,
586
+ where: 'JavaScript',
587
+ supported: (async () => 'OTPCredential' in self)(),
588
+ featureDetection: `(async () => 'OTPCredential' in self)()`,
589
+ documentation: 'https://web.dev/web-otp/',
590
+ blinkFeatureID: 2880,
591
+ },
592
+ 'WebSerial': {
593
+ regEx: /navigator\.serial\.requestPort\s*\(/g,
594
+ where: 'JavaScript',
595
+ supported: (async () => 'serial' in navigator)(),
596
+ featureDetection: `(async () => 'serial' in navigator)()`,
597
+ documentation: 'https://web.dev/serial/',
598
+ blinkFeatureID: 2546,
599
+ },
600
+ 'WebSocketStream': {
601
+ regEx: /new\s+WebSocketStream\s*\(/g,
602
+ where: 'JavaScript',
603
+ supported: (async () => 'WebSocketStream' in self)(),
604
+ featureDetection: `(async () => 'WebSocketStream' in self)()`,
605
+ documentation: 'https://web.dev/websocketstream/',
606
+ blinkFeatureID: 3018,
607
+ },
608
+ 'WebTransport': {
609
+ regEx: /new\s+WebTransport\s*\(/g,
610
+ where: 'JavaScript',
611
+ supported: (async () => 'WebTransport' in self)(),
612
+ featureDetection: `(async () => 'WebTransport' in self)()`,
613
+ documentation: 'https://web.dev/webtransport/',
614
+ blinkFeatureID: 3472,
615
+ },
616
+ 'WebUSB': {
617
+ regEx: /navigator\.usb\.requestDevice\s*\(/g,
618
+ where: 'JavaScript',
619
+ supported: (async () => 'usb' in navigator)(),
620
+ featureDetection: `(async () => 'usb' in navigator)()`,
621
+ documentation: 'https://web.dev/usb/',
622
+ blinkFeatureID: 1520,
623
+ },
624
+ 'Window Controls Overlay': {
625
+ regEx: /"window\-controls\-overlay"/g,
623
626
  where: 'Web App Manifest',
624
- supported: (async () => undefined)(),
625
- featureDetection: `(async () => undefined)()`,
626
- documentation:
627
- 'https://github.com/WICG/pwa-url-handler/blob/main/handle_links/explainer.md',
628
- blinkFeatureID: undefined,
627
+ supported: (async () => 'windowControlsOverlay' in navigator)(),
628
+ featureDetection: `(async () => 'windowControlsOverlay' in navigator)()`,
629
+ documentation: 'https://web.dev/window-controls-overlay/',
630
+ blinkFeatureID: 3902,
629
631
  },
630
632
  };