2.0.0 • Published 7 years ago

react-password-with-generator v2.0.0

Weekly downloads
11
License
MIT
Repository
github
Last release
7 years ago

An password input with a configurable generator.

Props

The component takes the following props.

PropTypeDescription
onFocusfunctionCallback function to invoke when the input password field has focus. The function signature should be the following: function(e) { }.
onBlurfunctionCallback function to invoke when field loses focus. The function signature should be the following: function(e) { }.
classNamestringClass name to be added to the wrapper div
messagesobjectYou could define the string messages to be shown for messages={{inputPlaceholder: 'Define the password', generateButtonLabel: 'Generate one!'}}
passwordCustomLengthintegerThe length of the password to be generated
passwordNotMemorablebooleanIf the password generated should be memorable. Default is false.
passwordShouldMatchPatternstringThe pattern to match for the generated password
passwordPrefixstringCustomize the generated password prefix

Installation

npm install react-password-with-generator

Demo

You have a demo here.

Usage

If you want the default styling include the components CSS with

import "react-password-with-generator/style.css" // for ES6 modules
// or
require("react-password-with-generator/style.css") // for CommonJS

Development

npm install
npm run dev

Build

npm run build

License

MIT

2.0.0

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

0.0.1

7 years ago