Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/obregonco/yii2-semantic-ui
Semantic UI extension for Yii2
https://github.com/obregonco/yii2-semantic-ui
semantic semantic-ui yii yii-extension yii2 yii2-extension yii2-widgets
Last synced: about 1 month ago
JSON representation
Semantic UI extension for Yii2
- Host: GitHub
- URL: https://github.com/obregonco/yii2-semantic-ui
- Owner: obregonco
- License: mit
- Fork: true (zelenin/yii2-semantic-ui)
- Created: 2017-04-09T20:14:23.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-05-18T17:02:45.000Z (over 7 years ago)
- Last Synced: 2024-09-24T08:32:08.382Z (about 1 month ago)
- Topics: semantic, semantic-ui, yii, yii-extension, yii2, yii2-extension, yii2-widgets
- Language: PHP
- Homepage: http://yii2-semantic-ui.zelenin.pw
- Size: 82 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Yii2 Semantic UI extension
[Semantic UI](http://semantic-ui.com) extension for [Yii2](http://www.yiiframework.com)
## Installation
yii2-semantic-ui 2.* works with Semantic UI 2.*
### Composer
The preferred way to install this extension is through [Composer](http://getcomposer.org/).
Either run
```
php composer.phar require obregonco/yii2-semantic-ui "~2"
```or add
```
"obregonco/yii2-semantic-ui": "~2"
```to the require section of your ```composer.json```
## Usage
Add SemanticUICSSAsset to AppAsset:
```php
set(\yii\grid\GridView::className(), \obregonco\SemanticUI\widgets\GridView::class);
Yii::$container->set(\yii\widgets\ActiveForm::className(), \obregonco\SemanticUI\widgets\ActiveForm::class);
Yii::$container->set(\yii\bootstrap\ActiveForm::className(), \obregonco\SemanticUI\widgets\ActiveForm::class);
Yii::$container->set(\yii\widgets\Breadcrumbs::className(), \obregonco\SemanticUI\collections\Breadcrumb::class);
Yii::$container->set(\yii\grid\CheckboxColumn::className(), \obregonco\SemanticUI\widgets\CheckboxColumn::class);
```Be very careful with it.
## Examples
- Inside an `ActiveForm` object
```php
$form->field($model, 'username')->label(false)->textInput([
'autofocus' => true,
'placeHolder' => $model->getAttributeLabel('username'),
'uiOptions' => [
'appendTo' => '',
'class' => 'ui left icon input',
]
])```
## Author
[Obregon.co](https://github.com/obregonco/)
[Ricardo O](https://github.com/robregonm/)### Credits
Original maintainer [Aleksandr Zelenin](https://github.com/zelenin/)