├── .babelrc.js
├── .editorconfig
├── .eslintrc
├── .gitignore
├── .storybook
├── addons.js
└── config.js
├── .travis.yml
├── CONTRIBUTING.md
├── README.md
├── assets
├── basic.gif
├── bootstrap.gif
├── fannypack.gif
├── react-payment-inputs.png
├── react-payment-inputs.sketch
└── wrapper.gif
├── docs
├── 3.3e7c09a6a2f7bbc36612.bundle.js
├── 3.3e7c09a6a2f7bbc36612.bundle.js.map
├── favicon.ico
├── iframe.html
├── index.html
├── main.3e7c09a6a2f7bbc36612.bundle.js
├── main.3e7c09a6a2f7bbc36612.bundle.js.map
├── main.77cad4a5274c0b554b48.bundle.js
├── runtime~main.3e7c09a6a2f7bbc36612.bundle.js
├── runtime~main.3e7c09a6a2f7bbc36612.bundle.js.map
├── runtime~main.4ac396420dd14c580a84.bundle.js
├── sb_dll
│ ├── storybook_ui-manifest.json
│ ├── storybook_ui_dll.LICENCE
│ └── storybook_ui_dll.js
├── vendors~main.3e7c09a6a2f7bbc36612.bundle.js
├── vendors~main.3e7c09a6a2f7bbc36612.bundle.js.map
└── vendors~main.e08e57400c6b35755772.bundle.js
├── nwb.config.js
├── package.json
├── rollup.config.js
├── scripts
├── create-proxies.js
├── get-modules.js
└── remove-proxies.js
├── src
├── PaymentInputsContainer.js
├── PaymentInputsWrapper.js
├── images
│ ├── amex.js
│ ├── dinersclub.js
│ ├── discover.js
│ ├── hipercard.js
│ ├── index.js
│ ├── jcb.js
│ ├── mastercard.js
│ ├── placeholder.js
│ ├── troy.js
│ ├── unionpay.js
│ └── visa.js
├── index.js
├── usePaymentInputs.js
└── utils
│ ├── cardTypes.js
│ ├── formatter.js
│ ├── index.js
│ └── validator.js
├── stories
└── index.stories.js
├── tests
├── .eslintrc
└── index-test.js
└── yarn.lock
/.babelrc.js:
--------------------------------------------------------------------------------
1 | const path = require('path');
2 |
3 | module.exports = {
4 | "presets": [
5 | "@babel/preset-env",
6 | "@babel/preset-react"
7 | ],
8 | "plugins": [
9 | "@babel/plugin-proposal-class-properties",
10 | "@babel/plugin-proposal-object-rest-spread",
11 | "@babel/plugin-syntax-dynamic-import",
12 | "@babel/plugin-proposal-export-namespace-from"
13 | ]
14 | }
15 |
--------------------------------------------------------------------------------
/.editorconfig:
--------------------------------------------------------------------------------
1 | [*]
2 | indent_style = space
3 | indent_size = 2
4 |
--------------------------------------------------------------------------------
/.eslintrc:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@medipass/react-medipass",
3 | "rules": {
4 | "react/prop-types": "off"
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /coverage
2 | /demo/dist
3 | /es
4 | /lib
5 | /node_modules
6 | /umd
7 | npm-debug.log*
8 | /utils/
9 | /use-payment-inputs/
10 | /images/
11 | /PaymentInputsWrapper/
12 | /PaymentInputsContainer/
13 | /usePaymentInputs/
14 |
--------------------------------------------------------------------------------
/.storybook/addons.js:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/.storybook/config.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import { Box, ThemeProvider, css, palette } from 'fannypack';
3 | import { configure, addDecorator } from '@storybook/react';
4 |
5 | // automatically import all files ending in *.stories.js
6 | const req = require.context('../stories', true, /\.stories\.js$/);
7 | function loadStories() {
8 | req.keys().forEach(filename => req(filename));
9 | }
10 |
11 | const theme = {
12 | global: {
13 | base: css`
14 | & input {
15 | font-size: 16px;
16 | }
17 |
18 | *:focus {
19 | outline: 2px solid ${palette('primary')};
20 | outline-offset: 0px;
21 | }
22 | `
23 | }
24 | }
25 | const Decorator = storyFn =>
Sorry, but you either have no stories or none are selected somehow.
If the problem persists, check the browser console, or the terminal you've run Storybook from.