link homepage images
This commit is contained in:
parent
7c5c312c42
commit
1968908e24
@ -50,9 +50,7 @@ const MasonryGallery = ({
|
|||||||
const { breakpoint } = useBreakpoint(breakpoints, 'xs')
|
const { breakpoint } = useBreakpoint(breakpoints, 'xs')
|
||||||
|
|
||||||
// const breakpoint = currentBreakpoint.length ? currentBreakpoint : "xs";
|
// const breakpoint = currentBreakpoint.length ? currentBreakpoint : "xs";
|
||||||
console.log("🚀 ~ file: MasonryGallery.tsx ~ line 51 ~ breakpoint", breakpoint)
|
|
||||||
const galleryWidth = `calc(100vw - ${ breakpoint === "xs" || breakpoint === "sm" ? "32" : "160" }px)`;
|
const galleryWidth = `calc(100vw - ${ breakpoint === "xs" || breakpoint === "sm" ? "32" : "160" }px)`;
|
||||||
console.log("🚀 ~ file: MasonryGallery.tsx ~ line 55 ~ galleryWidth", galleryWidth)
|
|
||||||
|
|
||||||
const aspectRatios = React.useMemo(
|
const aspectRatios = React.useMemo(
|
||||||
() => R.map(getAspectRatio, images).filter(Boolean),
|
() => R.map(getAspectRatio, images).filter(Boolean),
|
||||||
@ -161,7 +159,7 @@ const MasonryGallery = ({
|
|||||||
)`
|
)`
|
||||||
: "",
|
: "",
|
||||||
}}
|
}}
|
||||||
to={`/photogallery/${image.base}`}
|
to={`/photogallery/${image.base}/`}
|
||||||
>
|
>
|
||||||
{debugHue && (
|
{debugHue && (
|
||||||
<span className="text-white z-20 absolute bg-black">
|
<span className="text-white z-20 absolute bg-black">
|
||||||
|
@ -84,7 +84,6 @@ const Nav = ({ internalLinks, className }: NavProps) => {
|
|||||||
"my-4 flex flex-col-reverse md:flex-row items-center w-full font-sans px-4 md:px-8",
|
"my-4 flex flex-col-reverse md:flex-row items-center w-full font-sans px-4 md:px-8",
|
||||||
className
|
className
|
||||||
)}
|
)}
|
||||||
style={{ zIndex: 100 }}
|
|
||||||
>
|
>
|
||||||
<div className="md:flex items-baseline flex-auto">
|
<div className="md:flex items-baseline flex-auto">
|
||||||
<h1 className="font-bold mr-2">Chuck Dries</h1>
|
<h1 className="font-bold mr-2">Chuck Dries</h1>
|
||||||
@ -107,6 +106,7 @@ const Nav = ({ internalLinks, className }: NavProps) => {
|
|||||||
))}
|
))}
|
||||||
</ul>
|
</ul>
|
||||||
<Popover
|
<Popover
|
||||||
|
containerClassName="z-30 p-1"
|
||||||
content={<ExternalLinks />}
|
content={<ExternalLinks />}
|
||||||
isOpen={linksMenu}
|
isOpen={linksMenu}
|
||||||
onClickOutside={() => setLinksMenu(false)}
|
onClickOutside={() => setLinksMenu(false)}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import * as React from "react";
|
import * as React from "react";
|
||||||
import { graphql, PageProps } from "gatsby";
|
import { graphql, Link, PageProps } from "gatsby";
|
||||||
import { GatsbyImage, getImage } from "gatsby-plugin-image";
|
import { GatsbyImage, getImage } from "gatsby-plugin-image";
|
||||||
import { Helmet } from "react-helmet";
|
import { Helmet } from "react-helmet";
|
||||||
// import { take } from "ramda";
|
// import { take } from "ramda";
|
||||||
@ -90,13 +90,23 @@ const IndexPage = ({
|
|||||||
{ href: "/photogallery/", label: "Gallery" },
|
{ href: "/photogallery/", label: "Gallery" },
|
||||||
]}
|
]}
|
||||||
/>
|
/>
|
||||||
{isClient && <GatsbyImage
|
{isClient && (
|
||||||
|
<Link
|
||||||
|
className="flex-auto flex flex-col m-4 md:m-8 mt-0 md:mt-0"
|
||||||
|
to={`/photogallery/${image.base}/`}
|
||||||
|
>
|
||||||
|
<GatsbyImage
|
||||||
alt=""
|
alt=""
|
||||||
className="flex-auto m-4 md:m-8 mt-0 md:mt-0"
|
className="h-[calc(100vh-160px)]" // reeeeee
|
||||||
image={img!}
|
image={img!}
|
||||||
loading="eager"
|
loading="eager"
|
||||||
objectFit={browserIsLandscape ? "cover" : "contain"}
|
objectFit={browserIsLandscape ? "cover" : "contain"}
|
||||||
/>}
|
style={{
|
||||||
|
height: "calc(100vh-160px)",
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
</Link>
|
||||||
|
)}
|
||||||
</main>
|
</main>
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user