namespace ShoopNCook.Views; public partial class IngredientView : ContentView { private readonly BindableProperty NameProperty = BindableProperty.Create(nameof(Name), typeof(string), typeof(IngredientView), default(string)); private readonly BindableProperty QuantityProperty = BindableProperty.Create(nameof(Quantity), typeof(float), typeof(IngredientView), default(float)); private readonly BindableProperty UnitProperty = BindableProperty.Create(nameof(Unit), typeof(string), typeof(IngredientView), default(string)); public string Name { get => (string)GetValue(NameProperty); set => SetValue(NameProperty, value); } public float Quantity { get => (float)GetValue(QuantityProperty); set => SetValue(QuantityProperty, value); } public string Unit { get => (string)GetValue(UnitProperty); set => SetValue(UnitProperty, value); } public IngredientView(string name, float quantity, string unit) { InitializeComponent(); Name = name; Quantity = quantity; Unit = unit; } }