Skip to content

Commit

Permalink
Adopt configuration to changes in yiisoft/form (#64)
Browse files Browse the repository at this point in the history
  • Loading branch information
vjik committed May 30, 2022
1 parent 8e4dfdd commit 594a17c
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 37 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG.md
Expand Up @@ -2,8 +2,8 @@

## 1.0.1 under development

- no changes in this release.
- Chg #64: Adopt configuration to changes in `yiisoft/form` (vjik)

## 1.0.0 April 01, 2022

- Initial release.
- Initial release.
3 changes: 1 addition & 2 deletions composer.json
Expand Up @@ -46,8 +46,7 @@
"source-directory": "config"
},
"config-plugin": {
"params": "params.php",
"widgets": "widgets.php"
"params": "params.php"
}
},
"config": {
Expand Down
27 changes: 16 additions & 11 deletions config/params.php
Expand Up @@ -2,20 +2,25 @@

declare(strict_types=1);

/** @link https://bulma.io/documentation/form/general/#complete-form-example */
/**
* For use bulma style as default in Yii Forms set `$params['yiisoft/form']['defaultConfig']` to `bulma`.
*
* @link https://bulma.io/documentation/form/general/#complete-form-example
*/

return [
'yiisoft/form' => [
'bulma' => [
'enabled' => true,
'containerClass' => 'field',
'errorClass' => 'has-text-danger is-italic',
'hintClass' => 'help',
'inputClass' => 'input',
'invalidClass' => 'has-background-danger',
'labelClass' => 'label',
'template' => "{label}<div class=\"control\">\n{input}</div>\n{hint}\n{error}",
'validClass' => 'has-background-success',
'configs' => [
'bulma' => [
'containerClass' => 'field',
'inputClass' => 'input',
'invalidClass' => 'has-background-danger',
'validClass' => 'has-background-success',
'template' => "{label}<div class=\"control\">\n{input}</div>\n{hint}\n{error}",
'labelClass' => 'label',
'errorClass' => 'has-text-danger is-italic',
'hintClass' => 'help',
],
],
],
];
22 changes: 0 additions & 22 deletions config/widgets.php

This file was deleted.

0 comments on commit 594a17c

Please sign in to comment.