Fix html rendering and default checkbox

Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
This commit is contained in:
John Molakvoæ (skjnldsv) 2019-02-21 16:31:50 +01:00
parent 0816123f67
commit 50e5f7ca9e
No known key found for this signature in database
GPG Key ID: 60C25B8C072916CF
4 changed files with 21 additions and 6 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -50,13 +50,28 @@ export default {
}; };
}, },
description() { description() {
return t('accessibility', 'Universal access is very important to us. We follow web standards and check to make everything usable also without mouse, and assistive software such as screenreaders. We aim to be compliant with the {guidelines} 2.1 on AA level, with the high contrast theme even on AAA level.', {guidelines: this.guidelinesLink}) // using the `t` replace method escape html, we have to do it manually :/
return t(
'accessibility',
`Universal access is very important to us. We follow web standards
and check to make everything usable also without mouse,
and assistive software such as screenreaders.
We aim to be compliant with the {guidelines} 2.1 on AA level,
with the high contrast theme even on AAA level.`
)
.replace('{guidelines}', this.guidelinesLink)
}, },
guidelinesLink() { guidelinesLink() {
return `<a target="_blank" href="https://www.w3.org/WAI/standards-guidelines/wcag/" rel="noreferrer nofollow">${t('accessibility', 'Web Content Accessibility Guidelines')}</a>` return `<a target="_blank" href="https://www.w3.org/WAI/standards-guidelines/wcag/" rel="noreferrer nofollow">${t('accessibility', 'Web Content Accessibility Guidelines')}</a>`
}, },
descriptionDetail() { descriptionDetail() {
return t('accessibility', 'If you find any issues, dont hesitate to report them on {issuetracker}. And if you want to get involved, come join {designteam}!', {issuetracker: this.issuetrackerLink, designteam: this.designteamLink}) return t(
'accessibility',
`If you find any issues, dont hesitate to report them on {issuetracker}.
And if you want to get involved, come join {designteam}!`
)
.replace('{issuetracker}', this.issuetrackerLink)
.replace('{designteam}', this.designteamLink)
}, },
issuetrackerLink() { issuetrackerLink() {
return `<a target="_blank" href="https://github.com/nextcloud/server/issues/" rel="noreferrer nofollow">${t('accessibility', 'our issue tracker')}</a>` return `<a target="_blank" href="https://github.com/nextcloud/server/issues/" rel="noreferrer nofollow">${t('accessibility', 'our issue tracker')}</a>`

View File

@ -4,7 +4,7 @@
<div class="preview-description"> <div class="preview-description">
<h3>{{preview.title}}</h3> <h3>{{preview.title}}</h3>
<p>{{preview.text}}</p> <p>{{preview.text}}</p>
<input type="checkbox" class="checkbox" :id="'accessibility-' + preview.id" v-model="selected" /> <input type="checkbox" class="checkbox" :id="'accessibility-' + preview.id" :checked="selected === preview.id" />
<label :for="'accessibility-' + preview.id" @click="selectItem">{{t('accessibility', 'Enable')}} {{preview.title.toLowerCase()}}</label> <label :for="'accessibility-' + preview.id" @click="selectItem">{{t('accessibility', 'Enable')}} {{preview.title.toLowerCase()}}</label>
</div> </div>
</div> </div>