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

Kendo UI AIPromptView TagHelper AIPromptViewTagHelper class.

Definition

Namespace:Kendo.Mvc.TagHelpers

Assembly:Kendo.Mvc.dll

Syntax:

C#
[HtmlTargetElement("aiprompt-view", ParentTag = "aiprompt-views", TagStructure = TagStructure.NormalOrSelfClosing)]
[RestrictChildren("prompt-commands", new string[] { "button-icon" })]
[SuppressTagRendering]
public class AIPromptViewTagHelper : TagHelperCollectionItemBase, ITagHelper, ITagHelperComponent

Inheritance: objectTagHelperTagHelperChildBaseTagHelperCollectionItemBaseAIPromptViewTagHelper

Implements: ITagHelperITagHelperComponent

Inherited Members TagHelperChildBase.Init(TagHelperContext)TagHelperChildBase.AddSelfToContext(TagHelperContext)TagHelperChildBase.CreateHandler(string)TagHelperChildBase.IdPrefixTagHelper.Process(TagHelperContext, TagHelperOutput)TagHelper.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-aiprompt name="aiprompt">
    <aiprompt-views>
        <aiprompt-view type="ViewType.Prompt" name="view1" button-icon="gear"></aiprompt-view>
    </aiprompt-views>
</kendo-aiprompt>

Constructors

Initializes a new instance of the AIPromptViewTagHelper class.

C#
public AIPromptViewTagHelper()

Properties

The icon name of the Toolbar button rendered for the view.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#
[HtmlAttributeName("button-icon")]
public string ButtonIcon { get; set; }

The text of the Toolbar button rendered for the view.

C#
public string ButtonText { get; set; }

The template of the view footer. It can be a string, a function or a Kendo Template.

C#
public string FooterTemplate { get; set; }

The template of the view footer. It can be a string, a function or a Kendo Template. This option expects the name of a JavaScript function that will be called to return the template.

C#
public string FooterTemplateHandler { get; set; }

The template of the view footer. It can be a string, a function or a Kendo Template. This option expects the ID of the script element that contains the template.

C#
public string FooterTemplateId { get; set; }

The template of the view footer. It can be a string, a function or a Kendo Template. This option expects the IHtmlContent instance containing the created HTML.

C#
public IHtmlContent FooterTemplateView { get; set; }

A function that is executed when the view is rendered. It is used to initialize the components of the view with a custom content template.

C#
public string InitializeComponents { get; set; }

The name of the view. It is used to identify the view. It should be unique.

C#
public string Name { get; set; }

An array of prompt suggestions as strings to display in the prompt view. The suggestions can be clicked to populate the prompt input.

C#
public ICollection<string> PromptSuggestions { get; set; }

Defines the type of the view.

C#
public ViewType? Type { get; set; }

The template of the view content. It can be a string, a function or a Kendo Template.

C#
public string ViewTemplate { get; set; }

The template of the view content. It can be a string, a function or a Kendo Template. This option expects the name of a JavaScript function that will be called to return the template.

C#
public string ViewTemplateHandler { get; set; }

The template of the view content. It can be a string, a function or a Kendo Template. This option expects the ID of the script element that contains the template.

C#
public string ViewTemplateId { get; set; }

The template of the view content. It can be a string, a function or a Kendo Template. This option expects the IHtmlContent instance containing the created HTML.

C#
public IHtmlContent ViewTemplateView { get; set; }

Methods

Adds the current TagHelper instance to its parent TagHelper.

C#
protected override void AddSelfToParent(TagHelperContext context)
Parameters:contextTagHelperContext

The TagHelper context.

Overrides: TagHelperChildBase.AddSelfToParent(TagHelperContext)

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

Task

Overrides: TagHelperChildBase.ProcessAsync(TagHelperContext, TagHelperOutput)

Serializes the defined settings.

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

Dictionary<string, object>