From f6a3fb9c4d8dd86f78c9f75a23c1ac35bf35d4eb Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Thu, 19 Mar 2026 07:45:14 +0100 Subject: feat(treewide): Commit MVP --- rocie-macros/src/form/parse.rs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'rocie-macros/src/form/parse.rs') diff --git a/rocie-macros/src/form/parse.rs b/rocie-macros/src/form/parse.rs index 59a82c1..2cf8799 100644 --- a/rocie-macros/src/form/parse.rs +++ b/rocie-macros/src/form/parse.rs @@ -86,6 +86,15 @@ impl Parse for ParsedChild { auto_complete, } } + variant if variant == format_ident!("Textarea") => { + let name = parse_key_value!(input, name as Ident); + let label = parse_key_value!(input, label as LitStr); + + input.parse::()?; + input.parse::]>()?; + + ParsedChild::Textarea { name, label } + } variant if variant == format_ident!("Select") => { let name = parse_key_value!(input, name as Ident); let rust_type = parse_key_value!(input, rust_type as Type); @@ -130,6 +139,15 @@ impl Parse for ParsedChild { ParsedChild::Show { when, children } } + variant if variant == format_ident!("Checkbox") => { + let name = parse_key_value!(input, name as Ident); + let label = parse_key_value!(input, label as LitStr); + + input.parse::()?; + input.parse::]>()?; + + ParsedChild::Checkbox { name, label } + } _ => panic!("Unknown form child variant: {variant}"), }; -- cgit 1.4.1