Session
setFocusStyle()
setFocusStyle()
Sets the styling for the hosted field to the supplied styling attributes when focus on the hosted field in the iFrame is gained.
Usage Copied to clipboard
PaymentSession.setFocusStyle([hostedFieldsRole], styles)
Example Copied to clipboard
PaymentSession.setFocusStyle(["cardNumber","securityCode"], { borderColor: 'red', borderWidth: '3px' });
Arguments Copied to clipboard
hostedFieldsRole
Copied to clipboard
Array
An array of field roles for the hosted card fields, to be styled when the focus is gained. Valid values for array of field roles:
cardNumber
securityCode
styles
Copied to clipboard
Object
An object containing JavaScript CSS properties.
Return Value Copied to clipboard
None