diff --git a/packages/web/components/templates/article/ReaderSettingsControl.tsx b/packages/web/components/templates/article/ReaderSettingsControl.tsx
index 6f8b2cd9a..63ad1000f 100644
--- a/packages/web/components/templates/article/ReaderSettingsControl.tsx
+++ b/packages/web/components/templates/article/ReaderSettingsControl.tsx
@@ -3,7 +3,13 @@ import { Button } from '../../elements/Button'
import { StyledText } from '../../elements/StyledText'
import { styled, theme } from '../../tokens/stitches.config'
import { useEffect, useState } from 'react'
-import { AlignCenterHorizontalSimple, ArrowsInLineHorizontal, ArrowsOutLineHorizontal, CaretRight, Cursor } from 'phosphor-react'
+import {
+ AlignCenterHorizontalSimple,
+ ArrowsInLineHorizontal,
+ ArrowsOutLineHorizontal,
+ CaretRight,
+ Cursor,
+} from 'phosphor-react'
import { TickedRangeSlider } from '../../elements/TickedRangeSlider'
import { showSuccessToast } from '../../../lib/toastHelpers'
import { FontFamiliesOptions } from './FontFamiliesOptions'
@@ -27,139 +33,246 @@ const HorizontalDivider = styled(SpanBox, {
export function ReaderSettingsControl(props: ReaderSettingsProps): JSX.Element {
const [showFontOptions, setShowFontOptions] = useState(false)
- const readeringSettings = useReaderSettings()
+ const readerSettings = useReaderSettings()
return (
{showFontOptions ? (
{
- readeringSettings.setFontFamily(font)
+ readerSettings.setFontFamily(font)
props.articleActionHandler('setFontFamily', font)
}}
/>
) : (
<>
-
-
-
-
-
- setShowFontOptions(true)}
- >
- Font:
-
- {readeringSettings.fontFamily}
-
-
-
-
-
- Margin:
-
-
-
-
-
- Line Spacing:
-
- {
- const newLineHeight = Math.max(readeringSettings.lineHeight - 25, 100)
- readeringSettings.setLineHeight(newLineHeight)
- props.articleActionHandler('setLineHeight', newLineHeight)
- }}>
-
-
- {
- readeringSettings.setLineHeight(value)
- props.articleActionHandler('setLineHeight', value)
- }} />
- {
- const newLineHeight = Math.min(readeringSettings.lineHeight + 25, 300)
- readeringSettings.setLineHeight(newLineHeight)
- props.articleActionHandler('setLineHeight', newLineHeight)
- }}>
-
+
+ props.articleActionHandler('incrementFontSize')}
+ >
+ +
-
+ setShowFontOptions(true)}
+ >
+ Font:
+
+ {readerSettings.fontFamily}
+
+
+
+
+
+
+ Margin:
+
+
+ {
+ const newMarginWith = Math.max(
+ readerSettings.marginWidth - 45,
+ 200
+ )
+ readerSettings.setMarginWidth(newMarginWith)
+ props.articleActionHandler('setMarginWidth', newMarginWith)
+ }}
+ >
+
+
+ {
+ readerSettings.setMarginWidth(value)
+ props.articleActionHandler('setMarginWidth', value)
+ }}
+ />
+ {
+ const newMarginWith = Math.min(
+ readerSettings.marginWidth + 45,
+ 560
+ )
+ readerSettings.setMarginWidth(newMarginWith)
+ props.articleActionHandler('setMarginWidth', newMarginWith)
+ }}
+ >
+
+
+
+
-
+
+ Line Spacing:
+
+
+ {
+ const newLineHeight = Math.max(
+ readerSettings.lineHeight - 25,
+ 100
+ )
+ readerSettings.setLineHeight(newLineHeight)
+ props.articleActionHandler('setLineHeight', newLineHeight)
+ }}
+ >
+
+
+ {
+ readerSettings.setLineHeight(value)
+ props.articleActionHandler('setLineHeight', value)
+ }}
+ />
+ {
+ const newLineHeight = Math.min(
+ readerSettings.lineHeight + 25,
+ 300
+ )
+ readerSettings.setLineHeight(newLineHeight)
+ props.articleActionHandler('setLineHeight', newLineHeight)
+ }}
+ >
+
+
+
+
+
+
+ {
- readeringSettings.setFontFamily('Inter')
- readeringSettings.setMarginWidth(290)
- readeringSettings.setLineHeight(150)
+ readerSettings.setFontFamily('Inter')
+ readerSettings.setMarginWidth(290)
+ readerSettings.setLineHeight(150)
props.articleActionHandler('resetReaderSettings')
- showSuccessToast('Display settings reset', { position: 'bottom-right' })
+ showSuccessToast('Display settings reset', {
+ position: 'bottom-right',
+ })
}}
>
Reset to default