All source files

src/i18n.mjs

Download raw file

export const STRINGS = {
  zh: {
    pageTitleDaily:'每日猜词 | WordHint Lab', pageTitlePractice:'无限制练习 | WordHint Lab',
    description:'原创每日五字母挑战,六次猜测、主动提示、本地记录和无答案分享。',
    dailyTitle:'每日一词,逐步找线索', practiceTitle:'随时开始一局新练习',
    dailyIntro:'六次五字母猜测。提示由你决定何时解锁,成绩只保存在当前浏览器。', practiceIntro:'使用相同规则反复练习,不影响每日成绩和连续记录。',
    navDaily:'每日挑战', navPractice:'无限制练习', language:'English', source:'源码', privacyLink:'隐私与记录', contactLink:'联系', private:'本地优先',
    puzzle:'今日挑战', practice:'练习局', utc:'UTC 日期', unscheduled:'当前日期还没有已审核题目,请稍后再来。',
    boardLabel:'六行五字母猜词棋盘', submit:'检查猜测', hint:'显示下一条提示', reveal:'看答案', newRound:'开始新练习',
    hints:'渐进提示', hintIntro:'先给温和线索,再由你决定是否继续揭示。', hintOffer:'需要一点帮助吗?下一条提示已就绪。',
    hint1:'类别', hint2:'语义线索', hint3:'首字母', category:'类别', firstLetter:'首字母是',
    stats:'本地记录', played:'已玩', wins:'答对', streak:'当前连续', best:'最佳连续', distribution:'答对次数分布',
    how:'怎么玩', how1:'输入有效的五字母英文词,按 Enter 或“检查猜测”。', how2:'✓ 表示位置正确,~ 表示字母存在但位置不对,· 表示不在答案中。', how3:'重复字母按答案实际数量分配,不会重复给黄或绿。', how4:'非法单词不消耗机会;六次用完或答对后结束。',
    privacy:'记录与隐私', privacyText:'局面和统计仅存于当前浏览器。分析事件只包含次数和结果,不包含完整猜测或答案。',
    share:'分享成绩', shareText:'只包含期号、次数和色块,不包含答案。', copy:'复制无答案成绩', copied:'成绩已复制。', copyFailed:'无法自动复制,请手动选择成绩文本。',
    revealTitle:'查看今天的答案?', revealPracticeTitle:'查看本局答案?', revealText:'本局将计为“已看答案”,不会增加当前答对连续记录,最佳历史记录会保留。', cancel:'继续猜', confirmReveal:'查看答案',
    resultSolved:'答对了!', resultLost:'机会用完了。', resultRevealed:'已查看答案。', answerIs:'答案是', nextPuzzle:'距离下一题', noAccount:'无需账号',
    invalidLength:'请输入完整的五个英文字母。', invalidWord:'这个词不在当前猜测词表中,请换一个。', guessesLeft:'次机会剩余', row:'第', rowUnit:'行',
    correct:'位置正确', present:'位置不对', absent:'不在答案中', draft:'正在输入', terminal:'本局已结束',
    recoveredCorrupt:'当日存档无法读取,已重置当日局面;历史统计未受影响。', recoveredStats:'统计存档无法读取,已重新建立。', recoveredVersion:'旧版存档不兼容,已安全重置当日局面。', storageUnavailable:'浏览器存储不可用,仍可继续游戏,但刷新后可能丢失记录。', saveFailed:'当前记录无法保存,游戏仍可继续。', newDay:'新的一天,新的题目。', restored:'已恢复当前浏览器中的局面。',
    cookieSettings:'更改 Cookie 选择', cookieTitle:'分析 Cookie 选择', cookieText:'只有在你允许后,我们才加载 Google Tag Manager 与 Google Analytics,用于统计页面浏览和白名单游戏事件。选择前不会向 Google 发送请求,也不会写入分析 Cookie。你可以随时更改选择。', cookieAccept:'允许分析', cookieReject:'不允许', cookiePrivacy:'隐私与记录说明', cookieNoChannels:'当前构建未启用分析通道,因此没有可设置的分析 Cookie。'
  },
  en: {
    pageTitleDaily:'Daily word challenge | WordHint Lab', pageTitlePractice:'Unlimited practice | WordHint Lab',
    description:'Original daily five-letter puzzles with six guesses, player-controlled hints, local records and spoiler-free sharing.',
    dailyTitle:'One daily word, one clue at a time', practiceTitle:'Start a fresh practice round',
    dailyIntro:'Six five-letter guesses. You choose when to reveal hints, and results stay in this browser.', practiceIntro:'Repeat the same rules without changing your daily record or streak.',
    navDaily:'Daily challenge', navPractice:'Unlimited practice', language:'中文', source:'Source code', privacyLink:'Privacy & records', contactLink:'Contact', private:'Local first',
    puzzle:'Daily challenge', practice:'Practice round', utc:'UTC date', unscheduled:'No reviewed puzzle is scheduled for this date yet. Please check back later.',
    boardLabel:'Six rows of five-letter guesses', submit:'Check guess', hint:'Reveal next hint', reveal:'Reveal answer', newRound:'New practice round',
    hints:'Progressive hints', hintIntro:'Start with a gentle clue, then choose whether to reveal more.', hintOffer:'Need a nudge? The next hint is ready.',
    hint1:'Category', hint2:'Meaning clue', hint3:'First letter', category:'Category', firstLetter:'The first letter is',
    stats:'Your local record', played:'Played', wins:'Solved', streak:'Current streak', best:'Best streak', distribution:'Solved guess distribution',
    how:'How to play', how1:'Enter a valid five-letter English word, then press Enter or “Check guess”.', how2:'✓ means the letter and position are correct, ~ means the letter belongs elsewhere, and · means it is absent.', how3:'Repeated letters are limited by how many copies occur in the answer.', how4:'Invalid words do not consume a guess. The round ends after a solve or six guesses.',
    privacy:'Records and privacy', privacyText:'Your board and stats stay in this browser. Analytics events contain counts and outcomes, never complete guesses or the answer.',
    share:'Share your result', shareText:'Only the puzzle number, attempt count and tile grid are included. The answer stays hidden.', copy:'Copy spoiler-free result', copied:'Result copied.', copyFailed:'Automatic copy is unavailable. Select the result text manually.',
    revealTitle:'Reveal today’s answer?', revealPracticeTitle:'Reveal this round’s answer?', revealText:'This round will be marked as revealed. It will not increase your current solved streak, and your best historical streak is preserved.', cancel:'Keep guessing', confirmReveal:'Reveal answer',
    resultSolved:'Solved!', resultLost:'No guesses left.', resultRevealed:'Answer revealed.', answerIs:'The answer is', nextPuzzle:'Next puzzle in', noAccount:'No account needed',
    invalidLength:'Enter all five English letters before checking.', invalidWord:'That word is not in the current guess list. Try another.', guessesLeft:'guesses left', row:'Row ', rowUnit:'',
    correct:'correct', present:'misplaced', absent:'absent', draft:'Current guess', terminal:'Round complete',
    recoveredCorrupt:'Today’s saved board could not be read, so only the daily board was reset. Historical stats were left intact.', recoveredStats:'The saved stats could not be read, so they were rebuilt.', recoveredVersion:'The old save format is incompatible, so the daily board was reset safely.', storageUnavailable:'Browser storage is unavailable. You can keep playing, but this round may not survive a refresh.', saveFailed:'This record could not be saved. You can keep playing.', newDay:'A new day brings a new puzzle.', restored:'Your saved board was restored from this browser.',
    cookieSettings:'Change cookie choices', cookieTitle:'Analytics cookie choice', cookieText:'We load Google Tag Manager and Google Analytics only if you allow it, to measure page views and whitelisted game events. Before you choose, no request is sent to Google and no analytics cookie is written. You can change this choice at any time.', cookieAccept:'Allow analytics', cookieReject:'Don’t allow', cookiePrivacy:'privacy and records notice', cookieNoChannels:'No analytics channel is configured in this build, so there is no analytics cookie to set.'
  }
};

export function t(locale, key) {
  return (STRINGS[locale] || STRINGS.en)[key] || key;
}