UNPKG

@adyen/react-native

Version:

Wraps Adyen Checkout Drop-In and Components for iOS and Android for convenient use with React Native

26 lines (24 loc) 926 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ApplePayWrapper = void 0; var _PaymentComponentWrapper = require("../base/PaymentComponentWrapper"); /** Native module interface specific to ApplePay */ /** * Apple Pay wrapper - no additional events beyond inherited ones. * @warning handle() implementation throws an exception as Apple Pay doesn't support action handling. * @todo add express payment events */ class ApplePayWrapper extends _PaymentComponentWrapper.PaymentComponentWrapper { name = 'ApplePay'; isAvailable(paymentMethods, configuration) { return this.nativeModule.isAvailable(paymentMethods, configuration); } handle(_action) { throw new Error(ACTIONS_NOT_SUPPORTED_ERROR); } } exports.ApplePayWrapper = ApplePayWrapper; const ACTIONS_NOT_SUPPORTED_ERROR = 'Apple Pay does not support action handling.'; //# sourceMappingURL=ApplePayWrapper.js.map