"use client"; import React from "react"; import Image from "next/image"; export default function UI({ data }) { if (!data) return null; // 主图 const mainImage = data.image || "/assets/img/photos/about2.jpg"; const secondImage = data.image_1 || "/assets/img/photos/about3.jpg"; // 标题/副标题/描述 const title = data.title || ""; const subtitle = data.subtitle || ""; const description = data.description || ""; const icon = data.icon || "/files/icon.svg"; const htmlCode = data.html_code || ""; const buttonText = data.button_text || "MORE"; const buttonLink = data.button_link || "#"; return (
{/* 右侧图片区 - 错开叠放 */}
{/* 装饰性背景点 */}
{/* 错开叠放的图片容器 */}
{/* 第一张图片 - 较大,位置偏右 */}
image
{/* 第二张图片 - 较小,位置偏左,覆盖第一张图片 */}
image
{/* 左侧内容区 */}
{htmlCode ? (
) : ( icon )}

{title}

); }