"use strict";

import { StyleSheet, View } from "react-native";
import { IOColors, hexToRgba } from "../../core";

/* Logos */
import LogoPaymentCardBancomatPay from "./svg/LogoPaymentCardBancomatPay";
import LogoPaymentCardPayPal from "./svg/LogoPaymentCardPayPal";
import { jsx as _jsx } from "react/jsx-runtime";
export const IOPaymentCardLogos = {
  payPal: LogoPaymentCardPayPal,
  bancomatPay: LogoPaymentCardBancomatPay
};
const preserveAspectRatioValues = {
  start: "xMinYMin meet",
  center: "xMidYMid meet",
  end: "xMaxYMax meet"
};
const styles = StyleSheet.create({
  debugMode: {
    backgroundColor: hexToRgba(IOColors["error-500"], 0.2)
  }
});
const LogoPaymentCard = ({
  name,
  width = "100%",
  height = 32,
  align = "center",
  accessibilityLabel,
  testID,
  debugMode = false,
  ...props
}) => {
  const LogoElement = IOPaymentCardLogos[name];
  return /*#__PURE__*/_jsx(View, {
    accessible: true,
    accessibilityLabel: accessibilityLabel,
    style: [{
      width,
      height
    }, debugMode && styles.debugMode],
    testID: testID,
    children: /*#__PURE__*/_jsx(LogoElement, {
      preserveAspectRatio: preserveAspectRatioValues[align],
      ...props
    })
  });
};
export default LogoPaymentCard;
//# sourceMappingURL=LogoPaymentCard.js.map