Browse Source

Dashboard: Fix accessibility skip links

Signed-off-by: Jan C. Borchardt <hey@jancborchardt.net>
tags/v21.0.0beta1
Jan C. Borchardt 3 years ago
parent
commit
caf284dd2e
No account linked to committer's email address

+ 9
- 0
apps/dashboard/css/dashboard.scss View File

@@ -1,3 +1,12 @@
// Suppress "Skip to navigation of app" link since the app does not have a navigation
.skip-navigation:not(.skip-content) {
display: none;
}
// Fix position of "Skip to main content" link since the other link is gone
.skip-navigation.skip-content {
left: 3px;
}

#header {
background: transparent !important;
--color-header: rgba(24, 24, 24, 1);

+ 1
- 1
apps/dashboard/js/dashboard.js
File diff suppressed because it is too large
View File


+ 1
- 1
apps/dashboard/js/dashboard.js.map
File diff suppressed because it is too large
View File


+ 5
- 0
apps/dashboard/src/App.vue View File

@@ -215,6 +215,7 @@ export default {
},
mounted() {
this.updateGlobalStyles()
this.updateSkipLink()
window.addEventListener('scroll', this.handleScroll)

setInterval(() => {
@@ -321,6 +322,10 @@ export default {
document.body.classList.remove('dashboard--dark')
}
},
updateSkipLink() {
// Make sure "Skip to main content" link points to the app content
document.getElementsByClassName('skip-navigation')[0].setAttribute('href', '#app-dashboard')
},
updateStatusCheckbox(app, checked) {
if (checked) {
this.enableStatus(app)

Loading…
Cancel
Save