feat: add option to hide checkmark
This commit is contained in:
parent
098da30f2a
commit
f20c329962
|
@ -384,6 +384,7 @@ export default {
|
|||
disableCustomScrollbars: 'Disable custom scrollbars',
|
||||
bottomNav: 'Place the navigation bar at the bottom of the screen',
|
||||
centerNav: 'Center the navigation bar',
|
||||
hideCheckmark: 'Hide chechmark on favorite/boost buttons',
|
||||
preferences: 'Preferences',
|
||||
hotkeySettings: 'Hotkey settings',
|
||||
disableHotkeys: 'Disable all hotkeys',
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
ref:node
|
||||
>
|
||||
<SvgIcon className="icon-button-svg {svgClassName || ''}" ref:svg {href} />
|
||||
{#if checked}
|
||||
{#if showCheckmark}
|
||||
<SvgIcon className="icon-button-svg icon-button-check" ref:check href="#fa-check" />
|
||||
{/if}
|
||||
</button>
|
||||
|
@ -154,12 +154,13 @@
|
|||
sameColorWhenPressed ? 'same-pressed' : 'not-same-pressed',
|
||||
className
|
||||
)),
|
||||
ariaLabel: ({ pressable, pressed, label, pressedLabel }) => ((pressable && pressed) ? pressedLabel : label)
|
||||
ariaLabel: ({ pressable, pressed, label, pressedLabel }) => ((pressable && pressed) ? pressedLabel : label),
|
||||
showCheckmark: ({ checked, $hideCheckmark }) => (!$hideCheckmark && checked)
|
||||
},
|
||||
methods: {
|
||||
animate (animation, checkmarkAnimation) {
|
||||
this.refs.svg.animate(animation)
|
||||
if (checkmarkAnimation && this.get().checked) {
|
||||
if (checkmarkAnimation && this.get().showCheckmark) {
|
||||
this.refs.check.animate(checkmarkAnimation)
|
||||
}
|
||||
},
|
||||
|
|
|
@ -67,6 +67,11 @@
|
|||
bind:checked="$bottomNav" on:change="onChange(event)">
|
||||
{intl.bottomNav}
|
||||
</label>
|
||||
<label class="setting-group">
|
||||
<input type="checkbox" id="choice-hide-checkmark"
|
||||
bind:checked="$hideCheckmark" on:change="onChange(event)">
|
||||
{intl.hideCheckmark}
|
||||
</label>
|
||||
</form>
|
||||
|
||||
<h2>{intl.accessibility}</h2>
|
||||
|
|
|
@ -27,6 +27,7 @@ const persistedState = {
|
|||
disableTapOnStatus: false,
|
||||
enableGrayscale: false,
|
||||
hideCards: false,
|
||||
hideCheckmark: false,
|
||||
largeInlineMedia: false,
|
||||
leftRightChangesFocus: isKaiOS(),
|
||||
instanceNameInSearch: '',
|
||||
|
|
Loading…
Reference in New Issue