Rename "CustomButtonIcon" to "CustomIconButton"
This commit is contained in:
@@ -10,20 +10,20 @@ import type { ComponentProps } from 'react';
|
||||
import KeyboardArrowLeftIcon from '@mui/icons-material/KeyboardArrowLeft';
|
||||
import KeyboardArrowRightIcon from '@mui/icons-material/KeyboardArrowRight';
|
||||
import { CustomTooltip } from '@/base/components/CustomTooltip.tsx';
|
||||
import { CustomButtonIcon } from '@/base/components/buttons/CustomButtonIcon.tsx';
|
||||
import { CustomIconButton } from '@/base/components/buttons/CustomIconButton.tsx';
|
||||
|
||||
export const ReaderNavBarDesktopNextPreviousButton = ({
|
||||
title,
|
||||
type,
|
||||
disabled,
|
||||
...customIconButtonProps
|
||||
}: Omit<ComponentProps<typeof CustomButtonIcon>, 'children'> & {
|
||||
}: Omit<ComponentProps<typeof CustomIconButton>, 'children'> & {
|
||||
title: string;
|
||||
type: 'previous' | 'next';
|
||||
}) => (
|
||||
<CustomTooltip title={title} disabled={disabled}>
|
||||
<CustomButtonIcon sx={{ flexBasis: '15%' }} variant="contained" disabled={disabled} {...customIconButtonProps}>
|
||||
<CustomIconButton sx={{ flexBasis: '15%' }} variant="contained" disabled={disabled} {...customIconButtonProps}>
|
||||
{type === 'previous' ? <KeyboardArrowLeftIcon /> : <KeyboardArrowRightIcon />}
|
||||
</CustomButtonIcon>
|
||||
</CustomIconButton>
|
||||
</CustomTooltip>
|
||||
);
|
||||
|
||||
@@ -22,7 +22,7 @@ import {
|
||||
READER_PAGE_SCALE_MODE_VALUES,
|
||||
} from '@/features/reader/settings/ReaderSettings.constants.tsx';
|
||||
import type { MultiValueButtonDefaultableProps } from '@/base/Base.types.ts';
|
||||
import { CustomButtonIcon } from '@/base/components/buttons/CustomButtonIcon.tsx';
|
||||
import { CustomIconButton } from '@/base/components/buttons/CustomIconButton.tsx';
|
||||
|
||||
export const ReaderNavBarDesktopPageScale = ({
|
||||
pageScaleMode,
|
||||
@@ -52,14 +52,14 @@ export const ReaderNavBarDesktopPageScale = ({
|
||||
/>
|
||||
{READER_PAGE_SCALE_MODE_TO_SCALING_ALLOWED[pageScaleMode.value] && (
|
||||
<CustomTooltip title={t`Stretch small pages`}>
|
||||
<CustomButtonIcon
|
||||
<CustomIconButton
|
||||
onClick={() => updateSetting('shouldStretchPage', !shouldStretchPage.value)}
|
||||
sx={{ px: undefined }}
|
||||
variant="contained"
|
||||
color={shouldStretchPage.value ? 'secondary' : 'primary'}
|
||||
>
|
||||
<FitScreenIcon />
|
||||
</CustomButtonIcon>
|
||||
</CustomIconButton>
|
||||
</CustomTooltip>
|
||||
)}
|
||||
</Stack>
|
||||
|
||||
Reference in New Issue
Block a user