2using System.ComponentModel;
3using Microsoft.Maui.Controls;
7 [ContentProperty(nameof(Content))]
10 public static readonly BindableProperty StateKeyProperty = BindableProperty.Create(
15 defaultValueCreator:
_ =>
string.Empty);
17 public static readonly BindableProperty ViewTypeProperty = BindableProperty.Create(
23 public static readonly BindableProperty ViewModelTypeProperty = BindableProperty.Create(
24 nameof(ViewModelType),
29 public string StateKey
31 get => (string)this.GetValue(StateKeyProperty);
32 set => this.SetValue(StateKeyProperty, value);
35 public new View? Content
38 set => base.Content = value;
41 [TypeConverter(typeof(TypeTypeConverter))]
44 get => (Type?)this.GetValue(ViewTypeProperty);
45 set => this.SetValue(ViewTypeProperty, value);
48 [TypeConverter(typeof(TypeTypeConverter))]
49 public Type? ViewModelType
51 get => (Type?)this.GetValue(ViewModelTypeProperty);
52 set => this.SetValue(ViewModelTypeProperty, value);