@measured/puck-plugin-heading-analyzer 0.17.0-canary.229cbdd → 0.17.0-canary.858bfe7

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