Skip to content

Default form styling

Last updated: October 20, 2022

Our default integration is the quickest way to display the forms required to collect payment information, with no customization required.

Localization support for the following languages is built into the default integration:

  • Arabic
  • Dutch
  • English
  • French
  • German
  • Italian
  • Romanian
  • Spanish

You can also add your own localized strings to add support for additional languages.

The payment form with left to right text
The payment form with right to left text

For basic customization, the DefaultPaymentFormStyle and DefaultBillingFormStyle objects expose properties that allow you to change the text and colors displayed on the forms.

1
// Create a new DefaultPaymentFormStyle object
2
var paymentFormStyle = DefaultPaymentFormStyle()
3
4
// Change the payment form's background color
5
paymentFormStyle.backgroundColor = UIColor.darkGray
6
7
// Change the card number field's placeholder value
8
paymentFormStyle.expiryDate.textfield.placeholder = "00 / 00"
9
10
// Change the payment button text
11
paymentFormStyle.payButton.text = "Pay £54.63"
12
13
14
// Create a new DefaultBillingFormStyle object
15
var billingFormStyle = DefaultBillingFormStyle()
16
17
// Change the billing form header's font color
18
billingFormStyle.header.headerLabel.textColor = UIColor.darkGray
19
20
// Change the billing form header text
21
paymentFormStyle.header.headerLabel.text = "Billing info"
22
23
// Wrap the styling in a PaymentStyle wrapper
24
let paymentStyle = PaymentStyle(paymentFormStyle: paymentFormStyle,
25
billingFormStyle: billingFormStyle)

See our example project on GitHub.