improve font control

This commit is contained in:
Henry Jameson 2025-11-24 16:06:09 +02:00
commit fba7d15a2c
2 changed files with 15 additions and 13 deletions

View file

@ -1,13 +1,5 @@
<template> <template>
<div class="font-control"> <div class="font-control">
<label
:id="name + '-label'"
:for="manualEntry ? name : name + '-font-switcher'"
class="label"
>
{{ $t('settings.style.themes3.font.label', { label }) }}
</label>
{{ ' ' }}
<Checkbox <Checkbox
v-if="typeof fallback !== 'undefined'" v-if="typeof fallback !== 'undefined'"
:id="name + '-o'" :id="name + '-o'"
@ -15,8 +7,15 @@
:model-value="present" :model-value="present"
@change="$emit('update:modelValue', typeof modelValue === 'undefined' ? fallback : undefined)" @change="$emit('update:modelValue', typeof modelValue === 'undefined' ? fallback : undefined)"
> >
{{ $t('settings.style.themes3.define') }} <i18n-t
scope="global"
keypath="settings.style.fonts.override"
tag="span"
>
{{ label }}
</i18n-t>
</Checkbox> </Checkbox>
{{ ' ' }}
<div <div
v-if="modelValue?.family" v-if="modelValue?.family"
class="font-input" class="font-input"
@ -143,10 +142,6 @@
margin-left: 2em; margin-left: 2em;
margin-top: 0.5em; margin-top: 0.5em;
} }
.font-checkbox {
margin-left: 1em;
}
} }
.invalid-tooltip { .invalid-tooltip {

View file

@ -1079,6 +1079,13 @@
"post": "Post text", "post": "Post text",
"monospace": "Monospaced text" "monospace": "Monospaced text"
}, },
"components_inline": {
"interface": "interface",
"input": "input fields",
"post": "post text",
"monospace": "monospaced text"
},
"override": "Override {0} font",
"family": "Font name", "family": "Font name",
"size": "Size (in px)", "size": "Size (in px)",
"weight": "Weight (boldness)", "weight": "Weight (boldness)",