1.2.3-w • Published 8 years ago

bf-ng2-tag-input v1.2.3-w

Weekly downloads
1
License
ISC
Repository
-
Last release
8 years ago

angular2-tag-input

Tag input component for Angular 2

Demo & Examples

View Demo

Quick Start

npm install angular2-tag-input --save
// In one of your application NgModules
import {RlTagInputModule} from 'angular2-tag-input';

@NgModule({
  imports: [
    RlTagInputModule
  ]
})
export class YourModule {}

// In one of your component templates
<rl-tag-input [(ngModel)]="tags" placeholder="Testing placeholder"></rl-tag-input>

API

Inputs

NameTypeDefaultDescription
addOnBlurbooleantrueWhether to attempt to add a tag when the input loses focus.
addOnCommabooleantrueWhether to attempt to add a tag when the user presses comma.
addOnEnterbooleantrueWhether to attempt to add a tag when the user presses enter.
addOnPastebooleantrueWhether to attempt to add a tags when the user pastes their clipboard contents.
addOnSpacebooleantrueWhether to attempt to add a tags when the user presses space.
allowDuplicatesbooleanfalseAllow duplicate tags.
allowedTagsPatternRegExp/.+/RegExp that must match for a tag to be added.
autocompletebooleanfalseToggle autocomplete mode on/off
autocompleteItemsstring[][]List of suggestions for autocomplete menu
autocompleteMustMatchbooleantrueWhether a tag must be present in the suggestions list to be valid
autocompleteSelectFirstItembooleantruePre-highlight the first item in the suggestions list
placeholderstring'Add a tag'Placeholder for the <input> tag.

Outputs

NameType EmittedDescription
addTagstringEmits the added tag string
removeTagstringEmits the removed tag string
1.2.3-w

8 years ago

1.2.3-v

8 years ago

1.2.3-u

8 years ago

1.2.3-t

8 years ago

1.2.3-s

8 years ago

1.2.3-r

8 years ago

1.2.3-q

8 years ago

1.2.3-p

8 years ago

1.2.3-o

8 years ago

1.2.3-n

8 years ago

1.2.3-m

8 years ago

1.2.3-l

8 years ago

1.2.3-k

8 years ago

1.2.3-j

8 years ago

1.2.3-i

8 years ago

1.2.3-h

8 years ago

1.2.3-g

8 years ago

1.2.3-f

8 years ago

1.2.3-e

8 years ago

1.2.3-d

8 years ago

1.2.3-c

8 years ago

1.2.3-b

8 years ago

1.2.3-a

8 years ago