diff --git a/apps/dashboard/src/@/components/blocks/Img.tsx b/apps/dashboard/src/@/components/blocks/Img.tsx index 89a0c4ba125..765d284b8b6 100644 --- a/apps/dashboard/src/@/components/blocks/Img.tsx +++ b/apps/dashboard/src/@/components/blocks/Img.tsx @@ -1,6 +1,7 @@ /* eslint-disable @next/next/no-img-element */ "use client"; -import { useState } from "react"; +import { useRef, useState } from "react"; +import { useIsomorphicLayoutEffect } from "../../lib/useIsomorphicLayoutEffect"; import { cn } from "../../lib/utils"; type imgElementProps = React.DetailedHTMLProps< @@ -25,19 +26,39 @@ export function Img(props: imgElementProps) { const { className, fallback, skeleton, ...restProps } = props; const defaultSkeleton =
; const defaultFallback = ; + const imgRef = useRef