v4.0.0: 덱 UX·i18n·썸네일 저장 개선 및 413 수정
즐겨찾기·홀드 미리보기·페이지 도움말·3개국어 번역을 추가하고, 덱 저장 시 썸네일을 1200px로 통일하며 Nginx/API 업로드 제한을 상향했다. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
13
index.html
13
index.html
@@ -98,7 +98,7 @@
|
||||
<script type="module">
|
||||
async function loadSeriesList() {
|
||||
const urlParams = new URLSearchParams(window.location.search);
|
||||
const lang = urlParams.get('lang') || 'ko';
|
||||
const lang = urlParams.get('lang') || localStorage.getItem('lang') || 'ko';
|
||||
|
||||
try {
|
||||
const response = await fetch(`./i18n/translations.${lang}.json`);
|
||||
@@ -163,17 +163,24 @@
|
||||
}
|
||||
}
|
||||
|
||||
window.changeLanguage = function (lang) {
|
||||
window.changeLanguage = async function (lang) {
|
||||
localStorage.setItem('lang', lang);
|
||||
const currentUrl = new URL(window.location.href);
|
||||
currentUrl.searchParams.set('lang', lang);
|
||||
window.history.pushState({}, '', currentUrl.toString());
|
||||
loadSeriesList();
|
||||
await loadSeriesList();
|
||||
if (window.UaPageI18n?.applyPageI18n) {
|
||||
await window.UaPageI18n.applyPageI18n();
|
||||
}
|
||||
if (window.UaDeckAuth?.refresh) {
|
||||
await window.UaDeckAuth.refresh();
|
||||
}
|
||||
};
|
||||
|
||||
window.addEventListener('popstate', () => loadSeriesList());
|
||||
loadSeriesList();
|
||||
</script>
|
||||
<script src="/script/page-i18n.js"></script>
|
||||
<script src="/script/auth-header.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user