release: v1.0.2
Publish Docker image / build-and-push (push) Canceled after 0s
GitHub Release / release (push) Canceled after 0s
ci / ci (22, ubuntu-latest) (push) Canceled after 0s

Add i18n (zh-CN/en), mobile navigation menus, stats and upload UI
improvements, and Docker reset-password CLI for emergency recovery.
This commit is contained in:
O96u committed 2026-08-23 17:43:42 +08:00
1 parent 074e4502c2
commit 22cb2ca8bc
46 files changed
+3724 -587

No files matched your search

+304
View File
@@ -0,0 +1,304 @@
{
"app": {
"title": "PicHost - Image Hosting",
"description": "A lightweight self-hosted image hosting system",
"tagline": "Personal lightweight image host"
},
"common": {
"loadingSession": "Verifying session…",
"save": "Save",
"cancel": "Cancel",
"copy": "Copy",
"delete": "Delete",
"search": "Search",
"refresh": "Refresh",
"back": "Back",
"all": "All",
"notConfigured": "(not configured)",
"countImages": "{count} images",
"itemsUnit": "items",
"imagesUnit": "images"
},
"nav": {
"api": "API",
"stats": "Stats",
"settings": "Settings",
"menu": "Menu",
"language": "Language",
"appearance": "Appearance",
"account": "Account",
"backToUpload": "Back to upload",
"changePassword": "Change password",
"systemSettings": "System settings",
"logout": "Log out"
},
"theme": {
"switch": "Switch theme",
"light": "Light",
"dark": "Dark",
"system": "System"
},
"locale": {
"switch": "Switch language",
"zh-CN": "简体中文",
"en": "English"
},
"auth": {
"username": "Username",
"password": "Password",
"confirmPassword": "Confirm password",
"login": "Log in",
"register": "Register",
"adminSecret": "Admin secret",
"adminSecretPlaceholder": "Enter ADMIN_SECRET",
"legacyHint": "Legacy deployment: sign in with the secret to migrate to username/password",
"noAccount": "No account?",
"hasAccount": "Already have an account?",
"backToLogin": "Back to login",
"loginFooter": "Upload and management require sign-in",
"loginSuccess": "Signed in",
"loginFailedSecret": "Sign-in failed. Check your secret",
"loginFailedCredentials": "Invalid username or password",
"loginFailed": "Sign-in failed. Check username and password",
"registerFailed": "Registration failed. Check your input",
"setupFailed": "Setup failed. Check your input",
"migrateFailed": "Migration failed. Check your input",
"passwordMismatch": "Passwords do not match",
"registerSuccess": "Registered successfully",
"errors": {
"invalidUsername": "Username must be 3–32 letters, numbers, or underscores",
"invalidPassword": "Password must be at least 8 characters"
}
},
"setup": {
"migrateTitle": "Migrate to username/password",
"initTitle": "First run — create admin account",
"usernamePlaceholder": "3–32 letters, numbers, or underscores",
"passwordPlaceholder": "Set login password",
"confirmPlaceholder": "Enter password again",
"allowRegistration": "Allow user registration",
"migrateSubmit": "Complete migration",
"initSubmit": "Create and continue",
"migrateSuccess": "Migration complete",
"initSuccess": "Setup complete"
},
"register": {
"title": "Register",
"subtitle": "Create a PicHost user account"
},
"password": {
"title": "Change password",
"subtitle": "Update your login password",
"current": "Current password",
"new": "New password",
"confirmNew": "Confirm new password",
"newPlaceholder": "Set new password",
"mismatch": "New passwords do not match",
"changed": "Password updated",
"tooShort": "New password must be at least 8 characters",
"changeFailed": "Failed to change password",
"strength": "Password strength",
"weak": "Weak",
"medium": "Medium",
"strong": "Strong",
"ruleMinLength": "At least {n} characters",
"ruleMixedCase": "Upper and lower case letters",
"ruleNumber": "Contains a number",
"ruleSpecial": "Contains a special character"
},
"upload": {
"title": "Drop images here to upload",
"hint": "Or click to select files, press {ctrl} + {v} to paste",
"formats": "JPEG / PNG / WebP / GIF / SVG / ICO, max 10 MB each, up to 10 files per batch",
"selectFiles": "Select images",
"settings": "Upload settings",
"progress": "Upload progress",
"statusPending": "Pending",
"statusUploading": "Uploading",
"statusSuccess": "Done",
"statusError": "Failed",
"selectImages": "Select images to upload",
"maxFiles": "Up to {n} images per upload",
"uploadSuccess": "Uploaded {n} image(s)",
"uploadPartialFail": "{n} image(s) failed to upload",
"uploadFailed": "Upload failed",
"loginRequired": "Please sign in first",
"sessionTitle": "This session",
"sessionEmpty": "No uploads in this session"
},
"copy": {
"url": "URL",
"markdown": "Markdown",
"html": "HTML",
"copied": "Copied to clipboard",
"copiedLabel": "Copied {label}",
"copiedUrl": "URL copied",
"copiedMarkdown": "Markdown copied",
"copiedHtml": "HTML copied",
"copiedFormat": "Copied {format}",
"failed": "Copy failed",
"failedManual": "Copy failed — select the link manually",
"curl": "cURL example copied"
},
"preferences": {
"title": "Upload preferences",
"subtitle": "Browser-local and account settings for your uploads only",
"back": "Back to upload",
"processing": "Image processing",
"clientCompress": "Client-side compression",
"clientCompressHint": "Compress in the browser before upload (server still converts to WebP)",
"autoDeletePrefix": "Auto-delete after",
"autoDeleteSuffix": "days",
"autoDeleteHint": "Only affects images uploaded after enabling; existing images are kept",
"webpQuality": "WebP quality",
"webpQualityHint": "Client compression quality (1–100); requires client-side compression",
"current": "Current: {n}",
"qualityHigh": "High quality",
"qualityMedium": "Medium quality",
"qualityLow": "Lossy",
"convenience": "Convenience",
"autoCopy": "Copy link after upload",
"autoCopyHint": "Copy to clipboard in the selected format"
},
"settings": {
"title": "System settings",
"subtitle": "Saved to database; environment variables take precedence",
"uploadAccount": "Upload & accounts",
"defaultFolder": "Default upload folder",
"defaultFolderHint": "Stored in this browser only; affects your upload target",
"allowRegistration": "Open registration",
"allowRegistrationHint": "Allow new users to register (regular users see only their images)",
"accessControl": "Access control",
"refererHint": "Referer hotlink protection; comma-separated hostnames, empty = no restriction",
"refererPlaceholder": "example.com, www.example.com",
"linkGeneration": "Link generation",
"imageBaseUrlHint": "Public URL prefix for generated links; use your public domain behind a reverse proxy",
"imageBaseUrlPlaceholder": "https://pic.example.com",
"imageBaseUrlActive": "Active: {url}",
"badgeEnv": ".env",
"badgeSaved": "Saved",
"badgeDefault": "Default",
"badgeUnset": "Not set",
"tokenEnv": "Environment",
"tokenDb": "Generated in app",
"tokenNone": "Not configured",
"apiTokenLine": "API Token · {source} · v{version}",
"unsavedChanges": "Unsaved changes",
"manageToken": "Manage token",
"envOverride": "Overridden by environment variable; cannot edit in UI",
"saved": "Settings saved",
"saveFailed": "Failed to save settings",
"loadFailed": "Failed to load settings"
},
"stats": {
"title": "Statistics",
"subtitle": "Overview and gallery",
"uploadToday": "Uploaded today",
"uploadMonth": "Uploaded this month",
"uploadTotal": "Total uploads",
"storedCount": "Stored images",
"deleteToday": "Deleted today",
"deleteMonth": "Deleted this month",
"deleteTotal": "Total deleted",
"userCount": "Registered users",
"uploadBytes": "Total upload size",
"folderDistribution": "Uploads by folder",
"folderUsage": "Storage by folder",
"noData": "No data",
"folderCount": "{count} · {size}",
"gallery": "Gallery",
"folder": "Folder",
"searchPlaceholder": "Search filename",
"clear": "Clear",
"selected": "{n} selected",
"batchDelete": "Delete selected",
"scrollTop": "Back to top",
"loadFailed": "Failed to load statistics",
"selectFirst": "Select images first",
"deleted": "Deleted {n} image(s)",
"deletePartialFail": "{n} image(s) failed to delete",
"deleteFailed": "Delete failed",
"deletedSingle": "Deleted",
"allFolders": "All",
"counting": "Counting…",
"summarySearch": "{folder} · Search “{q}” · {total} images",
"summaryTotal": "{folder} · {total} images"
},
"image": {
"empty": "No images",
"previewFailed": "Preview failed",
"uploader": "Uploader: {name}"
},
"delete": {
"confirmTitle": "Confirm delete",
"confirmDesc": "Delete {count} selected image(s)? This cannot be undone.",
"confirm": "Delete"
},
"pagination": {
"pageOf": "Page {page} / {totalPages} · {total} {unit}",
"totalOnly": "{total} {unit}",
"first": "First page",
"prev": "Previous page",
"next": "Next page",
"last": "Last page"
},
"api": {
"tokenTitle": "API Token",
"envOverrideTitle": "Token overridden by environment",
"envOverrideDesc": "Restart after changing API_UPLOAD_TOKEN; cannot regenerate in UI.",
"personalTitle": "Personal API token",
"personalDesc": "For your scripts only; uploads belong to your account.",
"notConfiguredTitle": "No token configured",
"notConfiguredDesc": "Click Regenerate to create a token for Auth-Token on all endpoints below.",
"regenerate": "Regenerate",
"tokenSourceEnv": "Source: API_UPLOAD_TOKEN environment variable",
"tokenSourceDb": "Source: generated in app (can regenerate)",
"tokenSourceNone": "Source: not configured",
"tokenHeader": "Header:",
"tokenInvalidate": "Old token is invalidated immediately after regenerate",
"docsTitle": "API reference",
"curlExample": "cURL example",
"loadFailed": "Failed to load API settings",
"regenerateEnvBlocked": "Token is set via environment; cannot regenerate in UI",
"regenerateFailed": "Failed to regenerate token",
"confirmRegenerateTitle": "Regenerate token?",
"confirmRegenerateDesc": "The old token stops working immediately. Update scripts and automation before continuing.",
"confirmRegenerate": "Regenerate",
"newTokenTitle": "New token generated",
"newTokenDesc": "Copy and save it now. You can copy again from the field above after closing.",
"copyToken": "Copy token",
"saved": "Saved",
"docs": {
"upload": {
"title": "Upload images",
"descAdmin": "Upload one or more images. Use image field; folder creates directory if missing. Also accepts file, files, type.",
"descUser": "Upload one or more images via image field. Also accepts file, files. Stored under images/."
},
"list": {
"title": "List images",
"descAdmin": "Paginated gallery; optional folder filter. limit default 20, max 100.",
"descUser": "Paginated list of your images. limit default 20, max 100."
},
"search": {
"title": "Search images",
"desc": "Search by filename or path; q is required."
},
"delete": {
"title": "Delete image",
"desc": "Delete by key (storage path, e.g. images/2026/08/xxx.webp)."
},
"batchDelete": {
"title": "Batch delete",
"desc": "Delete multiple images; request body is a keys array."
},
"twikoo": {
"title": "Twikoo-compatible upload",
"desc": "Twikoo / EasyImage 2.0 protocol; stored under twikoo/. Fields: image + token."
}
}
},
"userSettings": {
"loadFailed": "Failed to load settings",
"saveFailed": "Failed to save settings"
}
}
+304
View File
@@ -0,0 +1,304 @@
{
"app": {
"title": "PicHost - 个人图床",
"description": "个人自用的轻量图床系统",
"tagline": "个人轻量图床"
},
"common": {
"loadingSession": "正在验证登录状态…",
"save": "保存",
"cancel": "取消",
"copy": "复制",
"delete": "删除",
"search": "搜索",
"refresh": "刷新",
"back": "返回",
"all": "全部",
"notConfigured": "(未配置)",
"countImages": "{count} 张",
"itemsUnit": "条",
"imagesUnit": "张"
},
"nav": {
"api": "API",
"stats": "统计",
"settings": "设置",
"menu": "菜单",
"language": "语言",
"appearance": "外观",
"account": "账户",
"backToUpload": "返回上传",
"changePassword": "修改密码",
"systemSettings": "系统设置",
"logout": "退出登录"
},
"theme": {
"switch": "切换主题",
"light": "浅色",
"dark": "深色",
"system": "跟随系统"
},
"locale": {
"switch": "切换语言",
"zh-CN": "简体中文",
"en": "English"
},
"auth": {
"username": "用户名",
"password": "密码",
"confirmPassword": "确认密码",
"login": "登录",
"register": "注册",
"adminSecret": "管理密钥",
"adminSecretPlaceholder": "输入 ADMIN_SECRET",
"legacyHint": "遗留部署:使用密钥登录后将引导创建账号",
"noAccount": "没有账号?",
"hasAccount": "已有账号?",
"backToLogin": "返回登录",
"loginFooter": "未登录时无法访问上传和管理功能",
"loginSuccess": "登录成功",
"loginFailedSecret": "登录失败,请检查密钥",
"loginFailedCredentials": "用户名或密码错误",
"loginFailed": "登录失败,请检查用户名和密码",
"registerFailed": "注册失败,请检查输入",
"setupFailed": "初始化失败,请检查输入",
"migrateFailed": "迁移失败,请检查输入",
"passwordMismatch": "两次输入的密码不一致",
"registerSuccess": "注册成功",
"errors": {
"invalidUsername": "用户名需为 3–32 位字母、数字或下划线",
"invalidPassword": "密码至少 8 位"
}
},
"setup": {
"migrateTitle": "迁移到账号密码登录",
"initTitle": "首次使用,创建管理员账号",
"usernamePlaceholder": "3–32 位字母、数字或下划线",
"passwordPlaceholder": "设置登录密码",
"confirmPlaceholder": "再次输入密码",
"allowRegistration": "允许其他用户注册",
"migrateSubmit": "完成迁移",
"initSubmit": "创建并进入",
"migrateSuccess": "账号迁移完成",
"initSuccess": "初始化完成"
},
"register": {
"title": "注册账号",
"subtitle": "创建 PicHost 用户账号"
},
"password": {
"title": "修改密码",
"subtitle": "修改您的登录密码",
"current": "当前密码",
"new": "新密码",
"confirmNew": "确认新密码",
"newPlaceholder": "设置新密码",
"mismatch": "两次输入的新密码不一致",
"changed": "密码已修改",
"tooShort": "新密码至少 8 位",
"changeFailed": "修改密码失败",
"strength": "密码强度",
"weak": "弱",
"medium": "中",
"strong": "强",
"ruleMinLength": "至少 {n} 个字符",
"ruleMixedCase": "包含大小写字母",
"ruleNumber": "包含数字",
"ruleSpecial": "包含特殊字符"
},
"upload": {
"title": "拖拽图片到此处上传",
"hint": "或点击选择文件,按 {ctrl} + {v} 粘贴图片",
"formats": "支持 JPEG / PNG / WebP / GIF / SVG / ICO,单张最大 10 MB,每次最多 10 张",
"selectFiles": "选择图片",
"settings": "上传设置",
"progress": "上传进度",
"statusPending": "等待",
"statusUploading": "上传中",
"statusSuccess": "成功",
"statusError": "失败",
"selectImages": "请选择图片",
"maxFiles": "每次最多上传 {n} 张图片",
"uploadSuccess": "成功上传 {n} 张图片",
"uploadPartialFail": "{n} 张图片上传失败",
"uploadFailed": "上传失败",
"loginRequired": "请先登录",
"sessionTitle": "本次上传",
"sessionEmpty": "暂无本次上传"
},
"copy": {
"url": "直链",
"markdown": "Markdown",
"html": "HTML",
"copied": "已复制到剪贴板",
"copiedLabel": "已复制 {label}",
"copiedUrl": "已复制直链",
"copiedMarkdown": "已复制 Markdown",
"copiedHtml": "已复制 HTML",
"copiedFormat": "已复制 {format}",
"failed": "复制失败",
"failedManual": "复制失败,请手动选中链接复制",
"curl": "已复制 cURL 示例"
},
"preferences": {
"title": "上传偏好",
"subtitle": "浏览器本地与账号设置,仅影响您的上传体验",
"back": "返回上传",
"processing": "图片处理",
"clientCompress": "客户端预压缩",
"clientCompressHint": "上传前在浏览器端压缩(服务端仍会转 WebP)",
"autoDeletePrefix": "自动删除超过",
"autoDeleteSuffix": "天的图片",
"autoDeleteHint": "仅清理开启后上传的图片,不影响此前已存的图片",
"webpQuality": "WebP 压缩质量",
"webpQualityHint": "客户端预压缩质量(1–100),需开启「客户端预压缩」",
"current": "当前:{n}",
"qualityHigh": "高质量",
"qualityMedium": "中等质量",
"qualityLow": "有损压缩",
"convenience": "便捷功能",
"autoCopy": "上传成功自动复制链接",
"autoCopyHint": "按所选格式复制到剪贴板"
},
"settings": {
"title": "系统设置",
"subtitle": "保存后写入数据库;环境变量优先级更高",
"uploadAccount": "上传与账号",
"defaultFolder": "默认上传目录",
"defaultFolderHint": "保存在本机浏览器,仅影响您的上传目标目录",
"allowRegistration": "开放用户注册",
"allowRegistrationHint": "允许新用户自行注册(普通用户仅可见自己的图片)",
"accessControl": "访问控制",
"refererHint": "Referer 防盗链,逗号分隔允许引用的域名,留空不限制",
"refererPlaceholder": "example.com, www.example.com",
"linkGeneration": "链接生成",
"imageBaseUrlHint": "生成图片链接的 URL 前缀,内网访问建议填公网域名",
"imageBaseUrlPlaceholder": "https://pic.example.com",
"imageBaseUrlActive": "当前生效:{url}",
"badgeEnv": ".env",
"badgeSaved": "已保存",
"badgeDefault": "默认",
"badgeUnset": "未设置",
"tokenEnv": "环境变量",
"tokenDb": "后台生成",
"tokenNone": "未配置",
"apiTokenLine": "API Token · {source} · v{version}",
"unsavedChanges": "有未保存的更改",
"manageToken": "管理 Token",
"envOverride": "该项已由环境变量覆盖,无法在后台修改",
"saved": "服务器配置已保存",
"saveFailed": "保存服务器配置失败",
"loadFailed": "加载设置失败"
},
"stats": {
"title": "统计",
"subtitle": "数据概览与图库记录",
"uploadToday": "今日上传",
"uploadMonth": "本月上传",
"uploadTotal": "累计上传",
"storedCount": "当前库存",
"deleteToday": "今日删除",
"deleteMonth": "本月删除",
"deleteTotal": "累计删除",
"userCount": "注册用户数量",
"uploadBytes": "累计上传体积",
"folderDistribution": "上传目录分布",
"folderUsage": "目录占用",
"noData": "暂无数据",
"folderCount": "{count} 张 · {size}",
"gallery": "图库记录",
"folder": "目录",
"searchPlaceholder": "搜索文件名",
"clear": "清除",
"selected": "已选 {n}",
"batchDelete": "批量删除",
"scrollTop": "回到顶部",
"loadFailed": "加载统计失败",
"selectFirst": "请先选择图片",
"deleted": "已删除 {n} 张图片",
"deletePartialFail": "{n} 张图片删除失败",
"deleteFailed": "删除失败",
"deletedSingle": "已删除",
"allFolders": "全部",
"counting": "统计中…",
"summarySearch": "{folder} · 搜索「{q}」· 共 {total} 张",
"summaryTotal": "{folder} · 共 {total} 张"
},
"image": {
"empty": "暂无图片",
"previewFailed": "预览失败",
"uploader": "上传者:{name}"
},
"delete": {
"confirmTitle": "确认删除",
"confirmDesc": "确定要删除选中的 {count} 张图片吗?此操作不可恢复。",
"confirm": "确认删除"
},
"pagination": {
"pageOf": "第 {page} / {totalPages} 页 · 共 {total} {unit}",
"totalOnly": "共 {total} {unit}",
"first": "第一页",
"prev": "上一页",
"next": "下一页",
"last": "最后一页"
},
"api": {
"tokenTitle": "API Token",
"envOverrideTitle": "Token 由环境变量覆盖",
"envOverrideDesc": "修改 API_UPLOAD_TOKEN 后需重启服务;后台无法重新生成。",
"personalTitle": "个人 API Token",
"personalDesc": "此 Token 仅用于您自己的脚本上传,上传的图片归属您的账号。",
"notConfiguredTitle": "尚未配置 Token",
"notConfiguredDesc": "点击「重新生成」创建 Token,用于下方所有接口的 Auth-Token 鉴权。",
"regenerate": "重新生成",
"tokenSourceEnv": "来源:环境变量 API_UPLOAD_TOKEN",
"tokenSourceDb": "来源:后台生成(可重新生成)",
"tokenSourceNone": "来源:未配置",
"tokenHeader": "请求头:",
"tokenInvalidate": "重新生成后旧 Token 立即失效",
"docsTitle": "API 文档",
"curlExample": "cURL 示例",
"loadFailed": "加载 API 设置失败",
"regenerateEnvBlocked": "环境变量已配置 Token,无法在后台重新生成",
"regenerateFailed": "重新生成 Token 失败",
"confirmRegenerateTitle": "确认重新生成 Token?",
"confirmRegenerateDesc": "旧 Token 将立即失效,使用旧 Token 的脚本与自动化任务将无法继续调用接口,直到你更新为新 Token。",
"confirmRegenerate": "确认重新生成",
"newTokenTitle": "新 Token 已生成",
"newTokenDesc": "请立即复制保存。关闭弹窗后仍可在上方输入框复制,但请尽快更新到你的脚本配置中。",
"copyToken": "复制 Token",
"saved": "我已保存",
"docs": {
"upload": {
"title": "上传图片",
"descAdmin": "上传单张或多张图片。字段 image 传图片,folder 指定目录(不存在则自动创建);仍兼容 file、files、type。",
"descUser": "上传单张或多张图片。字段 image 传图片;仍兼容 file、files。图片固定存入 images/ 目录。"
},
"list": {
"title": "获取图片列表",
"descAdmin": "分页列出图库,folder 可筛选目录,limit 默认 20、最大 100。",
"descUser": "分页列出您的图库,limit 默认 20、最大 100。"
},
"search": {
"title": "搜索图片",
"desc": "按文件名或路径关键词搜索,参数 q 必填。"
},
"delete": {
"title": "删除图片",
"desc": "通过 key 删除单张图片,key 为存储路径(如 images/2026/08/xxx.webp)。"
},
"batchDelete": {
"title": "批量删除",
"desc": "一次删除多张图片,请求体为 keys 数组。"
},
"twikoo": {
"title": "twikoo 兼容上传",
"desc": "兼容 Twikoo / EasyImage 2.0 协议,图片存入 twikoo/ 目录;字段 image + token。"
}
}
},
"userSettings": {
"loadFailed": "加载设置失败",
"saveFailed": "保存设置失败"
}
}