@onramper/onramper-react-native 1.1.1 → 1.2.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/CHANGELOG.md +36 -0
- package/README.md +2 -0
- package/ios/Frameworks/OnramperSDK.xcframework/Info.plist +5 -5
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/OnramperSDK.framework/Modules/OnramperSDK.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/OnramperSDK.framework/Modules/OnramperSDK.swiftmodule/arm64-apple-ios.swiftinterface +13 -1
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/OnramperSDK.framework/OnramperSDK +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/OnramperSDK.framework/OnramperSDK_OnramperSDK.bundle/PrivacyInfo.xcprivacy +36 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/OnramperSDK.framework/PrivacyInfo.xcprivacy +36 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/dSYMs/OnramperSDK.framework.dSYM/Contents/Resources/DWARF/OnramperSDK +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/dSYMs/OnramperSDK.framework.dSYM/Contents/Resources/Relocations/aarch64/OnramperSDK.yml +2678 -2578
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/Modules/OnramperSDK.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/Modules/OnramperSDK.swiftmodule/arm64-apple-ios-simulator.swiftinterface +13 -1
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/Modules/OnramperSDK.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/Modules/OnramperSDK.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +13 -1
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/OnramperSDK +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/OnramperSDK_OnramperSDK.bundle/PrivacyInfo.xcprivacy +36 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/OnramperSDK.framework/PrivacyInfo.xcprivacy +36 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/dSYMs/OnramperSDK.framework.dSYM/Contents/Resources/DWARF/OnramperSDK +0 -0
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/dSYMs/OnramperSDK.framework.dSYM/Contents/Resources/Relocations/aarch64/OnramperSDK.yml +2678 -2578
- package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64_x86_64-simulator/dSYMs/OnramperSDK.framework.dSYM/Contents/Resources/Relocations/x86_64/OnramperSDK.yml +2645 -2545
- package/ios/HybridOnramperNitro.swift +20 -4
- package/ios/OnramperCheckoutBridge.swift +33 -0
- package/lib/commonjs/OnramperClient.js +12 -2
- package/lib/commonjs/OnramperClient.js.map +1 -1
- package/lib/module/OnramperClient.js +12 -2
- package/lib/module/OnramperClient.js.map +1 -1
- package/lib/typescript/commonjs/src/OnramperClient.d.ts +12 -2
- package/lib/typescript/commonjs/src/OnramperClient.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/index.d.ts +1 -1
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/specs/OnramperNitro.nitro.d.ts +1 -1
- package/lib/typescript/commonjs/src/specs/OnramperNitro.nitro.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/types.d.ts +7 -0
- package/lib/typescript/commonjs/src/types.d.ts.map +1 -1
- package/lib/typescript/module/src/OnramperClient.d.ts +12 -2
- package/lib/typescript/module/src/OnramperClient.d.ts.map +1 -1
- package/lib/typescript/module/src/index.d.ts +1 -1
- package/lib/typescript/module/src/index.d.ts.map +1 -1
- package/lib/typescript/module/src/specs/OnramperNitro.nitro.d.ts +1 -1
- package/lib/typescript/module/src/specs/OnramperNitro.nitro.d.ts.map +1 -1
- package/lib/typescript/module/src/types.d.ts +7 -0
- package/lib/typescript/module/src/types.d.ts.map +1 -1
- package/nitrogen/generated/ios/c++/HybridOnramperNitroSpecSwift.hpp +2 -2
- package/nitrogen/generated/ios/swift/HybridOnramperNitroSpec.swift +1 -1
- package/nitrogen/generated/ios/swift/HybridOnramperNitroSpec_cxx.swift +2 -2
- package/nitrogen/generated/shared/c++/HybridOnramperNitroSpec.hpp +1 -1
- package/package.json +2 -2
- package/src/OnramperClient.ts +17 -1
- package/src/index.ts +1 -0
- package/src/specs/OnramperNitro.nitro.ts +5 -2
- package/src/types.ts +25 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,42 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project are documented in this file.
|
|
4
4
|
|
|
5
|
+
## [1.2.0]
|
|
6
|
+
|
|
7
|
+
Bundles `OnramperSDK@1.2.0`.
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
|
|
11
|
+
- Client-supplied **user-field prefill**. `getCheckoutRequirements()` accepts an optional third argument carrying values you already know about the user, and the OnramperID sign-in and additional-info screens arrive pre-populated instead of blank. New exported type: `OnramperUserPrefill` — `email`, `firstName`, `lastName`, `phoneNumber`, all optional; supply only what you know.
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
const { button, quote } = await client.getCheckoutRequirements(request, style, {
|
|
15
|
+
firstName: 'Ada',
|
|
16
|
+
lastName: 'Lovelace',
|
|
17
|
+
phoneNumber: '+3712345678', // E.164
|
|
18
|
+
});
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Prefill is **best-effort and never blocks sign-in.** If it can't be applied, the login flow opens normally without it. No error surfaces to your app, and there is nothing to handle. Prefill values are never logged at any `logLevel`.
|
|
22
|
+
|
|
23
|
+
A prefilled phone number is always a *candidate*: the user still verifies it, and a number already verified on the account takes precedence.
|
|
24
|
+
|
|
25
|
+
**Supply `email` only when you are confident** it is the address the user will sign in with. It identifies which account the other values belong to, so it is not merely another prefilled value: when it matches the account that signs in, the remaining values may be applied automatically; when it does not match, the whole prefill is dropped — which is strictly worse than omitting `email`, where the values are still offered to the user for confirmation.
|
|
26
|
+
|
|
27
|
+
Prefill is enabled per integration. Talk to your Onramper representative before relying on it — without it enabled, sign-in simply proceeds without prefill.
|
|
28
|
+
|
|
29
|
+
- Both example apps gained a prefill panel (a send/don't-send switch plus editable fields) so the flow can be exercised on device. `email` and `phoneNumber` start blank deliberately.
|
|
30
|
+
|
|
31
|
+
### Changed
|
|
32
|
+
|
|
33
|
+
- `getCheckoutRequirements(request, buttonStyle?)` gains a trailing `prefill?` parameter and is now `getCheckoutRequirements(request, buttonStyle?, prefill?)`. Existing call sites are unaffected; no migration is required. (The Swift SDK places `prefill` before `buttonStyle`, where argument labels keep it non-breaking — JavaScript has no labels, so the wrapper appends it instead.)
|
|
34
|
+
|
|
35
|
+
## [1.1.1]
|
|
36
|
+
Minor version bundling security enhancements from Onramper iOS SDK v1.1.1
|
|
37
|
+
|
|
38
|
+
### Changed (breaking)
|
|
39
|
+
- All clients should upgrade to this version. This version includes a new security paradigm for backend communications that is required.
|
|
40
|
+
|
|
5
41
|
## [1.1.0]
|
|
6
42
|
|
|
7
43
|
Bundles `OnramperSDK@1.1.0`. The SDK is pre-adoption, so breaking changes ship within the 1.x line.
|
package/README.md
CHANGED
|
@@ -58,6 +58,8 @@ return (
|
|
|
58
58
|
|
|
59
59
|
The button renders natively and presents login + payment sheets internally. ToS is rendered inside the button view.
|
|
60
60
|
|
|
61
|
+
Already know the user? Pass a third `prefill` argument (`email`, `firstName`, `lastName`, `phoneNumber` — all optional) to have the OnramperID screens arrive pre-populated. It's best-effort and never blocks sign-in. See [prefilling known user values](docs/GETTING_STARTED.md#prefilling-known-user-values) — note the caveat on `email` before supplying it.
|
|
62
|
+
|
|
61
63
|
## Checkout events
|
|
62
64
|
|
|
63
65
|
The SwiftUI `OnramperCheckoutButton` does not expose external callback hooks; checkout outcomes flow via the module-level event stream:
|
|
@@ -10,18 +10,15 @@
|
|
|
10
10
|
<key>DebugSymbolsPath</key>
|
|
11
11
|
<string>dSYMs</string>
|
|
12
12
|
<key>LibraryIdentifier</key>
|
|
13
|
-
<string>ios-
|
|
13
|
+
<string>ios-arm64</string>
|
|
14
14
|
<key>LibraryPath</key>
|
|
15
15
|
<string>OnramperSDK.framework</string>
|
|
16
16
|
<key>SupportedArchitectures</key>
|
|
17
17
|
<array>
|
|
18
18
|
<string>arm64</string>
|
|
19
|
-
<string>x86_64</string>
|
|
20
19
|
</array>
|
|
21
20
|
<key>SupportedPlatform</key>
|
|
22
21
|
<string>ios</string>
|
|
23
|
-
<key>SupportedPlatformVariant</key>
|
|
24
|
-
<string>simulator</string>
|
|
25
22
|
</dict>
|
|
26
23
|
<dict>
|
|
27
24
|
<key>BinaryPath</key>
|
|
@@ -29,15 +26,18 @@
|
|
|
29
26
|
<key>DebugSymbolsPath</key>
|
|
30
27
|
<string>dSYMs</string>
|
|
31
28
|
<key>LibraryIdentifier</key>
|
|
32
|
-
<string>ios-
|
|
29
|
+
<string>ios-arm64_x86_64-simulator</string>
|
|
33
30
|
<key>LibraryPath</key>
|
|
34
31
|
<string>OnramperSDK.framework</string>
|
|
35
32
|
<key>SupportedArchitectures</key>
|
|
36
33
|
<array>
|
|
37
34
|
<string>arm64</string>
|
|
35
|
+
<string>x86_64</string>
|
|
38
36
|
</array>
|
|
39
37
|
<key>SupportedPlatform</key>
|
|
40
38
|
<string>ios</string>
|
|
39
|
+
<key>SupportedPlatformVariant</key>
|
|
40
|
+
<string>simulator</string>
|
|
41
41
|
</dict>
|
|
42
42
|
</array>
|
|
43
43
|
<key>CFBundlePackageType</key>
|
|
Binary file
|
|
@@ -364,6 +364,16 @@ public struct EncryptedPayload : Swift.Codable, Swift.Sendable, Swift.Equatable
|
|
|
364
364
|
public func encode(to encoder: any Swift.Encoder) throws
|
|
365
365
|
public init(from decoder: any Swift.Decoder) throws
|
|
366
366
|
}
|
|
367
|
+
public struct OnramperUserPrefill : Swift.Sendable, Swift.Equatable {
|
|
368
|
+
public var email: Swift.String?
|
|
369
|
+
public var firstName: Swift.String?
|
|
370
|
+
public var lastName: Swift.String?
|
|
371
|
+
public var phoneNumber: Swift.String?
|
|
372
|
+
#if compiler(>=5.3) && $NonescapableTypes
|
|
373
|
+
public init(email: Swift.String? = nil, firstName: Swift.String? = nil, lastName: Swift.String? = nil, phoneNumber: Swift.String? = nil)
|
|
374
|
+
#endif
|
|
375
|
+
public static func == (a: OnramperSDK.OnramperUserPrefill, b: OnramperSDK.OnramperUserPrefill) -> Swift.Bool
|
|
376
|
+
}
|
|
367
377
|
public struct QuoteResponse : Swift.Codable, Swift.Sendable, Swift.Equatable {
|
|
368
378
|
public let quoteId: Swift.String
|
|
369
379
|
public let ramp: Swift.String
|
|
@@ -450,7 +460,9 @@ public enum RenderType : Swift.String, Swift.Codable, Swift.Sendable {
|
|
|
450
460
|
}
|
|
451
461
|
@_Concurrency.MainActor convenience public init(configuration: OnramperSDK.OnramperConfiguration)
|
|
452
462
|
@_Concurrency.MainActor final public func initialize(sessionId: Swift.String, sessionToken: Swift.String) async throws
|
|
453
|
-
|
|
463
|
+
#if compiler(>=5.3) && $NonescapableTypes
|
|
464
|
+
@_Concurrency.MainActor final public func getCheckoutRequirements(_ request: OnramperSDK.CheckoutIntentRequest, prefill: OnramperSDK.OnramperUserPrefill? = nil, buttonStyle: OnramperSDK.CheckoutButtonStyle = CheckoutButtonStyle()) async throws -> OnramperSDK.CheckoutRequirementsResult
|
|
465
|
+
#endif
|
|
454
466
|
@_Concurrency.MainActor final public func reset() async
|
|
455
467
|
@_Concurrency.MainActor final public func signOut() async
|
|
456
468
|
public typealias ObjectWillChangePublisher = Combine.ObservableObjectPublisher
|
|
Binary file
|
|
@@ -16,6 +16,42 @@
|
|
|
16
16
|
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
17
17
|
<false/>
|
|
18
18
|
</dict>
|
|
19
|
+
<dict>
|
|
20
|
+
<key>NSPrivacyCollectedDataType</key>
|
|
21
|
+
<string>NSPrivacyCollectedDataTypeEmailAddress</string>
|
|
22
|
+
<key>NSPrivacyCollectedDataTypePurposes</key>
|
|
23
|
+
<array>
|
|
24
|
+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
|
|
25
|
+
</array>
|
|
26
|
+
<key>NSPrivacyCollectedDataTypeLinked</key>
|
|
27
|
+
<true/>
|
|
28
|
+
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
29
|
+
<false/>
|
|
30
|
+
</dict>
|
|
31
|
+
<dict>
|
|
32
|
+
<key>NSPrivacyCollectedDataType</key>
|
|
33
|
+
<string>NSPrivacyCollectedDataTypeName</string>
|
|
34
|
+
<key>NSPrivacyCollectedDataTypePurposes</key>
|
|
35
|
+
<array>
|
|
36
|
+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
|
|
37
|
+
</array>
|
|
38
|
+
<key>NSPrivacyCollectedDataTypeLinked</key>
|
|
39
|
+
<true/>
|
|
40
|
+
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
41
|
+
<false/>
|
|
42
|
+
</dict>
|
|
43
|
+
<dict>
|
|
44
|
+
<key>NSPrivacyCollectedDataType</key>
|
|
45
|
+
<string>NSPrivacyCollectedDataTypePhoneNumber</string>
|
|
46
|
+
<key>NSPrivacyCollectedDataTypePurposes</key>
|
|
47
|
+
<array>
|
|
48
|
+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
|
|
49
|
+
</array>
|
|
50
|
+
<key>NSPrivacyCollectedDataTypeLinked</key>
|
|
51
|
+
<true/>
|
|
52
|
+
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
53
|
+
<false/>
|
|
54
|
+
</dict>
|
|
19
55
|
</array>
|
|
20
56
|
<key>NSPrivacyAccessedAPITypes</key>
|
|
21
57
|
<array/>
|
package/ios/Frameworks/OnramperSDK.xcframework/ios-arm64/OnramperSDK.framework/PrivacyInfo.xcprivacy
CHANGED
|
@@ -16,6 +16,42 @@
|
|
|
16
16
|
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
17
17
|
<false/>
|
|
18
18
|
</dict>
|
|
19
|
+
<dict>
|
|
20
|
+
<key>NSPrivacyCollectedDataType</key>
|
|
21
|
+
<string>NSPrivacyCollectedDataTypeEmailAddress</string>
|
|
22
|
+
<key>NSPrivacyCollectedDataTypePurposes</key>
|
|
23
|
+
<array>
|
|
24
|
+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
|
|
25
|
+
</array>
|
|
26
|
+
<key>NSPrivacyCollectedDataTypeLinked</key>
|
|
27
|
+
<true/>
|
|
28
|
+
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
29
|
+
<false/>
|
|
30
|
+
</dict>
|
|
31
|
+
<dict>
|
|
32
|
+
<key>NSPrivacyCollectedDataType</key>
|
|
33
|
+
<string>NSPrivacyCollectedDataTypeName</string>
|
|
34
|
+
<key>NSPrivacyCollectedDataTypePurposes</key>
|
|
35
|
+
<array>
|
|
36
|
+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
|
|
37
|
+
</array>
|
|
38
|
+
<key>NSPrivacyCollectedDataTypeLinked</key>
|
|
39
|
+
<true/>
|
|
40
|
+
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
41
|
+
<false/>
|
|
42
|
+
</dict>
|
|
43
|
+
<dict>
|
|
44
|
+
<key>NSPrivacyCollectedDataType</key>
|
|
45
|
+
<string>NSPrivacyCollectedDataTypePhoneNumber</string>
|
|
46
|
+
<key>NSPrivacyCollectedDataTypePurposes</key>
|
|
47
|
+
<array>
|
|
48
|
+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
|
|
49
|
+
</array>
|
|
50
|
+
<key>NSPrivacyCollectedDataTypeLinked</key>
|
|
51
|
+
<true/>
|
|
52
|
+
<key>NSPrivacyCollectedDataTypeTracking</key>
|
|
53
|
+
<false/>
|
|
54
|
+
</dict>
|
|
19
55
|
</array>
|
|
20
56
|
<key>NSPrivacyAccessedAPITypes</key>
|
|
21
57
|
<array/>
|