Browse Source

Fix BetterContentDialog title hiding when empty

pull/55/head
Ionite 1 year ago
parent
commit
d4460cc397
No known key found for this signature in database
  1. 2
      StabilityMatrix.Avalonia/Controls/BetterContentDialog.cs

2
StabilityMatrix.Avalonia/Controls/BetterContentDialog.cs

@ -138,7 +138,7 @@ public class BetterContentDialog : ContentDialog
if (subGrid is null) throw new InvalidOperationException("Could not find sub grid"); if (subGrid is null) throw new InvalidOperationException("Could not find sub grid");
var contentControlTitle = subGrid.Children[0] as ContentControl; var contentControlTitle = subGrid.Children[0] as ContentControl;
// Hide title if empty // Hide title if empty
if (Title is null) if (Title is null or string {Length: 0})
{ {
contentControlTitle!.IsVisible = false; contentControlTitle!.IsVisible = false;
} }

Loading…
Cancel
Save