saas-landing
Single-page SaaS landing page featuring hero, features, social proof, pricing, and CTA sections.
1How It Works & Mechanism
This template is purely data within a "folder-as-template" architecture: SKILL.md uses YAML frontmatter for selector metadata, while the body serves as layout instructions for the agent; the repository contains no template-specific code, meaning adding a template equals adding a folder.
SKILL.md — frontmatter (id, scenario, tags, …) + prompt body
At runtime, the host sandwiches this template body between shared design directives and user content to assemble a prompt—the template's "intelligence" resides entirely within this natural language text, containing no executable code.
return `${SHARED_DESIGN_DIRECTIVES} ${opts.body.trim()}
After loading the template via the host's /api/convert, the text is passed to a locally logged-in coding-agent CLI, streaming stdout back exclusively as HTML; the template itself performs no network requests, reads no credentials, and writes no files.
prompt = assemblePrompt({ body: skill.body, content, format });
The bundled example.html serves as a "pre-rendered example" emitted as-is by the preview endpoint into selector and gallery iframes—it determines visual preview availability in template cards and plays no part in content generation.
Returns the skill's `example.html` verbatim so it can be loaded into an
Frontmatter fields are mapped item-by-item into selector metadata (featured controls global sorting, recommended places it in the top "★ Recommended" group, example_* generates sample card copy), governing its placement in category/scenario filters.
if (typeof fm.featured === "number") meta.featured = fm.featured;
The generation capability of this template is fulfilled entirely by its own body: saas-landing/SKILL.md solely defines layout, color palette, typography, and content guidelines, without a single instruction directing the agent to run tools, fetch APIs, or read external data.
【模板: SaaS Landing】
The body decomposes the landing page into a fixed checklist of sections, defining the task as mapping user content into these designated slots.
【意图】完整的 SaaS 产品落地页, 把用户内容映射到标准 sections。
The composition of each section is also strictly specified: Hero must include a headline + subheadline + dual CTAs + visual placeholder, and Pricing must feature 2–3 tiers with the recommended tier highlighted.
- Hero (大标题 + 副标 + 双 CTA + 可视化占位)
Styling instructions prescribe a modern SaaS visual design language (large typography / subtle gradients / glassmorphism cards / scroll-triggered entrance animations), serving as subjective descriptions rather than pixel-level specifications.
- 现代 SaaS 风: 大字号, 柔和渐变, glassmorphism 卡片, 滚动入场动画
Responsiveness is a strict requirement: handling at least the md: breakpoint and a single-column layout on mobile devices.
- 至少处理 `md:` 断点, 移动端单栏
The example artifact demonstrates this structural layout (nav → hero → features → logo wall → pricing → closing → footer), with zero external links and zero JavaScript throughout.
<section class="pricing wrap" id="pricing" data-od-id="pricing">
2Core Capabilities
3External Dependencies
| Kind | Dependency / Endpoint |
|---|---|
| cli | 本地 coding-agent CLI(宿主提供,模板自身不调用) |
4Recommended Governance & Evidence
- SKILL.md: Pure prompt directives and rule text, with no script execution or external side effects
5Second-Pass Verification
- [ok] skill 目录的脚本 / 网络 / 凭证 / 写盘面 — 目录仅 SKILL.md / example.html 2 个文件,无 scripts/references/数据目录;token 扫描(curl / wget / fetch / exec / spawn / process.env / API_KEY / token / secret / write / save / delete)在该目录的 SKILL.md 中零命中;无自带可执行脚本。
- [ok] 运行时链路复核 — 重读 loader.ts / shared.ts / app/api/convert/route.ts / app/api/templates/[id]/preview/route.ts:模板正文只作为 prompt body 被 assemblePrompt 拼装,宿主 spawn 本地 CLI 并捕获 stdout;模板不参与任何执行。
- [ok] commit 与元数据 — 工作副本 git HEAD = 553ed98c283f9c0f489902d035416a972d6a9699(=任务表 pin 的 full 40 位);GitHub API nexu-io/html-anything:stars 8827、license spdx Apache-2.0、pushed_at 2026-09-15T03:36:24Z(与本地 HEAD 提交时间 2026-09-15 11:36:24 +0800 一致)。
- [discrepancy] README 与源码的 frontmatter schema 漂移(仓库级) — README 第 213 / 217 / 468 行称模板 frontmatter 必须含 mode · scenario · surface · preview · design_system;但在 next/src/lib/templates/skills/ 下 '^mode:'、'^surface:'、'^design_system:' 全部零命中,实际字段是 category / scenario / aspect_hint / featured / recommended + example_*(loader.ts 的 SkillFrontmatter)。文档滞后于代码,不影响本模板运行,但照 README 新写模板会踩空。
- [ok] frontmatter 元数据映射 — loader.ts fmToMeta 逐字段映射 zhName / enName / emoji / description / category / scenario / aspectHint / tags + featured / recommended + example 卡;本模板取自 SKILL.md 的实际取值与之相符。
- [discrepancy] example.html 与 SKILL.md 的一致性(FAQ / How-it-works 缺席) — 正文列了 8 段,其中 '- How it works (3 步流程, 数字 + 标题 + 描述)' 与 '- FAQ (details/summary 手风琴)' 在 example.html 中不存在:示例只有 nav / hero / features / proof(logo wall) / pricing / closing / footer,全文件 'details'、'summary' 零命中。示例是「示意」而非严格实现,拿它当验收基准会少看到两段。
- [ok] 端点扫描(目录内) — saas-landing 目录 2 个文件 http(s) 字面量零命中;无 <script>、无 <link rel="stylesheet">,是 9 个模板里依赖面最干净的。
- [discrepancy] 「glassmorphism / 滚动入场动画」是否在示例中兑现 — 正文要求 "- 现代 SaaS 风: 大字号, 柔和渐变, glassmorphism 卡片, 滚动入场动画",示例有柔和配色与大字号(.hero h1 用 clamp(44px, 6vw, 76px)),但无 backdrop-filter 类玻璃卡片、无滚动入场动画。规格比示例更"先进"。
6Verdict & Scenarios
4f4424030c2a6b97…