From a0e2f6c90fde8ead2e50fb491967f208aef34526 Mon Sep 17 00:00:00 2001 From: Chuck Dries Date: Sat, 17 Jul 2021 12:30:21 -0700 Subject: [PATCH] nav buttons work and I like the refactor but I like the navbar better --- src/pages/index.js | 131 +++++++++++++++++++++++---------------------- 1 file changed, 67 insertions(+), 64 deletions(-) diff --git a/src/pages/index.js b/src/pages/index.js index 9d8a73a..00df4d5 100644 --- a/src/pages/index.js +++ b/src/pages/index.js @@ -25,14 +25,72 @@ const getDifferentRand = (range, lastNs, iterations = 0) => { return n; }; +const getButtonClasses = (isClient, colorMode = 'vibrant') => + classnames( + "z-20 rounded-md text-md inline-block px-3 py-2 my-1 mr-2 text-md hover:underline", + isClient && + `text-muted-light bg-${colorMode}-dark blurred-or-opaque-bg-2`, + isClient && colorMode === 'muted' ? `hover:bg-muted` : '' + ); + +const Nav = ({ ar, isClient }) => ( + +); + const ImageButtons = ({ isClient, image, shuffleImage }) => (
( @@ -154,6 +204,7 @@ const IndexPage = ({ const vibrant = getVibrant(image); const ar = getAspectRatio(image); console.log("bg", image.base); + return ( <> @@ -200,55 +251,7 @@ const IndexPage = ({ )} style={{ gridArea: "1/1" }} > - - +