예제 #1
0
 /**
  * Initializes the widget.
  * If you override this method, make sure you call the parent implementation first.
  */
 public function init()
 {
     parent::init();
     Html::addCssClass($this->options, 'f-dropdown');
     $this->options['data-dropdown-content'] = 1;
     $this->options['tabindex'] = '-1';
     $this->_containerOptions = $this->options;
 }
예제 #2
0
 /**
  * 
  */
 public function init()
 {
     parent::init();
     Html::addCssClass($this->options, 'icon-bar');
     if (empty($this->options['role'])) {
         $this->options['role'] = 'navigation';
     }
     FoundationIconAsset::register($this->getView());
 }
 /**
  * 
  */
 public function init()
 {
     parent::init();
     if ($this->route === null && Yii::$app->controller !== null) {
         $this->route = Yii::$app->controller->getRoute();
     }
     if ($this->params === null) {
         $this->params = Yii::$app->request->getQueryParams();
     }
 }
예제 #4
0
 /**
  * 
  */
 public function init()
 {
     parent::init();
     Html::addCssClass($this->options, 'top-bar');
     if (empty($this->options['role'])) {
         $this->options['role'] = 'navigation';
     }
     $this->options['data-topbar'] = 1;
     $options = $this->options;
     $tag = ArrayHelper::remove($options, 'tag', 'nav');
     if (!empty($this->containerOptions)) {
         echo Html::beginTag('div', $this->containerOptions);
     }
     echo Html::beginTag($tag, $options);
     echo Html::tag('ul', implode("\n", $this->headerItems()), ['class' => 'title-area']);
 }
예제 #5
0
 /**
  * Initializes the widget.
  * If you override this method, make sure you call the parent implementation first.
  */
 public function init()
 {
     parent::init();
     Html::addCssClass($this->options, 'button-group');
 }
예제 #6
0
 /**
  * Initializes the widget.
  * If you override this method, make sure you call the parent implementation first.
  */
 public function init()
 {
     parent::init();
     $this->clientOptions = false;
     $this->options['role'] = 'button';
 }