1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-07-21 07:01:19 -04:00

images are finally linkable again

This commit is contained in:
2022-03-21 16:17:35 -04:00
parent 6b6bc5497e
commit 05608261ca
15 changed files with 185 additions and 143 deletions

View File

@@ -1,8 +1,7 @@
import Image from "../Image";
import Image, { CustomImageProps } from "../Image";
import innerText from "react-innertext";
import { styled } from "../../lib/styles/stitches.config";
import type { PropsWithChildren } from "react";
import type { ImageProps as NextImageProps } from "next/image";
const Wrapper = styled("figure", {
margin: "1em auto",
@@ -21,7 +20,7 @@ const Caption = styled("figcaption", {
},
});
export type FigureProps = Omit<NextImageProps, "alt"> &
export type FigureProps = Omit<CustomImageProps, "alt"> &
PropsWithChildren<{
alt?: string; // becomes optional -- pulled from plaintext-ified caption if missing
}>;