Fix mobile layout: Sprachauswahl überlappt nicht mehr mit Überschrift und korrigiere URL-Parameter für Sprachwechsel
This commit is contained in:
2
app.py
2
app.py
@@ -20,7 +20,7 @@ app.config['BABEL_TRANSLATION_DIRECTORIES'] = 'translations'
|
|||||||
babel = Babel()
|
babel = Babel()
|
||||||
|
|
||||||
# Version der App
|
# Version der App
|
||||||
APP_VERSION = "1.4.2"
|
APP_VERSION = "1.4.3"
|
||||||
|
|
||||||
# HTML-Template wird jetzt aus templates/index.html geladen
|
# HTML-Template wird jetzt aus templates/index.html geladen
|
||||||
|
|
||||||
|
@@ -475,6 +475,7 @@ button:focus, .accordion-header:focus {
|
|||||||
}
|
}
|
||||||
h1 {
|
h1 {
|
||||||
font-size: 1.3em;
|
font-size: 1.3em;
|
||||||
|
margin-top: 3.5em; /* Abstand für Sprachauswahl */
|
||||||
}
|
}
|
||||||
.help-button-container {
|
.help-button-container {
|
||||||
top: 1em;
|
top: 1em;
|
||||||
@@ -618,7 +619,11 @@ footer br + a {
|
|||||||
function changeLanguage(language) {
|
function changeLanguage(language) {
|
||||||
// Speichere Sprache in localStorage (datenschutzfreundlich)
|
// Speichere Sprache in localStorage (datenschutzfreundlich)
|
||||||
localStorage.setItem('preferred_language', language);
|
localStorage.setItem('preferred_language', language);
|
||||||
window.location.href = '/set_language/' + language;
|
|
||||||
|
// Erstelle neue URL mit korrektem lang-Parameter
|
||||||
|
const currentUrl = new URL(window.location.href);
|
||||||
|
currentUrl.searchParams.set('lang', language);
|
||||||
|
window.location.href = currentUrl.toString();
|
||||||
}
|
}
|
||||||
function openAccordion(idx) {
|
function openAccordion(idx) {
|
||||||
const headers = document.querySelectorAll('.accordion-header');
|
const headers = document.querySelectorAll('.accordion-header');
|
||||||
|
Reference in New Issue
Block a user