feat: 增加無障礙標籤及ARIA屬性以改善可訪問性
This commit is contained in:
@@ -42,7 +42,11 @@
|
||||
<div v-if="features.showToolbarActions" class="top-actions">
|
||||
<slot name="actions">
|
||||
<!-- 通知 -->
|
||||
<v-tooltip location="bottom" :text="toolbarActions.notificationsLabel">
|
||||
<v-tooltip
|
||||
location="bottom"
|
||||
:text="toolbarActions.notificationsLabel"
|
||||
:aria-label="toolbarActions.notificationsLabel"
|
||||
>
|
||||
<template #activator="{ props: activatorProps }">
|
||||
<v-btn
|
||||
v-bind="activatorProps"
|
||||
@@ -67,7 +71,11 @@
|
||||
</v-tooltip>
|
||||
|
||||
<!-- 訊息 -->
|
||||
<v-tooltip location="bottom" :text="toolbarActions.messagesLabel">
|
||||
<v-tooltip
|
||||
location="bottom"
|
||||
:text="toolbarActions.messagesLabel"
|
||||
:aria-label="toolbarActions.messagesLabel"
|
||||
>
|
||||
<template #activator="{ props: activatorProps }">
|
||||
<v-btn
|
||||
v-bind="activatorProps"
|
||||
@@ -110,7 +118,11 @@
|
||||
<!-- 設定 -->
|
||||
<v-menu :close-on-content-click="false" location="bottom end">
|
||||
<template #activator="{ props: menuProps }">
|
||||
<v-tooltip location="bottom" :text="toolbarActions.settingsLabel">
|
||||
<v-tooltip
|
||||
location="bottom"
|
||||
:text="toolbarActions.settingsLabel"
|
||||
:aria-label="toolbarActions.settingsLabel"
|
||||
>
|
||||
<template #activator="{ props: tooltipProps }">
|
||||
<v-btn
|
||||
v-bind="{ ...menuProps, ...tooltipProps }"
|
||||
@@ -154,7 +166,7 @@
|
||||
</v-menu>
|
||||
|
||||
<!-- 登出 -->
|
||||
<v-tooltip location="bottom" :text="logoutLabel">
|
||||
<v-tooltip location="bottom" :text="logoutLabel" :aria-label="logoutLabel">
|
||||
<template #activator="{ props: activatorProps }">
|
||||
<v-btn
|
||||
v-bind="activatorProps"
|
||||
@@ -169,7 +181,12 @@
|
||||
</template>
|
||||
</v-tooltip>
|
||||
|
||||
<v-tooltip v-if="features.showThemeToggle" location="bottom" :text="themeToggleLabel">
|
||||
<v-tooltip
|
||||
v-if="features.showThemeToggle"
|
||||
location="bottom"
|
||||
:text="themeToggleLabel"
|
||||
:aria-label="themeToggleLabel"
|
||||
>
|
||||
<template #activator="{ props: activatorProps }">
|
||||
<v-btn
|
||||
v-bind="activatorProps"
|
||||
|
||||
Reference in New Issue
Block a user