Skeleton Component

This commit is contained in:
Belen Curcio
2020-10-15 11:10:07 -03:00
parent 3b7b71422c
commit bf1ffcace9
9 changed files with 163 additions and 15 deletions

View File

@@ -128,7 +128,10 @@ export default function Search({
</>
) : (
// TODO: add a proper loading state
<div>Searching...</div>
<div>
Searching...
<Skeleton></Skeleton>
</div>
)}
</div>
<div className="col-span-2">

14
pages/ui.tsx Normal file
View File

@@ -0,0 +1,14 @@
import { GetStaticPropsContext, InferGetStaticPropsType } from 'next'
import { useRouter } from 'next/router'
import Link from 'next/link'
import { Layout } from '@components/core'
import { Container, Grid, Skeleton } from '@components/ui'
export default function Search() {
return (
<Container>
<Skeleton className="w-64 h-12 rounded-md" />
</Container>
)
}
Search.Layout = Layout