Open davidortinau opened 4 years ago
Agree with @DavidKarlas , can't wait to Contribute.
I was checking the source code today, in Microsoft.MobileBlazorBindings/Elements the source of all control wrappers are available.
For eg, button element:
public class Button : View
{
static Button()
{
ElementHandlerRegistry
.RegisterElementHandler<Button>(renderer => new ButtonHandler(renderer, new XF.Button()));
}
// ... rest of the code
// new property added, Font property is the same as XamarinFormsButton Font property
// https://docs.microsoft.com/en-us/dotnet/api/xamarin.forms.button.font?view=xamarin-forms
[Parameter] public XF.Font? Font {get;set;}
// rest of the code
And apply it with RenderAttribute method:
protected override void RenderAttributes(AttributesBuilder builder)
{
base.RenderAttributes(builder);
// ... rest of the code
if(Font != null)
{
builder.AddAttribute(nameof(Font), Font);
}
// ... rest of the code
}
Agree with all, I cannot wait to contribute.
I'd like a guide for how to add properties to existing controls, such as
Button
which is currently missing font size and borders, and new controls such asBoxView
.That in addition to a backlog of known work items would be great to enlist help.