const require_runtime = require("../../../../../../_virtual/_rolldown/runtime.js");
let react = require("react");
react = require_runtime.__toESM(react);
let classnames = require("classnames");
classnames = require_runtime.__toESM(classnames);
let src_components_productCard_components_Time_components_Like_like_heart_png = require("./like-heart.png");
src_components_productCard_components_Time_components_Like_like_heart_png = require_runtime.__toESM(src_components_productCard_components_Time_components_Like_like_heart_png);
let src_components_productCard_components_Time_components_Like_like_hide_heart_png = require("./like-hide-heart.png");
src_components_productCard_components_Time_components_Like_like_hide_heart_png = require_runtime.__toESM(src_components_productCard_components_Time_components_Like_like_hide_heart_png);
require("./index.less");
//#region src/components/productCard/components/Time/components/Like/index.tsx
const Like = ({ status, onLike, className, style, isShowChangeResource }) => {
	const url = status === "like" ? src_components_productCard_components_Time_components_Like_like_heart_png.default : src_components_productCard_components_Time_components_Like_like_hide_heart_png.default;
	const handleClick = (e) => {
		if (!onLike) return;
		e.preventDefault();
		e.stopPropagation();
		onLike === null || onLike === void 0 || onLike(status === "like" ? "common" : "like");
	};
	return /* @__PURE__ */ react.default.createElement("div", {
		onClick: handleClick,
		className: `pisell-lowcode-product-card-like-wrap ${isShowChangeResource ? "pisell-lowcode-change-resource-like-wrap" : ""}`
	}, /* @__PURE__ */ react.default.createElement("img", {
		style,
		src: url,
		className: (0, classnames.default)("like-icon", className)
	}));
};
//#endregion
exports.default = Like;
