2017 © Pedro Peláez
 

yii2-extension yii2-bootstrap-tokenfield

Create elegant taggable fields with copy/paste and keyboard support using Bootstrap Tokefield

image

akavov/yii2-bootstrap-tokenfield

Create elegant taggable fields with copy/paste and keyboard support using Bootstrap Tokefield

  • Friday, August 28, 2015
  • by akaVoV
  • Repository
  • 1 Watchers
  • 0 Stars
  • 478 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 1 Forks
  • 1 Open issues
  • 2 Versions
  • 15 % Grown

The README.md

Bootstrap Tokenfield

Create elegant taggable fields with copy/paste and keyboard support using Bootstrap Tokefield (http://sliptree.github.io/bootstrap-tokenfield/), (*1)

Installation

The preferred way to install this extension is through composer., (*2)

Either run, (*3)

php composer.phar require --prefer-dist akavov/yii2-bootstrap-tokenfield : "*"

or add, (*4)

"akavov/yii2-bootstrap-tokenfield": "*"

to the require section of your composer.json file., (*5)

Usage

Once the extension is installed, simply use it in your code by :, (*6)

<?= \akavov\tokenfield\Tokenfield::widget([
    'name' => 'inputName',
]);

to use autocomplete, (*7)

<?= \akavov\tokenfield\Tokenfield::widget([
    'name' => 'inputName',
    "pluginOptions" => [
        'delimiter' => '#', // default ',' (comma)
        'showAutocompleteOnFocus' => true,
        'autocomplete' => [
            'source' => ['red','blue','green','yellow','violet','brown','purple','black','white'],
            'delay' => 100
        ],
    ],
]);

to use with ActiveForm, (*8)

<?= $form->field($model, 'name')->widget(\akavov\tokenfield\Tokenfield::className(), [
    'pluginOptions' => [
        'delimiter' => '#', // default ',' (comma)
        'showAutocompleteOnFocus' => true,
        'autocomplete' => [
            'source' => ['red','blue','green','yellow','violet','brown','purple','black','white'],
            'delay' => 100
        ],
    ],
]); ?>

TODO

  1. Add ability to choose between jqueryui and typeahead
  2. Test

The Versions

28/08 2015

dev-master

9999999-dev

Create elegant taggable fields with copy/paste and keyboard support using Bootstrap Tokefield

  Sources   Download

MIT

The Requires

  • yiisoft/yii2 *
  • bower-asset/jquery >=2.1.0
  • bower-asset/jqueryui >=1.11.4
  • npm-asset/bootstrap-tokenfield *
  • bower-asset/bootstrap >=3.1.1
  • bower-asset/typeahead.js >=0.10.1

 

by Avatar akaVoV

extension yii2 tokenfield bootstrap tags

28/08 2015

0.1.0

0.1.0.0

Create elegant taggable fields with copy/paste and keyboard support using Bootstrap Tokefield

  Sources   Download

MIT

The Requires

  • yiisoft/yii2 *
  • bower-asset/jquery >=2.1.0
  • bower-asset/jqueryui >=1.11.4
  • npm-asset/bootstrap-tokenfield *
  • bower-asset/bootstrap >=3.1.1
  • bower-asset/typeahead.js >=0.10.1

 

by Avatar akaVoV

extension yii2 tokenfield bootstrap tags