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

Defines the fluent API for configuring the Kendo UI ExpansionPanel

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Syntax:

C#
public class ExpansionPanelBuilder : WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>, IHtmlContent

Inheritance: objectHelperResultWidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>ExpansionPanelBuilder

Implements: IHtmlContent

Inherited Members WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ToComponent()WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.Expression(string)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.Explorer(ModelExplorer)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.Name(string)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.Deferred(bool)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.HtmlAttributes(object)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.HtmlAttributes(IDictionary<string, object>)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ScriptAttributes(object, bool)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ScriptAttributes(IDictionary<string, object>, bool)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.Render()WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ToHtmlString()WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.WriteTo(TextWriter, HtmlEncoder)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ToClientTemplate()WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.AsModule(bool)WidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ComponentWidgetBuilderBase<ExpansionPanel, ExpansionPanelBuilder>.ContainerHelperResult.WriteTo(TextWriter, HtmlEncoder)HelperResult.WriteActionobject.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Constructors

Initializes a new instance of the ExpansionPanelBuilder class.

C#
public ExpansionPanelBuilder(ExpansionPanel component)
Parameters:componentExpansionPanel

Methods

A collection of visual animations used when ExpansionPanel is expand or collapsed through user interactions. Setting this option to false will disable all animations. is not a valid configuration.

C#
public ExpansionPanelBuilder Animation(Action<ExpansionPanelAnimationSettingsBuilder> configurator)
Parameters:configuratorAction<ExpansionPanelAnimationSettingsBuilder>

The ExpansionPanelAnimationSettingsBuilder for the animation setting.

Returns:

ExpansionPanelBuilder

Returns the current instance of ExpansionPanelBuilder .

A collection of visual animations used when ExpansionPanel is expand or collapsed through user interactions. Setting this option to false will disable all animations. is not a valid configuration.

C#
public ExpansionPanelBuilder Animation(bool enabled)
Parameters:enabledbool

Enables or disables the animation option.

Returns:

ExpansionPanelBuilder

Returns the current instance of ExpansionPanelAnimationSettingsBuilder .

The name of the collapse icon.

C#
public ExpansionPanelBuilder CollapseIconClass(string value)
Parameters:valuestring

The value for CollapseIconClass

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

The HTML string representing the associated content for the component.

C#
public ExpansionPanelBuilder Content(Action value)
Parameters:valueAction

The value for Position

Returns:

ExpansionPanelBuilder

Returns the current instance of ExpansionPanelBuilder to allow method chaining.

Example:
C#
@(Html.Kendo().ExpansionPanel()
.Name("expansionPanel")
.Content(() =&gt;
{
&lt;strong&gt;ExpansionPanel content&lt;/strong&gt;
})
)

The HTML string representing the associated content for the component.

C#
public ExpansionPanelBuilder Content(Func<object, object> value)
Parameters:valueFunc<object, object>

The value for Position

Returns:

ExpansionPanelBuilder

Returns the current instance of ExpansionPanelBuilder to allow method chaining.

Example:
C#
@(Html.Kendo().ExpansionPanel()
.Name("expansionPanel")
.Content(@&lt;strong&gt; Hello World!&lt;/strong&gt;)
)

The HTML string representing the associated content for the component.

C#
public ExpansionPanelBuilder Content(string value)
Parameters:valuestring

The value for Position

Returns:

ExpansionPanelBuilder

Returns the current instance of ExpansionPanelBuilder to allow method chaining.

Example:
C#
@(Html.Kendo().ExpansionPanel()
.Name("expansionPanel")
.Content("Hello World!")
)

If set to true the widget will be disabled.

C#
public ExpansionPanelBuilder Disabled()
Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

If set to true the widget will be disabled.

C#
public ExpansionPanelBuilder Disabled(bool value)
Parameters:valuebool

The value for Disabled

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

Configures the client-side events.

C#
public ExpansionPanelBuilder Events(Action<ExpansionPanelEventBuilder> configurator)
Parameters:configuratorAction<ExpansionPanelEventBuilder>

The client events action.

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

Example:
C#
@(Html.Kendo().ExpansionPanel()
.Name("ExpansionPanel")
.Events(events =&gt; events
.Expand("onExpand")
)
)

If set to true the widget will be expanded by default.

C#
public ExpansionPanelBuilder Expanded()
Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

If set to true the widget will be expanded by default.

C#
public ExpansionPanelBuilder Expanded(bool value)
Parameters:valuebool

The value for Expanded

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

The class of the expand icon.

C#
public ExpansionPanelBuilder ExpandIconClass(string value)
Parameters:valuestring

The value for ExpandIconClass

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

The height of the widget. Numeric values are treated as pixels.

C#
public ExpansionPanelBuilder Height(double value)
Parameters:valuedouble

The value for Height

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

The subtitle of the widget.

C#
public ExpansionPanelBuilder SubTitle(string value)
Parameters:valuestring

The value for SubTitle

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

The title of the widget.

C#
public ExpansionPanelBuilder Title(string value)
Parameters:valuestring

The value for Title

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.

If set to false the user will not be able to expand/collapse the widget.

C#
public ExpansionPanelBuilder Toggleable(bool value)
Parameters:valuebool

The value for Toggleable

Returns:

ExpansionPanelBuilder

Returns the current ExpansionPanelBuilder instance.