-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathe303a5b40266ab90ed422c8fbf265311f05d81b6-3bc2caf1303a083375f1.js.map
1 lines (1 loc) · 75.3 KB
/
e303a5b40266ab90ed422c8fbf265311f05d81b6-3bc2caf1303a083375f1.js.map
1
{"version":3,"file":"e303a5b40266ab90ed422c8fbf265311f05d81b6-3bc2caf1303a083375f1.js","mappings":"2uBA8mByB,MAAAA,EC/lBeC,IAAA,oBAAAC,kBAAA,YAAAA,iBAERC,UA2L5B,SAAAC,EAgBFC,EACAC,EACAC,EACAC,EACAC,GA4BA,YA5BA,IAAAA,IAAAA,EAAuB,CAAC,GAajBC,EAAA,GAKFH,EAAA,CACHI,QAAAH,EACAI,WAAYP,EACZ,kBAAkB,GAClBQ,MAAAH,EAAA,GACKD,EAAA,CACHK,QAASR,EAAW,EAAI,eAAAS,EAa5BV,EACAC,EACAC,EACAC,EACAC,EACAO,EACAC,EACAC,GAEA,MAAAC,EAAoC,CAAC,EAEjCH,IACFG,EAAaC,gBAAkBJ,EAAA,UAE3BT,GACFY,EAAaE,MAAQb,EACrBW,EAAalB,OAASQ,EACtBU,EAAaC,gBAAkBJ,EAC/BG,EAAaG,SAAA,6BACJf,GAAA,cAMAA,KALTY,EAAaG,SAAA,WACbH,EAAaI,IAAM,EACnBJ,EAAaK,KAAO,EACpBL,EAAaM,OAAS,EACtBN,EAAaO,MAAQ,IAUrBT,IACFE,EAAaQ,UAAYV,GAGvBC,IACFC,EAAaS,eAAiBV,GAEhC,MAAAW,EAAAnB,EAAA,GACKL,EAAA,CACH,eAAc,EACd,yBAAyB,GACzBQ,MAAAH,EAAA,CACEI,QAASR,EAAW,EAAI,EACxBwB,WAAA,wBACGX,KAeP,OAJIU,CAAA,CAgF8C,MAAAE,EAAA,aAAAC,EC9UE,SAAAC,GAGpD,IAHmEC,OACnE5B,EADmEe,MAEnEd,EAFmEN,OAGnEO,GAAAyB,EAEA,oBAAI3B,EAAAD,EAAAA,cAAA,wBAEiBQ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KAAMA,EAAMK,MAAMW,EAAAA,EAAAA,IAAQhB,OAIpC,QAGJ,ECjCR,MAJkB3B,IAAA,IAAC,UAAE8C,GAAkB9C,EAAA,OACrCM,EAAAA,cAAA,OAAK5F,UCRgB,sCDQcoI,EAAgB,EEsBrD,MAlB8B9C,IAAA,IAAC,KAAE+C,GAAa/C,EAAA,OAC5CM,EAAAA,cAAA,OAAK5F,UCTW,4BDUd4F,EAAAA,cAAA,MAAI5F,UCXU,4BDYXqI,EAAKlK,KAAKmK,GACT1C,EAAAA,cAAA,MAAI5F,UCfM,2BDekBzB,IAAK+J,EAAKzC,MACpCD,EAAAA,cAACkB,EAAAA,KAAI,CACHC,GAAIuB,EAAKzC,KACT7F,UCjBM,2BDkBNuI,gBCpBQ,8BDsBPD,EAAKE,WAKV,EEER,MAfgBlD,IAAyB,IAAxB,QAAEuB,GAAgBvB,EACjC,MAAM,OAAEsB,EAAM,UAAEwB,EAAS,KAAEC,IAASI,EAAAA,EAAAA,MAEpC,OACE7C,EAAAA,cAAA,OAAK5F,UCjBY,kCDkBf4F,EAAAA,cAAA,OAAK5F,UCnBQ,gCDoBX4F,EAAAA,cAAC8C,EAAM,CAAC9B,OAAQA,EAAQC,QAASA,IACjCjB,EAAAA,cAAC+C,EAAI,CAACN,KAAMA,IACZzC,EAAAA,cAACgD,EAAQ,CAACpB,SAAUZ,EAAOY,WAC3B5B,EAAAA,cAACiD,EAAS,CAACT,UAAWA,KAEpB,C","sources":["webpack://gatsby-starter-lumen/../src/image-utils.ts","webpack://gatsby-starter-lumen/../src/components/hooks.ts","webpack://gatsby-starter-lumen/../src/components/layout-wrapper.tsx","webpack://gatsby-starter-lumen/../src/components/picture.tsx","webpack://gatsby-starter-lumen/../src/components/placeholder.tsx","webpack://gatsby-starter-lumen/../src/components/main-image.tsx","webpack://gatsby-starter-lumen/../src/components/gatsby-image.server.tsx","webpack://gatsby-starter-lumen/../src/components/gatsby-image.browser.tsx","webpack://gatsby-starter-lumen/../src/components/static-image.server.tsx","webpack://gatsby-starter-lumen/../src/components/static-image.tsx","webpack://gatsby-starter-lumen/./node_modules/gatsby-plugin-image/node_modules/camelcase/index.js","webpack://gatsby-starter-lumen/./src/components/Page/Page.tsx","webpack://gatsby-starter-lumen/./src/components/Page/Page.module.scss","webpack://gatsby-starter-lumen/./src/components/Image/Image.tsx","webpack://gatsby-starter-lumen/./src/components/Sidebar/Author/Author.module.scss","webpack://gatsby-starter-lumen/./src/components/Sidebar/Author/Author.tsx","webpack://gatsby-starter-lumen/./src/components/Icon/Icon.tsx","webpack://gatsby-starter-lumen/./src/components/Icon/Icon.module.scss","webpack://gatsby-starter-lumen/./src/components/Sidebar/Contacts/Contacts.module.scss","webpack://gatsby-starter-lumen/./src/components/Sidebar/Contacts/Contacts.tsx","webpack://gatsby-starter-lumen/./src/components/Sidebar/Copyright/Copyright.tsx","webpack://gatsby-starter-lumen/./src/components/Sidebar/Copyright/Copyright.module.scss","webpack://gatsby-starter-lumen/./src/components/Sidebar/Menu/Menu.tsx","webpack://gatsby-starter-lumen/./src/components/Sidebar/Menu/Menu.module.scss","webpack://gatsby-starter-lumen/./src/components/Sidebar/Sidebar.tsx","webpack://gatsby-starter-lumen/./src/components/Sidebar/Sidebar.module.scss"],"sourcesContent":["import camelCase from \"camelcase\"\nimport type { IGatsbyImageData } from \"./index\"\n\nconst DEFAULT_PIXEL_DENSITIES = [0.25, 0.5, 1, 2]\nexport const DEFAULT_BREAKPOINTS = [750, 1080, 1366, 1920]\nexport const EVERY_BREAKPOINT = [\n 320, 654, 768, 1024, 1366, 1600, 1920, 2048, 2560, 3440, 3840, 4096,\n]\nconst DEFAULT_FLUID_WIDTH = 800\nconst DEFAULT_FIXED_WIDTH = 800\nconst DEFAULT_ASPECT_RATIO = 4 / 3\n\nexport type Fit = \"cover\" | \"fill\" | \"inside\" | \"outside\" | \"contain\"\n\nexport type Layout = \"fixed\" | \"fullWidth\" | \"constrained\"\nexport type ImageFormat = \"jpg\" | \"png\" | \"webp\" | \"avif\" | \"auto\" | \"\"\n\n/**\n * The minimal required reporter, as we don't want to import it from gatsby-cli\n */\nexport interface IReporter {\n warn(message: string): void\n}\n\nexport interface ISharpGatsbyImageArgs {\n layout?: Layout\n formats?: Array<ImageFormat>\n placeholder?: \"tracedSVG\" | \"dominantColor\" | \"blurred\" | \"none\"\n tracedSVGOptions?: Record<string, unknown>\n width?: number\n height?: number\n aspectRatio?: number\n sizes?: string\n quality?: number\n transformOptions?: {\n fit?: Fit\n cropFocus?: number | string\n duotone?: {\n highlight: string\n shadow: string\n opacity?: number\n }\n grayscale?: boolean\n rotate?: number\n trim?: number\n }\n jpgOptions?: Record<string, unknown>\n pngOptions?: Record<string, unknown>\n webpOptions?: Record<string, unknown>\n avifOptions?: Record<string, unknown>\n blurredOptions?: { width?: number; toFormat?: ImageFormat }\n breakpoints?: Array<number>\n outputPixelDensities?: Array<number>\n backgroundColor?: string\n}\n\nexport interface IImageSizeArgs {\n width?: number\n height?: number\n layout?: Layout\n filename: string\n outputPixelDensities?: Array<number>\n breakpoints?: Array<number>\n fit?: Fit\n reporter?: IReporter\n sourceMetadata: { width: number; height: number }\n}\n\nexport interface IImageSizes {\n sizes: Array<number>\n presentationWidth: number\n presentationHeight: number\n aspectRatio: number\n unscaledWidth: number\n}\n\nexport interface IImage {\n src: string\n width: number\n height: number\n format: ImageFormat\n}\n\nexport interface IGatsbyImageHelperArgs {\n pluginName: string\n generateImageSource: (\n filename: string,\n width: number,\n height: number,\n format: ImageFormat,\n fit?: Fit,\n options?: Record<string, unknown>\n ) => IImage\n layout?: Layout\n formats?: Array<ImageFormat>\n filename: string\n placeholderURL?: string\n width?: number\n height?: number\n sizes?: string\n reporter?: IReporter\n sourceMetadata?: { width: number; height: number; format: ImageFormat }\n fit?: Fit\n options?: Record<string, unknown>\n breakpoints?: Array<number>\n backgroundColor?: string\n aspectRatio?: number\n}\n\nconst warn = (message: string): void => console.warn(message)\n\nconst sortNumeric = (a: number, b: number): number => a - b\n\nexport const getSizes = (width: number, layout: Layout): string | undefined => {\n switch (layout) {\n // If screen is wider than the max size, image width is the max size,\n // otherwise it's the width of the screen\n case `constrained`:\n return `(min-width: ${width}px) ${width}px, 100vw`\n\n // Image is always the same width, whatever the size of the screen\n case `fixed`:\n return `${width}px`\n\n // Image is always the width of the screen\n case `fullWidth`:\n return `100vw`\n\n default:\n return undefined\n }\n}\n\nexport const getSrcSet = (images: Array<IImage>): string =>\n images.map(image => `${image.src} ${image.width}w`).join(`,\\n`)\n\nexport function formatFromFilename(filename: string): ImageFormat | undefined {\n const dot = filename.lastIndexOf(`.`)\n if (dot !== -1) {\n const ext = filename.slice(dot + 1)\n if (ext === `jpeg`) {\n return `jpg`\n }\n if (ext.length === 3 || ext.length === 4) {\n return ext as ImageFormat\n }\n }\n return undefined\n}\n\nexport function setDefaultDimensions(\n args: IGatsbyImageHelperArgs\n): IGatsbyImageHelperArgs {\n let {\n layout = `constrained`,\n width,\n height,\n sourceMetadata,\n breakpoints,\n aspectRatio,\n formats = [`auto`, `webp`],\n } = args\n formats = formats.map(format => format.toLowerCase() as ImageFormat)\n layout = camelCase(layout) as Layout\n\n if (width && height) {\n return { ...args, formats, layout, aspectRatio: width / height }\n }\n if (sourceMetadata.width && sourceMetadata.height && !aspectRatio) {\n aspectRatio = sourceMetadata.width / sourceMetadata.height\n }\n\n if (layout === `fullWidth`) {\n width = width || sourceMetadata.width || breakpoints[breakpoints.length - 1]\n height = height || Math.round(width / (aspectRatio || DEFAULT_ASPECT_RATIO))\n } else {\n if (!width) {\n if (height && aspectRatio) {\n width = height * aspectRatio\n } else if (sourceMetadata.width) {\n width = sourceMetadata.width\n } else if (height) {\n width = Math.round(height / DEFAULT_ASPECT_RATIO)\n } else {\n width = DEFAULT_FIXED_WIDTH\n }\n }\n\n if (aspectRatio && !height) {\n height = Math.round(width / aspectRatio)\n } else if (!aspectRatio) {\n aspectRatio = width / height\n }\n }\n return { ...args, width, height, aspectRatio, layout, formats }\n}\n\n/**\n * Use this for getting an image for the blurred placeholder. This ensures the\n * aspect ratio and crop match the main image\n */\nexport function getLowResolutionImageURL(\n args: IGatsbyImageHelperArgs,\n width = 20\n): string {\n args = setDefaultDimensions(args)\n const { generateImageSource, filename, aspectRatio } = args\n return generateImageSource(\n filename,\n width,\n Math.round(width / aspectRatio),\n args.sourceMetadata.format || `jpg`,\n args.fit,\n args.options\n )?.src\n}\n\nexport function generateImageData(\n args: IGatsbyImageHelperArgs\n): IGatsbyImageData {\n args = setDefaultDimensions(args)\n\n let {\n pluginName,\n sourceMetadata,\n generateImageSource,\n layout,\n fit,\n options,\n width,\n height,\n filename,\n reporter = { warn },\n backgroundColor,\n placeholderURL,\n } = args\n\n if (!pluginName) {\n reporter.warn(\n `[gatsby-plugin-image] \"generateImageData\" was not passed a plugin name`\n )\n }\n\n if (typeof generateImageSource !== `function`) {\n throw new Error(`generateImageSource must be a function`)\n }\n\n if (!sourceMetadata || (!sourceMetadata.width && !sourceMetadata.height)) {\n // No metadata means we let the CDN handle max size etc, aspect ratio etc\n sourceMetadata = {\n width,\n height,\n format: sourceMetadata?.format || formatFromFilename(filename) || `auto`,\n }\n } else if (!sourceMetadata.format) {\n sourceMetadata.format = formatFromFilename(filename)\n }\n\n const formats = new Set<ImageFormat>(args.formats)\n\n if (formats.size === 0 || formats.has(`auto`) || formats.has(``)) {\n formats.delete(`auto`)\n formats.delete(``)\n formats.add(sourceMetadata.format)\n }\n\n if (formats.has(`jpg`) && formats.has(`png`)) {\n reporter.warn(\n `[${pluginName}] Specifying both 'jpg' and 'png' formats is not supported. Using 'auto' instead`\n )\n if (sourceMetadata.format === `jpg`) {\n formats.delete(`png`)\n } else {\n formats.delete(`jpg`)\n }\n }\n\n const imageSizes = calculateImageSizes({ ...args, sourceMetadata })\n\n const result: IGatsbyImageData[\"images\"] = {\n sources: [],\n }\n\n let sizes = args.sizes\n if (!sizes) {\n sizes = getSizes(imageSizes.presentationWidth, layout)\n }\n\n formats.forEach(format => {\n const images = imageSizes.sizes\n .map(size => {\n const imageSrc = generateImageSource(\n filename,\n size,\n Math.round(size / imageSizes.aspectRatio),\n format,\n fit,\n options\n )\n if (\n !imageSrc?.width ||\n !imageSrc.height ||\n !imageSrc.src ||\n !imageSrc.format\n ) {\n reporter.warn(\n `[${pluginName}] The resolver for image ${filename} returned an invalid value.`\n )\n return undefined\n }\n return imageSrc\n })\n .filter(Boolean)\n\n if (format === `jpg` || format === `png` || format === `auto`) {\n const unscaled =\n images.find(img => img.width === imageSizes.unscaledWidth) || images[0]\n\n if (unscaled) {\n result.fallback = {\n src: unscaled.src,\n srcSet: getSrcSet(images),\n sizes,\n }\n }\n } else {\n result.sources?.push({\n srcSet: getSrcSet(images),\n sizes,\n type: `image/${format}`,\n })\n }\n })\n\n const imageProps: Partial<IGatsbyImageData> = {\n images: result,\n layout,\n backgroundColor,\n }\n\n if (placeholderURL) {\n imageProps.placeholder = { fallback: placeholderURL }\n }\n\n switch (layout) {\n case `fixed`:\n imageProps.width = imageSizes.presentationWidth\n imageProps.height = imageSizes.presentationHeight\n break\n\n case `fullWidth`:\n imageProps.width = 1\n imageProps.height = 1 / imageSizes.aspectRatio\n break\n\n case `constrained`:\n imageProps.width = args.width || imageSizes.presentationWidth || 1\n imageProps.height = (imageProps.width || 1) / imageSizes.aspectRatio\n }\n\n return imageProps as IGatsbyImageData\n}\n\nconst dedupeAndSortDensities = (values: Array<number>): Array<number> =>\n Array.from(new Set([1, ...values])).sort(sortNumeric)\n\nexport function calculateImageSizes(args: IImageSizeArgs): IImageSizes {\n const {\n width,\n height,\n filename,\n layout = `constrained`,\n sourceMetadata: imgDimensions,\n reporter = { warn },\n breakpoints = DEFAULT_BREAKPOINTS,\n } = args\n\n // check that all dimensions provided are positive\n const userDimensions = { width, height }\n const erroneousUserDimensions = Object.entries(userDimensions).filter(\n ([_, size]) => typeof size === `number` && size < 1\n )\n if (erroneousUserDimensions.length) {\n throw new Error(\n `Specified dimensions for images must be positive numbers (> 0). Problem dimensions you have are ${erroneousUserDimensions\n .map(dim => dim.join(`: `))\n .join(`, `)}`\n )\n }\n\n if (layout === `fixed`) {\n return fixedImageSizes(args)\n } else if (layout === `constrained`) {\n return responsiveImageSizes(args)\n } else if (layout === `fullWidth`) {\n return responsiveImageSizes({ breakpoints, ...args })\n } else {\n reporter.warn(\n `No valid layout was provided for the image at ${filename}. Valid image layouts are fixed, fullWidth, and constrained. Found ${layout}`\n )\n return {\n sizes: [imgDimensions.width],\n presentationWidth: imgDimensions.width,\n presentationHeight: imgDimensions.height,\n aspectRatio: imgDimensions.width / imgDimensions.height,\n unscaledWidth: imgDimensions.width,\n }\n }\n}\nexport function fixedImageSizes({\n filename,\n sourceMetadata: imgDimensions,\n width,\n height,\n fit = `cover`,\n outputPixelDensities = DEFAULT_PIXEL_DENSITIES,\n reporter = { warn },\n}: IImageSizeArgs): IImageSizes {\n let aspectRatio = imgDimensions.width / imgDimensions.height\n // Sort, dedupe and ensure there's a 1\n const densities = dedupeAndSortDensities(outputPixelDensities)\n\n // If both are provided then we need to check the fit\n if (width && height) {\n const calculated = getDimensionsAndAspectRatio(imgDimensions, {\n width,\n height,\n fit,\n })\n width = calculated.width\n height = calculated.height\n aspectRatio = calculated.aspectRatio\n }\n\n if (!width) {\n if (!height) {\n width = DEFAULT_FIXED_WIDTH\n } else {\n width = Math.round(height * aspectRatio)\n }\n } else if (!height) {\n height = Math.round(width / aspectRatio)\n }\n\n const originalWidth = width // will use this for presentationWidth, don't want to lose it\n const isTopSizeOverriden =\n imgDimensions.width < width || imgDimensions.height < (height as number)\n\n // If the image is smaller than requested, warn the user that it's being processed as such\n // print out this message with the necessary information before we overwrite it for sizing\n if (isTopSizeOverriden) {\n const fixedDimension = imgDimensions.width < width ? `width` : `height`\n reporter.warn(`\nThe requested ${fixedDimension} \"${\n fixedDimension === `width` ? width : height\n }px\" for the image ${filename} was larger than the actual image ${fixedDimension} of ${\n imgDimensions[fixedDimension]\n }px. If possible, replace the current image with a larger one.`)\n\n if (fixedDimension === `width`) {\n width = imgDimensions.width\n height = Math.round(width / aspectRatio)\n } else {\n height = imgDimensions.height\n width = height * aspectRatio\n }\n }\n\n const sizes = densities\n .filter(size => size >= 1) // remove smaller densities because fixed images don't need them\n .map(density => Math.round(density * (width as number)))\n .filter(size => size <= imgDimensions.width)\n\n return {\n sizes,\n aspectRatio,\n presentationWidth: originalWidth,\n presentationHeight: Math.round(originalWidth / aspectRatio),\n unscaledWidth: width,\n }\n}\n\nexport function responsiveImageSizes({\n sourceMetadata: imgDimensions,\n width,\n height,\n fit = `cover`,\n outputPixelDensities = DEFAULT_PIXEL_DENSITIES,\n breakpoints,\n layout,\n}: IImageSizeArgs): IImageSizes {\n let sizes\n let aspectRatio = imgDimensions.width / imgDimensions.height\n // Sort, dedupe and ensure there's a 1\n const densities = dedupeAndSortDensities(outputPixelDensities)\n\n // If both are provided then we need to check the fit\n if (width && height) {\n const calculated = getDimensionsAndAspectRatio(imgDimensions, {\n width,\n height,\n fit,\n })\n width = calculated.width\n height = calculated.height\n aspectRatio = calculated.aspectRatio\n }\n\n // Case 1: width of height were passed in, make sure it isn't larger than the actual image\n width = width && Math.min(width, imgDimensions.width)\n height = height && Math.min(height, imgDimensions.height)\n\n // Case 2: neither width or height were passed in, use default size\n if (!width && !height) {\n width = Math.min(DEFAULT_FLUID_WIDTH, imgDimensions.width)\n height = width / aspectRatio\n }\n\n // if it still hasn't been found, calculate width from the derived height.\n // TS isn't smart enough to realise the type for height has been narrowed here\n if (!width) {\n width = (height as number) * aspectRatio\n }\n\n const originalWidth = width\n const isTopSizeOverriden =\n imgDimensions.width < width || imgDimensions.height < (height as number)\n if (isTopSizeOverriden) {\n width = imgDimensions.width\n height = imgDimensions.height\n }\n\n width = Math.round(width)\n\n if (breakpoints?.length > 0) {\n sizes = breakpoints.filter(size => size <= imgDimensions.width)\n\n // If a larger breakpoint has been filtered-out, add the actual image width instead\n if (\n sizes.length < breakpoints.length &&\n !sizes.includes(imgDimensions.width)\n ) {\n sizes.push(imgDimensions.width)\n }\n } else {\n sizes = densities.map(density => Math.round(density * (width as number)))\n sizes = sizes.filter(size => size <= imgDimensions.width)\n }\n\n // ensure that the size passed in is included in the final output\n if (layout === `constrained` && !sizes.includes(width)) {\n sizes.push(width)\n }\n sizes = sizes.sort(sortNumeric)\n return {\n sizes,\n aspectRatio,\n presentationWidth: originalWidth,\n presentationHeight: Math.round(originalWidth / aspectRatio),\n unscaledWidth: width,\n }\n}\n\nexport function getDimensionsAndAspectRatio(\n dimensions,\n options\n): { width: number; height: number; aspectRatio: number } {\n // Calculate the eventual width/height of the image.\n const imageAspectRatio = dimensions.width / dimensions.height\n\n let width = options.width\n let height = options.height\n\n switch (options.fit) {\n case `fill`: {\n width = options.width ? options.width : dimensions.width\n height = options.height ? options.height : dimensions.height\n break\n }\n case `inside`: {\n const widthOption = options.width\n ? options.width\n : Number.MAX_SAFE_INTEGER\n const heightOption = options.height\n ? options.height\n : Number.MAX_SAFE_INTEGER\n\n width = Math.min(widthOption, Math.round(heightOption * imageAspectRatio))\n height = Math.min(\n heightOption,\n Math.round(widthOption / imageAspectRatio)\n )\n break\n }\n case `outside`: {\n const widthOption = options.width ? options.width : 0\n const heightOption = options.height ? options.height : 0\n\n width = Math.max(widthOption, Math.round(heightOption * imageAspectRatio))\n height = Math.max(\n heightOption,\n Math.round(widthOption / imageAspectRatio)\n )\n break\n }\n\n default: {\n if (options.width && !options.height) {\n width = options.width\n height = Math.round(options.width / imageAspectRatio)\n }\n\n if (options.height && !options.width) {\n width = Math.round(options.height * imageAspectRatio)\n height = options.height\n }\n }\n }\n\n return {\n width,\n height,\n aspectRatio: width / height,\n }\n}\n","/* global GATSBY___IMAGE */\nimport { generateImageData, EVERY_BREAKPOINT } from \"../image-utils\"\nimport type { CSSProperties, HTMLAttributes, ImgHTMLAttributes } from \"react\"\nimport type { Node } from \"gatsby\"\nimport type { PlaceholderProps } from \"./placeholder\"\nimport type { MainImageProps } from \"./main-image\"\nimport type { IGatsbyImageData } from \"./gatsby-image.browser\"\nimport type {\n IGatsbyImageHelperArgs,\n Layout,\n IImage,\n ImageFormat,\n} from \"../image-utils\"\n\n// Native lazy-loading support: https://addyosmani.com/blog/lazy-loading/\nexport const hasNativeLazyLoadSupport = (): boolean =>\n typeof HTMLImageElement !== `undefined` &&\n `loading` in HTMLImageElement.prototype\n\nexport function gatsbyImageIsInstalled(): boolean {\n return typeof GATSBY___IMAGE !== `undefined` && GATSBY___IMAGE\n}\n\nexport type IGatsbyImageDataParent<T = never> = T & {\n gatsbyImageData: IGatsbyImageData\n}\nexport type IGatsbyImageParent<T = never> = T & {\n gatsbyImage: IGatsbyImageData\n}\nexport type FileNode = Partial<Node> & {\n childImageSharp?: IGatsbyImageDataParent<Partial<Node>>\n}\n\nconst isGatsbyImageData = (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n node: IGatsbyImageData | any\n): node is IGatsbyImageData =>\n // 🦆 check for a deep prop to be sure this is a valid gatsbyImageData object\n Boolean(node?.images?.fallback?.src)\n\nconst isGatsbyImageDataParent = <T>(\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n node: IGatsbyImageDataParent<T> | any\n): node is IGatsbyImageDataParent<T> => Boolean(node?.gatsbyImageData)\n\nconst isGatsbyImageParent = <T>(\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n node: IGatsbyImageParent<T> | any\n): node is IGatsbyImageParent<T> => Boolean(node?.gatsbyImage)\n\nexport type ImageDataLike =\n | FileNode\n | IGatsbyImageDataParent\n | IGatsbyImageParent\n | IGatsbyImageData\n\nexport const getImage = (\n node: ImageDataLike | null\n): IGatsbyImageData | undefined => {\n // This checks both for gatsbyImageData and gatsbyImage\n if (isGatsbyImageData(node)) {\n return node\n }\n // gatsbyImageData GraphQL field\n if (isGatsbyImageDataParent(node)) {\n return node.gatsbyImageData\n }\n // gatsbyImage GraphQL field for Gatsby's Image CDN service\n if (isGatsbyImageParent(node)) {\n return node.gatsbyImage\n }\n return node?.childImageSharp?.gatsbyImageData\n}\n\nexport const getSrc = (node: ImageDataLike): string | undefined =>\n getImage(node)?.images?.fallback?.src\n\nexport const getSrcSet = (node: ImageDataLike): string | undefined =>\n getImage(node)?.images?.fallback?.srcSet\n\nexport function getWrapperProps(\n width: number,\n height: number,\n layout: Layout\n): Pick<HTMLAttributes<HTMLElement>, \"className\" | \"style\"> & {\n \"data-gatsby-image-wrapper\": string\n} {\n const wrapperStyle: CSSProperties = {}\n\n let className = `gatsby-image-wrapper`\n\n // If the plugin isn't installed we need to apply the styles inline\n if (!gatsbyImageIsInstalled()) {\n wrapperStyle.position = `relative`\n wrapperStyle.overflow = `hidden`\n }\n\n if (layout === `fixed`) {\n wrapperStyle.width = width\n wrapperStyle.height = height\n } else if (layout === `constrained`) {\n if (!gatsbyImageIsInstalled()) {\n wrapperStyle.display = `inline-block`\n wrapperStyle.verticalAlign = `top`\n }\n className = `gatsby-image-wrapper gatsby-image-wrapper-constrained`\n }\n\n return {\n className,\n \"data-gatsby-image-wrapper\": ``,\n style: wrapperStyle,\n }\n}\n\nexport interface IUrlBuilderArgs<OptionsType> {\n width: number\n height: number\n baseUrl: string\n format: ImageFormat\n options: OptionsType\n}\nexport interface IGetImageDataArgs<OptionsType = Record<string, unknown>> {\n baseUrl: string\n /**\n * For constrained and fixed images, the size of the image element\n */\n width?: number\n height?: number\n /**\n * If available, pass the source image width and height\n */\n sourceWidth?: number\n sourceHeight?: number\n /**\n * If only one dimension is passed, then this will be used to calculate the other.\n */\n aspectRatio?: number\n layout?: Layout\n /**\n * Returns a URL based on the passed arguments. Should be a pure function\n */\n urlBuilder: (args: IUrlBuilderArgs<OptionsType>) => string\n\n /**\n * Should be a data URI\n */\n placeholderURL?: string\n backgroundColor?: string\n /**\n * Used in error messages etc\n */\n pluginName?: string\n\n /**\n * If you do not support auto-format, pass an array of image types here\n */\n formats?: Array<ImageFormat>\n\n breakpoints?: Array<number>\n\n /**\n * Passed to the urlBuilder function\n */\n options?: OptionsType\n}\n\n/**\n * Use this hook to generate gatsby-plugin-image data in the browser.\n */\nexport function getImageData<OptionsType>({\n baseUrl,\n urlBuilder,\n sourceWidth,\n sourceHeight,\n pluginName = `getImageData`,\n formats = [`auto`],\n breakpoints,\n options,\n ...props\n}: IGetImageDataArgs<OptionsType>): IGatsbyImageData {\n if (\n !breakpoints?.length &&\n (props.layout === `fullWidth` || (props.layout as string) === `FULL_WIDTH`)\n ) {\n breakpoints = EVERY_BREAKPOINT\n }\n const generateImageSource = (\n baseUrl: string,\n width: number,\n height?: number,\n format?: ImageFormat\n ): IImage => {\n return {\n width,\n height,\n format,\n src: urlBuilder({ baseUrl, width, height, options, format }),\n }\n }\n\n const sourceMetadata: IGatsbyImageHelperArgs[\"sourceMetadata\"] = {\n width: sourceWidth,\n height: sourceHeight,\n format: `auto`,\n }\n\n const args: IGatsbyImageHelperArgs = {\n ...props,\n pluginName,\n generateImageSource,\n filename: baseUrl,\n formats,\n breakpoints,\n sourceMetadata,\n }\n return generateImageData(args)\n}\n\nexport function getMainProps(\n isLoading: boolean,\n isLoaded: boolean,\n images: IGatsbyImageData[\"images\"],\n loading?: \"eager\" | \"lazy\",\n style: CSSProperties = {}\n): Partial<MainImageProps> {\n // fallback when it's not configured in gatsby-config.\n if (!gatsbyImageIsInstalled()) {\n style = {\n height: `100%`,\n left: 0,\n position: `absolute`,\n top: 0,\n transform: `translateZ(0)`,\n transition: `opacity 250ms linear`,\n width: `100%`,\n willChange: `opacity`,\n ...style,\n }\n }\n\n const result = {\n ...images,\n loading,\n shouldLoad: isLoading,\n \"data-main-image\": ``,\n style: {\n ...style,\n opacity: isLoaded ? 1 : 0,\n },\n }\n\n return result\n}\n\nexport type PlaceholderImageAttrs = ImgHTMLAttributes<HTMLImageElement> &\n Pick<PlaceholderProps, \"sources\" | \"fallback\"> & {\n \"data-placeholder-image\"?: string\n }\n\nexport function getPlaceholderProps(\n placeholder: PlaceholderImageAttrs | undefined,\n isLoaded: boolean,\n layout: Layout,\n width?: number,\n height?: number,\n backgroundColor?: string,\n objectFit?: CSSProperties[\"objectFit\"],\n objectPosition?: CSSProperties[\"objectPosition\"]\n): PlaceholderImageAttrs {\n const wrapperStyle: CSSProperties = {}\n\n if (backgroundColor) {\n wrapperStyle.backgroundColor = backgroundColor\n\n if (layout === `fixed`) {\n wrapperStyle.width = width\n wrapperStyle.height = height\n wrapperStyle.backgroundColor = backgroundColor\n wrapperStyle.position = `relative`\n } else if (layout === `constrained`) {\n wrapperStyle.position = `absolute`\n wrapperStyle.top = 0\n wrapperStyle.left = 0\n wrapperStyle.bottom = 0\n wrapperStyle.right = 0\n } else if (layout === `fullWidth`) {\n wrapperStyle.position = `absolute`\n wrapperStyle.top = 0\n wrapperStyle.left = 0\n wrapperStyle.bottom = 0\n wrapperStyle.right = 0\n }\n }\n\n if (objectFit) {\n wrapperStyle.objectFit = objectFit\n }\n\n if (objectPosition) {\n wrapperStyle.objectPosition = objectPosition\n }\n const result: PlaceholderImageAttrs = {\n ...placeholder,\n \"aria-hidden\": true,\n \"data-placeholder-image\": ``,\n style: {\n opacity: isLoaded ? 0 : 1,\n transition: `opacity 500ms linear`,\n ...wrapperStyle,\n },\n }\n\n // fallback when it's not configured in gatsby-config.\n if (!gatsbyImageIsInstalled()) {\n result.style = {\n height: `100%`,\n left: 0,\n position: `absolute`,\n top: 0,\n width: `100%`,\n }\n }\n\n return result\n}\n\nexport interface IArtDirectedImage {\n media: string\n image: IGatsbyImageData\n}\n\n/**\n * Generate a Gatsby image data object with multiple, art-directed images that display at different\n * resolutions.\n *\n * @param defaultImage The image displayed when no media query matches.\n * It is also used for all other settings applied to the image, such as width, height and layout.\n * You should pass a className to the component with media queries to adjust the size of the container,\n * as this cannot be adjusted automatically.\n * @param artDirected Array of objects which each contains a `media` string which is a media query\n * such as `(min-width: 320px)`, and the image object to use when that query matches.\n */\nexport function withArtDirection(\n defaultImage: IGatsbyImageData,\n artDirected: Array<IArtDirectedImage>\n): IGatsbyImageData {\n const { images, placeholder, ...props } = defaultImage\n const output: IGatsbyImageData = {\n ...props,\n images: {\n ...images,\n sources: [],\n },\n placeholder: placeholder && {\n ...placeholder,\n sources: [],\n },\n }\n\n artDirected.forEach(({ media, image }) => {\n if (!media) {\n if (process.env.NODE_ENV === `development`) {\n console.warn(\n \"[gatsby-plugin-image] All art-directed images passed to must have a value set for `media`. Skipping.\"\n )\n }\n return\n }\n\n if (\n image.layout !== defaultImage.layout &&\n process.env.NODE_ENV === `development`\n ) {\n console.warn(\n `[gatsby-plugin-image] Mismatched image layout: expected \"${defaultImage.layout}\" but received \"${image.layout}\". All art-directed images use the same layout as the default image`\n )\n }\n\n output.images.sources.push(\n ...image.images.sources.map(source => {\n return { ...source, media }\n }),\n {\n media,\n srcSet: image.images.fallback.srcSet,\n }\n )\n\n if (!output.placeholder) {\n return\n }\n\n output.placeholder.sources.push({\n media,\n srcSet: image.placeholder.fallback,\n })\n })\n output.images.sources.push(...images.sources)\n if (placeholder?.sources) {\n output.placeholder?.sources.push(...placeholder.sources)\n }\n return output\n}\n","import React, { Fragment, FunctionComponent } from \"react\"\nimport terserMacro from \"../../macros/terser.macro\"\nimport { Layout } from \"../image-utils\"\n\nexport interface ILayoutWrapperProps {\n layout: Layout\n width: number\n height: number\n}\n\nconst NativeScriptLoading: FunctionComponent = () => (\n <script\n type=\"module\"\n dangerouslySetInnerHTML={{\n __html: terserMacro`\nconst hasNativeLazyLoadSupport = typeof HTMLImageElement !== \"undefined\" && \"loading\" in HTMLImageElement.prototype;\nif (hasNativeLazyLoadSupport) {\n const gatsbyImages = document.querySelectorAll('img[data-main-image]');\n for (let mainImage of gatsbyImages) {\n if (mainImage.dataset.src) {\n mainImage.setAttribute('src', mainImage.dataset.src)\n mainImage.removeAttribute('data-src')\n }\n if (mainImage.dataset.srcset) {\n mainImage.setAttribute('srcset', mainImage.dataset.srcset)\n mainImage.removeAttribute('data-srcset')\n }\n\n const sources = mainImage.parentNode.querySelectorAll('source[data-srcset]');\n for (let source of sources) {\n source.setAttribute('srcset', source.dataset.srcset)\n source.removeAttribute('data-srcset')\n }\n\n if (mainImage.complete) {\n mainImage.style.opacity = 1;\n\n // also hide the placeholder\n mainImage.parentNode.parentNode.querySelector('[data-placeholder-image]').style.opacity = 0;\n }\n }\n}\n`,\n }}\n />\n)\n\nexport function getSizer(\n layout: Layout,\n width: number,\n height: number\n): string {\n let sizer = ``\n if (layout === `fullWidth`) {\n sizer = `<div aria-hidden=\"true\" style=\"padding-top: ${\n (height / width) * 100\n }%;\"></div>`\n }\n\n if (layout === `constrained`) {\n sizer = `<div style=\"max-width: ${width}px; display: block;\"><img alt=\"\" role=\"presentation\" aria-hidden=\"true\" src=\"data:image/svg+xml;charset=utf-8,%3Csvg height='${height}' width='${width}' xmlns='http://www.w3.org/2000/svg' version='1.1'%3E%3C/svg%3E\" style=\"max-width: 100%; display: block; position: static;\"></div>`\n }\n\n return sizer\n}\n\nconst Sizer: FunctionComponent<ILayoutWrapperProps> = function Sizer({\n layout,\n width,\n height,\n}) {\n if (layout === `fullWidth`) {\n return (\n <div aria-hidden style={{ paddingTop: `${(height / width) * 100}%` }} />\n )\n }\n\n if (layout === `constrained`) {\n return (\n <div style={{ maxWidth: width, display: `block` }}>\n <img\n alt=\"\"\n role=\"presentation\"\n aria-hidden=\"true\"\n src={`data:image/svg+xml;charset=utf-8,%3Csvg height='${height}' width='${width}' xmlns='http://www.w3.org/2000/svg' version='1.1'%3E%3C/svg%3E`}\n style={{\n maxWidth: `100%`,\n display: `block`,\n position: `static`,\n }}\n />\n </div>\n )\n }\n\n return null\n}\n\nexport const LayoutWrapper: FunctionComponent<ILayoutWrapperProps> =\n function LayoutWrapper({ children, ...props }) {\n return (\n <Fragment>\n <Sizer {...props} />\n {children}\n\n {SERVER ? <NativeScriptLoading /> : null}\n </Fragment>\n )\n }\n","import React, { FunctionComponent, ImgHTMLAttributes } from \"react\"\nimport * as PropTypes from \"prop-types\"\n\nexport interface IResponsiveImageProps {\n sizes?: string\n srcSet: string\n}\n\nexport type SourceProps = IResponsiveImageProps &\n (\n | {\n media: string\n type?: string\n }\n | {\n media?: string\n type: string\n }\n )\n\ntype FallbackProps = { src: string } & Partial<IResponsiveImageProps>\n\ntype ImageProps = ImgHTMLAttributes<HTMLImageElement> & {\n src: string\n alt: string\n shouldLoad: boolean\n}\n\nexport type PictureProps = ImgHTMLAttributes<HTMLImageElement> & {\n fallback?: FallbackProps\n sources?: Array<SourceProps>\n alt: string\n shouldLoad?: boolean\n}\n\nconst Image: FunctionComponent<ImageProps> = function Image({\n src,\n srcSet,\n loading,\n alt = ``,\n shouldLoad,\n ...props\n}) {\n return (\n <img\n {...props}\n decoding=\"async\"\n loading={loading}\n src={shouldLoad ? src : undefined}\n data-src={!shouldLoad ? src : undefined}\n srcSet={shouldLoad ? srcSet : undefined}\n data-srcset={!shouldLoad ? srcSet : undefined}\n alt={alt}\n />\n )\n}\n\nexport const Picture: React.FC<PictureProps> = function Picture({\n fallback,\n sources = [],\n shouldLoad = true,\n ...props\n}) {\n const sizes = props.sizes || fallback?.sizes\n const fallbackImage = (\n <Image {...props} {...fallback} sizes={sizes} shouldLoad={shouldLoad} />\n )\n\n if (!sources.length) {\n return fallbackImage\n }\n\n return (\n <picture>\n {sources.map(({ media, srcSet, type }) => (\n <source\n key={`${media}-${type}-${srcSet}`}\n type={type}\n media={media}\n srcSet={shouldLoad ? srcSet : undefined}\n data-srcset={!shouldLoad ? srcSet : undefined}\n sizes={sizes}\n />\n ))}\n {fallbackImage}\n </picture>\n )\n}\n\nImage.propTypes = {\n src: PropTypes.string.isRequired,\n alt: PropTypes.string.isRequired,\n sizes: PropTypes.string,\n srcSet: PropTypes.string,\n shouldLoad: PropTypes.bool,\n}\n\nPicture.displayName = `Picture`\nPicture.propTypes = {\n alt: PropTypes.string.isRequired,\n shouldLoad: PropTypes.bool,\n fallback: PropTypes.exact({\n src: PropTypes.string.isRequired,\n srcSet: PropTypes.string,\n sizes: PropTypes.string,\n }),\n sources: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.exact({\n media: PropTypes.string.isRequired,\n type: PropTypes.string,\n sizes: PropTypes.string,\n srcSet: PropTypes.string.isRequired,\n }),\n PropTypes.exact({\n media: PropTypes.string,\n type: PropTypes.string.isRequired,\n sizes: PropTypes.string,\n srcSet: PropTypes.string.isRequired,\n }),\n ])\n ),\n}\n","import React, { FunctionComponent, ImgHTMLAttributes } from \"react\"\nimport * as PropTypes from \"prop-types\"\nimport { Picture, SourceProps } from \"./picture\"\n\nexport type PlaceholderProps = ImgHTMLAttributes<HTMLImageElement> & {\n fallback?: string\n sources?: Array<SourceProps>\n}\n\nexport const Placeholder: FunctionComponent<PlaceholderProps> =\n function Placeholder({ fallback, ...props }) {\n if (fallback) {\n return (\n <Picture\n {...props}\n fallback={{\n src: fallback,\n }}\n aria-hidden\n alt=\"\"\n />\n )\n } else {\n return <div {...props}></div>\n }\n }\n\nPlaceholder.displayName = `Placeholder`\nPlaceholder.propTypes = {\n fallback: PropTypes.string,\n sources: Picture.propTypes?.sources,\n alt: function (props, propName, componentName): Error | null {\n if (!props[propName]) {\n return null\n }\n\n return new Error(\n `Invalid prop \\`${propName}\\` supplied to \\`${componentName}\\`. Validation failed.`\n )\n },\n}\n","import React from \"react\"\nimport { Picture, PictureProps } from \"./picture\"\n\nexport type MainImageProps = PictureProps\n\nexport const MainImage: React.FC<PictureProps> = function MainImage(props) {\n return (\n <>\n <Picture {...props} />\n <noscript>\n <Picture {...props} shouldLoad={true} />\n </noscript>\n </>\n )\n}\n\nMainImage.displayName = `MainImage`\nMainImage.propTypes = Picture.propTypes\n","import React from \"react\"\nimport { getWrapperProps, getMainProps, getPlaceholderProps } from \"./hooks\"\nimport { Placeholder } from \"./placeholder\"\nimport { MainImage, MainImageProps } from \"./main-image\"\nimport { LayoutWrapper } from \"./layout-wrapper\"\nimport PropTypes from \"prop-types\"\nimport type { FunctionComponent, WeakValidationMap } from \"react\"\nimport type { GatsbyImageProps, IGatsbyImageData } from \"./gatsby-image.browser\"\n\nconst removeNewLines = (str: string): string => str.replace(/\\n/g, ``)\n\nexport const GatsbyImage: FunctionComponent<GatsbyImageProps> =\n function GatsbyImage({\n as = `div`,\n className,\n class: preactClass,\n style,\n image,\n loading = `lazy`,\n imgClassName,\n imgStyle,\n backgroundColor,\n objectFit,\n objectPosition,\n ...props\n }) {\n if (!image) {\n console.warn(`[gatsby-plugin-image] Missing image prop`)\n return null\n }\n\n if (preactClass) {\n className = preactClass\n }\n\n imgStyle = {\n objectFit,\n objectPosition,\n backgroundColor,\n ...imgStyle,\n }\n\n const {\n width,\n height,\n layout,\n images,\n placeholder,\n backgroundColor: placeholderBackgroundColor,\n } = image\n\n const {\n style: wStyle,\n className: wClass,\n ...wrapperProps\n } = getWrapperProps(width, height, layout)\n\n const cleanedImages: IGatsbyImageData[\"images\"] = {\n fallback: undefined,\n sources: [],\n }\n if (images.fallback) {\n cleanedImages.fallback = {\n ...images.fallback,\n srcSet: images.fallback.srcSet\n ? removeNewLines(images.fallback.srcSet)\n : undefined,\n }\n }\n\n if (images.sources) {\n cleanedImages.sources = images.sources.map(source => {\n return {\n ...source,\n srcSet: removeNewLines(source.srcSet),\n }\n })\n }\n\n return React.createElement(\n as,\n {\n ...wrapperProps,\n style: {\n ...wStyle,\n ...style,\n backgroundColor,\n },\n className: `${wClass}${className ? ` ${className}` : ``}`,\n },\n <LayoutWrapper layout={layout} width={width} height={height}>\n <Placeholder\n {...getPlaceholderProps(\n placeholder,\n false,\n layout,\n width,\n height,\n placeholderBackgroundColor,\n objectFit,\n objectPosition\n )}\n />\n\n <MainImage\n data-gatsby-image-ssr=\"\"\n className={imgClassName}\n {...(props as Omit<\n MainImageProps,\n \"images\" | \"fallback\" | \"onError\" | \"onLoad\"\n >)}\n // When eager is set we want to start the isLoading state on true (we want to load the img without react)\n {...getMainProps(\n loading === `eager`,\n false,\n cleanedImages,\n loading,\n imgStyle\n )}\n />\n </LayoutWrapper>\n )\n }\n\nexport const altValidator: PropTypes.Validator<string> = (\n props: GatsbyImageProps,\n propName,\n componentName,\n ...rest\n): Error | undefined => {\n if (!props.alt && props.alt !== ``) {\n return new Error(\n `The \"alt\" prop is required in ${componentName}. If the image is purely presentational then pass an empty string: e.g. alt=\"\". Learn more: https://a11y-style-guide.com/style-guide/section-media.html`\n )\n }\n\n return PropTypes.string(props, propName, componentName, ...rest)\n}\n\nexport const propTypes = {\n image: PropTypes.object.isRequired,\n alt: altValidator,\n} as WeakValidationMap<GatsbyImageProps>\n","import {\n createElement,\n memo,\n useMemo,\n useEffect,\n useLayoutEffect,\n useRef,\n} from \"react\"\nimport {\n getWrapperProps,\n gatsbyImageIsInstalled,\n hasNativeLazyLoadSupport,\n} from \"./hooks\"\nimport { getSizer } from \"./layout-wrapper\"\nimport { propTypes } from \"./gatsby-image.server\"\nimport type {\n FC,\n ElementType,\n FunctionComponent,\n ImgHTMLAttributes,\n CSSProperties,\n ReactEventHandler,\n} from \"react\"\nimport type { renderImageToString } from \"./lazy-hydrate\"\nimport type { PlaceholderProps } from \"./placeholder\"\nimport type { MainImageProps } from \"./main-image\"\nimport type { Layout } from \"../image-utils\"\n\nconst imageCache = new Set<string>()\nlet renderImageToStringPromise\nlet renderImage: typeof renderImageToString | undefined\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport interface GatsbyImageProps\n extends Omit<\n ImgHTMLAttributes<HTMLImageElement>,\n \"placeholder\" | \"onLoad\" | \"src\" | \"srcSet\" | \"width\" | \"height\"\n > {\n alt: string\n as?: ElementType\n className?: string\n class?: string\n imgClassName?: string\n image: IGatsbyImageData\n imgStyle?: CSSProperties\n backgroundColor?: string\n objectFit?: CSSProperties[\"objectFit\"]\n objectPosition?: CSSProperties[\"objectPosition\"]\n onLoad?: (props: { wasCached: boolean }) => void\n onError?: ReactEventHandler<HTMLImageElement>\n onStartLoad?: (props: { wasCached: boolean }) => void\n}\n\nexport interface IGatsbyImageData {\n layout: Layout\n width: number\n height: number\n backgroundColor?: string\n images: Pick<MainImageProps, \"sources\" | \"fallback\">\n placeholder?: Pick<PlaceholderProps, \"sources\" | \"fallback\">\n}\n\nconst GatsbyImageHydrator: FC<GatsbyImageProps> = function GatsbyImageHydrator({\n as = `div`,\n image,\n style,\n backgroundColor,\n className,\n class: preactClass,\n onStartLoad,\n onLoad,\n onError,\n ...props\n}) {\n const { width, height, layout } = image\n const {\n style: wStyle,\n className: wClass,\n ...wrapperProps\n } = getWrapperProps(width, height, layout)\n const root = useRef<HTMLElement>()\n const cacheKey = useMemo(() => JSON.stringify(image.images), [image.images])\n\n // Preact uses class instead of className so we need to check for both\n if (preactClass) {\n className = preactClass\n }\n\n const sizer = getSizer(layout, width, height)\n\n useEffect(() => {\n if (!renderImageToStringPromise) {\n renderImageToStringPromise = import(`./lazy-hydrate`).then(\n ({ renderImageToString, swapPlaceholderImage }) => {\n renderImage = renderImageToString\n\n return {\n renderImageToString,\n swapPlaceholderImage,\n }\n }\n )\n }\n\n // The plugin image component is a bit special where if it's server-side rendered, we add extra script tags to support lazy-loading without\n // In this case we stop hydration but fire the correct events.\n const ssrImage = root.current.querySelector(\n `[data-gatsby-image-ssr]`\n ) as HTMLImageElement\n if (ssrImage && hasNativeLazyLoadSupport()) {\n if (ssrImage.complete) {\n // Trigger onStartload and onLoad events\n onStartLoad?.({\n wasCached: true,\n })\n onLoad?.({\n wasCached: true,\n })\n\n // remove ssr key for state updates but add delay to not fight with native code snippt of gatsby-ssr\n setTimeout(() => {\n ssrImage.removeAttribute(`data-gatsby-image-ssr`)\n }, 0)\n } else {\n onStartLoad?.({\n wasCached: true,\n })\n\n ssrImage.addEventListener(`load`, function onLoadListener() {\n ssrImage.removeEventListener(`load`, onLoadListener)\n\n onLoad?.({\n wasCached: true,\n })\n // remove ssr key for state updates but add delay to not fight with native code snippt of gatsby-ssr\n setTimeout(() => {\n ssrImage.removeAttribute(`data-gatsby-image-ssr`)\n }, 0)\n })\n }\n\n imageCache.add(cacheKey)\n\n return\n }\n\n if (renderImage && imageCache.has(cacheKey)) {\n return\n }\n\n let animationFrame\n let cleanupCallback\n renderImageToStringPromise.then(\n ({ renderImageToString, swapPlaceholderImage }) => {\n if (!root.current) {\n return\n }\n\n root.current.innerHTML = renderImageToString({\n isLoading: true,\n isLoaded: imageCache.has(cacheKey),\n image,\n ...props,\n })\n\n if (!imageCache.has(cacheKey)) {\n animationFrame = requestAnimationFrame(() => {\n if (root.current) {\n cleanupCallback = swapPlaceholderImage(\n root.current,\n cacheKey,\n imageCache,\n style,\n onStartLoad,\n onLoad,\n onError\n )\n }\n })\n }\n }\n )\n\n // eslint-disable-next-line consistent-return\n return (): void => {\n if (animationFrame) {\n cancelAnimationFrame(animationFrame)\n }\n if (cleanupCallback) {\n cleanupCallback()\n }\n }\n }, [image])\n\n // useLayoutEffect is ran before React commits to the DOM. This allows us to make sure our HTML is using our cached image version\n useLayoutEffect(() => {\n if (imageCache.has(cacheKey) && renderImage) {\n root.current.innerHTML = renderImage({\n isLoading: imageCache.has(cacheKey),\n isLoaded: imageCache.has(cacheKey),\n image,\n ...props,\n })\n\n // Trigger onStartload and onLoad events\n onStartLoad?.({\n wasCached: true,\n })\n onLoad?.({\n wasCached: true,\n })\n }\n }, [image])\n\n // By keeping all props equal React will keep the component in the DOM\n return createElement(as, {\n ...wrapperProps,\n style: {\n ...wStyle,\n ...style,\n backgroundColor,\n },\n className: `${wClass}${className ? ` ${className}` : ``}`,\n ref: root,\n dangerouslySetInnerHTML: {\n __html: sizer,\n },\n suppressHydrationWarning: true,\n })\n}\n\nexport const GatsbyImage: FunctionComponent<GatsbyImageProps> = memo(\n function GatsbyImage(props) {\n if (!props.image) {\n if (process.env.NODE_ENV === `development`) {\n console.warn(`[gatsby-plugin-image] Missing image prop`)\n }\n\n return null\n }\n\n if (!gatsbyImageIsInstalled() && process.env.NODE_ENV === `development`) {\n console.warn(\n `[gatsby-plugin-image] You're missing out on some cool performance features. Please add \"gatsby-plugin-image\" to your gatsby-config.js`\n )\n }\n\n return createElement(GatsbyImageHydrator, props)\n }\n)\n\nGatsbyImage.propTypes = propTypes\nGatsbyImage.displayName = `GatsbyImage`\n","import React, { FunctionComponent, ReactElement } from \"react\"\nimport {\n altValidator,\n GatsbyImage as GatsbyImageServer,\n} from \"./gatsby-image.server\"\nimport { GatsbyImageProps, IGatsbyImageData } from \"./gatsby-image.browser\"\nimport PropTypes from \"prop-types\"\nimport { ISharpGatsbyImageArgs } from \"../image-utils\"\n\nexport interface IStaticImageProps\n extends Omit<GatsbyImageProps, \"image\">,\n Omit<ISharpGatsbyImageArgs, \"backgroundColor\"> {\n src: string\n}\n\n// These values are added by Babel. Do not add them manually\ninterface IPrivateProps {\n __imageData?: IGatsbyImageData\n __error?: string\n}\n\nexport function _getStaticImage(\n GatsbyImage: FunctionComponent<GatsbyImageProps>\n): React.FC<IStaticImageProps & IPrivateProps> {\n return function StaticImage({\n src,\n __imageData: imageData,\n __error,\n // We extract these because they're not meant to be passed-down to GatsbyImage\n /* eslint-disable @typescript-eslint/no-unused-vars */\n width,\n height,\n aspectRatio,\n tracedSVGOptions,\n placeholder,\n formats,\n quality,\n transformOptions,\n jpgOptions,\n pngOptions,\n webpOptions,\n avifOptions,\n blurredOptions,\n breakpoints,\n outputPixelDensities,\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ...props\n }): ReactElement {\n if (__error) {\n console.warn(__error)\n }\n\n if (imageData) {\n return <GatsbyImage image={imageData} {...props} />\n }\n console.warn(`Image not loaded`, src)\n if (!__error && process.env.NODE_ENV === `development`) {\n console.warn(\n `Please ensure that \"gatsby-plugin-image\" is included in the plugins array in gatsby-config.js, and that your version of gatsby is at least 2.24.78`\n )\n }\n return null\n }\n}\n\nconst StaticImage: React.FC<IStaticImageProps & IPrivateProps> =\n _getStaticImage(GatsbyImageServer)\n\nconst checkDimensionProps: PropTypes.Validator<number> = (\n props: IStaticImageProps & IPrivateProps,\n propName: keyof IStaticImageProps & IPrivateProps,\n ...rest\n) => {\n if (\n props.layout === `fullWidth` &&\n (propName === `width` || propName === `height`) &&\n props[propName]\n ) {\n return new Error(\n `\"${propName}\" ${props[propName]} may not be passed when layout is fullWidth.`\n )\n }\n return PropTypes.number(props, propName, ...rest)\n}\n\nconst validLayouts = new Set([`fixed`, `fullWidth`, `constrained`])\n\nexport const propTypes = {\n src: PropTypes.string.isRequired,\n alt: altValidator,\n width: checkDimensionProps,\n height: checkDimensionProps,\n sizes: PropTypes.string,\n layout: (props: IStaticImageProps & IPrivateProps): Error | undefined => {\n if (props.layout === undefined) {\n return undefined\n }\n if (validLayouts.has(props.layout)) {\n return undefined\n }\n\n return new Error(\n `Invalid value ${props.layout}\" provided for prop \"layout\". Defaulting to \"constrained\". Valid values are \"fixed\", \"fullWidth\" or \"constrained\".`\n )\n },\n}\n\nStaticImage.displayName = `StaticImage`\nStaticImage.propTypes = propTypes\n\nexport { StaticImage }\n","import {\n GatsbyImage as GatsbyImageBrowser,\n IGatsbyImageData,\n} from \"./gatsby-image.browser\"\nimport React from \"react\"\nimport {\n _getStaticImage,\n propTypes,\n IStaticImageProps,\n} from \"./static-image.server\"\n// These values are added by Babel. Do not add them manually\ninterface IPrivateProps {\n __imageData?: IGatsbyImageData\n __error?: string\n}\n\nconst StaticImage: React.FC<IStaticImageProps & IPrivateProps> =\n _getStaticImage(GatsbyImageBrowser)\n\nStaticImage.displayName = `StaticImage`\nStaticImage.propTypes = propTypes\n\nexport { StaticImage }\n","'use strict';\n\nconst preserveCamelCase = string => {\n\tlet isLastCharLower = false;\n\tlet isLastCharUpper = false;\n\tlet isLastLastCharUpper = false;\n\n\tfor (let i = 0; i < string.length; i++) {\n\t\tconst character = string[i];\n\n\t\tif (isLastCharLower && /[a-zA-Z]/.test(character) && character.toUpperCase() === character) {\n\t\t\tstring = string.slice(0, i) + '-' + string.slice(i);\n\t\t\tisLastCharLower = false;\n\t\t\tisLastLastCharUpper = isLastCharUpper;\n\t\t\tisLastCharUpper = true;\n\t\t\ti++;\n\t\t} else if (isLastCharUpper && isLastLastCharUpper && /[a-zA-Z]/.test(character) && character.toLowerCase() === character) {\n\t\t\tstring = string.slice(0, i - 1) + '-' + string.slice(i - 1);\n\t\t\tisLastLastCharUpper = isLastCharUpper;\n\t\t\tisLastCharUpper = false;\n\t\t\tisLastCharLower = true;\n\t\t} else {\n\t\t\tisLastCharLower = character.toLowerCase() === character && character.toUpperCase() !== character;\n\t\t\tisLastLastCharUpper = isLastCharUpper;\n\t\t\tisLastCharUpper = character.toUpperCase() === character && character.toLowerCase() !== character;\n\t\t}\n\t}\n\n\treturn string;\n};\n\nconst camelCase = (input, options) => {\n\tif (!(typeof input === 'string' || Array.isArray(input))) {\n\t\tthrow new TypeError('Expected the input to be `string | string[]`');\n\t}\n\n\toptions = Object.assign({\n\t\tpascalCase: false\n\t}, options);\n\n\tconst postProcess = x => options.pascalCase ? x.charAt(0).toUpperCase() + x.slice(1) : x;\n\n\tif (Array.isArray(input)) {\n\t\tinput = input.map(x => x.trim())\n\t\t\t.filter(x => x.length)\n\t\t\t.join('-');\n\t} else {\n\t\tinput = input.trim();\n\t}\n\n\tif (input.length === 0) {\n\t\treturn '';\n\t}\n\n\tif (input.length === 1) {\n\t\treturn options.pascalCase ? input.toUpperCase() : input.toLowerCase();\n\t}\n\n\tconst hasUpperCase = input !== input.toLowerCase();\n\n\tif (hasUpperCase) {\n\t\tinput = preserveCamelCase(input);\n\t}\n\n\tinput = input\n\t\t.replace(/^[_.\\- ]+/, '')\n\t\t.toLowerCase()\n\t\t.replace(/[_.\\- ]+(\\w|$)/g, (_, p1) => p1.toUpperCase())\n\t\t.replace(/\\d+(\\w|$)/g, m => m.toUpperCase());\n\n\treturn postProcess(input);\n};\n\nmodule.exports = camelCase;\n// TODO: Remove this for the next major release\nmodule.exports.default = camelCase;\n","import React, { useEffect, useRef } from \"react\";\n\nimport type { Nullable } from \"@/types\";\n\nimport * as styles from \"./Page.module.scss\";\n\ninterface Props {\n title?: string;\n children: React.ReactNode;\n}\n\nconst Page: React.FC<Props> = ({ title, children }: Props) => {\n const pageRef = useRef<Nullable<HTMLDivElement>>(null);\n\n useEffect(() => {\n if (pageRef.current) {\n pageRef.current.scrollIntoView();\n }\n }, []);\n\n return (\n <div ref={pageRef} className={styles.page}>\n <div className={styles.inner}>\n {title && <h1 className={styles.title}>{title}</h1>}\n <div className={styles.body}>{children}</div>\n </div>\n </div>\n );\n};\n\nexport default Page;\n","// extracted by mini-css-extract-plugin\nexport var body = \"Page-module--body--561c4\";\nexport var inner = \"Page-module--inner--4b31d\";\nexport var page = \"Page-module--page--24e03\";\nexport var title = \"Page-module--title--90338\";","import React, { FC } from \"react\";\n\nimport { graphql, StaticQuery } from \"gatsby\";\nimport {\n GatsbyImage,\n GatsbyImageProps,\n IGatsbyImageData,\n} from \"gatsby-plugin-image\";\nimport { FileSystemNode } from \"gatsby-source-filesystem\";\n\ninterface Props extends Omit<GatsbyImageProps, \"image\"> {\n path: string;\n}\n\ninterface Data {\n images: {\n edges: Array<{\n node: FileSystemNode & {\n childImageSharp: {\n gatsbyImageData: IGatsbyImageData;\n };\n };\n }>;\n };\n}\n\nconst Image: FC<Props> = ({ path, ...rest }: Props) => (\n <StaticQuery\n query={graphql`\n query {\n images: allFile(\n filter: { ext: { regex: \"/png|jpg|jpeg|webp|tif|tiff/\" } }\n ) {\n edges {\n node {\n absolutePath\n childImageSharp {\n gatsbyImageData(formats: [AUTO, WEBP, AVIF])\n }\n }\n }\n }\n }\n `}\n render={(data: Data) => {\n const { images: { edges = [] } = {} } = data;\n const image = edges.find(({ node }) => node.absolutePath.includes(path));\n\n if (!image) {\n return null;\n }\n\n const {\n node: { childImageSharp },\n } = image;\n\n return <GatsbyImage {...rest} image={childImageSharp.gatsbyImageData} />;\n }}\n />\n);\n\nexport default Image;\n","// extracted by mini-css-extract-plugin\nexport var author = \"Author-module--author--cbd31\";\nexport var link = \"Author-module--link--09c17\";\nexport var photo = \"Author-module--photo--9787b\";\nexport var subtitle = \"Author-module--subtitle--86ec5\";\nexport var title = \"Author-module--title--cf7e5\";\nexport var titleContainer = \"Author-module--titleContainer--4f576\";","import React from \"react\";\n\nimport { Link } from \"gatsby\";\n\nimport { Image } from \"@/components/Image\";\nimport { ThemeSwitcher } from \"@/components/ThemeSwitcher\";\n\nimport * as styles from \"./Author.module.scss\";\n\ntype Props = {\n author: {\n name: string;\n bio: string;\n photo: string;\n };\n isIndex?: boolean;\n};\n\nconst Author = ({ author, isIndex }: Props) => (\n <div className={styles.author}>\n <Link to=\"/\">\n <Image alt={author.name} path={author.photo} className={styles.photo} />\n </Link>\n\n <div className={styles.titleContainer}>\n {isIndex ? (\n <h1 className={styles.title}>\n <Link className={styles.link} to=\"/\">\n {author.name}\n </Link>\n </h1>\n ) : (\n <h2 className={styles.title}>\n <Link className={styles.link} to=\"/\">\n {author.name}\n </Link>\n </h2>\n )}\n <ThemeSwitcher />\n </div>\n <p className={styles.subtitle}>{author.bio}</p>\n </div>\n);\n\nexport default Author;\n","import React from \"react\";\n\nimport { ICONS } from \"@/constants\";\n\nimport * as styles from \"./Icon.module.scss\";\n\ninterface Props {\n name: keyof typeof ICONS;\n icon: {\n viewBox?: string;\n path?: string;\n };\n}\n\nconst Icon: React.FC<Props> = ({ name, icon }: Props) => (\n <svg className={styles.icon} viewBox={icon.viewBox}>\n <title>{name}</title>\n <path d={icon.path} />\n </svg>\n);\n\nexport default Icon;\n","// extracted by mini-css-extract-plugin\nexport var icon = \"Icon-module--icon--1d7da\";","// extracted by mini-css-extract-plugin\nexport var contacts = \"Contacts-module--contacts--09178\";\nexport var item = \"Contacts-module--item--f9cb0\";\nexport var link = \"Contacts-module--link--de1e0\";\nexport var list = \"Contacts-module--list--9670b\";","import React from \"react\";\n\nimport { atob } from \"abab\";\n\nimport { Icon } from \"@/components/Icon\";\nimport { ICONS } from \"@/constants\";\nimport { Dictionary } from \"@/types\";\nimport { getContactHref, getIcon } from \"@/utils\";\n\nimport * as styles from \"./Contacts.module.scss\";\n\ntype Props = {\n contacts: Dictionary<string>;\n};\n\nconst Contacts: React.FC<Props> = ({ contacts }: Props) => (\n <div className={styles.contacts}>\n <ul className={styles.list}>\n {(Object.keys(contacts) as Array<keyof typeof ICONS>).map((name) =>\n contacts[name] ? (\n <li className={styles.item} key={name}>\n {name === \"email\" ? (\n <span\n className={styles.link}\n onClick={() => {\n window.location.href =\n \"mailto:\" + atob(getContactHref(name, contacts[name]));\n }}\n >\n <Icon name={name} icon={getIcon(name)} />\n </span>\n ) : (\n <a\n className={styles.link}\n href={getContactHref(name, contacts[name])}\n target=\"_blank\"\n rel={`noopener noreferrer${name === \"mastodon\" ? \" me\" : \"\"}`}\n >\n <Icon name={name} icon={getIcon(name)} />\n </a>\n )}\n </li>\n ) : null,\n )}\n </ul>\n </div>\n);\n\nexport default Contacts;\n","import React from \"react\";\n\nimport * as styles from \"./Copyright.module.scss\";\n\ntype Props = {\n copyright: string;\n};\n\nconst Copyright = ({ copyright }: Props) => (\n <div className={styles.copyright}>{copyright}</div>\n);\n\nexport default Copyright;\n","// extracted by mini-css-extract-plugin\nexport var copyright = \"Copyright-module--copyright--2c602\";","import React from \"react\";\n\nimport { Link } from \"gatsby\";\n\nimport * as styles from \"./Menu.module.scss\";\n\ntype Props = {\n menu: Array<{\n label: string;\n path: string;\n }>;\n};\n\nconst Menu: React.FC<Props> = ({ menu }: Props) => (\n <nav className={styles.menu}>\n <ul className={styles.list}>\n {menu.map((item) => (\n <li className={styles.item} key={item.path}>\n <Link\n to={item.path}\n className={styles.link}\n activeClassName={styles.active}\n >\n {item.label}\n </Link>\n </li>\n ))}\n </ul>\n </nav>\n);\n\nexport default Menu;\n","// extracted by mini-css-extract-plugin\nexport var active = \"Menu-module--active--6cb74\";\nexport var item = \"Menu-module--item--8b679\";\nexport var link = \"Menu-module--link--a6f02\";\nexport var list = \"Menu-module--list--e1ae3\";\nexport var menu = \"Menu-module--menu--113a9\";","import React from \"react\";\n\nimport { useSiteMetadata } from \"@/hooks\";\n\nimport { Author } from \"./Author\";\nimport { Contacts } from \"./Contacts\";\nimport { Copyright } from \"./Copyright\";\nimport { Menu } from \"./Menu\";\n\nimport * as styles from \"./Sidebar.module.scss\";\n\ntype Props = {\n isIndex?: boolean;\n};\n\nconst Sidebar = ({ isIndex }: Props) => {\n const { author, copyright, menu } = useSiteMetadata();\n\n return (\n <div className={styles.sidebar}>\n <div className={styles.inner}>\n <Author author={author} isIndex={isIndex} />\n <Menu menu={menu} />\n <Contacts contacts={author.contacts} />\n <Copyright copyright={copyright} />\n </div>\n </div>\n );\n};\n\nexport default Sidebar;\n","// extracted by mini-css-extract-plugin\nexport var inner = \"Sidebar-module--inner--344d0\";\nexport var sidebar = \"Sidebar-module--sidebar--1bfa1\";"],"names":["N","height","HTMLImageElement","prototype","j","e","t","a","i","r","u","loading","shouldLoad","style","opacity","O","n","s","o","l","backgroundColor","width","position","top","left","bottom","right","objectFit","objectPosition","d","transition","z","D","_ref5","layout","paddingTop","maxWidth","display","alt","role","src","A","children","c","q","P","H","srcSet","decoding","G","fallback","sources","sizes","length","map","_ref6","media","type","key","V","propTypes","displayName","B","F","Error","U","Y","_len","arguments","Array","_key","h","concat","X","image","J","Z","K","Set","Q","ee","te","as","className","class","g","onStartLoad","p","onLoad","m","onError","f","w","y","b","v","E","M","k","S","$","I","JSON","stringify","images","x","then","_ref7","renderImageToString","swapPlaceholderImage","current","querySelector","complete","wasCached","setTimeout","removeAttribute","addEventListener","removeEventListener","add","has","_ref8","innerHTML","isLoading","isLoaded","requestAnimationFrame","cancelAnimationFrame","ref","dangerouslySetInnerHTML","__html","suppressHydrationWarning","ae","ie","re","_len2","_key2","ne","se","oe","__imageData","__error","console","warn","camelCase","input","options","isArray","TypeError","Object","assign","pascalCase","trim","filter","join","toUpperCase","toLowerCase","string","isLastCharLower","isLastCharUpper","isLastLastCharUpper","character","test","slice","preserveCamelCase","replace","_","p1","charAt","module","exports","_ref","title","pageRef","useRef","useEffect","scrollIntoView","React","path","rest","StaticQuery","query","render","data","edges","find","_ref2","node","absolutePath","includes","childImageSharp","GatsbyImage","gatsbyImageData","author","isIndex","Link","to","Image","name","photo","styles","ThemeSwitcher","bio","icon","viewBox","contacts","keys","onClick","window","location","href","atob","getContactHref","Icon","getIcon","target","rel","copyright","menu","item","activeClassName","label","useSiteMetadata","Author","Menu","Contacts","Copyright"],"sourceRoot":""}