From 74b31b5060a0941d14391400b20a725c1abba73f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9B=90=EB=8D=94?= Date: Fri, 8 Jan 2021 12:10:51 +0900 Subject: [PATCH] chore: renamed Label to Tag --- components/Labal.tsx | 15 --------------- components/Tag.tsx | 18 ++++++++++++++++++ 2 files changed, 18 insertions(+), 15 deletions(-) delete mode 100644 components/Labal.tsx create mode 100644 components/Tag.tsx diff --git a/components/Labal.tsx b/components/Labal.tsx deleted file mode 100644 index b424e01..0000000 --- a/components/Labal.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import Link from 'next/link' - -const Label = ({ href, text }:LabelProps):JSX.Element => { - return href ? - {text} - : {text} -} - -interface LabelProps { - href?: string - text: string - icon?: string -} - -export default Label \ No newline at end of file diff --git a/components/Tag.tsx b/components/Tag.tsx new file mode 100644 index 0000000..0a74e85 --- /dev/null +++ b/components/Tag.tsx @@ -0,0 +1,18 @@ +import Link from 'next/link' + +const Tag = ({ href, text, circular=false, dark=false, marginBottom=2 }:LabelProps):JSX.Element => { + return href ? + {text} + : {text} +} + +interface LabelProps { + href?: string + text: string | JSX.Element | JSX.Element[] + icon?: string + circular?: boolean + dark?: boolean + marginBottom?: number +} + +export default Tag \ No newline at end of file