summaryrefslogtreecommitdiffstats
path: root/apps/files/src/components
diff options
context:
space:
mode:
authorEduardo Morales <emoral435@gmail.com>2023-12-19 08:33:22 -0600
committerjulia.kirschenheuter <julia.kirschenheuter@nextcloud.com>2023-12-28 11:21:29 +0100
commit40ee6ce44967a92197a3a349a7cf6b42ec67a3c6 (patch)
tree6486e4cf510d5d432c2e069283acb455bf7b4a9e /apps/files/src/components
parente279d4519692a80906f3b57b784ce494e0ff13e0 (diff)
downloadnextcloud-server-40ee6ce44967a92197a3a349a7cf6b42ec67a3c6.tar.gz
nextcloud-server-40ee6ce44967a92197a3a349a7cf6b42ec67a3c6.zip
enh(breadcrumbs): removed unnecessary aria label
Signed-off-by: Eduardo Morales <emoral435@gmail.com>
Diffstat (limited to 'apps/files/src/components')
-rw-r--r--apps/files/src/components/BreadCrumbs.vue16
1 files changed, 11 insertions, 5 deletions
diff --git a/apps/files/src/components/BreadCrumbs.vue b/apps/files/src/components/BreadCrumbs.vue
index bed8f104e96..9931642342c 100644
--- a/apps/files/src/components/BreadCrumbs.vue
+++ b/apps/files/src/components/BreadCrumbs.vue
@@ -1,14 +1,17 @@
<template>
- <NcBreadcrumbs data-cy-files-content-breadcrumbs>
+ <NcBreadcrumbs
+ data-cy-files-content-breadcrumbs
+ :aria-label="t('files', 'Current directory path')">
<!-- Current path sections -->
<NcBreadcrumb v-for="(section, index) in sections"
:key="section.dir"
- :aria-label="ariaLabel(section)"
- :title="ariaLabel(section)"
v-bind="section"
+ dir="auto"
+ :to="section.to"
+ :title="titleForSection(section)"
@click.native="onClick(section.to)">
<template v-if="index === 0" #icon>
- <Home :size="20" />
+ <Home :size="20"/>
</template>
</NcBreadcrumb>
@@ -20,6 +23,7 @@
</template>
<script>
+import { translate as t} from '@nextcloud/l10n'
import { basename } from 'path'
import Home from 'vue-material-design-icons/Home.vue'
import NcBreadcrumb from '@nextcloud/vue/dist/Components/NcBreadcrumb.js'
@@ -104,12 +108,14 @@ export default Vue.extend({
}
},
- ariaLabel(section) {
+ titleForSection(section) {
if (section?.to?.query?.dir === this.$route.query.dir) {
return t('files', 'Reload current directory')
}
return t('files', 'Go to the "{dir}" directory', section)
},
+
+ t,
},
})
</script>