mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-11-10 04:41:26 +01:00
Fixed a bug with the theme
This commit is contained in:
parent
8dd7d9615f
commit
0a5eda1fc8
@ -73,12 +73,15 @@ public class Theme {
|
|||||||
if (Verify.equalsOne(value, defaultValue)) {
|
if (Verify.equalsOne(value, defaultValue)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!value.contains("url")) {
|
if (value.contains("url")) {
|
||||||
replaced = replaced.replace(defaultValue, value);
|
|
||||||
} else {
|
|
||||||
String[] colorAndUrl = value.split(" ");
|
String[] colorAndUrl = value.split(" ");
|
||||||
replaced = replaced.replace("background: " + defaultValue, "background: " + colorAndUrl[1]);
|
if (colorAndUrl.length >= 2) {
|
||||||
replaced = replaced.replace(defaultValue, colorAndUrl[0]);
|
replaced = replaced.replace("background: " + defaultValue, "background: " + colorAndUrl[1]);
|
||||||
|
replaced = replaced.replace(defaultValue, colorAndUrl[0]);
|
||||||
|
return replaced;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
replaced = replaced.replace(defaultValue, value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return replaced;
|
return replaced;
|
||||||
|
@ -28,7 +28,7 @@ public enum ThemeVal {
|
|||||||
GREEN("Colors.green", "#4CAF50"),
|
GREEN("Colors.green", "#4CAF50"),
|
||||||
LIGHT_GREEN("Colors.light-green", "#8BC34A"),
|
LIGHT_GREEN("Colors.light-green", "#8BC34A"),
|
||||||
LIME("Colors.lime", "#CDDC39"),
|
LIME("Colors.lime", "#CDDC39"),
|
||||||
YELLOW("Colors.yellow", "#FFEB3B"),
|
YELLOW("Colors.yellow", "#ffe821"),
|
||||||
AMBER("Colors.amber", "#FFC107"),
|
AMBER("Colors.amber", "#FFC107"),
|
||||||
ORANGE("Colors.orange", "#FF9800"),
|
ORANGE("Colors.orange", "#FF9800"),
|
||||||
DEEP_ORANGE("Colors.deep-orange", "#FF5722"),
|
DEEP_ORANGE("Colors.deep-orange", "#FF5722"),
|
||||||
|
@ -22,7 +22,7 @@ Colors:
|
|||||||
green: "#4CAF50"
|
green: "#4CAF50"
|
||||||
light-green: "#8BC34A"
|
light-green: "#8BC34A"
|
||||||
lime: "#CDDC39"
|
lime: "#CDDC39"
|
||||||
yellow: "#FFEB3B"
|
yellow: "#ffe821"
|
||||||
amber: "#FFC107"
|
amber: "#FFC107"
|
||||||
orange: "#FF9800"
|
orange: "#FF9800"
|
||||||
deep-orange: "#FF5722"
|
deep-orange: "#FF5722"
|
||||||
|
Loading…
Reference in New Issue
Block a user