/** * @param string $style * @return $this */ public function style($style = null) { if ($style) { $this->presenter->setStyle($this->config->get('styles.' . $style)); } return $this; }
/** * @param string $style * @return string */ public function present($style = null) { $this->initPresenter(); if ($style = $style ? $this->config->get('styles.' . $style) : ($this->style ?: null)) { $tmpStyle = $this->presenter->getStyle(); $this->presenter->setStyle($style); } $element = $this->presenter->renderAll(); if ($style) { $this->presenter->setStyle($tmpStyle); } return $element; }