git ssb

16+

Dominic / patchbay



Tree: 2b05be8ee023fdd9580d6a845ba074a425756685

Files: 2b05be8ee023fdd9580d6a845ba074a425756685 / app / html / settings / dyslexia-fonts.js

736 bytesRaw
1const nest = require('depnest')
2const { h, when } = require('mutant')
3
4exports.gives = nest({
5 'app.html.settings': true
6})
7
8exports.needs = nest({
9 'settings.obs.get': 'first'
10})
11
12exports.create = function (api) {
13 return nest({
14 'app.html.settings': accessibility
15 })
16
17 function accessibility () {
18 const font = api.settings.obs.get('patchbay.accessibility.openDyslexicEnabled', false)
19
20 return {
21 group: 'accessibility',
22 title: 'Dyslexia Fonts',
23 body: h('AccessibilityStyles', [
24 h('div', { 'ev-click': () => font.set(!font()) }, [
25 h('label', 'Enable OpenDyslexic font'),
26 h('i.fa', { className: when(font, 'fa-check-square', 'fa-square-o') })
27 ])
28 ])
29 }
30 }
31}
32

Built with git-ssb-web