<commit_before><?php
/**
 * @link http://www.yiiframework.com/
 * @copyright Copyright (c) 2008 Yii Software LLC
 * @license http://www.yiiframework.com/license/
 */

namespace yii\jui;

use Yii;
use yii\helpers\Html;

/**
 * DatePicker renders an datepicker jQuery UI widget.
 *
 * For example:
 *
 * ```php
 * echo DatePicker::widget(array(
 *     'language' => 'yii/jui/datepicker/i18n/ru',
 *     'model' => $model,
 *     'attribute' => 'country',
 *     'clientOptions' => array(
 *         'dateFormat' => 'yy-mm-dd',
 *     ),
 * ));
 * ```
 *
 * The following example will use the name property instead:
 *
 * ```php
 * echo DatePicker::widget(array(
 *     'language' => 'yii/jui/datepicker/i18n/ru',
 *     'name'  => 'country',
 *     'clientOptions' => array(
 *         'dateFormat' => 'yy-mm-dd',
 *     ),
 * ));
 *```
 *
 * @see http://api.jqueryui.com/datepicker/
 * @author <NAME> <<EMAIL>>
 * @since 2.0
 */
class DatePicker extends InputWidget
{
	/**
	 * @var string the jQuery UI datepicker widget language bundle.
	 */
	public $language = false;
	/**
	 * @var boolean If true, shows the widget as an inline calendar and the input as a hidden field.
	 */
	public $inline = false;


	/**
	 * Renders the widget.
	 */
	public function run()
	{
		echo $this->renderWidget() . "\n";
		$this->registerWidget('datepicker');
		if ($this->language !== false) {
			$this->getView()->registerAssetBundle($this->language);
		}<commit_msg>language as code, not bundle<commit_after><?php
/**
 * @link http://www.yiiframework.com/
 * @copyright Copyright (c) 2008 Yii Software LLC
 * @license http://www.yiiframework.com/license/
 */

namespace yii\jui;

use Yii;
use yii\helpers\Html;

/**
 * DatePicker renders an datepicker jQuery UI widget.
 *
 * For example:
 *
 * ```php
 * echo DatePicker::widget(array(
 *     'language' => 'ru',
 *     'model' => $model,
 *     'attribute' => 'country',
 *     'clientOptions' => array(
 *         'dateFormat' => 'yy-mm-dd',
 *     ),
 * ));
 * ```
 *
 * The following example will use the name property instead:
 *
 * ```php
 * echo DatePicker::widget(array(
 *     'language' => 'ru',
 *     'name'  => 'country',
 *     'clientOptions' => array(
 *         'dateFormat' => 'yy-mm-dd',
 *     ),
 * ));
 *```
 *
 * @see http://api.jqueryui.com/datepicker/
 * @author <NAME> <<EMAIL>>
 * @since 2.0
 */
class DatePicker extends InputWidget
{
	/**
	 * @var string the locale ID (eg 'fr', 'de') for the language to be used by the date picker.
	 * If this property set to false, I18N will not be involved. That is, the date picker will show in English.
	 */
	public $language = false;
	/**
	 * @var boolean If true, shows the widget as an inline calendar and the input as a hidden field.
	 */
	public $inline = false;


	/**
	 * Renders the widget.
	 */
	public function run()
	{
		echo $this->renderWidget() . "\n";
		$this->registerWidget('datepicker');
		if ($this->language !== false) {
			$this->getView()->registerAssetBundle("yii/jui/datepicker/i18n/$this->language");
		}
{'fraction_non_alphanumeric': 0.1799273687685705, 'fraction_numerical': 0.006602839220864972, 'mean_word_length': 2.9816031537450725, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 39, 'https://': 0, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5373635', 'n_tokens_mistral': 1055, 'n_tokens_neox': 1001, 'n_words': 269}