@capacitor-community/admob 6.2.0 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CapacitorCommunityAdmob.podspec +1 -1
- package/Package.swift +2 -2
- package/README.md +85 -58
- package/android/build.gradle +11 -11
- package/dist/docs.json +107 -797
- package/package.json +12 -12
|
@@ -11,7 +11,7 @@ Pod::Spec.new do |s|
|
|
|
11
11
|
s.author = package['author']
|
|
12
12
|
s.source = { :git => package['repository']['url'], :tag => s.version.to_s }
|
|
13
13
|
s.source_files = 'ios/Sources/**/*.{swift,h,m,c,cc,mm,cpp}'
|
|
14
|
-
s.ios.deployment_target
|
|
14
|
+
s.ios.deployment_target = '14.0'
|
|
15
15
|
s.swift_version = '5.1'
|
|
16
16
|
s.static_framework = true
|
|
17
17
|
s.dependency 'Capacitor'
|
package/Package.swift
CHANGED
|
@@ -3,14 +3,14 @@ import PackageDescription
|
|
|
3
3
|
|
|
4
4
|
let package = Package(
|
|
5
5
|
name: "CapacitorCommunityAdmob",
|
|
6
|
-
platforms: [.iOS(.
|
|
6
|
+
platforms: [.iOS(.v14)],
|
|
7
7
|
products: [
|
|
8
8
|
.library(
|
|
9
9
|
name: "CapacitorCommunityAdmob",
|
|
10
10
|
targets: ["AdMobPlugin"])
|
|
11
11
|
],
|
|
12
12
|
dependencies: [
|
|
13
|
-
.package(url: "https://github.com/ionic-team/capacitor-swift-pm.git", from: "
|
|
13
|
+
.package(url: "https://github.com/ionic-team/capacitor-swift-pm.git", from: "7.0.0"),
|
|
14
14
|
.package(url: "https://github.com/googleads/swift-package-manager-google-mobile-ads.git", branch: "main")
|
|
15
15
|
],
|
|
16
16
|
targets: [
|
package/README.md
CHANGED
|
@@ -6,8 +6,7 @@
|
|
|
6
6
|
</p>
|
|
7
7
|
|
|
8
8
|
<p align="center">
|
|
9
|
-
<img src="https://img.shields.io/maintenance/yes/
|
|
10
|
-
<!-- <a href="https://github.com/capacitor-community/example/actions?query=workflow%3A%22CI%22"><img src="https://img.shields.io/github/workflow/status/capacitor-community/example/CI?style=flat-square" /></a> -->
|
|
9
|
+
<img src="https://img.shields.io/maintenance/yes/2025?style=flat-square" />
|
|
11
10
|
<a href="https://www.npmjs.com/package/@capacitor-community/admob"><img src="https://img.shields.io/npm/l/@capacitor-community/admob?style=flat-square" /></a>
|
|
12
11
|
<br>
|
|
13
12
|
<a href="https://www.npmjs.com/package/@capacitor-community/admob"><img src="https://img.shields.io/npm/dw/@capacitor-community/admob?style=flat-square" /></a>
|
|
@@ -44,30 +43,10 @@ Made with [contributors-img](https://contrib.rocks).
|
|
|
44
43
|
|
|
45
44
|
## Installation
|
|
46
45
|
|
|
47
|
-
If you use capacitor 6
|
|
46
|
+
If you use capacitor 6:
|
|
48
47
|
|
|
49
|
-
```bash
|
|
50
|
-
% npm install --save @capacitor-community/admob@next
|
|
51
48
|
```
|
|
52
|
-
|
|
53
|
-
If you use capacitor 5:
|
|
54
|
-
|
|
55
|
-
```
|
|
56
|
-
% npm install --save @capacitor-community/admob@5.0.0
|
|
57
|
-
% npx cap update
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
If you use capacitor 4:
|
|
61
|
-
|
|
62
|
-
```
|
|
63
|
-
% npm install --save @capacitor-community/admob@4.0.0
|
|
64
|
-
% npx cap update
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
capacitor 3:
|
|
68
|
-
|
|
69
|
-
```
|
|
70
|
-
% npm install --save @capacitor-community/admob@3.3.0
|
|
49
|
+
% npm install --save @capacitor-community/admob@6
|
|
71
50
|
% npx cap update
|
|
72
51
|
```
|
|
73
52
|
|
|
@@ -396,7 +375,7 @@ AdMob.addListener(RewardAdPluginEvents.Rewarded, async () => {
|
|
|
396
375
|
### initialize(...)
|
|
397
376
|
|
|
398
377
|
```typescript
|
|
399
|
-
initialize(options?: AdMobInitializationOptions) => Promise<void>
|
|
378
|
+
initialize(options?: AdMobInitializationOptions | undefined) => Promise<void>
|
|
400
379
|
```
|
|
401
380
|
|
|
402
381
|
Initialize AdMob with <a href="#admobinitializationoptions">AdMobInitializationOptions</a>
|
|
@@ -405,6 +384,8 @@ Initialize AdMob with <a href="#admobinitializationoptions">AdMobInitializationO
|
|
|
405
384
|
| ------------- | --------------------------------------------------------------------------------- | -------------------------------------------------------------------- |
|
|
406
385
|
| **`options`** | <code><a href="#admobinitializationoptions">AdMobInitializationOptions</a></code> | <a href="#admobinitializationoptions">AdMobInitializationOptions</a> |
|
|
407
386
|
|
|
387
|
+
**Since:** 1.1.2
|
|
388
|
+
|
|
408
389
|
--------------------
|
|
409
390
|
|
|
410
391
|
|
|
@@ -418,6 +399,8 @@ Confirm requestTrackingAuthorization status (iOS >14)
|
|
|
418
399
|
|
|
419
400
|
**Returns:** <code>Promise<<a href="#trackingauthorizationstatusinterface">TrackingAuthorizationStatusInterface</a>></code>
|
|
420
401
|
|
|
402
|
+
**Since:** 3.1.0
|
|
403
|
+
|
|
421
404
|
--------------------
|
|
422
405
|
|
|
423
406
|
|
|
@@ -430,6 +413,8 @@ requestTrackingAuthorization() => Promise<void>
|
|
|
430
413
|
request requestTrackingAuthorization (iOS >14).
|
|
431
414
|
This is deprecated method. We recommend UMP Consent.
|
|
432
415
|
|
|
416
|
+
**Since:** 5.2.0
|
|
417
|
+
|
|
433
418
|
--------------------
|
|
434
419
|
|
|
435
420
|
|
|
@@ -445,6 +430,8 @@ Report application mute state to AdMob SDK
|
|
|
445
430
|
| ------------- | --------------------------------------------------------------------------- |
|
|
446
431
|
| **`options`** | <code><a href="#applicationmutedoptions">ApplicationMutedOptions</a></code> |
|
|
447
432
|
|
|
433
|
+
**Since:** 4.1.1
|
|
434
|
+
|
|
448
435
|
--------------------
|
|
449
436
|
|
|
450
437
|
|
|
@@ -460,6 +447,8 @@ Report application volume to AdMob SDK
|
|
|
460
447
|
| ------------- | ----------------------------------------------------------------------------- |
|
|
461
448
|
| **`options`** | <code><a href="#applicationvolumeoptions">ApplicationVolumeOptions</a></code> |
|
|
462
449
|
|
|
450
|
+
**Since:** 4.1.1
|
|
451
|
+
|
|
463
452
|
--------------------
|
|
464
453
|
|
|
465
454
|
|
|
@@ -475,6 +464,8 @@ Show a banner Ad
|
|
|
475
464
|
| ------------- | ----------------------------------------------------------- | ---------------------------------- |
|
|
476
465
|
| **`options`** | <code><a href="#banneradoptions">BannerAdOptions</a></code> | <a href="#adoptions">AdOptions</a> |
|
|
477
466
|
|
|
467
|
+
**Since:** 1.1.2
|
|
468
|
+
|
|
478
469
|
--------------------
|
|
479
470
|
|
|
480
471
|
|
|
@@ -486,6 +477,8 @@ hideBanner() => Promise<void>
|
|
|
486
477
|
|
|
487
478
|
Hide the banner, remove it from screen, but can show it later
|
|
488
479
|
|
|
480
|
+
**Since:** 1.1.2
|
|
481
|
+
|
|
489
482
|
--------------------
|
|
490
483
|
|
|
491
484
|
|
|
@@ -497,6 +490,8 @@ resumeBanner() => Promise<void>
|
|
|
497
490
|
|
|
498
491
|
Resume the banner, show it after hide
|
|
499
492
|
|
|
493
|
+
**Since:** 1.1.2
|
|
494
|
+
|
|
500
495
|
--------------------
|
|
501
496
|
|
|
502
497
|
|
|
@@ -508,6 +503,8 @@ removeBanner() => Promise<void>
|
|
|
508
503
|
|
|
509
504
|
Destroy the banner, remove it from screen.
|
|
510
505
|
|
|
506
|
+
**Since:** 1.1.2
|
|
507
|
+
|
|
511
508
|
--------------------
|
|
512
509
|
|
|
513
510
|
|
|
@@ -524,6 +521,8 @@ addListener(eventName: BannerAdPluginEvents.SizeChanged, listenerFunc: (info: Ad
|
|
|
524
521
|
|
|
525
522
|
**Returns:** <code>Promise<<a href="#pluginlistenerhandle">PluginListenerHandle</a>></code>
|
|
526
523
|
|
|
524
|
+
**Since:** 3.0.0
|
|
525
|
+
|
|
527
526
|
--------------------
|
|
528
527
|
|
|
529
528
|
|
|
@@ -542,6 +541,8 @@ Notice: request loaded Banner ad
|
|
|
542
541
|
|
|
543
542
|
**Returns:** <code>Promise<<a href="#pluginlistenerhandle">PluginListenerHandle</a>></code>
|
|
544
543
|
|
|
544
|
+
**Since:** 3.0.0
|
|
545
|
+
|
|
545
546
|
--------------------
|
|
546
547
|
|
|
547
548
|
|
|
@@ -560,6 +561,8 @@ Notice: request failed Banner ad
|
|
|
560
561
|
|
|
561
562
|
**Returns:** <code>Promise<<a href="#pluginlistenerhandle">PluginListenerHandle</a>></code>
|
|
562
563
|
|
|
564
|
+
**Since:** 3.0.0
|
|
565
|
+
|
|
563
566
|
--------------------
|
|
564
567
|
|
|
565
568
|
|
|
@@ -578,6 +581,8 @@ Notice: full-screen banner view will be presented in response to the user clicki
|
|
|
578
581
|
|
|
579
582
|
**Returns:** <code>Promise<<a href="#pluginlistenerhandle">PluginListenerHandle</a>></code>
|
|
580
583
|
|
|
584
|
+
**Since:** 3.0.0
|
|
585
|
+
|
|
581
586
|
--------------------
|
|
582
587
|
|
|
583
588
|
|
|
@@ -596,6 +601,8 @@ Notice: The full-screen banner view will been dismissed.
|
|
|
596
601
|
|
|
597
602
|
**Returns:** <code>Promise<<a href="#pluginlistenerhandle">PluginListenerHandle</a>></code>
|
|
598
603
|
|
|
604
|
+
**Since:** 3.0.0
|
|
605
|
+
|
|
599
606
|
--------------------
|
|
600
607
|
|
|
601
608
|
|
|
@@ -614,13 +621,15 @@ Unimplemented
|
|
|
614
621
|
|
|
615
622
|
**Returns:** <code>Promise<<a href="#pluginlistenerhandle">PluginListenerHandle</a>></code>
|
|
616
623
|
|
|
624
|
+
**Since:** 3.0.0
|
|
625
|
+
|
|
617
626
|
--------------------
|
|
618
627
|
|
|
619
628
|
|
|
620
629
|
### requestConsentInfo(...)
|
|
621
630
|
|
|
622
631
|
```typescript
|
|
623
|
-
requestConsentInfo(options?: AdmobConsentRequestOptions) => Promise<AdmobConsentInfo>
|
|
632
|
+
requestConsentInfo(options?: AdmobConsentRequestOptions | undefined) => Promise<AdmobConsentInfo>
|
|
624
633
|
```
|
|
625
634
|
|
|
626
635
|
Request user consent information
|
|
@@ -631,6 +640,8 @@ Request user consent information
|
|
|
631
640
|
|
|
632
641
|
**Returns:** <code>Promise<<a href="#admobconsentinfo">AdmobConsentInfo</a>></code>
|
|
633
642
|
|
|
643
|
+
**Since:** 5.0.0
|
|
644
|
+
|
|
634
645
|
--------------------
|
|
635
646
|
|
|
636
647
|
|
|
@@ -644,6 +655,8 @@ Shows a google user consent form (rendered from your GDPR message config).
|
|
|
644
655
|
|
|
645
656
|
**Returns:** <code>Promise<<a href="#admobconsentinfo">AdmobConsentInfo</a>></code>
|
|
646
657
|
|
|
658
|
+
**Since:** 5.0.0
|
|
659
|
+
|
|
647
660
|
--------------------
|
|
648
661
|
|
|
649
662
|
|
|
@@ -655,6 +668,8 @@ resetConsentInfo() => Promise<void>
|
|
|
655
668
|
|
|
656
669
|
Resets the UMP SDK state. Call requestConsentInfo function again to allow user modify their consent
|
|
657
670
|
|
|
671
|
+
**Since:** 5.0.0
|
|
672
|
+
|
|
658
673
|
--------------------
|
|
659
674
|
|
|
660
675
|
|
|
@@ -672,6 +687,8 @@ Prepare interstitial banner
|
|
|
672
687
|
|
|
673
688
|
**Returns:** <code>Promise<<a href="#adloadinfo">AdLoadInfo</a>></code>
|
|
674
689
|
|
|
690
|
+
**Since:** 1.1.2
|
|
691
|
+
|
|
675
692
|
--------------------
|
|
676
693
|
|
|
677
694
|
|
|
@@ -683,6 +700,8 @@ showInterstitial() => Promise<void>
|
|
|
683
700
|
|
|
684
701
|
Show interstitial ad when it’s ready
|
|
685
702
|
|
|
703
|
+
**Since:** 1.1.2
|
|
704
|
+
|
|
686
705
|
--------------------
|
|
687
706
|
|
|
688
707
|
|
|
@@ -780,6 +799,8 @@ Prepare a reward video ad
|
|
|
780
799
|
|
|
781
800
|
**Returns:** <code>Promise<<a href="#adloadinfo">AdLoadInfo</a>></code>
|
|
782
801
|
|
|
802
|
+
**Since:** 1.1.2
|
|
803
|
+
|
|
783
804
|
--------------------
|
|
784
805
|
|
|
785
806
|
|
|
@@ -793,6 +814,8 @@ Show a reward video ad
|
|
|
793
814
|
|
|
794
815
|
**Returns:** <code>Promise<<a href="#admobrewarditem">AdMobRewardItem</a>></code>
|
|
795
816
|
|
|
817
|
+
**Since:** 1.1.2
|
|
818
|
+
|
|
796
819
|
--------------------
|
|
797
820
|
|
|
798
821
|
|
|
@@ -906,6 +929,8 @@ Prepare a reward video ad
|
|
|
906
929
|
|
|
907
930
|
**Returns:** <code>Promise<<a href="#adloadinfo">AdLoadInfo</a>></code>
|
|
908
931
|
|
|
932
|
+
**Since:** 1.1.2
|
|
933
|
+
|
|
909
934
|
--------------------
|
|
910
935
|
|
|
911
936
|
|
|
@@ -919,6 +944,8 @@ Show a reward video ad
|
|
|
919
944
|
|
|
920
945
|
**Returns:** <code>Promise<<a href="#admobrewardinterstitialitem">AdMobRewardInterstitialItem</a>></code>
|
|
921
946
|
|
|
947
|
+
**Since:** 1.1.2
|
|
948
|
+
|
|
922
949
|
--------------------
|
|
923
950
|
|
|
924
951
|
|
|
@@ -1023,13 +1050,13 @@ addListener(eventName: RewardInterstitialAdPluginEvents.Showed, listenerFunc: ()
|
|
|
1023
1050
|
|
|
1024
1051
|
#### AdMobInitializationOptions
|
|
1025
1052
|
|
|
1026
|
-
| Prop | Type | Description |
|
|
1027
|
-
| ---------------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
1028
|
-
| **`testingDevices`** | <code>string[]</code> | An Array of devices IDs that will be marked as tested devices if {@link <a href="#admobinitializationoptions">AdMobInitializationOptions.initializeForTesting</a>} is true (Real Ads will be served to Testing devices, but they will not count as 'real'). |
|
|
1029
|
-
| **`initializeForTesting`** | <code>boolean</code> | If set to true, the devices on {@link <a href="#admobinitializationoptions">AdMobInitializationOptions.testingDevices</a>} will be registered to receive test production ads. |
|
|
1030
|
-
| **`tagForChildDirectedTreatment`** | <code>boolean</code> | For purposes of the Children's Online Privacy Protection Act (COPPA), there is a setting called tagForChildDirectedTreatment. |
|
|
1031
|
-
| **`tagForUnderAgeOfConsent`** | <code>boolean</code> | When using this feature, a Tag For Users under the Age of Consent in Europe (TFUA) parameter will be included in all future ad requests. |
|
|
1032
|
-
| **`maxAdContentRating`** | <code><a href="#maxadcontentrating">MaxAdContentRating</a></code> | As an app developer, you can indicate whether you want Google to treat your content as child-directed when you make an ad request. |
|
|
1053
|
+
| Prop | Type | Description | Default | Since |
|
|
1054
|
+
| ---------------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ | ----- |
|
|
1055
|
+
| **`testingDevices`** | <code>string[]</code> | An Array of devices IDs that will be marked as tested devices if {@link <a href="#admobinitializationoptions">AdMobInitializationOptions.initializeForTesting</a>} is true (Real Ads will be served to Testing devices, but they will not count as 'real'). | | 1.2.0 |
|
|
1056
|
+
| **`initializeForTesting`** | <code>boolean</code> | If set to true, the devices on {@link <a href="#admobinitializationoptions">AdMobInitializationOptions.testingDevices</a>} will be registered to receive test production ads. | <code>false</code> | 1.2.0 |
|
|
1057
|
+
| **`tagForChildDirectedTreatment`** | <code>boolean</code> | For purposes of the Children's Online Privacy Protection Act (COPPA), there is a setting called tagForChildDirectedTreatment. | | 3.1.0 |
|
|
1058
|
+
| **`tagForUnderAgeOfConsent`** | <code>boolean</code> | When using this feature, a Tag For Users under the Age of Consent in Europe (TFUA) parameter will be included in all future ad requests. | | 3.1.0 |
|
|
1059
|
+
| **`maxAdContentRating`** | <code><a href="#maxadcontentrating">MaxAdContentRating</a></code> | As an app developer, you can indicate whether you want Google to treat your content as child-directed when you make an ad request. | | 3.1.0 |
|
|
1033
1060
|
|
|
1034
1061
|
|
|
1035
1062
|
#### TrackingAuthorizationStatusInterface
|
|
@@ -1041,26 +1068,26 @@ addListener(eventName: RewardInterstitialAdPluginEvents.Showed, listenerFunc: ()
|
|
|
1041
1068
|
|
|
1042
1069
|
#### ApplicationMutedOptions
|
|
1043
1070
|
|
|
1044
|
-
| Prop | Type | Description |
|
|
1045
|
-
| ----------- | -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
1046
|
-
| **`muted`** | <code>boolean</code> | To inform the SDK that the app volume has been muted. Note: Video ads that are ineligible to be shown with muted audio are not returned for ad requests made, when the app volume is reported as muted or set to a value of 0. This may restrict a subset of the broader video ads pool from serving. |
|
|
1071
|
+
| Prop | Type | Description | Since |
|
|
1072
|
+
| ----------- | -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |
|
|
1073
|
+
| **`muted`** | <code>boolean</code> | To inform the SDK that the app volume has been muted. Note: Video ads that are ineligible to be shown with muted audio are not returned for ad requests made, when the app volume is reported as muted or set to a value of 0. This may restrict a subset of the broader video ads pool from serving. | 4.1.1 |
|
|
1047
1074
|
|
|
1048
1075
|
|
|
1049
1076
|
#### ApplicationVolumeOptions
|
|
1050
1077
|
|
|
1051
|
-
| Prop | Type | Description |
|
|
1052
|
-
| ------------ | ---------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1053
|
-
| **`volume`** | <code>0 \| 1 \| 0.1 \| 0.2 \| 0.3 \| 0.4 \| 0.5 \| 0.6 \| 0.7 \| 0.8 \| 0.9</code> | If your app has its own volume controls (such as custom music or sound effect volumes), disclosing app volume to the Google Mobile Ads SDK allows video ads to respect app volume settings. enable set 0.0 - 1.0, any float allowed. |
|
|
1078
|
+
| Prop | Type | Description | Since |
|
|
1079
|
+
| ------------ | ---------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----- |
|
|
1080
|
+
| **`volume`** | <code>0 \| 1 \| 0.1 \| 0.2 \| 0.3 \| 0.4 \| 0.5 \| 0.6 \| 0.7 \| 0.8 \| 0.9</code> | If your app has its own volume controls (such as custom music or sound effect volumes), disclosing app volume to the Google Mobile Ads SDK allows video ads to respect app volume settings. enable set 0.0 - 1.0, any float allowed. | 4.1.1 |
|
|
1054
1081
|
|
|
1055
1082
|
|
|
1056
1083
|
#### BannerAdOptions
|
|
1057
1084
|
|
|
1058
1085
|
This interface extends <a href="#adoptions">AdOptions</a>
|
|
1059
1086
|
|
|
1060
|
-
| Prop | Type | Description |
|
|
1061
|
-
| -------------- | ------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
|
|
1062
|
-
| **`adSize`** | <code><a href="#banneradsize">BannerAdSize</a></code> | Banner Ad Size, defaults to ADAPTIVE_BANNER. IT can be: ADAPTIVE_BANNER, SMART_BANNER, BANNER, MEDIUM_RECTANGLE, FULL_BANNER, LEADERBOARD |
|
|
1063
|
-
| **`position`** | <code><a href="#banneradposition">BannerAdPosition</a></code> | Set Banner Ad position. TOP_CENTER or CENTER or BOTTOM_CENTER |
|
|
1087
|
+
| Prop | Type | Description | Default | Since |
|
|
1088
|
+
| -------------- | ------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------- | ----- |
|
|
1089
|
+
| **`adSize`** | <code><a href="#banneradsize">BannerAdSize</a></code> | Banner Ad Size, defaults to ADAPTIVE_BANNER. IT can be: ADAPTIVE_BANNER, SMART_BANNER, BANNER, MEDIUM_RECTANGLE, FULL_BANNER, LEADERBOARD | <code>ADAPTIVE_BANNER</code> | 3.0.0 |
|
|
1090
|
+
| **`position`** | <code><a href="#banneradposition">BannerAdPosition</a></code> | Set Banner Ad position. TOP_CENTER or CENTER or BOTTOM_CENTER | <code>TOP_CENTER</code> | 1.1.2 |
|
|
1064
1091
|
|
|
1065
1092
|
|
|
1066
1093
|
#### PluginListenerHandle
|
|
@@ -1093,19 +1120,19 @@ https://developers.google.com/android/reference/com/google/android/gms/ads/AdErr
|
|
|
1093
1120
|
|
|
1094
1121
|
#### AdmobConsentInfo
|
|
1095
1122
|
|
|
1096
|
-
| Prop | Type | Description |
|
|
1097
|
-
| ---------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------- |
|
|
1098
|
-
| **`status`** | <code><a href="#admobconsentstatus">AdmobConsentStatus</a></code> | The consent status of the user. |
|
|
1099
|
-
| **`isConsentFormAvailable`** | <code>boolean</code> | If `true` a consent form is available and vice versa. |
|
|
1123
|
+
| Prop | Type | Description | Since |
|
|
1124
|
+
| ---------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------- | ----- |
|
|
1125
|
+
| **`status`** | <code><a href="#admobconsentstatus">AdmobConsentStatus</a></code> | The consent status of the user. | 5.0.0 |
|
|
1126
|
+
| **`isConsentFormAvailable`** | <code>boolean</code> | If `true` a consent form is available and vice versa. | 5.0.0 |
|
|
1100
1127
|
|
|
1101
1128
|
|
|
1102
1129
|
#### AdmobConsentRequestOptions
|
|
1103
1130
|
|
|
1104
|
-
| Prop | Type | Description |
|
|
1105
|
-
| ----------------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
|
|
1106
|
-
| **`debugGeography`** | <code><a href="#admobconsentdebuggeography">AdmobConsentDebugGeography</a></code> | Sets the debug geography to test the consent locally. |
|
|
1107
|
-
| **`testDeviceIdentifiers`** | <code>string[]</code> | An array of test device IDs to allow. Note: On iOS, the ID may renew if you uninstall and reinstall the app. |
|
|
1108
|
-
| **`tagForUnderAgeOfConsent`** | <code>boolean</code> | Set to `true` to provide the option for the user to accept being shown personalized ads. |
|
|
1131
|
+
| Prop | Type | Description | Default | Since |
|
|
1132
|
+
| ----------------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ------------------ | ----- |
|
|
1133
|
+
| **`debugGeography`** | <code><a href="#admobconsentdebuggeography">AdmobConsentDebugGeography</a></code> | Sets the debug geography to test the consent locally. | | 5.0.0 |
|
|
1134
|
+
| **`testDeviceIdentifiers`** | <code>string[]</code> | An array of test device IDs to allow. Note: On iOS, the ID may renew if you uninstall and reinstall the app. | | 5.0.0 |
|
|
1135
|
+
| **`tagForUnderAgeOfConsent`** | <code>boolean</code> | Set to `true` to provide the option for the user to accept being shown personalized ads. | <code>false</code> | 5.0.0 |
|
|
1109
1136
|
|
|
1110
1137
|
|
|
1111
1138
|
#### AdLoadInfo
|
|
@@ -1117,12 +1144,12 @@ https://developers.google.com/android/reference/com/google/android/gms/ads/AdErr
|
|
|
1117
1144
|
|
|
1118
1145
|
#### AdOptions
|
|
1119
1146
|
|
|
1120
|
-
| Prop | Type | Description |
|
|
1121
|
-
| --------------- | -------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
1122
|
-
| **`adId`** | <code>string</code> | The ad unit ID that you want to request |
|
|
1123
|
-
| **`isTesting`** | <code>boolean</code> | You can use test mode of ad. |
|
|
1124
|
-
| **`margin`** | <code>number</code> | Margin Banner. Default is 0px; If position is BOTTOM_CENTER, margin is be margin-bottom. If position is TOP_CENTER, margin is be margin-top. |
|
|
1125
|
-
| **`npa`** | <code>boolean</code> | The default behavior of the Google Mobile Ads SDK is to serve personalized ads. Set this to true to request Non-Personalized Ads |
|
|
1147
|
+
| Prop | Type | Description | Default | Since |
|
|
1148
|
+
| --------------- | -------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ | ----- |
|
|
1149
|
+
| **`adId`** | <code>string</code> | The ad unit ID that you want to request | | 1.1.2 |
|
|
1150
|
+
| **`isTesting`** | <code>boolean</code> | You can use test mode of ad. | <code>false</code> | 1.1.2 |
|
|
1151
|
+
| **`margin`** | <code>number</code> | Margin Banner. Default is 0px; If position is BOTTOM_CENTER, margin is be margin-bottom. If position is TOP_CENTER, margin is be margin-top. | <code>0</code> | 1.1.2 |
|
|
1152
|
+
| **`npa`** | <code>boolean</code> | The default behavior of the Google Mobile Ads SDK is to serve personalized ads. Set this to true to request Non-Personalized Ads | <code>false</code> | 1.2.0 |
|
|
1126
1153
|
|
|
1127
1154
|
|
|
1128
1155
|
#### RewardAdOptions
|
package/android/build.gradle
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
ext {
|
|
2
2
|
junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
|
|
3
|
-
androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.
|
|
3
|
+
androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.0'
|
|
4
4
|
androidxCoordinatorLayoutVersion = project.hasProperty('androidxCoordinatorLayoutVersion') ? rootProject.ext.androidxCoordinatorLayoutVersion : '1.2.0'
|
|
5
|
-
androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1
|
|
6
|
-
androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.
|
|
5
|
+
androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.2.1'
|
|
6
|
+
androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.6.1'
|
|
7
7
|
playServicesAdsVersion = project.hasProperty('playServicesAdsVersion') ? rootProject.ext.playServicesAdsVersion : '23.0.0'
|
|
8
8
|
androidxCoreKTXVersion = project.hasProperty('androidxCoreKTXVersion') ? rootProject.ext.androidxCoreKTXVersion : '1.13.0'
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
buildscript {
|
|
12
|
-
ext.kotlin_version = project.hasProperty("kotlin_version") ? rootProject.ext.kotlin_version : '1.9.
|
|
12
|
+
ext.kotlin_version = project.hasProperty("kotlin_version") ? rootProject.ext.kotlin_version : '1.9.25'
|
|
13
13
|
repositories {
|
|
14
14
|
google()
|
|
15
15
|
mavenCentral()
|
|
16
16
|
}
|
|
17
17
|
dependencies {
|
|
18
|
-
classpath 'com.android.tools.build:gradle:8.2
|
|
18
|
+
classpath 'com.android.tools.build:gradle:8.7.2'
|
|
19
19
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
|
20
20
|
}
|
|
21
21
|
}
|
|
@@ -25,10 +25,10 @@ apply plugin: 'kotlin-android'
|
|
|
25
25
|
|
|
26
26
|
android {
|
|
27
27
|
namespace "com.getcapacitor.community.admob.admob"
|
|
28
|
-
compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion :
|
|
28
|
+
compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 35
|
|
29
29
|
defaultConfig {
|
|
30
|
-
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion :
|
|
31
|
-
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion :
|
|
30
|
+
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
|
|
31
|
+
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 35
|
|
32
32
|
versionCode 1
|
|
33
33
|
versionName "1.0"
|
|
34
34
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
|
@@ -43,11 +43,11 @@ android {
|
|
|
43
43
|
abortOnError false
|
|
44
44
|
}
|
|
45
45
|
compileOptions {
|
|
46
|
-
sourceCompatibility JavaVersion.
|
|
47
|
-
targetCompatibility JavaVersion.
|
|
46
|
+
sourceCompatibility JavaVersion.VERSION_21
|
|
47
|
+
targetCompatibility JavaVersion.VERSION_21
|
|
48
48
|
}
|
|
49
49
|
kotlinOptions {
|
|
50
|
-
jvmTarget = JavaVersion.
|
|
50
|
+
jvmTarget = JavaVersion.VERSION_21
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
53
|
|