PrimerPayPalScope manages the PayPal payment flow including redirect handling.
Declaration
Properties
| Property | Type | Description |
|---|---|---|
state | AsyncStream<PrimerPayPalState> | Stream of PayPal state changes |
presentationContext | PresentationContext | .direct or .fromPaymentSelection |
dismissalMechanism | [DismissalMechanism] | Supported dismissal methods |
Customization
| Property | Type | Description |
|---|---|---|
screen | PayPalScreenComponent? | Full screen replacement. Signature: (any PrimerPayPalScope) -> any View |
payButton | PayPalButtonComponent? | Custom pay button. Signature: (any PrimerPayPalScope) -> any View |
submitButtonText | String? | Submit button label |
Methods
| Method | Description |
|---|---|
start() | Begin the PayPal flow |
submit() | Submit the payment |
onBack() | Navigate back |
cancel() | Cancel the PayPal flow |
PrimerPayPalState
| Property | Type | Description |
|---|---|---|
status | Status | Current payment status |
paymentMethod | CheckoutPaymentMethod? | PayPal payment method details |
surchargeAmount | String? | Formatted surcharge amount |
See also
Scopes overview
All available scopes