PaymentMethodView

class PaymentMethodView @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0) : AbstractComposeView

The PaymentMethod widget displays similar messaging and informational content as the Callout widget, but is designed specifically to be displayed in checkout UI where a consumer may select Catch as their payment method.

The widget may be placed in a "disabled" state when the cart contains items that cannot be purchased with Catch (e.g. gift cards). The disable state grays out the contents of the widget and provides a small tooltip that explains why Catch cannot be selected.

The PaymentMethod widget makes use of its price, items, and userCohorts properties to calculate rewards the user will earn on the current purchase.

Constructors

Link copied to clipboard
constructor(context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0)

Functions

Link copied to clipboard
open override fun Content()

Properties

Link copied to clipboard

The Catch color CatchColorTheme. If no theme is set, the theme set globally on the Catch object will be used, which defaults to CatchColorTheme.Light.

Link copied to clipboard

Whether or not the widget is in a disabled state.

Link copied to clipboard
var items: List<Item>?

A list of all items included in the order. Used to calculate item-based rewards.

Link copied to clipboard
var price: Int?

The cost in cents that a consumer would pay for the item(s) without redeeming Catch credit.

Link copied to clipboard

Style overrides which can be used to override the widget's default appearance (ex. font size, color, weight, etc.).

Link copied to clipboard

A list of user cohorts that the signed in user qualifies for. Used to calculate cohort-based rewards.

Link copied to clipboard

The PaymentMethod has several variants that allow you to customize what content is rendered in the widget. The PaymentMethodVariant options are: