Skip to content

Commit 26548e5

Browse files
rdlaboCopilot
andauthored
feat(): update to v8 (#457)
* feat(payment): update to v8 * feat(identity): update to v8 * feat(terminal): update to v8 * chore(demo): update to v8 * feat(): update node version target * chore(payment): add peer dependencies * chore(demo): ng update * fmt * chore * feat(identity): remove deprecated event (#458) * feat(identity): remove deprecated event * chore(demo): remove result check * Update packages/identity/android/src/main/java/com/getcapacitor/community/stripe/identity/StripeIdentityPlugin.kt Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * feat: stripe sdk is updated(not has breaking changes) (#459) * feat(terminal): sdk version to 5.1.0 (#460) * chore(): update readme for v8 * chore(demo): re-create android folder * Revert "feat(terminal): sdk version to 5.1.0 (#460)" This reverts commit 5c34e9c. * feat(web): update stripe-pwa-elements to 3.0.0 * fix(identity): remove unused and deprecated event * chore(payment): defineCustomElement changed to be not promise * feat(ios): update how to write package version * chore(demo): update for identity * feat(demo): ios spm is be default --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 2b43099 commit 26548e5

File tree

74 files changed

+2523
-13922
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+2523
-13922
lines changed

.github/workflows/build.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
- uses: actions/checkout@v4
1818
- uses: actions/setup-node@v4
1919
with:
20-
node-version: 20
20+
node-version: 22
2121
- name: Use cached node_modules
2222
uses: actions/cache@v4
2323
with:
@@ -75,7 +75,7 @@ jobs:
7575
- uses: actions/checkout@v4
7676
- uses: actions/setup-node@v4
7777
with:
78-
node-version: 20
78+
node-version: 22
7979
- name: Use cached node_modules
8080
uses: actions/cache@v4
8181
with:
@@ -99,7 +99,7 @@ jobs:
9999
- uses: actions/checkout@v4
100100
- uses: actions/setup-node@v4
101101
with:
102-
node-version: 20
102+
node-version: 22
103103
- name: Use cached node_modules
104104
uses: actions/cache@v4
105105
with:
@@ -124,7 +124,7 @@ jobs:
124124
- uses: actions/checkout@v4
125125
- uses: actions/setup-node@v4
126126
with:
127-
node-version: 20
127+
node-version: 22
128128
- name: Use cached node_modules
129129
uses: actions/cache@v4
130130
with:
@@ -143,7 +143,7 @@ jobs:
143143
- uses: actions/checkout@v3
144144
- uses: actions/setup-node@v3
145145
with:
146-
node-version: 20
146+
node-version: 22
147147
- name: Use cached node_modules
148148
uses: actions/cache@v4
149149
with:
@@ -162,7 +162,7 @@ jobs:
162162
- uses: actions/checkout@v3
163163
- uses: actions/setup-node@v3
164164
with:
165-
node-version: 20
165+
node-version: 22
166166
- name: Use cached node_modules
167167
uses: actions/cache@v4
168168
with:
@@ -181,7 +181,7 @@ jobs:
181181
- uses: actions/checkout@v3
182182
- uses: actions/setup-node@v3
183183
with:
184-
node-version: 20
184+
node-version: 22
185185
- name: Use cached node_modules
186186
uses: actions/cache@v4
187187
with:

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Setup Node.js
2323
uses: actions/setup-node@v4
2424
with:
25-
node-version: 20
25+
node-version: 22
2626
registry-url: 'https://registry.npmjs.org'
2727

2828
- name: Update npm

README.md

Lines changed: 31 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -21,42 +21,25 @@
2121

2222
## Hint
2323

24-
### Using v7, we recommend to remove buildscript from `app/build.gradle`
25-
26-
Good news for users who added a buildscript in v6 to eliminate the `Unable to get provider androidx.startup.InitializationProvider` error, it is no longer needed in Capacitor v7. Please remove the following
27-
28-
```diff
29-
- buildscript {
30-
- ext.kotlin_version = '2.0.+'
31-
- repositories {
32-
- google()
33-
- mavenCentral()
34-
- }
35-
- dependencies {
36-
- classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
37-
- }
38-
- }
39-
- apply plugin: 'kotlin-android'
40-
```
41-
4224
### Versions
4325

44-
Users of Capacitor v6 should use version v6 of the Plugin.
26+
Users of Capacitor v7 should use version v7 of the Plugin.
4527

4628
```bash
47-
% npm install @capacitor-community/stripe@6
48-
% npm install @capacitor-community/stripe-identity@6
49-
% npm install @capacitor-community/stripe-terminal@6
29+
% npm install @capacitor-community/stripe@7
30+
% npm install @capacitor-community/stripe-identity@7
31+
% npm install @capacitor-community/stripe-terminal@7
5032
```
5133

5234
### How to use Stripe Android currently package
5335

5436
Capacitor Android 7's default settings is here:
5537

56-
```
57-
minSdkVersion = 22
58-
compileSdkVersion = 35
59-
targetSdkVersion = 35
38+
```gradle
39+
ext {
40+
minSdkVersion = 24
41+
compileSdkVersion = 36
42+
targetSdkVersion = 36
6043
```
6144

6245
To use the latest Stripe Android, you need to version these up. To use the latest features, follow these steps.
@@ -68,31 +51,32 @@ To use the latest Stripe Android, you need to version these up. To use the lates
6851

6952
```diff
7053
ext {
71-
- minSdkVersion = 23
54+
- minSdkVersio = 24
7255
+ minSdkVersion = 26
73-
compileSdkVersion = 35
74-
targetSdkVersion = 35
75-
androidxActivityVersion = '1.9.2'
76-
androidxAppCompatVersion = '1.7.0'
77-
androidxCoordinatorLayoutVersion = '1.2.0'
78-
androidxCoreVersion = '1.15.0'
79-
androidxFragmentVersion = '1.8.4'
80-
coreSplashScreenVersion = '1.0.1'
81-
androidxWebkitVersion = '1.12.1'
56+
compileSdkVersion = 36
57+
targetSdkVersion = 36
58+
androidxActivityVersion = '1.11.0'
59+
androidxAppCompatVersion = '1.7.1'
60+
androidxCoordinatorLayoutVersion = '1.3.0'
61+
androidxCoreVersion = '1.17.0'
62+
androidxFragmentVersion = '1.8.9'
63+
coreSplashScreenVersion = '1.2.0'
64+
androidxWebkitVersion = '1.14.0'
8265
junitVersion = '4.13.2'
83-
androidxJunitVersion = '1.2.1'
84-
androidxEspressoCoreVersion = '3.6.1'
85-
cordovaAndroidVersion = '10.1.1'
66+
androidxJunitVersion = '1.3.0'
67+
androidxEspressoCoreVersion = '3.7.0'
68+
cordovaAndroidVersion = '14.0.1'
8669

87-
// If you use @capacitor-community/stripe:
88-
+ stripeAndroidVersion = '21.3.+'
70+
// If you will set @capacitor-community/stripe:
71+
+ stripeAndroidVersion = 【Your version】
8972

90-
// If you use @capacitor-community/stripe-identity:
91-
+ identityVersion = '21.3.+'
73+
// If you will set @capacitor-community/stripe-identity:
74+
+ identityVersion = 【Your version】
9275

93-
// If you use @capacitor-community/stripe-terminal:
94-
+ stripeterminalCoreVersion = '4.5.0'
95-
+ stripeterminalTapToPayVersion = '4.5.0'
76+
// If you will set @capacitor-community/stripe-terminal:
77+
+ stripeterminalCoreVersion =【Your version】
78+
+ stripeterminalTapToPayVersion =【Your version】
79+
+ stripeterminalAppOnDevicesVersion =【Your version】
9680
}
9781
```
9882

@@ -163,6 +147,6 @@ Made with [contributors-img](https://contrib.rocks).
163147

164148
```bash
165149
% git clone git@github.com:capacitor-community/stripe.git
166-
% cd packages/payment && npm install && npm run build
150+
% cd npm install && npm run build
167151
% cd demo && npm install && npm run cap && npx cap update
168152
```

demo/angular/android/app/build.gradle

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
apply plugin: 'com.android.application'
22

33
android {
4-
namespace "io.ionic.starter"
5-
compileSdk rootProject.ext.compileSdkVersion
4+
namespace = "com.capacitor.stripe"
5+
compileSdk = rootProject.ext.compileSdkVersion
66
defaultConfig {
7-
applicationId "io.ionic.starter"
7+
applicationId "com.capacitor.stripe"
88
minSdkVersion rootProject.ext.minSdkVersion
99
targetSdkVersion rootProject.ext.targetSdkVersion
1010
versionCode 1
@@ -13,7 +13,7 @@ android {
1313
aaptOptions {
1414
// Files and dirs to omit from the packaged assets dir, modified to accommodate modern web apps.
1515
// Default: https://android.googlesource.com/platform/frameworks/base/+/282e181b58cf72b6ca770dc7ca5f91f135444502/tools/aapt/AaptAssets.cpp#61
16-
ignoreAssetsPattern '!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~'
16+
ignoreAssetsPattern = '!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~'
1717
}
1818
}
1919
buildTypes {
@@ -22,10 +22,6 @@ android {
2222
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
2323
}
2424
}
25-
26-
packagingOptions {
27-
resources.excludes.add("org/bouncycastle/x509/*")
28-
}
2925
}
3026

3127
repositories {

demo/angular/android/app/src/main/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
android:theme="@style/AppTheme">
1717

1818
<activity
19-
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode|navigation"
19+
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode|navigation|density"
2020
android:name=".MainActivity"
2121
android:label="@string/title_activity_main"
2222
android:theme="@style/AppTheme.NoActionBarLaunch"
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
package com.capacitor.stripe;
2+
3+
import com.getcapacitor.BridgeActivity;
4+
5+
public class MainActivity extends BridgeActivity {}

demo/angular/android/app/src/main/java/io/ionic/starter/MainActivity.java

Lines changed: 0 additions & 21 deletions
This file was deleted.

demo/angular/android/app/src/main/res/values/strings.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,13 @@
22
<resources>
33
<string name="app_name">capacitor-stripe</string>
44
<string name="title_activity_main">capacitor-stripe</string>
5-
<string name="package_name">io.ionic.starter</string>
6-
<string name="custom_url_scheme">io.ionic.starter</string>
7-
85
<string name="publishable_key">pk_test_51MmARtKzMYim9cy3tOI5vOdHbai4G26V1AiDJmiE4aiAXc8BaSzh9Z0b0f8Novn0Jyyi8JqNdzLzcI2rUGT4g8ct00gfUVdLuM</string>
96
<bool name="enable_google_pay">true</bool>
107
<string name="country_code">US</string>
118
<string name="merchant_display_name">Widget Store</string>
129
<bool name="google_pay_is_testing">true</bool>
1310
<bool name="google_pay_existing_payment_method_required">false</bool>
1411
<!-- <string name="stripe_account"></string>-->
12+
<string name="package_name">com.capacitor.stripe</string>
13+
<string name="custom_url_scheme">com.capacitor.stripe</string>
1514
</resources>

demo/angular/android/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ buildscript {
66
mavenCentral()
77
}
88
dependencies {
9-
classpath 'com.android.tools.build:gradle:8.7.2'
10-
classpath 'com.google.gms:google-services:4.4.2'
9+
classpath 'com.android.tools.build:gradle:8.13.0'
10+
classpath 'com.google.gms:google-services:4.4.4'
1111

1212
// NOTE: Do not place your application dependencies here; they belong
1313
// in the individual module build.gradle files
181 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)