Beispiel #1
0
        public IEnumerable <string> GetZones()
        {
            var theme = _siteThemeService.GetSiteTheme();
            IEnumerable <string> zones = new List <string>();

            // get the zones for this theme
            if (theme.Zones != null)
            {
                zones = theme.Zones.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries)
                        .Select(x => x.Trim())
                        .Distinct()
                        .ToList();
            }

            // if this theme has no zones defined then walk the BaseTheme chain until we hit a theme which defines zones
            while (!zones.Any() && theme != null && !string.IsNullOrWhiteSpace(theme.BaseTheme))
            {
                string baseTheme = theme.BaseTheme;
                theme = _extensionManager.GetExtension(baseTheme);
                if (theme != null && theme.Zones != null)
                {
                    zones = theme.Zones.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries)
                            .Select(x => x.Trim())
                            .Distinct()
                            .ToList();
                }
            }

            return(zones);
        }
Beispiel #2
0
        public void OnResultExecuting(ResultExecutingContext filterContext)
        {
            // ignore filter on admin pages
            if (AdminFilter.IsApplied(filterContext.RequestContext))
            {
                return;
            }

            // should only run on a full view rendering result
            if (!(filterContext.Result is ViewResult))
            {
                return;
            }

            var viewResult = filterContext.Result as ViewResult;

            if (viewResult == null)
            {
                return;
            }

            var themeName = _siteThemeService.GetSiteTheme();

            if (themeName.Name == Constants.ThemeName)
            {
                this.AddCss();
            }
        }
        public void Exporting(ExportContext context)
        {
            if (!context.ExportOptions.CustomSteps.Contains("Current Theme"))
            {
                return;
            }

            var currentTheme = _siteThemeService.GetSiteTheme();

            if (currentTheme == null)
            {
                var ex = new OrchardException(T("Could not add the Current Theme step to the export because there is currently no theme activated."));
                Logger.Error(ex, ex.Message);
                throw ex;
            }

            var xmlElement = new XElement("CurrentTheme", new XAttribute("name", currentTheme.Name), new XAttribute("id", currentTheme.Id));

            var rootElement = context.Document.Descendants("Orchard").FirstOrDefault();

            if (rootElement == null)
            {
                var ex = new OrchardException(T("Could not add the Current Theme step to the export because the document passed via the Export Context did not contain a node called 'Orchard'. The document was malformed."));
                Logger.Error(ex, ex.Message);
                throw ex;
            }

            rootElement.Add(xmlElement);
        }
        public void PopulateConfiguration(CKEditorConfigContext config)
        {
            // Get CKEditor settings
            var ckSettings = Services.WorkContext.CurrentSite.As <CKEditorSettingsPart>();

            if (ckSettings != null)
            {
                if (!String.IsNullOrWhiteSpace(ckSettings.ContentsCss))
                {
                    // Push css link(s) into config
                    var currentTheme = _siteThemeService.GetSiteTheme();
                    var sheets       =
                        // Get list of stylesheets
                        ckSettings.ContentsCss.Split(new[] { ' ', ',' }, StringSplitOptions.RemoveEmptyEntries)
                        // Transform to full URLs
                        .Select(sheet => string.Format("{0}/{1}/Styles/{2}", currentTheme.Location, currentTheme.Id, sheet))
                        .Where(path => _virtualPathProvider.FileExists(path)).Select(path => UrlHelper.GenerateContentUrl(path, Services.WorkContext.HttpContext)).ToList(); // Execute at this time to avoid trouble later
                    config.Add(new CKEditorConfigStringList("contentsCss", sheets));
                }
                if (!String.IsNullOrWhiteSpace(ckSettings.ExtraPlugins))
                {
                    // TODO: Plugins should add modularly from an ICKEditorPlugin interface?
                    var plugins =
                        ckSettings.ExtraPlugins;

                    config.Add(new CKEditorConfigString("extraPlugins", plugins));
                }
                // For removing standard styles if stylesheet parser is used
                if (ckSettings.ClearDefaultStyleSets)
                {
                    config.Add(new CKEditorConfigStringList("stylesSet", Enumerable.Empty <String>()));
                }
            }
        }
Beispiel #5
0
        protected override DriverResult Editor(WidgetsContainerPart part, dynamic shapeHelper)
        {
            return(ContentShape("Parts_WidgetsContainer", () => {
                var settings = part.Settings.GetModel <WidgetsContainerSettings>();

                var currentTheme = _siteThemeService.GetSiteTheme();
                var currentThemesZones = _widgetsService.GetZones(currentTheme).ToList();
                var widgetTypes = _widgetsService.GetWidgetTypeNames().ToList();
                if (!settings.UseHierarchicalAssociation)
                {
                    if (!string.IsNullOrWhiteSpace(settings.AllowedZones))
                    {
                        currentThemesZones = currentThemesZones.Where(x => settings.AllowedZones.Split(',').Contains(x)).ToList();
                    }
                    if (!string.IsNullOrWhiteSpace(settings.AllowedWidgets))
                    {
                        widgetTypes = widgetTypes.Where(x => settings.AllowedWidgets.Split(',').Contains(x)).ToList();
                    }
                }
                else if (settings.HierarchicalAssociation != null && settings.HierarchicalAssociation.Count() > 0)
                {
                    currentThemesZones = currentThemesZones.Where(ctz => settings.HierarchicalAssociation.Select(x => x.ZoneName).Contains(ctz)).ToList();
                    widgetTypes = widgetTypes.Where(w => settings.HierarchicalAssociation.Any(x => x.Widgets.Any(a => a.WidgetType == w || a.WidgetType == "All"))).ToList();
                }

                var widgets = _widgetManager.GetWidgets(part.Id, false);

                var zonePreviewImagePath = string.Format("{0}/{1}/ThemeZonePreview.png", currentTheme.Location, currentTheme.Id);
                var zonePreviewImage = _virtualPathProvider.FileExists(zonePreviewImagePath) ? zonePreviewImagePath : null;

                var layer = _widgetsService.GetLayers().First();

                // recupero i contenuti localizzati una try è necessaria in quanto non è detto che un contenuto sia localizzato
                dynamic contentLocalizations;
                try {
                    contentLocalizations = _localizationService
                                           .GetLocalizations(part.ContentItem, VersionOptions.Latest) //the other cultures
                                           .Where(lp =>                                               //as long as a culture has been assigned
                                                  lp.Culture != null && !string.IsNullOrWhiteSpace(lp.Culture.Culture))
                                           .OrderBy(o => o.Culture.Culture)
                                           .ToList();
                } catch {
                    contentLocalizations = null;
                }

                var viewModel = New.ViewModel()
                                .CurrentTheme(currentTheme)
                                .Zones(currentThemesZones)
                                .ContentLocalizations(contentLocalizations)
                                .ZonePreviewImage(zonePreviewImage)
                                .WidgetTypes(widgetTypes)
                                .Widgets(widgets)
                                .ContentItem(part.ContentItem)
                                .LayerId(layer.Id)
                                .CloneFrom(0);

                return shapeHelper.EditorTemplate(TemplateName: "Parts.WidgetsContainer", Model: viewModel, Prefix: Prefix);
            }));
        }
Beispiel #6
0
        public void OnResultExecuting(ResultExecutingContext filterContext)
        {
            // ignore filter on admin pages
            if (AdminFilter.IsApplied(filterContext.RequestContext))
            {
                return;
            }

            // should only run on a full view rendering result
            if (!(filterContext.Result is ViewResult))
            {
                return;
            }

            var settings = _settingsService.GetSettings();

            if (String.IsNullOrEmpty(settings.Swatch))
            {
                return;
            }

            var themeName = _siteThemeService.GetSiteTheme();

            if (themeName.Name == Constants.ThemeName)
            {
                var viewResult = filterContext.Result as ViewResult;
                if (viewResult == null)
                {
                    return;
                }

                if (settings.UseFixedNav)
                {
                    /* TODO: Replace note use Items collection */
                    System.Web.HttpContext.Current.Items[Constants.UseFixedNav] = settings.UseFixedNav.ToString();
                }
                if (settings.UseNavSearch)
                {
                    /* TODO: Replace note use Items collection */
                    System.Web.HttpContext.Current.Items[Constants.UseNavSearch] = settings.UseNavSearch.ToString();
                }
                if (settings.UseFluidLayout)
                {
                    /* TODO: Replace note use Items collection */
                    System.Web.HttpContext.Current.Items[Constants.UseFluidLayout] = settings.UseFluidLayout.ToString();
                }
                if (settings.UseInverseNav)
                {
                    /* TODO: Replace note use Items collection */
                    System.Web.HttpContext.Current.Items[Constants.UseInverseNav] = settings.UseInverseNav.ToString();
                }
                if (settings.UseStickyFooter)
                {
                    /* TODO: Replace note use Items collection */
                    System.Web.HttpContext.Current.Items[Constants.UseStickyFooter] = settings.UseStickyFooter.ToString();
                }
            }
        }
        public void GetNavigation(NavigationBuilder builder)
        {
            var themeName = _siteThemeService.GetSiteTheme();

            if (themeName.Name == Constants.THEME_NAME)
            {
                builder.Add(T("Themes"), "10", BuildMenu);
            }
        }
Beispiel #8
0
        protected string GetThemePath()
        {
            // get current frontend theme
            var theme = _siteThemeService.GetSiteTheme();
            // find the Styles/Skins folder for the theme
            var basePath = PathCombine(theme.Location, theme.Id);

            return(basePath);
        }
        public IList <string> GetDisplayPluginsFor(Enums.DisplayTemplate displayTemplate)
        {
            ThemeEntry          currentTheme           = null;
            ExtensionDescriptor currentThemeDescriptor = _siteThemeService.GetSiteTheme();

            if (currentThemeDescriptor != null)
            {
                currentTheme = new ThemeEntry(currentThemeDescriptor);
            }
            System.Configuration.Configuration config;
            try {
                config = _localConfiguration.GetConfiguration(currentTheme.Descriptor.Path.StartsWith("~/Themes/") ? currentTheme.Descriptor.Path : "" + "~/Themes/" + currentTheme.Descriptor.Path);
                return(config.AppSettings.Settings["DisplayPluginsFor" + displayTemplate.ToString()].Value.Split(new string[] { ",", ";", "|" }, StringSplitOptions.RemoveEmptyEntries)
                       .Select(s => displayTemplate + " - " + s.Trim()).ToList());
            } catch {
                return(null);
            } finally {
                config = null;
            }
        }
        public void GetNavigation(NavigationBuilder builder)
        {
            var themeName = _siteThemeService.GetSiteTheme();

            if (themeName.Name == Constants.ThemeName)
            {
                builder.Add(T("Themes"),
                            menu => menu
                            .Add(T("Theme Options"), "1.0", item => item.Action("Index", "Admin", new { area = Constants.RoutesAreaName }).LocalNav())
                            );
            }
        }
Beispiel #11
0
        private bool IsBootstrapThemeOrBasedOnBootstrapTheme()
        {
            var theme = _siteThemeService.GetSiteTheme();

            if (theme.Name == Constants.ThemeName || theme.BaseTheme == Constants.ThemeName)
            {
                return(true);
            }
            if (theme.Name.Contains(Constants.ThemeName)) //Should find a way I could recursivly check if Bootstrap is the base theme.
            {
                return(true);
            }
            return(false);
        }
Beispiel #12
0
        public ActionResult Index(int?layerId)
        {
            ExtensionDescriptor currentTheme = _siteThemeService.GetSiteTheme();

            if (currentTheme == null)
            {
                Services.Notifier.Error(T("To manage widgets you must have a theme enabled."));
                return(RedirectToAction("Index", "Admin", new { area = "Dashboard" }));
            }

            IEnumerable <LayerPart> layers = _widgetsService.GetLayers().ToList();

            if (!layers.Any())
            {
                Services.Notifier.Error(T("There are no widget layers defined. A layer will need to be added in order to add widgets to any part of the site."));
                return(RedirectToAction("AddLayer"));
            }

            LayerPart currentLayer = layerId == null
                ? layers.FirstOrDefault()
                : layers.FirstOrDefault(layer => layer.Id == layerId);

            if (currentLayer == null && layerId != null)   // Incorrect layer id passed
            {
                Services.Notifier.Error(T("Layer not found: {0}", layerId));
                return(RedirectToAction("Index"));
            }

            IEnumerable <string> allZones           = _widgetsService.GetZones();
            IEnumerable <string> currentThemesZones = _widgetsService.GetZones(currentTheme);

            string zonePreviewImagePath = string.Format("{0}/{1}/ThemeZonePreview.png", currentTheme.Location, currentTheme.Id);
            string zonePreviewImage     = _virtualPathProvider.FileExists(zonePreviewImagePath) ? zonePreviewImagePath : null;

            dynamic viewModel = Shape.ViewModel()
                                .CurrentTheme(currentTheme)
                                .CurrentLayer(currentLayer)
                                .Layers(layers)
                                .Widgets(_widgetsService.GetWidgets())
                                .Zones(currentThemesZones)
                                .OrphanZones(allZones.Except(currentThemesZones))
                                .OrphanWidgets(_widgetsService.GetOrphanedWidgets())
                                .ZonePreviewImage(zonePreviewImage);

            // Casting to avoid invalid (under medium trust) reflection over the protected View method and force a static invocation.
            return(View((object)viewModel));
        }
        private void BindPlacement(BuildShapeContext context, string displayType, string stereotype)
        {
            context.FindPlacement = (partShapeType, differentiator, defaultLocation) => {
                var theme      = SiteThemeService.GetSiteTheme();
                var shapeTable = ShapeTableLocator.Lookup(theme.Id);

                var request = RequestContext.HttpContext.Request;

                ShapeDescriptor descriptor;
                if (shapeTable.Descriptors.TryGetValue(partShapeType, out descriptor))
                {
                    var placementContext = new ShapePlacementContext
                    {
                        Content        = context.ContentItem,
                        ContentType    = context.ContentItem.ContentType,
                        Stereotype     = stereotype,
                        DisplayType    = displayType,
                        Differentiator = differentiator,
                        Path           = VirtualPathUtility.AppendTrailingSlash(VirtualPathProvider.ToAppRelative(request.Path)) // get the current app-relative path, i.e. ~/my-blog/foo
                    };

                    // define which location should be used if none placement is hit
                    descriptor.DefaultPlacement = defaultLocation;

                    var placement = descriptor.Placement(placementContext);
                    if (placement != null)
                    {
                        placement.Source = placementContext.Source;
                        return(placement);
                    }
                }

                return(new PlacementInfo
                {
                    Location = defaultLocation,
                    Source = String.Empty
                });
            };
        }
Beispiel #14
0
        public void OnResultExecuting(ResultExecutingContext filterContext)
        {
            // ignore filter on admin pages
            if (AdminFilter.IsApplied(filterContext.RequestContext))
            {
                return;
            }

            // should only run on a full view rendering result
            if (!(filterContext.Result is ViewResult))
            {
                return;
            }

            var settings = _settingsService.GetSettings();

            if (String.IsNullOrEmpty(settings.AccentCss))
            {
                return;
            }

            var themeName = _siteThemeService.GetSiteTheme();

            if (themeName.Name == Constants.THEME_NAME)
            {
                var viewResult = filterContext.Result as ViewResult;
                if (viewResult == null)
                {
                    return;
                }

                if (settings.UseBranding)
                {
                    /* TODO: Replace note use Items collection */
                    System.Web.HttpContext.Current.Items[Constants.ITEM_USE_BRANDING] = settings.UseBranding.ToString();
                    System.Web.HttpContext.Current.Items[Constants.ITEM_TAGLINE]      = settings.Tagline;
                }
            }
        }
        public void List()
        {
            var currentTheme           = _siteThemeService.GetSiteTheme();
            var featuresThatNeedUpdate = _dataMigrationManager.GetFeaturesThatNeedUpdate();

            var themes = _extensionManager.AvailableExtensions()
                         .Where(d => DefaultExtensionTypes.IsTheme(d.ExtensionType))
                         .Where(d => d.Tags != null && d.Tags.Split(',').Any(t => t.Trim().Equals("hidden", StringComparison.OrdinalIgnoreCase)) == false)
                         .Select(d => new ThemeEntry {
                Descriptor  = d,
                NeedsUpdate = featuresThatNeedUpdate.Contains(d.Id),
                Enabled     = _shellDescriptor.Features.Any(sf => sf.Name == d.Id)
            })
                         .ToArray();

            if (Summary)
            {
                foreach (var theme in themes)
                {
                    Context.Output.WriteLine(T("{0}", theme.Name));
                }
            }
            else
            {
                Context.Output.WriteLine(T("Current theme"));
                Context.Output.WriteLine(T("--------------------------"));
                WriteThemeLines(new ThemeEntry {
                    Descriptor  = currentTheme,
                    NeedsUpdate = featuresThatNeedUpdate.Contains(currentTheme.Id),
                    Enabled     = _shellDescriptor.Features.Any(sf => sf.Name == currentTheme.Id)
                });

                Context.Output.WriteLine(T("List of available themes"));
                Context.Output.WriteLine(T("--------------------------"));
                themes.Where(t => t.Name.Trim().Equals(currentTheme.Name.Trim(), StringComparison.OrdinalIgnoreCase) == false)
                .ToList()
                .ForEach(WriteThemeLines);
            }
        }
Beispiel #16
0
        protected override DriverResult Editor(WidgetsContainerPart part, dynamic shapeHelper)
        {
            return(ContentShape("Parts_WidgetsContainer", () => {
                var currentTheme = _siteThemeService.GetSiteTheme();
                var currentThemesZones = _widgetsService.GetZones(currentTheme).ToList();
                var widgetTypes = _widgetsService.GetWidgetTypeNames().ToList();
                var widgets = _widgetManager.GetWidgets(part.Id, VersionOptions.Latest);
                var zonePreviewImagePath = string.Format("{0}/{1}/ThemeZonePreview.png", currentTheme.Location, currentTheme.Id);
                var zonePreviewImage = _virtualPathProvider.FileExists(zonePreviewImagePath) ? zonePreviewImagePath : null;
                var layer = _widgetsService.GetLayers().First();

                var viewModel = New.ViewModel()
                                .CurrentTheme(currentTheme)
                                .Zones(currentThemesZones)
                                .ZonePreviewImage(zonePreviewImage)
                                .WidgetTypes(widgetTypes)
                                .Widgets(widgets)
                                .ContentItem(part.ContentItem)
                                .LayerId(layer.Id);

                return shapeHelper.EditorTemplate(TemplateName: "Parts.WidgetsContainer", Model: viewModel, Prefix: Prefix);
            }));
        }
        public override IEnumerable <TemplateViewModel> TypePartEditor(ContentTypePartDefinition definition)
        {
            if (definition.PartDefinition.Name == "WidgetsContainerPart")
            {
                var model = definition.Settings.GetModel <WidgetsContainerSettings>();

                var currentTheme = _siteThemeService.GetSiteTheme();

                var allowedViewModel = new WidgetsContainerSettingsViewModel();
                allowedViewModel.SelectedZones = model.AllowedZones != null?model.AllowedZones.Split(',') : new string[]
                {
                };
                allowedViewModel.Zones           = _widgetsService.GetZones(currentTheme).ToList();
                allowedViewModel.SelectedWidgets = model.AllowedWidgets != null?model.AllowedWidgets.Split(',') : new string[]
                {
                };
                allowedViewModel.Widgets = _widgetsService.GetWidgetTypeNames().OrderBy(o => o).ToList();
                allowedViewModel.UseHierarchicalAssociation  = model.UseHierarchicalAssociation;
                allowedViewModel.HierarchicalAssociationJson = model.HierarchicalAssociationJson;

                yield return(DefinitionTemplate(allowedViewModel));
            }
        }
Beispiel #18
0
        public IEnumerable <string> GetLayouts()
        {
            var theme = _siteThemeService.GetSiteTheme();

            return(ExtractLayoutNames(theme));
        }
        public ActionResult Index(int?layerId, string culture)
        {
            ExtensionDescriptor currentTheme = _siteThemeService.GetSiteTheme();

            if (currentTheme == null)
            {
                Services.Notifier.Error(T("To manage widgets you must have a theme enabled."));
                return(RedirectToAction("Index", "Admin", new { area = "Dashboard" }));
            }

            IEnumerable <LayerPart> layers = _widgetsService.GetLayers().OrderBy(x => x.Name).ToList();

            if (!layers.Any())
            {
                Services.Notifier.Error(T("There are no widget layers defined. A layer will need to be added in order to add widgets to any part of the site."));
                return(RedirectToAction("AddLayer"));
            }

            LayerPart currentLayer = layerId == null
                                     // look for the "Default" layer, or take the first if it doesn't exist
                ? layers.FirstOrDefault(x => x.Name == "Default") ?? layers.FirstOrDefault()
                : layers.FirstOrDefault(layer => layer.Id == layerId);

            if (currentLayer == null && layerId != null)   // Incorrect layer id passed
            {
                Services.Notifier.Error(T("Layer not found: {0}", layerId));
                return(RedirectToAction("Index"));
            }

            IEnumerable <string> allZones           = _widgetsService.GetZones();
            IEnumerable <string> currentThemesZones = _widgetsService.GetZones(currentTheme);

            string zonePreviewImagePath = string.Format("{0}/{1}/ThemeZonePreview.png", currentTheme.Location, currentTheme.Id);
            string zonePreviewImage     = _virtualPathProvider.FileExists(zonePreviewImagePath) ? zonePreviewImagePath : null;

            var widgets = _widgetsService.GetWidgets();

            if (!String.IsNullOrWhiteSpace(culture))
            {
                widgets = widgets.Where(x => {
                    if (x.Has <ILocalizableAspect>())
                    {
                        return(String.Equals(x.As <ILocalizableAspect>().Culture, culture, StringComparison.InvariantCultureIgnoreCase));
                    }

                    return(false);
                }).ToList();
            }

            var viewModel = Shape.ViewModel()
                            .CurrentTheme(currentTheme)
                            .CurrentLayer(currentLayer)
                            .CurrentCulture(culture)
                            .Layers(layers)
                            .Widgets(widgets)
                            .Zones(currentThemesZones)
                            .Cultures(_cultureManager.ListCultures())
                            .OrphanZones(allZones.Except(currentThemesZones))
                            .OrphanWidgets(_widgetsService.GetOrphanedWidgets())
                            .ZonePreviewImage(zonePreviewImage);

            return(View(viewModel));
        }
Beispiel #20
0
        public ActionResult Index()
        {
            bool installThemes =
                _featureManager.GetEnabledFeatures().FirstOrDefault(f => f.Id == "PackagingServices") != null &&
                Services.Authorizer.Authorize(StandardPermissions.SiteOwner) && // only site owners
                _shellSettings.Name == ShellSettings.DefaultName;    // of the default tenant

            var featuresThatNeedUpdate = _dataMigrationManager.GetFeaturesThatNeedUpdate();

            ThemeEntry          currentTheme           = null;
            ExtensionDescriptor currentThemeDescriptor = _siteThemeService.GetSiteTheme();

            if (currentThemeDescriptor != null)
            {
                currentTheme = new ThemeEntry(currentThemeDescriptor);
            }

            IEnumerable <ThemeEntry> themes = _extensionManager.AvailableExtensions()
                                              .Where(extensionDescriptor => {
                bool hidden = false;
                string tags = extensionDescriptor.Tags;
                if (tags != null)
                {
                    hidden = tags.Split(',').Any(t => t.Trim().Equals("hidden", StringComparison.OrdinalIgnoreCase));
                }

                // is the theme allowed for this tenant ?
                bool allowed = _shellSettings.Themes.Length == 0 || _shellSettings.Themes.Contains(extensionDescriptor.Id);

                return(!hidden && allowed &&
                       DefaultExtensionTypes.IsTheme(extensionDescriptor.ExtensionType) &&
                       (currentTheme == null ||
                        !currentTheme.Descriptor.Id.Equals(extensionDescriptor.Id)));
            })
                                              .Select(extensionDescriptor => {
                ThemeEntry themeEntry = new ThemeEntry(extensionDescriptor)
                {
                    NeedsUpdate         = featuresThatNeedUpdate.Contains(extensionDescriptor.Id),
                    IsRecentlyInstalled = _themeService.IsRecentlyInstalled(extensionDescriptor),
                    Enabled             = _shellDescriptor.Features.Any(sf => sf.Name == extensionDescriptor.Id),
                    CanUninstall        = installThemes
                };

                if (_extensionDisplayEventHandler != null)
                {
                    foreach (string notification in _extensionDisplayEventHandler.Displaying(themeEntry.Descriptor, ControllerContext.RequestContext))
                    {
                        themeEntry.Notifications.Add(notification);
                    }
                }

                return(themeEntry);
            })
                                              .ToArray();

            return(View(new ThemesIndexViewModel {
                CurrentTheme = currentTheme,
                InstallThemes = installThemes,
                Themes = themes
            }));
        }