|
@@ -1,6 +1,7 @@
|
|
|
import React, { FormEvent } from 'react';
|
|
|
import { IconButton } from '../button/IconButton';
|
|
|
import styles from './caloriesInput.css';
|
|
|
+import { iconTypes } from '../icon/iconTypes';
|
|
|
|
|
|
type CaloriesInputProps = {
|
|
|
addCalories: (calories: { title: string, count: number }) => void,
|
|
@@ -39,8 +40,8 @@ function CaloriesInput ({addCalories, saveCalories, item}: CaloriesInputProps) {
|
|
|
} = item || {};
|
|
|
|
|
|
const buttonIcon = item
|
|
|
- ? 'tick'
|
|
|
- : 'plus';
|
|
|
+ ? iconTypes.TICK
|
|
|
+ : iconTypes.PLUS;
|
|
|
|
|
|
return (
|
|
|
<form onSubmit={onSubmit} className={styles.caloriesInput}>
|