diff --git a/CSS/theme-options/organizr-dark.css b/CSS/theme-options/organizr-dark.css
deleted file mode 100644
index e4935c9c..00000000
--- a/CSS/theme-options/organizr-dark.css
+++ /dev/null
@@ -1 +0,0 @@
-@import url("https://develop.theme-park.dev/CSS/variables/organizr.css");
\ No newline at end of file
diff --git a/Resources/landing-page/assets/img/organizr-dark-small.jpg b/Resources/landing-page/assets/img/organizr-small.jpg
similarity index 100%
rename from Resources/landing-page/assets/img/organizr-dark-small.jpg
rename to Resources/landing-page/assets/img/organizr-small.jpg
diff --git a/Resources/landing-page/assets/img/organizr-dark.png b/Resources/landing-page/assets/img/organizr.png
similarity index 100%
rename from Resources/landing-page/assets/img/organizr-dark.png
rename to Resources/landing-page/assets/img/organizr.png
diff --git a/Resources/landing-page/assets/img/overseer-small.jpg b/Resources/landing-page/assets/img/overseerr-small.jpg
similarity index 100%
rename from Resources/landing-page/assets/img/overseer-small.jpg
rename to Resources/landing-page/assets/img/overseerr-small.jpg
diff --git a/Resources/landing-page/assets/img/overseer.png b/Resources/landing-page/assets/img/overseerr.png
similarity index 100%
rename from Resources/landing-page/assets/img/overseer.png
rename to Resources/landing-page/assets/img/overseerr.png
diff --git a/Resources/landing-page/css/custom.css b/Resources/landing-page/css/custom.css
index d651b934..5c27e48b 100644
--- a/Resources/landing-page/css/custom.css
+++ b/Resources/landing-page/css/custom.css
@@ -348,7 +348,7 @@ p {
background: radial-gradient(ellipse at center, rgba(87, 108, 117, 1) 0%, rgba(37, 50, 55, 1) 100.2%);
}
-#portfolio [class*="container-"] .portfolio-box .portfolio-box-caption.organizr-dark-hover {
+#portfolio [class*="container-"] .portfolio-box .portfolio-box-caption.organizr-hover {
background: #1f1f1f;
}
@@ -364,7 +364,7 @@ p {
background: #282a36;
}
-#portfolio [class*="container-"] .portfolio-box .portfolio-box-caption.overseer-hover {
+#portfolio [class*="container-"] .portfolio-box .portfolio-box-caption.overseerr-hover {
background: linear-gradient(360deg, hsl(221, 39%, 11%) 65%, hsl(215, 28%, 17%) 100%);
}
diff --git a/Resources/landing-page/js/scripts.js b/Resources/landing-page/js/scripts.js
index 11d9b26a..5295df0e 100644
--- a/Resources/landing-page/js/scripts.js
+++ b/Resources/landing-page/js/scripts.js
@@ -6,29 +6,6 @@
(function ($) {
"use strict"; // Start of use strict
- // Smooth scrolling using anime.js
- $('a.js-scroll-trigger[href*="#"]:not([href="#"])').on('click', function () {
- if (
- location.pathname.replace(/^\//, "") ==
- this.pathname.replace(/^\//, "") &&
- location.hostname == this.hostname
- ) {
- var target = $(this.hash);
- target = target.length ?
- target :
- $("[name=" + this.hash.slice(1) + "]");
- if (target.length) {
- anime({
- targets: 'html, body',
- scrollTop: target.offset().top - 72,
- duration: 1000,
- easing: 'easeInOutExpo'
- });
- return false;
- }
- }
- });
-
// Closes responsive menu when a scroll trigger link is clicked
$('.js-scroll-trigger').click(function () {
$('.navbar-collapse').collapse('hide');
@@ -71,17 +48,14 @@
})(jQuery); // End of use strict
-const themes = ["aquamarine","hotline","dark","organizr-dark","dracula","overseerr",
-"plex","space-gray","hotpink","onedark","nord"];
-var random = themes[~~(Math.random() * themes.length)];
-// load a random css stylesheet
+
function injectTheme(theme,container="head") {
if (container === "head") {
html_element = document.head;
} else html_element = document.body;
let themeOption = document.getElementById("theme-option")
let link = themeOption ? themeOption : document.createElement("link");
- url = "/CSS/variables/"
+ url = "/CSS/theme-options/"
link.type = "text/css";
link.rel = "stylesheet";
link.href = `${url}/${theme.toLowerCase()}.css`;
@@ -92,6 +66,7 @@ function injectTheme(theme,container="head") {
// Add theme data and set theme vars
var apps;
var themeOptions;
+
function addThemeData() {
let themeJsonUrl = "/themes.json"
fetch(themeJsonUrl)
@@ -105,27 +80,45 @@ function injectTheme(theme,container="head") {
document.getElementById("app-count").innerHTML = `
theme.park contains ${appCount} themed applications, with css addons on certain themes.`
- document.getElementById("theme-count").innerHTML = `Choose between ${Object.keys(json.themes).length} different
- styles! With the possibility to easily create your own themes using the defined ${Object.keys(json.themes).length} official
+ styles, and ${Object.keys(json["community-themes"]).length} community styles! With the possibility to easily create your own themes using the defined variables.`
- createApps(apps)
+ createApps(apps,themeOptions)
+ smoothScroll()
+ let randomTheme = Object.keys(themeOptions)[~~(Math.random() * Object.keys(themeOptions).length)]
+ injectTheme(randomTheme)
})
}
-function createApps(apps) {
+function createApps(apps,themeOptions) {
let allAppsDiv = document.getElementById("all-apps")
- sorted = Object.keys(apps).sort()
- for (let app in sorted) {
+ let allThemesDiv = document.getElementById("all-themes")
+ sortedApps = Object.keys(apps).sort()
+ sortedThemes = Object.keys(themeOptions).sort()
+ for (let app in sortedApps) {
let newApp = `
-
-
- ${sorted[app][0].toUpperCase() + sorted[app].slice(1)} ${sortedApps[app][0].toUpperCase() + sortedApps[app].slice(1)}