Skip to content

Latest commit

 

History

History
40 lines (31 loc) · 741 Bytes

README.md

File metadata and controls

40 lines (31 loc) · 741 Bytes

EmailHint

Autocomplete domain part of e-mail after type any chars after @.

EmailHint

Usage

  1. Wrap HTML <input> element with:
<span class="emailHint">
  <input name="email">
  <span class="emailHint-hint"></span>
</span>
  1. Add CSS class selectors .emailHint-measure and .emailHint-hint to input declaration:
input,
.emailHint-measure,
.emailHint-hint {
  /* some styles */
}
  1. Link emailHint.js.

  2. Init with className and domains list:

EmailHint.init(
  "emailHint", // className
  [
    "gmail.com",
    /* … */
  ]
);

(http://jecas.cz/napovidani-emailu)