reformat and store darkmode setting correct in db
This commit is contained in:
parent
8c4b1a836a
commit
827fd6a1b2
@ -29,13 +29,15 @@ if (isset($_POST['action'])) {
|
|||||||
$videopath = $_POST['videopath'];
|
$videopath = $_POST['videopath'];
|
||||||
$tvshowpath = $_POST['tvshowpath'];
|
$tvshowpath = $_POST['tvshowpath'];
|
||||||
$tmdbsupport = $_POST['tmdbsupport'];
|
$tmdbsupport = $_POST['tmdbsupport'];
|
||||||
|
$darkmodeenabled = $_POST['darkmodeenabled'];
|
||||||
|
|
||||||
$query = "UPDATE settings SET
|
$query = "UPDATE settings SET
|
||||||
video_path='$videopath',
|
video_path='$videopath',
|
||||||
episode_path='$tvshowpath',
|
episode_path='$tvshowpath',
|
||||||
password='$password',
|
password='$password',
|
||||||
mediacenter_name='$mediacentername',
|
mediacenter_name='$mediacentername',
|
||||||
TMDB_grabbing=$tmdbsupport
|
TMDB_grabbing=$tmdbsupport,
|
||||||
|
DarkMode=$darkmodeenabled
|
||||||
WHERE 1";
|
WHERE 1";
|
||||||
|
|
||||||
if ($conn->query($query) === true) {
|
if ($conn->query($query) === true) {
|
||||||
|
@ -2,15 +2,15 @@
|
|||||||
* The coloring elements for dark theme
|
* The coloring elements for dark theme
|
||||||
*/
|
*/
|
||||||
|
|
||||||
.backgroundcolor{
|
.backgroundcolor {
|
||||||
background-color: #141520;
|
background-color: #141520;
|
||||||
}
|
}
|
||||||
|
|
||||||
.textcolor{
|
.textcolor {
|
||||||
color: white;
|
color: white;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subtextcolor{
|
.subtextcolor {
|
||||||
color: #dedad6;
|
color: #dedad6;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -18,11 +18,11 @@
|
|||||||
background: white;
|
background: white;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hrcolor{
|
.hrcolor {
|
||||||
border-color: rgba(255,255,255,.1);
|
border-color: rgba(255, 255, 255, .1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.previewhover:hover{
|
.previewhover:hover {
|
||||||
box-shadow: rgba(255, 255, 255, 0.7) 0 0 0 5px;
|
box-shadow: rgba(255, 255, 255, 0.7) 0 0 0 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -130,6 +130,7 @@ class GeneralSettings extends React.Component {
|
|||||||
updateRequest.append('tvshowpath', this.state.tvshowpath);
|
updateRequest.append('tvshowpath', this.state.tvshowpath);
|
||||||
updateRequest.append('mediacentername', this.state.mediacentername);
|
updateRequest.append('mediacentername', this.state.mediacentername);
|
||||||
updateRequest.append("tmdbsupport", this.state.tmdbsupport);
|
updateRequest.append("tmdbsupport", this.state.tmdbsupport);
|
||||||
|
updateRequest.append("darkmodeenabled", StaticInfos.isDarkTheme());
|
||||||
|
|
||||||
fetch('/api/Settings.php', {method: 'POST', body: updateRequest})
|
fetch('/api/Settings.php', {method: 'POST', body: updateRequest})
|
||||||
.then((response) => response.json()
|
.then((response) => response.json()
|
||||||
|
Loading…
Reference in New Issue
Block a user