From 402fb2a572e2494ed2b1fd519608b087b90e1d2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20B=C5=82a=C5=BCejewicz=20=28Peter=20Blazejewicz=29?= Date: Wed, 30 Oct 2019 20:39:16 +0100 Subject: [PATCH 1/2] Allow to specify type on MatIconButton. Fixes #315 - Material icon button changes - set type in Material autocomplete Thanks! --- .../MatAutocompleteList/MatAutocompleteList.razor | 2 +- .../Components/MatIconButton/BaseMatIconButton.cs | 7 +++++++ src/MatBlazor/Components/MatIconButton/MatIconButton.razor | 2 +- src/MatBlazor/MatBlazor.xml | 6 ++++++ 4 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/MatBlazor/Components/MatAutocompleteList/MatAutocompleteList.razor b/src/MatBlazor/Components/MatAutocompleteList/MatAutocompleteList.razor index eeacf4be..68884799 100644 --- a/src/MatBlazor/Components/MatAutocompleteList/MatAutocompleteList.razor +++ b/src/MatBlazor/Components/MatAutocompleteList/MatAutocompleteList.razor @@ -9,7 +9,7 @@ @if (IsShowingClearButton) {
- +
} @if (Items != null && IsOpened) diff --git a/src/MatBlazor/Components/MatIconButton/BaseMatIconButton.cs b/src/MatBlazor/Components/MatIconButton/BaseMatIconButton.cs index 54b4a4ff..c609996e 100644 --- a/src/MatBlazor/Components/MatIconButton/BaseMatIconButton.cs +++ b/src/MatBlazor/Components/MatIconButton/BaseMatIconButton.cs @@ -48,6 +48,13 @@ public bool Toggled [Parameter] public EventCallback ToggledChanged { get; set; } + /// + /// The default behavior of the button. Possible values are: + /// "button", "reset", "submit" + /// + [Parameter] + public string Type { get; set; } + /// /// Navigate to this url when clicked. /// diff --git a/src/MatBlazor/Components/MatIconButton/MatIconButton.razor b/src/MatBlazor/Components/MatIconButton/MatIconButton.razor index 9e926590..5162129c 100644 --- a/src/MatBlazor/Components/MatIconButton/MatIconButton.razor +++ b/src/MatBlazor/Components/MatIconButton/MatIconButton.razor @@ -1,7 +1,7 @@ @namespace MatBlazor @inherits BaseMatIconButton -