Skip to content

Commit

Permalink
rename interface in PresetIcon component, generate again package-lock…
Browse files Browse the repository at this point in the history
….json
  • Loading branch information
bohdanprog committed May 16, 2024
1 parent 1addb3d commit fd0bb67
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/frontend/sharedComponents/icons/PresetIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {UIActivityIndicator} from 'react-native-indicators';
import {useGetPresetIcon} from '../../hooks/server/presets';
import MaterialIcon from 'react-native-vector-icons/MaterialIcons';

interface CategoryIconProps {
interface PresetIconProps {
size?: IconSize;
name?: string;
}
Expand All @@ -24,7 +24,7 @@ const radii = {
large: 35,
};

export const PresetIcon = memo<CategoryIconProps>(({size = 'medium', name}) => {
export const PresetIcon = memo<PresetIconProps>(({size = 'medium', name}) => {
const iconSize = iconSizes[size] || 35;
const {data, isLoading} = useGetPresetIcon(size, name);
const [error, setError] = React.useState(false);
Expand All @@ -44,10 +44,7 @@ export const PresetIcon = memo<CategoryIconProps>(({size = 'medium', name}) => {
);
});

export const PresetCircleIcon = ({
name,
size = 'medium',
}: CategoryIconProps) => {
export const PresetCircleIcon = ({name, size = 'medium'}: PresetIconProps) => {
return (
<Circle radius={radii[size]}>
<PresetIcon name={name} size={size} />
Expand Down

0 comments on commit fd0bb67

Please sign in to comment.