Spaces:
Running
Running
GitHub Action
commited on
Commit
·
00973ce
1
Parent(s):
367ef98
Sync ling-space changes from GitHub commit fb5b9aa
Browse files- static/app.html +1 -5
static/app.html
CHANGED
|
@@ -26,14 +26,10 @@
|
|
| 26 |
console.log(`[I18n] Language set to: ${lang}`);
|
| 27 |
|
| 28 |
if (reload) {
|
| 29 |
-
// If we are in an iframe, we want to change the top-level URL
|
| 30 |
-
// Otherwise, just change the current window URL. using window.top
|
| 31 |
-
const isInIframe = window.self !== window.top;
|
| 32 |
-
const targetWindow = isInIframe ? window.top : window;
|
| 33 |
// Update URL to reflect language or just reload
|
| 34 |
const url = new URL(window.location);
|
| 35 |
url.searchParams.set(SpaceApp.URL_PARAM_LANG, lang);
|
| 36 |
-
|
| 37 |
}
|
| 38 |
},
|
| 39 |
|
|
|
|
| 26 |
console.log(`[I18n] Language set to: ${lang}`);
|
| 27 |
|
| 28 |
if (reload) {
|
|
|
|
|
|
|
|
|
|
|
|
|
| 29 |
// Update URL to reflect language or just reload
|
| 30 |
const url = new URL(window.location);
|
| 31 |
url.searchParams.set(SpaceApp.URL_PARAM_LANG, lang);
|
| 32 |
+
window.location.href = url.toString();
|
| 33 |
}
|
| 34 |
},
|
| 35 |
|