Appearance
In this article, you will find information about the styling options and rendering of the Telerik UI for ASP.NET Core NumericTextBox.
For a live example, visit the Appearance Demo of the NumericTextBox.
Options
The NumericTextBox HtmlHelper supports the following styling options:
Size()—configures the overall size of the component.FillMode()—configures how the color is applied to the component.Rounded()—configures the border radius of the component.
Size
The Size() method allows you to adjust the size of the NumericTextBox.
@(Html.Kendo().NumericTextBox()
.Name("numeric")
.Size(ComponentSize.Medium)
)The option is applied to the wrapping span element through the k-input-md class.
<span class="k-numerictextbox k-input k-input-md">
</span>
The following values are available for the Size option:
SmallMediumLarge
When not explicitly set, the applied theme controls the default size.
The
Nonevalue is deprecated. Use custom CSS instead.
Rounded
You can control how much border radius is applied to the component by using the Rounded() method.
@(Html.Kendo().NumericTextBox()
.Name("numeric")
.Rounded(Rounded.Medium)
)The option is applied to the wrapping span element through the k-rounded-md class.
<span class="k-numerictextbox k-input k-rounded-md">
The Rounded option supports the following values:
SmallMediumLargeFull
When not explicitly set, the applied theme controls the default border radius.
The
Nonevalue is deprecated. Use custom CSS instead.
FillMode
The FillMode option controls the way the color is applied to the NumericTextBox.
@(Html.Kendo().NumericTextBox()
.Name("numeric")
.FillMode(FillMode.Solid)
)The option is applied to the wrapping span element through the k-input-solid class.
<span class="k-numerictextbox k-input k-input-solid">
The following values are available for the FillMode option:
SolidFlatOutline
When not explicitly set, the applied theme controls the default fill mode.
The
Nonevalue is deprecated. Use custom CSS instead.
Rendering
Starting with version R1 2022, the component has a new rendering. For additional information on the decision behind these changes, visit the Components Rendering Overview article.
To review the latest rendering of the component, refer to the HTML specifications in the Kendo UI Themes Monorepo. The tests folder of the repository contains the rendering for all flavors of the components, providing a clear reference for how their elements are structured. The rendering information can help you customize a component's appearance and behavior by applying custom CSS or JavaScript to suit specific design or functional requirements.