Compare commits

...

2 commits

Author SHA1 Message Date
Rowan 0246e80f93 make elements public 2024-04-08 18:30:53 -04:00
Rowan cfe11d3777 make some attributes match css names better 2024-04-08 18:30:53 -04:00
2 changed files with 3 additions and 3 deletions

View file

@ -3,7 +3,7 @@ mod apply_mutations;
pub mod colors; pub mod colors;
mod deferred_system; mod deferred_system;
mod ecs_hooks; mod ecs_hooks;
mod elements; pub mod elements;
#[macro_use] #[macro_use]
mod events; mod events;
#[cfg(feature = "hot_reload")] #[cfg(feature = "hot_reload")]

View file

@ -196,10 +196,10 @@ pub fn set_attribute(
("text_multiline_alignment", "right") if text.is_some() => { ("text_multiline_alignment", "right") if text.is_some() => {
text.unwrap().justify = JustifyText::Right; text.unwrap().justify = JustifyText::Right;
} }
("text_size", value) if text.is_some() => { ("font_size", value) if text.is_some() => {
text.unwrap().sections[0].style.font_size = parse_f32(value); text.unwrap().sections[0].style.font_size = parse_f32(value);
} }
("text_color", value) if text.is_some() => { ("color", value) if text.is_some() => {
text.unwrap().sections[0].style.color = parse_color(value); text.unwrap().sections[0].style.color = parse_color(value);
} }
("image_asset_path", value) if image.is_some() => { ("image_asset_path", value) if image.is_some() => {