mirror of
https://github.com/hazemKrimi/personal-website.git
synced 2026-05-02 02:10:27 +00:00
Update icon button component
This commit is contained in:
@@ -1,6 +1,10 @@
|
|||||||
import { FC } from 'react';
|
import { FC } from 'react';
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
import Image from 'next/image';
|
import Image from 'next/image';
|
||||||
|
interface Props {
|
||||||
|
icon: string;
|
||||||
|
onClick?: () => void;
|
||||||
|
}
|
||||||
|
|
||||||
const Btn = styled.button`
|
const Btn = styled.button`
|
||||||
display: inline;
|
display: inline;
|
||||||
@@ -11,11 +15,6 @@ const Btn = styled.button`
|
|||||||
outline: none;
|
outline: none;
|
||||||
`;
|
`;
|
||||||
|
|
||||||
export interface Props {
|
|
||||||
icon: string;
|
|
||||||
onClick?: () => void;
|
|
||||||
}
|
|
||||||
|
|
||||||
const IconButton: FC<Props> = ({ icon, onClick }) => {
|
const IconButton: FC<Props> = ({ icon, onClick }) => {
|
||||||
return (
|
return (
|
||||||
<Btn onClick={onClick}>
|
<Btn onClick={onClick}>
|
||||||
|
|||||||
Reference in New Issue
Block a user