chore: establish learning module baseline

This commit is contained in:
inman committed 2026-08-16 14:58:47 +08:00
commit 2d04197f3f
2409 files changed
+533050

No files matched your search

@@ -0,0 +1,27 @@
### ImageElement
```json
{
"id": "image_001",
"type": "image",
"left": 100,
"top": 150,
"width": 400,
"height": 300,
"src": "img_1",
"fixedRatio": true
}
```
**Required Fields**: `id`, `type`, `left`, `top`, `width`, `height`, `src` (source image ID like "img_1"), `fixedRatio` (always true)
**Source Image Sizing Rules (keep original aspect ratio)**:
- `src` must be an image ID from the assigned media list (for example, "img_1"). Do not use URLs or invented IDs
- If no suitable source image exists, do not create image elements; use text and shapes only
- When dimensions are provided (for example, "img_1: 884x424, ratio 2.08"):
- Choose a width based on layout needs, typically 300-500px
- Calculate `height = width / aspect_ratio`
- Example: ratio 2.08, width 400 -> height = 400 / 2.08 ~= 192
- When dimensions are not provided, use 4:3 default (width:height ~= 1.33)
- Ensure the image stays within canvas margins (50px from each edge)