forked from naskya/firefish
fix: push notification
Co-authored-by: naskya <m@naskya.net>
This commit is contained in:
parent
4aff9e953f
commit
0afd1de14e
2 changed files with 5 additions and 2 deletions
|
@ -10,7 +10,7 @@ export const apiUrl = `${url}/api`;
|
||||||
export const wsUrl = `${url
|
export const wsUrl = `${url
|
||||||
.replace("http://", "ws://")
|
.replace("http://", "ws://")
|
||||||
.replace("https://", "wss://")}/streaming`;
|
.replace("https://", "wss://")}/streaming`;
|
||||||
export const lang = localStorage.getItem("lang")?.split("-")[0] ?? "en";
|
export const lang = localStorage.getItem("lang") ?? "en-US";
|
||||||
export const langs = _LANGS_;
|
export const langs = _LANGS_;
|
||||||
export const locale = JSON.parse(localStorage.getItem("locale") || "en-US");
|
export const locale = JSON.parse(localStorage.getItem("locale") || "en-US");
|
||||||
export const version = _VERSION_;
|
export const version = _VERSION_;
|
||||||
|
|
|
@ -124,7 +124,10 @@ function checkForSplash() {
|
||||||
// #region Set lang attr
|
// #region Set lang attr
|
||||||
const html = document.documentElement;
|
const html = document.documentElement;
|
||||||
html.setAttribute("lang", lang ?? "en-US");
|
html.setAttribute("lang", lang ?? "en-US");
|
||||||
html.setAttribute("dir", langmap[lang].rtl === true ? "rtl" : "ltr");
|
html.setAttribute(
|
||||||
|
"dir",
|
||||||
|
langmap[lang.split("-", 1)[0]].rtl === true ? "rtl" : "ltr",
|
||||||
|
);
|
||||||
// #endregion
|
// #endregion
|
||||||
|
|
||||||
// #region loginId
|
// #region loginId
|
||||||
|
|
Loading…
Reference in a new issue