logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe git clone https://hacktivis.me/git/pleroma-fe.git
commit: ccd7378347594d3e1e38f8716ce83a4068a65057
parent 8e711e05875f9be5b46437a4b38ea98b94cf4306
Author: Henry Jameson <me@hjkos.com>
Date:   Sun, 27 Mar 2022 13:28:59 +0300

fix (roundness) ranges in theme tab

Diffstat:

Msrc/components/range_input/range_input.vue13+++++++------
1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/src/components/range_input/range_input.vue b/src/components/range_input/range_input.vue @@ -14,8 +14,8 @@ :id="name + '-o'" class="opt" type="checkbox" - :modelValue="present" - @input="$emit('update:modelValue', !present ? fallback : undefined)" + :checked="present" + @change="$emit('update:modelValue', !present ? fallback : undefined)" > <label v-if="typeof fallback !== 'undefined'" @@ -26,7 +26,7 @@ :id="name" class="input-number" type="range" - :value="value || fallback" + :value="modelValue || fallback" :disabled="!present || disabled" :max="max || hardMax || 100" :min="min || hardMin || 0" @@ -37,7 +37,7 @@ :id="name" class="input-number" type="number" - :value="value || fallback" + :value="modelValue || fallback" :disabled="!present || disabled" :max="hardMax" :min="hardMin" @@ -50,11 +50,12 @@ <script> export default { props: [ - 'name', 'value', 'fallback', 'disabled', 'label', 'max', 'min', 'step', 'hardMin', 'hardMax' + 'name', 'modelValue', 'fallback', 'disabled', 'label', 'max', 'min', 'step', 'hardMin', 'hardMax' ], + emits: ['update:modelValue'], computed: { present () { - return typeof this.value !== 'undefined' + return typeof this.modelValue !== 'undefined' } } }