Skip to content

CardElement

Card number, expiry and CVC fields for Visa, in a frame on a Pesepay origin. Pay with confirmCardPayment().

export interface CardElement extends PesepayElementBase<CardElementEventMap>
NameTypeDescription
elementType"card"Always "card".

Listen with on(), once() or off(), by event name. Each handler receives the event’s payload.

EventPayloadDescription
changeCardChangeEventThe input changed, with the detected brand.
blurElementBlurEventA field lost focus.
escapeElementEscapeEventThe customer pressed Escape.
focusElementFocusEventA field gained focus.
loaderrorElementLoadErrorEventThe element could not load.
readyElementReadyEventThe element has rendered.

Also has everything PesepayElementBase has.