Tuto Site
Estilo de texto
StyleTextContent référencé par style_title / style_subtitle (string uuid, pas ViewDataString). Live : s_text_content.dart. Ne pas mettre fontSize dans le view JSON (n’existe pas).
Champs JSON
| Clé | Type | Rôle |
|---|---|---|
font | string | nom (ex. "Libre Baskerville") |
size_d size_m | double | px desktop / mobile. size_m==0 → fallback d |
height_d height_m | double | line height. 0 = default Flutter |
weight | int 0–8 | w100…w900. 3 = w400, 6 = w700 |
style | 0|1 | 0 normal · 1 italic |
align | int | 0 left · 1 right · 2 center · 3 justify · 4 start · 5 end |
uuid_theme | ViewDataString | couleur (primaryText vs onSurface) |
{
"uuid": "baf5fe27-59ea-46b7-b3eb-099f34874518",
"uuid_theme": { "l": { "i": "019ab229-6c63-710c-b417-1cb3fae2b153" } },
"name": "DOCU TITLE Main",
"font": "Libre Baskerville",
"font_web": "",
"asset": 1,
"size_d": 14,
"size_m": 14,
"height_d": 0,
"height_m": 0,
"weight": 3,
"style": 0,
"align": 0,
"ratio": 2
}
View :
"style_title": "baf5fe27-59ea-46b7-b3eb-099f34874518"
Défaut titleStyle : bodyLarge + colorScheme.primary (18 desktop). subtitleStyle : bodyMedium + onSurface (15 desktop).
Piège. Cet
align n’aligne pas wrap_text (axis_align du folder le fait). Ne pas « corriger » un wrap_text centré en changeant le style texte. Consommateurs de s_text_content.align : id_text_animated, titres agenda.