jQuery plugin providing a Bootstrap user interface for managing tags
<StyleSheet StyleSheet="Framework.bootstrap.bootstrap.css" /> <StyleSheet ShowModes="rdBrowser" StyleSheet="Framework.bootstrap.Overrides.css" /> <StyleSheet ShowModes="rdBrowser" StyleSheet="Fonts.combined.css" /> <StyleSheet ShowModes="rdBrowser" StyleSheet="Framework.css.Layout.css" /> <IncludeScriptFile ID="jquery" IncludedScriptFile="Framework.bootstrap.jquery.min.js" /> <IncludeScriptFile ID="bootstrap" IncludedScriptFile="Framework.bootstrap.bootstrap.js"> <Note Note="Includes Bootstrap.min.js, Popper.js or tether.js" /> </IncludeScriptFile>
<StyleSheet StyleSheet="TagsInput.bootstrap-tagsinput.css" /> <IncludeScriptFile IncludedScriptFile="TagsInput.typeahead.bundle.min.js" /> <IncludeScriptFile IncludedScriptFile="TagsInput.angular-min.js" /> <IncludeScriptFile IncludedScriptFile="TagsInput.bootstrap-tagsinput.min.js" /> <IncludeScriptFile IncludedScriptFile="TagsInput.bootstrap-tagsinput-angular.min.js" />
<StyleSheet StyleSheet="Framework.bootstrap.bootstrap.css" /> <StyleSheet StyleSheet="Framework.bootstrap.Overrides.css" /> <StyleSheet ShowModes="rdBrowser" StyleSheet="Framework.css.Layout.css" /> <IncludeScriptFile IncludedScriptFile="Framework.bootstrap.jquery.min.js" /> <IncludeScriptFile IncludedScriptFile="Framework.bootstrap.bootstrap.js"> <Note Note="Includes Bootstrap.min.js and Popper.js" /> </IncludeScriptFile>
Add data-role="tagsinput" to your input field to automatically change it to a tags input field.
data-role="tagsinput"
Typeahead is not included in Bootstrap, so you'll have to include your own typeahead.js library. An example of using this is shown below.
tagClass
itemValue
itemText
confirmKeys
maxTags
maxChars
cancelConfirmKeysOnEmpty
onTagExists
trimValue
allowDuplicates
focusClass
freeInput
typeahead
source
add
remove
removeAll
focus
input
refresh
destroy
//change the selected date range of that picker $('input').tagsinput('add', { id: 1, text: 'some tag' }); $('input').tagsinput('remove', { id: 1, text: 'some tag' });
itemAddedOnInit
beforeItemAdd
itemAdded
beforeItemRemove
itemRemoved
$('input').on('itemAddedOnInit', function(event) { // event.item: contains the item });