Files
photo-live/apps/viewer/src/i18n/locales/en.ts
T
浅念 2bb6f291d3 feat(ov,viewer): two-tier download with wechat guidance
P4a Task 4(T12 收口):ov 域公开照片下载端点 + viewer 下载 UI。

- interactions 增 downloads:GET /public/albums/{token}/photos/{photoId}
  /download?variant=browse|original。两级开关(A18):browse 需
  downloadEnabled;original 需叠加 originalDownloadEnabled(级联,browse 关
  则两者均 403 DOWNLOAD_DISABLED)。水印相册 browse 现签 watermark pattern
  key(browse-key 解析抽取 shared/ov-browse-key 与 public-ov 复用);原图
  现签 originalObjectKey(SIGNED_URL_TTL)。来源 IP 固定窗限速
  (DOWNLOAD_WINDOW_REQUESTS/DOWNLOAD_WINDOW_SECONDS,env 可调);零浏览
  计数写入(排除规则)。STORAGE_PORT_OV 经新 StorageOvModule 与 public-ov
  共享同一实例。
- 契约微调登记:PublicAlbum 增 readOnly 必返 downloadEnabled/
  originalDownloadEnabled(cn+ov 同形返回;public e2e 精确键断言同步)。
- viewer:lightbox 下载入口随开关渲染(无/单按钮/分体菜单两选项)、过期
  凭证静默重取一次、微信内置浏览器(MicroMessenger UA)出保存图片指引
  浮层(复制深链 + 反馈)替代直接下载;i18n zh/en 词条。
- tests:api e2e +7(开关矩阵 + URL/字节级断言、水印键一致、隐藏 404、
  限速 429、零计数行);viewer vitest +9(UA/矩阵/菜单/重取/失败/指引/
  复制);viewer Playwright +3(入口矩阵、微信 UA 浮层、真实端点 200 +
  签名 URL 模式)。

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-20 18:32:34 +08:00

66 lines
2.4 KiB
TypeScript

export default {
app: { title: 'Live Gallery' },
home: { hint: 'Open an album link to start viewing' },
album: {
loading: 'Loading…',
loadingMore: 'Loading more…',
emptyNotice: 'Photos coming soon',
time: 'Time',
venue: 'Venue',
views: 'Views',
categories: 'Categories',
all: 'All',
sortLabel: 'Sort',
sortLatest: 'Latest',
sortHot: 'Popular',
end: 'You have reached the end',
newPhotos: 'New photos — tap to refresh',
retry: 'Retry',
},
lang: { switch: 'Switch language' },
prefs: { reduceMotion: 'Reduce motion' },
download: {
action: 'Download photo',
original: 'Download original',
options: 'Download options',
busy: 'Preparing…',
failed: 'Download failed, please try again',
// WeChat in-app browser guidance (no programmatic download): long-press save + copy link.
wechatTitle: 'How to save this photo',
wechatHint: 'Pages opened inside WeChat cannot download directly. Long-press the photo above to save it, or copy the link and open it in a browser to download.',
copyLink: 'Copy link',
copied: 'Link copied',
copyFailed: 'Copy failed — long-press to select the link below',
dismiss: 'Got it',
},
viewer: {
title: 'Photo viewer',
close: 'Close',
previous: 'Previous photo',
next: 'Next photo',
counter: '{current} / {total}',
like: 'Like',
likeCount: '{count} likes',
bubbleOpen: 'Open the liked photo',
loadFailed: 'Failed to load image',
// PHOTO_NOT_PUBLIC 专用:not found / unpublished / hidden share one code (anti-enumeration).
photoUnavailable: 'Photo not found or unavailable',
backToAlbum: 'Back to album',
},
route: { tokenLabel: 'Album token', photoLabel: 'Photo' },
errors: {
albumNotFound: 'Album not found',
// ALBUM_NOT_PUBLIC 专用:offline / disabled / ghost token 同码(防枚举)。
albumNotAvailable: 'Album not found or offline',
photoNotFound: 'Photo not found',
notFound: 'Page not found',
authExpired: 'Session expired',
forbidden: 'Access denied',
rateLimited: 'Too many requests, please try again later',
validationFailed: 'Invalid request',
internal: 'Service temporarily unavailable, please try again later',
unknown: 'Something went wrong, please try again later',
network: 'Network error, please check your connection',
},
};