UNPKG

@bounceapp/react-native-paypal

Version:

React Native wrapper to bridge PayPal iOS and Android SDK

40 lines (39 loc) 932 B
"use strict"; import * as React from "react"; import { Pressable, StyleSheet } from "react-native"; import PaypalLogo from "./PaypalLogo"; import { jsx as _jsx } from "react/jsx-runtime"; const PaypalButton = ({ style, disabled = false, onPress }) => /*#__PURE__*/_jsx(Pressable, { onPress: onPress, disabled: disabled, accessibilityRole: "button", style: ({ pressed }) => [styles.idle, pressed && styles.pressed, disabled && styles.disabled, style], children: !disabled && /*#__PURE__*/_jsx(PaypalLogo, { height: 22, width: 69 }) }); const styles = StyleSheet.create({ idle: { height: 48, width: "100%", justifyContent: "center", alignItems: "center", backgroundColor: "#FFC439", borderRadius: 6 }, pressed: { backgroundColor: "#F2BA37" }, disabled: { backgroundColor: "#E5E7EB" } }); export default PaypalButton; //# sourceMappingURL=PaypalButton.js.map