Files
NapCatQQ/.pnpm-store/v3/files/1c/f5498cc007ec1f111328a024c341722ae091761d94f2cf04b2516113ec7b130308c04e7fe819e725b133243de1ff239205716ad0964082d9a3cd1db6076ac2
T
TanTan e311ca3275
Build NapCat Artifacts / Windows Loader Test (push) Canceled after 0s
Build NapCat Artifacts / Type Check & Test (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Framework (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Shell (push) Canceled after 0s
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

53 lines
1.2 KiB
Plaintext

"use client";
import {
useImage
} from "./chunk-DSOLHU5M.mjs";
// src/image.tsx
import { cloneElement } from "react";
import { forwardRef } from "@heroui/system";
import { jsx, jsxs } from "react/jsx-runtime";
var Image = forwardRef((props, ref) => {
const {
Component,
domRef,
slots,
classNames,
isBlurred,
isZoomed,
fallbackSrc,
removeWrapper,
disableSkeleton,
getImgProps,
getWrapperProps,
getBlurredImgProps
} = useImage({
...props,
ref
});
const img = /* @__PURE__ */ jsx(Component, { ref: domRef, ...getImgProps() });
if (removeWrapper) {
return img;
}
const zoomed = /* @__PURE__ */ jsx("div", { className: slots.zoomedWrapper({ class: classNames == null ? void 0 : classNames.zoomedWrapper }), children: img });
if (isBlurred) {
return /* @__PURE__ */ jsxs("div", { ...getWrapperProps(), children: [
isZoomed ? zoomed : img,
cloneElement(img, getBlurredImgProps())
] });
}
if (isZoomed || !disableSkeleton || fallbackSrc) {
return /* @__PURE__ */ jsxs("div", { ...getWrapperProps(), children: [
" ",
isZoomed ? zoomed : img
] });
}
return img;
});
Image.displayName = "HeroUI.Image";
var image_default = Image;
export {
image_default
};