diff --git a/apps/web/components/content/integ/Integrated.tsx b/apps/web/components/content/integ/Integrated.tsx new file mode 100644 index 0000000..cec8bb4 --- /dev/null +++ b/apps/web/components/content/integ/Integrated.tsx @@ -0,0 +1,132 @@ +import React from 'react'; + +const services = [ + { + icon: '/picture/1.jpg', // 这里可以替换为图片或SVG + label: '军队自考', + href: '/study', + }, + { + icon: '/picture/2.jpg', + label: '军人', + href: '/scholarship', + }, + { + icon: '/picture/3.jpg', + label: '蓝天邮局', + href: '/mail', + }, + { + icon: '/picture/4.jpg', + label: '策划工具', + href: '/plan', + }, + { + icon: '/picture/5.jpg', + label: '情调研', + href: '/survey', + }, + { + icon: '/picture/6.jpg', + label: '上网助手', + href: '/net', + }, + { + icon: '/picture/7.jpg', + label: '常用软件', + href: '/software', + }, + { + icon: '/picture/8.jpg', + label: '智能语音', + href: '/voice', + }, + { + icon: '/picture/9.jpg', + label: '办公模板', + href: '/office', + }, + { + icon: '/picture/10.jpg', + label: '智能校对', + href: '/ai-check', + }, + { + icon: '/picture/11.jpg', + label: '考试平台', + href: '/exam', + }, + { + icon: '/picture/12.jpg', + label: '学习平台', + href: '/study', + }, +]; + +const Integrated: React.FC = () => { + return ( +
+
+
+ + 综合服务 + +
+ + + + +
+ {services.map((service, index) => { + // 计算实际显示位置 + const row = Math.floor(index / 6); + const col = index % 6; + + // 根据行数调整列的顺序 + let displayCol = col; + // if (row === 0) { + // // 第一行:右下、左下顺序 + // displayCol = col < 3 ? col + 3 : col - 3; + // } else { + // // 第二行:右上、左上顺序 + // displayCol = col < 3 ? col + 3 : col - 3; + // } + + // 确定内容在网格中的位置 + const positionClass = row === 0 + ? (col % 2 === 0 ? 'bottom-0 right-0' : 'bottom-0 left-0') // 第一行:右下、左下 + : (col % 2 === 0 ? 'top-0 right-0' : 'top-0 left-0'); // 第二行:右上、左上 + + return ( + // 外部 div:负责网格布局和白色背景,本身不可点击 +
+ {/* 这个 div 是 104x108 的容器,绝对定位在单元格内,并负责对齐其内部的可点击链接 */} +
+ {/* 这个 标签是可点击的区域,它将包裹图标和标签,并作为 Flex 容器垂直排列它们 */} + + {/* 为图标创建一个圆形背景的 div */} +
+ {/* 图标:应用文本颜色 */} + {service.label} +
+ {/* 标签:没有额外颜色类,使用默认文本颜色 */} + {service.label} +
+
+
+ ); + })} +
+
+
+ ); +}; + +export default Integrated; \ No newline at end of file diff --git a/apps/web/public/picture/1.jpg b/apps/web/public/picture/1.jpg new file mode 100644 index 0000000..e610636 Binary files /dev/null and b/apps/web/public/picture/1.jpg differ diff --git a/apps/web/public/picture/10.jpg b/apps/web/public/picture/10.jpg new file mode 100644 index 0000000..0545b73 Binary files /dev/null and b/apps/web/public/picture/10.jpg differ diff --git a/apps/web/public/picture/11.jpg b/apps/web/public/picture/11.jpg new file mode 100644 index 0000000..3ee73ce Binary files /dev/null and b/apps/web/public/picture/11.jpg differ diff --git a/apps/web/public/picture/12.jpg b/apps/web/public/picture/12.jpg new file mode 100644 index 0000000..1adf285 Binary files /dev/null and b/apps/web/public/picture/12.jpg differ diff --git a/apps/web/public/picture/2.jpg b/apps/web/public/picture/2.jpg new file mode 100644 index 0000000..cf3776a Binary files /dev/null and b/apps/web/public/picture/2.jpg differ diff --git a/apps/web/public/picture/3.jpg b/apps/web/public/picture/3.jpg new file mode 100644 index 0000000..75b01b1 Binary files /dev/null and b/apps/web/public/picture/3.jpg differ diff --git a/apps/web/public/picture/4.jpg b/apps/web/public/picture/4.jpg new file mode 100644 index 0000000..13fca73 Binary files /dev/null and b/apps/web/public/picture/4.jpg differ diff --git a/apps/web/public/picture/5.jpg b/apps/web/public/picture/5.jpg new file mode 100644 index 0000000..175086d Binary files /dev/null and b/apps/web/public/picture/5.jpg differ diff --git a/apps/web/public/picture/6.jpg b/apps/web/public/picture/6.jpg new file mode 100644 index 0000000..8f1c94a Binary files /dev/null and b/apps/web/public/picture/6.jpg differ diff --git a/apps/web/public/picture/7.jpg b/apps/web/public/picture/7.jpg new file mode 100644 index 0000000..09028e4 Binary files /dev/null and b/apps/web/public/picture/7.jpg differ diff --git a/apps/web/public/picture/8.jpg b/apps/web/public/picture/8.jpg new file mode 100644 index 0000000..3516ef0 Binary files /dev/null and b/apps/web/public/picture/8.jpg differ diff --git a/apps/web/public/picture/9.jpg b/apps/web/public/picture/9.jpg new file mode 100644 index 0000000..2809da0 Binary files /dev/null and b/apps/web/public/picture/9.jpg differ