amwx / FluentAvalonia

Control library focused on fluent design and bringing more WinUI controls into Avalonia
MIT License
1.05k stars 97 forks source link

Improve expander animations #521

Closed styris-ame closed 9 months ago

styris-ame commented 9 months ago

Is your feature request related to a problem? Please describe. See the following FluentAvalonia animation:

FAControlsGallery Desktop_PId8vbRKNE

It looks okay, however not as nice as the settings app animation:

ApplicationFrameHost_RVrHmYgHVc

Describe the solution you'd like Updated animations to more closely match the settings app.

amwx commented 9 months ago

It was an intentional decision not to include the animation within SettingsExpander. Because of the way Avalonia implemented the animation of the actual expander control, it doesn't work quite right in all situations with this control (particularly if you want the implicit composition animations to make the rest of the UI move with the expansion/collapse).

You can still enable it yourself with a Selector that targets the Expander in the template of the SettingsExpander to set the ContentTransition property.

styris-ame commented 9 months ago

@amwx Thanks for the reply! If I may ask, is there an Avalonia issue to track this as an issue, or is it inherent to the design?