Communitygithub.com

KazmerMaximiliano/neus-ui

生成完整的 SaaS 落地页,包含英雄区、功能展示、社交证明、定价和页脚行动号召。输出 .tsx 文件,使用 Neus UI 的 Button、Card 和 Link 组件,并带有自定义导航头部。

neus-ui 是什么?

该技能专为需要快速构建面向产品营销的 SaaS 落地页而设计,适用于 Claude Code、Cursor 等 AI 代码代理。它完全基于 Neus UI 组件库(Button、Card、Link)生成代码,并明确不使用 AppTemplate,确保页面是公开营销页面而非应用仪表盘。工作流程清晰:首先收集用户输入(产品名称、功能亮点、定价方案、社交证明、主题色等),然后解析视觉指令(深色/浅色模式、视觉个性),最后依次生成三个文件:类型定义(ProductLanding.types.ts)、主组件(ProductLanding.tsx)和样式(ProductLanding.styles.css)。技能内置了严格的质量规则,禁止虚构数据、内联样式、非 Neus UI 的 HTML 标签,并强制按规范使用组件 prop。深色模式自动应用卡片变体、背景颜色和毛玻璃导航。最终落地页包含导航头部、英雄区、功能卡片网格、可选定价/社交证明区域和页脚行动号召,所有动画均为预置的 neus-fade-up 渐变效果。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/KazmerMaximiliano/neus-ui/tree/HEAD/.agents/skills/neus-landing-saas

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

Neus Landing SaaS

生成包含英雄区、功能展示、可选社交证明、可选定价和页脚行动号召的产品落地页。

重要提示:此页面不使用 AppTemplate。它是一个公开营销页面。

开始之前

下面的“共享规则”部分始终生效。此外,请阅读:

  • .agents/skills/_shared/anti-slop.md — 强制性质量规则(“营销页面”部分)
  • .agents/skills/_shared/prop-constraints.md — 禁止的 prop 和不存在的组件
  • .agents/skills/_shared/component-catalog.md — Button、Card、Link 部分
  • .agents/skills/_shared/theme-config.md — ThemeProvider 配置
  • .agents/skills/_shared/design-personality.md — VISUAL DIRECTIVE 格式、个性轴
  • .agents/skills/_shared/checklist.md — P0/P1/P2 关卡
  • .agents/skills/_shared/dark-surfaces.md — 深色模式 CSS 配方(当模式为 dark 时阅读)
  • .agents/skills/_shared/light-surfaces.md — 浅色模式 CSS 配方(当模式为 light 时阅读)
  • .agents/skills/_shared/layout-patterns.md — 可选的进阶落地页布局模式
  • references/landing-sections.md — 各部分模式

阶段 0 — 收集数据

在生成之前,向用户询问以下问题并等待他们完整回答:


定价 — 落地页是否包含定价部分?

  • 是,包含方案和价格(推荐)— 包含定价方案卡片的部分
  • 否,仅英雄区 + 功能 + 行动号召 — 不含定价的落地页

社交证明 — 是否包含社交证明(推荐语或数据指标)?

  • 是,真实的推荐语/数据指标 — 用户将提供
  • 否,无社交证明 — 完全省略推荐语部分

同时在你的回复中包含:

  • 产品名称和标语(1 行)
  • 要突出的功能(最多 6 个,精确格式:标题 + 简短描述)
  • 主要行动号召:按钮文本 + 目标链接
  • 如果包含定价:方案(名称 + 价格 + 周期 + 包含的功能 — 精确)
  • 如果包含社交证明:精确的推荐语或数据指标(如果用户说“否”,则完全省略)
  • 主要主题色(十六进制或“使用默认值”)
  • 导航头部项目(导航链接)
  • 主题模式:浅色还是深色?(默认:浅色)
  • 视觉个性:简洁/通透、社论/层次、大胆/动感、或结构化?(可选)

阶段 1 — 视觉解析

在编写任何代码之前,解析 VISUAL DIRECTIVE:

  • 模式:dark → 阅读 dark-surfaces.md;使用 #0a0a14 画布、毛玻璃导航、功能卡片使用 <Card variant="glass">、英雄区按钮使用 color="white"
  • 模式:light → 阅读 light-surfaces.md;使用 var(--color-white) 画布、标准 <Card>、按钮使用 color="primary"

声明:

VISUAL DIRECTIVE
  Mode: dark | light
  Personality: [从收集数据中获取或默认:Structured]
  Surface file: dark-surfaces.md | light-surfaces.md

阶段 1b — P0 验证

  • 零虚构数据 — 所有内容均来自收集数据或用户明确指定使用的内容
  • 无 AppTemplate,无 Sidebar
  • 精确的功能来自收集数据(不添加“直觉”之外的额外内容)
  • 如果用户说“无社交证明” → 输出中零条推荐语

阶段 2 — 生成产物

阅读 references/landing-sections.md 以了解每个部分的模式。

按此顺序生成三个文件:ProductLanding.types.ts → ProductLanding.tsx → ProductLanding.styles.css。

ProductLanding.types.ts

export type NavItem = {
  label: string;
  href: string;
};

export type Feature = {
  icon: string;
  title: string;
  description: string;
};

export type PricingPlan = {
  name: string;
  price: string;
  period: string;
  features: string[];
  cta: string;
  highlighted?: boolean;
};

export type ProductLandingProps = {
  // 静态营销内容 — 无 API props
  onGetStarted?: () => void;
};

基础组件结构

import { Button, Card, Link } from 'neus-ui';
import './ProductLanding.styles.css';
import type { ProductLandingProps } from './ProductLanding.types';

export const ProductLanding = ({ onGetStarted }: ProductLandingProps) => {
  return (
    <div className="landing">
      {/* 1. 导航头部 */}
      <header className="landing__nav">...</header>

      {/* 2. 英雄区 */}
      <section className="landing__hero">
        <h1>[Product Name] — [Tagline from intake]</h1>
        <p>[Subheading from intake]</p>
        <div className="landing__hero-cta">
          <Button label="[CTA from intake]" variant="solid" color="primary" />
          {/* 英雄区中的次要链接:使用 type="primary" — 英雄区有浅色背景 */}
          <Link label="See how it works" type="primary" href="#features" />
        </div>
      </section>

      {/* 3. 功能展示(精确来自收集数据的功能) */}
      <section className="landing__features">
        <h2>Features</h2>
        <div className="landing__features-grid">
          {/* 每个功能一张 Card — 完全按照指定内容 */}
        </div>
      </section>

      {/* 4. 社交证明(仅在请求并且提供了数据时) */}
      {/* 5. 定价(仅在请求时) */}
      {/* 6. 页脚行动号召 */}
      {/* 7. 页脚 */}
    </div>
  );
};

功能卡片

使用带有 icon、title 和 description 插槽的 Card:

<Card
  icon={<SomeIcon size={24} color="var(--color-primary)" />}
  title="[Feature title from intake]"
  description="[Feature description from intake]"
/>

定价卡片

使用带有 highlighted prop 的 Card。在 children 中组合完整内容:

<Card highlighted={plan.highlighted}>
  {plan.highlighted && <span className="pricing__badge">Most popular</span>}
  <p className="pricing__name">{plan.name}</p>
  <div className="pricing__amount">
    <span className="pricing__price">{plan.price}</span>
    <span className="pricing__period">{plan.period}</span>
  </div>
  <ul className="pricing__features">
    {plan.features.map((f) => (
      <li key={f}><span aria-hidden="true">✓</span> {f}</li>
    ))}
  </ul>
  <Button
    label={plan.cta}
    variant={plan.highlighted ? "solid" : "outlined"}
    color="primary"
    fullWidth
  />
</Card>

缺少的 Neus UI 组件

  • NavigationBar:使用 <header> 配合 flex 导航 — 视为待定
  • TestimonialCard:使用带有 avatarImage + 引用内容的 Card(如果请求)

阶段 3 — ProductLanding.styles.css

根据 VISUAL DIRECTIVE 应用模式。查阅 .agents/skills/_shared/layout-patterns.md 的落地页部分以获取可选的进阶模式(统计行、分节标题、英雄展示网格、紧凑卡片网格、眉毛药丸)。

@keyframes neus-fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* 浅色模式(默认) */
.landing { font-family: var(--font-display); }
.landing__nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  /* 浅色毛玻璃导航 */
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
/* 深色模式导航 — 当模式为 dark 时应用 */
/* .landing__nav { background: rgba(10, 10, 20, 0.8); border-bottom: 1px solid rgba(255,255,255,0.06); } */
.landing__hero {
  display: grid;
  grid-template-columns: 1.4fr 0.6fr;
  align-items: center;
  gap: 3rem;
  padding: 6rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}
/* 如果右侧没有视觉元素,使用居中单列: */
/* .landing__hero { text-align: center; padding: 6rem 2rem; max-width: 800px; margin: 0 auto; } */
.landing__hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--color-gray-900);
  margin-bottom: 1rem;
  animation: neus-fade-up 0.5s ease forwards;
}
/* 深色模式 H1 — 可选渐变文本 */
/* .landing__hero h1 { color: #e2e8f0; }
   在 H1 元素上应用 .neus-gradient-text 以获得渐变文本效果 */
.landing__hero p {
  font-size: 1.25rem;
  color: var(--color-gray-600);
  margin-bottom: 2rem;
  animation: neus-fade-up 0.5s 0.1s ease both;
}
.landing__hero-cta {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: 1.5rem;
  animation: neus-fade-up 0.5s 0.2s ease both;
}
.landing__features { padding: 6rem 2rem; max-width: 1200px; margin: 0 auto; }
.landing__features h2 {
  font-family: var(--font-display);
  text-align: center;
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 3rem;
  color: var(--color-gray-900);
}
/* 旗舰功能:第一张卡片占满整行 */
.landing__features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 2rem; }
.landing__features-grid > *:first-child { grid-column: 1 / -1; }
/* 交错卡片动画 */
.landing__features-grid > *:nth-child(1) { animation: neus-fade-up 0.5s 0.05s ease both; }
.landing__features-grid > *:nth-child(2) { animation: neus-fade-up 0.5s 0.15s ease both; }
.landing__features-grid > *:nth-child(3) { animation: neus-fade-up 0.5s 0.25s ease both; }
.landing__features-grid > *:nth-child(4) { animation: neus-fade-up 0.5s 0.35s ease both; }
/* 交替部分背景 */
.landing__features-alt { background: var(--color-primary-light); }
/* 页脚行动号召 */
.landing__cta-section { background: var(--color-primary-light); padding: 6rem 2rem; text-align: center; }

/* 深色模式页面覆盖 — 当模式为 dark 时应用 */
/* .landing { background: #0a0a14; color: #e2e8f0; } */
/* .landing__features h2 { color: #e2e8f0; } */
/* .landing__features-alt { background: rgba(20,20,40,0.4); } */
/* .landing__cta-section { background: rgba(99,102,241,0.1); border-top: 1px solid rgba(129,140,248,0.2); } */

共享规则(内嵌)

这些规则始终生效。即使未读取 _shared/ 文件,它们也适用。

输出 — 始终三个文件

每个技能输出:ComponentName.types.ts → ComponentName.tsx → ComponentName.styles.css。 无内联样式(style={{}})。组件内无 <style> 标签。CSS 仅放在 .styles.css 中。

导入

import { Button, Card, Input, Badge, Link, Select, Modal, DataTable } from 'neus-ui';

绝不要从内部路径如 ../../components/Button/Button 导入。

类型

所有 type / interface 声明 → ComponentName.types.ts。绝不在 .tsx 中声明类型。

React 19 — 无 FormEvent

绝不要 import { FormEvent } from 'react'。改用 <Button type="submit" onClick={...} />。

组件 Prop 约束

  • Button variant:"solid" | "outlined" | "text" — "ghost" 不存在
  • Button color:"primary" | "success" | "error" | "info" | "white" — "white" 仅用于深色画布
  • Button size:"small" | "medium" | "large"
  • Card variant:"default" | "glass" — "glass" 用于深色画布
  • Badge color:"primary" | "success" | "error" | "info" | "neutral"
  • Link type:"primary"(品牌色)| "secondary"(灰色调和)
  • Select:无 required prop — 在外部处理验证
  • FormTemplate:仅 children、submitLabel、loading — 无 onSubmit/onCancel

内容黑名单

  • 无内联样式 / style={{}} / <style> 标签
  • 当数据来自 API 时,无硬编码数组 — 使用类型化的 props
  • 无虚构文案(伪造的推荐语、占位名称、假指标)
  • 无 any TypeScript 类型
  • 当存在 Neus UI 组件时,无原始 <a>、<span>、<input>、<button>
  • 无硬编码字体栈 — 使用 var(--font-display) / var(--font-mono)
  • 在深色模式下:无 var(--color-primary-light) 作为部分背景;无原始 div 卡片 — 使用 <Card variant="glass">

Individual skills in this repo

This repo contains 3 individual skills — each has its own dedicated page.

相关技能