Skip to content

Commit

Permalink
feat(blazorui): BitTextField improvements #9092 (#9101)
Browse files Browse the repository at this point in the history
  • Loading branch information
msynk authored Nov 4, 2024
1 parent 21cd61e commit 945057f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/BlazorUI/Bit.BlazorUI/Components/Inputs/BitInputBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ protected BitInputBase()
/// <summary>
/// Gets or sets a collection of additional attributes that will be applied to the created element.
/// </summary>
[Parameter] public IReadOnlyDictionary<string, object>? InputHtmlAttributes { get; set; }
[Parameter] public Dictionary<string, object>? InputHtmlAttributes { get; set; }

/// <summary>
/// Gets or sets the name of the element.
Expand Down Expand Up @@ -152,7 +152,7 @@ public override Task SetParametersAsync(ParameterView parameters)
break;

case nameof(InputHtmlAttributes):
InputHtmlAttributes = (IReadOnlyDictionary<string, object>?)parameter.Value;
InputHtmlAttributes = (Dictionary<string, object>?)parameter.Value;
parametersDictionary.Remove(parameter.Key);
break;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
name="@Name"
id="@_inputId"
rows="@(Rows ?? 3)"
tabindex="@TabIndex"
readonly="@ReadOnly"
required="@Required"
style="@Styles?.Input"
Expand Down Expand Up @@ -81,6 +82,7 @@
type="@_inputType"
readonly="@ReadOnly"
required="@Required"
tabindex="@TabIndex"
style="@Styles?.Input"
autofocus="@AutoFocus"
maxlength="@MaxLength"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,11 @@ public partial class BitTextField : BitTextInputBase<string?>
/// </summary>
[Parameter] public RenderFragment? SuffixTemplate { get; set; }

/// <summary>
/// The value of the tabindex html attribute of the input element.
/// </summary>
[Parameter] public string? TabIndex { get; set; }

/// <summary>
/// Specifies whether to remove any leading or trailing whitespace from the value.
/// </summary>
Expand Down

0 comments on commit 945057f

Please sign in to comment.