Preserve title data and focus across updates

This commit is contained in:
justinzeus 2026-11-05 17:13:53 +01:00
parent 0c94e8f910
commit 6d7df0fb19
31 changed files with 747 additions and 147 deletions

View file

@ -86,6 +86,8 @@ def render_tokens(tokens: dict) -> tuple[str, str]:
elif isinstance(token.get("dp"), dict):
for suffix, dimension in token["dp"].items():
lines.append(f" val {name}{suffix[0].upper() + suffix[1:]} = {number(dimension)}.dp")
if kind == "card":
lines.append(f" const val {name}Slots = {token['fullSlotsPerRow']}")
elif group_name == "image" and isinstance(token.get("px"), list):
for suffix, dimension in zip(("Width", "Height"), token["px"]):
lines.append(f" const val {name}{suffix} = {int(dimension)}")