0.6.0 • Published 4 years ago

react-email-autocomplete-dropdown v0.6.0

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

react-email-autocomplete-dropdown

image

Demo

https://codesandbox.io/s/angry-elbakyan-s3xt7?file=/src/App.js

Installation

npm install react-email-autocomplete-dropdown

Usage

import React, { Component } from "react";
import Email from "react-email-autocomplete-dropdown";
import "react-email-autocomplete-dropdown/lib/main.min.css";

class App extends Component {
  render() {
    return (
      <div>
        <Email />
      </div>
    );
  }
}

export default App;

Custom domains

const domains = ["test.com", "hello.com"];
class App extends Component {
  render() {
    return (
      <div>
        <Email domains={domains} />
      </div>
    );
  }
}

export default App;

Events

handleOnChange=(e)=>{
    console.log(e.target.value)
}

dropdownClick=(value)=>{
    console.log(value)
}

......

<Email
  onChange={this.handleOnChange}
  dropdownOnClick={this.dropdownClick}
/>

Options

NameTypeDescriptionExample
valuestringinput state value'hello world'
placeholderstringcustom placeholder'hello world'
domainsarraycustom dropdown domains"gmail.com","yahoo.com"
disabledBooleandisable inputfalse (Default)

Events

onChange, dropdownOnClick

License

This software is released under the MIT License.

0.6.0

4 years ago

0.5.5

4 years ago

0.5.4

4 years ago

0.5.3

4 years ago

0.5.2

4 years ago

0.5.1

4 years ago

0.5.0

4 years ago