diff --git a/components/Card.tsx b/components/Card.tsx index 663f9a2..d5fc7b2 100644 --- a/components/Card.tsx +++ b/components/Card.tsx @@ -12,7 +12,7 @@ export function Card( class="text-white rounded-3xl shadow-md p-4 relative overflow-hidden lg:w-56 lg:h-56 sm:w-48 sm:h-48 - w-32 h-32" + w-[37vw] h-[37vw]" >
diff --git a/components/Grid.tsx b/components/Grid.tsx index 702d0c5..61f2687 100644 --- a/components/Grid.tsx +++ b/components/Grid.tsx @@ -2,10 +2,7 @@ import { ComponentChildren } from "preact"; export const Grid = ({ children }: { children: ComponentChildren }) => { return ( -
+
{children}
); diff --git a/routes/recipes/index.tsx b/routes/recipes/index.tsx index 9b9e063..ae998a1 100644 --- a/routes/recipes/index.tsx +++ b/routes/recipes/index.tsx @@ -15,9 +15,9 @@ export const handler: Handlers = { export default function Greet(props: PageProps) { return ( -
+
diff --git a/static/global.css b/static/global.css index bf0095b..44e7cb1 100644 --- a/static/global.css +++ b/static/global.css @@ -10,6 +10,16 @@ a { color: cadetblue } +.custom-grid { + grid-template-columns: repeat(auto-fit, minmax(37vw, 1fr)) ; +} + +@media(min-width: 640px){ +.custom-grid { + grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) ; +} +} + .noisy-gradient::after { content: ""; top: 0;