panix / wgt-colorpicker
Widget colorpicker
Installs: 219
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Language:JavaScript
Type:pixelion-component
Requires
- panix/engine: *
This package is auto-updated.
Last update: 2024-10-29 04:58:56 UTC
README
Widget for Yii Framework 2.0 to use colorpicker
Installation
The preferred way to install this extension is through composer.
Either run
php composer require --prefer-dist panix/wgt-colorpicker "*"
or add
"panix/wgt-colorpicker": "*"
to the require section of your composer.json
file.
Usage
Once the extension is installed, simply use it in your code by :
<?php echo $form->field($model, 'color')->widget(ColorPicker::className(), [ ])->textInput(['maxlength' => 7]); ?>
Configuration
Examaple
<?php echo $form->field($model, 'color')->widget(ColorPicker::className(), [ 'onShow' => new JsExpression('function() {}), ])->textInput(['maxlength' => 7]); ?>