mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-04-26 13:18:26 -04:00
fix custom image width/height when passed in as strings
This commit is contained in:
parent
e5b862508c
commit
e91595c8bf
@ -1,8 +1,8 @@
|
||||
.copy {
|
||||
.button {
|
||||
line-height: 1;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.success {
|
||||
.button.success {
|
||||
color: var(--success) !important;
|
||||
}
|
||||
|
@ -47,7 +47,7 @@ const CopyButton = forwardRef(function CopyButton(
|
||||
|
||||
return (
|
||||
<button
|
||||
className={cx({ copy: true, success: !!copied }, className)}
|
||||
className={cx({ button: true, success: !!copied }, className)}
|
||||
title="Copy to clipboard"
|
||||
aria-label="Copy to clipboard"
|
||||
onClick={handleCopy}
|
||||
|
@ -17,8 +17,8 @@ const CustomImage = ({
|
||||
}: NextImageProps) => {
|
||||
// passed directly into next/image: https://nextjs.org/docs/api-reference/next/image
|
||||
const imageProps: Partial<NextImageProps> = {
|
||||
width,
|
||||
height,
|
||||
width: typeof width === "string" ? parseInt(width) : width,
|
||||
height: typeof height === "string" ? parseInt(height) : height,
|
||||
layout: "intrinsic",
|
||||
alt: alt || "",
|
||||
quality: quality || 65,
|
||||
|
@ -1,8 +1,8 @@
|
||||
import { NextSeo } from "next-seo";
|
||||
import Content from "../components/Content/Content";
|
||||
import PageTitle from "../components/PageTitle/PageTitle";
|
||||
import ContactForm from "../components/ContactForm/ContactForm";
|
||||
import { MailIcon, LockIcon } from "../components/Icons";
|
||||
import Content from "../components/Content/Content";
|
||||
|
||||
const Contact = () => (
|
||||
<>
|
||||
|
@ -1,5 +1,5 @@
|
||||
import ColorfulLink from "../components/ColorfulLink/ColorfulLink";
|
||||
import Content from "../components/Content/Content";
|
||||
import ColorfulLink from "../components/ColorfulLink/ColorfulLink";
|
||||
import { WaveIcon, LockIcon } from "../components/Icons";
|
||||
|
||||
const Index = () => (
|
||||
|
@ -1,11 +1,11 @@
|
||||
import { graphql } from "@octokit/graphql";
|
||||
import { NextSeo } from "next-seo";
|
||||
import Content from "../components/Content/Content";
|
||||
import PageTitle from "../components/PageTitle/PageTitle";
|
||||
import RepositoryCard from "../components/RepositoryCard/RepositoryCard";
|
||||
import { ProjectsIcon } from "../components/Icons";
|
||||
import type { GetStaticProps } from "next";
|
||||
import { RepoType } from "../types";
|
||||
import Content from "../components/Content/Content";
|
||||
|
||||
type Props = {
|
||||
repos: RepoType[];
|
||||
|
Loading…
x
Reference in New Issue
Block a user