mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-21 09:19:29 +08:00
Merge branch 'master' into fluencydoc_master
# Conflicts: # extra/update-version.js # server/client.js # server/server.js
This commit is contained in:
@@ -64,7 +64,19 @@ export function timezoneList() {
|
||||
}
|
||||
|
||||
export function setPageLocale() {
|
||||
const html = document.documentElement
|
||||
html.setAttribute('lang', currentLocale() )
|
||||
html.setAttribute('dir', localeDirection() )
|
||||
const html = document.documentElement;
|
||||
html.setAttribute("lang", currentLocale() );
|
||||
html.setAttribute("dir", localeDirection() );
|
||||
}
|
||||
|
||||
/**
|
||||
* Mainly used for dev, because the backend and the frontend are in different ports.
|
||||
*/
|
||||
export function getResBaseURL() {
|
||||
const env = process.env.NODE_ENV;
|
||||
if (env === "development" || localStorage.dev === "dev") {
|
||||
return location.protocol + "//" + location.hostname + ":3001";
|
||||
} else {
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user