1
0

Update components/settings/SettingsFontSize.vue

Co-authored-by: 三咲智子 Kevin Deng <sxzz@sxzz.moe>
This commit is contained in:
wheat 2023-01-12 11:03:26 -05:00 committed by GitHub
parent 799d157424
commit 16c316b0e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -5,9 +5,9 @@ import type { FontSize } from '~/types'
const sizes = ['xs', 'sm', 'md', 'lg', 'xl'] as FontSize[]
const fontSize = useFontSizeRef()
const setFontSize = (e: any) => {
if ('valueAsNumber' in e.target)
fontSize.value = sizes[e.target.valueAsNumber]
const setFontSize = (e: Event) => {
if (e.target && 'valueAsNumber' in e.target)
fontSize.value = sizes[e.target.valueAsNumber as number]
}
</script>