Skip to content

Commit

Permalink
fix: phone country code comments addressed
Browse files Browse the repository at this point in the history
  • Loading branch information
Pritish Budhiraja committed Apr 5, 2024
1 parent e1ad9aa commit 1ca3bc4
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/Components/PaymentField.res
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ let make = (
setValue={setValueDropDown->Option.getOr(_ => ())}
fieldName={dropDownFieldName->Option.getOr(fieldName)}
options={dropDownOptions->Option.getOr([])}
width="!w-1/3 mr-2"
width="w-1/3 mr-2"
/>
</RenderIf>
<RenderIf condition={fieldName->String.length > 0 && config.appearance.labels == Above}>
Expand Down
6 changes: 1 addition & 5 deletions src/Components/PhoneNumberPaymentInput.res
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,8 @@ let make = () => {
->Array.get(0)
->Option.getOr(
{
"country_code": "",
"phone_number_code": "",
"validation_regex": "",
"format_example": "",
"format_regex": "",
}->toJson,
}->Identity.anyTypeToJson,
)
->getDictFromJson
->getString("phone_number_code", "")
Expand Down
2 changes: 1 addition & 1 deletion src/PaymentElement.res
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ let make = (
let checkoutEle = {
<ErrorBoundary key={selectedOption}>
{switch selectedOption->PaymentModeType.paymentMode {
| Card => <CardPayment cardProps expiryProps cvcProps paymentType list />
| Card => <PhoneNumberPaymentInput />
| Klarna =>
<SessionPaymentWrapper type_=Others>
{switch klarnaTokenObj {
Expand Down

0 comments on commit 1ca3bc4

Please sign in to comment.