/** * Registers the needed assets */ public function registerAssets() { $view = $this->getView(); TabsXAsset::register($view); $this->registerPlugin($this->_pluginName, 'jQuery("#' . $this->containerOptions['id'] . '")'); }
/** * Registers the needed assets */ public function registerAssets() { $view = $this->getView(); TabsXAsset::register($view); $id = $this->containerOptions['id']; if (!empty($this->pluginEvents)) { foreach ($this->pluginEvents as $event => $handler) { $function = new JsExpression($handler); $script .= "{$id}.on('{$event}', {$function});\n"; } } }
/** * Registers the assets for [[TabsX]] widget. */ public function registerAssets() { $view = $this->getView(); TabsXAsset::register($view); if ($this->printable) { $view->registerCss('@media print { .tab-content.printable > .tab-pane { display: block; opacity: 1; }}'); } $id = 'jQuery("#' . $this->containerOptions['id'] . '")'; $this->registerPlugin($this->pluginName, $id); if ($this->enableStickyTabs) { StickyTabsAsset::register($view); $opts = Json::encode($this->stickyTabsOptions); $id = 'jQuery("#' . $this->containerOptions['id'] . '>.nav")'; $view->registerJs("{$id}.stickyTabs({$opts});"); } }
/** * Registers the needed assets */ public function registerAssets() { $view = $this->getView(); TabsXAsset::register($view); $id = 'jQuery("#' . $this->containerOptions['id'] . '")'; $this->registerPlugin($this->pluginName, $id); if ($this->enableStickyTabs) { StickyTabsAsset::register($view); $opts = Json::encode($this->stickyTabsOptions); $view->registerJs("{$id}.stickyTabs({$opts});"); } }