Skip to content
Snippets Groups Projects
Unverified Commit 9872154e authored by Janis Köhr's avatar Janis Köhr
Browse files

Changed highcontrast from array (theme) to object (flag/filter)

parent 05ef7725
No related branches found
No related tags found
No related merge requests found
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
......@@ -65,14 +65,12 @@ class AccessibilityProvider {
}
public function getHighContrast() {
return array(
[
return [
'id' => 'highcontrast',
'img' => $this->urlGenerator->imagePath($this->appName, 'theme-highcontrast.jpg'),
'title' => $this->l->t('High contrast theme'),
'text' => $this->l->t('A high contrast theme to ease your navigation. Visual quality will be reduced but clarity will be increased.')
]
);
];
}
public function getFonts() {
......
......@@ -114,7 +114,7 @@ class ConfigController extends OCSController {
}
$themes = $this->accessibilityProvider->getThemes();
$highcontrast = $this->accessibilityProvider->getHighContrast();
$highcontrast = array($this->accessibilityProvider->getHighContrast());
$fonts = $this->accessibilityProvider->getFonts();
$availableOptions = array_map(function($option) {
......
......@@ -5,8 +5,8 @@
<p v-html="descriptionDetail" />
<div class="preview-list">
<preview v-for="preview in highcontrast" :preview="preview"
:key="preview.id" :selected="selected.highcontrast"
<preview :preview="highcontrast"
:key="highcontrast.id" :selected="selected.highcontrast"
v-on:select="selectHighContrast"></preview>
<preview v-for="preview in themes" :preview="preview"
:key="preview.id" :selected="selected.theme"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment