1
0
Fork 0
forked from wry/wry

Add animation style toggle

This commit is contained in:
atagen 2026-05-27 22:52:06 +10:00
parent 02222d5189
commit e7f9a5cb09
15 changed files with 238 additions and 20 deletions

View file

@ -270,6 +270,7 @@ pub struct UiDrag {
pub struct Animations {
pub enabled: Option<bool>,
pub duration_ms: Option<u32>,
pub style: Option<String>,
pub curve: Option<AnimationCurveConfig>,
}
@ -678,3 +679,13 @@ fn custom_animation_curve_parses() {
Some(AnimationCurveConfig::CubicBezier([0.25, 0.1, 0.25, 1.0]))
);
}
#[test]
fn animation_style_parses() {
let input = b"
[animations]
style = \"plain\"
";
let config = parse_config(input, &Default::default(), |_| ()).unwrap();
assert_eq!(config.animations.style.as_deref(), Some("plain"));
}