New to Telerik UI for ASP.NET Core? Start a free 30-day trial

Defines the fluent API for configuring ButtonBadgeSettings

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Syntax:

C#
public class ButtonBadgeSettingsBuilder

Inheritance: objectButtonBadgeSettingsBuilder

Inherited Members object.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Constructors

ButtonBadgeSettingsBuilder method.

C#
public ButtonBadgeSettingsBuilder(ButtonBadgeSettings container)
Parameters:containerButtonBadgeSettings

Properties

Gets the settings being configured.

C#
protected ButtonBadgeSettings Container { get; }

Methods

Specifies alignment of the badge relative to button. Valid position options are: top start, top end, bottom start, bottom end. works in conjunction with badge.position.

C#
public ButtonBadgeSettingsBuilder Align(BadgeAlign value)
Parameters:valueBadgeAlign

The value for Align

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Specifies wether or not to render additional "cutout" border around the badge.

C#
public ButtonBadgeSettingsBuilder CutoutBorder()
Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Specifies wether or not to render additional "cutout" border around the badge.

C#
public ButtonBadgeSettingsBuilder CutoutBorder(bool value)
Parameters:valuebool

The value for CutoutBorder

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Determines whether the textual content should be rendered as an HTML string or it should be encoded.

C#
public ButtonBadgeSettingsBuilder Encoded(bool value)
Parameters:valuebool

The value for Encoded

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Sets a value controlling how the color is applied to the badge. When undefined (the default), the theme controls the fill mode. Can also be set to the following string values: "solid" or "outline".

C#
public ButtonBadgeSettingsBuilder FillMode(BadgeFill value)
Parameters:valueBadgeFill

The value for FillMode

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Defines the name for an existing icon in a Kendo UI theme or SVG content. The icon is rendered inside the badge by a span.k-icon or span.k-svg-icon element.Set this option to an icon descriptor such as { name: "gear", variant: "outline" }. The variant can be outline, solid, or duotone; it applies to SVG rendering and is ignored for font icons.

C#
public ButtonBadgeSettingsBuilder Icon(Action<ButtonBadgeIconSettingsBuilder> configurator)
Parameters:configuratorAction<ButtonBadgeIconSettingsBuilder>

The ButtonBadgeIconSettingsBuilder for the icon setting.

Returns:

ButtonBadgeSettingsBuilder

Returns the current instance of ButtonBadgeSettingsBuilder .

Defines the name for an existing icon in a Kendo UI theme or SVG content. The icon is rendered inside the badge by a span.k-icon or span.k-svg-icon element.Set this option to an icon descriptor such as { name: "gear", variant: "outline" }. The variant can be outline, solid, or duotone; it applies to SVG rendering and is ignored for font icons.

C#
public ButtonBadgeSettingsBuilder Icon(string icon)
Parameters:iconstring

The icon.

Returns:

ButtonBadgeSettingsBuilder

Returns the current instance of ButtonBadgeSettingsBuilder .

If text is a number, it will cap that number.

C#
public ButtonBadgeSettingsBuilder Max(double value)
Parameters:valuedouble

The value for Max

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Specifies position of the badge relative to the edge of the button. Valid placemnt options are: inline, edge, inside, outside.Note: position configuration, other than inline, requires the badge to be aligned. See badge.align for more details.

C#
public ButtonBadgeSettingsBuilder Position(BadgePosition value)
Parameters:valueBadgePosition

The value for Position

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Specifies the rounding of the badge. When undefined (the default), the theme controls the default border radius. Valid options are small, medium, large and full.

C#
public ButtonBadgeSettingsBuilder Rounded(Rounded value)
Parameters:valueRounded

The value for Rounded

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Sets a value controlling the size of the badge. When undefined (the default), the theme controls the size. Can also be set to the following string values: "small"; "medium" or "large".

C#
public ButtonBadgeSettingsBuilder Size(BadgeSize value)
Parameters:valueBadgeSize

The value for Size

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

The template which renders the content of the badge.

C#
public ButtonBadgeSettingsBuilder Template(string value)
Parameters:valuestring

The value for Template

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

The template which renders the content of the badge.

C#
public ButtonBadgeSettingsBuilder Template<TModel>(TemplateBuilder<TModel> template)
Parameters:templateTemplateBuilder<TModel>

A Template component that configures the template.

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

The template which renders the content of the badge.

C#
public ButtonBadgeSettingsBuilder TemplateHandler(string templateHandler)
Parameters:templateHandlerstring

The handler that returs the template for Template

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

The template which renders the content of the badge.

C#
public ButtonBadgeSettingsBuilder TemplateId(string templateId)
Parameters:templateIdstring

The ID of the template element for Template

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

The template which renders the content of the badge.

C#
public ButtonBadgeSettingsBuilder TemplateView(IHtmlContent templateView)
Parameters:templateViewIHtmlContent

The view that contains the template for Template

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

The text of the badge. Valid input includes string, number or object with toString method. Default is empty string.

C#
public ButtonBadgeSettingsBuilder Text(string value)
Parameters:valuestring

The value for Text

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

Specifies the color of the component. Valid options are inherit, default, primary, secondary, tertiary, info, success, warning, error, inverted.

C#
public ButtonBadgeSettingsBuilder ThemeColor(BadgeColor value)
Parameters:valueBadgeColor

The value for ThemeColor

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.

If set to false the badge will not be displayed.

C#
public ButtonBadgeSettingsBuilder Visible(bool value)
Parameters:valuebool

The value for Visible

Returns:

ButtonBadgeSettingsBuilder

Returns the current ButtonBadgeSettingsBuilder instance.