diff options
| author | HJ <30-hj@users.noreply.git.pleroma.social> | 2022-03-31 17:45:29 +0000 |
|---|---|---|
| committer | HJ <30-hj@users.noreply.git.pleroma.social> | 2022-03-31 17:45:29 +0000 |
| commit | f71f101fce21ec053d46556928393a5f05f16239 (patch) | |
| tree | 7b880c9c76502c57d455e81a8477e273d8178049 /src/components/font_control/font_control.js | |
| parent | 1d1ea7e703891ec48dfcbd2fc8090656cef1e36a (diff) | |
| parent | afdc61b9b7088f5d9880a4a8466461bd8c5aeb78 (diff) | |
Merge branch 'vue3-again' into 'develop'
Migration to Vue 3 (again)
See merge request pleroma/pleroma-fe!1385
Diffstat (limited to 'src/components/font_control/font_control.js')
| -rw-r--r-- | src/components/font_control/font_control.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/components/font_control/font_control.js b/src/components/font_control/font_control.js index 137ef9c0..92ee3f30 100644 --- a/src/components/font_control/font_control.js +++ b/src/components/font_control/font_control.js @@ -1,4 +1,4 @@ -import { set } from 'vue' +import { set } from 'lodash' import Select from '../select/select.vue' export default { @@ -6,11 +6,12 @@ export default { Select }, props: [ - 'name', 'label', 'value', 'fallback', 'options', 'no-inherit' + 'name', 'label', 'modelValue', 'fallback', 'options', 'no-inherit' ], + emits: ['update:modelValue'], data () { return { - lValue: this.value, + lValue: this.modelValue, availableOptions: [ this.noInherit ? '' : 'inherit', 'custom', @@ -22,7 +23,7 @@ export default { } }, beforeUpdate () { - this.lValue = this.value + this.lValue = this.modelValue }, computed: { present () { @@ -37,7 +38,7 @@ export default { }, set (v) { set(this.lValue, 'family', v) - this.$emit('input', this.lValue) + this.$emit('update:modelValue', this.lValue) } }, isCustom () { |
