Fix superflous header, other minor bugs

This commit is contained in:
Mukhtar Akere
2025-07-21 20:35:49 +01:00
parent afe577bf2f
commit 3d2fcf5656
6 changed files with 47 additions and 6 deletions

View File

@@ -25,4 +25,5 @@ node_modules/
# Build artifacts
decypharr
healthcheck
*.exe
*.exe
.venv/

3
.gitignore vendored
View File

@@ -14,4 +14,5 @@ logs/**
auth.json
.ven/
.env
node_modules/
node_modules/
.venv/

View File

@@ -19,6 +19,7 @@ func (q *QBit) handleLogin(w http.ResponseWriter, r *http.Request) {
if err := _arr.Validate(); err != nil {
q.logger.Error().Err(err).Msgf("Error validating arr")
http.Error(w, "Invalid arr configuration", http.StatusBadRequest)
return
}
_, _ = w.Write([]byte("Ok."))
}

File diff suppressed because one or more lines are too long

View File

@@ -405,10 +405,46 @@
box-shadow: 0 0 0 2px hsl(var(--p) / 0.2);
}
/* Select options */
/* Select options - Enhanced dark mode support */
[data-theme="dark"] .select option {
background-color: hsl(var(--b1));
color: #ffffff;
background-color: hsl(var(--b1)) !important;
color: #ffffff !important;
}
/* Force dark styling for select dropdowns even when OS is in light mode */
[data-theme="dark"] .select {
color-scheme: dark !important;
}
/* Additional browser-specific overrides for select options */
[data-theme="dark"] select option {
background-color: hsl(var(--b1)) !important;
color: #ffffff !important;
border: none !important;
}
[data-theme="dark"] select optgroup {
background-color: hsl(var(--b1)) !important;
color: #ffffff !important;
}
/* WebKit-specific styling for select dropdown */
[data-theme="dark"] select::-webkit-scrollbar {
width: 8px;
background-color: hsl(var(--b2));
}
[data-theme="dark"] select::-webkit-scrollbar-thumb {
background-color: hsl(var(--bc) / 0.3);
border-radius: 4px;
}
/* Firefox-specific select styling */
@-moz-document url-prefix() {
[data-theme="dark"] select option {
background-color: hsl(var(--b1)) !important;
color: #ffffff !important;
}
}
/* Disabled inputs */

View File

@@ -474,6 +474,7 @@ func (h *Handler) handleGet(w http.ResponseWriter, r *http.Request) {
if streamErr.StatusCode > 0 && !hasHeadersWritten(w) {
http.Error(w, streamErr.Error(), streamErr.StatusCode)
return
} else {
h.logger.Error().
Err(streamErr.Err).
@@ -484,6 +485,7 @@ func (h *Handler) handleGet(w http.ResponseWriter, r *http.Request) {
// Generic error
if !hasHeadersWritten(w) {
http.Error(w, "Stream error", http.StatusInternalServerError)
return
} else {
h.logger.Error().
Err(err).