-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #707 from Automattic/update/paypal-logo
Components: Add `isCompact` prop to `PaymentLogo`
- Loading branch information
Showing
5 changed files
with
68 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
PaymentLogo | ||
==== | ||
|
||
## Usage | ||
|
||
```js | ||
import PaymentLogo from 'components/payment-logo'; | ||
|
||
<PaymentLogo type="amex" /> | ||
|
||
<PaymentLogo type="paypal" /> | ||
|
||
<PaymentLogo type="paypal" isCompact /> | ||
|
||
``` | ||
|
||
## Required props | ||
|
||
* `type` – String that determines which type of logo is displayed. Currently accepts: | ||
* amex | ||
* discover | ||
* mastercard | ||
* visa | ||
* paypal | ||
* `isCompact` (optional) – Boolean that determines if the compact PayPal logo is rendered. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* External dependencies | ||
*/ | ||
import React from 'react'; | ||
|
||
/** | ||
* Internal dependencies | ||
*/ | ||
import PaymentLogo from '../index'; | ||
|
||
const PaymentLogoExamples = React.createClass( { | ||
mixins: [ React.addons.PureRenderMixin ], | ||
|
||
render() { | ||
return ( | ||
<div className="design-assets__group"> | ||
<h2>PaymentLogo</h2> | ||
<div> | ||
<PaymentLogo type="amex" /> { ' ' } | ||
<PaymentLogo type="discover" /> { ' ' } | ||
<PaymentLogo type="mastercard" /> { ' ' } | ||
<PaymentLogo type="visa" /> { ' ' } | ||
<PaymentLogo type="paypal" isCompact /> { ' ' } | ||
<PaymentLogo type="paypal" /> | ||
</div> | ||
</div> | ||
); | ||
} | ||
} ); | ||
|
||
module.exports = PaymentLogoExamples; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters