Allow larger font sizes

This commit is contained in:
Jackson Harper
2023-08-25 17:21:01 +08:00
parent 7db20ebc3d
commit 2dcd4f0a64
5 changed files with 6 additions and 6 deletions

File diff suppressed because one or more lines are too long

View File

@ -203,7 +203,7 @@ public enum WebFont: String, CaseIterable {
}, label: { Image(systemName: "textformat.size.smaller") })
.frame(width: 25, height: 25, alignment: .center)
CustomSlider(value: $storedFontSize, minValue: 10, maxValue: 42) { _ in
CustomSlider(value: $storedFontSize, minValue: 10, maxValue: 48) { _ in
if storedFontSize % 1 == 0 {
updateReaderPreferences()
}

File diff suppressed because one or more lines are too long

View File

@ -208,7 +208,7 @@ export function ArticleContainer(props: ArticleContainerProps): JSX.Element {
const handleFontSizeChange = async (event: UpdateFontSizeEvent) => {
const newFontSize = event.fontSize ?? 18
if (newFontSize >= 10 && newFontSize <= 28) {
if (newFontSize >= 10 && newFontSize <= 48) {
updateFontSize(newFontSize)
}
}

View File

@ -87,12 +87,12 @@ export const useReaderSettings = (): ReaderSettings => {
switch (action) {
case 'setFontSize':
const value = Number(arg)
if (value >= 10 && value <= 34) {
if (value >= 10 && value <= 48) {
updateFontSize(value)
}
break
case 'incrementFontSize':
updateFontSize(Math.min(fontSize + 2, 34))
updateFontSize(Math.min(fontSize + 2, 48))
break
case 'decrementFontSize':
updateFontSize(Math.max(fontSize - 2, 10))