Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] - Support for Checkout customization #4

Open
JonatanSalas opened this issue Jun 19, 2020 · 2 comments
Open

[Feature] - Support for Checkout customization #4

JonatanSalas opened this issue Jun 19, 2020 · 2 comments
Assignees
Labels
enhancement New feature or request platform:android Issues related to Android code platform:ios Issues related to IOS code platform:javascript Issues related to Javascript code priority:high Prioridad alta de la issue

Comments

@JonatanSalas
Copy link
Member

JonatanSalas commented Jun 19, 2020

Motivation

  • Enable users to customize checkout UI colors.
  • Provide an easier way to customize.

Current Limitations

On Android the current API for styling is static, that said, we can't expose to the Javascript module a way to pass custom colors for checkout. We've open an issue on Android PX repository, see issue here.

Draft APIs

We've in mind the following APIs:

Simpler Customization

It matches with the following documentation.

const payment = await MercadoPagoCheckout.createPayment({
    publicKey: Env.MP_PUBLIC_KEY,
    preferenceId: `your_preference_id`,
    themeOptions: { 
        primaryColor: `#your_color`
    }
});

Advanced Customization

It matches with the following documentation.

const payment = await MercadoPagoCheckout.createPayment({
    publicKey: Env.MP_PUBLIC_KEY,
    preferenceId: `your_preference_id`,
    themeOptions: { 
        primaryColor: `#your_color`, 
        highlightBackgroundColor: `#your_color`, 
        navigationBarStyle: {
            backgroundColor: `#your_color`, 
            tintColor: `#your_color`, 
        },
        loadingStyle: {
            backgroundColor: `#your_color`, 
            tintColor: `#your_color`, 
        },
        fontsStyle: {
             default: `your_font_name`,
             light: `your_light_font_name`,
             semiBold: `your_semibold_font_name`
        }
    }
});
@JonatanSalas JonatanSalas added the enhancement New feature or request label Jun 19, 2020
@JonatanSalas JonatanSalas self-assigned this Jun 19, 2020
@JonatanSalas JonatanSalas added platform:android Issues related to Android code platform:ios Issues related to IOS code platform:javascript Issues related to Javascript code labels Jun 19, 2020
@JonatanSalas JonatanSalas changed the title [Feature Request] - Support for Checkout customization [Feature] - Support for Checkout customization Jun 19, 2020
@JonatanSalas JonatanSalas added the priority:high Prioridad alta de la issue label Jun 21, 2020
@LuisGarcia9000
Copy link

HI @JonatanSalas, there is any update about this feature?

@JonatanSalas
Copy link
Member Author

Hi @LuisGarcia9000, for now no because I'm out of time. But if you want to add it, feel free to fork our repo and make us a PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request platform:android Issues related to Android code platform:ios Issues related to IOS code platform:javascript Issues related to Javascript code priority:high Prioridad alta de la issue
Projects
None yet
Development

No branches or pull requests

2 participants