mirror of
https://github.com/kingomarnajjar/flex-template-web.git
synced 2026-07-26 06:47:17 +10:00
Update proptypes
This commit is contained in:
parent
a78777a85b
commit
fcc932441e
6 changed files with 12 additions and 8 deletions
|
|
@ -516,6 +516,8 @@ CheckoutPageComponent.defaultProps = {
|
|||
enquiredTransaction: null,
|
||||
currentUser: null,
|
||||
stripePaymentToken: null,
|
||||
stripePaymentTokenInProgress: false,
|
||||
stripePaymentTokenError: null,
|
||||
};
|
||||
|
||||
CheckoutPageComponent.propTypes = {
|
||||
|
|
@ -539,8 +541,8 @@ CheckoutPageComponent.propTypes = {
|
|||
}).isRequired,
|
||||
sendOrderRequest: func.isRequired,
|
||||
onCreateStripePaymentToken: func.isRequired,
|
||||
stripePaymentTokenInProgress: bool.isRequired,
|
||||
stripePaymentTokenError: bool.isRequired,
|
||||
stripePaymentTokenInProgress: bool,
|
||||
stripePaymentTokenError: propTypes.error,
|
||||
stripePaymentToken: object,
|
||||
|
||||
// from connect
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ describe('CheckoutPage', () => {
|
|||
scrollingDisabled: false,
|
||||
onCreateStripePaymentToken: noop,
|
||||
stripePaymentTokenInProgress: false,
|
||||
stripePaymentTokenError: false,
|
||||
stripePaymentTokenError: null,
|
||||
};
|
||||
const tree = renderShallow(<CheckoutPageComponent {...props} />);
|
||||
expect(tree).toMatchSnapshot();
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ exports[`CheckoutPage matches snapshot 1`] = `
|
|||
paymentInfo="CheckoutPage.paymentInfo"
|
||||
showInitialMessageInput={true}
|
||||
stripePaymentToken={null}
|
||||
stripePaymentTokenError={false}
|
||||
stripePaymentTokenError={null}
|
||||
stripePaymentTokenInProgress={false}
|
||||
/>
|
||||
</section>
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ const initialState = {
|
|||
stripeAccount: null,
|
||||
stripeAccountFetched: false,
|
||||
stripePaymentTokenInProgress: false,
|
||||
stripePaymentTokenError: false,
|
||||
stripePaymentTokenError: null,
|
||||
stripePaymentToken: null,
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ export const Empty = {
|
|||
intl: fakeIntl,
|
||||
onCreateStripePaymentToken: noop,
|
||||
stripePaymentTokenInProgress: false,
|
||||
stripePaymentTokenError: false,
|
||||
stripePaymentTokenError: null,
|
||||
},
|
||||
group: 'forms',
|
||||
};
|
||||
|
|
|
|||
|
|
@ -272,6 +272,8 @@ StripePaymentForm.defaultProps = {
|
|||
onChange: () => null,
|
||||
showInitialMessageInput: true,
|
||||
stripePaymentToken: null,
|
||||
stripePaymentTokenInProgress: false,
|
||||
stripePaymentTokenError: null,
|
||||
};
|
||||
|
||||
const { bool, func, string, object } = PropTypes;
|
||||
|
|
@ -288,8 +290,8 @@ StripePaymentForm.propTypes = {
|
|||
authorDisplayName: string.isRequired,
|
||||
showInitialMessageInput: bool,
|
||||
onCreateStripePaymentToken: func.isRequired,
|
||||
stripePaymentTokenInProgress: bool.isRequired,
|
||||
stripePaymentTokenError: bool.isRequired,
|
||||
stripePaymentTokenInProgress: bool,
|
||||
stripePaymentTokenError: propTypes.error,
|
||||
stripePaymentToken: object,
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue