fix(studio-ds): P5 评审收口——a11y + 文案 + 注释清理

- 补 icon-only 按钮 aria-label:Feed 上/下切换(common.action.prev/next)
- GameCard 封面播放区键盘可达:role=button/tabindex/aria-label/@keydown.enter.space
- 新增 common.action.prev/next 中英文案;删 InteractBar 过期注释(flag 已补)

P5 of HJ-FE-DS-001。opus 评审无 P0、逻辑保真经机器 diff 实证;修 P1-1 无障碍。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
zizi 2026-06-16 16:24:58 +00:00
parent caa2e1ba03
commit 87f00323ce
5 changed files with 9 additions and 5 deletions

View File

@ -62,8 +62,12 @@ const fallbackVars = computed<Record<string, string>>(() => {
<!-- 封面(首屏即玩入口,点击进试玩) -->
<div
class="game-card__cover"
role="button"
tabindex="0"
:aria-label="card.title"
:style="{ backgroundImage: hasCover ? `url(${card.coverUrl})` : undefined }"
@click="emit('play', { gameId: card.gameId, versionId: card.versionId })"
@keydown.enter.space.prevent="emit('play', { gameId: card.gameId, versionId: card.versionId })"
>
<!-- 无封面(含 1×1 占位图)时的渐变底纹兜底:按 hash 选主题渐变 + 柔光点(::before) + 波形(::after) + 标题 -->
<div

View File

@ -45,7 +45,7 @@ const { t } = useI18n()
<span class="interact-bar__icon"><Icon name="share" :size="22" /></span>
<span class="interact-bar__label">{{ t('feed.share') }}</span>
</button>
<!-- 举报(action=4):缺 flag 图标,name='flag' 暂渲空 SVG(Icon 对未知名零报错),待主代理补登记 -->
<!-- 举报(action=4):flag 图标 -->
<button class="interact-bar__item" @click="emit('interact', 4)">
<span class="interact-bar__icon"><Icon name="flag" :size="22" /></span>
<span class="interact-bar__label">{{ t('feed.report') }}</span>

View File

@ -5,7 +5,7 @@ export default {
common: {
brand: 'ZaoMeng AI',
nav: { feed: 'Feed', create: 'Create', message: 'Inbox', me: 'Me', discover: 'Discover' },
action: { play: 'Play now', share: 'Share', save: 'Save', submit: 'Submit', cancel: 'Cancel', confirm: 'Confirm', back: 'Back', retry: 'Retry', more: 'More' },
action: { play: 'Play now', share: 'Share', save: 'Save', submit: 'Submit', cancel: 'Cancel', confirm: 'Confirm', back: 'Back', retry: 'Retry', more: 'More', prev: 'Previous', next: 'Next' },
state: { loading: 'Loading', empty: 'Nothing here yet', saved: 'Saved', failed: 'Failed', success: 'Success' },
status: { draft: 'Draft', review: 'In review', published: 'Published', rejected: 'Rejected' },
},

View File

@ -6,7 +6,7 @@ export default {
common: {
brand: '造梦AI',
nav: { feed: '游戏流', create: '创作', message: '消息', me: '我的', discover: '发现' },
action: { play: '立即玩', share: '分享', save: '保存', submit: '提交', cancel: '取消', confirm: '确定', back: '返回', retry: '重试', more: '更多' },
action: { play: '立即玩', share: '分享', save: '保存', submit: '提交', cancel: '取消', confirm: '确定', back: '返回', retry: '重试', more: '更多', prev: '上一个', next: '下一个' },
state: { loading: '加载中', empty: '这里还没有内容', saved: '已保存', failed: '失败', success: '成功' },
status: { draft: '草稿', review: '审核中', published: '已发布', rejected: '已驳回' },
},

View File

@ -269,10 +269,10 @@ function onPlay(payload: { gameId: number; versionId: number }): void {
<!-- 上/下切换按钮(竖屏右下,兜底非触摸滑动场景,如桌面验证) -->
<div v-if="list.length > 1" class="feed__nav">
<!-- 上/下切换:复用 chevron(右向)旋转 -90°/90° 成上/下箭头,杀 emoji 字形 -->
<button class="feed__nav-btn" :disabled="activeIndex <= 0" @click="go(-1)">
<button class="feed__nav-btn" :disabled="activeIndex <= 0" :aria-label="t('common.action.prev')" @click="go(-1)">
<Icon name="chevron" :size="16" class="feed__nav-ico feed__nav-ico--up" />
</button>
<button class="feed__nav-btn" :disabled="activeIndex >= list.length - 1" @click="go(1)">
<button class="feed__nav-btn" :disabled="activeIndex >= list.length - 1" :aria-label="t('common.action.next')" @click="go(1)">
<Icon name="chevron" :size="16" class="feed__nav-ico feed__nav-ico--down" />
</button>
</div>