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

Kendo UI Slider TagHelper SliderTagHelper class.

Definition

Namespace:Kendo.Mvc.TagHelpers

Assembly:Kendo.Mvc.dll

Syntax:

C#
[HtmlTargetElement("kendo-slider")]
[HtmlTargetElement("slider-editor", ParentTag = "form-item")]
[HtmlTargetElement("slider-editor", ParentTag = "property-grid-item")]
[RestrictChildren("slider-tooltip", new string[] { })]
[OutputElementHint("div")]
public class SliderTagHelper : TagHelperBase, ITagHelper, ITagHelperComponent, IKendoFormEditor

Inheritance: objectTagHelperTagHelperBaseSliderTagHelper

Implements: IKendoFormEditorITagHelperITagHelperComponent

Inherited Members TagHelperBase.MinimumValidatorTagHelperBase.MaximumValidatorTagHelperBase.Init(TagHelperContext)TagHelperBase.Process(TagHelperContext, TagHelperOutput)TagHelperBase.GetInitializator()TagHelperBase.VerifySettings()TagHelperBase.SerializeTemplates()TagHelperBase.GenerateId(TagHelperOutput)TagHelperBase.CreateHandler(string)TagHelperBase.GetRangeValidationParameter<TValue>(ModelExplorer, string)TagHelperBase.ExtractEditFormat(string)TagHelperBase.ToDictionaryHandler(IDictionary<string, string>)TagHelperBase.AddSelfToTemplate(TagHelperContext)TagHelperBase.ViewContextTagHelperBase.GeneratorTagHelperBase.InitializerTagHelperBase.WriterTagHelperBase.ScriptAttributesTagHelperBase.NameTagHelperBase.IdTagHelperBase.SelectorTagHelperBase.IdPrefixTagHelperBase.IsInClientTemplateTagHelperBase.DeferredTagHelperBase.AsModuleTagHelper.Orderobject.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Example:

csharp
@addTagHelper *, Kendo.Mvc

<kendo-slider name="slider" min="0" max="100" small-step="1" value="20"></kendo-slider>

Child Tagsslider-tooltip

Constructors

Initializes a new instance of the SliderTagHelper class.

C#
public SliderTagHelper(IKendoHtmlGenerator generator)
Parameters:generatorIKendoHtmlGenerator

Properties

The title of the decrease button of the Slider.

C#
public string DecreaseButtonTitle { get; set; }

The title of the drag handle of the Slider.

C#
public string DragHandleTitle { get; set; }

An expression to be evaluated against the current model.

C#
public ModelExpression For { get; set; }

The title of the increase button of the Slider.

C#
public string IncreaseButtonTitle { get; set; }

IsNested member.

C#
[HtmlAttributeNotBound]
public bool IsNested { get; set; }

Implements: IKendoFormEditor.IsNested

The delta with which the value will change when the user presses the Page Up or Page Down key (the drag handle must be focused). Note: largeStep will also set a large tick for every large step.Must be a positive number, larger than smallStep.

C#
public double? LargeStep { get; set; }

The maximum value of the Slider.

C#
public double? Max { get; set; }

The minimum value of the Slider.

C#
public double? Min { get; set; }

The name of the JavaScript function that will handle the change event. Fires when the slider value changes as a result of selecting a new value with the drag handle, buttons or keyboard.

C#
public string OnChange { get; set; }

The name of the JavaScript function that will handle the kendoKeydown event. Triggered when the user presses a keyboard key while the Slider is focused.The event handler function context (available via the this keyword) will be set to the widget instance.

C#
public string OnKendoKeydown { get; set; }

The name of the JavaScript function that will handle the slide event. Fires when the user drags the drag handle to a new position.

C#
public string OnSlide { get; set; }

The orientation of a Slider

C#
public SliderOrientation? Orientation { get; set; }

Can be used to show (true) or hide (false) the increase and decrease buttons of a Slider.

C#
public bool? ShowButtons { get; set; }

The small step value of the Slider. Must be a positive number, otherwise an Javascript exception will be thrown.The small step value determines the amount of Slider value change when the end user clicks on the increase or decrease buttons of the Slider;; presses the arrow keys (the drag handle must be focused); or drags the drag handle..

C#
public double? SmallStep { get; set; }

Denotes the location of the tick marks in the Slider

C#
public SliderTickPlacement? TickPlacement { get; set; }

The underlying value of the Slider.

C#
public double? Value { get; set; }

Methods

Gets the initialization script.

C#
protected override string GetInitializationScript()
Returns:

string

The initialization script.

Overrides: TagHelperBase.GetInitializationScript()

C#
public override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
Parameters:contextTagHelperContextoutputTagHelperOutputReturns:

Task

Overrides: TagHelper.ProcessAsync(TagHelperContext, TagHelperOutput)

Serializes the defined settings.

C#
public override IDictionary<string, object> Serialize()
Returns:

IDictionary<string, object>

Overrides: TagHelperBase.Serialize()

SerializeEvents method.

C#
protected override Dictionary<string, object> SerializeEvents()
Returns:

Dictionary<string, object>

Overrides: TagHelperBase.SerializeEvents()

SerializeSettings method.

C#
protected override Dictionary<string, object> SerializeSettings()
Returns:

Dictionary<string, object>

Overrides: TagHelperBase.SerializeSettings()

TryAddAsEditor method.

C#
public bool TryAddAsEditor(TagHelperContext context)
Parameters:contextTagHelperContextReturns:

bool

The result.

Implements: IKendoFormEditor.TryAddAsEditor(TagHelperContext)

Writes the HTML output.

C#
protected override void WriteHtml(TagHelperOutput output)
Parameters:outputTagHelperOutput

The TagHelper output.

Overrides: TagHelperBase.WriteHtml(TagHelperOutput)