1.0.3 • Published 2 years ago

react-ir-banks-logo v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

react-ir-banks-logo

A React component that returns logos of Iranian banks based on card number. Demo

Installation

npm i react-ir-banks-logo

Example

import { BankIcon } from 'react-ir-banks-logo';

function App() {
  const [digits, setDigits] = useState('');
  const [name, setName] = useState('');
  return (
    <div className="App">
      <input
        type="text"
        value={digits}
        onChange={e => setDigits(e.target.value)}
      />
      <BankIcon
        digits={digits}
        size="200px"
        margin="100px"
        onFindBankName={(name: string) => setName(name)}
      />
      <h1>{name}</h1>
    </div>
  );
}

Props

PropsValue TypeDefault Value
digitsstring \| numberis required
sizestring'40px'
marginstring'8px'
onFindBankName(name: string) => void-
1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago

0.2.1

2 years ago

0.2.0

2 years ago

0.1.5

2 years ago

0.1.4

2 years ago

0.1.3

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago

0.1.0

2 years ago