mirror of
https://github.com/SteamDeckHomebrew/decky-loader.git
synced 2026-06-13 12:15:09 +03:00
Hotfix for i18n where the detector was overriding localStorage (#439)
* Hotfix for i18n where the detector was overriding localStorage * Please, pnpm, cooperate
This commit is contained in:
@@ -45,7 +45,6 @@
|
||||
"dependencies": {
|
||||
"decky-frontend-lib": "3.20.6",
|
||||
"i18next": "^22.4.15",
|
||||
"i18next-browser-languagedetector": "^7.0.1",
|
||||
"i18next-http-backend": "^2.2.0",
|
||||
"react-file-icon": "^1.3.0",
|
||||
"react-i18next": "^12.2.2",
|
||||
|
||||
Generated
+45
-55
@@ -7,9 +7,6 @@ dependencies:
|
||||
i18next:
|
||||
specifier: ^22.4.15
|
||||
version: 22.4.15
|
||||
i18next-browser-languagedetector:
|
||||
specifier: ^7.0.1
|
||||
version: 7.0.1
|
||||
i18next-http-backend:
|
||||
specifier: ^2.2.0
|
||||
version: 2.2.0
|
||||
@@ -120,22 +117,22 @@ packages:
|
||||
'@babel/highlight': 7.18.6
|
||||
dev: true
|
||||
|
||||
/@babel/compat-data@7.21.5:
|
||||
resolution: {integrity: sha512-M+XAiQ7GzQ3FDPf0KOLkugzptnIypt0X0ma0wmlTKPR3IchgNFdx2JXxZdvd18JY5s7QkaFD/qyX0dsMpog/Ug==}
|
||||
/@babel/compat-data@7.21.7:
|
||||
resolution: {integrity: sha512-KYMqFYTaenzMK4yUtf4EW9wc4N9ef80FsbMtkwool5zpwl4YrT1SdWYSTRcT94KO4hannogdS+LxY7L+arP3gA==}
|
||||
engines: {node: '>=6.9.0'}
|
||||
dev: true
|
||||
|
||||
/@babel/core@7.21.5:
|
||||
resolution: {integrity: sha512-9M398B/QH5DlfCOTKDZT1ozXr0x8uBEeFd+dJraGUZGiaNpGCDVGCc14hZexsMblw3XxltJ+6kSvogp9J+5a9g==}
|
||||
/@babel/core@7.21.8:
|
||||
resolution: {integrity: sha512-YeM22Sondbo523Sz0+CirSPnbj9bG3P0CdHcBZdqUuaeOaYEFbOLoGU7lebvGP6P5J/WE9wOn7u7C4J9HvS1xQ==}
|
||||
engines: {node: '>=6.9.0'}
|
||||
dependencies:
|
||||
'@ampproject/remapping': 2.2.1
|
||||
'@babel/code-frame': 7.21.4
|
||||
'@babel/generator': 7.21.5
|
||||
'@babel/helper-compilation-targets': 7.21.5(@babel/core@7.21.5)
|
||||
'@babel/helper-compilation-targets': 7.21.5(@babel/core@7.21.8)
|
||||
'@babel/helper-module-transforms': 7.21.5
|
||||
'@babel/helpers': 7.21.5
|
||||
'@babel/parser': 7.21.5
|
||||
'@babel/parser': 7.21.8
|
||||
'@babel/template': 7.20.7
|
||||
'@babel/traverse': 7.21.5
|
||||
'@babel/types': 7.21.5
|
||||
@@ -158,14 +155,14 @@ packages:
|
||||
jsesc: 2.5.2
|
||||
dev: true
|
||||
|
||||
/@babel/helper-compilation-targets@7.21.5(@babel/core@7.21.5):
|
||||
/@babel/helper-compilation-targets@7.21.5(@babel/core@7.21.8):
|
||||
resolution: {integrity: sha512-1RkbFGUKex4lvsB9yhIfWltJM5cZKUftB2eNajaDv3dCMEp49iBG0K14uH8NnX9IPux2+mK7JGEOB0jn48/J6w==}
|
||||
engines: {node: '>=6.9.0'}
|
||||
peerDependencies:
|
||||
'@babel/core': ^7.0.0
|
||||
dependencies:
|
||||
'@babel/compat-data': 7.21.5
|
||||
'@babel/core': 7.21.5
|
||||
'@babel/compat-data': 7.21.7
|
||||
'@babel/core': 7.21.8
|
||||
'@babel/helper-validator-option': 7.21.0
|
||||
browserslist: 4.21.5
|
||||
lru-cache: 5.1.1
|
||||
@@ -264,8 +261,8 @@ packages:
|
||||
js-tokens: 4.0.0
|
||||
dev: true
|
||||
|
||||
/@babel/parser@7.21.5:
|
||||
resolution: {integrity: sha512-J+IxH2IsxV4HbnTrSWgMAQj0UEo61hDA4Ny8h8PCX0MLXiibqHbqIOVneqdocemSBc22VpBKxt4J6FQzy9HarQ==}
|
||||
/@babel/parser@7.21.8:
|
||||
resolution: {integrity: sha512-6zavDGdzG3gUqAdWvlLFfk+36RilI+Pwyuuh7HItyeScCWP3k6i8vKclAQ0bM/0y/Kz/xiwvxhMv9MgTJP5gmA==}
|
||||
engines: {node: '>=6.0.0'}
|
||||
hasBin: true
|
||||
dependencies:
|
||||
@@ -283,7 +280,7 @@ packages:
|
||||
engines: {node: '>=6.9.0'}
|
||||
dependencies:
|
||||
'@babel/code-frame': 7.21.4
|
||||
'@babel/parser': 7.21.5
|
||||
'@babel/parser': 7.21.8
|
||||
'@babel/types': 7.21.5
|
||||
dev: true
|
||||
|
||||
@@ -297,7 +294,7 @@ packages:
|
||||
'@babel/helper-function-name': 7.21.0
|
||||
'@babel/helper-hoist-variables': 7.18.6
|
||||
'@babel/helper-split-export-declaration': 7.18.6
|
||||
'@babel/parser': 7.21.5
|
||||
'@babel/parser': 7.21.8
|
||||
'@babel/types': 7.21.5
|
||||
debug: 4.3.4
|
||||
globals: 11.12.0
|
||||
@@ -734,7 +731,7 @@ packages:
|
||||
resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==}
|
||||
dependencies:
|
||||
'@types/minimatch': 5.1.2
|
||||
'@types/node': 18.16.2
|
||||
'@types/node': 18.16.3
|
||||
dev: true
|
||||
|
||||
/@types/hast@2.3.4:
|
||||
@@ -769,8 +766,8 @@ packages:
|
||||
resolution: {integrity: sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==}
|
||||
dev: false
|
||||
|
||||
/@types/node@18.16.2:
|
||||
resolution: {integrity: sha512-GQW/JL/5Fz/0I8RpeBG9lKp0+aNcXEaVL71c0D2Q0QHDTFvlYKT7an0onCUXj85anv7b4/WesqdfchLc0jtsCg==}
|
||||
/@types/node@18.16.3:
|
||||
resolution: {integrity: sha512-OPs5WnnT1xkCBiuQrZA4+YAV4HEJejmHneyraIaxsbev5yCEr6KMwINNFP9wQeFIw8FWcoTqF3vQsa5CDaI+8Q==}
|
||||
dev: true
|
||||
|
||||
/@types/prop-types@15.7.5:
|
||||
@@ -798,7 +795,7 @@ packages:
|
||||
/@types/resolve@1.17.1:
|
||||
resolution: {integrity: sha512-yy7HuzQhj0dhGpD8RLXSZWEkLsV9ibvxvi6EiJ3bkqLAO1RGo0WbkWQiwpRlSFymTJRz0d3k5LM3kkx8ArDbLw==}
|
||||
dependencies:
|
||||
'@types/node': 18.16.2
|
||||
'@types/node': 18.16.3
|
||||
dev: true
|
||||
|
||||
/@types/symlink-or-copy@1.2.0:
|
||||
@@ -812,9 +809,9 @@ packages:
|
||||
/@types/webpack@5.28.1:
|
||||
resolution: {integrity: sha512-qw1MqGZclCoBrpiSe/hokSgQM/su8Ocpl3L/YHE0L6moyaypg4+5F7Uzq7NgaPKPxUxUbQ4fLPLpDWdR27bCZw==}
|
||||
dependencies:
|
||||
'@types/node': 18.16.2
|
||||
'@types/node': 18.16.3
|
||||
tapable: 2.2.1
|
||||
webpack: 5.81.0
|
||||
webpack: 5.82.0
|
||||
transitivePeerDependencies:
|
||||
- '@swc/core'
|
||||
- esbuild
|
||||
@@ -1101,8 +1098,8 @@ packages:
|
||||
engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}
|
||||
hasBin: true
|
||||
dependencies:
|
||||
caniuse-lite: 1.0.30001481
|
||||
electron-to-chromium: 1.4.377
|
||||
caniuse-lite: 1.0.30001482
|
||||
electron-to-chromium: 1.4.380
|
||||
node-releases: 2.0.10
|
||||
update-browserslist-db: 1.0.11(browserslist@4.21.5)
|
||||
dev: true
|
||||
@@ -1154,8 +1151,8 @@ packages:
|
||||
engines: {node: '>=4'}
|
||||
dev: true
|
||||
|
||||
/caniuse-lite@1.0.30001481:
|
||||
resolution: {integrity: sha512-KCqHwRnaa1InZBtqXzP98LPg0ajCVujMKjqKDhZEthIpAsJl/YEIa3YvXjGXPVqzZVguccuu7ga9KOE1J9rKPQ==}
|
||||
/caniuse-lite@1.0.30001482:
|
||||
resolution: {integrity: sha512-F1ZInsg53cegyjroxLNW9DmrEQ1SuGRTO1QlpA0o2/6OpQ0gFeDRoq1yFmnr8Sakn9qwwt9DmbxHB6w167OSuQ==}
|
||||
dev: true
|
||||
|
||||
/ccount@2.0.1:
|
||||
@@ -1195,7 +1192,7 @@ packages:
|
||||
css-what: 6.1.0
|
||||
domelementtype: 2.3.0
|
||||
domhandler: 5.0.3
|
||||
domutils: 3.0.1
|
||||
domutils: 3.1.0
|
||||
dev: true
|
||||
|
||||
/cheerio@1.0.0-rc.12:
|
||||
@@ -1205,7 +1202,7 @@ packages:
|
||||
cheerio-select: 2.1.0
|
||||
dom-serializer: 2.0.0
|
||||
domhandler: 5.0.3
|
||||
domutils: 3.0.1
|
||||
domutils: 3.1.0
|
||||
htmlparser2: 8.0.2
|
||||
parse5: 7.1.2
|
||||
parse5-htmlparser2-tree-adapter: 7.0.0
|
||||
@@ -1228,8 +1225,8 @@ packages:
|
||||
restore-cursor: 3.1.0
|
||||
dev: true
|
||||
|
||||
/cli-spinners@2.8.0:
|
||||
resolution: {integrity: sha512-/eG5sJcvEIwxcdYM86k5tPwn0MUzkX5YY3eImTGpJOZgVe4SdTMY14vQpcxgBzJ0wXwAYrS8E+c3uHeK4JNyzQ==}
|
||||
/cli-spinners@2.9.0:
|
||||
resolution: {integrity: sha512-4/aL9X3Wh0yiMQlE+eeRhWP6vclO3QRtw1JHKIT0FFUs5FjpFmESqtMvYZ0+lbzBw900b95mS0hohy+qn2VK/g==}
|
||||
engines: {node: '>=6'}
|
||||
dev: true
|
||||
|
||||
@@ -1358,7 +1355,7 @@ packages:
|
||||
boolbase: 1.0.0
|
||||
css-what: 6.1.0
|
||||
domhandler: 5.0.3
|
||||
domutils: 3.0.1
|
||||
domutils: 3.1.0
|
||||
nth-check: 2.1.1
|
||||
dev: true
|
||||
|
||||
@@ -1480,8 +1477,8 @@ packages:
|
||||
domelementtype: 2.3.0
|
||||
dev: true
|
||||
|
||||
/domutils@3.0.1:
|
||||
resolution: {integrity: sha512-z08c1l761iKhDFtfXO04C7kTdPBLi41zwOZl00WS8b5eiaebNpY00HKbztwBq+e3vyqWNwWF3mP9YLUeqIrF+Q==}
|
||||
/domutils@3.1.0:
|
||||
resolution: {integrity: sha512-H78uMmQtI2AhgDJjWeQmHwJJ2bLPD3GMmO7Zja/ZZh84wkm+4ut+IUnUdRa8uCGX88DiVx1j6FRe1XfxEgjEZA==}
|
||||
dependencies:
|
||||
dom-serializer: 2.0.0
|
||||
domelementtype: 2.3.0
|
||||
@@ -1497,8 +1494,8 @@ packages:
|
||||
stream-shift: 1.0.1
|
||||
dev: true
|
||||
|
||||
/electron-to-chromium@1.4.377:
|
||||
resolution: {integrity: sha512-H3BYG6DW5Z+l0xcfXaicJGxrpA4kMlCxnN71+iNX+dBLkRMOdVJqFJiAmbNZZKA1zISpRg17JR03qGifXNsJtw==}
|
||||
/electron-to-chromium@1.4.380:
|
||||
resolution: {integrity: sha512-XKGdI4pWM78eLH2cbXJHiBnWUwFSzZM7XujsB6stDiGu9AeSqziedP6amNLpJzE3i0rLTcfAwdCTs5ecP5yeSg==}
|
||||
dev: true
|
||||
|
||||
/emoji-regex@8.0.0:
|
||||
@@ -1918,7 +1915,7 @@ packages:
|
||||
dependencies:
|
||||
domelementtype: 2.3.0
|
||||
domhandler: 5.0.3
|
||||
domutils: 3.0.1
|
||||
domutils: 3.1.0
|
||||
entities: 4.5.0
|
||||
dev: true
|
||||
|
||||
@@ -1928,12 +1925,6 @@ packages:
|
||||
hasBin: true
|
||||
dev: true
|
||||
|
||||
/i18next-browser-languagedetector@7.0.1:
|
||||
resolution: {integrity: sha512-Pa5kFwaczXJAeHE56CHG2aWzFBMJNUNghf0Pm4SwSrEMps/PTKqW90EYWlIvhuYStf3Sn1K0vw+gH3+TLdkH1g==}
|
||||
dependencies:
|
||||
'@babel/runtime': 7.21.5
|
||||
dev: false
|
||||
|
||||
/i18next-http-backend@2.2.0:
|
||||
resolution: {integrity: sha512-Z4sM7R6tzdLknSPER9GisEBxKPg5FkI07UrQniuroZmS15PHQrcCPLyuGKj8SS68tf+O2aEDYSUnmy1TZqZSbw==}
|
||||
dependencies:
|
||||
@@ -2012,8 +2003,8 @@ packages:
|
||||
/import-sort-parser-babylon@6.0.0:
|
||||
resolution: {integrity: sha512-NyShTiNhTh4Vy7kJUVe6CuvOaQAzzfSIT72wtp3CzGjz8bHjNj59DCAjncuviicmDOgVAgmLuSh1WMcLYAMWGg==}
|
||||
dependencies:
|
||||
'@babel/core': 7.21.5
|
||||
'@babel/parser': 7.21.5
|
||||
'@babel/core': 7.21.8
|
||||
'@babel/parser': 7.21.8
|
||||
'@babel/traverse': 7.21.5
|
||||
'@babel/types': 7.21.5
|
||||
find-line-column: 0.5.2
|
||||
@@ -2233,7 +2224,7 @@ packages:
|
||||
resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==}
|
||||
engines: {node: '>= 10.13.0'}
|
||||
dependencies:
|
||||
'@types/node': 18.16.2
|
||||
'@types/node': 18.16.3
|
||||
merge-stream: 2.0.0
|
||||
supports-color: 8.1.1
|
||||
dev: true
|
||||
@@ -2538,14 +2529,13 @@ packages:
|
||||
uvu: 0.5.6
|
||||
dev: false
|
||||
|
||||
/micromark-extension-gfm-autolink-literal@1.0.3:
|
||||
resolution: {integrity: sha512-i3dmvU0htawfWED8aHMMAzAVp/F0Z+0bPh3YrbTPPL1v4YAlCZpy5rBO5p0LPYiZo0zFVkoYh7vDU7yQSiCMjg==}
|
||||
/micromark-extension-gfm-autolink-literal@1.0.4:
|
||||
resolution: {integrity: sha512-WCssN+M9rUyfHN5zPBn3/f0mIA7tqArHL/EKbv3CZK+LT2rG77FEikIQEqBkv46fOqXQK4NEW/Pc7Z27gshpeg==}
|
||||
dependencies:
|
||||
micromark-util-character: 1.1.0
|
||||
micromark-util-sanitize-uri: 1.1.0
|
||||
micromark-util-symbol: 1.0.1
|
||||
micromark-util-types: 1.0.2
|
||||
uvu: 0.5.6
|
||||
dev: false
|
||||
|
||||
/micromark-extension-gfm-footnote@1.1.0:
|
||||
@@ -2601,7 +2591,7 @@ packages:
|
||||
/micromark-extension-gfm@2.0.1:
|
||||
resolution: {integrity: sha512-p2sGjajLa0iYiGQdT0oelahRYtMWvLjy8J9LOCxzIQsllMCGLbsLW+Nc+N4vi02jcRJvedVJ68cjelKIO6bpDA==}
|
||||
dependencies:
|
||||
micromark-extension-gfm-autolink-literal: 1.0.3
|
||||
micromark-extension-gfm-autolink-literal: 1.0.4
|
||||
micromark-extension-gfm-footnote: 1.1.0
|
||||
micromark-extension-gfm-strikethrough: 1.0.5
|
||||
micromark-extension-gfm-table: 1.0.5
|
||||
@@ -2902,7 +2892,7 @@ packages:
|
||||
bl: 4.1.0
|
||||
chalk: 4.1.2
|
||||
cli-cursor: 3.1.0
|
||||
cli-spinners: 2.8.0
|
||||
cli-spinners: 2.9.0
|
||||
is-interactive: 1.0.0
|
||||
is-unicode-supported: 0.1.0
|
||||
log-symbols: 4.1.0
|
||||
@@ -3532,7 +3522,7 @@ packages:
|
||||
streamx: 2.13.2
|
||||
dev: true
|
||||
|
||||
/terser-webpack-plugin@5.3.7(webpack@5.81.0):
|
||||
/terser-webpack-plugin@5.3.7(webpack@5.82.0):
|
||||
resolution: {integrity: sha512-AfKwIktyP7Cu50xNjXF/6Qb5lBNzYaWpU6YfoX3uZicTx0zTy0stDDCsvjDapKsSDvOeWo5MEq4TmdBy2cNoHw==}
|
||||
engines: {node: '>= 10.13.0'}
|
||||
peerDependencies:
|
||||
@@ -3553,7 +3543,7 @@ packages:
|
||||
schema-utils: 3.1.2
|
||||
serialize-javascript: 6.0.1
|
||||
terser: 5.17.1
|
||||
webpack: 5.81.0
|
||||
webpack: 5.82.0
|
||||
dev: true
|
||||
|
||||
/terser@5.17.1:
|
||||
@@ -3897,8 +3887,8 @@ packages:
|
||||
engines: {node: '>=10.13.0'}
|
||||
dev: true
|
||||
|
||||
/webpack@5.81.0:
|
||||
resolution: {integrity: sha512-AAjaJ9S4hYCVODKLQTgG5p5e11hiMawBwV2v8MYLE0C/6UAGLuAF4n1qa9GOwdxnicaP+5k6M5HrLmD4+gIB8Q==}
|
||||
/webpack@5.82.0:
|
||||
resolution: {integrity: sha512-iGNA2fHhnDcV1bONdUu554eZx+XeldsaeQ8T67H6KKHl2nUSwX8Zm7cmzOA46ox/X1ARxf7Bjv8wQ/HsB5fxBg==}
|
||||
engines: {node: '>=10.13.0'}
|
||||
hasBin: true
|
||||
peerDependencies:
|
||||
@@ -3928,7 +3918,7 @@ packages:
|
||||
neo-async: 2.6.2
|
||||
schema-utils: 3.1.2
|
||||
tapable: 2.2.1
|
||||
terser-webpack-plugin: 5.3.7(webpack@5.81.0)
|
||||
terser-webpack-plugin: 5.3.7(webpack@5.82.0)
|
||||
watchpack: 2.4.0
|
||||
webpack-sources: 3.2.3
|
||||
transitivePeerDependencies:
|
||||
|
||||
@@ -14,7 +14,7 @@ export default defineConfig({
|
||||
input: 'src/index.tsx',
|
||||
plugins: [
|
||||
del({ targets: '../backend/static/*', force: true }),
|
||||
commonjs({include: '../frontend/node_modules/**'}),
|
||||
commonjs(),
|
||||
nodeResolve({
|
||||
browser: true
|
||||
}),
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import { Navigation, Router, sleep } from 'decky-frontend-lib';
|
||||
import i18n from 'i18next';
|
||||
import LanguageDetector from 'i18next-browser-languagedetector';
|
||||
import Backend from 'i18next-http-backend';
|
||||
import { initReactI18next } from 'react-i18next';
|
||||
|
||||
@@ -42,7 +41,6 @@ declare global {
|
||||
|
||||
i18n
|
||||
.use(Backend)
|
||||
.use(LanguageDetector)
|
||||
.use(initReactI18next)
|
||||
.init({
|
||||
load: 'currentOnly',
|
||||
@@ -51,6 +49,7 @@ declare global {
|
||||
lookupQuerystring: 'lng',
|
||||
},
|
||||
//debug: true,
|
||||
lng: navigator.language,
|
||||
fallbackLng: 'en-US',
|
||||
interpolation: {
|
||||
escapeValue: true,
|
||||
|
||||
Reference in New Issue
Block a user