forked from rDrama/rDrama
fds
parent
c447af6f50
commit
be49ed862f
|
@ -289,7 +289,7 @@ def settings_profile_post(v):
|
||||||
|
|
||||||
theme = request.values.get("theme")
|
theme = request.values.get("theme")
|
||||||
if theme:
|
if theme:
|
||||||
if theme in {"dramblr", "classic", "classic_dark", "transparent", "win98", "dark", "light", "coffee", "tron", "4chan", "midnight"}:
|
if theme in {"dramblr", "reddit", "reddit_dark", "classic", "classic_dark", "transparent", "win98", "dark", "light", "coffee", "tron", "4chan", "midnight"}:
|
||||||
if theme == "transparent" and not v.background:
|
if theme == "transparent" and not v.background:
|
||||||
return {"error": "You need to set a background to use the transparent theme!"}
|
return {"error": "You need to set a background to use the transparent theme!"}
|
||||||
v.theme = theme
|
v.theme = theme
|
||||||
|
|
|
@ -128,7 +128,14 @@
|
||||||
<p>Change the theme for the website.</p>
|
<p>Change the theme for the website.</p>
|
||||||
<div class="input-group mb2">
|
<div class="input-group mb2">
|
||||||
<select autocomplete="off" id='theme' class="form-control" form="profile-settings" name="theme" onchange="post_toast(this,'/settings/profile?theme='+document.getElementById('theme').value, '1')">
|
<select autocomplete="off" id='theme' class="form-control" form="profile-settings" name="theme" onchange="post_toast(this,'/settings/profile?theme='+document.getElementById('theme').value, '1')">
|
||||||
{% for entry in ["dramblr", "classic", "classic_dark", "transparent", "win98", "dark", "light", "coffee", "tron", "4chan", "midnight"] %}
|
|
||||||
|
{% if SITE_NAME == 'rDrama' %}
|
||||||
|
{% set themes = ["dramblr", "classic", "classic_dark", "transparent", "win98", "dark", "light", "coffee", "tron", "4chan", "midnight"] %}
|
||||||
|
{% else %}
|
||||||
|
{% set themes = ["dramblr", "reddit", "reddit_dark", "transparent", "win98", "dark", "light", "coffee", "tron", "4chan", "midnight"] %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% for entry in themes %}
|
||||||
<option value="{{entry}}" {% if v.theme==entry %} selected {% endif %}>
|
<option value="{{entry}}" {% if v.theme==entry %} selected {% endif %}>
|
||||||
{{entry}}
|
{{entry}}
|
||||||
</option>
|
</option>
|
||||||
|
|
Loading…
Reference in New Issue