Kendo UI SegmentedControl TagHelper
Definition
Namespace:Kendo.Mvc.TagHelpers
Assembly:Kendo.Mvc.dll
Syntax:
[HtmlTargetElement("kendo-segmentedcontrol")]
[RestrictChildren("items", new string[] { })]
public class SegmentedControlTagHelper : TagHelperBase, ITagHelper, ITagHelperComponent
Inheritance: objectTagHelperTagHelperBaseSegmentedControlTagHelper
Implements:
Inherited Members
Example:
@addTagHelper *, Kendo.Mvc
<kendo-segmentedcontrol name="segmentedcontrol">
<items>
<item text="Option 1" value="1"></item>
<item text="Option 2" value="2"></item>
<item text="Option 3" value="3"></item>
</items>
</kendo-segmentedcontrol>
Child Tags
Constructors
Initializes a new instance of the SegmentedControlTagHelper class.
public SegmentedControlTagHelper(IKendoHtmlGenerator generator)
Properties
Configures whether the SegmentedControl will be enabled or disabled.
public bool? Enabled { get; set; }
Sets a value that will shape the layout mode of the SegmentedControl.
public SegmentedButtonLayoutMode? LayoutMode { get; set; }
The name of the JavaScript function that will handle the change event. Fires when the user changes a button selection in the SegmentedControl.The event handler function context (available via the this keyword) will be set to the widget instance.
public string OnChange { get; set; }
The selected value of the component. Must match the value of one of the items.
public string SelectedValue { get; set; }
Sets the size of the component.
public ComponentSize? Size { get; set; }
Methods
Gets the generated initialization script.
public override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
Overrides:
Serializes the defined settings.
public override IDictionary<string, object> Serialize()
Overrides:
SerializeEvents method.
protected override Dictionary<string, object> SerializeEvents()
Overrides:
SerializeSettings method.
protected override Dictionary<string, object> SerializeSettings()
Overrides:
Writes content to the output.
protected override void WriteHtml(TagHelperOutput output)
Overrides: