protected function renderToggleButton() { if (!$this->toggleButton) { return ''; } $options = isset($this->toggleButton['wrapper']) ? $this->toggleButton['wrapper'] : []; unset($this->toggleButton['wrapper']); $this->toggleButton['data-target'] = '#' . $this->options['id']; $tag = isset($options['tag']) ? $options['tag'] : 'span'; if ($this->isStatic) { $this->toggleButton['data-backdrop'] = 'static'; } return Html::tag($tag, parent::renderToggleButton(), $options); }