更新 generate.md 和 layout-extract.md 文档:添加对参考图像的自动检测和使用说明

This commit is contained in:
catlog22
2025-10-12 10:11:08 +08:00
parent be2d0f24b6
commit 75ec70ad23
52 changed files with 25 additions and 53 deletions

View File

@@ -144,6 +144,11 @@ Task(ui-design-agent): `
Each template must include:
- target (string)
- variant_id (string, e.g., "layout-1")
- source_image_path (string, REQUIRED): Path to the primary reference image used for this layout analysis
* For image input: Use the actual image file path from {images_pattern}
* For URL input: Use the screenshot path if available, or empty string
* For text/prompt input: Use empty string
* Example: "{base_path}/screenshots/home.png"
- device_type (string)
- design_philosophy (string)
- dom_structure (JSON object)
@@ -276,6 +281,7 @@ bash(echo '{json}' > {base_path}/layout-extraction/layout-templates.json)
{
"target": "home",
"variant_id": "layout-1",
"source_image_path": "{base_path}/screenshots/home.png",
"device_type": "responsive",
"design_philosophy": "Responsive 3-column holy grail layout with fixed header and footer",
"dom_structure": {