11<?php
22
33/**
4- * @copyright Copyright © Kartik Visweswaran, Krajee.com, 2015 - 2021
4+ * @copyright Copyright © Kartik Visweswaran, Krajee.com, 2015 - 2022
55 * @package yii2-widgets
66 * @subpackage yii2-widget-activeform
77 * @version 1.6.1
2121 * ActiveForm is a widget that builds an interactive HTML form for one or multiple data models and extends the
2222 * [[YiiActiveForm]] widget to handle various bootstrap form types and new functionality.
2323 *
24- * Example:
24+ * For example,
2525 *
26- * ~~~
26+ * ```php
2727 * // Horizontal Form
2828 * $form = ActiveForm::begin([
2929 * 'id' => 'form-signup',
4141 * 'type' => ActiveForm::TYPE_HORIZONTAL
4242 * 'formConfig' => ['labelSpan' => 2, 'deviceSize' => ActiveForm::SIZE_SMALL]
4343 * ]);
44- * ~~~
44+ * ```
4545 *
4646 * @method ActiveField field(Model $model, string $attribute, array $options = [])
47+ *
4748 * @author Kartik Visweswaran <[email protected] > 4849 * @since 1.0
4950 */
@@ -52,8 +53,7 @@ class ActiveForm extends YiiActiveForm implements BootstrapInterface
5253 use BootstrapTrait;
5354
5455 /**
55- * @var bool whether to render tooltip styled error and success messages. Applicable only for [[bsVersion]] 4.x
56- * and above.
56+ * @var bool whether to render tooltip styled error and success messages. Applicable only for [[bsVersion]] >= 4.
5757 */
5858 public $ tooltipStyleFeedback = false ;
5959
@@ -118,20 +118,27 @@ class ActiveForm extends YiiActiveForm implements BootstrapInterface
118118 * forms.
119119 * - `showHints`: _boolean_, whether to show hints (true) or hide errors (false). Defaults to `true`. The hint will be
120120 * rendered only if a valid hint has been set through the `hint()` method.
121- * ~~~
121+ *
122+ * Defaults to,
123+ *
124+ * ```php
122125 * [
123126 * 'labelSpan' => 2,
124127 * 'deviceSize' => ActiveForm::SIZE_MEDIUM,
125128 * 'showLabels' => true,
126129 * 'showErrors' => true,
127130 * 'showHints' => true
128131 * ],
129- * ~~~
132+ * ```
130133 */
131134 public $ formConfig = [];
132135
133136 /**
134- * @var array HTML attributes for the form tag. Defaults to `['role' => 'form']`.
137+ * @var array HTML attributes for the form tag. Defaults to:
138+ *
139+ * ```php
140+ * ['role' => 'form']
141+ * ```
135142 */
136143 public $ options = ['role ' => 'form ' ];
137144
0 commit comments