Conversation
🦋 Changeset detectedLatest commit: b13cdcb The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
| }, | ||
| ], | ||
| paymentMethods: { | ||
| card: { |
fsantelys-godaddy
left a comment
There was a problem hiding this comment.
Tested while on a call with Carlos. Left a comment
| case PaymentMethodType.OFFLINE: | ||
| return t.payment.methods.offline; | ||
| case PaymentMethodType.MERCADOPAGO: | ||
| return 'MercadoPago'; |
There was a problem hiding this comment.
we should add translations to all of our files even if they are '' incase anyone needs to override them for any reason.
| case PaymentMethodType.OFFLINE: | ||
| return t.payment.descriptions?.offline; | ||
| case PaymentMethodType.MERCADOPAGO: | ||
| return undefined; |
There was a problem hiding this comment.
we should add translations to all of our files even if they are '' incase anyone needs to override them for any reason.
| [PaymentMethodType.MERCADOPAGO]: { | ||
| [PaymentProvider.MERCADOPAGO]: { | ||
| form: 'MercadoPagoCreditCardForm', | ||
| button: 'MercadoPagoCreditCardCheckoutButton', |
There was a problem hiding this comment.
Don't have to include a button component here if it's not used. That being said I think we should perhaps try and see what this form looks like as a the button instead of the form since we typically put all of our payment buttons at the bottom of checkout. So you'd still select the Mercado Pago radio button but no form would appear in the accordion but it would below instead.
| }, []); | ||
|
|
||
| return ( | ||
| <MercadoPagoContext.Provider |
There was a problem hiding this comment.
I don't think we need a provider. All of this can be done in the meracopago component. We utilize the providers to share state between the payment forms and payment buttons but in this case there will only ever be one as far as I can tell.
| @@ -0,0 +1,226 @@ | |||
| import { useCallback, useEffect, useLayoutEffect, useRef, useState } from 'react'; | |||
There was a problem hiding this comment.
Can you move this file into payment-methods/mercadopago to keep it separated as a different method.
| @@ -0,0 +1,5 @@ | |||
| export function MercadoPagoCreditCardCheckoutButton() { | |||
There was a problem hiding this comment.
I think the form should be a part of this instead of payment-methods; but if decided that's not the way, this file is not needed.
| @@ -23,11005 +23,11043 @@ | |||
| * ``` | |||
| */ | |||
| const introspection = { | |||
| name: 'checkout-api', | |||
There was a problem hiding this comment.
run pnpm lint:fix in packages/react
Summary
This branch introduces MercadoPago improvements: event tracking, rendering stability adjustments, and a fixed dummy email for the Brick initialization.
Changeset
Test Plan
Configure your store with MercadoPago
Set your store to Brasil and use this test account
BR:
"id": 1309558710,
"nickname": "TEST_USER_1309558710",
"password": "b3OJ26sZZU",
Run nextjs project setting the right .env variables