createCssLoader() публичный Метод

public createCssLoader ( string $name ) : WebLoader\Nette\CssLoader
$name string
Результат WebLoader\Nette\CssLoader
 public function startup()
 {
     parent::startup();
     $this->cssLoader = $this->webLoader->createCssLoader('default');
     $this->jsLoader = $this->webLoader->createJavaScriptLoader('default');
     // css file
     $cssCompiler = $this->cssLoader->getCompiler();
     $this->cssLoaderFile = $cssCompiler->getOutputNamingConvention()->getFilename($cssCompiler->getFileCollection()->getFiles(), $cssCompiler) . '?' . $cssCompiler->getLastModified();
     // js file
     $jsCompiler = $this->jsLoader->getCompiler();
     $this->jsLoaderFile = $jsCompiler->getOutputNamingConvention()->getFilename($jsCompiler->getFileCollection()->getFiles(), $jsCompiler) . '?' . $jsCompiler->getLastModified();
 }
Пример #2
0
 /**
  * @param string $name
  * @return CssLoader
  */
 public function createCssLoader(string $name = self::DEFAULT_CSS_SECTION) : CssLoader
 {
     return $this->loaderFactory->createCssLoader($name);
 }
Пример #3
0
 /**
  * @param LoaderFactory $f abstraktní továrna WebLoader
  * @return CssLoader
  */
 protected function createComponentCss(LoaderFactory $f)
 {
     return $f->createCssLoader('front');
 }
Пример #4
0
 protected function createComponentCss()
 {
     return $this->webLoader->createCssLoader('default')->setMedia('screen,projection,tv,print');
 }
Пример #5
0
 protected function createComponentCss()
 {
     return $this->webLoader->createCssLoader('frontend');
 }
Пример #6
0
 /**
  * @param  string  $module
  * @return string
  */
 public function renderCss($module = 'default')
 {
     $control = $this->factory->createCssLoader($module);
     return $control->render();
 }
Пример #7
0
 /** @return CssLoader */
 protected function createComponentCss()
 {
     return $this->webLoader->createCssLoader('default');
 }