Bakit

ba-figma-sync — Figma Make prompt lane

Sinh prompt text paste-ready cho Figma Make từ SRS canon đã duyệt. Không dùng MCP, không cần file thiết kế.

ba-figma-sync

/ba-figma-sync sinh prompt text paste-ready cho Figma Make từ SRS canon đã duyệt. Không gọi MCP tool nào (không Figma MCP, không Pencil MCP, không Stitch MCP). Figma Make không có API — cách dùng duy nhất là paste prompt vào chat của nó.

Cách gọi

RuntimeLệnh
Claude Code/ba-figma-sync --slug ten-du-an --module thanh-toan
Codex$ba-figma-sync --slug ten-du-an --module thanh-toan
Antigravity"Đọc skills/ba-figma-sync/SKILL.md và sinh prompt Figma Make cho slug X, module Y"

Flags thường dùng

--refresh-shared   # Sinh lại baseline dùng chung (khi đổi DESIGN.md)
--uc <usecase>     # Chỉ 1 use case thay vì toàn bộ module
--dry-run          # Xem plan, không ghi file

Cách hoạt động

  1. Đọc SRS canon của module: srs-compile-receipt.json, ascii-screen/, screen-field-contract.yaml
  2. Kiểm tra điều kiện tiên quyết: phải có DESIGN.md, shared-shell-contract.md, receipt không stale
  3. Sinh shared baseline (shared-prompt-skeleton.md) — khoá design system, màu sắc, typography, navigation
  4. Sinh prompt từng UC (uc-{slug}-make-prompt.md) — paste-ready prompt cho default state + follow-up prompts cho error/empty/loading states
  5. Sinh prototype-conformance-checklist.md để BA tự kiểm tra output Figma Make

Kết quả tạo ra

Tất cả output là file text, không phải file thiết kế:

  • shared-prompt-skeleton.md, shared-rules.md, shared-component-contracts.md — baseline dùng chung toàn module
  • uc-{slug}-make-prompt.md — prompt paste-ready cho từng use case
  • uc-{slug}-change-log.md — lịch sử phiên bản prompt đã sinh
  • make-guidelines.md, make-prompt-pack.md — index và hướng dẫn cho BA
  • prototype-conformance-checklist.md / prototype-conformance-report.md — checklist kiểm tra thủ công

Cách dùng với Figma Make

  1. Mở Figma Make, paste shared-prompt-skeleton.md trước (1 lần duy nhất)
  2. Với từng UC, paste uc-{slug}-make-prompt.md — paste prompt default state trước, rồi paste follow-up prompts trong cùng đoạn chat
  3. Đối chiếu kết quả Figma Make với prototype-conformance-checklist.md, điền vào report

Xem hướng dẫn chi tiết: ba-figma-sync-guide.md

Lưu ý: Đây là lane một chiều — từ BA canon sang Figma Make prompt. Không đọc ngược kết quả Figma Make về. Nếu Figma Make khác canon → sửa canon trước, chạy lại /ba-figma-sync.

On this page