diff options
Diffstat (limited to 'src/components/Buttons/ButtonSearch/ButtonSearch.tsx')
| -rw-r--r-- | src/components/Buttons/ButtonSearch/ButtonSearch.tsx | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/src/components/Buttons/ButtonSearch/ButtonSearch.tsx b/src/components/Buttons/ButtonSearch/ButtonSearch.tsx deleted file mode 100644 index be5a9bc..0000000 --- a/src/components/Buttons/ButtonSearch/ButtonSearch.tsx +++ /dev/null @@ -1,40 +0,0 @@ -import { CloseIcon, SearchIcon } from '@components/Icons'; -import { t } from '@lingui/macro'; -import { SetStateAction } from 'react'; -import styles from '../Buttons.module.scss'; - -const ButtonSearch = ({ - isActivated, - setIsActivated, -}: { - isActivated: boolean; - setIsActivated: (value: SetStateAction<boolean>) => void; -}) => { - const btnClasses = isActivated - ? `${styles.search} ${styles['search--opened']}` - : styles.search; - - return ( - <button - className={btnClasses} - type="button" - onClick={() => setIsActivated(!isActivated)} - > - <span className={styles.icon}> - <span className={styles.front}> - <SearchIcon /> - </span> - <span className={styles.back}> - <CloseIcon /> - </span> - </span> - {isActivated ? ( - <span className="screen-reader-text">{t`Close search`}</span> - ) : ( - <span className="screen-reader-text">{t`Open search`}</span> - )} - </button> - ); -}; - -export default ButtonSearch; |
