@paypal/checkout-components
Advanced tools
Comparing version 5.0.336 to 5.0.337
{ | ||
"name": "@paypal/checkout-components", | ||
"version": "5.0.336", | ||
"version": "5.0.337", | ||
"description": "PayPal Checkout components, for integrating checkout products.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -114,7 +114,17 @@ /* @flow */ | ||
if (color === "" || typeof color === "undefined") { | ||
// if multiple buttons are being rendered (smart stack), we set default color as gold | ||
// if a single button is rendered, we set color to first option in the fundingSource config | ||
color = multiple ? "gold" : colors[0]; | ||
color = colors[0]; | ||
// if multiple buttons are being rendered (smart stack), we set default color as gold > first | ||
if (multiple) { | ||
color = "gold"; | ||
} | ||
} | ||
// validate the first button rendered has a valid color | ||
// this check is needed to validate the first button in a smart stack gets the correct color | ||
if (i === 0 && !colors.includes(color)) { | ||
color = colors[0]; | ||
} | ||
// The secondary colors are used to render the smart stack (multiple buttons) | ||
@@ -121,0 +131,0 @@ // they keep track of the mapping of the color style prop to the |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1215627
16866