Exemple #1
0
 public function __construct()
 {
     parent::__construct();
     // Change the default jQuery UI theme.
     $this->configureJuiTheme('base');
     // Get the current theme if set and valid.
     $theme = Theme::theme();
     // If not set or not valid, use the default theme.
     if (!$theme) {
         $this->depends = [static::$defaultThemeAsset];
         return;
     }
     // Configure bootstrap and jQuery UI theme.
     $this->configureBootstrap($theme->bootstrap);
     $this->configureJuiTheme($theme->juiTheme);
     // Setup the dependencies.
     $this->configureDependencies($theme->depends);
     $this->configureDependencies($theme->depends);
     // Set source path for the theme assets and register CSS and JS.
     $this->sourcePath = $theme->sourcePath;
     $this->configureDependencies($theme->depends);
     $this->configureCSS($theme->css);
     $this->configureJS($theme->js);
 }