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
import React, { useMemo, useContext } from 'react'; | |
import { Image } from 'react-native'; | |
import PropTypes from 'prop-types'; | |
import { connect } from 'react-redux'; | |
import { View } from 'react-native'; | |
import { SvgWithCss } from 'react-native-svg'; | |
import { BrandingContext } from 'contexts'; | |
import { actions, selectors } from 'store/cards'; | |
import styles from './styles'; |
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
import { createAppContainer } from 'react-navigation'; | |
import { Provider as StoreProvider } from 'react-redux'; | |
import React from 'react'; | |
import store from 'store'; | |
import Navigation from 'navigation'; | |
import { BrandingProvider } from 'contexts'; | |
const AppContainer = createAppContainer(Navigation); |
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
import React, { createContext } from 'react'; | |
import PropTypes from 'prop-types'; | |
import { useSelector } from 'react-redux'; | |
import { split, trimEnd, toNumber } from 'lodash'; | |
import colors from 'res/colors'; | |
import { selectors } from 'store/branding'; | |
import { hexToHSL } from 'utils/helpers'; | |
export const BrandingContext = createContext({}); |
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
onAuthorize: function(data, actions) | |
{ | |
return actions.payment.execute().then(function() | |
{ | |
// Show a confirmation message to the buyer | |
window.alert('Thank you for your purchase!'); | |
}); | |
} |
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
payment: function(data, actions) { | |
return actions.payment.create({ | |
transactions: [{ | |
amount: { | |
total: '30.11', | |
currency: 'USD', | |
details: { | |
subtotal: '30.00', | |
tax: '0.07', | |
shipping: '0.03', |
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
payment: function(data, actions) { | |
return actions.payment.create({ | |
transactions: [{ | |
amount: { | |
total: '0.01', | |
currency: 'USD' | |
} | |
}] | |
}); | |
} |
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
<div id="paypal-button"></div> | |
<script src="https://www.paypalobjects.com/api/checkout.js"></script> | |
<script> | |
paypal.Button.render({ | |
// Configure environment | |
env: 'sandbox', | |
client: { | |
sandbox: 'demo_sandbox_client_id', | |
production: 'demo_production_client_id' | |
}, |
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
https://mws.amazonservices.com/OffAmazonPayments_Sandbox/2013-01-01 ?AWSAccessKeyId=AKIAJKYFSJU7PEXAMPLE | |
&Action=AuthorizeOnBillingAgreement | |
&AmazonBillingAgreementId=C01-1234567-1234567 | |
&AuthorizationAmount.Amount=10 | |
&AuthorizationAmount.CurrencyCode=USD | |
&AuthorizationReferenceId=test_authorize_1 | |
&MWSAuthToken=amzn.mws.4ea38b7b-f563-7709-4bae-87aeaEXAMPLE | |
&SellerId=YOUR_SELLER_ID_HERE | |
&SellerAuthorizationNote=ForNovemberOrder | |
&SellerOrderAttributes.SellerOrderId=testSellerOrderId |
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
https://mws.amazonservices.com/OffAmazonPayments_Sandbox/2013-01-01?AWSAccessKeyId=AKIAJKYFSJU7PEXAMPLE | |
&AmazonBillingAgreementId=C01-8824045-7416542 | |
&Action=ValidateBillingAgreement | |
&MWSAuthToken=amzn.mws.4ea38b7b-f563-7709-4bae-87aeaEXAMPLE | |
&SellerId=YOUR_SELLER_ID_HERE | |
&SignatureMethod=HmacSHA256 | |
&SignatureVersion=2 | |
&Timestamp=2013-12-11T10%3A38%3A44.000Z | |
&Version=2013-01-01 | |
&Signature=gP11oEBaaiQdASWsLDyid18Wn%2BB%2FKZQQtKgpHCtDHdc%3D |
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
https://mws.amazonservices.com/OffAmazonPayments_Sandbox/2013-01-01? | |
AWSAccessKeyId=AKIAJKYFSJU7PEXAMPLE | |
&AmazonBillingAgreementId=C01-8824045-7416542 | |
&Action=SetBillingAgreementDetails | |
&BillingAgreementAttributes.PlatformId=PLATFORM_ID_HERE | |
&BillingAgreementAttributes.SellerNote=APPROVE LITE APPROVE HEAVY | |
&BillingAgreementAttributes.SellerBillingAgreementAttributes.CustomInformati | |
on=Example Customer Info | |
&BillingAgreementAttributes.SellerBillingAgreementAttributes.StoreName=Test Store Name | |
&MWSAuthToken=amzn.mws.4ea38b7b-f563-7709-4bae-87aeaEXAMPLE |
NewerOlder