Small fix to badges in other components

This commit is contained in:
Joshen Lim committed 2020-12-01 16:46:56 +08:00
1 parent 23940431b4
commit 1803148116
5 files changed
+12 -6

No files matched your search

+1 -1
View File
@@ -22,7 +22,7 @@ const Features = () => {
</div>
<dt className="flex flex-row xl:flex-col ml-4 text-lg leading-6 font-medium text-gray-900 dark:text-white">
{name}
{label && <Badge>{label}</Badge>}
{label && <Badge className="mt-1">{label}</Badge>}
</dt>
</div>
<div className="mt-5">
+1 -1
View File
@@ -42,7 +42,7 @@ const MadeForDevelopers = () => {
<div className="lg:mt-5">
<dt className="text-lg leading-6 font-medium text-gray-900 dark:text-white flex">
Local emulator
<Badge>Q1 2021</Badge>
<Badge className="ml-3">Q1 2021</Badge>
</dt>
<dd className="mt-3 text-base text-gray-500 mb-6 dark:text-dark-100">
Develop locally and push to production when you're ready
+1 -1
View File
@@ -42,7 +42,7 @@ const FlyOut = () => {
<div className="ml-4 md:flex-1 md:flex md:flex-col md:justify-between lg:ml-0 lg:mt-4">
<div>
<p className="text-base font-medium text-gray-900 dark:text-white">
{name} {label && <Badge>{label}</Badge>}
{name} {label && <Badge className="ml-3">{label}</Badge>}
</p>
<p className="mt-1 text-sm text-gray-500 dark:text-dark-100">
{description}
+1 -1
View File
@@ -47,7 +47,7 @@ const Nav = (props: Props) => {
<div className="ml-4 md:flex-1 md:flex md:flex-col md:justify-between lg:ml-0 lg:mt-4">
<div>
<p className="text-base font-medium text-gray-900 dark:text-white">
{name} {label && <Badge>{label}</Badge>}
{name} {label && <Badge className="ml-3">{label}</Badge>}
</p>
<p className="mt-1 text-sm text-gray-500 dark:text-dark-100">{description}</p>
</div>
+8 -2
View File
@@ -1,6 +1,12 @@
const Badge = (props: any) => {
type Props = {
className?: string,
children: any
}
const Badge = (props: Props) => {
const { className, children } = props
return (
<span className="ml-3 xl:ml-0 xl:mt-1 inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-indigo-100 text-indigo-800">
<span className={`inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-indigo-100 text-indigo-800 ${className}`}>
<svg className="-ml-0.5 mr-1.5 h-2 w-2 text-indigo-400" fill="currentColor" viewBox="0 0 8 8">
<circle cx="4" cy="4" r="3" />
</svg>