Class
TelerikInputBase<T>

Definition

Namespace:Telerik.Blazor.Components.Common

Assembly:Telerik.Blazor.dll

Type Parameters:

T

Syntax:

cs-api-definition
public class TelerikInputBase<T> : BaseComponent, IComponent, IHandleEvent, IHandleAfterRender, IDisposable

Inheritance: objectComponentBaseBaseComponentTelerikInputBase<T>

Derived Classes: ColorEditorBaseTelerikPickerBase<T>TextBoxBaseTelerikCheckBox<TValue>TelerikColorPaletteTelerikDateInput<T>TelerikEditorTelerikNumericTextBox<T>TelerikSwitch<TValue>

Implements: IComponentIDisposableIHandleAfterRenderIHandleEvent

Inherited Members BaseComponent.ShouldRender()BaseComponent.OnAfterRenderAsync(bool)BaseComponent.InitLocalizer()BaseComponent.ThrowIfParameterIsNull(object, string)BaseComponent.HaveOptionsChanged(IDictionary<string, object>, IDictionary<string, object>)BaseComponent.GetClassString(params string[])BaseComponent.InvokeAsync<T>(string, params object[])BaseComponent.InvokeAsync<T>(string, CancellationToken, params object[])BaseComponent.InvokeVoidAsync(string, params object[])BaseComponent.InvokeComponentMethodAsync<T>(string, params object[])BaseComponent.InvokeComponentMethodAsync<T>(string, CancellationToken, params object[])BaseComponent.InvokeVoidComponentMethodAsync(string, params object[])BaseComponent.InvokeComponentVoidMethodAsync(string, object)BaseComponent.InvokeDisposeAsync()BaseComponent.StateHasChanged()BaseComponent.RootComponentBaseComponent.ClassComponentBase.BuildRenderTree(RenderTreeBuilder)ComponentBase.OnInitialized()ComponentBase.OnParametersSet()ComponentBase.OnAfterRender(bool)ComponentBase.InvokeAsync(Action)ComponentBase.InvokeAsync(Func<Task>)ComponentBase.DispatchExceptionAsync(Exception)

Constructors

TelerikInputBase()

Declaration

cs-api-definition
public TelerikInputBase()

Properties

AriaDescribedBy

References elements that provide additional description or context for the component. Use to associate help text, validation messages, or instructions with the component. Example: "content-help validation-message" to reference multiple descriptive elements. Improves accessibility by providing screen readers with additional context beyond the label.

Declaration

cs-api-definition
[Parameter]
public string AriaDescribedBy { get; set; }

Property Value

string

AriaLabel

Sets the accessible label for screen readers and assistive technologies when a visible label is not present. Use descriptive text like "Article content editor" or "Comment editor" to help users understand the component's purpose. Essential for accessibility compliance and helping users with disabilities navigate your application. Alternative to using a connected label element with AriaLabelledBy.

Declaration

cs-api-definition
[Parameter]
public string AriaLabel { get; set; }

Property Value

string

AriaLabelledBy

References the ID of an element that serves as the accessible label for the component. Use when you have a visible label element that should be associated with this component. Example: "content-label" where an element with id="content-label" contains the label text. Provides better accessibility than AriaLabel when visible labels are present.

Declaration

cs-api-definition
[Parameter]
public string AriaLabelledBy { get; set; }

Property Value

string

CascadedEditContext

Declaration

cs-api-definition
[CascadingParameter]
public EditContext CascadedEditContext { get; set; }

Property Value

EditContext

Enabled

Controls whether the component accepts user interaction and responds to input events. When set to false, disables all user interactions including typing, clicking tools, and keyboard navigation. Use to temporarily disable editing while maintaining visual state or during data loading operations. Default value is true.

Declaration

cs-api-definition
[Parameter]
public bool Enabled { get; set; }

Property Value

bool

FloatingLabel

Declaration

cs-api-definition
[CascadingParameter]
public TelerikFloatingLabel FloatingLabel { get; set; }

Property Value

TelerikFloatingLabel

Id

Sets the unique identifier for the component which can be used for CSS targeting and accessibility. Use meaningful IDs that describe the component's purpose like "article-content-editor" or "comment-editor". Required for proper form association and accessibility when using with labels or validation. Should be unique within the page to avoid conflicts with other elements.

Declaration

cs-api-definition
[Parameter]
public string Id { get; set; }

Property Value

string

InputMode

Sets the input mode hint for mobile keyboards to optimize the virtual keyboard layout. Use "text" for general content, "none" to suppress virtual keyboard, or other values for specific input types. Helps mobile users by showing appropriate keyboard layouts for the expected content type. See MDN inputmode documentation for available values.

Declaration

cs-api-definition
[Parameter]
public string InputMode { get; set; }

Property Value

string

OnBlur

Fires when the component loses focus after user interaction ends. Use for triggering validation, saving draft content, or updating UI state. Important for accessibility and form workflows where focus changes indicate interaction completion. Combine with OnChange for complete interaction tracking.

Declaration

cs-api-definition
[Parameter]
public virtual EventCallback OnBlur { get; set; }

Property Value

EventCallback

OnChange

Fires when the user confirms their input by pressing Enter or when the component loses focus. Use for validation, data persistence, or triggering business logic after user completes editing. Different from ValueChanged which fires during active editing. Provides the committed value for final processing or server updates.

Declaration

cs-api-definition
[Parameter]
public virtual EventCallback<object> OnChange { get; set; }

Property Value

EventCallback<object>

TabIndex

Controls the tab order of the component within the page for keyboard navigation accessibility. Set to positive values (1, 2, 3...) to specify custom tab order, 0 for natural document order. Set to -1 to remove from tab order completely when Enabled is false. Use consecutive numbers without gaps for predictable navigation experience. Essential for keyboard accessibility and screen reader users.

Declaration

cs-api-definition
[Parameter]
public int? TabIndex { get; set; }

Property Value

int?

ValidateOn

Controls when form validation is triggered for the component within EditForm context. Input validates during typing for immediate feedback. Change validates on focus loss or Enter key for less intrusive experience. Choose based on content type: Input for critical fields, Change for longer content editing.

Declaration

cs-api-definition
[Parameter]
public ValidationEvent ValidateOn { get; set; }

Property Value

ValidationEvent

Value

Gets or sets the current value of the component for two-way data binding. For Editor, this contains the HTML content as a string with all formatting and markup. Use with @bind-Value for automatic two-way binding or set directly for programmatic control. Value changes trigger ValueChanged and validation when in EditForm context.

Declaration

cs-api-definition
[Parameter]
public virtual T Value { get; set; }

Property Value

T

ValueChanged

Callback that fires immediately when the component value changes during user interaction. Use for real-time data binding, validation, or triggering dependent component updates. Called automatically when using two-way binding syntax like @bind-Value="model.Content". Provides the new value for updating your data model or performing additional processing.

Declaration

cs-api-definition
[Parameter]
public EventCallback<T> ValueChanged { get; set; }

Property Value

EventCallback<T>

ValueExpression

Defines the expression that identifies the bound property for two-way data binding and validation. Required when using the component within EditForm for proper validation and change tracking. Automatically provided when using bind-Value syntax like @bind-Value="model.Content". Enables proper form validation, field identification, and integration with validation frameworks.

Declaration

cs-api-definition
[Parameter]
public Expression<Func<T>> ValueExpression { get; set; }

Property Value

Expression<Func<T>>

Methods

Dispose()

Declaration

cs-api-definition
public override void Dispose()

Overrides BaseComponent.Dispose()

Implements IDisposable.Dispose()

FocusAsync()

Moves focus to the component.

Declaration

cs-api-definition
public virtual Task FocusAsync()

Returns

Task

OnInitializedAsync()

Declaration

cs-api-definition
protected override Task OnInitializedAsync()

Returns

Task

Overrides BaseComponent.OnInitializedAsync()

OnParametersSetAsync()

Declaration

cs-api-definition
protected override Task OnParametersSetAsync()

Returns

Task

Overrides ComponentBase.OnParametersSetAsync()

SetParametersAsync(ParameterView)

Declaration

cs-api-definition
public override Task SetParametersAsync(ParameterView parameters)

Parameters

parameters

ParameterView

Returns

Task

Overrides ComponentBase.SetParametersAsync(ParameterView)