0.0.5 • Published 8 years ago

ng-smart-input v0.0.5

Weekly downloads
3
License
Apache-2.0
Repository
github
Last release
8 years ago

Alt text

ng-smart-input

Introduction

Fancy performance input box with autocomplete

Installing

  • npm install -g gulp gulp-cli install global cli dependencies
  • npm install to install dependencies

Usage

  • <script type='text/javascript' src='ng-smart-input/dist/app.min.js'></script>
  • angular.module('myApp', ['ng-smart-input'])
  • provide a config object

Config Options

  • id: give your input a unique id (mandatory)
  • placeholders: list of texts to be displayed as placeholder (optional)
  • delay: wait time until suggestions appear (optional)
  • max: maximum number of suggestions to be shown
  • suggestions: search space

Config Example

this.smartInputConfig = {
	id: 'fancy-input',
	placeholders: [
		'fancy smart input...',
		'your search text goes here'
	],
	delay: 500,
	suggestions: [
		'angular', 
		'angoala', 
		'kola', 
		'ant', 
		'angry',
		'anthem',
		'apple',
		'ak',
		'car',
		'arse',
		'anker',
		'antler',
		'obama',
		'omaha',
		'alabama'
	]
};
0.0.5

8 years ago

0.0.4

8 years ago

0.0.2

8 years ago

0.0.1

8 years ago