Rename "MultiValueButton" props to "SelectButton" props

This commit is contained in:
schroda
2026-06-02 13:39:47 +02:00
parent d8a4227d13
commit 1228b5ac2a
11 changed files with 27 additions and 28 deletions

View File

@@ -22,7 +22,7 @@ import {
READER_PAGE_SCALE_MODE_VALUES,
} from '@/features/reader/settings/ReaderSettings.constants.tsx';
import { CustomIconButton } from '@/base/components/buttons/CustomIconButton.tsx';
import type { MultiValueButtonDefaultableProps } from '@/base/components/buttons/SelectButton.tsx';
import type { SelectButtonDefaultableProps } from '@/base/components/buttons/SelectButton.tsx';
export const ReaderNavBarDesktopPageScale = ({
pageScaleMode,
@@ -30,7 +30,7 @@ export const ReaderNavBarDesktopPageScale = ({
updateSetting,
...buttonSelectInputProps
}: Pick<IReaderSettingsWithDefaultFlag, 'pageScaleMode' | 'shouldStretchPage'> &
Pick<MultiValueButtonDefaultableProps<ReaderPageScaleMode>, 'isDefaultable' | 'onDefault'> & {
Pick<SelectButtonDefaultableProps<ReaderPageScaleMode>, 'isDefaultable' | 'onDefault'> & {
updateSetting: <Setting extends keyof Pick<IReaderSettings, 'pageScaleMode' | 'shouldStretchPage'>>(
setting: Setting,
value: IReaderSettings[Setting],

View File

@@ -14,14 +14,14 @@ import {
READING_DIRECTION_VALUE_TO_DISPLAY_DATA,
} from '@/features/reader/settings/ReaderSettings.constants.tsx';
import type { MultiValueButtonDefaultableProps } from '@/base/components/buttons/SelectButton.tsx';
import type { SelectButtonDefaultableProps } from '@/base/components/buttons/SelectButton.tsx';
export const ReaderNavBarDesktopReadingDirection = ({
readingDirection,
setReadingDirection,
...buttonSelectInputProps
}: Pick<IReaderSettingsWithDefaultFlag, 'readingDirection'> &
Pick<MultiValueButtonDefaultableProps<ReadingDirection>, 'isDefaultable' | 'onDefault'> & {
Pick<SelectButtonDefaultableProps<ReadingDirection>, 'isDefaultable' | 'onDefault'> & {
setReadingDirection: (readingDirection: ReadingDirection) => void;
}) => {
const { t } = useLingui();

View File

@@ -14,14 +14,14 @@ import {
READING_MODE_VALUES,
} from '@/features/reader/settings/ReaderSettings.constants.tsx';
import type { MultiValueButtonDefaultableProps } from '@/base/components/buttons/SelectButton.tsx';
import type { SelectButtonDefaultableProps } from '@/base/components/buttons/SelectButton.tsx';
export const ReaderNavBarDesktopReadingMode = ({
readingMode,
setReadingMode,
...buttonSelectInputProps
}: Pick<IReaderSettingsWithDefaultFlag, 'readingMode'> &
Pick<MultiValueButtonDefaultableProps<ReadingMode>, 'isDefaultable' | 'onDefault'> & {
Pick<SelectButtonDefaultableProps<ReadingMode>, 'isDefaultable' | 'onDefault'> & {
setReadingMode: (mode: ReadingMode) => void;
}) => {
const { t } = useLingui();