视频点击问题

This commit is contained in:
杨丹华
2025-05-19 16:27:55 +08:00
parent 3d17bb9225
commit 32e8e0ace4

View File

@@ -304,8 +304,15 @@
}
});
/*图片放大效果*/
$(".bigImg").click(function () {
$(".enlarge-img").show();
$(".bigImg").click(function() {
// 判断容器内是否存在视频元素
if ($(this).find("video").length > 0) {
// 若存在视频,不执行任何操作
return;
} else if ($(this).find("img").length > 0) {
// 若存在图片,显示放大图片层
$(".enlarge-img").show();
}
});
$(".enlarge-img .close").click(function () {
$(".enlarge-img").hide();