Update components/settings/SettingsFontSize.vue
Co-authored-by: 三咲智子 Kevin Deng <sxzz@sxzz.moe>
This commit is contained in:
parent
799d157424
commit
16c316b0e3
@ -5,9 +5,9 @@ import type { FontSize } from '~/types'
|
|||||||
const sizes = ['xs', 'sm', 'md', 'lg', 'xl'] as FontSize[]
|
const sizes = ['xs', 'sm', 'md', 'lg', 'xl'] as FontSize[]
|
||||||
const fontSize = useFontSizeRef()
|
const fontSize = useFontSizeRef()
|
||||||
|
|
||||||
const setFontSize = (e: any) => {
|
const setFontSize = (e: Event) => {
|
||||||
if ('valueAsNumber' in e.target)
|
if (e.target && 'valueAsNumber' in e.target)
|
||||||
fontSize.value = sizes[e.target.valueAsNumber]
|
fontSize.value = sizes[e.target.valueAsNumber as number]
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user