@continuous-excellence/ze-great-dashboard-aws 0.31.43 → 0.31.45
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.
- package/dist/lambda.mjs +2246 -914
- package/package.json +1 -1
package/dist/lambda.mjs
CHANGED
|
@@ -9449,7 +9449,7 @@ var init_RpcProtocol = __esm({
|
|
|
9449
9449
|
const deserializer = this.deserializer;
|
|
9450
9450
|
const ns = NormalizedSchema.of(operationSchema.output);
|
|
9451
9451
|
const dataObject = {};
|
|
9452
|
-
if (response.statusCode
|
|
9452
|
+
if (this.isErrorResponse(response.statusCode)) {
|
|
9453
9453
|
const bytes = await collectBody(response.body, context);
|
|
9454
9454
|
if (bytes.byteLength > 0) {
|
|
9455
9455
|
Object.assign(dataObject, await deserializer.read(15, bytes));
|
|
@@ -9480,6 +9480,49 @@ var init_RpcProtocol = __esm({
|
|
|
9480
9480
|
dataObject.$metadata = this.deserializeMetadata(response);
|
|
9481
9481
|
return dataObject;
|
|
9482
9482
|
}
|
|
9483
|
+
isErrorResponse(statusCode) {
|
|
9484
|
+
return statusCode >= 300;
|
|
9485
|
+
}
|
|
9486
|
+
};
|
|
9487
|
+
}
|
|
9488
|
+
});
|
|
9489
|
+
|
|
9490
|
+
// node_modules/@smithy/core/dist-es/submodules/protocols/AbstractRpcV2Protocol.js
|
|
9491
|
+
var AbstractRpcV2Protocol;
|
|
9492
|
+
var init_AbstractRpcV2Protocol = __esm({
|
|
9493
|
+
"node_modules/@smithy/core/dist-es/submodules/protocols/AbstractRpcV2Protocol.js"() {
|
|
9494
|
+
init_schema();
|
|
9495
|
+
init_transport();
|
|
9496
|
+
init_RpcProtocol();
|
|
9497
|
+
AbstractRpcV2Protocol = class extends RpcProtocol {
|
|
9498
|
+
constructor({ defaultNamespace, errorTypeRegistries: errorTypeRegistries5 }) {
|
|
9499
|
+
super({ defaultNamespace, errorTypeRegistries: errorTypeRegistries5 });
|
|
9500
|
+
}
|
|
9501
|
+
async serializeRequest(operationSchema, input2, context) {
|
|
9502
|
+
const request = await super.serializeRequest(operationSchema, input2, context);
|
|
9503
|
+
Object.assign(request.headers, {
|
|
9504
|
+
"content-type": this.getDefaultContentType(),
|
|
9505
|
+
"smithy-protocol": this.getSmithyProtocolHeaderValue(),
|
|
9506
|
+
accept: this.getDefaultContentType()
|
|
9507
|
+
});
|
|
9508
|
+
if (deref(operationSchema.input) === "unit") {
|
|
9509
|
+
delete request.body;
|
|
9510
|
+
delete request.headers["content-type"];
|
|
9511
|
+
} else {
|
|
9512
|
+
this.applyEmptyBody(request);
|
|
9513
|
+
}
|
|
9514
|
+
const { service, operation: operation2 } = getSmithyContext(context);
|
|
9515
|
+
const path = `/service/${service}/operation/${operation2}`;
|
|
9516
|
+
if (request.path.endsWith("/")) {
|
|
9517
|
+
request.path += path.slice(1);
|
|
9518
|
+
} else {
|
|
9519
|
+
request.path += path;
|
|
9520
|
+
}
|
|
9521
|
+
return request;
|
|
9522
|
+
}
|
|
9523
|
+
isErrorResponse(statusCode) {
|
|
9524
|
+
return statusCode !== 200;
|
|
9525
|
+
}
|
|
9483
9526
|
};
|
|
9484
9527
|
}
|
|
9485
9528
|
});
|
|
@@ -11263,12 +11306,11 @@ var init_JsonCodec2 = __esm({
|
|
|
11263
11306
|
var SmithyRpcV2JsonProtocol;
|
|
11264
11307
|
var init_SmithyRpcV2JsonProtocol = __esm({
|
|
11265
11308
|
"node_modules/@smithy/core/dist-es/submodules/protocols/json/SmithyRpcV2JsonProtocol.js"() {
|
|
11266
|
-
|
|
11309
|
+
init_AbstractRpcV2Protocol();
|
|
11267
11310
|
init_schema();
|
|
11268
|
-
init_transport();
|
|
11269
11311
|
init_JsonCodec2();
|
|
11270
11312
|
init_parseJsonBody();
|
|
11271
|
-
SmithyRpcV2JsonProtocol = class extends
|
|
11313
|
+
SmithyRpcV2JsonProtocol = class extends AbstractRpcV2Protocol {
|
|
11272
11314
|
codec = new JsonCodec2({
|
|
11273
11315
|
timestampFormat: {
|
|
11274
11316
|
useTrait: false,
|
|
@@ -11279,39 +11321,19 @@ var init_SmithyRpcV2JsonProtocol = __esm({
|
|
|
11279
11321
|
});
|
|
11280
11322
|
serializer = this.codec.createSerializer();
|
|
11281
11323
|
deserializer = this.codec.createDeserializer();
|
|
11282
|
-
constructor({ defaultNamespace, errorTypeRegistries: errorTypeRegistries5 }) {
|
|
11283
|
-
super({ defaultNamespace, errorTypeRegistries: errorTypeRegistries5 });
|
|
11284
|
-
}
|
|
11285
11324
|
getShapeId() {
|
|
11286
11325
|
return "smithy.protocols#rpcv2Json";
|
|
11287
11326
|
}
|
|
11288
11327
|
getPayloadCodec() {
|
|
11289
11328
|
return this.codec;
|
|
11290
11329
|
}
|
|
11291
|
-
|
|
11292
|
-
|
|
11293
|
-
|
|
11294
|
-
|
|
11295
|
-
|
|
11296
|
-
accept: this.getDefaultContentType()
|
|
11297
|
-
});
|
|
11298
|
-
if (deref(operationSchema.input) === "unit") {
|
|
11299
|
-
delete request.body;
|
|
11300
|
-
delete request.headers["content-type"];
|
|
11301
|
-
} else if (!request.body) {
|
|
11330
|
+
getSmithyProtocolHeaderValue() {
|
|
11331
|
+
return "rpc-v2-json";
|
|
11332
|
+
}
|
|
11333
|
+
applyEmptyBody(request) {
|
|
11334
|
+
if (!request.body) {
|
|
11302
11335
|
request.body = "{}";
|
|
11303
11336
|
}
|
|
11304
|
-
const { service, operation: operation2 } = getSmithyContext(context);
|
|
11305
|
-
const path = `/service/${service}/operation/${operation2}`;
|
|
11306
|
-
if (request.path.endsWith("/")) {
|
|
11307
|
-
request.path += path.slice(1);
|
|
11308
|
-
} else {
|
|
11309
|
-
request.path += path;
|
|
11310
|
-
}
|
|
11311
|
-
return request;
|
|
11312
|
-
}
|
|
11313
|
-
async deserializeResponse(operationSchema, context, response) {
|
|
11314
|
-
return super.deserializeResponse(operationSchema, context, response);
|
|
11315
11337
|
}
|
|
11316
11338
|
async handleError(operationSchema, context, response, dataObject, metadata) {
|
|
11317
11339
|
const errorName = loadSmithyRpcV2JsonErrorCode(response, dataObject) ?? "Unknown";
|
|
@@ -11823,6 +11845,7 @@ var init_JsonCodec = __esm({
|
|
|
11823
11845
|
// node_modules/@smithy/core/dist-es/submodules/protocols/index.js
|
|
11824
11846
|
var protocols_exports = {};
|
|
11825
11847
|
__export(protocols_exports, {
|
|
11848
|
+
AbstractRpcV2Protocol: () => AbstractRpcV2Protocol,
|
|
11826
11849
|
Field: () => Field,
|
|
11827
11850
|
Fields: () => Fields,
|
|
11828
11851
|
FromStringShapeDeserializer: () => FromStringShapeDeserializer,
|
|
@@ -11872,6 +11895,7 @@ var init_protocols = __esm({
|
|
|
11872
11895
|
init_HttpBindingProtocol();
|
|
11873
11896
|
init_HttpProtocol();
|
|
11874
11897
|
init_RpcProtocol();
|
|
11898
|
+
init_AbstractRpcV2Protocol();
|
|
11875
11899
|
init_requestBuilder();
|
|
11876
11900
|
init_resolve_path();
|
|
11877
11901
|
init_FromStringShapeDeserializer();
|
|
@@ -14351,819 +14375,2092 @@ var init_nodeAppIdConfigOptions = __esm({
|
|
|
14351
14375
|
}
|
|
14352
14376
|
});
|
|
14353
14377
|
|
|
14354
|
-
// node_modules/bowser/
|
|
14355
|
-
var
|
|
14356
|
-
|
|
14357
|
-
|
|
14358
|
-
|
|
14359
|
-
|
|
14360
|
-
|
|
14361
|
-
|
|
14362
|
-
|
|
14363
|
-
|
|
14364
|
-
|
|
14365
|
-
|
|
14366
|
-
|
|
14367
|
-
|
|
14368
|
-
|
|
14369
|
-
|
|
14370
|
-
|
|
14371
|
-
|
|
14372
|
-
|
|
14373
|
-
|
|
14374
|
-
|
|
14375
|
-
|
|
14376
|
-
|
|
14377
|
-
|
|
14378
|
-
|
|
14379
|
-
|
|
14380
|
-
|
|
14381
|
-
|
|
14382
|
-
|
|
14383
|
-
|
|
14384
|
-
|
|
14385
|
-
|
|
14386
|
-
|
|
14387
|
-
|
|
14388
|
-
|
|
14389
|
-
|
|
14390
|
-
|
|
14391
|
-
|
|
14392
|
-
|
|
14393
|
-
|
|
14394
|
-
|
|
14395
|
-
|
|
14396
|
-
|
|
14397
|
-
|
|
14398
|
-
|
|
14399
|
-
|
|
14400
|
-
|
|
14401
|
-
|
|
14402
|
-
|
|
14403
|
-
|
|
14404
|
-
|
|
14405
|
-
|
|
14406
|
-
|
|
14407
|
-
|
|
14408
|
-
|
|
14409
|
-
|
|
14410
|
-
|
|
14411
|
-
|
|
14412
|
-
|
|
14413
|
-
|
|
14414
|
-
|
|
14415
|
-
|
|
14416
|
-
|
|
14417
|
-
|
|
14418
|
-
|
|
14419
|
-
|
|
14420
|
-
|
|
14421
|
-
|
|
14422
|
-
|
|
14423
|
-
|
|
14424
|
-
|
|
14425
|
-
|
|
14426
|
-
|
|
14427
|
-
|
|
14428
|
-
|
|
14429
|
-
|
|
14430
|
-
|
|
14431
|
-
|
|
14432
|
-
|
|
14433
|
-
|
|
14434
|
-
|
|
14435
|
-
|
|
14436
|
-
|
|
14437
|
-
|
|
14438
|
-
|
|
14439
|
-
|
|
14440
|
-
|
|
14441
|
-
|
|
14442
|
-
|
|
14443
|
-
|
|
14444
|
-
|
|
14445
|
-
|
|
14446
|
-
|
|
14447
|
-
|
|
14448
|
-
|
|
14449
|
-
|
|
14450
|
-
|
|
14451
|
-
|
|
14452
|
-
|
|
14453
|
-
|
|
14454
|
-
|
|
14455
|
-
|
|
14456
|
-
|
|
14457
|
-
|
|
14458
|
-
|
|
14459
|
-
|
|
14460
|
-
|
|
14461
|
-
|
|
14462
|
-
|
|
14463
|
-
|
|
14464
|
-
|
|
14465
|
-
|
|
14466
|
-
|
|
14467
|
-
|
|
14468
|
-
|
|
14469
|
-
|
|
14470
|
-
|
|
14471
|
-
|
|
14472
|
-
|
|
14473
|
-
|
|
14474
|
-
|
|
14475
|
-
|
|
14476
|
-
|
|
14477
|
-
|
|
14478
|
-
|
|
14479
|
-
|
|
14480
|
-
|
|
14481
|
-
|
|
14482
|
-
|
|
14483
|
-
|
|
14484
|
-
|
|
14485
|
-
|
|
14486
|
-
|
|
14487
|
-
|
|
14488
|
-
|
|
14489
|
-
|
|
14490
|
-
|
|
14491
|
-
|
|
14492
|
-
|
|
14493
|
-
|
|
14494
|
-
|
|
14495
|
-
|
|
14496
|
-
|
|
14497
|
-
|
|
14498
|
-
|
|
14499
|
-
|
|
14500
|
-
|
|
14501
|
-
|
|
14502
|
-
|
|
14503
|
-
|
|
14504
|
-
|
|
14505
|
-
|
|
14506
|
-
|
|
14507
|
-
|
|
14508
|
-
|
|
14509
|
-
|
|
14510
|
-
|
|
14511
|
-
|
|
14512
|
-
|
|
14513
|
-
|
|
14514
|
-
|
|
14515
|
-
|
|
14516
|
-
|
|
14517
|
-
|
|
14518
|
-
|
|
14519
|
-
|
|
14520
|
-
|
|
14521
|
-
|
|
14522
|
-
|
|
14523
|
-
|
|
14524
|
-
|
|
14525
|
-
|
|
14526
|
-
|
|
14527
|
-
|
|
14528
|
-
|
|
14529
|
-
|
|
14530
|
-
|
|
14531
|
-
|
|
14532
|
-
|
|
14533
|
-
|
|
14534
|
-
|
|
14535
|
-
|
|
14536
|
-
|
|
14537
|
-
|
|
14538
|
-
|
|
14539
|
-
|
|
14540
|
-
|
|
14541
|
-
|
|
14542
|
-
|
|
14543
|
-
|
|
14544
|
-
|
|
14545
|
-
|
|
14546
|
-
|
|
14547
|
-
|
|
14548
|
-
|
|
14549
|
-
|
|
14550
|
-
|
|
14551
|
-
|
|
14552
|
-
|
|
14553
|
-
|
|
14554
|
-
|
|
14555
|
-
|
|
14556
|
-
|
|
14557
|
-
|
|
14558
|
-
|
|
14559
|
-
|
|
14560
|
-
|
|
14561
|
-
|
|
14562
|
-
|
|
14563
|
-
|
|
14564
|
-
|
|
14565
|
-
|
|
14566
|
-
|
|
14567
|
-
|
|
14568
|
-
|
|
14569
|
-
|
|
14570
|
-
|
|
14571
|
-
|
|
14572
|
-
|
|
14573
|
-
|
|
14574
|
-
|
|
14575
|
-
|
|
14576
|
-
|
|
14577
|
-
|
|
14578
|
-
|
|
14579
|
-
|
|
14580
|
-
|
|
14581
|
-
|
|
14582
|
-
|
|
14583
|
-
|
|
14584
|
-
|
|
14585
|
-
|
|
14586
|
-
|
|
14587
|
-
|
|
14588
|
-
|
|
14589
|
-
|
|
14590
|
-
|
|
14591
|
-
|
|
14592
|
-
|
|
14593
|
-
|
|
14594
|
-
|
|
14595
|
-
|
|
14596
|
-
|
|
14597
|
-
|
|
14598
|
-
|
|
14599
|
-
|
|
14600
|
-
|
|
14601
|
-
|
|
14602
|
-
|
|
14603
|
-
|
|
14604
|
-
|
|
14605
|
-
|
|
14606
|
-
|
|
14607
|
-
|
|
14608
|
-
return
|
|
14609
|
-
|
|
14610
|
-
return
|
|
14611
|
-
|
|
14612
|
-
return
|
|
14613
|
-
|
|
14614
|
-
return
|
|
14615
|
-
|
|
14616
|
-
|
|
14617
|
-
|
|
14618
|
-
|
|
14619
|
-
|
|
14620
|
-
|
|
14621
|
-
|
|
14622
|
-
|
|
14623
|
-
|
|
14624
|
-
|
|
14625
|
-
|
|
14626
|
-
|
|
14627
|
-
|
|
14628
|
-
|
|
14629
|
-
|
|
14630
|
-
return
|
|
14631
|
-
|
|
14632
|
-
return
|
|
14633
|
-
|
|
14634
|
-
return
|
|
14635
|
-
|
|
14636
|
-
|
|
14637
|
-
|
|
14638
|
-
return
|
|
14639
|
-
|
|
14640
|
-
|
|
14641
|
-
|
|
14642
|
-
|
|
14643
|
-
|
|
14644
|
-
|
|
14645
|
-
|
|
14646
|
-
|
|
14647
|
-
|
|
14648
|
-
|
|
14649
|
-
|
|
14650
|
-
|
|
14651
|
-
|
|
14652
|
-
|
|
14653
|
-
|
|
14654
|
-
|
|
14655
|
-
|
|
14656
|
-
|
|
14657
|
-
|
|
14658
|
-
|
|
14659
|
-
|
|
14660
|
-
|
|
14661
|
-
|
|
14662
|
-
|
|
14663
|
-
|
|
14664
|
-
|
|
14665
|
-
|
|
14666
|
-
|
|
14667
|
-
|
|
14668
|
-
|
|
14669
|
-
|
|
14670
|
-
|
|
14671
|
-
|
|
14672
|
-
|
|
14673
|
-
|
|
14674
|
-
|
|
14675
|
-
|
|
14676
|
-
|
|
14677
|
-
|
|
14678
|
-
|
|
14679
|
-
|
|
14680
|
-
|
|
14681
|
-
|
|
14682
|
-
|
|
14683
|
-
|
|
14684
|
-
|
|
14685
|
-
|
|
14686
|
-
|
|
14687
|
-
|
|
14688
|
-
|
|
14689
|
-
|
|
14690
|
-
|
|
14691
|
-
|
|
14692
|
-
|
|
14693
|
-
|
|
14694
|
-
|
|
14695
|
-
|
|
14696
|
-
|
|
14697
|
-
|
|
14698
|
-
|
|
14699
|
-
return
|
|
14700
|
-
}
|
|
14701
|
-
|
|
14702
|
-
|
|
14703
|
-
|
|
14704
|
-
|
|
14705
|
-
|
|
14706
|
-
|
|
14707
|
-
|
|
14708
|
-
|
|
14709
|
-
}
|
|
14710
|
-
|
|
14711
|
-
|
|
14712
|
-
|
|
14713
|
-
|
|
14714
|
-
|
|
14715
|
-
|
|
14716
|
-
|
|
14717
|
-
|
|
14718
|
-
|
|
14719
|
-
|
|
14720
|
-
|
|
14721
|
-
|
|
14722
|
-
|
|
14723
|
-
|
|
14724
|
-
var
|
|
14725
|
-
|
|
14726
|
-
}
|
|
14727
|
-
|
|
14728
|
-
|
|
14729
|
-
|
|
14730
|
-
|
|
14731
|
-
|
|
14732
|
-
|
|
14733
|
-
|
|
14734
|
-
|
|
14735
|
-
|
|
14736
|
-
|
|
14737
|
-
|
|
14738
|
-
|
|
14739
|
-
|
|
14740
|
-
|
|
14741
|
-
|
|
14742
|
-
|
|
14743
|
-
|
|
14744
|
-
|
|
14745
|
-
|
|
14746
|
-
|
|
14747
|
-
|
|
14748
|
-
|
|
14749
|
-
|
|
14750
|
-
|
|
14751
|
-
|
|
14752
|
-
|
|
14753
|
-
|
|
14754
|
-
|
|
14755
|
-
|
|
14756
|
-
|
|
14757
|
-
|
|
14758
|
-
|
|
14759
|
-
|
|
14760
|
-
|
|
14761
|
-
|
|
14762
|
-
|
|
14763
|
-
|
|
14764
|
-
|
|
14765
|
-
|
|
14766
|
-
|
|
14767
|
-
|
|
14768
|
-
|
|
14769
|
-
|
|
14770
|
-
|
|
14771
|
-
|
|
14772
|
-
|
|
14773
|
-
|
|
14774
|
-
|
|
14775
|
-
|
|
14776
|
-
|
|
14777
|
-
}
|
|
14778
|
-
|
|
14779
|
-
|
|
14780
|
-
|
|
14781
|
-
|
|
14782
|
-
|
|
14783
|
-
|
|
14784
|
-
|
|
14785
|
-
|
|
14786
|
-
|
|
14787
|
-
|
|
14788
|
-
|
|
14789
|
-
|
|
14790
|
-
|
|
14791
|
-
|
|
14792
|
-
|
|
14793
|
-
|
|
14794
|
-
|
|
14795
|
-
|
|
14796
|
-
|
|
14797
|
-
}
|
|
14798
|
-
|
|
14799
|
-
|
|
14800
|
-
|
|
14801
|
-
|
|
14802
|
-
|
|
14803
|
-
|
|
14804
|
-
|
|
14805
|
-
|
|
14806
|
-
|
|
14807
|
-
|
|
14808
|
-
|
|
14809
|
-
|
|
14810
|
-
|
|
14811
|
-
|
|
14812
|
-
|
|
14813
|
-
|
|
14814
|
-
|
|
14815
|
-
|
|
14816
|
-
|
|
14817
|
-
|
|
14818
|
-
|
|
14819
|
-
|
|
14820
|
-
|
|
14821
|
-
|
|
14822
|
-
|
|
14823
|
-
|
|
14824
|
-
|
|
14825
|
-
|
|
14826
|
-
|
|
14827
|
-
}
|
|
14828
|
-
|
|
14829
|
-
|
|
14830
|
-
|
|
14831
|
-
|
|
14832
|
-
|
|
14833
|
-
|
|
14834
|
-
|
|
14835
|
-
|
|
14836
|
-
|
|
14837
|
-
|
|
14838
|
-
|
|
14839
|
-
|
|
14840
|
-
|
|
14841
|
-
|
|
14842
|
-
|
|
14843
|
-
|
|
14844
|
-
|
|
14845
|
-
|
|
14846
|
-
|
|
14847
|
-
|
|
14848
|
-
|
|
14849
|
-
|
|
14850
|
-
|
|
14851
|
-
|
|
14852
|
-
|
|
14853
|
-
|
|
14854
|
-
|
|
14855
|
-
|
|
14856
|
-
|
|
14857
|
-
}
|
|
14858
|
-
|
|
14859
|
-
|
|
14860
|
-
|
|
14861
|
-
|
|
14862
|
-
|
|
14863
|
-
|
|
14864
|
-
|
|
14865
|
-
|
|
14866
|
-
|
|
14867
|
-
|
|
14868
|
-
|
|
14869
|
-
|
|
14870
|
-
|
|
14871
|
-
|
|
14872
|
-
|
|
14873
|
-
|
|
14874
|
-
|
|
14875
|
-
|
|
14876
|
-
|
|
14877
|
-
|
|
14878
|
-
|
|
14879
|
-
|
|
14880
|
-
|
|
14881
|
-
|
|
14882
|
-
|
|
14883
|
-
|
|
14884
|
-
|
|
14885
|
-
|
|
14886
|
-
|
|
14887
|
-
}
|
|
14888
|
-
|
|
14889
|
-
|
|
14890
|
-
|
|
14891
|
-
|
|
14892
|
-
|
|
14893
|
-
|
|
14894
|
-
|
|
14895
|
-
|
|
14896
|
-
|
|
14897
|
-
|
|
14898
|
-
|
|
14899
|
-
|
|
14900
|
-
|
|
14901
|
-
|
|
14902
|
-
|
|
14903
|
-
|
|
14904
|
-
|
|
14905
|
-
|
|
14906
|
-
|
|
14907
|
-
|
|
14908
|
-
|
|
14909
|
-
|
|
14910
|
-
|
|
14911
|
-
|
|
14912
|
-
|
|
14913
|
-
|
|
14914
|
-
|
|
14915
|
-
|
|
14916
|
-
|
|
14917
|
-
|
|
14918
|
-
|
|
14919
|
-
|
|
14920
|
-
|
|
14921
|
-
|
|
14922
|
-
|
|
14923
|
-
|
|
14924
|
-
|
|
14925
|
-
|
|
14926
|
-
|
|
14927
|
-
}
|
|
14928
|
-
|
|
14929
|
-
|
|
14930
|
-
|
|
14931
|
-
|
|
14932
|
-
|
|
14933
|
-
|
|
14934
|
-
|
|
14935
|
-
|
|
14936
|
-
|
|
14937
|
-
|
|
14938
|
-
|
|
14939
|
-
|
|
14940
|
-
|
|
14941
|
-
|
|
14942
|
-
|
|
14943
|
-
|
|
14944
|
-
|
|
14945
|
-
|
|
14946
|
-
|
|
14947
|
-
|
|
14948
|
-
|
|
14949
|
-
|
|
14950
|
-
|
|
14951
|
-
|
|
14952
|
-
|
|
14953
|
-
|
|
14954
|
-
|
|
14955
|
-
|
|
14956
|
-
|
|
14957
|
-
|
|
14958
|
-
|
|
14959
|
-
|
|
14960
|
-
|
|
14961
|
-
|
|
14962
|
-
|
|
14963
|
-
|
|
14964
|
-
|
|
14965
|
-
|
|
14966
|
-
|
|
14967
|
-
|
|
14968
|
-
|
|
14969
|
-
|
|
14970
|
-
|
|
14971
|
-
|
|
14972
|
-
|
|
14973
|
-
|
|
14974
|
-
|
|
14975
|
-
|
|
14976
|
-
|
|
14977
|
-
|
|
14978
|
-
|
|
14979
|
-
|
|
14980
|
-
|
|
14981
|
-
}
|
|
14982
|
-
|
|
14983
|
-
|
|
14984
|
-
|
|
14985
|
-
|
|
14986
|
-
|
|
14987
|
-
|
|
14988
|
-
|
|
14989
|
-
|
|
14990
|
-
|
|
14991
|
-
|
|
14992
|
-
|
|
14993
|
-
|
|
14994
|
-
|
|
14995
|
-
|
|
14996
|
-
|
|
14997
|
-
|
|
14998
|
-
|
|
14999
|
-
|
|
15000
|
-
|
|
15001
|
-
|
|
15002
|
-
|
|
15003
|
-
|
|
15004
|
-
|
|
15005
|
-
|
|
15006
|
-
|
|
15007
|
-
|
|
15008
|
-
|
|
15009
|
-
|
|
15010
|
-
|
|
15011
|
-
|
|
15012
|
-
|
|
15013
|
-
|
|
15014
|
-
|
|
15015
|
-
}
|
|
15016
|
-
|
|
15017
|
-
|
|
15018
|
-
|
|
15019
|
-
|
|
15020
|
-
|
|
15021
|
-
|
|
15022
|
-
|
|
15023
|
-
|
|
15024
|
-
|
|
15025
|
-
}
|
|
15026
|
-
|
|
15027
|
-
|
|
15028
|
-
|
|
15029
|
-
|
|
15030
|
-
|
|
15031
|
-
|
|
15032
|
-
|
|
15033
|
-
|
|
15034
|
-
|
|
15035
|
-
}
|
|
15036
|
-
|
|
15037
|
-
|
|
15038
|
-
|
|
15039
|
-
|
|
15040
|
-
|
|
15041
|
-
|
|
15042
|
-
|
|
15043
|
-
|
|
15044
|
-
|
|
15045
|
-
}
|
|
15046
|
-
|
|
15047
|
-
|
|
15048
|
-
|
|
15049
|
-
|
|
15050
|
-
|
|
15051
|
-
|
|
15052
|
-
|
|
15053
|
-
|
|
15054
|
-
|
|
15055
|
-
}
|
|
15056
|
-
|
|
15057
|
-
|
|
15058
|
-
|
|
15059
|
-
|
|
15060
|
-
|
|
15061
|
-
|
|
15062
|
-
|
|
15063
|
-
|
|
15064
|
-
|
|
15065
|
-
|
|
15066
|
-
|
|
15067
|
-
|
|
15068
|
-
|
|
15069
|
-
|
|
15070
|
-
|
|
15071
|
-
|
|
15072
|
-
|
|
15073
|
-
|
|
15074
|
-
|
|
15075
|
-
|
|
15076
|
-
|
|
15077
|
-
|
|
15078
|
-
|
|
15079
|
-
|
|
15080
|
-
|
|
15081
|
-
|
|
15082
|
-
|
|
15083
|
-
|
|
15084
|
-
|
|
15085
|
-
}
|
|
15086
|
-
|
|
15087
|
-
|
|
15088
|
-
|
|
15089
|
-
|
|
15090
|
-
|
|
15091
|
-
|
|
15092
|
-
|
|
15093
|
-
|
|
15094
|
-
|
|
15095
|
-
}
|
|
15096
|
-
|
|
15097
|
-
|
|
15098
|
-
|
|
15099
|
-
|
|
15100
|
-
|
|
15101
|
-
|
|
15102
|
-
|
|
15103
|
-
|
|
15104
|
-
|
|
15105
|
-
|
|
15106
|
-
|
|
15107
|
-
|
|
15108
|
-
|
|
15109
|
-
|
|
15110
|
-
|
|
15111
|
-
|
|
15112
|
-
|
|
15113
|
-
|
|
15114
|
-
|
|
15115
|
-
|
|
15116
|
-
|
|
15117
|
-
|
|
15118
|
-
|
|
15119
|
-
|
|
15120
|
-
|
|
15121
|
-
|
|
15122
|
-
|
|
15123
|
-
|
|
15124
|
-
|
|
15125
|
-
|
|
15126
|
-
|
|
15127
|
-
|
|
15128
|
-
|
|
15129
|
-
|
|
15130
|
-
|
|
15131
|
-
|
|
15132
|
-
|
|
15133
|
-
|
|
15134
|
-
|
|
15135
|
-
|
|
15136
|
-
|
|
15137
|
-
|
|
15138
|
-
|
|
15139
|
-
|
|
15140
|
-
|
|
15141
|
-
|
|
15142
|
-
|
|
15143
|
-
|
|
15144
|
-
|
|
15145
|
-
|
|
15146
|
-
|
|
15147
|
-
|
|
15148
|
-
|
|
15149
|
-
|
|
15150
|
-
|
|
15151
|
-
|
|
15152
|
-
|
|
15153
|
-
|
|
15154
|
-
|
|
15155
|
-
}
|
|
15156
|
-
|
|
15157
|
-
|
|
15158
|
-
|
|
15159
|
-
|
|
15160
|
-
|
|
15161
|
-
|
|
15162
|
-
|
|
15163
|
-
|
|
15164
|
-
|
|
15165
|
-
|
|
15166
|
-
|
|
14378
|
+
// node_modules/bowser/bowser.mjs
|
|
14379
|
+
var bowser_exports = {};
|
|
14380
|
+
__export(bowser_exports, {
|
|
14381
|
+
BROWSER_MAP: () => BROWSER_MAP,
|
|
14382
|
+
ENGINE_MAP: () => ENGINE_MAP,
|
|
14383
|
+
OS_MAP: () => OS_MAP,
|
|
14384
|
+
PLATFORMS_MAP: () => PLATFORMS_MAP,
|
|
14385
|
+
default: () => Bowser,
|
|
14386
|
+
getParser: () => getParser,
|
|
14387
|
+
parse: () => parse3
|
|
14388
|
+
});
|
|
14389
|
+
function _defineProperties(e5, r5) {
|
|
14390
|
+
for (var t = 0; t < r5.length; t++) {
|
|
14391
|
+
var o3 = r5[t];
|
|
14392
|
+
o3.enumerable = o3.enumerable || false, o3.configurable = true, "value" in o3 && (o3.writable = true), Object.defineProperty(e5, _toPropertyKey(o3.key), o3);
|
|
14393
|
+
}
|
|
14394
|
+
}
|
|
14395
|
+
function _createClass(e5, r5, t) {
|
|
14396
|
+
return r5 && _defineProperties(e5.prototype, r5), t && _defineProperties(e5, t), Object.defineProperty(e5, "prototype", {
|
|
14397
|
+
writable: false
|
|
14398
|
+
}), e5;
|
|
14399
|
+
}
|
|
14400
|
+
function _toPropertyKey(t) {
|
|
14401
|
+
var i5 = _toPrimitive(t, "string");
|
|
14402
|
+
return "symbol" == typeof i5 ? i5 : i5 + "";
|
|
14403
|
+
}
|
|
14404
|
+
function _toPrimitive(t, r5) {
|
|
14405
|
+
if ("object" != typeof t || !t) return t;
|
|
14406
|
+
var e5 = t[Symbol.toPrimitive];
|
|
14407
|
+
if (void 0 !== e5) {
|
|
14408
|
+
var i5 = e5.call(t, r5 || "default");
|
|
14409
|
+
if ("object" != typeof i5) return i5;
|
|
14410
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
14411
|
+
}
|
|
14412
|
+
return ("string" === r5 ? String : Number)(t);
|
|
14413
|
+
}
|
|
14414
|
+
var BROWSER_ALIASES_MAP, BROWSER_MAP, PLATFORMS_MAP, OS_MAP, ENGINE_MAP, Utils, commonVersionIdentifier, browsersList, parser_os_default, parser_platforms_default, parser_engines_default, Parser, Bowser, parse3, getParser;
|
|
14415
|
+
var init_bowser = __esm({
|
|
14416
|
+
"node_modules/bowser/bowser.mjs"() {
|
|
14417
|
+
BROWSER_ALIASES_MAP = {
|
|
14418
|
+
AmazonBot: "amazonbot",
|
|
14419
|
+
"Amazon Silk": "amazon_silk",
|
|
14420
|
+
"Android Browser": "android",
|
|
14421
|
+
BaiduSpider: "baiduspider",
|
|
14422
|
+
Bada: "bada",
|
|
14423
|
+
BingCrawler: "bingcrawler",
|
|
14424
|
+
Brave: "brave",
|
|
14425
|
+
BlackBerry: "blackberry",
|
|
14426
|
+
"ChatGPT-User": "chatgpt_user",
|
|
14427
|
+
Chrome: "chrome",
|
|
14428
|
+
ClaudeBot: "claudebot",
|
|
14429
|
+
Chromium: "chromium",
|
|
14430
|
+
Diffbot: "diffbot",
|
|
14431
|
+
DuckDuckBot: "duckduckbot",
|
|
14432
|
+
DuckDuckGo: "duckduckgo",
|
|
14433
|
+
Electron: "electron",
|
|
14434
|
+
Epiphany: "epiphany",
|
|
14435
|
+
FacebookExternalHit: "facebookexternalhit",
|
|
14436
|
+
Firefox: "firefox",
|
|
14437
|
+
Focus: "focus",
|
|
14438
|
+
Generic: "generic",
|
|
14439
|
+
"Google Search": "google_search",
|
|
14440
|
+
Googlebot: "googlebot",
|
|
14441
|
+
GPTBot: "gptbot",
|
|
14442
|
+
"HeyTap Browser": "heytap",
|
|
14443
|
+
"Internet Explorer": "ie",
|
|
14444
|
+
InternetArchiveCrawler: "internetarchivecrawler",
|
|
14445
|
+
"K-Meleon": "k_meleon",
|
|
14446
|
+
Ladybird: "ladybird",
|
|
14447
|
+
LibreWolf: "librewolf",
|
|
14448
|
+
Linespider: "linespider",
|
|
14449
|
+
Maxthon: "maxthon",
|
|
14450
|
+
"Meta-ExternalAds": "meta_externalads",
|
|
14451
|
+
"Meta-ExternalAgent": "meta_externalagent",
|
|
14452
|
+
"Meta-ExternalFetcher": "meta_externalfetcher",
|
|
14453
|
+
"Meta-WebIndexer": "meta_webindexer",
|
|
14454
|
+
"Microsoft Edge": "edge",
|
|
14455
|
+
"MZ Browser": "mz",
|
|
14456
|
+
"NAVER Whale Browser": "naver",
|
|
14457
|
+
"OAI-SearchBot": "oai_searchbot",
|
|
14458
|
+
Omgilibot: "omgilibot",
|
|
14459
|
+
Opera: "opera",
|
|
14460
|
+
"Opera Coast": "opera_coast",
|
|
14461
|
+
"Pale Moon": "pale_moon",
|
|
14462
|
+
PerplexityBot: "perplexitybot",
|
|
14463
|
+
"Perplexity-User": "perplexity_user",
|
|
14464
|
+
PhantomJS: "phantomjs",
|
|
14465
|
+
PingdomBot: "pingdombot",
|
|
14466
|
+
Puffin: "puffin",
|
|
14467
|
+
QQ: "qq",
|
|
14468
|
+
QQLite: "qqlite",
|
|
14469
|
+
QupZilla: "qupzilla",
|
|
14470
|
+
Roku: "roku",
|
|
14471
|
+
Safari: "safari",
|
|
14472
|
+
Sailfish: "sailfish",
|
|
14473
|
+
"Samsung Internet for Android": "samsung_internet",
|
|
14474
|
+
SlackBot: "slackbot",
|
|
14475
|
+
SeaMonkey: "seamonkey",
|
|
14476
|
+
Sleipnir: "sleipnir",
|
|
14477
|
+
"Sogou Browser": "sogou",
|
|
14478
|
+
Swing: "swing",
|
|
14479
|
+
Tizen: "tizen",
|
|
14480
|
+
"UC Browser": "uc",
|
|
14481
|
+
"Vivo Browser": "vivo",
|
|
14482
|
+
Vivaldi: "vivaldi",
|
|
14483
|
+
"WebOS Browser": "webos",
|
|
14484
|
+
WeChat: "wechat",
|
|
14485
|
+
YahooSlurp: "yahooslurp",
|
|
14486
|
+
"Yandex Browser": "yandex",
|
|
14487
|
+
YandexBot: "yandexbot",
|
|
14488
|
+
YouBot: "youbot"
|
|
14489
|
+
};
|
|
14490
|
+
BROWSER_MAP = {
|
|
14491
|
+
amazonbot: "AmazonBot",
|
|
14492
|
+
amazon_silk: "Amazon Silk",
|
|
14493
|
+
android: "Android Browser",
|
|
14494
|
+
baiduspider: "BaiduSpider",
|
|
14495
|
+
bada: "Bada",
|
|
14496
|
+
bingcrawler: "BingCrawler",
|
|
14497
|
+
blackberry: "BlackBerry",
|
|
14498
|
+
brave: "Brave",
|
|
14499
|
+
chatgpt_user: "ChatGPT-User",
|
|
14500
|
+
chrome: "Chrome",
|
|
14501
|
+
claudebot: "ClaudeBot",
|
|
14502
|
+
chromium: "Chromium",
|
|
14503
|
+
diffbot: "Diffbot",
|
|
14504
|
+
duckduckbot: "DuckDuckBot",
|
|
14505
|
+
duckduckgo: "DuckDuckGo",
|
|
14506
|
+
edge: "Microsoft Edge",
|
|
14507
|
+
electron: "Electron",
|
|
14508
|
+
epiphany: "Epiphany",
|
|
14509
|
+
facebookexternalhit: "FacebookExternalHit",
|
|
14510
|
+
firefox: "Firefox",
|
|
14511
|
+
focus: "Focus",
|
|
14512
|
+
generic: "Generic",
|
|
14513
|
+
google_search: "Google Search",
|
|
14514
|
+
googlebot: "Googlebot",
|
|
14515
|
+
gptbot: "GPTBot",
|
|
14516
|
+
heytap: "HeyTap Browser",
|
|
14517
|
+
ie: "Internet Explorer",
|
|
14518
|
+
internetarchivecrawler: "InternetArchiveCrawler",
|
|
14519
|
+
k_meleon: "K-Meleon",
|
|
14520
|
+
ladybird: "Ladybird",
|
|
14521
|
+
librewolf: "LibreWolf",
|
|
14522
|
+
linespider: "Linespider",
|
|
14523
|
+
maxthon: "Maxthon",
|
|
14524
|
+
meta_externalads: "Meta-ExternalAds",
|
|
14525
|
+
meta_externalagent: "Meta-ExternalAgent",
|
|
14526
|
+
meta_externalfetcher: "Meta-ExternalFetcher",
|
|
14527
|
+
meta_webindexer: "Meta-WebIndexer",
|
|
14528
|
+
mz: "MZ Browser",
|
|
14529
|
+
naver: "NAVER Whale Browser",
|
|
14530
|
+
oai_searchbot: "OAI-SearchBot",
|
|
14531
|
+
omgilibot: "Omgilibot",
|
|
14532
|
+
opera: "Opera",
|
|
14533
|
+
opera_coast: "Opera Coast",
|
|
14534
|
+
pale_moon: "Pale Moon",
|
|
14535
|
+
perplexitybot: "PerplexityBot",
|
|
14536
|
+
perplexity_user: "Perplexity-User",
|
|
14537
|
+
phantomjs: "PhantomJS",
|
|
14538
|
+
pingdombot: "PingdomBot",
|
|
14539
|
+
puffin: "Puffin",
|
|
14540
|
+
qq: "QQ Browser",
|
|
14541
|
+
qqlite: "QQ Browser Lite",
|
|
14542
|
+
qupzilla: "QupZilla",
|
|
14543
|
+
roku: "Roku",
|
|
14544
|
+
safari: "Safari",
|
|
14545
|
+
sailfish: "Sailfish",
|
|
14546
|
+
samsung_internet: "Samsung Internet for Android",
|
|
14547
|
+
seamonkey: "SeaMonkey",
|
|
14548
|
+
slackbot: "SlackBot",
|
|
14549
|
+
sleipnir: "Sleipnir",
|
|
14550
|
+
sogou: "Sogou Browser",
|
|
14551
|
+
swing: "Swing",
|
|
14552
|
+
tizen: "Tizen",
|
|
14553
|
+
uc: "UC Browser",
|
|
14554
|
+
vivo: "Vivo Browser",
|
|
14555
|
+
vivaldi: "Vivaldi",
|
|
14556
|
+
webos: "WebOS Browser",
|
|
14557
|
+
wechat: "WeChat",
|
|
14558
|
+
yahooslurp: "YahooSlurp",
|
|
14559
|
+
yandex: "Yandex Browser",
|
|
14560
|
+
yandexbot: "YandexBot",
|
|
14561
|
+
youbot: "YouBot"
|
|
14562
|
+
};
|
|
14563
|
+
PLATFORMS_MAP = {
|
|
14564
|
+
bot: "bot",
|
|
14565
|
+
desktop: "desktop",
|
|
14566
|
+
mobile: "mobile",
|
|
14567
|
+
tablet: "tablet",
|
|
14568
|
+
tv: "tv"
|
|
14569
|
+
};
|
|
14570
|
+
OS_MAP = {
|
|
14571
|
+
Android: "Android",
|
|
14572
|
+
Bada: "Bada",
|
|
14573
|
+
BlackBerry: "BlackBerry",
|
|
14574
|
+
ChromeOS: "Chrome OS",
|
|
14575
|
+
HarmonyOS: "HarmonyOS",
|
|
14576
|
+
iOS: "iOS",
|
|
14577
|
+
Linux: "Linux",
|
|
14578
|
+
MacOS: "macOS",
|
|
14579
|
+
PlayStation4: "PlayStation 4",
|
|
14580
|
+
Roku: "Roku",
|
|
14581
|
+
Tizen: "Tizen",
|
|
14582
|
+
WebOS: "WebOS",
|
|
14583
|
+
Windows: "Windows",
|
|
14584
|
+
WindowsPhone: "Windows Phone"
|
|
14585
|
+
};
|
|
14586
|
+
ENGINE_MAP = {
|
|
14587
|
+
Blink: "Blink",
|
|
14588
|
+
EdgeHTML: "EdgeHTML",
|
|
14589
|
+
Gecko: "Gecko",
|
|
14590
|
+
LibWeb: "LibWeb",
|
|
14591
|
+
Presto: "Presto",
|
|
14592
|
+
Trident: "Trident",
|
|
14593
|
+
WebKit: "WebKit"
|
|
14594
|
+
};
|
|
14595
|
+
Utils = /* @__PURE__ */ (function() {
|
|
14596
|
+
function Utils2() {
|
|
14597
|
+
}
|
|
14598
|
+
Utils2.getFirstMatch = function getFirstMatch(regexp, ua) {
|
|
14599
|
+
var match2 = ua.match(regexp);
|
|
14600
|
+
return match2 && match2.length > 0 && match2[1] || "";
|
|
14601
|
+
};
|
|
14602
|
+
Utils2.getSecondMatch = function getSecondMatch(regexp, ua) {
|
|
14603
|
+
var match2 = ua.match(regexp);
|
|
14604
|
+
return match2 && match2.length > 1 && match2[2] || "";
|
|
14605
|
+
};
|
|
14606
|
+
Utils2.matchAndReturnConst = function matchAndReturnConst(regexp, ua, _const) {
|
|
14607
|
+
if (regexp.test(ua)) return _const;
|
|
14608
|
+
};
|
|
14609
|
+
Utils2.isFirefoxOnIpad = function isFirefoxOnIpad(ua) {
|
|
14610
|
+
var macIndex = ua.indexOf("Macintosh");
|
|
14611
|
+
if (macIndex === -1) return false;
|
|
14612
|
+
var fxiosIndex = ua.indexOf(" FxiOS", macIndex + 9);
|
|
14613
|
+
return fxiosIndex !== -1 && ua.indexOf("/", fxiosIndex + 6) !== -1;
|
|
14614
|
+
};
|
|
14615
|
+
Utils2.getWindowsVersionName = function getWindowsVersionName(version2) {
|
|
14616
|
+
switch (version2) {
|
|
14617
|
+
case "NT":
|
|
14618
|
+
return "NT";
|
|
14619
|
+
case "XP":
|
|
14620
|
+
return "XP";
|
|
14621
|
+
case "NT 5.0":
|
|
14622
|
+
return "2000";
|
|
14623
|
+
case "NT 5.1":
|
|
14624
|
+
return "XP";
|
|
14625
|
+
case "NT 5.2":
|
|
14626
|
+
return "2003";
|
|
14627
|
+
case "NT 6.0":
|
|
14628
|
+
return "Vista";
|
|
14629
|
+
case "NT 6.1":
|
|
14630
|
+
return "7";
|
|
14631
|
+
case "NT 6.2":
|
|
14632
|
+
return "8";
|
|
14633
|
+
case "NT 6.3":
|
|
14634
|
+
return "8.1";
|
|
14635
|
+
case "NT 10.0":
|
|
14636
|
+
return "10";
|
|
14637
|
+
default:
|
|
14638
|
+
return;
|
|
14639
|
+
}
|
|
14640
|
+
};
|
|
14641
|
+
Utils2.getMacOSVersionName = function getMacOSVersionName(version2) {
|
|
14642
|
+
var v = version2.split(".").splice(0, 2).map(function(s2) {
|
|
14643
|
+
return parseInt(s2, 10) || 0;
|
|
14644
|
+
});
|
|
14645
|
+
v.push(0);
|
|
14646
|
+
var major = v[0];
|
|
14647
|
+
var minor = v[1];
|
|
14648
|
+
if (major === 10) switch (minor) {
|
|
14649
|
+
case 5:
|
|
14650
|
+
return "Leopard";
|
|
14651
|
+
case 6:
|
|
14652
|
+
return "Snow Leopard";
|
|
14653
|
+
case 7:
|
|
14654
|
+
return "Lion";
|
|
14655
|
+
case 8:
|
|
14656
|
+
return "Mountain Lion";
|
|
14657
|
+
case 9:
|
|
14658
|
+
return "Mavericks";
|
|
14659
|
+
case 10:
|
|
14660
|
+
return "Yosemite";
|
|
14661
|
+
case 11:
|
|
14662
|
+
return "El Capitan";
|
|
14663
|
+
case 12:
|
|
14664
|
+
return "Sierra";
|
|
14665
|
+
case 13:
|
|
14666
|
+
return "High Sierra";
|
|
14667
|
+
case 14:
|
|
14668
|
+
return "Mojave";
|
|
14669
|
+
case 15:
|
|
14670
|
+
return "Catalina";
|
|
14671
|
+
default:
|
|
14672
|
+
return;
|
|
14673
|
+
}
|
|
14674
|
+
switch (major) {
|
|
14675
|
+
case 11:
|
|
14676
|
+
return "Big Sur";
|
|
14677
|
+
case 12:
|
|
14678
|
+
return "Monterey";
|
|
14679
|
+
case 13:
|
|
14680
|
+
return "Ventura";
|
|
14681
|
+
case 14:
|
|
14682
|
+
return "Sonoma";
|
|
14683
|
+
case 15:
|
|
14684
|
+
return "Sequoia";
|
|
14685
|
+
default:
|
|
14686
|
+
return;
|
|
14687
|
+
}
|
|
14688
|
+
};
|
|
14689
|
+
Utils2.getAndroidVersionName = function getAndroidVersionName(version2) {
|
|
14690
|
+
var v = version2.split(".").splice(0, 2).map(function(s2) {
|
|
14691
|
+
return parseInt(s2, 10) || 0;
|
|
14692
|
+
});
|
|
14693
|
+
v.push(0);
|
|
14694
|
+
if (v[0] === 1 && v[1] < 5) return void 0;
|
|
14695
|
+
if (v[0] === 1 && v[1] < 6) return "Cupcake";
|
|
14696
|
+
if (v[0] === 1 && v[1] >= 6) return "Donut";
|
|
14697
|
+
if (v[0] === 2 && v[1] < 2) return "Eclair";
|
|
14698
|
+
if (v[0] === 2 && v[1] === 2) return "Froyo";
|
|
14699
|
+
if (v[0] === 2 && v[1] > 2) return "Gingerbread";
|
|
14700
|
+
if (v[0] === 3) return "Honeycomb";
|
|
14701
|
+
if (v[0] === 4 && v[1] < 1) return "Ice Cream Sandwich";
|
|
14702
|
+
if (v[0] === 4 && v[1] < 4) return "Jelly Bean";
|
|
14703
|
+
if (v[0] === 4 && v[1] >= 4) return "KitKat";
|
|
14704
|
+
if (v[0] === 5) return "Lollipop";
|
|
14705
|
+
if (v[0] === 6) return "Marshmallow";
|
|
14706
|
+
if (v[0] === 7) return "Nougat";
|
|
14707
|
+
if (v[0] === 8) return "Oreo";
|
|
14708
|
+
if (v[0] === 9) return "Pie";
|
|
14709
|
+
};
|
|
14710
|
+
Utils2.getVersionPrecision = function getVersionPrecision(version2) {
|
|
14711
|
+
return version2.split(".").length;
|
|
14712
|
+
};
|
|
14713
|
+
Utils2.compareVersions = function compareVersions(versionA, versionB, isLoose) {
|
|
14714
|
+
if (isLoose === void 0) isLoose = false;
|
|
14715
|
+
var versionAPrecision = Utils2.getVersionPrecision(versionA);
|
|
14716
|
+
var versionBPrecision = Utils2.getVersionPrecision(versionB);
|
|
14717
|
+
var precision = Math.max(versionAPrecision, versionBPrecision);
|
|
14718
|
+
var lastPrecision = 0;
|
|
14719
|
+
var chunks = Utils2.map([versionA, versionB], function(version2) {
|
|
14720
|
+
var delta = precision - Utils2.getVersionPrecision(version2);
|
|
14721
|
+
var _version = version2 + new Array(delta + 1).join(".0");
|
|
14722
|
+
return Utils2.map(_version.split("."), function(chunk) {
|
|
14723
|
+
return new Array(20 - chunk.length).join("0") + chunk;
|
|
14724
|
+
}).reverse();
|
|
14725
|
+
});
|
|
14726
|
+
if (isLoose) lastPrecision = precision - Math.min(versionAPrecision, versionBPrecision);
|
|
14727
|
+
precision -= 1;
|
|
14728
|
+
while (precision >= lastPrecision) {
|
|
14729
|
+
if (chunks[0][precision] > chunks[1][precision]) return 1;
|
|
14730
|
+
if (chunks[0][precision] === chunks[1][precision]) {
|
|
14731
|
+
if (precision === lastPrecision) return 0;
|
|
14732
|
+
precision -= 1;
|
|
14733
|
+
} else if (chunks[0][precision] < chunks[1][precision]) return -1;
|
|
14734
|
+
}
|
|
14735
|
+
};
|
|
14736
|
+
Utils2.map = function map4(arr, iterator) {
|
|
14737
|
+
var result = [];
|
|
14738
|
+
var i5;
|
|
14739
|
+
if (Array.prototype.map) return Array.prototype.map.call(arr, iterator);
|
|
14740
|
+
for (i5 = 0; i5 < arr.length; i5 += 1) result.push(iterator(arr[i5]));
|
|
14741
|
+
return result;
|
|
14742
|
+
};
|
|
14743
|
+
Utils2.find = function find(arr, predicate) {
|
|
14744
|
+
var i5;
|
|
14745
|
+
var l3;
|
|
14746
|
+
if (Array.prototype.find) return Array.prototype.find.call(arr, predicate);
|
|
14747
|
+
for (i5 = 0, l3 = arr.length; i5 < l3; i5 += 1) {
|
|
14748
|
+
var value = arr[i5];
|
|
14749
|
+
if (predicate(value, i5)) return value;
|
|
14750
|
+
}
|
|
14751
|
+
};
|
|
14752
|
+
Utils2.assign = function assign(obj) {
|
|
14753
|
+
var result = obj;
|
|
14754
|
+
var i5;
|
|
14755
|
+
var l3;
|
|
14756
|
+
for (var _len = arguments.length, assigners = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) assigners[_key - 1] = arguments[_key];
|
|
14757
|
+
if (Object.assign) return Object.assign.apply(Object, [obj].concat(assigners));
|
|
14758
|
+
var _loop = function _loop2() {
|
|
14759
|
+
var assigner = assigners[i5];
|
|
14760
|
+
if (typeof assigner === "object" && assigner !== null) Object.keys(assigner).forEach(function(key) {
|
|
14761
|
+
result[key] = assigner[key];
|
|
14762
|
+
});
|
|
14763
|
+
};
|
|
14764
|
+
for (i5 = 0, l3 = assigners.length; i5 < l3; i5 += 1) _loop();
|
|
14765
|
+
return obj;
|
|
14766
|
+
};
|
|
14767
|
+
Utils2.getBrowserAlias = function getBrowserAlias(browserName) {
|
|
14768
|
+
return BROWSER_ALIASES_MAP[browserName];
|
|
14769
|
+
};
|
|
14770
|
+
Utils2.getBrowserTypeByAlias = function getBrowserTypeByAlias(browserAlias) {
|
|
14771
|
+
return BROWSER_MAP[browserAlias] || "";
|
|
14772
|
+
};
|
|
14773
|
+
return Utils2;
|
|
14774
|
+
})();
|
|
14775
|
+
commonVersionIdentifier = /version\/(\d+(\.?_?\d+)+)/i;
|
|
14776
|
+
browsersList = [{
|
|
14777
|
+
test: [/gptbot/i],
|
|
14778
|
+
describe: function describe3(ua) {
|
|
14779
|
+
var browser = {
|
|
14780
|
+
name: "GPTBot"
|
|
14781
|
+
};
|
|
14782
|
+
var version2 = Utils.getFirstMatch(/gptbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14783
|
+
if (version2) browser.version = version2;
|
|
14784
|
+
return browser;
|
|
14785
|
+
}
|
|
14786
|
+
}, {
|
|
14787
|
+
test: [/chatgpt-user/i],
|
|
14788
|
+
describe: function describe4(ua) {
|
|
14789
|
+
var browser = {
|
|
14790
|
+
name: "ChatGPT-User"
|
|
14791
|
+
};
|
|
14792
|
+
var version2 = Utils.getFirstMatch(/chatgpt-user\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14793
|
+
if (version2) browser.version = version2;
|
|
14794
|
+
return browser;
|
|
14795
|
+
}
|
|
14796
|
+
}, {
|
|
14797
|
+
test: [/oai-searchbot/i],
|
|
14798
|
+
describe: function describe5(ua) {
|
|
14799
|
+
var browser = {
|
|
14800
|
+
name: "OAI-SearchBot"
|
|
14801
|
+
};
|
|
14802
|
+
var version2 = Utils.getFirstMatch(/oai-searchbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14803
|
+
if (version2) browser.version = version2;
|
|
14804
|
+
return browser;
|
|
14805
|
+
}
|
|
14806
|
+
}, {
|
|
14807
|
+
test: [/claudebot/i, /claude-web/i, /claude-user/i, /claude-searchbot/i],
|
|
14808
|
+
describe: function describe6(ua) {
|
|
14809
|
+
var browser = {
|
|
14810
|
+
name: "ClaudeBot"
|
|
14811
|
+
};
|
|
14812
|
+
var version2 = Utils.getFirstMatch(/(?:claudebot|claude-web|claude-user|claude-searchbot)\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14813
|
+
if (version2) browser.version = version2;
|
|
14814
|
+
return browser;
|
|
14815
|
+
}
|
|
14816
|
+
}, {
|
|
14817
|
+
test: [/omgilibot/i, /webzio-extended/i],
|
|
14818
|
+
describe: function describe7(ua) {
|
|
14819
|
+
var browser = {
|
|
14820
|
+
name: "Omgilibot"
|
|
14821
|
+
};
|
|
14822
|
+
var version2 = Utils.getFirstMatch(/(?:omgilibot|webzio-extended)\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14823
|
+
if (version2) browser.version = version2;
|
|
14824
|
+
return browser;
|
|
14825
|
+
}
|
|
14826
|
+
}, {
|
|
14827
|
+
test: [/diffbot/i],
|
|
14828
|
+
describe: function describe8(ua) {
|
|
14829
|
+
var browser = {
|
|
14830
|
+
name: "Diffbot"
|
|
14831
|
+
};
|
|
14832
|
+
var version2 = Utils.getFirstMatch(/diffbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14833
|
+
if (version2) browser.version = version2;
|
|
14834
|
+
return browser;
|
|
14835
|
+
}
|
|
14836
|
+
}, {
|
|
14837
|
+
test: [/perplexitybot/i],
|
|
14838
|
+
describe: function describe9(ua) {
|
|
14839
|
+
var browser = {
|
|
14840
|
+
name: "PerplexityBot"
|
|
14841
|
+
};
|
|
14842
|
+
var version2 = Utils.getFirstMatch(/perplexitybot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14843
|
+
if (version2) browser.version = version2;
|
|
14844
|
+
return browser;
|
|
14845
|
+
}
|
|
14846
|
+
}, {
|
|
14847
|
+
test: [/perplexity-user/i],
|
|
14848
|
+
describe: function describe10(ua) {
|
|
14849
|
+
var browser = {
|
|
14850
|
+
name: "Perplexity-User"
|
|
14851
|
+
};
|
|
14852
|
+
var version2 = Utils.getFirstMatch(/perplexity-user\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14853
|
+
if (version2) browser.version = version2;
|
|
14854
|
+
return browser;
|
|
14855
|
+
}
|
|
14856
|
+
}, {
|
|
14857
|
+
test: [/youbot/i],
|
|
14858
|
+
describe: function describe11(ua) {
|
|
14859
|
+
var browser = {
|
|
14860
|
+
name: "YouBot"
|
|
14861
|
+
};
|
|
14862
|
+
var version2 = Utils.getFirstMatch(/youbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14863
|
+
if (version2) browser.version = version2;
|
|
14864
|
+
return browser;
|
|
14865
|
+
}
|
|
14866
|
+
}, {
|
|
14867
|
+
test: [/meta-webindexer/i],
|
|
14868
|
+
describe: function describe12(ua) {
|
|
14869
|
+
var browser = {
|
|
14870
|
+
name: "Meta-WebIndexer"
|
|
14871
|
+
};
|
|
14872
|
+
var version2 = Utils.getFirstMatch(/meta-webindexer\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14873
|
+
if (version2) browser.version = version2;
|
|
14874
|
+
return browser;
|
|
14875
|
+
}
|
|
14876
|
+
}, {
|
|
14877
|
+
test: [/meta-externalads/i],
|
|
14878
|
+
describe: function describe13(ua) {
|
|
14879
|
+
var browser = {
|
|
14880
|
+
name: "Meta-ExternalAds"
|
|
14881
|
+
};
|
|
14882
|
+
var version2 = Utils.getFirstMatch(/meta-externalads\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14883
|
+
if (version2) browser.version = version2;
|
|
14884
|
+
return browser;
|
|
14885
|
+
}
|
|
14886
|
+
}, {
|
|
14887
|
+
test: [/meta-externalagent/i],
|
|
14888
|
+
describe: function describe14(ua) {
|
|
14889
|
+
var browser = {
|
|
14890
|
+
name: "Meta-ExternalAgent"
|
|
14891
|
+
};
|
|
14892
|
+
var version2 = Utils.getFirstMatch(/meta-externalagent\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14893
|
+
if (version2) browser.version = version2;
|
|
14894
|
+
return browser;
|
|
14895
|
+
}
|
|
14896
|
+
}, {
|
|
14897
|
+
test: [/meta-externalfetcher/i],
|
|
14898
|
+
describe: function describe15(ua) {
|
|
14899
|
+
var browser = {
|
|
14900
|
+
name: "Meta-ExternalFetcher"
|
|
14901
|
+
};
|
|
14902
|
+
var version2 = Utils.getFirstMatch(/meta-externalfetcher\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14903
|
+
if (version2) browser.version = version2;
|
|
14904
|
+
return browser;
|
|
14905
|
+
}
|
|
14906
|
+
}, {
|
|
14907
|
+
test: [/googlebot/i],
|
|
14908
|
+
describe: function describe16(ua) {
|
|
14909
|
+
var browser = {
|
|
14910
|
+
name: "Googlebot"
|
|
14911
|
+
};
|
|
14912
|
+
var version2 = Utils.getFirstMatch(/googlebot\/(\d+(\.\d+))/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14913
|
+
if (version2) browser.version = version2;
|
|
14914
|
+
return browser;
|
|
14915
|
+
}
|
|
14916
|
+
}, {
|
|
14917
|
+
test: [/linespider/i],
|
|
14918
|
+
describe: function describe17(ua) {
|
|
14919
|
+
var browser = {
|
|
14920
|
+
name: "Linespider"
|
|
14921
|
+
};
|
|
14922
|
+
var version2 = Utils.getFirstMatch(/(?:linespider)(?:-[-\w]{1,64})?[\s/](\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14923
|
+
if (version2) browser.version = version2;
|
|
14924
|
+
return browser;
|
|
14925
|
+
}
|
|
14926
|
+
}, {
|
|
14927
|
+
test: [/amazonbot/i],
|
|
14928
|
+
describe: function describe18(ua) {
|
|
14929
|
+
var browser = {
|
|
14930
|
+
name: "AmazonBot"
|
|
14931
|
+
};
|
|
14932
|
+
var version2 = Utils.getFirstMatch(/amazonbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14933
|
+
if (version2) browser.version = version2;
|
|
14934
|
+
return browser;
|
|
14935
|
+
}
|
|
14936
|
+
}, {
|
|
14937
|
+
test: [/bingbot/i],
|
|
14938
|
+
describe: function describe19(ua) {
|
|
14939
|
+
var browser = {
|
|
14940
|
+
name: "BingCrawler"
|
|
14941
|
+
};
|
|
14942
|
+
var version2 = Utils.getFirstMatch(/bingbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14943
|
+
if (version2) browser.version = version2;
|
|
14944
|
+
return browser;
|
|
14945
|
+
}
|
|
14946
|
+
}, {
|
|
14947
|
+
test: [/baiduspider/i],
|
|
14948
|
+
describe: function describe20(ua) {
|
|
14949
|
+
var browser = {
|
|
14950
|
+
name: "BaiduSpider"
|
|
14951
|
+
};
|
|
14952
|
+
var version2 = Utils.getFirstMatch(/baiduspider\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14953
|
+
if (version2) browser.version = version2;
|
|
14954
|
+
return browser;
|
|
14955
|
+
}
|
|
14956
|
+
}, {
|
|
14957
|
+
test: [/duckduckbot/i],
|
|
14958
|
+
describe: function describe21(ua) {
|
|
14959
|
+
var browser = {
|
|
14960
|
+
name: "DuckDuckBot"
|
|
14961
|
+
};
|
|
14962
|
+
var version2 = Utils.getFirstMatch(/duckduckbot\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14963
|
+
if (version2) browser.version = version2;
|
|
14964
|
+
return browser;
|
|
14965
|
+
}
|
|
14966
|
+
}, {
|
|
14967
|
+
test: [/ia_archiver/i],
|
|
14968
|
+
describe: function describe22(ua) {
|
|
14969
|
+
var browser = {
|
|
14970
|
+
name: "InternetArchiveCrawler"
|
|
14971
|
+
};
|
|
14972
|
+
var version2 = Utils.getFirstMatch(/ia_archiver\/(\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14973
|
+
if (version2) browser.version = version2;
|
|
14974
|
+
return browser;
|
|
14975
|
+
}
|
|
14976
|
+
}, {
|
|
14977
|
+
test: [/facebookexternalhit/i, /facebookcatalog/i],
|
|
14978
|
+
describe: function describe23() {
|
|
14979
|
+
return {
|
|
14980
|
+
name: "FacebookExternalHit"
|
|
14981
|
+
};
|
|
14982
|
+
}
|
|
14983
|
+
}, {
|
|
14984
|
+
test: [/slackbot/i, /slack-imgProxy/i],
|
|
14985
|
+
describe: function describe24(ua) {
|
|
14986
|
+
var browser = {
|
|
14987
|
+
name: "SlackBot"
|
|
14988
|
+
};
|
|
14989
|
+
var version2 = Utils.getFirstMatch(/(?:slackbot|slack-imgproxy)(?:-[-\w]{1,64})?[\s/](\d+(\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
14990
|
+
if (version2) browser.version = version2;
|
|
14991
|
+
return browser;
|
|
14992
|
+
}
|
|
14993
|
+
}, {
|
|
14994
|
+
test: [/yahoo!?[\s/]*slurp/i],
|
|
14995
|
+
describe: function describe25() {
|
|
14996
|
+
return {
|
|
14997
|
+
name: "YahooSlurp"
|
|
14998
|
+
};
|
|
14999
|
+
}
|
|
15000
|
+
}, {
|
|
15001
|
+
test: [/yandexbot/i, /yandexmobilebot/i],
|
|
15002
|
+
describe: function describe26() {
|
|
15003
|
+
return {
|
|
15004
|
+
name: "YandexBot"
|
|
15005
|
+
};
|
|
15006
|
+
}
|
|
15007
|
+
}, {
|
|
15008
|
+
test: [/pingdom/i],
|
|
15009
|
+
describe: function describe27() {
|
|
15010
|
+
return {
|
|
15011
|
+
name: "PingdomBot"
|
|
15012
|
+
};
|
|
15013
|
+
}
|
|
15014
|
+
}, {
|
|
15015
|
+
test: [/opera/i],
|
|
15016
|
+
describe: function describe28(ua) {
|
|
15017
|
+
var browser = {
|
|
15018
|
+
name: "Opera"
|
|
15019
|
+
};
|
|
15020
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15021
|
+
if (version2) browser.version = version2;
|
|
15022
|
+
return browser;
|
|
15023
|
+
}
|
|
15024
|
+
}, {
|
|
15025
|
+
test: [/opr\/|opios/i],
|
|
15026
|
+
describe: function describe29(ua) {
|
|
15027
|
+
var browser = {
|
|
15028
|
+
name: "Opera"
|
|
15029
|
+
};
|
|
15030
|
+
var version2 = Utils.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15031
|
+
if (version2) browser.version = version2;
|
|
15032
|
+
return browser;
|
|
15033
|
+
}
|
|
15034
|
+
}, {
|
|
15035
|
+
test: [/SamsungBrowser/i],
|
|
15036
|
+
describe: function describe30(ua) {
|
|
15037
|
+
var browser = {
|
|
15038
|
+
name: "Samsung Internet for Android"
|
|
15039
|
+
};
|
|
15040
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15041
|
+
if (version2) browser.version = version2;
|
|
15042
|
+
return browser;
|
|
15043
|
+
}
|
|
15044
|
+
}, {
|
|
15045
|
+
test: [/Whale/i],
|
|
15046
|
+
describe: function describe31(ua) {
|
|
15047
|
+
var browser = {
|
|
15048
|
+
name: "NAVER Whale Browser"
|
|
15049
|
+
};
|
|
15050
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i, ua);
|
|
15051
|
+
if (version2) browser.version = version2;
|
|
15052
|
+
return browser;
|
|
15053
|
+
}
|
|
15054
|
+
}, {
|
|
15055
|
+
test: [/PaleMoon/i],
|
|
15056
|
+
describe: function describe32(ua) {
|
|
15057
|
+
var browser = {
|
|
15058
|
+
name: "Pale Moon"
|
|
15059
|
+
};
|
|
15060
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:PaleMoon)[\s/](\d+(?:\.\d+)+)/i, ua);
|
|
15061
|
+
if (version2) browser.version = version2;
|
|
15062
|
+
return browser;
|
|
15063
|
+
}
|
|
15064
|
+
}, {
|
|
15065
|
+
test: [/HeyTapBrowser/i],
|
|
15066
|
+
describe: function describe33(ua) {
|
|
15067
|
+
var browser = {
|
|
15068
|
+
name: "HeyTap Browser"
|
|
15069
|
+
};
|
|
15070
|
+
var version2 = Utils.getFirstMatch(/(?:HeyTapBrowser)[\s/](\d+(?:\.\d+)*)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15071
|
+
if (version2) browser.version = version2;
|
|
15072
|
+
return browser;
|
|
15073
|
+
}
|
|
15074
|
+
}, {
|
|
15075
|
+
test: [/VivoBrowser/i],
|
|
15076
|
+
describe: function describe34(ua) {
|
|
15077
|
+
var browser = {
|
|
15078
|
+
name: "Vivo Browser"
|
|
15079
|
+
};
|
|
15080
|
+
var version2 = Utils.getFirstMatch(/(?:VivoBrowser)[\s/](\d+(?:\.\d+)*)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15081
|
+
if (version2) browser.version = version2;
|
|
15082
|
+
return browser;
|
|
15083
|
+
}
|
|
15084
|
+
}, {
|
|
15085
|
+
test: [/MZBrowser/i],
|
|
15086
|
+
describe: function describe35(ua) {
|
|
15087
|
+
var browser = {
|
|
15088
|
+
name: "MZ Browser"
|
|
15089
|
+
};
|
|
15090
|
+
var version2 = Utils.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15091
|
+
if (version2) browser.version = version2;
|
|
15092
|
+
return browser;
|
|
15093
|
+
}
|
|
15094
|
+
}, {
|
|
15095
|
+
test: [/focus/i],
|
|
15096
|
+
describe: function describe36(ua) {
|
|
15097
|
+
var browser = {
|
|
15098
|
+
name: "Focus"
|
|
15099
|
+
};
|
|
15100
|
+
var version2 = Utils.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15101
|
+
if (version2) browser.version = version2;
|
|
15102
|
+
return browser;
|
|
15103
|
+
}
|
|
15104
|
+
}, {
|
|
15105
|
+
test: [/swing/i],
|
|
15106
|
+
describe: function describe37(ua) {
|
|
15107
|
+
var browser = {
|
|
15108
|
+
name: "Swing"
|
|
15109
|
+
};
|
|
15110
|
+
var version2 = Utils.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15111
|
+
if (version2) browser.version = version2;
|
|
15112
|
+
return browser;
|
|
15113
|
+
}
|
|
15114
|
+
}, {
|
|
15115
|
+
test: [/coast/i],
|
|
15116
|
+
describe: function describe38(ua) {
|
|
15117
|
+
var browser = {
|
|
15118
|
+
name: "Opera Coast"
|
|
15119
|
+
};
|
|
15120
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15121
|
+
if (version2) browser.version = version2;
|
|
15122
|
+
return browser;
|
|
15123
|
+
}
|
|
15124
|
+
}, {
|
|
15125
|
+
test: [/opt\/\d+(?:.?_?\d+)+/i],
|
|
15126
|
+
describe: function describe39(ua) {
|
|
15127
|
+
var browser = {
|
|
15128
|
+
name: "Opera Touch"
|
|
15129
|
+
};
|
|
15130
|
+
var version2 = Utils.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15131
|
+
if (version2) browser.version = version2;
|
|
15132
|
+
return browser;
|
|
15133
|
+
}
|
|
15134
|
+
}, {
|
|
15135
|
+
test: [/yabrowser/i],
|
|
15136
|
+
describe: function describe40(ua) {
|
|
15137
|
+
var browser = {
|
|
15138
|
+
name: "Yandex Browser"
|
|
15139
|
+
};
|
|
15140
|
+
var version2 = Utils.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15141
|
+
if (version2) browser.version = version2;
|
|
15142
|
+
return browser;
|
|
15143
|
+
}
|
|
15144
|
+
}, {
|
|
15145
|
+
test: [/ucbrowser/i],
|
|
15146
|
+
describe: function describe41(ua) {
|
|
15147
|
+
var browser = {
|
|
15148
|
+
name: "UC Browser"
|
|
15149
|
+
};
|
|
15150
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15151
|
+
if (version2) browser.version = version2;
|
|
15152
|
+
return browser;
|
|
15153
|
+
}
|
|
15154
|
+
}, {
|
|
15155
|
+
test: [/Maxthon|mxios/i],
|
|
15156
|
+
describe: function describe42(ua) {
|
|
15157
|
+
var browser = {
|
|
15158
|
+
name: "Maxthon"
|
|
15159
|
+
};
|
|
15160
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15161
|
+
if (version2) browser.version = version2;
|
|
15162
|
+
return browser;
|
|
15163
|
+
}
|
|
15164
|
+
}, {
|
|
15165
|
+
test: [/epiphany/i],
|
|
15166
|
+
describe: function describe43(ua) {
|
|
15167
|
+
var browser = {
|
|
15168
|
+
name: "Epiphany"
|
|
15169
|
+
};
|
|
15170
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15171
|
+
if (version2) browser.version = version2;
|
|
15172
|
+
return browser;
|
|
15173
|
+
}
|
|
15174
|
+
}, {
|
|
15175
|
+
test: [/puffin/i],
|
|
15176
|
+
describe: function describe44(ua) {
|
|
15177
|
+
var browser = {
|
|
15178
|
+
name: "Puffin"
|
|
15179
|
+
};
|
|
15180
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15181
|
+
if (version2) browser.version = version2;
|
|
15182
|
+
return browser;
|
|
15183
|
+
}
|
|
15184
|
+
}, {
|
|
15185
|
+
test: [/sleipnir/i],
|
|
15186
|
+
describe: function describe45(ua) {
|
|
15187
|
+
var browser = {
|
|
15188
|
+
name: "Sleipnir"
|
|
15189
|
+
};
|
|
15190
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15191
|
+
if (version2) browser.version = version2;
|
|
15192
|
+
return browser;
|
|
15193
|
+
}
|
|
15194
|
+
}, {
|
|
15195
|
+
test: [/k-meleon/i],
|
|
15196
|
+
describe: function describe46(ua) {
|
|
15197
|
+
var browser = {
|
|
15198
|
+
name: "K-Meleon"
|
|
15199
|
+
};
|
|
15200
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15201
|
+
if (version2) browser.version = version2;
|
|
15202
|
+
return browser;
|
|
15203
|
+
}
|
|
15204
|
+
}, {
|
|
15205
|
+
test: [/micromessenger/i],
|
|
15206
|
+
describe: function describe47(ua) {
|
|
15207
|
+
var browser = {
|
|
15208
|
+
name: "WeChat"
|
|
15209
|
+
};
|
|
15210
|
+
var version2 = Utils.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15211
|
+
if (version2) browser.version = version2;
|
|
15212
|
+
return browser;
|
|
15213
|
+
}
|
|
15214
|
+
}, {
|
|
15215
|
+
test: [/qqbrowser/i],
|
|
15216
|
+
describe: function describe48(ua) {
|
|
15217
|
+
var browser = {
|
|
15218
|
+
name: /qqbrowserlite/i.test(ua) ? "QQ Browser Lite" : "QQ Browser"
|
|
15219
|
+
};
|
|
15220
|
+
var version2 = Utils.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15221
|
+
if (version2) browser.version = version2;
|
|
15222
|
+
return browser;
|
|
15223
|
+
}
|
|
15224
|
+
}, {
|
|
15225
|
+
test: [/msie|trident/i],
|
|
15226
|
+
describe: function describe49(ua) {
|
|
15227
|
+
var browser = {
|
|
15228
|
+
name: "Internet Explorer"
|
|
15229
|
+
};
|
|
15230
|
+
var version2 = Utils.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i, ua);
|
|
15231
|
+
if (version2) browser.version = version2;
|
|
15232
|
+
return browser;
|
|
15233
|
+
}
|
|
15234
|
+
}, {
|
|
15235
|
+
test: [/\sedg\//i],
|
|
15236
|
+
describe: function describe50(ua) {
|
|
15237
|
+
var browser = {
|
|
15238
|
+
name: "Microsoft Edge"
|
|
15239
|
+
};
|
|
15240
|
+
var version2 = Utils.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15241
|
+
if (version2) browser.version = version2;
|
|
15242
|
+
return browser;
|
|
15243
|
+
}
|
|
15244
|
+
}, {
|
|
15245
|
+
test: [/edg([ea]|ios)\//i],
|
|
15246
|
+
describe: function describe51(ua) {
|
|
15247
|
+
var browser = {
|
|
15248
|
+
name: "Microsoft Edge"
|
|
15249
|
+
};
|
|
15250
|
+
var version2 = Utils.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15251
|
+
if (version2) browser.version = version2;
|
|
15252
|
+
return browser;
|
|
15253
|
+
}
|
|
15254
|
+
}, {
|
|
15255
|
+
test: function test(parser) {
|
|
15256
|
+
if (parser.hasBrand("Vivaldi")) return true;
|
|
15257
|
+
return parser.test(/vivaldi/i);
|
|
15258
|
+
},
|
|
15259
|
+
describe: function describe52(ua, parser) {
|
|
15260
|
+
var browser = {
|
|
15261
|
+
name: "Vivaldi"
|
|
15262
|
+
};
|
|
15263
|
+
if (parser) {
|
|
15264
|
+
var hintsVersion = parser.getBrandVersion("Vivaldi");
|
|
15265
|
+
if (hintsVersion) {
|
|
15266
|
+
browser.version = hintsVersion;
|
|
15267
|
+
return browser;
|
|
15268
|
+
}
|
|
15269
|
+
}
|
|
15270
|
+
var version2 = Utils.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15271
|
+
if (version2) browser.version = version2;
|
|
15272
|
+
return browser;
|
|
15273
|
+
}
|
|
15274
|
+
}, {
|
|
15275
|
+
test: [/seamonkey/i],
|
|
15276
|
+
describe: function describe53(ua) {
|
|
15277
|
+
var browser = {
|
|
15278
|
+
name: "SeaMonkey"
|
|
15279
|
+
};
|
|
15280
|
+
var version2 = Utils.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15281
|
+
if (version2) browser.version = version2;
|
|
15282
|
+
return browser;
|
|
15283
|
+
}
|
|
15284
|
+
}, {
|
|
15285
|
+
test: [/sailfish/i],
|
|
15286
|
+
describe: function describe54(ua) {
|
|
15287
|
+
var browser = {
|
|
15288
|
+
name: "Sailfish"
|
|
15289
|
+
};
|
|
15290
|
+
var version2 = Utils.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i, ua);
|
|
15291
|
+
if (version2) browser.version = version2;
|
|
15292
|
+
return browser;
|
|
15293
|
+
}
|
|
15294
|
+
}, {
|
|
15295
|
+
test: [/silk/i],
|
|
15296
|
+
describe: function describe55(ua) {
|
|
15297
|
+
var browser = {
|
|
15298
|
+
name: "Amazon Silk"
|
|
15299
|
+
};
|
|
15300
|
+
var version2 = Utils.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15301
|
+
if (version2) browser.version = version2;
|
|
15302
|
+
return browser;
|
|
15303
|
+
}
|
|
15304
|
+
}, {
|
|
15305
|
+
test: [/phantom/i],
|
|
15306
|
+
describe: function describe56(ua) {
|
|
15307
|
+
var browser = {
|
|
15308
|
+
name: "PhantomJS"
|
|
15309
|
+
};
|
|
15310
|
+
var version2 = Utils.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15311
|
+
if (version2) browser.version = version2;
|
|
15312
|
+
return browser;
|
|
15313
|
+
}
|
|
15314
|
+
}, {
|
|
15315
|
+
test: [/slimerjs/i],
|
|
15316
|
+
describe: function describe57(ua) {
|
|
15317
|
+
var browser = {
|
|
15318
|
+
name: "SlimerJS"
|
|
15319
|
+
};
|
|
15320
|
+
var version2 = Utils.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15321
|
+
if (version2) browser.version = version2;
|
|
15322
|
+
return browser;
|
|
15323
|
+
}
|
|
15324
|
+
}, {
|
|
15325
|
+
test: [/blackberry|\bbb\d+/i, /rim\stablet/i],
|
|
15326
|
+
describe: function describe58(ua) {
|
|
15327
|
+
var browser = {
|
|
15328
|
+
name: "BlackBerry"
|
|
15329
|
+
};
|
|
15330
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15331
|
+
if (version2) browser.version = version2;
|
|
15332
|
+
return browser;
|
|
15333
|
+
}
|
|
15334
|
+
}, {
|
|
15335
|
+
test: [/(web|hpw)[o0]s/i],
|
|
15336
|
+
describe: function describe59(ua) {
|
|
15337
|
+
var browser = {
|
|
15338
|
+
name: "WebOS Browser"
|
|
15339
|
+
};
|
|
15340
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua) || Utils.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15341
|
+
if (version2) browser.version = version2;
|
|
15342
|
+
return browser;
|
|
15343
|
+
}
|
|
15344
|
+
}, {
|
|
15345
|
+
test: [/bada/i],
|
|
15346
|
+
describe: function describe60(ua) {
|
|
15347
|
+
var browser = {
|
|
15348
|
+
name: "Bada"
|
|
15349
|
+
};
|
|
15350
|
+
var version2 = Utils.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15351
|
+
if (version2) browser.version = version2;
|
|
15352
|
+
return browser;
|
|
15353
|
+
}
|
|
15354
|
+
}, {
|
|
15355
|
+
test: [/tizen/i],
|
|
15356
|
+
describe: function describe61(ua) {
|
|
15357
|
+
var browser = {
|
|
15358
|
+
name: "Tizen"
|
|
15359
|
+
};
|
|
15360
|
+
var version2 = Utils.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15361
|
+
if (version2) browser.version = version2;
|
|
15362
|
+
return browser;
|
|
15363
|
+
}
|
|
15364
|
+
}, {
|
|
15365
|
+
test: [/qupzilla/i],
|
|
15366
|
+
describe: function describe62(ua) {
|
|
15367
|
+
var browser = {
|
|
15368
|
+
name: "QupZilla"
|
|
15369
|
+
};
|
|
15370
|
+
var version2 = Utils.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15371
|
+
if (version2) browser.version = version2;
|
|
15372
|
+
return browser;
|
|
15373
|
+
}
|
|
15374
|
+
}, {
|
|
15375
|
+
test: [/librewolf/i],
|
|
15376
|
+
describe: function describe63(ua) {
|
|
15377
|
+
var browser = {
|
|
15378
|
+
name: "LibreWolf"
|
|
15379
|
+
};
|
|
15380
|
+
var version2 = Utils.getFirstMatch(/(?:librewolf)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15381
|
+
if (version2) browser.version = version2;
|
|
15382
|
+
return browser;
|
|
15383
|
+
}
|
|
15384
|
+
}, {
|
|
15385
|
+
test: [/firefox|iceweasel|fxios/i],
|
|
15386
|
+
describe: function describe64(ua) {
|
|
15387
|
+
var browser = {
|
|
15388
|
+
name: "Firefox"
|
|
15389
|
+
};
|
|
15390
|
+
var version2 = Utils.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15391
|
+
if (version2) browser.version = version2;
|
|
15392
|
+
return browser;
|
|
15393
|
+
}
|
|
15394
|
+
}, {
|
|
15395
|
+
test: [/electron/i],
|
|
15396
|
+
describe: function describe65(ua) {
|
|
15397
|
+
var browser = {
|
|
15398
|
+
name: "Electron"
|
|
15399
|
+
};
|
|
15400
|
+
var version2 = Utils.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15401
|
+
if (version2) browser.version = version2;
|
|
15402
|
+
return browser;
|
|
15403
|
+
}
|
|
15404
|
+
}, {
|
|
15405
|
+
test: [/sogoumobilebrowser/i, /metasr/i, /se 2\.[x]/i],
|
|
15406
|
+
describe: function describe66(ua) {
|
|
15407
|
+
var browser = {
|
|
15408
|
+
name: "Sogou Browser"
|
|
15409
|
+
};
|
|
15410
|
+
var sogouMobileVersion = Utils.getFirstMatch(/(?:sogoumobilebrowser)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15411
|
+
var chromiumVersion = Utils.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15412
|
+
var seVersion = Utils.getFirstMatch(/se ([\d.]+)x/i, ua);
|
|
15413
|
+
var version2 = sogouMobileVersion || chromiumVersion || seVersion;
|
|
15414
|
+
if (version2) browser.version = version2;
|
|
15415
|
+
return browser;
|
|
15416
|
+
}
|
|
15417
|
+
}, {
|
|
15418
|
+
test: [/MiuiBrowser/i],
|
|
15419
|
+
describe: function describe67(ua) {
|
|
15420
|
+
var browser = {
|
|
15421
|
+
name: "Miui"
|
|
15422
|
+
};
|
|
15423
|
+
var version2 = Utils.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i, ua);
|
|
15424
|
+
if (version2) browser.version = version2;
|
|
15425
|
+
return browser;
|
|
15426
|
+
}
|
|
15427
|
+
}, {
|
|
15428
|
+
test: function test2(parser) {
|
|
15429
|
+
if (parser.hasBrand("DuckDuckGo")) return true;
|
|
15430
|
+
return parser.test(/\sDdg\/[\d.]+$/i);
|
|
15431
|
+
},
|
|
15432
|
+
describe: function describe68(ua, parser) {
|
|
15433
|
+
var browser = {
|
|
15434
|
+
name: "DuckDuckGo"
|
|
15435
|
+
};
|
|
15436
|
+
if (parser) {
|
|
15437
|
+
var hintsVersion = parser.getBrandVersion("DuckDuckGo");
|
|
15438
|
+
if (hintsVersion) {
|
|
15439
|
+
browser.version = hintsVersion;
|
|
15440
|
+
return browser;
|
|
15441
|
+
}
|
|
15442
|
+
}
|
|
15443
|
+
var uaVersion = Utils.getFirstMatch(/\sDdg\/([\d.]+)$/i, ua);
|
|
15444
|
+
if (uaVersion) browser.version = uaVersion;
|
|
15445
|
+
return browser;
|
|
15446
|
+
}
|
|
15447
|
+
}, {
|
|
15448
|
+
test: function test3(parser) {
|
|
15449
|
+
return parser.hasBrand("Brave");
|
|
15450
|
+
},
|
|
15451
|
+
describe: function describe69(ua, parser) {
|
|
15452
|
+
var browser = {
|
|
15453
|
+
name: "Brave"
|
|
15454
|
+
};
|
|
15455
|
+
if (parser) {
|
|
15456
|
+
var hintsVersion = parser.getBrandVersion("Brave");
|
|
15457
|
+
if (hintsVersion) {
|
|
15458
|
+
browser.version = hintsVersion;
|
|
15459
|
+
return browser;
|
|
15460
|
+
}
|
|
15461
|
+
}
|
|
15462
|
+
return browser;
|
|
15463
|
+
}
|
|
15464
|
+
}, {
|
|
15465
|
+
test: [/chromium/i],
|
|
15466
|
+
describe: function describe70(ua) {
|
|
15467
|
+
var browser = {
|
|
15468
|
+
name: "Chromium"
|
|
15469
|
+
};
|
|
15470
|
+
var version2 = Utils.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i, ua) || Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15471
|
+
if (version2) browser.version = version2;
|
|
15472
|
+
return browser;
|
|
15473
|
+
}
|
|
15474
|
+
}, {
|
|
15475
|
+
test: [/ladybird/i],
|
|
15476
|
+
describe: function describe71(ua) {
|
|
15477
|
+
var browser = {
|
|
15478
|
+
name: "Ladybird"
|
|
15479
|
+
};
|
|
15480
|
+
var version2 = Utils.getFirstMatch(/ladybird\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15481
|
+
if (version2) browser.version = version2;
|
|
15482
|
+
return browser;
|
|
15483
|
+
}
|
|
15484
|
+
}, {
|
|
15485
|
+
test: [/chrome|crios|crmo/i],
|
|
15486
|
+
describe: function describe72(ua) {
|
|
15487
|
+
var browser = {
|
|
15488
|
+
name: "Chrome"
|
|
15489
|
+
};
|
|
15490
|
+
var version2 = Utils.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15491
|
+
if (version2) browser.version = version2;
|
|
15492
|
+
return browser;
|
|
15493
|
+
}
|
|
15494
|
+
}, {
|
|
15495
|
+
test: [/GSA/i],
|
|
15496
|
+
describe: function describe73(ua) {
|
|
15497
|
+
var browser = {
|
|
15498
|
+
name: "Google Search"
|
|
15499
|
+
};
|
|
15500
|
+
var version2 = Utils.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i, ua);
|
|
15501
|
+
if (version2) browser.version = version2;
|
|
15502
|
+
return browser;
|
|
15503
|
+
}
|
|
15504
|
+
}, {
|
|
15505
|
+
test: function test4(parser) {
|
|
15506
|
+
var notLikeAndroid = !parser.test(/like android/i);
|
|
15507
|
+
var butAndroid = parser.test(/android/i);
|
|
15508
|
+
return notLikeAndroid && butAndroid;
|
|
15509
|
+
},
|
|
15510
|
+
describe: function describe74(ua) {
|
|
15511
|
+
var browser = {
|
|
15512
|
+
name: "Android Browser"
|
|
15513
|
+
};
|
|
15514
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15515
|
+
if (version2) browser.version = version2;
|
|
15516
|
+
return browser;
|
|
15517
|
+
}
|
|
15518
|
+
}, {
|
|
15519
|
+
test: [/playstation 4/i],
|
|
15520
|
+
describe: function describe75(ua) {
|
|
15521
|
+
var browser = {
|
|
15522
|
+
name: "PlayStation 4"
|
|
15523
|
+
};
|
|
15524
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15525
|
+
if (version2) browser.version = version2;
|
|
15526
|
+
return browser;
|
|
15527
|
+
}
|
|
15528
|
+
}, {
|
|
15529
|
+
test: [/safari|applewebkit/i],
|
|
15530
|
+
describe: function describe76(ua) {
|
|
15531
|
+
var browser = {
|
|
15532
|
+
name: "Safari"
|
|
15533
|
+
};
|
|
15534
|
+
var version2 = Utils.getFirstMatch(commonVersionIdentifier, ua);
|
|
15535
|
+
if (version2) browser.version = version2;
|
|
15536
|
+
return browser;
|
|
15537
|
+
}
|
|
15538
|
+
}, {
|
|
15539
|
+
test: [/.*/i],
|
|
15540
|
+
describe: function describe77(ua) {
|
|
15541
|
+
var regexp = ua.search("\\(") !== -1 ? /^(.*)\/([^/]*)[ \t]\((.*)/ : /^(.*)\/([^/]*) /;
|
|
15542
|
+
return {
|
|
15543
|
+
name: Utils.getFirstMatch(regexp, ua),
|
|
15544
|
+
version: Utils.getSecondMatch(regexp, ua)
|
|
15545
|
+
};
|
|
15546
|
+
}
|
|
15547
|
+
}];
|
|
15548
|
+
parser_os_default = [{
|
|
15549
|
+
test: [/Roku\/DVP/],
|
|
15550
|
+
describe: function describe78(ua) {
|
|
15551
|
+
var version2 = Utils.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i, ua);
|
|
15552
|
+
return {
|
|
15553
|
+
name: OS_MAP.Roku,
|
|
15554
|
+
version: version2
|
|
15555
|
+
};
|
|
15556
|
+
}
|
|
15557
|
+
}, {
|
|
15558
|
+
test: [/windows phone/i],
|
|
15559
|
+
describe: function describe79(ua) {
|
|
15560
|
+
var version2 = Utils.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i, ua);
|
|
15561
|
+
return {
|
|
15562
|
+
name: OS_MAP.WindowsPhone,
|
|
15563
|
+
version: version2
|
|
15564
|
+
};
|
|
15565
|
+
}
|
|
15566
|
+
}, {
|
|
15567
|
+
test: [/windows /i],
|
|
15568
|
+
describe: function describe80(ua) {
|
|
15569
|
+
var version2 = Utils.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i, ua);
|
|
15570
|
+
var versionName = Utils.getWindowsVersionName(version2);
|
|
15571
|
+
return {
|
|
15572
|
+
name: OS_MAP.Windows,
|
|
15573
|
+
version: version2,
|
|
15574
|
+
versionName
|
|
15575
|
+
};
|
|
15576
|
+
}
|
|
15577
|
+
}, {
|
|
15578
|
+
test: function test5(parser) {
|
|
15579
|
+
return Utils.isFirefoxOnIpad(parser.getUA());
|
|
15580
|
+
},
|
|
15581
|
+
describe: function describe81(ua) {
|
|
15582
|
+
var result = {
|
|
15583
|
+
name: OS_MAP.iOS
|
|
15584
|
+
};
|
|
15585
|
+
var version2 = Utils.getSecondMatch(/(Version\/)(\d[\d.]+)/, ua);
|
|
15586
|
+
if (version2) result.version = version2;
|
|
15587
|
+
return result;
|
|
15588
|
+
}
|
|
15589
|
+
}, {
|
|
15590
|
+
test: [/macintosh/i],
|
|
15591
|
+
describe: function describe82(ua) {
|
|
15592
|
+
var version2 = Utils.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i, ua).replace(/[_\s]/g, ".");
|
|
15593
|
+
var versionName = Utils.getMacOSVersionName(version2);
|
|
15594
|
+
var os = {
|
|
15595
|
+
name: OS_MAP.MacOS,
|
|
15596
|
+
version: version2
|
|
15597
|
+
};
|
|
15598
|
+
if (versionName) os.versionName = versionName;
|
|
15599
|
+
return os;
|
|
15600
|
+
}
|
|
15601
|
+
}, {
|
|
15602
|
+
test: [/(ipod|iphone|ipad)/i],
|
|
15603
|
+
describe: function describe83(ua) {
|
|
15604
|
+
var version2 = Utils.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i, ua).replace(/[_\s]/g, ".");
|
|
15605
|
+
return {
|
|
15606
|
+
name: OS_MAP.iOS,
|
|
15607
|
+
version: version2
|
|
15608
|
+
};
|
|
15609
|
+
}
|
|
15610
|
+
}, {
|
|
15611
|
+
test: [/OpenHarmony/i],
|
|
15612
|
+
describe: function describe84(ua) {
|
|
15613
|
+
var version2 = Utils.getFirstMatch(/OpenHarmony\s+(\d+(\.\d+)*)/i, ua);
|
|
15614
|
+
return {
|
|
15615
|
+
name: OS_MAP.HarmonyOS,
|
|
15616
|
+
version: version2
|
|
15617
|
+
};
|
|
15618
|
+
}
|
|
15619
|
+
}, {
|
|
15620
|
+
test: function test6(parser) {
|
|
15621
|
+
var notLikeAndroid = !parser.test(/like android/i);
|
|
15622
|
+
var butAndroid = parser.test(/android/i);
|
|
15623
|
+
return notLikeAndroid && butAndroid;
|
|
15624
|
+
},
|
|
15625
|
+
describe: function describe85(ua) {
|
|
15626
|
+
var version2 = Utils.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i, ua);
|
|
15627
|
+
var versionName = Utils.getAndroidVersionName(version2);
|
|
15628
|
+
var os = {
|
|
15629
|
+
name: OS_MAP.Android,
|
|
15630
|
+
version: version2
|
|
15631
|
+
};
|
|
15632
|
+
if (versionName) os.versionName = versionName;
|
|
15633
|
+
return os;
|
|
15634
|
+
}
|
|
15635
|
+
}, {
|
|
15636
|
+
test: [/(web|hpw)[o0]s/i],
|
|
15637
|
+
describe: function describe86(ua) {
|
|
15638
|
+
var version2 = Utils.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i, ua);
|
|
15639
|
+
var os = {
|
|
15640
|
+
name: OS_MAP.WebOS
|
|
15641
|
+
};
|
|
15642
|
+
if (version2 && version2.length) os.version = version2;
|
|
15643
|
+
return os;
|
|
15644
|
+
}
|
|
15645
|
+
}, {
|
|
15646
|
+
test: [/blackberry|\bbb\d+/i, /rim\stablet/i],
|
|
15647
|
+
describe: function describe87(ua) {
|
|
15648
|
+
var version2 = Utils.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i, ua) || Utils.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i, ua) || Utils.getFirstMatch(/\bbb(\d+)/i, ua);
|
|
15649
|
+
return {
|
|
15650
|
+
name: OS_MAP.BlackBerry,
|
|
15651
|
+
version: version2
|
|
15652
|
+
};
|
|
15653
|
+
}
|
|
15654
|
+
}, {
|
|
15655
|
+
test: [/bada/i],
|
|
15656
|
+
describe: function describe88(ua) {
|
|
15657
|
+
var version2 = Utils.getFirstMatch(/bada\/(\d+(\.\d+)*)/i, ua);
|
|
15658
|
+
return {
|
|
15659
|
+
name: OS_MAP.Bada,
|
|
15660
|
+
version: version2
|
|
15661
|
+
};
|
|
15662
|
+
}
|
|
15663
|
+
}, {
|
|
15664
|
+
test: [/tizen/i],
|
|
15665
|
+
describe: function describe89(ua) {
|
|
15666
|
+
var version2 = Utils.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i, ua);
|
|
15667
|
+
return {
|
|
15668
|
+
name: OS_MAP.Tizen,
|
|
15669
|
+
version: version2
|
|
15670
|
+
};
|
|
15671
|
+
}
|
|
15672
|
+
}, {
|
|
15673
|
+
test: [/linux/i],
|
|
15674
|
+
describe: function describe90() {
|
|
15675
|
+
return {
|
|
15676
|
+
name: OS_MAP.Linux
|
|
15677
|
+
};
|
|
15678
|
+
}
|
|
15679
|
+
}, {
|
|
15680
|
+
test: [/CrOS/],
|
|
15681
|
+
describe: function describe91() {
|
|
15682
|
+
return {
|
|
15683
|
+
name: OS_MAP.ChromeOS
|
|
15684
|
+
};
|
|
15685
|
+
}
|
|
15686
|
+
}, {
|
|
15687
|
+
test: [/PlayStation 4/],
|
|
15688
|
+
describe: function describe92(ua) {
|
|
15689
|
+
var version2 = Utils.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i, ua);
|
|
15690
|
+
return {
|
|
15691
|
+
name: OS_MAP.PlayStation4,
|
|
15692
|
+
version: version2
|
|
15693
|
+
};
|
|
15694
|
+
}
|
|
15695
|
+
}];
|
|
15696
|
+
parser_platforms_default = [{
|
|
15697
|
+
test: [/googlebot/i],
|
|
15698
|
+
describe: function describe93() {
|
|
15699
|
+
return {
|
|
15700
|
+
type: PLATFORMS_MAP.bot,
|
|
15701
|
+
vendor: "Google"
|
|
15702
|
+
};
|
|
15703
|
+
}
|
|
15704
|
+
}, {
|
|
15705
|
+
test: [/linespider/i],
|
|
15706
|
+
describe: function describe94() {
|
|
15707
|
+
return {
|
|
15708
|
+
type: PLATFORMS_MAP.bot,
|
|
15709
|
+
vendor: "Line"
|
|
15710
|
+
};
|
|
15711
|
+
}
|
|
15712
|
+
}, {
|
|
15713
|
+
test: [/amazonbot/i],
|
|
15714
|
+
describe: function describe95() {
|
|
15715
|
+
return {
|
|
15716
|
+
type: PLATFORMS_MAP.bot,
|
|
15717
|
+
vendor: "Amazon"
|
|
15718
|
+
};
|
|
15719
|
+
}
|
|
15720
|
+
}, {
|
|
15721
|
+
test: [/gptbot/i],
|
|
15722
|
+
describe: function describe96() {
|
|
15723
|
+
return {
|
|
15724
|
+
type: PLATFORMS_MAP.bot,
|
|
15725
|
+
vendor: "OpenAI"
|
|
15726
|
+
};
|
|
15727
|
+
}
|
|
15728
|
+
}, {
|
|
15729
|
+
test: [/chatgpt-user/i],
|
|
15730
|
+
describe: function describe97() {
|
|
15731
|
+
return {
|
|
15732
|
+
type: PLATFORMS_MAP.bot,
|
|
15733
|
+
vendor: "OpenAI"
|
|
15734
|
+
};
|
|
15735
|
+
}
|
|
15736
|
+
}, {
|
|
15737
|
+
test: [/oai-searchbot/i],
|
|
15738
|
+
describe: function describe98() {
|
|
15739
|
+
return {
|
|
15740
|
+
type: PLATFORMS_MAP.bot,
|
|
15741
|
+
vendor: "OpenAI"
|
|
15742
|
+
};
|
|
15743
|
+
}
|
|
15744
|
+
}, {
|
|
15745
|
+
test: [/baiduspider/i],
|
|
15746
|
+
describe: function describe99() {
|
|
15747
|
+
return {
|
|
15748
|
+
type: PLATFORMS_MAP.bot,
|
|
15749
|
+
vendor: "Baidu"
|
|
15750
|
+
};
|
|
15751
|
+
}
|
|
15752
|
+
}, {
|
|
15753
|
+
test: [/bingbot/i],
|
|
15754
|
+
describe: function describe100() {
|
|
15755
|
+
return {
|
|
15756
|
+
type: PLATFORMS_MAP.bot,
|
|
15757
|
+
vendor: "Bing"
|
|
15758
|
+
};
|
|
15759
|
+
}
|
|
15760
|
+
}, {
|
|
15761
|
+
test: [/duckduckbot/i],
|
|
15762
|
+
describe: function describe101() {
|
|
15763
|
+
return {
|
|
15764
|
+
type: PLATFORMS_MAP.bot,
|
|
15765
|
+
vendor: "DuckDuckGo"
|
|
15766
|
+
};
|
|
15767
|
+
}
|
|
15768
|
+
}, {
|
|
15769
|
+
test: [/claudebot/i, /claude-web/i, /claude-user/i, /claude-searchbot/i],
|
|
15770
|
+
describe: function describe102() {
|
|
15771
|
+
return {
|
|
15772
|
+
type: PLATFORMS_MAP.bot,
|
|
15773
|
+
vendor: "Anthropic"
|
|
15774
|
+
};
|
|
15775
|
+
}
|
|
15776
|
+
}, {
|
|
15777
|
+
test: [/omgilibot/i, /webzio-extended/i],
|
|
15778
|
+
describe: function describe103() {
|
|
15779
|
+
return {
|
|
15780
|
+
type: PLATFORMS_MAP.bot,
|
|
15781
|
+
vendor: "Webz.io"
|
|
15782
|
+
};
|
|
15783
|
+
}
|
|
15784
|
+
}, {
|
|
15785
|
+
test: [/diffbot/i],
|
|
15786
|
+
describe: function describe104() {
|
|
15787
|
+
return {
|
|
15788
|
+
type: PLATFORMS_MAP.bot,
|
|
15789
|
+
vendor: "Diffbot"
|
|
15790
|
+
};
|
|
15791
|
+
}
|
|
15792
|
+
}, {
|
|
15793
|
+
test: [/perplexitybot/i],
|
|
15794
|
+
describe: function describe105() {
|
|
15795
|
+
return {
|
|
15796
|
+
type: PLATFORMS_MAP.bot,
|
|
15797
|
+
vendor: "Perplexity AI"
|
|
15798
|
+
};
|
|
15799
|
+
}
|
|
15800
|
+
}, {
|
|
15801
|
+
test: [/perplexity-user/i],
|
|
15802
|
+
describe: function describe106() {
|
|
15803
|
+
return {
|
|
15804
|
+
type: PLATFORMS_MAP.bot,
|
|
15805
|
+
vendor: "Perplexity AI"
|
|
15806
|
+
};
|
|
15807
|
+
}
|
|
15808
|
+
}, {
|
|
15809
|
+
test: [/youbot/i],
|
|
15810
|
+
describe: function describe107() {
|
|
15811
|
+
return {
|
|
15812
|
+
type: PLATFORMS_MAP.bot,
|
|
15813
|
+
vendor: "You.com"
|
|
15814
|
+
};
|
|
15815
|
+
}
|
|
15816
|
+
}, {
|
|
15817
|
+
test: [/ia_archiver/i],
|
|
15818
|
+
describe: function describe108() {
|
|
15819
|
+
return {
|
|
15820
|
+
type: PLATFORMS_MAP.bot,
|
|
15821
|
+
vendor: "Internet Archive"
|
|
15822
|
+
};
|
|
15823
|
+
}
|
|
15824
|
+
}, {
|
|
15825
|
+
test: [/meta-webindexer/i],
|
|
15826
|
+
describe: function describe109() {
|
|
15827
|
+
return {
|
|
15828
|
+
type: PLATFORMS_MAP.bot,
|
|
15829
|
+
vendor: "Meta"
|
|
15830
|
+
};
|
|
15831
|
+
}
|
|
15832
|
+
}, {
|
|
15833
|
+
test: [/meta-externalads/i],
|
|
15834
|
+
describe: function describe110() {
|
|
15835
|
+
return {
|
|
15836
|
+
type: PLATFORMS_MAP.bot,
|
|
15837
|
+
vendor: "Meta"
|
|
15838
|
+
};
|
|
15839
|
+
}
|
|
15840
|
+
}, {
|
|
15841
|
+
test: [/meta-externalagent/i],
|
|
15842
|
+
describe: function describe111() {
|
|
15843
|
+
return {
|
|
15844
|
+
type: PLATFORMS_MAP.bot,
|
|
15845
|
+
vendor: "Meta"
|
|
15846
|
+
};
|
|
15847
|
+
}
|
|
15848
|
+
}, {
|
|
15849
|
+
test: [/meta-externalfetcher/i],
|
|
15850
|
+
describe: function describe112() {
|
|
15851
|
+
return {
|
|
15852
|
+
type: PLATFORMS_MAP.bot,
|
|
15853
|
+
vendor: "Meta"
|
|
15854
|
+
};
|
|
15855
|
+
}
|
|
15856
|
+
}, {
|
|
15857
|
+
test: [/facebookexternalhit/i, /facebookcatalog/i],
|
|
15858
|
+
describe: function describe113() {
|
|
15859
|
+
return {
|
|
15860
|
+
type: PLATFORMS_MAP.bot,
|
|
15861
|
+
vendor: "Meta"
|
|
15862
|
+
};
|
|
15863
|
+
}
|
|
15864
|
+
}, {
|
|
15865
|
+
test: [/slackbot/i, /slack-imgProxy/i],
|
|
15866
|
+
describe: function describe114() {
|
|
15867
|
+
return {
|
|
15868
|
+
type: PLATFORMS_MAP.bot,
|
|
15869
|
+
vendor: "Slack"
|
|
15870
|
+
};
|
|
15871
|
+
}
|
|
15872
|
+
}, {
|
|
15873
|
+
test: [/yahoo/i],
|
|
15874
|
+
describe: function describe115() {
|
|
15875
|
+
return {
|
|
15876
|
+
type: PLATFORMS_MAP.bot,
|
|
15877
|
+
vendor: "Yahoo"
|
|
15878
|
+
};
|
|
15879
|
+
}
|
|
15880
|
+
}, {
|
|
15881
|
+
test: [/yandexbot/i, /yandexmobilebot/i],
|
|
15882
|
+
describe: function describe116() {
|
|
15883
|
+
return {
|
|
15884
|
+
type: PLATFORMS_MAP.bot,
|
|
15885
|
+
vendor: "Yandex"
|
|
15886
|
+
};
|
|
15887
|
+
}
|
|
15888
|
+
}, {
|
|
15889
|
+
test: [/pingdom/i],
|
|
15890
|
+
describe: function describe117() {
|
|
15891
|
+
return {
|
|
15892
|
+
type: PLATFORMS_MAP.bot,
|
|
15893
|
+
vendor: "Pingdom"
|
|
15894
|
+
};
|
|
15895
|
+
}
|
|
15896
|
+
}, {
|
|
15897
|
+
test: [/huawei/i],
|
|
15898
|
+
describe: function describe118(ua) {
|
|
15899
|
+
var model = Utils.getFirstMatch(/(can-l01)/i, ua) && "Nova";
|
|
15900
|
+
var platform2 = {
|
|
15901
|
+
type: PLATFORMS_MAP.mobile,
|
|
15902
|
+
vendor: "Huawei"
|
|
15903
|
+
};
|
|
15904
|
+
if (model) platform2.model = model;
|
|
15905
|
+
return platform2;
|
|
15906
|
+
}
|
|
15907
|
+
}, {
|
|
15908
|
+
test: [/nexus\s*(?:7|8|9|10).*/i],
|
|
15909
|
+
describe: function describe119() {
|
|
15910
|
+
return {
|
|
15911
|
+
type: PLATFORMS_MAP.tablet,
|
|
15912
|
+
vendor: "Nexus"
|
|
15913
|
+
};
|
|
15914
|
+
}
|
|
15915
|
+
}, {
|
|
15916
|
+
test: [/ipad/i],
|
|
15917
|
+
describe: function describe120() {
|
|
15918
|
+
return {
|
|
15919
|
+
type: PLATFORMS_MAP.tablet,
|
|
15920
|
+
vendor: "Apple",
|
|
15921
|
+
model: "iPad"
|
|
15922
|
+
};
|
|
15923
|
+
}
|
|
15924
|
+
}, {
|
|
15925
|
+
test: function test7(parser) {
|
|
15926
|
+
return Utils.isFirefoxOnIpad(parser.getUA());
|
|
15927
|
+
},
|
|
15928
|
+
describe: function describe121() {
|
|
15929
|
+
return {
|
|
15930
|
+
type: PLATFORMS_MAP.tablet,
|
|
15931
|
+
vendor: "Apple",
|
|
15932
|
+
model: "iPad"
|
|
15933
|
+
};
|
|
15934
|
+
}
|
|
15935
|
+
}, {
|
|
15936
|
+
test: [/kftt build/i],
|
|
15937
|
+
describe: function describe122() {
|
|
15938
|
+
return {
|
|
15939
|
+
type: PLATFORMS_MAP.tablet,
|
|
15940
|
+
vendor: "Amazon",
|
|
15941
|
+
model: "Kindle Fire HD 7"
|
|
15942
|
+
};
|
|
15943
|
+
}
|
|
15944
|
+
}, {
|
|
15945
|
+
test: [/silk/i],
|
|
15946
|
+
describe: function describe123() {
|
|
15947
|
+
return {
|
|
15948
|
+
type: PLATFORMS_MAP.tablet,
|
|
15949
|
+
vendor: "Amazon"
|
|
15950
|
+
};
|
|
15951
|
+
}
|
|
15952
|
+
}, {
|
|
15953
|
+
test: [/tablet(?! pc)/i],
|
|
15954
|
+
describe: function describe124() {
|
|
15955
|
+
return {
|
|
15956
|
+
type: PLATFORMS_MAP.tablet
|
|
15957
|
+
};
|
|
15958
|
+
}
|
|
15959
|
+
}, {
|
|
15960
|
+
test: function test8(parser) {
|
|
15961
|
+
var iDevice = parser.test(/ipod|iphone/i);
|
|
15962
|
+
var likeIDevice = parser.test(/like (ipod|iphone)/i);
|
|
15963
|
+
return iDevice && !likeIDevice;
|
|
15964
|
+
},
|
|
15965
|
+
describe: function describe125(ua) {
|
|
15966
|
+
var model = Utils.getFirstMatch(/(ipod|iphone)/i, ua);
|
|
15967
|
+
return {
|
|
15968
|
+
type: PLATFORMS_MAP.mobile,
|
|
15969
|
+
vendor: "Apple",
|
|
15970
|
+
model
|
|
15971
|
+
};
|
|
15972
|
+
}
|
|
15973
|
+
}, {
|
|
15974
|
+
test: [/nexus\s*[0-6].*/i, /galaxy nexus/i],
|
|
15975
|
+
describe: function describe126() {
|
|
15976
|
+
return {
|
|
15977
|
+
type: PLATFORMS_MAP.mobile,
|
|
15978
|
+
vendor: "Nexus"
|
|
15979
|
+
};
|
|
15980
|
+
}
|
|
15981
|
+
}, {
|
|
15982
|
+
test: [/Nokia/i],
|
|
15983
|
+
describe: function describe127(ua) {
|
|
15984
|
+
var model = Utils.getFirstMatch(/Nokia\s+([0-9]+(\.[0-9]+)?)/i, ua);
|
|
15985
|
+
var platform2 = {
|
|
15986
|
+
type: PLATFORMS_MAP.mobile,
|
|
15987
|
+
vendor: "Nokia"
|
|
15988
|
+
};
|
|
15989
|
+
if (model) platform2.model = model;
|
|
15990
|
+
return platform2;
|
|
15991
|
+
}
|
|
15992
|
+
}, {
|
|
15993
|
+
test: [/[^-]mobi/i],
|
|
15994
|
+
describe: function describe128() {
|
|
15995
|
+
return {
|
|
15996
|
+
type: PLATFORMS_MAP.mobile
|
|
15997
|
+
};
|
|
15998
|
+
}
|
|
15999
|
+
}, {
|
|
16000
|
+
test: function test9(parser) {
|
|
16001
|
+
return parser.getBrowserName(true) === "blackberry";
|
|
16002
|
+
},
|
|
16003
|
+
describe: function describe129() {
|
|
16004
|
+
return {
|
|
16005
|
+
type: PLATFORMS_MAP.mobile,
|
|
16006
|
+
vendor: "BlackBerry"
|
|
16007
|
+
};
|
|
16008
|
+
}
|
|
16009
|
+
}, {
|
|
16010
|
+
test: function test10(parser) {
|
|
16011
|
+
return parser.getBrowserName(true) === "bada";
|
|
16012
|
+
},
|
|
16013
|
+
describe: function describe130() {
|
|
16014
|
+
return {
|
|
16015
|
+
type: PLATFORMS_MAP.mobile
|
|
16016
|
+
};
|
|
16017
|
+
}
|
|
16018
|
+
}, {
|
|
16019
|
+
test: function test11(parser) {
|
|
16020
|
+
return parser.getBrowserName() === "windows phone";
|
|
16021
|
+
},
|
|
16022
|
+
describe: function describe131() {
|
|
16023
|
+
return {
|
|
16024
|
+
type: PLATFORMS_MAP.mobile,
|
|
16025
|
+
vendor: "Microsoft"
|
|
16026
|
+
};
|
|
16027
|
+
}
|
|
16028
|
+
}, {
|
|
16029
|
+
test: function test12(parser) {
|
|
16030
|
+
var osMajorVersion = Number(String(parser.getOSVersion()).split(".")[0]);
|
|
16031
|
+
return parser.getOSName(true) === "android" && osMajorVersion >= 3;
|
|
16032
|
+
},
|
|
16033
|
+
describe: function describe132() {
|
|
16034
|
+
return {
|
|
16035
|
+
type: PLATFORMS_MAP.tablet
|
|
16036
|
+
};
|
|
16037
|
+
}
|
|
16038
|
+
}, {
|
|
16039
|
+
test: function test13(parser) {
|
|
16040
|
+
return parser.getOSName(true) === "android";
|
|
16041
|
+
},
|
|
16042
|
+
describe: function describe133() {
|
|
16043
|
+
return {
|
|
16044
|
+
type: PLATFORMS_MAP.mobile
|
|
16045
|
+
};
|
|
16046
|
+
}
|
|
16047
|
+
}, {
|
|
16048
|
+
test: [/smart-?tv|smarttv/i],
|
|
16049
|
+
describe: function describe134() {
|
|
16050
|
+
return {
|
|
16051
|
+
type: PLATFORMS_MAP.tv
|
|
16052
|
+
};
|
|
16053
|
+
}
|
|
16054
|
+
}, {
|
|
16055
|
+
test: [/netcast/i],
|
|
16056
|
+
describe: function describe135() {
|
|
16057
|
+
return {
|
|
16058
|
+
type: PLATFORMS_MAP.tv
|
|
16059
|
+
};
|
|
16060
|
+
}
|
|
16061
|
+
}, {
|
|
16062
|
+
test: function test14(parser) {
|
|
16063
|
+
return parser.getOSName(true) === "macos";
|
|
16064
|
+
},
|
|
16065
|
+
describe: function describe136() {
|
|
16066
|
+
return {
|
|
16067
|
+
type: PLATFORMS_MAP.desktop,
|
|
16068
|
+
vendor: "Apple"
|
|
16069
|
+
};
|
|
16070
|
+
}
|
|
16071
|
+
}, {
|
|
16072
|
+
test: function test15(parser) {
|
|
16073
|
+
return parser.getOSName(true) === "windows";
|
|
16074
|
+
},
|
|
16075
|
+
describe: function describe137() {
|
|
16076
|
+
return {
|
|
16077
|
+
type: PLATFORMS_MAP.desktop
|
|
16078
|
+
};
|
|
16079
|
+
}
|
|
16080
|
+
}, {
|
|
16081
|
+
test: function test16(parser) {
|
|
16082
|
+
return parser.getOSName(true) === "linux";
|
|
16083
|
+
},
|
|
16084
|
+
describe: function describe138() {
|
|
16085
|
+
return {
|
|
16086
|
+
type: PLATFORMS_MAP.desktop
|
|
16087
|
+
};
|
|
16088
|
+
}
|
|
16089
|
+
}, {
|
|
16090
|
+
test: function test17(parser) {
|
|
16091
|
+
return parser.getOSName(true) === "playstation 4";
|
|
16092
|
+
},
|
|
16093
|
+
describe: function describe139() {
|
|
16094
|
+
return {
|
|
16095
|
+
type: PLATFORMS_MAP.tv
|
|
16096
|
+
};
|
|
16097
|
+
}
|
|
16098
|
+
}, {
|
|
16099
|
+
test: function test18(parser) {
|
|
16100
|
+
return parser.getOSName(true) === "roku";
|
|
16101
|
+
},
|
|
16102
|
+
describe: function describe140() {
|
|
16103
|
+
return {
|
|
16104
|
+
type: PLATFORMS_MAP.tv
|
|
16105
|
+
};
|
|
16106
|
+
}
|
|
16107
|
+
}];
|
|
16108
|
+
parser_engines_default = [{
|
|
16109
|
+
test: function test19(parser) {
|
|
16110
|
+
return parser.getBrowserName(true) === "microsoft edge";
|
|
16111
|
+
},
|
|
16112
|
+
describe: function describe141(ua) {
|
|
16113
|
+
if (/\sedg\//i.test(ua)) return {
|
|
16114
|
+
name: ENGINE_MAP.Blink
|
|
16115
|
+
};
|
|
16116
|
+
var version2 = Utils.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i, ua);
|
|
16117
|
+
return {
|
|
16118
|
+
name: ENGINE_MAP.EdgeHTML,
|
|
16119
|
+
version: version2
|
|
16120
|
+
};
|
|
16121
|
+
}
|
|
16122
|
+
}, {
|
|
16123
|
+
test: function test20(parser) {
|
|
16124
|
+
return parser.getBrowserName(true) === "ladybird";
|
|
16125
|
+
},
|
|
16126
|
+
describe: function describe142() {
|
|
16127
|
+
return {
|
|
16128
|
+
name: ENGINE_MAP.LibWeb
|
|
16129
|
+
};
|
|
16130
|
+
}
|
|
16131
|
+
}, {
|
|
16132
|
+
test: [/trident/i],
|
|
16133
|
+
describe: function describe143(ua) {
|
|
16134
|
+
var engine = {
|
|
16135
|
+
name: ENGINE_MAP.Trident
|
|
16136
|
+
};
|
|
16137
|
+
var version2 = Utils.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i, ua);
|
|
16138
|
+
if (version2) engine.version = version2;
|
|
16139
|
+
return engine;
|
|
16140
|
+
}
|
|
16141
|
+
}, {
|
|
16142
|
+
test: function test21(parser) {
|
|
16143
|
+
return parser.test(/presto/i);
|
|
16144
|
+
},
|
|
16145
|
+
describe: function describe144(ua) {
|
|
16146
|
+
var engine = {
|
|
16147
|
+
name: ENGINE_MAP.Presto
|
|
16148
|
+
};
|
|
16149
|
+
var version2 = Utils.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i, ua);
|
|
16150
|
+
if (version2) engine.version = version2;
|
|
16151
|
+
return engine;
|
|
16152
|
+
}
|
|
16153
|
+
}, {
|
|
16154
|
+
test: function test22(parser) {
|
|
16155
|
+
var isGecko = parser.test(/gecko/i);
|
|
16156
|
+
var likeGecko = parser.test(/like gecko/i);
|
|
16157
|
+
return isGecko && !likeGecko;
|
|
16158
|
+
},
|
|
16159
|
+
describe: function describe145(ua) {
|
|
16160
|
+
var engine = {
|
|
16161
|
+
name: ENGINE_MAP.Gecko
|
|
16162
|
+
};
|
|
16163
|
+
var version2 = Utils.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i, ua);
|
|
16164
|
+
if (version2) engine.version = version2;
|
|
16165
|
+
return engine;
|
|
16166
|
+
}
|
|
16167
|
+
}, {
|
|
16168
|
+
test: [/(apple)?webkit\/537\.36/i],
|
|
16169
|
+
describe: function describe146() {
|
|
16170
|
+
return {
|
|
16171
|
+
name: ENGINE_MAP.Blink
|
|
16172
|
+
};
|
|
16173
|
+
}
|
|
16174
|
+
}, {
|
|
16175
|
+
test: [/(apple)?webkit/i],
|
|
16176
|
+
describe: function describe147(ua) {
|
|
16177
|
+
var engine = {
|
|
16178
|
+
name: ENGINE_MAP.WebKit
|
|
16179
|
+
};
|
|
16180
|
+
var version2 = Utils.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i, ua);
|
|
16181
|
+
if (version2) engine.version = version2;
|
|
16182
|
+
return engine;
|
|
16183
|
+
}
|
|
16184
|
+
}];
|
|
16185
|
+
Parser = /* @__PURE__ */ (function() {
|
|
16186
|
+
function Parser2(UA, skipParsingOrHints, clientHints) {
|
|
16187
|
+
if (skipParsingOrHints === void 0) skipParsingOrHints = false;
|
|
16188
|
+
if (clientHints === void 0) clientHints = null;
|
|
16189
|
+
if (UA === void 0 || UA === null || UA === "") throw new Error("UserAgent parameter can't be empty");
|
|
16190
|
+
this._ua = UA;
|
|
16191
|
+
var skipParsing = false;
|
|
16192
|
+
if (typeof skipParsingOrHints === "boolean") {
|
|
16193
|
+
skipParsing = skipParsingOrHints;
|
|
16194
|
+
this._hints = clientHints;
|
|
16195
|
+
} else if (skipParsingOrHints != null && typeof skipParsingOrHints === "object") this._hints = skipParsingOrHints;
|
|
16196
|
+
else this._hints = null;
|
|
16197
|
+
this.parsedResult = {};
|
|
16198
|
+
if (skipParsing !== true) this.parse();
|
|
16199
|
+
}
|
|
16200
|
+
var _proto = Parser2.prototype;
|
|
16201
|
+
_proto.getHints = function getHints() {
|
|
16202
|
+
return this._hints;
|
|
16203
|
+
};
|
|
16204
|
+
_proto.hasBrand = function hasBrand(brandName) {
|
|
16205
|
+
if (!this._hints || !Array.isArray(this._hints.brands)) return false;
|
|
16206
|
+
var brandLower = brandName.toLowerCase();
|
|
16207
|
+
return this._hints.brands.some(function(b5) {
|
|
16208
|
+
return b5.brand && b5.brand.toLowerCase() === brandLower;
|
|
16209
|
+
});
|
|
16210
|
+
};
|
|
16211
|
+
_proto.getBrandVersion = function getBrandVersion(brandName) {
|
|
16212
|
+
if (!this._hints || !Array.isArray(this._hints.brands)) return;
|
|
16213
|
+
var brandLower = brandName.toLowerCase();
|
|
16214
|
+
var brand = Utils.find(this._hints.brands, function(b5) {
|
|
16215
|
+
return b5.brand && b5.brand.toLowerCase() === brandLower;
|
|
16216
|
+
});
|
|
16217
|
+
return brand ? brand.version : void 0;
|
|
16218
|
+
};
|
|
16219
|
+
_proto.getUA = function getUA() {
|
|
16220
|
+
return this._ua;
|
|
16221
|
+
};
|
|
16222
|
+
_proto.test = function test23(regex) {
|
|
16223
|
+
return regex.test(this._ua);
|
|
16224
|
+
};
|
|
16225
|
+
_proto.parseBrowser = function parseBrowser() {
|
|
16226
|
+
var _this = this;
|
|
16227
|
+
this.parsedResult.browser = {};
|
|
16228
|
+
var browserDescriptor = Utils.find(browsersList, function(_browser) {
|
|
16229
|
+
if (typeof _browser.test === "function") return _browser.test(_this);
|
|
16230
|
+
if (Array.isArray(_browser.test)) return _browser.test.some(function(condition) {
|
|
16231
|
+
return _this.test(condition);
|
|
16232
|
+
});
|
|
16233
|
+
throw new Error("Browser's test function is not valid");
|
|
16234
|
+
});
|
|
16235
|
+
if (browserDescriptor) this.parsedResult.browser = browserDescriptor.describe(this.getUA(), this);
|
|
16236
|
+
return this.parsedResult.browser;
|
|
16237
|
+
};
|
|
16238
|
+
_proto.getBrowser = function getBrowser() {
|
|
16239
|
+
if (this.parsedResult.browser) return this.parsedResult.browser;
|
|
16240
|
+
return this.parseBrowser();
|
|
16241
|
+
};
|
|
16242
|
+
_proto.getBrowserName = function getBrowserName(toLowerCase) {
|
|
16243
|
+
if (toLowerCase) return String(this.getBrowser().name).toLowerCase() || "";
|
|
16244
|
+
return this.getBrowser().name || "";
|
|
16245
|
+
};
|
|
16246
|
+
_proto.getBrowserVersion = function getBrowserVersion() {
|
|
16247
|
+
return this.getBrowser().version;
|
|
16248
|
+
};
|
|
16249
|
+
_proto.getOS = function getOS() {
|
|
16250
|
+
if (this.parsedResult.os) return this.parsedResult.os;
|
|
16251
|
+
return this.parseOS();
|
|
16252
|
+
};
|
|
16253
|
+
_proto.parseOS = function parseOS() {
|
|
16254
|
+
var _this2 = this;
|
|
16255
|
+
this.parsedResult.os = {};
|
|
16256
|
+
var os = Utils.find(parser_os_default, function(_os) {
|
|
16257
|
+
if (typeof _os.test === "function") return _os.test(_this2);
|
|
16258
|
+
if (Array.isArray(_os.test)) return _os.test.some(function(condition) {
|
|
16259
|
+
return _this2.test(condition);
|
|
16260
|
+
});
|
|
16261
|
+
throw new Error("Browser's test function is not valid");
|
|
16262
|
+
});
|
|
16263
|
+
if (os) this.parsedResult.os = os.describe(this.getUA());
|
|
16264
|
+
return this.parsedResult.os;
|
|
16265
|
+
};
|
|
16266
|
+
_proto.getOSName = function getOSName(toLowerCase) {
|
|
16267
|
+
var name = this.getOS().name;
|
|
16268
|
+
if (toLowerCase) return String(name).toLowerCase() || "";
|
|
16269
|
+
return name || "";
|
|
16270
|
+
};
|
|
16271
|
+
_proto.getOSVersion = function getOSVersion() {
|
|
16272
|
+
return this.getOS().version;
|
|
16273
|
+
};
|
|
16274
|
+
_proto.getPlatform = function getPlatform() {
|
|
16275
|
+
if (this.parsedResult.platform) return this.parsedResult.platform;
|
|
16276
|
+
return this.parsePlatform();
|
|
16277
|
+
};
|
|
16278
|
+
_proto.getPlatformType = function getPlatformType(toLowerCase) {
|
|
16279
|
+
if (toLowerCase === void 0) toLowerCase = false;
|
|
16280
|
+
var type = this.getPlatform().type;
|
|
16281
|
+
if (toLowerCase) return String(type).toLowerCase() || "";
|
|
16282
|
+
return type || "";
|
|
16283
|
+
};
|
|
16284
|
+
_proto.parsePlatform = function parsePlatform() {
|
|
16285
|
+
var _this3 = this;
|
|
16286
|
+
this.parsedResult.platform = {};
|
|
16287
|
+
var platform2 = Utils.find(parser_platforms_default, function(_platform) {
|
|
16288
|
+
if (typeof _platform.test === "function") return _platform.test(_this3);
|
|
16289
|
+
if (Array.isArray(_platform.test)) return _platform.test.some(function(condition) {
|
|
16290
|
+
return _this3.test(condition);
|
|
16291
|
+
});
|
|
16292
|
+
throw new Error("Browser's test function is not valid");
|
|
16293
|
+
});
|
|
16294
|
+
if (platform2) this.parsedResult.platform = platform2.describe(this.getUA());
|
|
16295
|
+
return this.parsedResult.platform;
|
|
16296
|
+
};
|
|
16297
|
+
_proto.getEngine = function getEngine() {
|
|
16298
|
+
if (this.parsedResult.engine) return this.parsedResult.engine;
|
|
16299
|
+
return this.parseEngine();
|
|
16300
|
+
};
|
|
16301
|
+
_proto.getEngineName = function getEngineName(toLowerCase) {
|
|
16302
|
+
if (toLowerCase) return String(this.getEngine().name).toLowerCase() || "";
|
|
16303
|
+
return this.getEngine().name || "";
|
|
16304
|
+
};
|
|
16305
|
+
_proto.parseEngine = function parseEngine() {
|
|
16306
|
+
var _this4 = this;
|
|
16307
|
+
this.parsedResult.engine = {};
|
|
16308
|
+
var engine = Utils.find(parser_engines_default, function(_engine) {
|
|
16309
|
+
if (typeof _engine.test === "function") return _engine.test(_this4);
|
|
16310
|
+
if (Array.isArray(_engine.test)) return _engine.test.some(function(condition) {
|
|
16311
|
+
return _this4.test(condition);
|
|
16312
|
+
});
|
|
16313
|
+
throw new Error("Browser's test function is not valid");
|
|
16314
|
+
});
|
|
16315
|
+
if (engine) this.parsedResult.engine = engine.describe(this.getUA());
|
|
16316
|
+
return this.parsedResult.engine;
|
|
16317
|
+
};
|
|
16318
|
+
_proto.parse = function parse4() {
|
|
16319
|
+
this.parseBrowser();
|
|
16320
|
+
this.parseOS();
|
|
16321
|
+
this.parsePlatform();
|
|
16322
|
+
this.parseEngine();
|
|
16323
|
+
return this;
|
|
16324
|
+
};
|
|
16325
|
+
_proto.getResult = function getResult() {
|
|
16326
|
+
return Utils.assign({}, this.parsedResult);
|
|
16327
|
+
};
|
|
16328
|
+
_proto.satisfies = function satisfies(checkTree) {
|
|
16329
|
+
var _this5 = this;
|
|
16330
|
+
var platformsAndOSes = {};
|
|
16331
|
+
var platformsAndOSCounter = 0;
|
|
16332
|
+
var browsers = {};
|
|
16333
|
+
var browsersCounter = 0;
|
|
16334
|
+
Object.keys(checkTree).forEach(function(key) {
|
|
16335
|
+
var currentDefinition = checkTree[key];
|
|
16336
|
+
if (typeof currentDefinition === "string" || Array.isArray(currentDefinition)) {
|
|
16337
|
+
browsers[key] = currentDefinition;
|
|
16338
|
+
browsersCounter += 1;
|
|
16339
|
+
} else if (typeof currentDefinition === "object") {
|
|
16340
|
+
platformsAndOSes[key] = currentDefinition;
|
|
16341
|
+
platformsAndOSCounter += 1;
|
|
16342
|
+
}
|
|
16343
|
+
});
|
|
16344
|
+
if (platformsAndOSCounter > 0) {
|
|
16345
|
+
var platformsAndOSNames = Object.keys(platformsAndOSes);
|
|
16346
|
+
var OSMatchingDefinition = Utils.find(platformsAndOSNames, function(name) {
|
|
16347
|
+
return _this5.isOS(name);
|
|
16348
|
+
});
|
|
16349
|
+
if (OSMatchingDefinition) {
|
|
16350
|
+
var osResult = this.satisfies(platformsAndOSes[OSMatchingDefinition]);
|
|
16351
|
+
if (osResult !== void 0) return osResult;
|
|
16352
|
+
}
|
|
16353
|
+
var platformMatchingDefinition = Utils.find(platformsAndOSNames, function(name) {
|
|
16354
|
+
return _this5.isPlatform(name);
|
|
16355
|
+
});
|
|
16356
|
+
if (platformMatchingDefinition) {
|
|
16357
|
+
var platformResult = this.satisfies(platformsAndOSes[platformMatchingDefinition]);
|
|
16358
|
+
if (platformResult !== void 0) return platformResult;
|
|
16359
|
+
}
|
|
16360
|
+
}
|
|
16361
|
+
if (browsersCounter > 0) {
|
|
16362
|
+
var browserNames = Object.keys(browsers);
|
|
16363
|
+
var matchingDefinition = Utils.find(browserNames, function(name) {
|
|
16364
|
+
return _this5.isBrowser(name, true);
|
|
16365
|
+
});
|
|
16366
|
+
if (matchingDefinition !== void 0) return this.compareVersions(browsers[matchingDefinition]);
|
|
16367
|
+
}
|
|
16368
|
+
};
|
|
16369
|
+
_proto.isBrowser = function isBrowser(browserName, includingAlias) {
|
|
16370
|
+
if (includingAlias === void 0) includingAlias = false;
|
|
16371
|
+
var defaultBrowserName = this.getBrowserName().toLowerCase();
|
|
16372
|
+
var browserNameLower = browserName.toLowerCase();
|
|
16373
|
+
var alias = Utils.getBrowserTypeByAlias(browserNameLower);
|
|
16374
|
+
if (includingAlias && alias) browserNameLower = alias.toLowerCase();
|
|
16375
|
+
return browserNameLower === defaultBrowserName;
|
|
16376
|
+
};
|
|
16377
|
+
_proto.compareVersions = function compareVersions(versionsOrVersion) {
|
|
16378
|
+
var _this6 = this;
|
|
16379
|
+
if (typeof versionsOrVersion === "string") return this.compareVersion(versionsOrVersion);
|
|
16380
|
+
return versionsOrVersion.some(function(version2) {
|
|
16381
|
+
return _this6.compareVersion(version2);
|
|
16382
|
+
});
|
|
16383
|
+
};
|
|
16384
|
+
_proto.compareVersion = function compareVersion(version2) {
|
|
16385
|
+
var expectedResults = [0];
|
|
16386
|
+
var comparableVersion = version2;
|
|
16387
|
+
var isLoose = false;
|
|
16388
|
+
var currentBrowserVersion = this.getBrowserVersion();
|
|
16389
|
+
if (typeof currentBrowserVersion !== "string") return;
|
|
16390
|
+
if (version2[0] === ">" || version2[0] === "<") {
|
|
16391
|
+
comparableVersion = version2.substr(1);
|
|
16392
|
+
if (version2[1] === "=") {
|
|
16393
|
+
isLoose = true;
|
|
16394
|
+
comparableVersion = version2.substr(2);
|
|
16395
|
+
} else expectedResults = [];
|
|
16396
|
+
if (version2[0] === ">") expectedResults.push(1);
|
|
16397
|
+
else expectedResults.push(-1);
|
|
16398
|
+
} else if (version2[0] === "=") comparableVersion = version2.substr(1);
|
|
16399
|
+
else if (version2[0] === "~") {
|
|
16400
|
+
isLoose = true;
|
|
16401
|
+
comparableVersion = version2.substr(1);
|
|
16402
|
+
}
|
|
16403
|
+
return expectedResults.indexOf(Utils.compareVersions(currentBrowserVersion, comparableVersion, isLoose)) > -1;
|
|
16404
|
+
};
|
|
16405
|
+
_proto.isOS = function isOS(osName) {
|
|
16406
|
+
return this.getOSName(true) === String(osName).toLowerCase();
|
|
16407
|
+
};
|
|
16408
|
+
_proto.isPlatform = function isPlatform(platformType) {
|
|
16409
|
+
return this.getPlatformType(true) === String(platformType).toLowerCase();
|
|
16410
|
+
};
|
|
16411
|
+
_proto.isEngine = function isEngine(engineName) {
|
|
16412
|
+
return this.getEngineName(true) === String(engineName).toLowerCase();
|
|
16413
|
+
};
|
|
16414
|
+
_proto.is = function is(anything, includingAlias) {
|
|
16415
|
+
if (includingAlias === void 0) includingAlias = false;
|
|
16416
|
+
return this.isBrowser(anything, includingAlias) || this.isOS(anything) || this.isPlatform(anything);
|
|
16417
|
+
};
|
|
16418
|
+
_proto.some = function some(anythings) {
|
|
16419
|
+
var _this7 = this;
|
|
16420
|
+
if (anythings === void 0) anythings = [];
|
|
16421
|
+
return anythings.some(function(anything) {
|
|
16422
|
+
return _this7.is(anything);
|
|
16423
|
+
});
|
|
16424
|
+
};
|
|
16425
|
+
return Parser2;
|
|
16426
|
+
})();
|
|
16427
|
+
Bowser = /* @__PURE__ */ (function() {
|
|
16428
|
+
function Bowser2() {
|
|
16429
|
+
}
|
|
16430
|
+
Bowser2.getParser = function getParser2(UA, skipParsingOrHints, clientHints) {
|
|
16431
|
+
if (skipParsingOrHints === void 0) skipParsingOrHints = false;
|
|
16432
|
+
if (clientHints === void 0) clientHints = null;
|
|
16433
|
+
if (typeof UA !== "string") throw new Error("UserAgent should be a string");
|
|
16434
|
+
return new Parser(UA, skipParsingOrHints, clientHints);
|
|
16435
|
+
};
|
|
16436
|
+
Bowser2.parse = function parse4(UA, clientHints) {
|
|
16437
|
+
if (clientHints === void 0) clientHints = null;
|
|
16438
|
+
return new Parser(UA, clientHints).getResult();
|
|
16439
|
+
};
|
|
16440
|
+
return _createClass(Bowser2, null, [{
|
|
16441
|
+
key: "BROWSER_MAP",
|
|
16442
|
+
get: function get2() {
|
|
16443
|
+
return BROWSER_MAP;
|
|
16444
|
+
}
|
|
16445
|
+
}, {
|
|
16446
|
+
key: "ENGINE_MAP",
|
|
16447
|
+
get: function get2() {
|
|
16448
|
+
return ENGINE_MAP;
|
|
16449
|
+
}
|
|
16450
|
+
}, {
|
|
16451
|
+
key: "OS_MAP",
|
|
16452
|
+
get: function get2() {
|
|
16453
|
+
return OS_MAP;
|
|
16454
|
+
}
|
|
16455
|
+
}, {
|
|
16456
|
+
key: "PLATFORMS_MAP",
|
|
16457
|
+
get: function get2() {
|
|
16458
|
+
return PLATFORMS_MAP;
|
|
16459
|
+
}
|
|
16460
|
+
}]);
|
|
16461
|
+
})();
|
|
16462
|
+
parse3 = Bowser.parse;
|
|
16463
|
+
getParser = Bowser.getParser;
|
|
15167
16464
|
}
|
|
15168
16465
|
});
|
|
15169
16466
|
|
|
@@ -15172,9 +16469,9 @@ var createUserAgentStringParsingProvider;
|
|
|
15172
16469
|
var init_createUserAgentStringParsingProvider = __esm({
|
|
15173
16470
|
"node_modules/@aws-sdk/core/dist-es/submodules/client/util-user-agent-browser/createUserAgentStringParsingProvider.js"() {
|
|
15174
16471
|
createUserAgentStringParsingProvider = ({ serviceId, clientVersion }) => async (config2) => {
|
|
15175
|
-
const module = await Promise.resolve().then(() =>
|
|
15176
|
-
const
|
|
15177
|
-
const parsedUA = typeof window !== "undefined" && window?.navigator?.userAgent ?
|
|
16472
|
+
const module = await Promise.resolve().then(() => (init_bowser(), bowser_exports));
|
|
16473
|
+
const parse4 = module.parse ?? module.default.parse ?? (() => "");
|
|
16474
|
+
const parsedUA = typeof window !== "undefined" && window?.navigator?.userAgent ? parse4(window.navigator.userAgent) : void 0;
|
|
15178
16475
|
const sections = [
|
|
15179
16476
|
["aws-sdk-js", clientVersion],
|
|
15180
16477
|
["ua", "2.1"],
|
|
@@ -16996,13 +18293,25 @@ var require_dist_cjs5 = __commonJS({
|
|
|
16996
18293
|
}
|
|
16997
18294
|
return timing.setTimeout(registerListener, deferTimeMs);
|
|
16998
18295
|
};
|
|
18296
|
+
var resolveDefaultSocketTimeout = (config2) => {
|
|
18297
|
+
const value = config2?.defaultSocketTimeout;
|
|
18298
|
+
return typeof value === "number" && Number.isFinite(value) && value > 0 ? value : void 0;
|
|
18299
|
+
};
|
|
16999
18300
|
var DEFER_EVENT_LISTENER_TIME = 3e3;
|
|
17000
|
-
var setSocketTimeout = (request, reject, timeoutInMs = 0) => {
|
|
18301
|
+
var setSocketTimeout = (request, reject, timeoutInMs = 0, destroyResponseBodyOnTimeout = false) => {
|
|
18302
|
+
let response;
|
|
18303
|
+
if (destroyResponseBodyOnTimeout) {
|
|
18304
|
+
request.once("response", (res) => response = res);
|
|
18305
|
+
}
|
|
17001
18306
|
const registerTimeout = (offset) => {
|
|
17002
18307
|
const timeout = timeoutInMs - offset;
|
|
17003
18308
|
const onTimeout = () => {
|
|
18309
|
+
const error63 = Object.assign(new Error(`@smithy/node-http-handler - the request socket timed out after ${timeoutInMs} ms of inactivity (${destroyResponseBodyOnTimeout ? "service default socket timeout" : "configured by client requestHandler"}).`), { name: "TimeoutError" });
|
|
18310
|
+
if (destroyResponseBodyOnTimeout) {
|
|
18311
|
+
response?.destroy(error63);
|
|
18312
|
+
}
|
|
17004
18313
|
request.destroy();
|
|
17005
|
-
reject(
|
|
18314
|
+
reject(error63);
|
|
17006
18315
|
};
|
|
17007
18316
|
if (request.socket) {
|
|
17008
18317
|
request.socket.setTimeout(timeout, onTimeout);
|
|
@@ -17015,7 +18324,12 @@ var require_dist_cjs5 = __commonJS({
|
|
|
17015
18324
|
registerTimeout(0);
|
|
17016
18325
|
return 0;
|
|
17017
18326
|
}
|
|
17018
|
-
|
|
18327
|
+
const deferralId = timing.setTimeout(registerTimeout.bind(null, timeoutInMs === 0 ? 0 : DEFER_EVENT_LISTENER_TIME), DEFER_EVENT_LISTENER_TIME);
|
|
18328
|
+
if (destroyResponseBodyOnTimeout) {
|
|
18329
|
+
request.once("close", () => timing.clearTimeout(deferralId));
|
|
18330
|
+
return 0;
|
|
18331
|
+
}
|
|
18332
|
+
return deferralId;
|
|
17019
18333
|
};
|
|
17020
18334
|
var MIN_WAIT_TIME = 6e3;
|
|
17021
18335
|
async function writeRequestBody(httpRequest, request, maxContinueTimeoutMs = MIN_WAIT_TIME, externalAgent = false) {
|
|
@@ -17243,7 +18557,12 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
17243
18557
|
const effectiveRequestTimeout = requestTimeout ?? config2.requestTimeout;
|
|
17244
18558
|
connectionTimeoutId = setConnectionTimeout(req, reject, config2.connectionTimeout);
|
|
17245
18559
|
requestTimeoutId = setRequestTimeout(req, reject, effectiveRequestTimeout, config2.throwOnRequestTimeout, logger2 ?? console);
|
|
17246
|
-
|
|
18560
|
+
const defaultSocketTimeout = config2.socketTimeout === void 0 ? resolveDefaultSocketTimeout(config2) : void 0;
|
|
18561
|
+
if (defaultSocketTimeout) {
|
|
18562
|
+
socketTimeoutId = setSocketTimeout(req, reject, defaultSocketTimeout, true);
|
|
18563
|
+
} else {
|
|
18564
|
+
socketTimeoutId = setSocketTimeout(req, reject, config2.socketTimeout);
|
|
18565
|
+
}
|
|
17247
18566
|
const httpAgent = nodeHttpsOptions.agent;
|
|
17248
18567
|
if (typeof httpAgent === "object" && "keepAlive" in httpAgent) {
|
|
17249
18568
|
keepAliveTimeoutId = setSocketKeepAlive(req, {
|
|
@@ -17283,6 +18602,7 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
17283
18602
|
connectionTimeout,
|
|
17284
18603
|
requestTimeout,
|
|
17285
18604
|
socketTimeout,
|
|
18605
|
+
defaultSocketTimeout: resolveDefaultSocketTimeout(options),
|
|
17286
18606
|
socketAcquisitionWarningTimeout,
|
|
17287
18607
|
throwOnRequestTimeout,
|
|
17288
18608
|
httpAgentProvider: async () => {
|
|
@@ -17560,7 +18880,8 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
17560
18880
|
}
|
|
17561
18881
|
async handle(request, { abortSignal, requestTimeout, isEventStream } = {}) {
|
|
17562
18882
|
if (!this.config) {
|
|
17563
|
-
|
|
18883
|
+
const config2 = await this.configProvider;
|
|
18884
|
+
this.config = { ...config2, defaultSocketTimeout: resolveDefaultSocketTimeout(config2) };
|
|
17564
18885
|
const { disableConcurrentStreams: disableConcurrentStreams2, maxConcurrentStreams, nodeHttp2ConnectOptions } = this.config;
|
|
17565
18886
|
this.connectionManager.setDisableConcurrentStreams(disableConcurrentStreams2 ?? false);
|
|
17566
18887
|
if (maxConcurrentStreams) {
|
|
@@ -17570,9 +18891,10 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
17570
18891
|
this.connectionManager.setNodeHttp2ConnectOptions(nodeHttp2ConnectOptions);
|
|
17571
18892
|
}
|
|
17572
18893
|
}
|
|
17573
|
-
const { requestTimeout: configRequestTimeout, disableConcurrentStreams } = this.config;
|
|
18894
|
+
const { requestTimeout: configRequestTimeout, disableConcurrentStreams, sessionTimeout } = this.config;
|
|
17574
18895
|
const useIsolatedSession = disableConcurrentStreams || isEventStream;
|
|
17575
18896
|
const effectiveRequestTimeout = requestTimeout ?? configRequestTimeout;
|
|
18897
|
+
const defaultSocketTimeout = effectiveRequestTimeout === void 0 && sessionTimeout === void 0 ? this.config.defaultSocketTimeout : void 0;
|
|
17576
18898
|
return new Promise((_resolve, _reject) => {
|
|
17577
18899
|
let fulfilled = false;
|
|
17578
18900
|
let writeRequestBodyPromise = void 0;
|
|
@@ -17632,6 +18954,18 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
17632
18954
|
timeoutError.name = "TimeoutError";
|
|
17633
18955
|
rejectWithDestroy(timeoutError);
|
|
17634
18956
|
});
|
|
18957
|
+
} else if (defaultSocketTimeout) {
|
|
18958
|
+
clientHttp2Stream.setTimeout(defaultSocketTimeout, () => {
|
|
18959
|
+
const timeoutError = new Error(`Stream timed out because of no activity for ${defaultSocketTimeout} ms`);
|
|
18960
|
+
timeoutError.name = "TimeoutError";
|
|
18961
|
+
fulfilled = true;
|
|
18962
|
+
reject(timeoutError);
|
|
18963
|
+
clientHttp2Stream.destroy(timeoutError);
|
|
18964
|
+
if (useIsolatedSession) {
|
|
18965
|
+
ref.destroy();
|
|
18966
|
+
}
|
|
18967
|
+
});
|
|
18968
|
+
clientHttp2Stream.once("response", () => clientHttp2Stream.setTimeout(defaultSocketTimeout));
|
|
17635
18969
|
}
|
|
17636
18970
|
if (abortSignal) {
|
|
17637
18971
|
const onAbort = () => {
|
|
@@ -17948,7 +19282,7 @@ var init_package = __esm({
|
|
|
17948
19282
|
"node_modules/@aws-sdk/nested-clients/package.json"() {
|
|
17949
19283
|
package_default = {
|
|
17950
19284
|
name: "@aws-sdk/nested-clients",
|
|
17951
|
-
version: "3.997.
|
|
19285
|
+
version: "3.997.51",
|
|
17952
19286
|
description: "Nested clients for AWS SDK packages.",
|
|
17953
19287
|
homepage: "https://github.com/aws/aws-sdk-js-v3/tree/main/packages/nested-clients",
|
|
17954
19288
|
license: "Apache-2.0",
|
|
@@ -18048,12 +19382,12 @@ var init_package = __esm({
|
|
|
18048
19382
|
"test:watch": "yarn g:vitest watch"
|
|
18049
19383
|
},
|
|
18050
19384
|
dependencies: {
|
|
18051
|
-
"@aws-sdk/core": "^3.978.
|
|
19385
|
+
"@aws-sdk/core": "^3.978.6",
|
|
18052
19386
|
"@aws-sdk/signature-v4-multi-region": "^3.996.49",
|
|
18053
19387
|
"@aws-sdk/types": "^3.975.0",
|
|
18054
|
-
"@smithy/core": "^3.
|
|
19388
|
+
"@smithy/core": "^3.37.0",
|
|
18055
19389
|
"@smithy/fetch-http-handler": "^5.8.0",
|
|
18056
|
-
"@smithy/node-http-handler": "^4.
|
|
19390
|
+
"@smithy/node-http-handler": "^4.13.0",
|
|
18057
19391
|
"@smithy/types": "^4.19.0",
|
|
18058
19392
|
tslib: "^2.6.2"
|
|
18059
19393
|
},
|
|
@@ -19381,52 +20715,29 @@ var init_SmithyRpcV2CborProtocol = __esm({
|
|
|
19381
20715
|
"node_modules/@smithy/core/dist-es/submodules/cbor/SmithyRpcV2CborProtocol.js"() {
|
|
19382
20716
|
init_protocols();
|
|
19383
20717
|
init_schema();
|
|
19384
|
-
init_transport();
|
|
19385
20718
|
init_CborCodec();
|
|
19386
20719
|
init_parseCborBody();
|
|
19387
|
-
SmithyRpcV2CborProtocol = class extends
|
|
20720
|
+
SmithyRpcV2CborProtocol = class extends AbstractRpcV2Protocol {
|
|
19388
20721
|
codec = new CborCodec();
|
|
19389
20722
|
serializer = this.codec.createSerializer();
|
|
19390
20723
|
deserializer = this.codec.createDeserializer();
|
|
19391
|
-
constructor({ defaultNamespace, errorTypeRegistries: errorTypeRegistries5 }) {
|
|
19392
|
-
super({ defaultNamespace, errorTypeRegistries: errorTypeRegistries5 });
|
|
19393
|
-
}
|
|
19394
20724
|
getShapeId() {
|
|
19395
20725
|
return "smithy.protocols#rpcv2Cbor";
|
|
19396
20726
|
}
|
|
19397
20727
|
getPayloadCodec() {
|
|
19398
20728
|
return this.codec;
|
|
19399
20729
|
}
|
|
19400
|
-
|
|
19401
|
-
|
|
19402
|
-
|
|
19403
|
-
|
|
19404
|
-
|
|
19405
|
-
|
|
19406
|
-
|
|
19407
|
-
if (deref(operationSchema.input) === "unit") {
|
|
19408
|
-
delete request.body;
|
|
19409
|
-
delete request.headers["content-type"];
|
|
19410
|
-
} else {
|
|
19411
|
-
if (!request.body) {
|
|
19412
|
-
this.serializer.write(15, {});
|
|
19413
|
-
request.body = this.serializer.flush();
|
|
19414
|
-
}
|
|
19415
|
-
if (request.body instanceof Uint8Array) {
|
|
19416
|
-
request.headers["content-length"] = String(request.body.byteLength);
|
|
19417
|
-
}
|
|
20730
|
+
getSmithyProtocolHeaderValue() {
|
|
20731
|
+
return "rpc-v2-cbor";
|
|
20732
|
+
}
|
|
20733
|
+
applyEmptyBody(request) {
|
|
20734
|
+
if (!request.body) {
|
|
20735
|
+
this.serializer.write(15, {});
|
|
20736
|
+
request.body = this.serializer.flush();
|
|
19418
20737
|
}
|
|
19419
|
-
|
|
19420
|
-
|
|
19421
|
-
if (request.path.endsWith("/")) {
|
|
19422
|
-
request.path += path.slice(1);
|
|
19423
|
-
} else {
|
|
19424
|
-
request.path += path;
|
|
20738
|
+
if (request.body instanceof Uint8Array) {
|
|
20739
|
+
request.headers["content-length"] = String(request.body.byteLength);
|
|
19425
20740
|
}
|
|
19426
|
-
return request;
|
|
19427
|
-
}
|
|
19428
|
-
async deserializeResponse(operationSchema, context, response) {
|
|
19429
|
-
return super.deserializeResponse(operationSchema, context, response);
|
|
19430
20741
|
}
|
|
19431
20742
|
async handleError(operationSchema, context, response, dataObject, metadata) {
|
|
19432
20743
|
const errorIdentifier = loadSmithyRpcV2CborErrorCode(response, dataObject) ?? "Unknown";
|
|
@@ -26441,7 +27752,7 @@ var require_dist_cjs16 = __commonJS({
|
|
|
26441
27752
|
Region: { type: "builtInParams", name: "region" },
|
|
26442
27753
|
UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }
|
|
26443
27754
|
};
|
|
26444
|
-
var version2 = "3.
|
|
27755
|
+
var version2 = "3.1156.0";
|
|
26445
27756
|
var packageInfo = {
|
|
26446
27757
|
version: version2
|
|
26447
27758
|
};
|
|
@@ -28232,7 +29543,7 @@ var require_dist_cjs17 = __commonJS({
|
|
|
28232
29543
|
Region: { type: "builtInParams", name: "region" },
|
|
28233
29544
|
UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }
|
|
28234
29545
|
};
|
|
28235
|
-
var version2 = "3.
|
|
29546
|
+
var version2 = "3.1156.0";
|
|
28236
29547
|
var packageInfo = {
|
|
28237
29548
|
version: version2
|
|
28238
29549
|
};
|
|
@@ -43668,9 +44979,9 @@ ${indent}${start}${value}${end2}`;
|
|
|
43668
44979
|
const str = value.replace(/\n+/g, `$&
|
|
43669
44980
|
${indent}`);
|
|
43670
44981
|
if (actualString) {
|
|
43671
|
-
const
|
|
44982
|
+
const test23 = (tag2) => tag2.default && tag2.tag !== "tag:yaml.org,2002:str" && tag2.test?.test(str);
|
|
43672
44983
|
const { compat, tags } = ctx.doc.schema;
|
|
43673
|
-
if (tags.some(
|
|
44984
|
+
if (tags.some(test23) || compat?.some(test23))
|
|
43674
44985
|
return quotedString(value, ctx);
|
|
43675
44986
|
}
|
|
43676
44987
|
return implicitKey ? str : foldFlowLines.foldFlowLines(str, indent, foldFlowLines.FOLD_FLOW, getFoldOptions(ctx, false));
|
|
@@ -48597,10 +49908,10 @@ var require_lexer = __commonJS({
|
|
|
48597
49908
|
}
|
|
48598
49909
|
return n3;
|
|
48599
49910
|
}
|
|
48600
|
-
*pushUntil(
|
|
49911
|
+
*pushUntil(test23) {
|
|
48601
49912
|
let i5 = this.pos;
|
|
48602
49913
|
let ch = this.buffer[i5];
|
|
48603
|
-
while (!
|
|
49914
|
+
while (!test23(ch))
|
|
48604
49915
|
ch = this.buffer[++i5];
|
|
48605
49916
|
return yield* this.pushToIndex(i5, false);
|
|
48606
49917
|
}
|
|
@@ -48737,7 +50048,7 @@ var require_parser = __commonJS({
|
|
|
48737
50048
|
}
|
|
48738
50049
|
}
|
|
48739
50050
|
}
|
|
48740
|
-
var
|
|
50051
|
+
var Parser2 = class {
|
|
48741
50052
|
/**
|
|
48742
50053
|
* @param onNewLine - If defined, called separately with the start position of
|
|
48743
50054
|
* each new line (in `parse()`, including the start of input).
|
|
@@ -49510,7 +50821,7 @@ var require_parser = __commonJS({
|
|
|
49510
50821
|
}
|
|
49511
50822
|
}
|
|
49512
50823
|
};
|
|
49513
|
-
exports.Parser =
|
|
50824
|
+
exports.Parser = Parser2;
|
|
49514
50825
|
}
|
|
49515
50826
|
});
|
|
49516
50827
|
|
|
@@ -49563,7 +50874,7 @@ var require_public_api = __commonJS({
|
|
|
49563
50874
|
}
|
|
49564
50875
|
return doc;
|
|
49565
50876
|
}
|
|
49566
|
-
function
|
|
50877
|
+
function parse4(src, reviver, options) {
|
|
49567
50878
|
let _reviver = void 0;
|
|
49568
50879
|
if (typeof reviver === "function") {
|
|
49569
50880
|
_reviver = reviver;
|
|
@@ -49604,7 +50915,7 @@ var require_public_api = __commonJS({
|
|
|
49604
50915
|
return value.toString(options);
|
|
49605
50916
|
return new Document.Document(value, _replacer, options).toString(options);
|
|
49606
50917
|
}
|
|
49607
|
-
exports.parse =
|
|
50918
|
+
exports.parse = parse4;
|
|
49608
50919
|
exports.parseAllDocuments = parseAllDocuments;
|
|
49609
50920
|
exports.parseDocument = parseDocument;
|
|
49610
50921
|
exports.stringify = stringify;
|
|
@@ -51767,18 +53078,18 @@ var validateAsync = async (schema, value, _ctx) => {
|
|
|
51767
53078
|
return result.issues.length === 0;
|
|
51768
53079
|
};
|
|
51769
53080
|
var _encode = (_Err) => {
|
|
51770
|
-
const
|
|
53081
|
+
const parse4 = _parse(_Err);
|
|
51771
53082
|
const fn = (schema, value, _ctx, _params) => {
|
|
51772
53083
|
const ctx = _ctx ? { ..._ctx, direction: "backward" } : { direction: "backward" };
|
|
51773
|
-
return
|
|
53084
|
+
return parse4(schema, value, ctx, finalizeParams(fn, _params));
|
|
51774
53085
|
};
|
|
51775
53086
|
return fn;
|
|
51776
53087
|
};
|
|
51777
53088
|
var encode = /* @__PURE__ */ _encode($ZodRealError);
|
|
51778
53089
|
var _decode = (_Err) => {
|
|
51779
|
-
const
|
|
53090
|
+
const parse4 = _parse(_Err);
|
|
51780
53091
|
const fn = (schema, value, _ctx, _params) => {
|
|
51781
|
-
return
|
|
53092
|
+
return parse4(schema, value, _ctx, finalizeParams(fn, _params));
|
|
51782
53093
|
};
|
|
51783
53094
|
return fn;
|
|
51784
53095
|
};
|
|
@@ -53273,7 +54584,7 @@ function capSize(inst, size) {
|
|
|
53273
54584
|
if (!caps.length)
|
|
53274
54585
|
return;
|
|
53275
54586
|
const cap = Math.min(...caps.map((c5) => c5[0]));
|
|
53276
|
-
const
|
|
54587
|
+
const parse4 = inst._zod.parse;
|
|
53277
54588
|
inst._zod.parse = (payload2, ctx) => {
|
|
53278
54589
|
const n3 = size(payload2.value);
|
|
53279
54590
|
if (n3 > cap && !ctx?.skipChecks && ctx?.direction !== "backward") {
|
|
@@ -53287,7 +54598,7 @@ function capSize(inst, size) {
|
|
|
53287
54598
|
}
|
|
53288
54599
|
}
|
|
53289
54600
|
}
|
|
53290
|
-
return
|
|
54601
|
+
return parse4(payload2, ctx);
|
|
53291
54602
|
};
|
|
53292
54603
|
}
|
|
53293
54604
|
var arraySize = (input2) => Array.isArray(input2) ? input2.length : -1;
|
|
@@ -71825,16 +73136,21 @@ var _getQueryParam = (url2, key, multiple) => {
|
|
|
71825
73136
|
if (hashIndex !== -1) url2 = url2.slice(0, hashIndex);
|
|
71826
73137
|
let encoded;
|
|
71827
73138
|
if (!multiple && key && key.indexOf("%") === -1 && key.indexOf("+") === -1) {
|
|
71828
|
-
|
|
73139
|
+
const queryIndex = url2.indexOf("?", 8);
|
|
73140
|
+
let keyIndex2 = queryIndex;
|
|
71829
73141
|
if (keyIndex2 === -1) return;
|
|
71830
73142
|
if (!url2.startsWith(key, keyIndex2 + 1)) keyIndex2 = url2.indexOf(`&${key}`, keyIndex2 + 1);
|
|
71831
73143
|
while (keyIndex2 !== -1) {
|
|
71832
73144
|
const trailingKeyCode = url2.charCodeAt(keyIndex2 + key.length + 1);
|
|
71833
|
-
if (trailingKeyCode === 61) {
|
|
71834
|
-
|
|
71835
|
-
|
|
71836
|
-
|
|
71837
|
-
|
|
73145
|
+
if (trailingKeyCode === 61 || trailingKeyCode === 38 || isNaN(trailingKeyCode)) {
|
|
73146
|
+
if (keyIndex2 > queryIndex && /(?:^|&)[^=&]*[%+]/.test(url2.slice(queryIndex + 1, keyIndex2))) break;
|
|
73147
|
+
if (trailingKeyCode === 61) {
|
|
73148
|
+
const valueIndex = keyIndex2 + key.length + 2;
|
|
73149
|
+
const endIndex = url2.indexOf("&", valueIndex);
|
|
73150
|
+
return _decodeURI(url2.slice(valueIndex, endIndex === -1 ? void 0 : endIndex));
|
|
73151
|
+
}
|
|
73152
|
+
return "";
|
|
73153
|
+
}
|
|
71838
73154
|
keyIndex2 = url2.indexOf(`&${key}`, keyIndex2 + 1);
|
|
71839
73155
|
}
|
|
71840
73156
|
encoded = /[%+]/.test(url2);
|
|
@@ -73340,7 +74656,7 @@ var Node3 = class Node4 {
|
|
|
73340
74656
|
const restPathString = path.slice(partOffsets[i5]);
|
|
73341
74657
|
const m3 = matcher.exec(restPathString);
|
|
73342
74658
|
if (m3) {
|
|
73343
|
-
params[name] = m3[0];
|
|
74659
|
+
if (!Object.hasOwn(params, name)) params[name] = m3[0];
|
|
73344
74660
|
this.#pushHandlerSets(handlerSets, child, method, node2.#params, params);
|
|
73345
74661
|
if (m3[0].length === restPathString.length && child.#children["*"]) this.#pushHandlerSets(handlerSets, child.#children["*"], method, node2.#params, params);
|
|
73346
74662
|
for (const _ in child.#children) {
|
|
@@ -73353,7 +74669,7 @@ var Node3 = class Node4 {
|
|
|
73353
74669
|
}
|
|
73354
74670
|
}
|
|
73355
74671
|
if (matcher === true || matcher.test(part)) {
|
|
73356
|
-
params[name] = part;
|
|
74672
|
+
if (!Object.hasOwn(params, name)) params[name] = part;
|
|
73357
74673
|
if (isLast) {
|
|
73358
74674
|
this.#pushHandlerSets(handlerSets, child, method, params, node2.#params);
|
|
73359
74675
|
if (child.#children["*"]) this.#pushHandlerSets(handlerSets, child.#children["*"], method, params, node2.#params);
|
|
@@ -74294,7 +75610,7 @@ async function fetchTemplate(assetPath, fetcher) {
|
|
|
74294
75610
|
try {
|
|
74295
75611
|
response = await fetcher(url2);
|
|
74296
75612
|
} catch (cause) {
|
|
74297
|
-
throw new TemplateFetchError(assetPath, `the request failed: ${
|
|
75613
|
+
throw new TemplateFetchError(assetPath, `the request failed: ${describe148(cause)}`);
|
|
74298
75614
|
}
|
|
74299
75615
|
if (!response.ok) {
|
|
74300
75616
|
throw new TemplateFetchError(assetPath, `responded ${response.status} ${response.statusText}`);
|
|
@@ -74309,7 +75625,7 @@ async function fetchTemplate(assetPath, fetcher) {
|
|
|
74309
75625
|
return body;
|
|
74310
75626
|
}
|
|
74311
75627
|
var HEAD_PATTERN = /<head[^>]*>/i;
|
|
74312
|
-
function
|
|
75628
|
+
function describe148(cause) {
|
|
74313
75629
|
return cause instanceof Error ? cause.message : String(cause);
|
|
74314
75630
|
}
|
|
74315
75631
|
var TemplateCache = class {
|
|
@@ -75009,3 +76325,19 @@ var handler = handle({
|
|
|
75009
76325
|
export {
|
|
75010
76326
|
handler
|
|
75011
76327
|
};
|
|
76328
|
+
/*! Bundled license information:
|
|
76329
|
+
|
|
76330
|
+
bowser/bowser.mjs:
|
|
76331
|
+
(*!
|
|
76332
|
+
* Bowser - a browser detector
|
|
76333
|
+
* https://github.com/lancedikson/bowser
|
|
76334
|
+
* MIT License | (c) Dustin Diaz 2012-2015
|
|
76335
|
+
* MIT License | (c) Denis Demchenko 2015-2026
|
|
76336
|
+
*)
|
|
76337
|
+
(*!
|
|
76338
|
+
* Bowser - a browser detector
|
|
76339
|
+
* https://github.com/bowser-js/bowser
|
|
76340
|
+
* MIT License | (c) Dustin Diaz 2012-2015
|
|
76341
|
+
* MIT License | (c) Denis Demchenko 2015-2026
|
|
76342
|
+
*)
|
|
76343
|
+
*/
|