@xsolla/xui-input-payment 0.114.0 → 0.115.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/native/index.js +105 -96
- package/native/index.js.map +1 -1
- package/native/index.mjs +105 -96
- package/native/index.mjs.map +1 -1
- package/package.json +4 -4
- package/web/index.js +115 -96
- package/web/index.js.map +1 -1
- package/web/index.mjs +115 -96
- package/web/index.mjs.map +1 -1
package/native/index.js
CHANGED
|
@@ -745,107 +745,116 @@ var InputPayment = (0, import_react2.forwardRef)(
|
|
|
745
745
|
const borderRadius = borderRadiusConfig[size];
|
|
746
746
|
const iconSize = iconSizeConfig[size];
|
|
747
747
|
const focusOutline = focusOutlineConfig[size];
|
|
748
|
-
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
{
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
748
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
749
|
+
Box,
|
|
750
|
+
{
|
|
751
|
+
flexDirection: "column",
|
|
752
|
+
gap: sizeStyles.fieldGap,
|
|
753
|
+
width: "100%",
|
|
754
|
+
testID,
|
|
755
|
+
children: [
|
|
756
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
757
|
+
Box,
|
|
758
|
+
{
|
|
759
|
+
backgroundColor,
|
|
760
|
+
borderColor,
|
|
761
|
+
borderWidth: borderColor !== "transparent" ? 1 : 0,
|
|
762
|
+
borderRadius,
|
|
763
|
+
height: sizeStyles.height,
|
|
764
|
+
paddingVertical: padding.vertical,
|
|
765
|
+
paddingHorizontal: padding.horizontal,
|
|
766
|
+
flexDirection: "row",
|
|
767
|
+
alignItems: "center",
|
|
768
|
+
gap: 10,
|
|
769
|
+
position: "relative",
|
|
770
|
+
style: {
|
|
771
|
+
...outlineColor ? {
|
|
772
|
+
outline: `${focusOutline.width}px solid ${outlineColor}`,
|
|
773
|
+
outlineOffset: `${focusOutline.offset}px`
|
|
774
|
+
} : {}
|
|
775
|
+
},
|
|
776
|
+
hoverStyle: !isDisable && !isFocus && !isError ? {
|
|
777
|
+
backgroundColor: inputColors.bgHover,
|
|
778
|
+
borderColor: inputColors.borderHover
|
|
779
|
+
} : void 0,
|
|
780
|
+
children: [
|
|
781
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
782
|
+
Box,
|
|
783
783
|
{
|
|
784
|
-
|
|
785
|
-
|
|
784
|
+
alignItems: "center",
|
|
785
|
+
justifyContent: "center",
|
|
786
|
+
role: "img",
|
|
787
|
+
"aria-hidden": true,
|
|
788
|
+
children: import_react2.default.isValidElement(icon) ? import_react2.default.cloneElement(
|
|
789
|
+
icon,
|
|
790
|
+
{
|
|
791
|
+
size: iconSize,
|
|
792
|
+
color: iconColor
|
|
793
|
+
}
|
|
794
|
+
) : icon
|
|
786
795
|
}
|
|
787
|
-
)
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
possiblePayments.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
818
|
-
Box,
|
|
819
|
-
{
|
|
820
|
-
alignItems: "center",
|
|
821
|
-
justifyContent: "center",
|
|
822
|
-
"data-testid": "input-payment__card-icons",
|
|
823
|
-
style: { overflow: "hidden" },
|
|
824
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
825
|
-
PaymentIcons,
|
|
796
|
+
),
|
|
797
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Box, { flex: 1, height: "100%", justifyContent: "center", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
798
|
+
InputPrimitive,
|
|
799
|
+
{
|
|
800
|
+
ref: inputRef,
|
|
801
|
+
id: inputId,
|
|
802
|
+
value: passValue,
|
|
803
|
+
name,
|
|
804
|
+
placeholder,
|
|
805
|
+
onChange: handleChange,
|
|
806
|
+
onFocus: handleFocus,
|
|
807
|
+
onBlur: handleBlur,
|
|
808
|
+
onKeyDown: handleKeyDown,
|
|
809
|
+
disabled: isDisable,
|
|
810
|
+
type: "text",
|
|
811
|
+
inputMode: "numeric",
|
|
812
|
+
autoComplete: "off",
|
|
813
|
+
color: textColor,
|
|
814
|
+
fontSize: sizeStyles.fontSize,
|
|
815
|
+
placeholderTextColor: placeholderColor,
|
|
816
|
+
"aria-invalid": isError || void 0,
|
|
817
|
+
"aria-describedby": errorMessage ? errorId : void 0,
|
|
818
|
+
"aria-label": ariaLabel || "Card number",
|
|
819
|
+
"aria-disabled": isDisable || void 0,
|
|
820
|
+
"data-testid": "input-payment__field",
|
|
821
|
+
...rest
|
|
822
|
+
}
|
|
823
|
+
) }),
|
|
824
|
+
possiblePayments.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
825
|
+
Box,
|
|
826
826
|
{
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
827
|
+
alignItems: "center",
|
|
828
|
+
justifyContent: "center",
|
|
829
|
+
"data-testid": "input-payment__card-icons",
|
|
830
|
+
style: { overflow: "hidden" },
|
|
831
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
832
|
+
PaymentIcons,
|
|
833
|
+
{
|
|
834
|
+
possiblePayments,
|
|
835
|
+
maxVisible: maxVisiblePossiblePayments,
|
|
836
|
+
recognizedPayment: displayRecognizedPayment,
|
|
837
|
+
iconHeight: iconSize
|
|
838
|
+
}
|
|
839
|
+
)
|
|
831
840
|
}
|
|
832
841
|
)
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
842
|
+
]
|
|
843
|
+
}
|
|
844
|
+
),
|
|
845
|
+
errorMessage && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
846
|
+
Text,
|
|
847
|
+
{
|
|
848
|
+
id: errorId,
|
|
849
|
+
role: "alert",
|
|
850
|
+
color: theme.colors.content.alert.primary,
|
|
851
|
+
fontSize: sizeStyles.fontSize - 2,
|
|
852
|
+
children: errorMessage
|
|
853
|
+
}
|
|
854
|
+
)
|
|
855
|
+
]
|
|
856
|
+
}
|
|
857
|
+
);
|
|
849
858
|
}
|
|
850
859
|
);
|
|
851
860
|
InputPayment.displayName = "InputPayment";
|
package/native/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.tsx","../../src/InputPayment.tsx","../../../primitives-native/src/Box.tsx","../../../primitives-native/src/Text.tsx","../../../primitives-native/src/Input.tsx"],"sourcesContent":["export * from \"./InputPayment\";\n","import React, {\n useState,\n forwardRef,\n useRef,\n useEffect,\n type InputHTMLAttributes,\n type ReactNode,\n} from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, InputPrimitive } from \"@xsolla/xui-primitives\";\nimport { useDesignSystem, useId, isWeb } from \"@xsolla/xui-core\";\nimport {\n Visa,\n Mastercard,\n Maestro,\n AmericanExpress,\n Dinersclub,\n Discover,\n Jcb,\n Unionpay,\n Aura,\n CartesBancaires,\n Cirrus,\n Dankort,\n Elo,\n Hipercard,\n Mir,\n Naranja,\n Paypal,\n Sodexo,\n Uatp,\n type PaymentIconProps,\n} from \"@xsolla/xui-icons-payment\";\n\n/**\n * Supported payment system keys\n */\nexport type PaymentSystemKey =\n | \"visa\"\n | \"mastercard\"\n | \"amex\"\n | \"diners\"\n | \"maestro\"\n | \"unionpay\"\n | \"discover\"\n | \"jcb\"\n | \"aura\"\n | \"cartesbancaires\"\n | \"cirrus\"\n | \"dankort\"\n | \"elo\"\n | \"hipercard\"\n | \"mir\"\n | \"naranja\"\n | \"paypal\"\n | \"sodexo\"\n | \"uatp\";\n\n/**\n * Default payment systems to display\n */\nconst DEFAULT_POSSIBLE_PAYMENTS: PaymentSystemKey[] = [\n \"mastercard\",\n \"visa\",\n \"maestro\",\n \"diners\",\n \"amex\",\n \"discover\",\n \"jcb\",\n \"unionpay\",\n];\n\nexport interface InputPaymentProps extends Omit<\n InputHTMLAttributes<HTMLInputElement>,\n \"size\" | \"onChange\"\n> {\n /**\n * Property for specifying the value of the control.\n */\n value?: string;\n /**\n * Property to display the icon to the left of the content.\n */\n icon?: ReactNode;\n /**\n * Property for specifying the placeholder of the control.\n */\n placeholder?: string;\n /**\n * Event handler when the value changes (for controlled mode).\n */\n onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;\n /**\n * Event handler when the text changes (alternative to onChange).\n */\n onChangeText?: (text: string) => void;\n /**\n * Property for changing the size of the input.\n */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /**\n * Property for specifying the name of the control.\n */\n name?: string;\n /**\n * Property for disabling the control and highlighting it as an inactive state.\n */\n disabled?: boolean;\n /**\n * Property for displaying an error message and highlighting the control as invalid.\n */\n errorMessage?: string;\n /**\n * Property for displaying an error and highlighting the control as invalid.\n */\n error?: boolean;\n /**\n * Property to specify the possible payment systems displayed on the right.\n */\n possiblePayments?: PaymentSystemKey[];\n /**\n * Property to set the maximum number of visible possible payment systems at the same time on the right side of the input.\n */\n maxVisiblePossiblePayments?: number;\n /**\n * Property to show the recognized payment system (all possible payment systems are hidden and only the current one passed by this prop is displayed).\n */\n recognizedPayment?: PaymentSystemKey;\n /**\n * Callback when card type is auto-detected from the input value.\n */\n onRecognizedPaymentChange?: (payment: PaymentSystemKey | null) => void;\n /**\n * Property to enable automatic payment system detection from input value.\n */\n autoDetect?: boolean;\n /**\n * Unique identifier for the input element. Used for accessibility linking.\n */\n id?: string;\n /**\n * Accessible label for screen readers when no visible label is present.\n */\n \"aria-label\"?: string;\n /**\n * Test identifier for the component.\n */\n testID?: string;\n}\n\n// Map payment system keys to icon components\nconst paymentIconComponents: Record<\n PaymentSystemKey,\n React.FC<PaymentIconProps>\n> = {\n visa: Visa,\n mastercard: Mastercard,\n maestro: Maestro,\n amex: AmericanExpress,\n diners: Dinersclub,\n discover: Discover,\n jcb: Jcb,\n unionpay: Unionpay,\n aura: Aura,\n cartesbancaires: CartesBancaires,\n cirrus: Cirrus,\n dankort: Dankort,\n elo: Elo,\n hipercard: Hipercard,\n mir: Mir,\n naranja: Naranja,\n paypal: Paypal,\n sodexo: Sodexo,\n uatp: Uatp,\n};\n\n/**\n * Detects payment system from card number using BIN ranges.\n * Order matters - more specific patterns should come before general ones.\n */\nconst detectPaymentSystem = (cardNumber: string): PaymentSystemKey | null => {\n const cleanNumber = cardNumber.replace(/\\s/g, \"\");\n\n if (!cleanNumber) return null;\n\n // UATP: starts with 1\n if (/^1/.test(cleanNumber)) return \"uatp\";\n\n // Mir: 2200-2204\n if (/^220[0-4]/.test(cleanNumber)) return \"mir\";\n\n // Amex: 34, 37\n if (/^3[47]/.test(cleanNumber)) return \"amex\";\n\n // Diners Club: 300-305, 36, 38\n if (/^3(?:0[0-5]|[68])/.test(cleanNumber)) return \"diners\";\n\n // JCB: 3528-3589\n if (/^35(?:2[89]|[3-8])/.test(cleanNumber)) return \"jcb\";\n\n // Elo: specific BIN ranges (must check before Visa/Mastercard due to overlapping ranges)\n if (\n /^(401178|401179|431274|438935|451416|457393|457631|457632|504175|506699|5067[0-9]{2}|509[0-9]{3}|627780|636297|636368|650[0-9]{3}|651[0-9]{3}|655[0-9]{3})/.test(\n cleanNumber\n )\n )\n return \"elo\";\n\n // Visa: starts with 4\n if (/^4/.test(cleanNumber)) return \"visa\";\n\n // Hipercard: 606282, 637095, 637568, 637599, 637609, 637612\n if (/^(606282|637095|637568|637599|637609|637612)/.test(cleanNumber))\n return \"hipercard\";\n\n // Aura: 507860\n if (/^507860/.test(cleanNumber)) return \"aura\";\n\n // Dankort: 5019\n if (/^5019/.test(cleanNumber)) return \"dankort\";\n\n // Naranja: 589562\n if (/^589562/.test(cleanNumber)) return \"naranja\";\n\n // Mastercard: 51-55 or 2221-2720\n // For 51-55 range\n if (/^5[1-5]/.test(cleanNumber)) return \"mastercard\";\n // For 2221-2720 range (need 4+ digits for accurate detection)\n if (\n cleanNumber.length >= 4 &&\n /^(?:222[1-9]|22[3-9]\\d|2[3-6]\\d{2}|27[01]\\d|2720)/.test(cleanNumber)\n )\n return \"mastercard\";\n\n // Discover: 6011, 622126-622925, 644-649, 65\n if (/^(?:6011|65|64[4-9])/.test(cleanNumber)) return \"discover\";\n // For 622126-622925 range (need 6+ digits for accurate detection)\n if (\n cleanNumber.length >= 6 &&\n /^(?:6221(?:2[6-9]|[3-9]\\d)|622[2-8]\\d{2}|6229(?:[01]\\d|2[0-5]))/.test(\n cleanNumber\n )\n )\n return \"discover\";\n\n // UnionPay: 62 (but not 622126-622925 which is Discover)\n if (/^62/.test(cleanNumber)) return \"unionpay\";\n\n // Maestro: 50, 56-69 (catch-all for remaining 5x and 6x ranges)\n if (/^(?:5[06-9]|6)/.test(cleanNumber)) return \"maestro\";\n\n return null;\n};\n\n// Card icon dimensions (4:3 aspect ratio)\nconst CARD_GAP = 4;\n\n/**\n * Payment card icons component with sliding animation\n */\nconst PaymentIcons: React.FC<{\n possiblePayments: PaymentSystemKey[];\n maxVisible: number;\n recognizedPayment?: PaymentSystemKey | null;\n iconHeight: number;\n}> = ({ possiblePayments, maxVisible, recognizedPayment, iconHeight }) => {\n const [cyclingIndex, setCyclingIndex] = useState(0);\n const [isTransitioning, setIsTransitioning] = useState(false);\n const [isRecognized, setIsRecognized] = useState(false);\n\n // Scale factor based on size (icons use 4:3 aspect ratio)\n const scaledCardHeight = iconHeight;\n const scaledCardWidth = Math.round(iconHeight * (4 / 3));\n const scaledGap = CARD_GAP;\n\n // Calculate which cards to show in cycling position\n const constantCards = possiblePayments.slice(0, maxVisible - 1);\n const cyclingCards = possiblePayments.slice(maxVisible - 1);\n\n // Handle recognized payment animation\n useEffect(() => {\n if (recognizedPayment) {\n setIsRecognized(true);\n } else {\n // Small delay before showing all cards again\n const timeout = setTimeout(() => {\n setIsRecognized(false);\n }, 50);\n return () => clearTimeout(timeout);\n }\n }, [recognizedPayment]);\n\n // Cycle through remaining cards\n useEffect(() => {\n if (cyclingCards.length <= 1 || recognizedPayment) return;\n\n const interval = setInterval(() => {\n setIsTransitioning(true);\n setTimeout(() => {\n setCyclingIndex((prev) => (prev + 1) % cyclingCards.length);\n setIsTransitioning(false);\n }, 150);\n }, 2000);\n\n return () => clearInterval(interval);\n }, [cyclingCards.length, recognizedPayment]);\n\n // Human-readable labels for payment systems\n const paymentLabels: Record<PaymentSystemKey, string> = {\n mastercard: \"Mastercard\",\n visa: \"Visa\",\n maestro: \"Maestro\",\n diners: \"Diners Club\",\n amex: \"American Express\",\n discover: \"Discover\",\n jcb: \"JCB\",\n unionpay: \"UnionPay\",\n aura: \"Aura\",\n cartesbancaires: \"Cartes Bancaires\",\n cirrus: \"Cirrus\",\n dankort: \"Dankort\",\n elo: \"Elo\",\n hipercard: \"Hipercard\",\n mir: \"Mir\",\n naranja: \"Naranja\",\n paypal: \"PayPal\",\n sodexo: \"Sodexo\",\n uatp: \"UATP\",\n };\n\n // Build aria label from possible payments\n const getAriaLabel = () => {\n if (recognizedPayment) {\n return `Recognized payment: ${paymentLabels[recognizedPayment]}`;\n }\n return `Accepted payment cards: ${possiblePayments\n .map((key) => paymentLabels[key])\n .join(\", \")}`;\n };\n\n // Calculate total width for the container\n const totalVisibleCards = Math.min(possiblePayments.length, maxVisible);\n const containerWidth =\n totalVisibleCards * scaledCardWidth + (totalVisibleCards - 1) * scaledGap;\n\n return (\n <Box\n flexDirection=\"row\"\n alignItems=\"center\"\n role=\"img\"\n aria-label={getAriaLabel()}\n position=\"relative\"\n width={containerWidth}\n height={scaledCardHeight}\n style={{ overflow: \"hidden\" }}\n >\n {/* All constant cards */}\n {constantCards.map((key, index) => {\n const IconComponent = paymentIconComponents[key];\n const isRecognizedCard = recognizedPayment === key;\n\n // Calculate slide offset when recognized\n // Cards should slide to the right, except the recognized one\n let translateX = 0;\n let opacity = 1;\n\n if (isRecognized && recognizedPayment) {\n if (isRecognizedCard) {\n // Move recognized card to the rightmost position\n const targetPosition =\n (totalVisibleCards - 1) * (scaledCardWidth + scaledGap);\n const currentPosition = index * (scaledCardWidth + scaledGap);\n translateX = targetPosition - currentPosition;\n opacity = 1;\n } else {\n // Slide non-recognized cards to the right and fade out\n translateX = containerWidth;\n opacity = 0;\n }\n }\n\n return (\n <Box\n key={key}\n position=\"absolute\"\n left={index * (scaledCardWidth + scaledGap)}\n style={{\n transform: isWeb ? `translateX(${translateX}px)` : undefined,\n opacity,\n ...(isWeb && {\n transition: \"transform 300ms ease-out, opacity 300ms ease-out\",\n }),\n }}\n >\n <IconComponent size={scaledCardHeight} />\n </Box>\n );\n })}\n\n {/* Cycling position */}\n {cyclingCards.length > 0 && (\n <Box\n position=\"absolute\"\n left={(maxVisible - 1) * (scaledCardWidth + scaledGap)}\n width={scaledCardWidth}\n height={scaledCardHeight}\n >\n {cyclingCards.map((key, index) => {\n const IconComponent = paymentIconComponents[key];\n const isCurrentCycling = index === cyclingIndex;\n const isRecognizedCard = recognizedPayment === key;\n\n let translateX = 0;\n let opacity = isCurrentCycling && !isTransitioning ? 1 : 0;\n\n if (isRecognized && recognizedPayment) {\n if (isRecognizedCard) {\n // Keep in place, fully visible\n opacity = 1;\n } else {\n // Slide out to the right\n translateX = containerWidth;\n opacity = 0;\n }\n }\n\n return (\n <Box\n key={key}\n position=\"absolute\"\n top={0}\n left={0}\n style={{\n transform: isWeb ? `translateX(${translateX}px)` : undefined,\n opacity,\n ...(isWeb && {\n transition: isRecognized\n ? \"transform 300ms ease-out, opacity 300ms ease-out\"\n : \"opacity 150ms ease-in-out\",\n }),\n }}\n >\n <IconComponent size={scaledCardHeight} />\n </Box>\n );\n })}\n </Box>\n )}\n </Box>\n );\n};\n\nexport const InputPayment = forwardRef<HTMLInputElement, InputPaymentProps>(\n (\n {\n value,\n icon,\n placeholder = \"Card number\",\n onChange,\n onChangeText,\n onKeyDown,\n size = \"md\",\n name,\n disabled = false,\n errorMessage,\n error,\n possiblePayments = DEFAULT_POSSIBLE_PAYMENTS,\n maxVisiblePossiblePayments = 5,\n recognizedPayment: controlledRecognizedPayment,\n onRecognizedPaymentChange,\n autoDetect = true,\n id: providedId,\n \"aria-label\": ariaLabel,\n testID,\n ...rest\n },\n ref\n ) => {\n const { theme } = useDesignSystem();\n const [internalState, setInternalState] = useState<\"default\" | \"focus\">(\n \"default\"\n );\n const [passValue, setPassValue] = useState(value ?? \"\");\n const [detectedPayment, setDetectedPayment] =\n useState<PaymentSystemKey | null>(null);\n const inputRef = useRef<HTMLInputElement>(null);\n\n // Generate unique IDs for accessibility\n const rawId = useId();\n const safeId = rawId.replace(/:/g, \"\");\n const inputId = providedId || `input-payment-${safeId}`;\n const errorId = `${inputId}-error`;\n\n // Forward ref to input element\n React.useImperativeHandle(\n ref,\n () => inputRef.current as HTMLInputElement,\n []\n );\n\n // Sync passValue with value prop when it changes\n useEffect(() => {\n if (value !== undefined) {\n setPassValue(value);\n }\n }, [value]);\n\n // Auto-detect payment system when value changes\n // Only detect cards that are in the possiblePayments list\n useEffect(() => {\n if (autoDetect && passValue) {\n const detected = detectPaymentSystem(passValue);\n // Only use the detected payment if it's in possiblePayments\n const validDetected =\n detected && possiblePayments.includes(detected) ? detected : null;\n setDetectedPayment(validDetected);\n onRecognizedPaymentChange?.(validDetected);\n } else if (!passValue) {\n setDetectedPayment(null);\n if (autoDetect) {\n onRecognizedPaymentChange?.(null);\n }\n }\n }, [passValue, autoDetect, onRecognizedPaymentChange, possiblePayments]);\n\n const isDisable = disabled;\n const isError = !!(errorMessage || error);\n const isFocus = internalState === \"focus\";\n\n // Determine which payment to display\n const displayRecognizedPayment =\n controlledRecognizedPayment ?? detectedPayment;\n\n // Resolve Config from Theme\n const sizeStyles = theme.sizing.input(size);\n const inputColors = theme.colors.control.input;\n\n const handleFocus = () => {\n if (!isDisable) {\n setInternalState(\"focus\");\n }\n };\n\n const handleBlur = () => {\n if (!isDisable) {\n setInternalState(\"default\");\n }\n };\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n const newValue = e.target.value;\n\n if (onChange) {\n onChange(e);\n }\n if (onChangeText) {\n onChangeText(newValue);\n }\n\n setPassValue(newValue);\n };\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLInputElement>) => {\n if (e.key === \"Escape\") {\n e.currentTarget.blur();\n }\n if (onKeyDown) {\n onKeyDown(e);\n }\n };\n\n // Resolve background and border colors based on state\n let backgroundColor = inputColors.bg;\n let borderColor = inputColors.border;\n let outlineColor: string | undefined;\n\n if (isDisable) {\n backgroundColor = inputColors.bgDisable;\n borderColor = inputColors.borderDisable;\n } else if (isError) {\n outlineColor = theme.colors.border.alert;\n if (isFocus) {\n backgroundColor = theme.colors.control.focus.bg;\n }\n } else if (isFocus) {\n backgroundColor = theme.colors.control.focus.bg;\n outlineColor = theme.colors.border.brand;\n }\n\n const textColor = isDisable ? inputColors.textDisable : inputColors.text;\n const placeholderColor = inputColors.placeholder;\n const iconColor = inputColors.placeholder;\n\n // Padding values from Figma design\n const paddingConfig: Record<\n string,\n { vertical: number; horizontal: number }\n > = {\n xl: { vertical: 12, horizontal: 12 },\n lg: { vertical: 14, horizontal: 12 },\n md: { vertical: 11, horizontal: 12 },\n sm: { vertical: 7, horizontal: 10 },\n xs: { vertical: 7, horizontal: 10 },\n };\n\n // Border radius from Figma design\n const borderRadiusConfig: Record<string, number> = {\n xl: 8,\n lg: 8,\n md: 8,\n sm: 4,\n xs: 4,\n };\n\n // Icon sizes from Figma design\n const iconSizeConfig: Record<string, number> = {\n xl: 18,\n lg: 18,\n md: 18,\n sm: 16,\n xs: 16,\n };\n\n // Focus outline config from Figma design\n const focusOutlineConfig: Record<\n string,\n { width: number; offset: number }\n > = {\n xl: { width: 1, offset: -1 },\n lg: { width: 1, offset: -1 },\n md: { width: 1, offset: -1 },\n sm: { width: 1, offset: -1 },\n xs: { width: 1, offset: -1 },\n };\n\n const padding = paddingConfig[size];\n const borderRadius = borderRadiusConfig[size];\n const iconSize = iconSizeConfig[size];\n const focusOutline = focusOutlineConfig[size];\n\n return (\n <Box flexDirection=\"column\" gap={8} width=\"100%\" testID={testID}>\n <Box\n backgroundColor={backgroundColor}\n borderColor={borderColor}\n borderWidth={borderColor !== \"transparent\" ? 1 : 0}\n borderRadius={borderRadius}\n height={sizeStyles.height}\n paddingVertical={padding.vertical}\n paddingHorizontal={padding.horizontal}\n flexDirection=\"row\"\n alignItems=\"center\"\n gap={10}\n position=\"relative\"\n style={{\n ...(outlineColor\n ? {\n outline: `${focusOutline.width}px solid ${outlineColor}`,\n outlineOffset: `${focusOutline.offset}px`,\n }\n : {}),\n }}\n hoverStyle={\n !isDisable && !isFocus && !isError\n ? {\n backgroundColor: inputColors.bgHover,\n borderColor: inputColors.borderHover,\n }\n : undefined\n }\n >\n {icon && (\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n role=\"img\"\n aria-hidden={true}\n >\n {React.isValidElement(icon)\n ? React.cloneElement(\n icon as React.ReactElement<{\n size?: number;\n color?: string;\n }>,\n {\n size: iconSize,\n color: iconColor,\n }\n )\n : icon}\n </Box>\n )}\n\n <Box flex={1} height=\"100%\" justifyContent=\"center\">\n <InputPrimitive\n ref={inputRef}\n id={inputId}\n value={passValue}\n name={name}\n placeholder={placeholder}\n onChange={handleChange}\n onFocus={handleFocus}\n onBlur={handleBlur}\n onKeyDown={handleKeyDown}\n disabled={isDisable}\n type=\"text\"\n inputMode=\"numeric\"\n autoComplete=\"off\"\n color={textColor}\n fontSize={sizeStyles.fontSize}\n placeholderTextColor={placeholderColor}\n aria-invalid={isError || undefined}\n aria-describedby={errorMessage ? errorId : undefined}\n aria-label={ariaLabel || \"Card number\"}\n aria-disabled={isDisable || undefined}\n data-testid=\"input-payment__field\"\n {...rest}\n />\n </Box>\n\n {possiblePayments.length > 0 && (\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n data-testid=\"input-payment__card-icons\"\n style={{ overflow: \"hidden\" }}\n >\n <PaymentIcons\n possiblePayments={possiblePayments}\n maxVisible={maxVisiblePossiblePayments}\n recognizedPayment={displayRecognizedPayment}\n iconHeight={iconSize}\n />\n </Box>\n )}\n </Box>\n\n {errorMessage && (\n <Text\n id={errorId}\n role=\"alert\"\n color={theme.colors.content.alert.primary}\n fontSize={sizeStyles.fontSize - 2}\n >\n {errorMessage}\n </Text>\n )}\n </Box>\n );\n }\n);\n\nInputPayment.displayName = \"InputPayment\";\n","import React from \"react\";\nimport {\n View,\n Pressable,\n Image,\n ViewStyle,\n ImageStyle,\n DimensionValue,\n AnimatableNumericValue,\n} from \"react-native\";\nimport { BoxProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Box: React.FC<BoxProps> = ({\n children,\n onPress,\n onLayout,\n onMoveShouldSetResponder,\n onResponderGrant,\n onResponderMove,\n onResponderRelease,\n onResponderTerminate,\n backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius,\n borderStyle,\n height,\n padding,\n paddingHorizontal,\n paddingVertical,\n margin,\n marginTop,\n marginBottom,\n marginLeft,\n marginRight,\n flexDirection,\n alignItems,\n justifyContent,\n position,\n top,\n bottom,\n left,\n right,\n width,\n flex,\n overflow,\n zIndex,\n hoverStyle,\n pressStyle,\n style,\n \"data-testid\": dataTestId,\n testID,\n as,\n src,\n alt,\n ...rest\n}) => {\n const getContainerStyle = (pressed?: boolean): ViewStyle => ({\n backgroundColor:\n pressed && pressStyle?.backgroundColor\n ? pressStyle.backgroundColor\n : backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius: borderRadius as AnimatableNumericValue,\n borderStyle: borderStyle as ViewStyle[\"borderStyle\"],\n overflow,\n zIndex,\n height: height as DimensionValue,\n width: width as DimensionValue,\n padding: padding as DimensionValue,\n paddingHorizontal: paddingHorizontal as DimensionValue,\n paddingVertical: paddingVertical as DimensionValue,\n margin: margin as DimensionValue,\n marginTop: marginTop as DimensionValue,\n marginBottom: marginBottom as DimensionValue,\n marginLeft: marginLeft as DimensionValue,\n marginRight: marginRight as DimensionValue,\n flexDirection,\n alignItems,\n justifyContent,\n position: position as ViewStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n flex,\n ...(style as ViewStyle),\n });\n\n const finalTestID = dataTestId || testID;\n\n // Destructure and drop web-only props from rest before passing to RN components\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {\n role,\n tabIndex,\n onKeyDown,\n onKeyUp,\n \"aria-label\": _ariaLabel,\n \"aria-labelledby\": _ariaLabelledBy,\n \"aria-current\": _ariaCurrent,\n \"aria-disabled\": _ariaDisabled,\n \"aria-live\": _ariaLive,\n className,\n \"data-testid\": _dataTestId,\n ...nativeRest\n } = rest as Record<string, unknown>;\n\n // Handle as=\"img\" for React Native\n if (as === \"img\" && src) {\n const imageStyle: ImageStyle = {\n width: width as DimensionValue,\n height: height as DimensionValue,\n borderRadius: borderRadius as number,\n position: position as ImageStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n ...(style as ImageStyle),\n };\n\n return (\n <Image\n source={{ uri: src }}\n style={imageStyle}\n testID={finalTestID}\n resizeMode=\"cover\"\n {...nativeRest}\n />\n );\n }\n\n if (onPress) {\n return (\n <Pressable\n onPress={onPress}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n style={({ pressed }) => getContainerStyle(pressed)}\n testID={finalTestID}\n {...nativeRest}\n >\n {children}\n </Pressable>\n );\n }\n\n return (\n <View\n style={getContainerStyle()}\n testID={finalTestID}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n {...nativeRest}\n >\n {children}\n </View>\n );\n};\n","import React from \"react\";\nimport {\n Text as RNText,\n TextStyle,\n AccessibilityRole,\n StyleSheet,\n} from \"react-native\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\n\nconst roleMap: Record<string, AccessibilityRole> = {\n alert: \"alert\",\n heading: \"header\",\n button: \"button\",\n link: \"link\",\n text: \"text\",\n};\n\nconst parseNumericValue = (\n value: string | number | undefined\n): number | undefined => {\n if (value === undefined) return undefined;\n if (typeof value === \"number\") return value;\n const parsed = parseFloat(value);\n return isNaN(parsed) ? undefined : parsed;\n};\n\nexport const Text: React.FC<TextProps> = ({\n children,\n color,\n fontSize,\n fontWeight,\n fontFamily,\n textAlign,\n lineHeight,\n numberOfLines,\n id,\n role,\n style: styleProp,\n ...props\n}) => {\n let resolvedFontFamily = fontFamily\n ? fontFamily.split(\",\")[0].replace(/['\"]/g, \"\").trim()\n : undefined;\n\n if (\n resolvedFontFamily === \"Pilat Wide\" ||\n resolvedFontFamily === \"Pilat Wide Bold\" ||\n resolvedFontFamily === \"Aktiv Grotesk\"\n ) {\n resolvedFontFamily = undefined;\n }\n\n const incomingStyle = StyleSheet.flatten(styleProp) as TextStyle | undefined;\n\n const baseStyle: TextStyle = {\n color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n fontWeight: fontWeight as TextStyle[\"fontWeight\"],\n fontFamily: resolvedFontFamily,\n textDecorationLine: props.textDecoration as TextStyle[\"textDecorationLine\"],\n textAlign: textAlign ?? incomingStyle?.textAlign,\n lineHeight: parseNumericValue(lineHeight ?? incomingStyle?.lineHeight),\n marginTop: parseNumericValue(\n incomingStyle?.marginTop as number | string | undefined\n ),\n marginBottom: parseNumericValue(\n incomingStyle?.marginBottom as number | string | undefined\n ),\n };\n\n const accessibilityRole = role ? roleMap[role] : undefined;\n\n return (\n <RNText\n style={baseStyle}\n numberOfLines={numberOfLines}\n testID={id}\n accessibilityRole={accessibilityRole}\n >\n {children}\n </RNText>\n );\n};\n","import React, { forwardRef } from \"react\";\nimport { TextInput as RNTextInput } from \"react-native\";\nimport { InputPrimitiveProps } from \"@xsolla/xui-primitives-core\";\n\n// Map web input types to React Native keyboard types\nconst keyboardTypeMap: Record<string, any> = {\n text: \"default\",\n number: \"numeric\",\n email: \"email-address\",\n tel: \"phone-pad\",\n url: \"url\",\n decimal: \"decimal-pad\",\n};\n\n// Map web inputMode to React Native keyboard types\nconst inputModeToKeyboardType: Record<string, any> = {\n none: \"default\",\n text: \"default\",\n decimal: \"decimal-pad\",\n numeric: \"number-pad\",\n tel: \"phone-pad\",\n search: \"default\",\n email: \"email-address\",\n url: \"url\",\n};\n\n// Map web autoComplete to React Native textContentType (iOS)\nconst autoCompleteToTextContentType: Record<string, any> = {\n \"one-time-code\": \"oneTimeCode\",\n email: \"emailAddress\",\n username: \"username\",\n password: \"password\",\n \"new-password\": \"newPassword\",\n tel: \"telephoneNumber\",\n \"postal-code\": \"postalCode\",\n name: \"name\",\n};\n\nexport const InputPrimitive = forwardRef<RNTextInput, InputPrimitiveProps>(\n (\n {\n value,\n placeholder,\n onChange,\n onChangeText,\n onFocus,\n onBlur,\n onKeyDown,\n disabled,\n secureTextEntry,\n style,\n color,\n fontSize,\n placeholderTextColor,\n maxLength,\n type,\n inputMode,\n autoComplete,\n id,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-label\": ariaLabel,\n \"aria-disabled\": ariaDisabled,\n \"data-testid\": dataTestId,\n },\n ref\n ) => {\n const handleChangeText = (text: string) => {\n onChangeText?.(text);\n\n // Create a synthetic event for onChange compatibility\n // Include nativeEvent and no-op methods to prevent runtime errors\n // when consumers expect DOM-like event behavior\n if (onChange) {\n const syntheticEvent = {\n target: { value: text },\n currentTarget: { value: text },\n type: \"change\",\n nativeEvent: { text },\n preventDefault: () => {},\n stopPropagation: () => {},\n isTrusted: false,\n } as unknown as React.ChangeEvent<HTMLInputElement>;\n onChange(syntheticEvent);\n }\n };\n\n // Determine keyboard type - inputMode takes precedence over type\n const keyboardType = inputMode\n ? inputModeToKeyboardType[inputMode] || \"default\"\n : type\n ? keyboardTypeMap[type] || \"default\"\n : \"default\";\n\n // Determine textContentType for iOS autofill\n const textContentType = autoComplete\n ? autoCompleteToTextContentType[autoComplete]\n : undefined;\n\n return (\n <RNTextInput\n ref={ref}\n value={value}\n placeholder={placeholder}\n onChangeText={handleChangeText}\n onFocus={onFocus}\n onBlur={onBlur}\n onKeyPress={(e) => {\n // Map onKeyPress to onKeyDown for cross-platform compatibility\n // Include preventDefault to avoid runtime errors when consumers call it\n if (onKeyDown) {\n onKeyDown({\n key: e.nativeEvent.key,\n preventDefault: () => {},\n } as any);\n }\n }}\n editable={!disabled}\n secureTextEntry={secureTextEntry || type === \"password\"}\n keyboardType={keyboardType}\n textContentType={textContentType}\n style={[\n {\n color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n flex: 1,\n padding: 0,\n textAlign: (style as any)?.textAlign || \"left\",\n },\n style as any,\n ]}\n placeholderTextColor={placeholderTextColor}\n maxLength={maxLength}\n // React Native accessibility props\n testID={dataTestId || id}\n accessibilityLabel={ariaLabel}\n accessibilityHint={ariaDescribedBy}\n accessibilityState={{\n disabled: disabled || ariaDisabled,\n }}\n accessible={true}\n />\n );\n }\n);\n\nInputPrimitive.displayName = \"InputPrimitive\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAOO;;;ACNP,0BAQO;AAmID;AAhIC,IAAM,MAA0B,CAAC;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,eAAe;AAAA,EACf;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,oBAAoB,CAAC,aAAkC;AAAA,IAC3D,iBAC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ACC,IAAI;AAAA,UACJ,MAAK;AAAA,UACL,OAAO,MAAM,OAAO,QAAQ,MAAM;AAAA,UAClC,UAAU,WAAW,WAAW;AAAA,UAE/B;AAAA;AAAA,MACH;AAAA,OAEJ;AAAA,EAEJ;AACF;AAEA,aAAa,cAAc;","names":["import_react","import_react_native","import_jsx_runtime","RNText","import_react_native","import_jsx_runtime","RNTextInput","import_jsx_runtime","React"]}
|
|
1
|
+
{"version":3,"sources":["../../src/index.tsx","../../src/InputPayment.tsx","../../../primitives-native/src/Box.tsx","../../../primitives-native/src/Text.tsx","../../../primitives-native/src/Input.tsx"],"sourcesContent":["export * from \"./InputPayment\";\n","import React, {\n useState,\n forwardRef,\n useRef,\n useEffect,\n type InputHTMLAttributes,\n type ReactNode,\n} from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, InputPrimitive } from \"@xsolla/xui-primitives\";\nimport { useDesignSystem, useId, isWeb } from \"@xsolla/xui-core\";\nimport {\n Visa,\n Mastercard,\n Maestro,\n AmericanExpress,\n Dinersclub,\n Discover,\n Jcb,\n Unionpay,\n Aura,\n CartesBancaires,\n Cirrus,\n Dankort,\n Elo,\n Hipercard,\n Mir,\n Naranja,\n Paypal,\n Sodexo,\n Uatp,\n type PaymentIconProps,\n} from \"@xsolla/xui-icons-payment\";\n\n/**\n * Supported payment system keys\n */\nexport type PaymentSystemKey =\n | \"visa\"\n | \"mastercard\"\n | \"amex\"\n | \"diners\"\n | \"maestro\"\n | \"unionpay\"\n | \"discover\"\n | \"jcb\"\n | \"aura\"\n | \"cartesbancaires\"\n | \"cirrus\"\n | \"dankort\"\n | \"elo\"\n | \"hipercard\"\n | \"mir\"\n | \"naranja\"\n | \"paypal\"\n | \"sodexo\"\n | \"uatp\";\n\n/**\n * Default payment systems to display\n */\nconst DEFAULT_POSSIBLE_PAYMENTS: PaymentSystemKey[] = [\n \"mastercard\",\n \"visa\",\n \"maestro\",\n \"diners\",\n \"amex\",\n \"discover\",\n \"jcb\",\n \"unionpay\",\n];\n\nexport interface InputPaymentProps extends Omit<\n InputHTMLAttributes<HTMLInputElement>,\n \"size\" | \"onChange\"\n> {\n /**\n * Property for specifying the value of the control.\n */\n value?: string;\n /**\n * Property to display the icon to the left of the content.\n */\n icon?: ReactNode;\n /**\n * Property for specifying the placeholder of the control.\n */\n placeholder?: string;\n /**\n * Event handler when the value changes (for controlled mode).\n */\n onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;\n /**\n * Event handler when the text changes (alternative to onChange).\n */\n onChangeText?: (text: string) => void;\n /**\n * Property for changing the size of the input.\n */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /**\n * Property for specifying the name of the control.\n */\n name?: string;\n /**\n * Property for disabling the control and highlighting it as an inactive state.\n */\n disabled?: boolean;\n /**\n * Property for displaying an error message and highlighting the control as invalid.\n */\n errorMessage?: string;\n /**\n * Property for displaying an error and highlighting the control as invalid.\n */\n error?: boolean;\n /**\n * Property to specify the possible payment systems displayed on the right.\n */\n possiblePayments?: PaymentSystemKey[];\n /**\n * Property to set the maximum number of visible possible payment systems at the same time on the right side of the input.\n */\n maxVisiblePossiblePayments?: number;\n /**\n * Property to show the recognized payment system (all possible payment systems are hidden and only the current one passed by this prop is displayed).\n */\n recognizedPayment?: PaymentSystemKey;\n /**\n * Callback when card type is auto-detected from the input value.\n */\n onRecognizedPaymentChange?: (payment: PaymentSystemKey | null) => void;\n /**\n * Property to enable automatic payment system detection from input value.\n */\n autoDetect?: boolean;\n /**\n * Unique identifier for the input element. Used for accessibility linking.\n */\n id?: string;\n /**\n * Accessible label for screen readers when no visible label is present.\n */\n \"aria-label\"?: string;\n /**\n * Test identifier for the component.\n */\n testID?: string;\n}\n\n// Map payment system keys to icon components\nconst paymentIconComponents: Record<\n PaymentSystemKey,\n React.FC<PaymentIconProps>\n> = {\n visa: Visa,\n mastercard: Mastercard,\n maestro: Maestro,\n amex: AmericanExpress,\n diners: Dinersclub,\n discover: Discover,\n jcb: Jcb,\n unionpay: Unionpay,\n aura: Aura,\n cartesbancaires: CartesBancaires,\n cirrus: Cirrus,\n dankort: Dankort,\n elo: Elo,\n hipercard: Hipercard,\n mir: Mir,\n naranja: Naranja,\n paypal: Paypal,\n sodexo: Sodexo,\n uatp: Uatp,\n};\n\n/**\n * Detects payment system from card number using BIN ranges.\n * Order matters - more specific patterns should come before general ones.\n */\nconst detectPaymentSystem = (cardNumber: string): PaymentSystemKey | null => {\n const cleanNumber = cardNumber.replace(/\\s/g, \"\");\n\n if (!cleanNumber) return null;\n\n // UATP: starts with 1\n if (/^1/.test(cleanNumber)) return \"uatp\";\n\n // Mir: 2200-2204\n if (/^220[0-4]/.test(cleanNumber)) return \"mir\";\n\n // Amex: 34, 37\n if (/^3[47]/.test(cleanNumber)) return \"amex\";\n\n // Diners Club: 300-305, 36, 38\n if (/^3(?:0[0-5]|[68])/.test(cleanNumber)) return \"diners\";\n\n // JCB: 3528-3589\n if (/^35(?:2[89]|[3-8])/.test(cleanNumber)) return \"jcb\";\n\n // Elo: specific BIN ranges (must check before Visa/Mastercard due to overlapping ranges)\n if (\n /^(401178|401179|431274|438935|451416|457393|457631|457632|504175|506699|5067[0-9]{2}|509[0-9]{3}|627780|636297|636368|650[0-9]{3}|651[0-9]{3}|655[0-9]{3})/.test(\n cleanNumber\n )\n )\n return \"elo\";\n\n // Visa: starts with 4\n if (/^4/.test(cleanNumber)) return \"visa\";\n\n // Hipercard: 606282, 637095, 637568, 637599, 637609, 637612\n if (/^(606282|637095|637568|637599|637609|637612)/.test(cleanNumber))\n return \"hipercard\";\n\n // Aura: 507860\n if (/^507860/.test(cleanNumber)) return \"aura\";\n\n // Dankort: 5019\n if (/^5019/.test(cleanNumber)) return \"dankort\";\n\n // Naranja: 589562\n if (/^589562/.test(cleanNumber)) return \"naranja\";\n\n // Mastercard: 51-55 or 2221-2720\n // For 51-55 range\n if (/^5[1-5]/.test(cleanNumber)) return \"mastercard\";\n // For 2221-2720 range (need 4+ digits for accurate detection)\n if (\n cleanNumber.length >= 4 &&\n /^(?:222[1-9]|22[3-9]\\d|2[3-6]\\d{2}|27[01]\\d|2720)/.test(cleanNumber)\n )\n return \"mastercard\";\n\n // Discover: 6011, 622126-622925, 644-649, 65\n if (/^(?:6011|65|64[4-9])/.test(cleanNumber)) return \"discover\";\n // For 622126-622925 range (need 6+ digits for accurate detection)\n if (\n cleanNumber.length >= 6 &&\n /^(?:6221(?:2[6-9]|[3-9]\\d)|622[2-8]\\d{2}|6229(?:[01]\\d|2[0-5]))/.test(\n cleanNumber\n )\n )\n return \"discover\";\n\n // UnionPay: 62 (but not 622126-622925 which is Discover)\n if (/^62/.test(cleanNumber)) return \"unionpay\";\n\n // Maestro: 50, 56-69 (catch-all for remaining 5x and 6x ranges)\n if (/^(?:5[06-9]|6)/.test(cleanNumber)) return \"maestro\";\n\n return null;\n};\n\n// Card icon dimensions (4:3 aspect ratio)\nconst CARD_GAP = 4;\n\n/**\n * Payment card icons component with sliding animation\n */\nconst PaymentIcons: React.FC<{\n possiblePayments: PaymentSystemKey[];\n maxVisible: number;\n recognizedPayment?: PaymentSystemKey | null;\n iconHeight: number;\n}> = ({ possiblePayments, maxVisible, recognizedPayment, iconHeight }) => {\n const [cyclingIndex, setCyclingIndex] = useState(0);\n const [isTransitioning, setIsTransitioning] = useState(false);\n const [isRecognized, setIsRecognized] = useState(false);\n\n // Scale factor based on size (icons use 4:3 aspect ratio)\n const scaledCardHeight = iconHeight;\n const scaledCardWidth = Math.round(iconHeight * (4 / 3));\n const scaledGap = CARD_GAP;\n\n // Calculate which cards to show in cycling position\n const constantCards = possiblePayments.slice(0, maxVisible - 1);\n const cyclingCards = possiblePayments.slice(maxVisible - 1);\n\n // Handle recognized payment animation\n useEffect(() => {\n if (recognizedPayment) {\n setIsRecognized(true);\n } else {\n // Small delay before showing all cards again\n const timeout = setTimeout(() => {\n setIsRecognized(false);\n }, 50);\n return () => clearTimeout(timeout);\n }\n }, [recognizedPayment]);\n\n // Cycle through remaining cards\n useEffect(() => {\n if (cyclingCards.length <= 1 || recognizedPayment) return;\n\n const interval = setInterval(() => {\n setIsTransitioning(true);\n setTimeout(() => {\n setCyclingIndex((prev) => (prev + 1) % cyclingCards.length);\n setIsTransitioning(false);\n }, 150);\n }, 2000);\n\n return () => clearInterval(interval);\n }, [cyclingCards.length, recognizedPayment]);\n\n // Human-readable labels for payment systems\n const paymentLabels: Record<PaymentSystemKey, string> = {\n mastercard: \"Mastercard\",\n visa: \"Visa\",\n maestro: \"Maestro\",\n diners: \"Diners Club\",\n amex: \"American Express\",\n discover: \"Discover\",\n jcb: \"JCB\",\n unionpay: \"UnionPay\",\n aura: \"Aura\",\n cartesbancaires: \"Cartes Bancaires\",\n cirrus: \"Cirrus\",\n dankort: \"Dankort\",\n elo: \"Elo\",\n hipercard: \"Hipercard\",\n mir: \"Mir\",\n naranja: \"Naranja\",\n paypal: \"PayPal\",\n sodexo: \"Sodexo\",\n uatp: \"UATP\",\n };\n\n // Build aria label from possible payments\n const getAriaLabel = () => {\n if (recognizedPayment) {\n return `Recognized payment: ${paymentLabels[recognizedPayment]}`;\n }\n return `Accepted payment cards: ${possiblePayments\n .map((key) => paymentLabels[key])\n .join(\", \")}`;\n };\n\n // Calculate total width for the container\n const totalVisibleCards = Math.min(possiblePayments.length, maxVisible);\n const containerWidth =\n totalVisibleCards * scaledCardWidth + (totalVisibleCards - 1) * scaledGap;\n\n return (\n <Box\n flexDirection=\"row\"\n alignItems=\"center\"\n role=\"img\"\n aria-label={getAriaLabel()}\n position=\"relative\"\n width={containerWidth}\n height={scaledCardHeight}\n style={{ overflow: \"hidden\" }}\n >\n {/* All constant cards */}\n {constantCards.map((key, index) => {\n const IconComponent = paymentIconComponents[key];\n const isRecognizedCard = recognizedPayment === key;\n\n // Calculate slide offset when recognized\n // Cards should slide to the right, except the recognized one\n let translateX = 0;\n let opacity = 1;\n\n if (isRecognized && recognizedPayment) {\n if (isRecognizedCard) {\n // Move recognized card to the rightmost position\n const targetPosition =\n (totalVisibleCards - 1) * (scaledCardWidth + scaledGap);\n const currentPosition = index * (scaledCardWidth + scaledGap);\n translateX = targetPosition - currentPosition;\n opacity = 1;\n } else {\n // Slide non-recognized cards to the right and fade out\n translateX = containerWidth;\n opacity = 0;\n }\n }\n\n return (\n <Box\n key={key}\n position=\"absolute\"\n left={index * (scaledCardWidth + scaledGap)}\n style={{\n transform: isWeb ? `translateX(${translateX}px)` : undefined,\n opacity,\n ...(isWeb && {\n transition: \"transform 300ms ease-out, opacity 300ms ease-out\",\n }),\n }}\n >\n <IconComponent size={scaledCardHeight} />\n </Box>\n );\n })}\n\n {/* Cycling position */}\n {cyclingCards.length > 0 && (\n <Box\n position=\"absolute\"\n left={(maxVisible - 1) * (scaledCardWidth + scaledGap)}\n width={scaledCardWidth}\n height={scaledCardHeight}\n >\n {cyclingCards.map((key, index) => {\n const IconComponent = paymentIconComponents[key];\n const isCurrentCycling = index === cyclingIndex;\n const isRecognizedCard = recognizedPayment === key;\n\n let translateX = 0;\n let opacity = isCurrentCycling && !isTransitioning ? 1 : 0;\n\n if (isRecognized && recognizedPayment) {\n if (isRecognizedCard) {\n // Keep in place, fully visible\n opacity = 1;\n } else {\n // Slide out to the right\n translateX = containerWidth;\n opacity = 0;\n }\n }\n\n return (\n <Box\n key={key}\n position=\"absolute\"\n top={0}\n left={0}\n style={{\n transform: isWeb ? `translateX(${translateX}px)` : undefined,\n opacity,\n ...(isWeb && {\n transition: isRecognized\n ? \"transform 300ms ease-out, opacity 300ms ease-out\"\n : \"opacity 150ms ease-in-out\",\n }),\n }}\n >\n <IconComponent size={scaledCardHeight} />\n </Box>\n );\n })}\n </Box>\n )}\n </Box>\n );\n};\n\nexport const InputPayment = forwardRef<HTMLInputElement, InputPaymentProps>(\n (\n {\n value,\n icon,\n placeholder = \"Card number\",\n onChange,\n onChangeText,\n onKeyDown,\n size = \"md\",\n name,\n disabled = false,\n errorMessage,\n error,\n possiblePayments = DEFAULT_POSSIBLE_PAYMENTS,\n maxVisiblePossiblePayments = 5,\n recognizedPayment: controlledRecognizedPayment,\n onRecognizedPaymentChange,\n autoDetect = true,\n id: providedId,\n \"aria-label\": ariaLabel,\n testID,\n ...rest\n },\n ref\n ) => {\n const { theme } = useDesignSystem();\n const [internalState, setInternalState] = useState<\"default\" | \"focus\">(\n \"default\"\n );\n const [passValue, setPassValue] = useState(value ?? \"\");\n const [detectedPayment, setDetectedPayment] =\n useState<PaymentSystemKey | null>(null);\n const inputRef = useRef<HTMLInputElement>(null);\n\n // Generate unique IDs for accessibility\n const rawId = useId();\n const safeId = rawId.replace(/:/g, \"\");\n const inputId = providedId || `input-payment-${safeId}`;\n const errorId = `${inputId}-error`;\n\n // Forward ref to input element\n React.useImperativeHandle(\n ref,\n () => inputRef.current as HTMLInputElement,\n []\n );\n\n // Sync passValue with value prop when it changes\n useEffect(() => {\n if (value !== undefined) {\n setPassValue(value);\n }\n }, [value]);\n\n // Auto-detect payment system when value changes\n // Only detect cards that are in the possiblePayments list\n useEffect(() => {\n if (autoDetect && passValue) {\n const detected = detectPaymentSystem(passValue);\n // Only use the detected payment if it's in possiblePayments\n const validDetected =\n detected && possiblePayments.includes(detected) ? detected : null;\n setDetectedPayment(validDetected);\n onRecognizedPaymentChange?.(validDetected);\n } else if (!passValue) {\n setDetectedPayment(null);\n if (autoDetect) {\n onRecognizedPaymentChange?.(null);\n }\n }\n }, [passValue, autoDetect, onRecognizedPaymentChange, possiblePayments]);\n\n const isDisable = disabled;\n const isError = !!(errorMessage || error);\n const isFocus = internalState === \"focus\";\n\n // Determine which payment to display\n const displayRecognizedPayment =\n controlledRecognizedPayment ?? detectedPayment;\n\n // Resolve Config from Theme\n const sizeStyles = theme.sizing.input(size);\n const inputColors = theme.colors.control.input;\n\n const handleFocus = () => {\n if (!isDisable) {\n setInternalState(\"focus\");\n }\n };\n\n const handleBlur = () => {\n if (!isDisable) {\n setInternalState(\"default\");\n }\n };\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n const newValue = e.target.value;\n\n if (onChange) {\n onChange(e);\n }\n if (onChangeText) {\n onChangeText(newValue);\n }\n\n setPassValue(newValue);\n };\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLInputElement>) => {\n if (e.key === \"Escape\") {\n e.currentTarget.blur();\n }\n if (onKeyDown) {\n onKeyDown(e);\n }\n };\n\n // Resolve background and border colors based on state\n let backgroundColor = inputColors.bg;\n let borderColor = inputColors.border;\n let outlineColor: string | undefined;\n\n if (isDisable) {\n backgroundColor = inputColors.bgDisable;\n borderColor = inputColors.borderDisable;\n } else if (isError) {\n outlineColor = theme.colors.border.alert;\n if (isFocus) {\n backgroundColor = theme.colors.control.focus.bg;\n }\n } else if (isFocus) {\n backgroundColor = theme.colors.control.focus.bg;\n outlineColor = theme.colors.border.brand;\n }\n\n const textColor = isDisable ? inputColors.textDisable : inputColors.text;\n const placeholderColor = inputColors.placeholder;\n const iconColor = inputColors.placeholder;\n\n // Padding values from Figma design\n const paddingConfig: Record<\n string,\n { vertical: number; horizontal: number }\n > = {\n xl: { vertical: 12, horizontal: 12 },\n lg: { vertical: 14, horizontal: 12 },\n md: { vertical: 11, horizontal: 12 },\n sm: { vertical: 7, horizontal: 10 },\n xs: { vertical: 7, horizontal: 10 },\n };\n\n // Border radius from Figma design\n const borderRadiusConfig: Record<string, number> = {\n xl: 8,\n lg: 8,\n md: 8,\n sm: 4,\n xs: 4,\n };\n\n // Icon sizes from Figma design\n const iconSizeConfig: Record<string, number> = {\n xl: 18,\n lg: 18,\n md: 18,\n sm: 16,\n xs: 16,\n };\n\n // Focus outline config from Figma design\n const focusOutlineConfig: Record<\n string,\n { width: number; offset: number }\n > = {\n xl: { width: 1, offset: -1 },\n lg: { width: 1, offset: -1 },\n md: { width: 1, offset: -1 },\n sm: { width: 1, offset: -1 },\n xs: { width: 1, offset: -1 },\n };\n\n const padding = paddingConfig[size];\n const borderRadius = borderRadiusConfig[size];\n const iconSize = iconSizeConfig[size];\n const focusOutline = focusOutlineConfig[size];\n\n return (\n <Box\n flexDirection=\"column\"\n gap={sizeStyles.fieldGap}\n width=\"100%\"\n testID={testID}\n >\n <Box\n backgroundColor={backgroundColor}\n borderColor={borderColor}\n borderWidth={borderColor !== \"transparent\" ? 1 : 0}\n borderRadius={borderRadius}\n height={sizeStyles.height}\n paddingVertical={padding.vertical}\n paddingHorizontal={padding.horizontal}\n flexDirection=\"row\"\n alignItems=\"center\"\n gap={10}\n position=\"relative\"\n style={{\n ...(outlineColor\n ? {\n outline: `${focusOutline.width}px solid ${outlineColor}`,\n outlineOffset: `${focusOutline.offset}px`,\n }\n : {}),\n }}\n hoverStyle={\n !isDisable && !isFocus && !isError\n ? {\n backgroundColor: inputColors.bgHover,\n borderColor: inputColors.borderHover,\n }\n : undefined\n }\n >\n {icon && (\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n role=\"img\"\n aria-hidden={true}\n >\n {React.isValidElement(icon)\n ? React.cloneElement(\n icon as React.ReactElement<{\n size?: number;\n color?: string;\n }>,\n {\n size: iconSize,\n color: iconColor,\n }\n )\n : icon}\n </Box>\n )}\n\n <Box flex={1} height=\"100%\" justifyContent=\"center\">\n <InputPrimitive\n ref={inputRef}\n id={inputId}\n value={passValue}\n name={name}\n placeholder={placeholder}\n onChange={handleChange}\n onFocus={handleFocus}\n onBlur={handleBlur}\n onKeyDown={handleKeyDown}\n disabled={isDisable}\n type=\"text\"\n inputMode=\"numeric\"\n autoComplete=\"off\"\n color={textColor}\n fontSize={sizeStyles.fontSize}\n placeholderTextColor={placeholderColor}\n aria-invalid={isError || undefined}\n aria-describedby={errorMessage ? errorId : undefined}\n aria-label={ariaLabel || \"Card number\"}\n aria-disabled={isDisable || undefined}\n data-testid=\"input-payment__field\"\n {...rest}\n />\n </Box>\n\n {possiblePayments.length > 0 && (\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n data-testid=\"input-payment__card-icons\"\n style={{ overflow: \"hidden\" }}\n >\n <PaymentIcons\n possiblePayments={possiblePayments}\n maxVisible={maxVisiblePossiblePayments}\n recognizedPayment={displayRecognizedPayment}\n iconHeight={iconSize}\n />\n </Box>\n )}\n </Box>\n\n {errorMessage && (\n <Text\n id={errorId}\n role=\"alert\"\n color={theme.colors.content.alert.primary}\n fontSize={sizeStyles.fontSize - 2}\n >\n {errorMessage}\n </Text>\n )}\n </Box>\n );\n }\n);\n\nInputPayment.displayName = \"InputPayment\";\n","import React from \"react\";\nimport {\n View,\n Pressable,\n Image,\n ViewStyle,\n ImageStyle,\n DimensionValue,\n AnimatableNumericValue,\n} from \"react-native\";\nimport { BoxProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Box: React.FC<BoxProps> = ({\n children,\n onPress,\n onLayout,\n onMoveShouldSetResponder,\n onResponderGrant,\n onResponderMove,\n onResponderRelease,\n onResponderTerminate,\n backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius,\n borderStyle,\n height,\n padding,\n paddingHorizontal,\n paddingVertical,\n margin,\n marginTop,\n marginBottom,\n marginLeft,\n marginRight,\n flexDirection,\n alignItems,\n justifyContent,\n position,\n top,\n bottom,\n left,\n right,\n width,\n flex,\n overflow,\n zIndex,\n hoverStyle,\n pressStyle,\n style,\n \"data-testid\": dataTestId,\n testID,\n as,\n src,\n alt,\n ...rest\n}) => {\n const getContainerStyle = (pressed?: boolean): ViewStyle => ({\n backgroundColor:\n pressed && pressStyle?.backgroundColor\n ? pressStyle.backgroundColor\n : backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius: borderRadius as AnimatableNumericValue,\n borderStyle: borderStyle as ViewStyle[\"borderStyle\"],\n overflow,\n zIndex,\n height: height as DimensionValue,\n width: width as DimensionValue,\n padding: padding as DimensionValue,\n paddingHorizontal: paddingHorizontal as DimensionValue,\n paddingVertical: paddingVertical as DimensionValue,\n margin: margin as DimensionValue,\n marginTop: marginTop as DimensionValue,\n marginBottom: marginBottom as DimensionValue,\n marginLeft: marginLeft as DimensionValue,\n marginRight: marginRight as DimensionValue,\n flexDirection,\n alignItems,\n justifyContent,\n position: position as ViewStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n flex,\n ...(style as ViewStyle),\n });\n\n const finalTestID = dataTestId || testID;\n\n // Destructure and drop web-only props from rest before passing to RN components\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {\n role,\n tabIndex,\n onKeyDown,\n onKeyUp,\n \"aria-label\": _ariaLabel,\n \"aria-labelledby\": _ariaLabelledBy,\n \"aria-current\": _ariaCurrent,\n \"aria-disabled\": _ariaDisabled,\n \"aria-live\": _ariaLive,\n className,\n \"data-testid\": _dataTestId,\n ...nativeRest\n } = rest as Record<string, unknown>;\n\n // Handle as=\"img\" for React Native\n if (as === \"img\" && src) {\n const imageStyle: ImageStyle = {\n width: width as DimensionValue,\n height: height as DimensionValue,\n borderRadius: borderRadius as number,\n position: position as ImageStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n ...(style as ImageStyle),\n };\n\n return (\n <Image\n source={{ uri: src }}\n style={imageStyle}\n testID={finalTestID}\n resizeMode=\"cover\"\n {...nativeRest}\n />\n );\n }\n\n if (onPress) {\n return (\n <Pressable\n onPress={onPress}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n style={({ pressed }) => getContainerStyle(pressed)}\n testID={finalTestID}\n {...nativeRest}\n >\n {children}\n </Pressable>\n );\n }\n\n return (\n <View\n style={getContainerStyle()}\n testID={finalTestID}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n {...nativeRest}\n >\n {children}\n </View>\n );\n};\n","import React from \"react\";\nimport {\n Text as RNText,\n TextStyle,\n AccessibilityRole,\n StyleSheet,\n} from \"react-native\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\n\nconst roleMap: Record<string, AccessibilityRole> = {\n alert: \"alert\",\n heading: \"header\",\n button: \"button\",\n link: \"link\",\n text: \"text\",\n};\n\nconst parseNumericValue = (\n value: string | number | undefined\n): number | undefined => {\n if (value === undefined) return undefined;\n if (typeof value === \"number\") return value;\n const parsed = parseFloat(value);\n return isNaN(parsed) ? undefined : parsed;\n};\n\nexport const Text: React.FC<TextProps> = ({\n children,\n color,\n fontSize,\n fontWeight,\n fontFamily,\n textAlign,\n lineHeight,\n numberOfLines,\n id,\n role,\n style: styleProp,\n ...props\n}) => {\n let resolvedFontFamily = fontFamily\n ? fontFamily.split(\",\")[0].replace(/['\"]/g, \"\").trim()\n : undefined;\n\n if (\n resolvedFontFamily === \"Pilat Wide\" ||\n resolvedFontFamily === \"Pilat Wide Bold\" ||\n resolvedFontFamily === \"Aktiv Grotesk\"\n ) {\n resolvedFontFamily = undefined;\n }\n\n const incomingStyle = StyleSheet.flatten(styleProp) as TextStyle | undefined;\n\n const baseStyle: TextStyle = {\n color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n fontWeight: fontWeight as TextStyle[\"fontWeight\"],\n fontFamily: resolvedFontFamily,\n textDecorationLine: props.textDecoration as TextStyle[\"textDecorationLine\"],\n textAlign: textAlign ?? incomingStyle?.textAlign,\n lineHeight: parseNumericValue(lineHeight ?? incomingStyle?.lineHeight),\n marginTop: parseNumericValue(\n incomingStyle?.marginTop as number | string | undefined\n ),\n marginBottom: parseNumericValue(\n incomingStyle?.marginBottom as number | string | undefined\n ),\n };\n\n const accessibilityRole = role ? roleMap[role] : undefined;\n\n return (\n <RNText\n style={baseStyle}\n numberOfLines={numberOfLines}\n testID={id}\n accessibilityRole={accessibilityRole}\n >\n {children}\n </RNText>\n );\n};\n","import React, { forwardRef } from \"react\";\nimport { TextInput as RNTextInput } from \"react-native\";\nimport { InputPrimitiveProps } from \"@xsolla/xui-primitives-core\";\n\n// Map web input types to React Native keyboard types\nconst keyboardTypeMap: Record<string, any> = {\n text: \"default\",\n number: \"numeric\",\n email: \"email-address\",\n tel: \"phone-pad\",\n url: \"url\",\n decimal: \"decimal-pad\",\n};\n\n// Map web inputMode to React Native keyboard types\nconst inputModeToKeyboardType: Record<string, any> = {\n none: \"default\",\n text: \"default\",\n decimal: \"decimal-pad\",\n numeric: \"number-pad\",\n tel: \"phone-pad\",\n search: \"default\",\n email: \"email-address\",\n url: \"url\",\n};\n\n// Map web autoComplete to React Native textContentType (iOS)\nconst autoCompleteToTextContentType: Record<string, any> = {\n \"one-time-code\": \"oneTimeCode\",\n email: \"emailAddress\",\n username: \"username\",\n password: \"password\",\n \"new-password\": \"newPassword\",\n tel: \"telephoneNumber\",\n \"postal-code\": \"postalCode\",\n name: \"name\",\n};\n\nexport const InputPrimitive = forwardRef<RNTextInput, InputPrimitiveProps>(\n (\n {\n value,\n placeholder,\n onChange,\n onChangeText,\n onFocus,\n onBlur,\n onKeyDown,\n disabled,\n secureTextEntry,\n style,\n color,\n fontSize,\n placeholderTextColor,\n maxLength,\n type,\n inputMode,\n autoComplete,\n id,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-label\": ariaLabel,\n \"aria-disabled\": ariaDisabled,\n \"data-testid\": dataTestId,\n },\n ref\n ) => {\n const handleChangeText = (text: string) => {\n onChangeText?.(text);\n\n // Create a synthetic event for onChange compatibility\n // Include nativeEvent and no-op methods to prevent runtime errors\n // when consumers expect DOM-like event behavior\n if (onChange) {\n const syntheticEvent = {\n target: { value: text },\n currentTarget: { value: text },\n type: \"change\",\n nativeEvent: { text },\n preventDefault: () => {},\n stopPropagation: () => {},\n isTrusted: false,\n } as unknown as React.ChangeEvent<HTMLInputElement>;\n onChange(syntheticEvent);\n }\n };\n\n // Determine keyboard type - inputMode takes precedence over type\n const keyboardType = inputMode\n ? inputModeToKeyboardType[inputMode] || \"default\"\n : type\n ? keyboardTypeMap[type] || \"default\"\n : \"default\";\n\n // Determine textContentType for iOS autofill\n const textContentType = autoComplete\n ? autoCompleteToTextContentType[autoComplete]\n : undefined;\n\n return (\n <RNTextInput\n ref={ref}\n value={value}\n placeholder={placeholder}\n onChangeText={handleChangeText}\n onFocus={onFocus}\n onBlur={onBlur}\n onKeyPress={(e) => {\n // Map onKeyPress to onKeyDown for cross-platform compatibility\n // Include preventDefault to avoid runtime errors when consumers call it\n if (onKeyDown) {\n onKeyDown({\n key: e.nativeEvent.key,\n preventDefault: () => {},\n } as any);\n }\n }}\n editable={!disabled}\n secureTextEntry={secureTextEntry || type === \"password\"}\n keyboardType={keyboardType}\n textContentType={textContentType}\n style={[\n {\n color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n flex: 1,\n padding: 0,\n textAlign: (style as any)?.textAlign || \"left\",\n },\n style as any,\n ]}\n placeholderTextColor={placeholderTextColor}\n maxLength={maxLength}\n // React Native accessibility props\n testID={dataTestId || id}\n accessibilityLabel={ariaLabel}\n accessibilityHint={ariaDescribedBy}\n accessibilityState={{\n disabled: disabled || ariaDisabled,\n }}\n accessible={true}\n />\n );\n }\n);\n\nInputPrimitive.displayName = \"InputPrimitive\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAOO;;;ACNP,0BAQO;AAmID;AAhIC,IAAM,MAA0B,CAAC;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA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oBACrB,sBAAsB;AAAA,oBACtB,gBAAc,WAAW;AAAA,oBACzB,oBAAkB,eAAe,UAAU;AAAA,oBAC3C,cAAY,aAAa;AAAA,oBACzB,iBAAe,aAAa;AAAA,oBAC5B,eAAY;AAAA,oBACX,GAAG;AAAA;AAAA,gBACN,GACF;AAAA,gBAEC,iBAAiB,SAAS,KACzB;AAAA,kBAAC;AAAA;AAAA,oBACC,YAAW;AAAA,oBACX,gBAAe;AAAA,oBACf,eAAY;AAAA,oBACZ,OAAO,EAAE,UAAU,SAAS;AAAA,oBAE5B;AAAA,sBAAC;AAAA;AAAA,wBACC;AAAA,wBACA,YAAY;AAAA,wBACZ,mBAAmB;AAAA,wBACnB,YAAY;AAAA;AAAA,oBACd;AAAA;AAAA,gBACF;AAAA;AAAA;AAAA,UAEJ;AAAA,UAEC,gBACC;AAAA,YAAC;AAAA;AAAA,cACC,IAAI;AAAA,cACJ,MAAK;AAAA,cACL,OAAO,MAAM,OAAO,QAAQ,MAAM;AAAA,cAClC,UAAU,WAAW,WAAW;AAAA,cAE/B;AAAA;AAAA,UACH;AAAA;AAAA;AAAA,IAEJ;AAAA,EAEJ;AACF;AAEA,aAAa,cAAc;","names":["import_react","import_react_native","import_jsx_runtime","RNText","import_react_native","import_jsx_runtime","RNTextInput","import_jsx_runtime","React"]}
|