广告点击添加

This commit is contained in:
谢宇宁
2026-10-29 16:37:54 +07:00
parent 654257a2d2
commit faf1b3d210
7 changed files with 97 additions and 1 deletions
+3
View File
@@ -1,4 +1,5 @@
import { DecryptedImage } from "@/components/common/decrypted-image";
import { adClickData } from "@/lib/api/ads-actions";
import type { AdvertiseInfo, AdvitiseData } from "@/lib/api/types";
import { IMG_PLACEHOLDER } from "@/lib/image/decrypt";
@@ -38,6 +39,7 @@ export function AdBanners({
href={href}
target={external ? "_blank" : undefined}
rel={external ? "sponsored nofollow noopener noreferrer" : undefined}
{...adClickData(ad)}
className="block aspect-[720/150] overflow-hidden rounded-xl"
>
<DecryptedImage
@@ -68,6 +70,7 @@ export function AdBanners({
href={href}
target={external ? "_blank" : undefined}
rel={external ? "sponsored nofollow noopener noreferrer" : undefined}
{...adClickData(ad)}
className="block aspect-[720/150] overflow-hidden rounded-xl"
>
<DecryptedImage
+2
View File
@@ -1,5 +1,6 @@
import { AdIconMarquee } from "@/components/common/ad-icon-marquee";
import { DecryptedImage } from "@/components/common/decrypted-image";
import { adClickData } from "@/lib/api/ads-actions";
import type { AdvertiseInfo, AdvitiseData } from "@/lib/api/types";
import { IMG_PLACEHOLDER } from "@/lib/image/decrypt";
@@ -45,6 +46,7 @@ export function AdSquares({ slot, variant = "pc", items, advitise, className = "
target={external ? "_blank" : undefined}
rel={external ? "sponsored nofollow noopener noreferrer" : undefined}
title={ad.title || undefined}
{...adClickData(ad)}
className={`group flex shrink-0 flex-col items-center gap-1.5 ${isH5 ? "w-[72px]" : "w-[120px]"}`}
>
<DecryptedImage