@measured/puck-plugin-heading-analyzer 0.17.0-canary.f71da6d → 0.17.0-canary.fcdf346
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.js +23 -1314
- package/dist/index.mjs +27 -1322
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
@@ -116,1292 +116,6 @@ var require_classnames = __commonJS({
|
|
116
116
|
}
|
117
117
|
});
|
118
118
|
|
119
|
-
// ../../node_modules/ua-parser-js/src/ua-parser.js
|
120
|
-
var require_ua_parser = __commonJS({
|
121
|
-
"../../node_modules/ua-parser-js/src/ua-parser.js"(exports, module) {
|
122
|
-
"use strict";
|
123
|
-
init_react_import();
|
124
|
-
(function(window2, undefined2) {
|
125
|
-
"use strict";
|
126
|
-
var LIBVERSION = "1.0.37", EMPTY = "", UNKNOWN = "?", FUNC_TYPE = "function", UNDEF_TYPE = "undefined", OBJ_TYPE = "object", STR_TYPE = "string", MAJOR = "major", MODEL = "model", NAME = "name", TYPE = "type", VENDOR = "vendor", VERSION = "version", ARCHITECTURE = "architecture", CONSOLE = "console", MOBILE = "mobile", TABLET = "tablet", SMARTTV = "smarttv", WEARABLE = "wearable", EMBEDDED = "embedded", UA_MAX_LENGTH = 500;
|
127
|
-
var AMAZON = "Amazon", APPLE = "Apple", ASUS = "ASUS", BLACKBERRY = "BlackBerry", BROWSER = "Browser", CHROME = "Chrome", EDGE = "Edge", FIREFOX = "Firefox", GOOGLE = "Google", HUAWEI = "Huawei", LG = "LG", MICROSOFT = "Microsoft", MOTOROLA = "Motorola", OPERA = "Opera", SAMSUNG = "Samsung", SHARP = "Sharp", SONY = "Sony", XIAOMI = "Xiaomi", ZEBRA = "Zebra", FACEBOOK = "Facebook", CHROMIUM_OS = "Chromium OS", MAC_OS = "Mac OS";
|
128
|
-
var extend = function(regexes2, extensions) {
|
129
|
-
var mergedRegexes = {};
|
130
|
-
for (var i in regexes2) {
|
131
|
-
if (extensions[i] && extensions[i].length % 2 === 0) {
|
132
|
-
mergedRegexes[i] = extensions[i].concat(regexes2[i]);
|
133
|
-
} else {
|
134
|
-
mergedRegexes[i] = regexes2[i];
|
135
|
-
}
|
136
|
-
}
|
137
|
-
return mergedRegexes;
|
138
|
-
}, enumerize = function(arr) {
|
139
|
-
var enums = {};
|
140
|
-
for (var i = 0; i < arr.length; i++) {
|
141
|
-
enums[arr[i].toUpperCase()] = arr[i];
|
142
|
-
}
|
143
|
-
return enums;
|
144
|
-
}, has = function(str1, str2) {
|
145
|
-
return typeof str1 === STR_TYPE ? lowerize(str2).indexOf(lowerize(str1)) !== -1 : false;
|
146
|
-
}, lowerize = function(str) {
|
147
|
-
return str.toLowerCase();
|
148
|
-
}, majorize = function(version) {
|
149
|
-
return typeof version === STR_TYPE ? version.replace(/[^\d\.]/g, EMPTY).split(".")[0] : undefined2;
|
150
|
-
}, trim = function(str, len) {
|
151
|
-
if (typeof str === STR_TYPE) {
|
152
|
-
str = str.replace(/^\s\s*/, EMPTY);
|
153
|
-
return typeof len === UNDEF_TYPE ? str : str.substring(0, UA_MAX_LENGTH);
|
154
|
-
}
|
155
|
-
};
|
156
|
-
var rgxMapper = function(ua, arrays) {
|
157
|
-
var i = 0, j, k, p, q, matches, match;
|
158
|
-
while (i < arrays.length && !matches) {
|
159
|
-
var regex = arrays[i], props = arrays[i + 1];
|
160
|
-
j = k = 0;
|
161
|
-
while (j < regex.length && !matches) {
|
162
|
-
if (!regex[j]) {
|
163
|
-
break;
|
164
|
-
}
|
165
|
-
matches = regex[j++].exec(ua);
|
166
|
-
if (!!matches) {
|
167
|
-
for (p = 0; p < props.length; p++) {
|
168
|
-
match = matches[++k];
|
169
|
-
q = props[p];
|
170
|
-
if (typeof q === OBJ_TYPE && q.length > 0) {
|
171
|
-
if (q.length === 2) {
|
172
|
-
if (typeof q[1] == FUNC_TYPE) {
|
173
|
-
this[q[0]] = q[1].call(this, match);
|
174
|
-
} else {
|
175
|
-
this[q[0]] = q[1];
|
176
|
-
}
|
177
|
-
} else if (q.length === 3) {
|
178
|
-
if (typeof q[1] === FUNC_TYPE && !(q[1].exec && q[1].test)) {
|
179
|
-
this[q[0]] = match ? q[1].call(this, match, q[2]) : undefined2;
|
180
|
-
} else {
|
181
|
-
this[q[0]] = match ? match.replace(q[1], q[2]) : undefined2;
|
182
|
-
}
|
183
|
-
} else if (q.length === 4) {
|
184
|
-
this[q[0]] = match ? q[3].call(this, match.replace(q[1], q[2])) : undefined2;
|
185
|
-
}
|
186
|
-
} else {
|
187
|
-
this[q] = match ? match : undefined2;
|
188
|
-
}
|
189
|
-
}
|
190
|
-
}
|
191
|
-
}
|
192
|
-
i += 2;
|
193
|
-
}
|
194
|
-
}, strMapper = function(str, map) {
|
195
|
-
for (var i in map) {
|
196
|
-
if (typeof map[i] === OBJ_TYPE && map[i].length > 0) {
|
197
|
-
for (var j = 0; j < map[i].length; j++) {
|
198
|
-
if (has(map[i][j], str)) {
|
199
|
-
return i === UNKNOWN ? undefined2 : i;
|
200
|
-
}
|
201
|
-
}
|
202
|
-
} else if (has(map[i], str)) {
|
203
|
-
return i === UNKNOWN ? undefined2 : i;
|
204
|
-
}
|
205
|
-
}
|
206
|
-
return str;
|
207
|
-
};
|
208
|
-
var oldSafariMap = {
|
209
|
-
"1.0": "/8",
|
210
|
-
"1.2": "/1",
|
211
|
-
"1.3": "/3",
|
212
|
-
"2.0": "/412",
|
213
|
-
"2.0.2": "/416",
|
214
|
-
"2.0.3": "/417",
|
215
|
-
"2.0.4": "/419",
|
216
|
-
"?": "/"
|
217
|
-
}, windowsVersionMap = {
|
218
|
-
"ME": "4.90",
|
219
|
-
"NT 3.11": "NT3.51",
|
220
|
-
"NT 4.0": "NT4.0",
|
221
|
-
"2000": "NT 5.0",
|
222
|
-
"XP": ["NT 5.1", "NT 5.2"],
|
223
|
-
"Vista": "NT 6.0",
|
224
|
-
"7": "NT 6.1",
|
225
|
-
"8": "NT 6.2",
|
226
|
-
"8.1": "NT 6.3",
|
227
|
-
"10": ["NT 6.4", "NT 10.0"],
|
228
|
-
"RT": "ARM"
|
229
|
-
};
|
230
|
-
var regexes = {
|
231
|
-
browser: [
|
232
|
-
[
|
233
|
-
/\b(?:crmo|crios)\/([\w\.]+)/i
|
234
|
-
// Chrome for Android/iOS
|
235
|
-
],
|
236
|
-
[VERSION, [NAME, "Chrome"]],
|
237
|
-
[
|
238
|
-
/edg(?:e|ios|a)?\/([\w\.]+)/i
|
239
|
-
// Microsoft Edge
|
240
|
-
],
|
241
|
-
[VERSION, [NAME, "Edge"]],
|
242
|
-
[
|
243
|
-
// Presto based
|
244
|
-
/(opera mini)\/([-\w\.]+)/i,
|
245
|
-
// Opera Mini
|
246
|
-
/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,
|
247
|
-
// Opera Mobi/Tablet
|
248
|
-
/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i
|
249
|
-
// Opera
|
250
|
-
],
|
251
|
-
[NAME, VERSION],
|
252
|
-
[
|
253
|
-
/opios[\/ ]+([\w\.]+)/i
|
254
|
-
// Opera mini on iphone >= 8.0
|
255
|
-
],
|
256
|
-
[VERSION, [NAME, OPERA + " Mini"]],
|
257
|
-
[
|
258
|
-
/\bopr\/([\w\.]+)/i
|
259
|
-
// Opera Webkit
|
260
|
-
],
|
261
|
-
[VERSION, [NAME, OPERA]],
|
262
|
-
[
|
263
|
-
// Mixed
|
264
|
-
/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i
|
265
|
-
// Baidu
|
266
|
-
],
|
267
|
-
[VERSION, [NAME, "Baidu"]],
|
268
|
-
[
|
269
|
-
/(kindle)\/([\w\.]+)/i,
|
270
|
-
// Kindle
|
271
|
-
/(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,
|
272
|
-
// Lunascape/Maxthon/Netfront/Jasmine/Blazer
|
273
|
-
// Trident based
|
274
|
-
/(avant|iemobile|slim)\s?(?:browser)?[\/ ]?([\w\.]*)/i,
|
275
|
-
// Avant/IEMobile/SlimBrowser
|
276
|
-
/(?:ms|\()(ie) ([\w\.]+)/i,
|
277
|
-
// Internet Explorer
|
278
|
-
// Webkit/KHTML based // Flock/RockMelt/Midori/Epiphany/Silk/Skyfire/Bolt/Iron/Iridium/PhantomJS/Bowser/QupZilla/Falkon
|
279
|
-
/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,
|
280
|
-
// Rekonq/Puffin/Brave/Whale/QQBrowserLite/QQ, aka ShouQ
|
281
|
-
/(heytap|ovi)browser\/([\d\.]+)/i,
|
282
|
-
// Heytap/Ovi
|
283
|
-
/(weibo)__([\d\.]+)/i
|
284
|
-
// Weibo
|
285
|
-
],
|
286
|
-
[NAME, VERSION],
|
287
|
-
[
|
288
|
-
/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i
|
289
|
-
// UCBrowser
|
290
|
-
],
|
291
|
-
[VERSION, [NAME, "UC" + BROWSER]],
|
292
|
-
[
|
293
|
-
/microm.+\bqbcore\/([\w\.]+)/i,
|
294
|
-
// WeChat Desktop for Windows Built-in Browser
|
295
|
-
/\bqbcore\/([\w\.]+).+microm/i,
|
296
|
-
/micromessenger\/([\w\.]+)/i
|
297
|
-
// WeChat
|
298
|
-
],
|
299
|
-
[VERSION, [NAME, "WeChat"]],
|
300
|
-
[
|
301
|
-
/konqueror\/([\w\.]+)/i
|
302
|
-
// Konqueror
|
303
|
-
],
|
304
|
-
[VERSION, [NAME, "Konqueror"]],
|
305
|
-
[
|
306
|
-
/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i
|
307
|
-
// IE11
|
308
|
-
],
|
309
|
-
[VERSION, [NAME, "IE"]],
|
310
|
-
[
|
311
|
-
/ya(?:search)?browser\/([\w\.]+)/i
|
312
|
-
// Yandex
|
313
|
-
],
|
314
|
-
[VERSION, [NAME, "Yandex"]],
|
315
|
-
[
|
316
|
-
/slbrowser\/([\w\.]+)/i
|
317
|
-
// Smart Lenovo Browser
|
318
|
-
],
|
319
|
-
[VERSION, [NAME, "Smart Lenovo " + BROWSER]],
|
320
|
-
[
|
321
|
-
/(avast|avg)\/([\w\.]+)/i
|
322
|
-
// Avast/AVG Secure Browser
|
323
|
-
],
|
324
|
-
[[NAME, /(.+)/, "$1 Secure " + BROWSER], VERSION],
|
325
|
-
[
|
326
|
-
/\bfocus\/([\w\.]+)/i
|
327
|
-
// Firefox Focus
|
328
|
-
],
|
329
|
-
[VERSION, [NAME, FIREFOX + " Focus"]],
|
330
|
-
[
|
331
|
-
/\bopt\/([\w\.]+)/i
|
332
|
-
// Opera Touch
|
333
|
-
],
|
334
|
-
[VERSION, [NAME, OPERA + " Touch"]],
|
335
|
-
[
|
336
|
-
/coc_coc\w+\/([\w\.]+)/i
|
337
|
-
// Coc Coc Browser
|
338
|
-
],
|
339
|
-
[VERSION, [NAME, "Coc Coc"]],
|
340
|
-
[
|
341
|
-
/dolfin\/([\w\.]+)/i
|
342
|
-
// Dolphin
|
343
|
-
],
|
344
|
-
[VERSION, [NAME, "Dolphin"]],
|
345
|
-
[
|
346
|
-
/coast\/([\w\.]+)/i
|
347
|
-
// Opera Coast
|
348
|
-
],
|
349
|
-
[VERSION, [NAME, OPERA + " Coast"]],
|
350
|
-
[
|
351
|
-
/miuibrowser\/([\w\.]+)/i
|
352
|
-
// MIUI Browser
|
353
|
-
],
|
354
|
-
[VERSION, [NAME, "MIUI " + BROWSER]],
|
355
|
-
[
|
356
|
-
/fxios\/([-\w\.]+)/i
|
357
|
-
// Firefox for iOS
|
358
|
-
],
|
359
|
-
[VERSION, [NAME, FIREFOX]],
|
360
|
-
[
|
361
|
-
/\bqihu|(qi?ho?o?|360)browser/i
|
362
|
-
// 360
|
363
|
-
],
|
364
|
-
[[NAME, "360 " + BROWSER]],
|
365
|
-
[
|
366
|
-
/(oculus|sailfish|huawei|vivo)browser\/([\w\.]+)/i
|
367
|
-
],
|
368
|
-
[[NAME, /(.+)/, "$1 " + BROWSER], VERSION],
|
369
|
-
[
|
370
|
-
// Oculus/Sailfish/HuaweiBrowser/VivoBrowser
|
371
|
-
/samsungbrowser\/([\w\.]+)/i
|
372
|
-
// Samsung Internet
|
373
|
-
],
|
374
|
-
[VERSION, [NAME, SAMSUNG + " Internet"]],
|
375
|
-
[
|
376
|
-
/(comodo_dragon)\/([\w\.]+)/i
|
377
|
-
// Comodo Dragon
|
378
|
-
],
|
379
|
-
[[NAME, /_/g, " "], VERSION],
|
380
|
-
[
|
381
|
-
/metasr[\/ ]?([\d\.]+)/i
|
382
|
-
// Sogou Explorer
|
383
|
-
],
|
384
|
-
[VERSION, [NAME, "Sogou Explorer"]],
|
385
|
-
[
|
386
|
-
/(sogou)mo\w+\/([\d\.]+)/i
|
387
|
-
// Sogou Mobile
|
388
|
-
],
|
389
|
-
[[NAME, "Sogou Mobile"], VERSION],
|
390
|
-
[
|
391
|
-
/(electron)\/([\w\.]+) safari/i,
|
392
|
-
// Electron-based App
|
393
|
-
/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,
|
394
|
-
// Tesla
|
395
|
-
/m?(qqbrowser|2345Explorer)[\/ ]?([\w\.]+)/i
|
396
|
-
// QQBrowser/2345 Browser
|
397
|
-
],
|
398
|
-
[NAME, VERSION],
|
399
|
-
[
|
400
|
-
/(lbbrowser)/i,
|
401
|
-
// LieBao Browser
|
402
|
-
/\[(linkedin)app\]/i
|
403
|
-
// LinkedIn App for iOS & Android
|
404
|
-
],
|
405
|
-
[NAME],
|
406
|
-
[
|
407
|
-
// WebView
|
408
|
-
/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i
|
409
|
-
// Facebook App for iOS & Android
|
410
|
-
],
|
411
|
-
[[NAME, FACEBOOK], VERSION],
|
412
|
-
[
|
413
|
-
/(Klarna)\/([\w\.]+)/i,
|
414
|
-
// Klarna Shopping Browser for iOS & Android
|
415
|
-
/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,
|
416
|
-
// Kakao App
|
417
|
-
/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,
|
418
|
-
// Naver InApp
|
419
|
-
/safari (line)\/([\w\.]+)/i,
|
420
|
-
// Line App for iOS
|
421
|
-
/\b(line)\/([\w\.]+)\/iab/i,
|
422
|
-
// Line App for Android
|
423
|
-
/(alipay)client\/([\w\.]+)/i,
|
424
|
-
// Alipay
|
425
|
-
/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i
|
426
|
-
// Chromium/Instagram/Snapchat
|
427
|
-
],
|
428
|
-
[NAME, VERSION],
|
429
|
-
[
|
430
|
-
/\bgsa\/([\w\.]+) .*safari\//i
|
431
|
-
// Google Search Appliance on iOS
|
432
|
-
],
|
433
|
-
[VERSION, [NAME, "GSA"]],
|
434
|
-
[
|
435
|
-
/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i
|
436
|
-
// TikTok
|
437
|
-
],
|
438
|
-
[VERSION, [NAME, "TikTok"]],
|
439
|
-
[
|
440
|
-
/headlesschrome(?:\/([\w\.]+)| )/i
|
441
|
-
// Chrome Headless
|
442
|
-
],
|
443
|
-
[VERSION, [NAME, CHROME + " Headless"]],
|
444
|
-
[
|
445
|
-
/ wv\).+(chrome)\/([\w\.]+)/i
|
446
|
-
// Chrome WebView
|
447
|
-
],
|
448
|
-
[[NAME, CHROME + " WebView"], VERSION],
|
449
|
-
[
|
450
|
-
/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i
|
451
|
-
// Android Browser
|
452
|
-
],
|
453
|
-
[VERSION, [NAME, "Android " + BROWSER]],
|
454
|
-
[
|
455
|
-
/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i
|
456
|
-
// Chrome/OmniWeb/Arora/Tizen/Nokia
|
457
|
-
],
|
458
|
-
[NAME, VERSION],
|
459
|
-
[
|
460
|
-
/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i
|
461
|
-
// Mobile Safari
|
462
|
-
],
|
463
|
-
[VERSION, [NAME, "Mobile Safari"]],
|
464
|
-
[
|
465
|
-
/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i
|
466
|
-
// Safari & Safari Mobile
|
467
|
-
],
|
468
|
-
[VERSION, NAME],
|
469
|
-
[
|
470
|
-
/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i
|
471
|
-
// Safari < 3.0
|
472
|
-
],
|
473
|
-
[NAME, [VERSION, strMapper, oldSafariMap]],
|
474
|
-
[
|
475
|
-
/(webkit|khtml)\/([\w\.]+)/i
|
476
|
-
],
|
477
|
-
[NAME, VERSION],
|
478
|
-
[
|
479
|
-
// Gecko based
|
480
|
-
/(navigator|netscape\d?)\/([-\w\.]+)/i
|
481
|
-
// Netscape
|
482
|
-
],
|
483
|
-
[[NAME, "Netscape"], VERSION],
|
484
|
-
[
|
485
|
-
/mobile vr; rv:([\w\.]+)\).+firefox/i
|
486
|
-
// Firefox Reality
|
487
|
-
],
|
488
|
-
[VERSION, [NAME, FIREFOX + " Reality"]],
|
489
|
-
[
|
490
|
-
/ekiohf.+(flow)\/([\w\.]+)/i,
|
491
|
-
// Flow
|
492
|
-
/(swiftfox)/i,
|
493
|
-
// Swiftfox
|
494
|
-
/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,
|
495
|
-
// IceDragon/Iceweasel/Camino/Chimera/Fennec/Maemo/Minimo/Conkeror/Klar
|
496
|
-
/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,
|
497
|
-
// Firefox/SeaMonkey/K-Meleon/IceCat/IceApe/Firebird/Phoenix
|
498
|
-
/(firefox)\/([\w\.]+)/i,
|
499
|
-
// Other Firefox-based
|
500
|
-
/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,
|
501
|
-
// Mozilla
|
502
|
-
// Other
|
503
|
-
/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,
|
504
|
-
// Polaris/Lynx/Dillo/iCab/Doris/Amaya/w3m/NetSurf/Sleipnir/Obigo/Mosaic/Go/ICE/UP.Browser
|
505
|
-
/(links) \(([\w\.]+)/i,
|
506
|
-
// Links
|
507
|
-
/panasonic;(viera)/i
|
508
|
-
// Panasonic Viera
|
509
|
-
],
|
510
|
-
[NAME, VERSION],
|
511
|
-
[
|
512
|
-
/(cobalt)\/([\w\.]+)/i
|
513
|
-
// Cobalt
|
514
|
-
],
|
515
|
-
[NAME, [VERSION, /master.|lts./, ""]]
|
516
|
-
],
|
517
|
-
cpu: [
|
518
|
-
[
|
519
|
-
/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i
|
520
|
-
// AMD64 (x64)
|
521
|
-
],
|
522
|
-
[[ARCHITECTURE, "amd64"]],
|
523
|
-
[
|
524
|
-
/(ia32(?=;))/i
|
525
|
-
// IA32 (quicktime)
|
526
|
-
],
|
527
|
-
[[ARCHITECTURE, lowerize]],
|
528
|
-
[
|
529
|
-
/((?:i[346]|x)86)[;\)]/i
|
530
|
-
// IA32 (x86)
|
531
|
-
],
|
532
|
-
[[ARCHITECTURE, "ia32"]],
|
533
|
-
[
|
534
|
-
/\b(aarch64|arm(v?8e?l?|_?64))\b/i
|
535
|
-
// ARM64
|
536
|
-
],
|
537
|
-
[[ARCHITECTURE, "arm64"]],
|
538
|
-
[
|
539
|
-
/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i
|
540
|
-
// ARMHF
|
541
|
-
],
|
542
|
-
[[ARCHITECTURE, "armhf"]],
|
543
|
-
[
|
544
|
-
// PocketPC mistakenly identified as PowerPC
|
545
|
-
/windows (ce|mobile); ppc;/i
|
546
|
-
],
|
547
|
-
[[ARCHITECTURE, "arm"]],
|
548
|
-
[
|
549
|
-
/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i
|
550
|
-
// PowerPC
|
551
|
-
],
|
552
|
-
[[ARCHITECTURE, /ower/, EMPTY, lowerize]],
|
553
|
-
[
|
554
|
-
/(sun4\w)[;\)]/i
|
555
|
-
// SPARC
|
556
|
-
],
|
557
|
-
[[ARCHITECTURE, "sparc"]],
|
558
|
-
[
|
559
|
-
/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i
|
560
|
-
// IA64, 68K, ARM/64, AVR/32, IRIX/64, MIPS/64, SPARC/64, PA-RISC
|
561
|
-
],
|
562
|
-
[[ARCHITECTURE, lowerize]]
|
563
|
-
],
|
564
|
-
device: [
|
565
|
-
[
|
566
|
-
//////////////////////////
|
567
|
-
// MOBILES & TABLETS
|
568
|
-
/////////////////////////
|
569
|
-
// Samsung
|
570
|
-
/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i
|
571
|
-
],
|
572
|
-
[MODEL, [VENDOR, SAMSUNG], [TYPE, TABLET]],
|
573
|
-
[
|
574
|
-
/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,
|
575
|
-
/samsung[- ]([-\w]+)/i,
|
576
|
-
/sec-(sgh\w+)/i
|
577
|
-
],
|
578
|
-
[MODEL, [VENDOR, SAMSUNG], [TYPE, MOBILE]],
|
579
|
-
[
|
580
|
-
// Apple
|
581
|
-
/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i
|
582
|
-
// iPod/iPhone
|
583
|
-
],
|
584
|
-
[MODEL, [VENDOR, APPLE], [TYPE, MOBILE]],
|
585
|
-
[
|
586
|
-
/\((ipad);[-\w\),; ]+apple/i,
|
587
|
-
// iPad
|
588
|
-
/applecoremedia\/[\w\.]+ \((ipad)/i,
|
589
|
-
/\b(ipad)\d\d?,\d\d?[;\]].+ios/i
|
590
|
-
],
|
591
|
-
[MODEL, [VENDOR, APPLE], [TYPE, TABLET]],
|
592
|
-
[
|
593
|
-
/(macintosh);/i
|
594
|
-
],
|
595
|
-
[MODEL, [VENDOR, APPLE]],
|
596
|
-
[
|
597
|
-
// Sharp
|
598
|
-
/\b(sh-?[altvz]?\d\d[a-ekm]?)/i
|
599
|
-
],
|
600
|
-
[MODEL, [VENDOR, SHARP], [TYPE, MOBILE]],
|
601
|
-
[
|
602
|
-
// Huawei
|
603
|
-
/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i
|
604
|
-
],
|
605
|
-
[MODEL, [VENDOR, HUAWEI], [TYPE, TABLET]],
|
606
|
-
[
|
607
|
-
/(?:huawei|honor)([-\w ]+)[;\)]/i,
|
608
|
-
/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i
|
609
|
-
],
|
610
|
-
[MODEL, [VENDOR, HUAWEI], [TYPE, MOBILE]],
|
611
|
-
[
|
612
|
-
// Xiaomi
|
613
|
-
/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,
|
614
|
-
// Xiaomi POCO
|
615
|
-
/\b; (\w+) build\/hm\1/i,
|
616
|
-
// Xiaomi Hongmi 'numeric' models
|
617
|
-
/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,
|
618
|
-
// Xiaomi Hongmi
|
619
|
-
/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,
|
620
|
-
// Xiaomi Redmi
|
621
|
-
/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,
|
622
|
-
// Xiaomi Redmi 'numeric' models
|
623
|
-
/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i
|
624
|
-
// Xiaomi Mi
|
625
|
-
],
|
626
|
-
[[MODEL, /_/g, " "], [VENDOR, XIAOMI], [TYPE, MOBILE]],
|
627
|
-
[
|
628
|
-
/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,
|
629
|
-
// Redmi Pad
|
630
|
-
/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i
|
631
|
-
// Mi Pad tablets
|
632
|
-
],
|
633
|
-
[[MODEL, /_/g, " "], [VENDOR, XIAOMI], [TYPE, TABLET]],
|
634
|
-
[
|
635
|
-
// OPPO
|
636
|
-
/; (\w+) bui.+ oppo/i,
|
637
|
-
/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i
|
638
|
-
],
|
639
|
-
[MODEL, [VENDOR, "OPPO"], [TYPE, MOBILE]],
|
640
|
-
[
|
641
|
-
// Vivo
|
642
|
-
/vivo (\w+)(?: bui|\))/i,
|
643
|
-
/\b(v[12]\d{3}\w?[at])(?: bui|;)/i
|
644
|
-
],
|
645
|
-
[MODEL, [VENDOR, "Vivo"], [TYPE, MOBILE]],
|
646
|
-
[
|
647
|
-
// Realme
|
648
|
-
/\b(rmx[1-3]\d{3})(?: bui|;|\))/i
|
649
|
-
],
|
650
|
-
[MODEL, [VENDOR, "Realme"], [TYPE, MOBILE]],
|
651
|
-
[
|
652
|
-
// Motorola
|
653
|
-
/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,
|
654
|
-
/\bmot(?:orola)?[- ](\w*)/i,
|
655
|
-
/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i
|
656
|
-
],
|
657
|
-
[MODEL, [VENDOR, MOTOROLA], [TYPE, MOBILE]],
|
658
|
-
[
|
659
|
-
/\b(mz60\d|xoom[2 ]{0,2}) build\//i
|
660
|
-
],
|
661
|
-
[MODEL, [VENDOR, MOTOROLA], [TYPE, TABLET]],
|
662
|
-
[
|
663
|
-
// LG
|
664
|
-
/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i
|
665
|
-
],
|
666
|
-
[MODEL, [VENDOR, LG], [TYPE, TABLET]],
|
667
|
-
[
|
668
|
-
/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,
|
669
|
-
/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,
|
670
|
-
/\blg-?([\d\w]+) bui/i
|
671
|
-
],
|
672
|
-
[MODEL, [VENDOR, LG], [TYPE, MOBILE]],
|
673
|
-
[
|
674
|
-
// Lenovo
|
675
|
-
/(ideatab[-\w ]+)/i,
|
676
|
-
/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i
|
677
|
-
],
|
678
|
-
[MODEL, [VENDOR, "Lenovo"], [TYPE, TABLET]],
|
679
|
-
[
|
680
|
-
// Nokia
|
681
|
-
/(?:maemo|nokia).*(n900|lumia \d+)/i,
|
682
|
-
/nokia[-_ ]?([-\w\.]*)/i
|
683
|
-
],
|
684
|
-
[[MODEL, /_/g, " "], [VENDOR, "Nokia"], [TYPE, MOBILE]],
|
685
|
-
[
|
686
|
-
// Google
|
687
|
-
/(pixel c)\b/i
|
688
|
-
// Google Pixel C
|
689
|
-
],
|
690
|
-
[MODEL, [VENDOR, GOOGLE], [TYPE, TABLET]],
|
691
|
-
[
|
692
|
-
/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i
|
693
|
-
// Google Pixel
|
694
|
-
],
|
695
|
-
[MODEL, [VENDOR, GOOGLE], [TYPE, MOBILE]],
|
696
|
-
[
|
697
|
-
// Sony
|
698
|
-
/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i
|
699
|
-
],
|
700
|
-
[MODEL, [VENDOR, SONY], [TYPE, MOBILE]],
|
701
|
-
[
|
702
|
-
/sony tablet [ps]/i,
|
703
|
-
/\b(?:sony)?sgp\w+(?: bui|\))/i
|
704
|
-
],
|
705
|
-
[[MODEL, "Xperia Tablet"], [VENDOR, SONY], [TYPE, TABLET]],
|
706
|
-
[
|
707
|
-
// OnePlus
|
708
|
-
/ (kb2005|in20[12]5|be20[12][59])\b/i,
|
709
|
-
/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i
|
710
|
-
],
|
711
|
-
[MODEL, [VENDOR, "OnePlus"], [TYPE, MOBILE]],
|
712
|
-
[
|
713
|
-
// Amazon
|
714
|
-
/(alexa)webm/i,
|
715
|
-
/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,
|
716
|
-
// Kindle Fire without Silk / Echo Show
|
717
|
-
/(kf[a-z]+)( bui|\)).+silk\//i
|
718
|
-
// Kindle Fire HD
|
719
|
-
],
|
720
|
-
[MODEL, [VENDOR, AMAZON], [TYPE, TABLET]],
|
721
|
-
[
|
722
|
-
/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i
|
723
|
-
// Fire Phone
|
724
|
-
],
|
725
|
-
[[MODEL, /(.+)/g, "Fire Phone $1"], [VENDOR, AMAZON], [TYPE, MOBILE]],
|
726
|
-
[
|
727
|
-
// BlackBerry
|
728
|
-
/(playbook);[-\w\),; ]+(rim)/i
|
729
|
-
// BlackBerry PlayBook
|
730
|
-
],
|
731
|
-
[MODEL, VENDOR, [TYPE, TABLET]],
|
732
|
-
[
|
733
|
-
/\b((?:bb[a-f]|st[hv])100-\d)/i,
|
734
|
-
/\(bb10; (\w+)/i
|
735
|
-
// BlackBerry 10
|
736
|
-
],
|
737
|
-
[MODEL, [VENDOR, BLACKBERRY], [TYPE, MOBILE]],
|
738
|
-
[
|
739
|
-
// Asus
|
740
|
-
/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i
|
741
|
-
],
|
742
|
-
[MODEL, [VENDOR, ASUS], [TYPE, TABLET]],
|
743
|
-
[
|
744
|
-
/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i
|
745
|
-
],
|
746
|
-
[MODEL, [VENDOR, ASUS], [TYPE, MOBILE]],
|
747
|
-
[
|
748
|
-
// HTC
|
749
|
-
/(nexus 9)/i
|
750
|
-
// HTC Nexus 9
|
751
|
-
],
|
752
|
-
[MODEL, [VENDOR, "HTC"], [TYPE, TABLET]],
|
753
|
-
[
|
754
|
-
/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,
|
755
|
-
// HTC
|
756
|
-
// ZTE
|
757
|
-
/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,
|
758
|
-
/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i
|
759
|
-
// Alcatel/GeeksPhone/Nexian/Panasonic/Sony
|
760
|
-
],
|
761
|
-
[VENDOR, [MODEL, /_/g, " "], [TYPE, MOBILE]],
|
762
|
-
[
|
763
|
-
// Acer
|
764
|
-
/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i
|
765
|
-
],
|
766
|
-
[MODEL, [VENDOR, "Acer"], [TYPE, TABLET]],
|
767
|
-
[
|
768
|
-
// Meizu
|
769
|
-
/droid.+; (m[1-5] note) bui/i,
|
770
|
-
/\bmz-([-\w]{2,})/i
|
771
|
-
],
|
772
|
-
[MODEL, [VENDOR, "Meizu"], [TYPE, MOBILE]],
|
773
|
-
[
|
774
|
-
// Ulefone
|
775
|
-
/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i
|
776
|
-
],
|
777
|
-
[MODEL, [VENDOR, "Ulefone"], [TYPE, MOBILE]],
|
778
|
-
[
|
779
|
-
// MIXED
|
780
|
-
/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,
|
781
|
-
// BlackBerry/BenQ/Palm/Sony-Ericsson/Acer/Asus/Dell/Meizu/Motorola/Polytron
|
782
|
-
/(hp) ([\w ]+\w)/i,
|
783
|
-
// HP iPAQ
|
784
|
-
/(asus)-?(\w+)/i,
|
785
|
-
// Asus
|
786
|
-
/(microsoft); (lumia[\w ]+)/i,
|
787
|
-
// Microsoft Lumia
|
788
|
-
/(lenovo)[-_ ]?([-\w]+)/i,
|
789
|
-
// Lenovo
|
790
|
-
/(jolla)/i,
|
791
|
-
// Jolla
|
792
|
-
/(oppo) ?([\w ]+) bui/i
|
793
|
-
// OPPO
|
794
|
-
],
|
795
|
-
[VENDOR, MODEL, [TYPE, MOBILE]],
|
796
|
-
[
|
797
|
-
/(kobo)\s(ereader|touch)/i,
|
798
|
-
// Kobo
|
799
|
-
/(archos) (gamepad2?)/i,
|
800
|
-
// Archos
|
801
|
-
/(hp).+(touchpad(?!.+tablet)|tablet)/i,
|
802
|
-
// HP TouchPad
|
803
|
-
/(kindle)\/([\w\.]+)/i,
|
804
|
-
// Kindle
|
805
|
-
/(nook)[\w ]+build\/(\w+)/i,
|
806
|
-
// Nook
|
807
|
-
/(dell) (strea[kpr\d ]*[\dko])/i,
|
808
|
-
// Dell Streak
|
809
|
-
/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,
|
810
|
-
// Le Pan Tablets
|
811
|
-
/(trinity)[- ]*(t\d{3}) bui/i,
|
812
|
-
// Trinity Tablets
|
813
|
-
/(gigaset)[- ]+(q\w{1,9}) bui/i,
|
814
|
-
// Gigaset Tablets
|
815
|
-
/(vodafone) ([\w ]+)(?:\)| bui)/i
|
816
|
-
// Vodafone
|
817
|
-
],
|
818
|
-
[VENDOR, MODEL, [TYPE, TABLET]],
|
819
|
-
[
|
820
|
-
/(surface duo)/i
|
821
|
-
// Surface Duo
|
822
|
-
],
|
823
|
-
[MODEL, [VENDOR, MICROSOFT], [TYPE, TABLET]],
|
824
|
-
[
|
825
|
-
/droid [\d\.]+; (fp\du?)(?: b|\))/i
|
826
|
-
// Fairphone
|
827
|
-
],
|
828
|
-
[MODEL, [VENDOR, "Fairphone"], [TYPE, MOBILE]],
|
829
|
-
[
|
830
|
-
/(u304aa)/i
|
831
|
-
// AT&T
|
832
|
-
],
|
833
|
-
[MODEL, [VENDOR, "AT&T"], [TYPE, MOBILE]],
|
834
|
-
[
|
835
|
-
/\bsie-(\w*)/i
|
836
|
-
// Siemens
|
837
|
-
],
|
838
|
-
[MODEL, [VENDOR, "Siemens"], [TYPE, MOBILE]],
|
839
|
-
[
|
840
|
-
/\b(rct\w+) b/i
|
841
|
-
// RCA Tablets
|
842
|
-
],
|
843
|
-
[MODEL, [VENDOR, "RCA"], [TYPE, TABLET]],
|
844
|
-
[
|
845
|
-
/\b(venue[\d ]{2,7}) b/i
|
846
|
-
// Dell Venue Tablets
|
847
|
-
],
|
848
|
-
[MODEL, [VENDOR, "Dell"], [TYPE, TABLET]],
|
849
|
-
[
|
850
|
-
/\b(q(?:mv|ta)\w+) b/i
|
851
|
-
// Verizon Tablet
|
852
|
-
],
|
853
|
-
[MODEL, [VENDOR, "Verizon"], [TYPE, TABLET]],
|
854
|
-
[
|
855
|
-
/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i
|
856
|
-
// Barnes & Noble Tablet
|
857
|
-
],
|
858
|
-
[MODEL, [VENDOR, "Barnes & Noble"], [TYPE, TABLET]],
|
859
|
-
[
|
860
|
-
/\b(tm\d{3}\w+) b/i
|
861
|
-
],
|
862
|
-
[MODEL, [VENDOR, "NuVision"], [TYPE, TABLET]],
|
863
|
-
[
|
864
|
-
/\b(k88) b/i
|
865
|
-
// ZTE K Series Tablet
|
866
|
-
],
|
867
|
-
[MODEL, [VENDOR, "ZTE"], [TYPE, TABLET]],
|
868
|
-
[
|
869
|
-
/\b(nx\d{3}j) b/i
|
870
|
-
// ZTE Nubia
|
871
|
-
],
|
872
|
-
[MODEL, [VENDOR, "ZTE"], [TYPE, MOBILE]],
|
873
|
-
[
|
874
|
-
/\b(gen\d{3}) b.+49h/i
|
875
|
-
// Swiss GEN Mobile
|
876
|
-
],
|
877
|
-
[MODEL, [VENDOR, "Swiss"], [TYPE, MOBILE]],
|
878
|
-
[
|
879
|
-
/\b(zur\d{3}) b/i
|
880
|
-
// Swiss ZUR Tablet
|
881
|
-
],
|
882
|
-
[MODEL, [VENDOR, "Swiss"], [TYPE, TABLET]],
|
883
|
-
[
|
884
|
-
/\b((zeki)?tb.*\b) b/i
|
885
|
-
// Zeki Tablets
|
886
|
-
],
|
887
|
-
[MODEL, [VENDOR, "Zeki"], [TYPE, TABLET]],
|
888
|
-
[
|
889
|
-
/\b([yr]\d{2}) b/i,
|
890
|
-
/\b(dragon[- ]+touch |dt)(\w{5}) b/i
|
891
|
-
// Dragon Touch Tablet
|
892
|
-
],
|
893
|
-
[[VENDOR, "Dragon Touch"], MODEL, [TYPE, TABLET]],
|
894
|
-
[
|
895
|
-
/\b(ns-?\w{0,9}) b/i
|
896
|
-
// Insignia Tablets
|
897
|
-
],
|
898
|
-
[MODEL, [VENDOR, "Insignia"], [TYPE, TABLET]],
|
899
|
-
[
|
900
|
-
/\b((nxa|next)-?\w{0,9}) b/i
|
901
|
-
// NextBook Tablets
|
902
|
-
],
|
903
|
-
[MODEL, [VENDOR, "NextBook"], [TYPE, TABLET]],
|
904
|
-
[
|
905
|
-
/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i
|
906
|
-
// Voice Xtreme Phones
|
907
|
-
],
|
908
|
-
[[VENDOR, "Voice"], MODEL, [TYPE, MOBILE]],
|
909
|
-
[
|
910
|
-
/\b(lvtel\-)?(v1[12]) b/i
|
911
|
-
// LvTel Phones
|
912
|
-
],
|
913
|
-
[[VENDOR, "LvTel"], MODEL, [TYPE, MOBILE]],
|
914
|
-
[
|
915
|
-
/\b(ph-1) /i
|
916
|
-
// Essential PH-1
|
917
|
-
],
|
918
|
-
[MODEL, [VENDOR, "Essential"], [TYPE, MOBILE]],
|
919
|
-
[
|
920
|
-
/\b(v(100md|700na|7011|917g).*\b) b/i
|
921
|
-
// Envizen Tablets
|
922
|
-
],
|
923
|
-
[MODEL, [VENDOR, "Envizen"], [TYPE, TABLET]],
|
924
|
-
[
|
925
|
-
/\b(trio[-\w\. ]+) b/i
|
926
|
-
// MachSpeed Tablets
|
927
|
-
],
|
928
|
-
[MODEL, [VENDOR, "MachSpeed"], [TYPE, TABLET]],
|
929
|
-
[
|
930
|
-
/\btu_(1491) b/i
|
931
|
-
// Rotor Tablets
|
932
|
-
],
|
933
|
-
[MODEL, [VENDOR, "Rotor"], [TYPE, TABLET]],
|
934
|
-
[
|
935
|
-
/(shield[\w ]+) b/i
|
936
|
-
// Nvidia Shield Tablets
|
937
|
-
],
|
938
|
-
[MODEL, [VENDOR, "Nvidia"], [TYPE, TABLET]],
|
939
|
-
[
|
940
|
-
/(sprint) (\w+)/i
|
941
|
-
// Sprint Phones
|
942
|
-
],
|
943
|
-
[VENDOR, MODEL, [TYPE, MOBILE]],
|
944
|
-
[
|
945
|
-
/(kin\.[onetw]{3})/i
|
946
|
-
// Microsoft Kin
|
947
|
-
],
|
948
|
-
[[MODEL, /\./g, " "], [VENDOR, MICROSOFT], [TYPE, MOBILE]],
|
949
|
-
[
|
950
|
-
/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i
|
951
|
-
// Zebra
|
952
|
-
],
|
953
|
-
[MODEL, [VENDOR, ZEBRA], [TYPE, TABLET]],
|
954
|
-
[
|
955
|
-
/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i
|
956
|
-
],
|
957
|
-
[MODEL, [VENDOR, ZEBRA], [TYPE, MOBILE]],
|
958
|
-
[
|
959
|
-
///////////////////
|
960
|
-
// SMARTTVS
|
961
|
-
///////////////////
|
962
|
-
/smart-tv.+(samsung)/i
|
963
|
-
// Samsung
|
964
|
-
],
|
965
|
-
[VENDOR, [TYPE, SMARTTV]],
|
966
|
-
[
|
967
|
-
/hbbtv.+maple;(\d+)/i
|
968
|
-
],
|
969
|
-
[[MODEL, /^/, "SmartTV"], [VENDOR, SAMSUNG], [TYPE, SMARTTV]],
|
970
|
-
[
|
971
|
-
/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i
|
972
|
-
// LG SmartTV
|
973
|
-
],
|
974
|
-
[[VENDOR, LG], [TYPE, SMARTTV]],
|
975
|
-
[
|
976
|
-
/(apple) ?tv/i
|
977
|
-
// Apple TV
|
978
|
-
],
|
979
|
-
[VENDOR, [MODEL, APPLE + " TV"], [TYPE, SMARTTV]],
|
980
|
-
[
|
981
|
-
/crkey/i
|
982
|
-
// Google Chromecast
|
983
|
-
],
|
984
|
-
[[MODEL, CHROME + "cast"], [VENDOR, GOOGLE], [TYPE, SMARTTV]],
|
985
|
-
[
|
986
|
-
/droid.+aft(\w+)( bui|\))/i
|
987
|
-
// Fire TV
|
988
|
-
],
|
989
|
-
[MODEL, [VENDOR, AMAZON], [TYPE, SMARTTV]],
|
990
|
-
[
|
991
|
-
/\(dtv[\);].+(aquos)/i,
|
992
|
-
/(aquos-tv[\w ]+)\)/i
|
993
|
-
// Sharp
|
994
|
-
],
|
995
|
-
[MODEL, [VENDOR, SHARP], [TYPE, SMARTTV]],
|
996
|
-
[
|
997
|
-
/(bravia[\w ]+)( bui|\))/i
|
998
|
-
// Sony
|
999
|
-
],
|
1000
|
-
[MODEL, [VENDOR, SONY], [TYPE, SMARTTV]],
|
1001
|
-
[
|
1002
|
-
/(mitv-\w{5}) bui/i
|
1003
|
-
// Xiaomi
|
1004
|
-
],
|
1005
|
-
[MODEL, [VENDOR, XIAOMI], [TYPE, SMARTTV]],
|
1006
|
-
[
|
1007
|
-
/Hbbtv.*(technisat) (.*);/i
|
1008
|
-
// TechniSAT
|
1009
|
-
],
|
1010
|
-
[VENDOR, MODEL, [TYPE, SMARTTV]],
|
1011
|
-
[
|
1012
|
-
/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,
|
1013
|
-
// Roku
|
1014
|
-
/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i
|
1015
|
-
// HbbTV devices
|
1016
|
-
],
|
1017
|
-
[[VENDOR, trim], [MODEL, trim], [TYPE, SMARTTV]],
|
1018
|
-
[
|
1019
|
-
/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i
|
1020
|
-
// SmartTV from Unidentified Vendors
|
1021
|
-
],
|
1022
|
-
[[TYPE, SMARTTV]],
|
1023
|
-
[
|
1024
|
-
///////////////////
|
1025
|
-
// CONSOLES
|
1026
|
-
///////////////////
|
1027
|
-
/(ouya)/i,
|
1028
|
-
// Ouya
|
1029
|
-
/(nintendo) ([wids3utch]+)/i
|
1030
|
-
// Nintendo
|
1031
|
-
],
|
1032
|
-
[VENDOR, MODEL, [TYPE, CONSOLE]],
|
1033
|
-
[
|
1034
|
-
/droid.+; (shield) bui/i
|
1035
|
-
// Nvidia
|
1036
|
-
],
|
1037
|
-
[MODEL, [VENDOR, "Nvidia"], [TYPE, CONSOLE]],
|
1038
|
-
[
|
1039
|
-
/(playstation [345portablevi]+)/i
|
1040
|
-
// Playstation
|
1041
|
-
],
|
1042
|
-
[MODEL, [VENDOR, SONY], [TYPE, CONSOLE]],
|
1043
|
-
[
|
1044
|
-
/\b(xbox(?: one)?(?!; xbox))[\); ]/i
|
1045
|
-
// Microsoft Xbox
|
1046
|
-
],
|
1047
|
-
[MODEL, [VENDOR, MICROSOFT], [TYPE, CONSOLE]],
|
1048
|
-
[
|
1049
|
-
///////////////////
|
1050
|
-
// WEARABLES
|
1051
|
-
///////////////////
|
1052
|
-
/((pebble))app/i
|
1053
|
-
// Pebble
|
1054
|
-
],
|
1055
|
-
[VENDOR, MODEL, [TYPE, WEARABLE]],
|
1056
|
-
[
|
1057
|
-
/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i
|
1058
|
-
// Apple Watch
|
1059
|
-
],
|
1060
|
-
[MODEL, [VENDOR, APPLE], [TYPE, WEARABLE]],
|
1061
|
-
[
|
1062
|
-
/droid.+; (glass) \d/i
|
1063
|
-
// Google Glass
|
1064
|
-
],
|
1065
|
-
[MODEL, [VENDOR, GOOGLE], [TYPE, WEARABLE]],
|
1066
|
-
[
|
1067
|
-
/droid.+; (wt63?0{2,3})\)/i
|
1068
|
-
],
|
1069
|
-
[MODEL, [VENDOR, ZEBRA], [TYPE, WEARABLE]],
|
1070
|
-
[
|
1071
|
-
/(quest( 2| pro)?)/i
|
1072
|
-
// Oculus Quest
|
1073
|
-
],
|
1074
|
-
[MODEL, [VENDOR, FACEBOOK], [TYPE, WEARABLE]],
|
1075
|
-
[
|
1076
|
-
///////////////////
|
1077
|
-
// EMBEDDED
|
1078
|
-
///////////////////
|
1079
|
-
/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i
|
1080
|
-
// Tesla
|
1081
|
-
],
|
1082
|
-
[VENDOR, [TYPE, EMBEDDED]],
|
1083
|
-
[
|
1084
|
-
/(aeobc)\b/i
|
1085
|
-
// Echo Dot
|
1086
|
-
],
|
1087
|
-
[MODEL, [VENDOR, AMAZON], [TYPE, EMBEDDED]],
|
1088
|
-
[
|
1089
|
-
////////////////////
|
1090
|
-
// MIXED (GENERIC)
|
1091
|
-
///////////////////
|
1092
|
-
/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i
|
1093
|
-
// Android Phones from Unidentified Vendors
|
1094
|
-
],
|
1095
|
-
[MODEL, [TYPE, MOBILE]],
|
1096
|
-
[
|
1097
|
-
/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i
|
1098
|
-
// Android Tablets from Unidentified Vendors
|
1099
|
-
],
|
1100
|
-
[MODEL, [TYPE, TABLET]],
|
1101
|
-
[
|
1102
|
-
/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i
|
1103
|
-
// Unidentifiable Tablet
|
1104
|
-
],
|
1105
|
-
[[TYPE, TABLET]],
|
1106
|
-
[
|
1107
|
-
/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i
|
1108
|
-
// Unidentifiable Mobile
|
1109
|
-
],
|
1110
|
-
[[TYPE, MOBILE]],
|
1111
|
-
[
|
1112
|
-
/(android[-\w\. ]{0,9});.+buil/i
|
1113
|
-
// Generic Android Device
|
1114
|
-
],
|
1115
|
-
[MODEL, [VENDOR, "Generic"]]
|
1116
|
-
],
|
1117
|
-
engine: [
|
1118
|
-
[
|
1119
|
-
/windows.+ edge\/([\w\.]+)/i
|
1120
|
-
// EdgeHTML
|
1121
|
-
],
|
1122
|
-
[VERSION, [NAME, EDGE + "HTML"]],
|
1123
|
-
[
|
1124
|
-
/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i
|
1125
|
-
// Blink
|
1126
|
-
],
|
1127
|
-
[VERSION, [NAME, "Blink"]],
|
1128
|
-
[
|
1129
|
-
/(presto)\/([\w\.]+)/i,
|
1130
|
-
// Presto
|
1131
|
-
/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,
|
1132
|
-
// WebKit/Trident/NetFront/NetSurf/Amaya/Lynx/w3m/Goanna
|
1133
|
-
/ekioh(flow)\/([\w\.]+)/i,
|
1134
|
-
// Flow
|
1135
|
-
/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,
|
1136
|
-
// KHTML/Tasman/Links
|
1137
|
-
/(icab)[\/ ]([23]\.[\d\.]+)/i,
|
1138
|
-
// iCab
|
1139
|
-
/\b(libweb)/i
|
1140
|
-
],
|
1141
|
-
[NAME, VERSION],
|
1142
|
-
[
|
1143
|
-
/rv\:([\w\.]{1,9})\b.+(gecko)/i
|
1144
|
-
// Gecko
|
1145
|
-
],
|
1146
|
-
[VERSION, NAME]
|
1147
|
-
],
|
1148
|
-
os: [
|
1149
|
-
[
|
1150
|
-
// Windows
|
1151
|
-
/microsoft (windows) (vista|xp)/i
|
1152
|
-
// Windows (iTunes)
|
1153
|
-
],
|
1154
|
-
[NAME, VERSION],
|
1155
|
-
[
|
1156
|
-
/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i
|
1157
|
-
// Windows Phone
|
1158
|
-
],
|
1159
|
-
[NAME, [VERSION, strMapper, windowsVersionMap]],
|
1160
|
-
[
|
1161
|
-
/windows nt 6\.2; (arm)/i,
|
1162
|
-
// Windows RT
|
1163
|
-
/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,
|
1164
|
-
/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i
|
1165
|
-
],
|
1166
|
-
[[VERSION, strMapper, windowsVersionMap], [NAME, "Windows"]],
|
1167
|
-
[
|
1168
|
-
// iOS/macOS
|
1169
|
-
/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,
|
1170
|
-
// iOS
|
1171
|
-
/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,
|
1172
|
-
/cfnetwork\/.+darwin/i
|
1173
|
-
],
|
1174
|
-
[[VERSION, /_/g, "."], [NAME, "iOS"]],
|
1175
|
-
[
|
1176
|
-
/(mac os x) ?([\w\. ]*)/i,
|
1177
|
-
/(macintosh|mac_powerpc\b)(?!.+haiku)/i
|
1178
|
-
// Mac OS
|
1179
|
-
],
|
1180
|
-
[[NAME, MAC_OS], [VERSION, /_/g, "."]],
|
1181
|
-
[
|
1182
|
-
// Mobile OSes
|
1183
|
-
/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i
|
1184
|
-
// Android-x86/HarmonyOS
|
1185
|
-
],
|
1186
|
-
[VERSION, NAME],
|
1187
|
-
[
|
1188
|
-
// Android/WebOS/QNX/Bada/RIM/Maemo/MeeGo/Sailfish OS
|
1189
|
-
/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,
|
1190
|
-
/(blackberry)\w*\/([\w\.]*)/i,
|
1191
|
-
// Blackberry
|
1192
|
-
/(tizen|kaios)[\/ ]([\w\.]+)/i,
|
1193
|
-
// Tizen/KaiOS
|
1194
|
-
/\((series40);/i
|
1195
|
-
// Series 40
|
1196
|
-
],
|
1197
|
-
[NAME, VERSION],
|
1198
|
-
[
|
1199
|
-
/\(bb(10);/i
|
1200
|
-
// BlackBerry 10
|
1201
|
-
],
|
1202
|
-
[VERSION, [NAME, BLACKBERRY]],
|
1203
|
-
[
|
1204
|
-
/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i
|
1205
|
-
// Symbian
|
1206
|
-
],
|
1207
|
-
[VERSION, [NAME, "Symbian"]],
|
1208
|
-
[
|
1209
|
-
/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i
|
1210
|
-
// Firefox OS
|
1211
|
-
],
|
1212
|
-
[VERSION, [NAME, FIREFOX + " OS"]],
|
1213
|
-
[
|
1214
|
-
/web0s;.+rt(tv)/i,
|
1215
|
-
/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i
|
1216
|
-
// WebOS
|
1217
|
-
],
|
1218
|
-
[VERSION, [NAME, "webOS"]],
|
1219
|
-
[
|
1220
|
-
/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i
|
1221
|
-
// watchOS
|
1222
|
-
],
|
1223
|
-
[VERSION, [NAME, "watchOS"]],
|
1224
|
-
[
|
1225
|
-
// Google Chromecast
|
1226
|
-
/crkey\/([\d\.]+)/i
|
1227
|
-
// Google Chromecast
|
1228
|
-
],
|
1229
|
-
[VERSION, [NAME, CHROME + "cast"]],
|
1230
|
-
[
|
1231
|
-
/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i
|
1232
|
-
// Chromium OS
|
1233
|
-
],
|
1234
|
-
[[NAME, CHROMIUM_OS], VERSION],
|
1235
|
-
[
|
1236
|
-
// Smart TVs
|
1237
|
-
/panasonic;(viera)/i,
|
1238
|
-
// Panasonic Viera
|
1239
|
-
/(netrange)mmh/i,
|
1240
|
-
// Netrange
|
1241
|
-
/(nettv)\/(\d+\.[\w\.]+)/i,
|
1242
|
-
// NetTV
|
1243
|
-
// Console
|
1244
|
-
/(nintendo|playstation) ([wids345portablevuch]+)/i,
|
1245
|
-
// Nintendo/Playstation
|
1246
|
-
/(xbox); +xbox ([^\);]+)/i,
|
1247
|
-
// Microsoft Xbox (360, One, X, S, Series X, Series S)
|
1248
|
-
// Other
|
1249
|
-
/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,
|
1250
|
-
// Joli/Palm
|
1251
|
-
/(mint)[\/\(\) ]?(\w*)/i,
|
1252
|
-
// Mint
|
1253
|
-
/(mageia|vectorlinux)[; ]/i,
|
1254
|
-
// Mageia/VectorLinux
|
1255
|
-
/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,
|
1256
|
-
// Ubuntu/Debian/SUSE/Gentoo/Arch/Slackware/Fedora/Mandriva/CentOS/PCLinuxOS/RedHat/Zenwalk/Linpus/Raspbian/Plan9/Minix/RISCOS/Contiki/Deepin/Manjaro/elementary/Sabayon/Linspire
|
1257
|
-
/(hurd|linux) ?([\w\.]*)/i,
|
1258
|
-
// Hurd/Linux
|
1259
|
-
/(gnu) ?([\w\.]*)/i,
|
1260
|
-
// GNU
|
1261
|
-
/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,
|
1262
|
-
// FreeBSD/NetBSD/OpenBSD/PC-BSD/GhostBSD/DragonFly
|
1263
|
-
/(haiku) (\w+)/i
|
1264
|
-
// Haiku
|
1265
|
-
],
|
1266
|
-
[NAME, VERSION],
|
1267
|
-
[
|
1268
|
-
/(sunos) ?([\w\.\d]*)/i
|
1269
|
-
// Solaris
|
1270
|
-
],
|
1271
|
-
[[NAME, "Solaris"], VERSION],
|
1272
|
-
[
|
1273
|
-
/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,
|
1274
|
-
// Solaris
|
1275
|
-
/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,
|
1276
|
-
// AIX
|
1277
|
-
/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,
|
1278
|
-
// BeOS/OS2/AmigaOS/MorphOS/OpenVMS/Fuchsia/HP-UX/SerenityOS
|
1279
|
-
/(unix) ?([\w\.]*)/i
|
1280
|
-
// UNIX
|
1281
|
-
],
|
1282
|
-
[NAME, VERSION]
|
1283
|
-
]
|
1284
|
-
};
|
1285
|
-
var UAParser2 = function(ua, extensions) {
|
1286
|
-
if (typeof ua === OBJ_TYPE) {
|
1287
|
-
extensions = ua;
|
1288
|
-
ua = undefined2;
|
1289
|
-
}
|
1290
|
-
if (!(this instanceof UAParser2)) {
|
1291
|
-
return new UAParser2(ua, extensions).getResult();
|
1292
|
-
}
|
1293
|
-
var _navigator = typeof window2 !== UNDEF_TYPE && window2.navigator ? window2.navigator : undefined2;
|
1294
|
-
var _ua = ua || (_navigator && _navigator.userAgent ? _navigator.userAgent : EMPTY);
|
1295
|
-
var _uach = _navigator && _navigator.userAgentData ? _navigator.userAgentData : undefined2;
|
1296
|
-
var _rgxmap = extensions ? extend(regexes, extensions) : regexes;
|
1297
|
-
var _isSelfNav = _navigator && _navigator.userAgent == _ua;
|
1298
|
-
this.getBrowser = function() {
|
1299
|
-
var _browser = {};
|
1300
|
-
_browser[NAME] = undefined2;
|
1301
|
-
_browser[VERSION] = undefined2;
|
1302
|
-
rgxMapper.call(_browser, _ua, _rgxmap.browser);
|
1303
|
-
_browser[MAJOR] = majorize(_browser[VERSION]);
|
1304
|
-
if (_isSelfNav && _navigator && _navigator.brave && typeof _navigator.brave.isBrave == FUNC_TYPE) {
|
1305
|
-
_browser[NAME] = "Brave";
|
1306
|
-
}
|
1307
|
-
return _browser;
|
1308
|
-
};
|
1309
|
-
this.getCPU = function() {
|
1310
|
-
var _cpu = {};
|
1311
|
-
_cpu[ARCHITECTURE] = undefined2;
|
1312
|
-
rgxMapper.call(_cpu, _ua, _rgxmap.cpu);
|
1313
|
-
return _cpu;
|
1314
|
-
};
|
1315
|
-
this.getDevice = function() {
|
1316
|
-
var _device = {};
|
1317
|
-
_device[VENDOR] = undefined2;
|
1318
|
-
_device[MODEL] = undefined2;
|
1319
|
-
_device[TYPE] = undefined2;
|
1320
|
-
rgxMapper.call(_device, _ua, _rgxmap.device);
|
1321
|
-
if (_isSelfNav && !_device[TYPE] && _uach && _uach.mobile) {
|
1322
|
-
_device[TYPE] = MOBILE;
|
1323
|
-
}
|
1324
|
-
if (_isSelfNav && _device[MODEL] == "Macintosh" && _navigator && typeof _navigator.standalone !== UNDEF_TYPE && _navigator.maxTouchPoints && _navigator.maxTouchPoints > 2) {
|
1325
|
-
_device[MODEL] = "iPad";
|
1326
|
-
_device[TYPE] = TABLET;
|
1327
|
-
}
|
1328
|
-
return _device;
|
1329
|
-
};
|
1330
|
-
this.getEngine = function() {
|
1331
|
-
var _engine = {};
|
1332
|
-
_engine[NAME] = undefined2;
|
1333
|
-
_engine[VERSION] = undefined2;
|
1334
|
-
rgxMapper.call(_engine, _ua, _rgxmap.engine);
|
1335
|
-
return _engine;
|
1336
|
-
};
|
1337
|
-
this.getOS = function() {
|
1338
|
-
var _os = {};
|
1339
|
-
_os[NAME] = undefined2;
|
1340
|
-
_os[VERSION] = undefined2;
|
1341
|
-
rgxMapper.call(_os, _ua, _rgxmap.os);
|
1342
|
-
if (_isSelfNav && !_os[NAME] && _uach && _uach.platform != "Unknown") {
|
1343
|
-
_os[NAME] = _uach.platform.replace(/chrome os/i, CHROMIUM_OS).replace(/macos/i, MAC_OS);
|
1344
|
-
}
|
1345
|
-
return _os;
|
1346
|
-
};
|
1347
|
-
this.getResult = function() {
|
1348
|
-
return {
|
1349
|
-
ua: this.getUA(),
|
1350
|
-
browser: this.getBrowser(),
|
1351
|
-
engine: this.getEngine(),
|
1352
|
-
os: this.getOS(),
|
1353
|
-
device: this.getDevice(),
|
1354
|
-
cpu: this.getCPU()
|
1355
|
-
};
|
1356
|
-
};
|
1357
|
-
this.getUA = function() {
|
1358
|
-
return _ua;
|
1359
|
-
};
|
1360
|
-
this.setUA = function(ua2) {
|
1361
|
-
_ua = typeof ua2 === STR_TYPE && ua2.length > UA_MAX_LENGTH ? trim(ua2, UA_MAX_LENGTH) : ua2;
|
1362
|
-
return this;
|
1363
|
-
};
|
1364
|
-
this.setUA(_ua);
|
1365
|
-
return this;
|
1366
|
-
};
|
1367
|
-
UAParser2.VERSION = LIBVERSION;
|
1368
|
-
UAParser2.BROWSER = enumerize([NAME, VERSION, MAJOR]);
|
1369
|
-
UAParser2.CPU = enumerize([ARCHITECTURE]);
|
1370
|
-
UAParser2.DEVICE = enumerize([MODEL, VENDOR, TYPE, CONSOLE, MOBILE, SMARTTV, TABLET, WEARABLE, EMBEDDED]);
|
1371
|
-
UAParser2.ENGINE = UAParser2.OS = enumerize([NAME, VERSION]);
|
1372
|
-
if (typeof exports !== UNDEF_TYPE) {
|
1373
|
-
if (typeof module !== UNDEF_TYPE && module.exports) {
|
1374
|
-
exports = module.exports = UAParser2;
|
1375
|
-
}
|
1376
|
-
exports.UAParser = UAParser2;
|
1377
|
-
} else {
|
1378
|
-
if (typeof define === FUNC_TYPE && define.amd) {
|
1379
|
-
define(function() {
|
1380
|
-
return UAParser2;
|
1381
|
-
});
|
1382
|
-
} else if (typeof window2 !== UNDEF_TYPE) {
|
1383
|
-
window2.UAParser = UAParser2;
|
1384
|
-
}
|
1385
|
-
}
|
1386
|
-
var $ = typeof window2 !== UNDEF_TYPE && (window2.jQuery || window2.Zepto);
|
1387
|
-
if ($ && !$.ua) {
|
1388
|
-
var parser = new UAParser2();
|
1389
|
-
$.ua = parser.getResult();
|
1390
|
-
$.ua.get = function() {
|
1391
|
-
return parser.getUA();
|
1392
|
-
};
|
1393
|
-
$.ua.set = function(ua) {
|
1394
|
-
parser.setUA(ua);
|
1395
|
-
var result = parser.getResult();
|
1396
|
-
for (var prop in result) {
|
1397
|
-
$.ua[prop] = result[prop];
|
1398
|
-
}
|
1399
|
-
};
|
1400
|
-
}
|
1401
|
-
})(typeof window === "object" ? window : exports);
|
1402
|
-
}
|
1403
|
-
});
|
1404
|
-
|
1405
119
|
// index.ts
|
1406
120
|
init_react_import();
|
1407
121
|
|
@@ -1534,10 +248,17 @@ import { useContext as useContext2, useMemo } from "react";
|
|
1534
248
|
|
1535
249
|
// ../core/components/DropZone/context.tsx
|
1536
250
|
init_react_import();
|
251
|
+
import { createContext, useCallback, useState } from "react";
|
252
|
+
import { Fragment, jsx as jsx2 } from "react/jsx-runtime";
|
253
|
+
var dropZoneContext = createContext(null);
|
254
|
+
|
255
|
+
// ../core/components/Puck/context.tsx
|
256
|
+
init_react_import();
|
1537
257
|
import {
|
1538
|
-
createContext,
|
1539
|
-
|
1540
|
-
|
258
|
+
createContext as createContext2,
|
259
|
+
useContext,
|
260
|
+
useEffect as useEffect3,
|
261
|
+
useState as useState4
|
1541
262
|
} from "react";
|
1542
263
|
|
1543
264
|
// ../core/lib/get-item.ts
|
@@ -1550,31 +271,6 @@ var rootDroppableId = "default-zone";
|
|
1550
271
|
// ../core/lib/setup-zone.ts
|
1551
272
|
init_react_import();
|
1552
273
|
|
1553
|
-
// ../core/lib/get-zone-id.ts
|
1554
|
-
init_react_import();
|
1555
|
-
var getZoneId = (zoneCompound) => {
|
1556
|
-
if (!zoneCompound) {
|
1557
|
-
return [];
|
1558
|
-
}
|
1559
|
-
if (zoneCompound && zoneCompound.indexOf(":") > -1) {
|
1560
|
-
return zoneCompound.split(":");
|
1561
|
-
}
|
1562
|
-
return [rootDroppableId, zoneCompound];
|
1563
|
-
};
|
1564
|
-
|
1565
|
-
// ../core/components/DropZone/context.tsx
|
1566
|
-
import { Fragment, jsx as jsx2 } from "react/jsx-runtime";
|
1567
|
-
var dropZoneContext = createContext(null);
|
1568
|
-
|
1569
|
-
// ../core/components/Puck/context.tsx
|
1570
|
-
init_react_import();
|
1571
|
-
import {
|
1572
|
-
createContext as createContext2,
|
1573
|
-
useContext,
|
1574
|
-
useEffect as useEffect3,
|
1575
|
-
useState as useState4
|
1576
|
-
} from "react";
|
1577
|
-
|
1578
274
|
// ../core/components/ViewportControls/default-viewports.ts
|
1579
275
|
init_react_import();
|
1580
276
|
var defaultViewports = [
|
@@ -1583,9 +279,6 @@ var defaultViewports = [
|
|
1583
279
|
{ width: 1280, height: "auto", icon: "Monitor", label: "Large" }
|
1584
280
|
];
|
1585
281
|
|
1586
|
-
// ../core/components/Puck/context.tsx
|
1587
|
-
var import_ua_parser_js = __toESM(require_ua_parser());
|
1588
|
-
|
1589
282
|
// ../core/lib/use-resolved-permissions.ts
|
1590
283
|
init_react_import();
|
1591
284
|
import { useCallback as useCallback2, useEffect, useState as useState2 } from "react";
|
@@ -1653,7 +346,6 @@ var defaultContext = {
|
|
1653
346
|
status: "LOADING",
|
1654
347
|
setStatus: () => null,
|
1655
348
|
iframe: {},
|
1656
|
-
safariFallbackMode: false,
|
1657
349
|
globalPermissions: {},
|
1658
350
|
getPermissions: () => ({}),
|
1659
351
|
refreshPermissions: () => null
|
@@ -1673,6 +365,18 @@ function useAppContext() {
|
|
1673
365
|
});
|
1674
366
|
}
|
1675
367
|
|
368
|
+
// ../core/lib/get-zone-id.ts
|
369
|
+
init_react_import();
|
370
|
+
var getZoneId = (zoneCompound) => {
|
371
|
+
if (!zoneCompound) {
|
372
|
+
return [];
|
373
|
+
}
|
374
|
+
if (zoneCompound && zoneCompound.indexOf(":") > -1) {
|
375
|
+
return zoneCompound.split(":");
|
376
|
+
}
|
377
|
+
return [rootDroppableId, zoneCompound];
|
378
|
+
};
|
379
|
+
|
1676
380
|
// ../core/lib/use-breadcrumbs.ts
|
1677
381
|
var convertPathDataToBreadcrumbs = (selectedItem, pathData, data) => {
|
1678
382
|
const id = selectedItem ? selectedItem == null ? void 0 : selectedItem.props.id : "";
|
@@ -1866,11 +570,12 @@ var scrollIntoView = (el) => {
|
|
1866
570
|
// ../core/lib/get-frame.ts
|
1867
571
|
init_react_import();
|
1868
572
|
var getFrame = () => {
|
1869
|
-
|
1870
|
-
|
1871
|
-
|
573
|
+
if (typeof window === "undefined") return;
|
574
|
+
let frameEl = document.querySelector("#preview-frame");
|
575
|
+
if ((frameEl == null ? void 0 : frameEl.tagName) === "IFRAME") {
|
576
|
+
return frameEl.contentDocument || document;
|
1872
577
|
}
|
1873
|
-
return
|
578
|
+
return (frameEl == null ? void 0 : frameEl.ownerDocument) || document;
|
1874
579
|
};
|
1875
580
|
|
1876
581
|
// src/HeadingAnalyzer.tsx
|