JT
1 year ago
2 changed files with 26 additions and 8 deletions
@ -0,0 +1,23 @@
|
||||
using Avalonia.Controls; |
||||
using Avalonia.Controls.Primitives; |
||||
using Avalonia.Styling; |
||||
|
||||
namespace StabilityMatrix.Avalonia.Controls; |
||||
|
||||
public class Card : Expander |
||||
{ |
||||
public Card() |
||||
{ |
||||
// Expander /template/ ToggleButton#PART_toggle |
||||
var customStyle = new Style(x => |
||||
x.OfType<Expander>().Template().OfType<ToggleButton>().Name("PART_toggle")); |
||||
|
||||
customStyle.Setters.Add(new Setter |
||||
{ |
||||
Property = IsVisibleProperty, |
||||
Value = false |
||||
}); |
||||
|
||||
Styles.Add(customStyle); |
||||
} |
||||
} |
Loading…
Reference in new issue