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

Kendo UI Dialog TagHelper DialogTagHelper class.

Definition

Namespace:Kendo.Mvc.TagHelpers

Assembly:Kendo.Mvc.dll

Syntax:

C#
[HtmlTargetElement("kendo-dialog")]
[HtmlTargetElement("editable-window", ParentTag = "editable")]
[RestrictChildren("actions", new string[] { "content", "popup-animation", "dialog-title", "modal", "kendo-dialog-messages-settings" })]
[OutputElementHint("div")]
public class DialogTagHelper : TagHelperBase, ITagHelper, ITagHelperComponent

Inheritance: objectTagHelperTagHelperBaseDialogTagHelper

Implements: ITagHelperITagHelperComponent

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-dialog name="dialog">
    <content>Dialog content</content>
</kendo-dialog>

Constructors

Initializes a new instance of the DialogTagHelper class.

C#
public DialogTagHelper(IKendoHtmlGenerator generator)
Parameters:generatorIKendoHtmlGenerator

Properties

Specifies the possible layout of the action buttons in the Dialog.Note: Stretched layout has no effect in browsers, like IE9, that do not support flexbox.Possible values are: normal or stretched.

C#
public string ButtonLayout { get; set; }

Specifies whether a close button should be rendered at the top corner of the dialog.

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

The content of the dialog

C#
public string Content { get; set; }

Specifies height of the dialog.

C#
public string Height { get; set; }

The maximum height (in pixels) that may be achieved by resizing the dialog.

C#
public string MaxHeight { get; set; }

The maximum width (in pixels) that may be achieved by resizing the dialog.

C#
public string MaxWidth { get; set; }

The minimum height (in pixels) that may be achieved by resizing the dialog.

C#
public string MinHeight { get; set; }

The minimum width (in pixels) that may be achieved by resizing the dialog.

C#
public string MinWidth { get; set; }

Specifies whether the dialog should show a modal overlay over the page.

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

The name of the JavaScript function that will handle the close event. Triggered when a Dialog is closed (by a user or through the close() method).

C#
public string OnClose { get; set; }

The name of the JavaScript function that will handle the hide event. Triggered when a Dialog has finished its closing animation.

C#
public string OnHide { get; set; }

The name of the JavaScript function that will handle the initOpen event. Triggered when a Dialog is opened for the first time (i.e. the open() method is called).

C#
public string OnInitOpen { get; set; }

The name of the JavaScript function that will handle the kendoKeydown event. Triggered when the user presses a keyboard key while the Dialog 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 open event. Triggered when a Dialog is opened (i.e. the open() method is called).

C#
public string OnOpen { get; set; }

The name of the JavaScript function that will handle the show event. Triggered when a Dialog has finished its opening animation.

C#
public string OnShow { get; set; }

Set predefined size to the dialog. The width and height configuration options override the predefined size.Possible values are: auto; small; medium or large.

C#
public string Size { get; set; }

The text in the dialog title bar. If false, the dialog will be displayed without a title bar.

C#
public string Title { get; set; }

Specifies whether the dialog will be initially visible.

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

Specifies width of the dialog.

C#
public string Width { 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()

Writes the HTML output.

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

The TagHelper output.

Overrides: TagHelperBase.WriteHtml(TagHelperOutput)