Class TwCarouselItem
- Namespace
- TwBlazor.Components
- Assembly
- TwBlazor.dll
Represents a single slide within a TwCarousel.
public class TwCarouselItem : TwBlazorComponentBase, IComponent, IHandleEvent, IHandleAfterRender, ITwComponent
- Inheritance
-
TwCarouselItem
- Implements
- Inherited Members
Remarks
A TwCarouselItem is only ever used as a child of a TwCarousel. It renders nothing itself - its ChildContent is rendered by the parent carousel only while this slide is the active one.
Constructors
TwCarouselItem()
public TwCarouselItem()
Properties
ChildContent
The content to display while this slide is active. This is a required parameter.
[Parameter]
public required RenderFragment ChildContent { get; set; }
Property Value
Parent
The parent carousel that this slide belongs to. This property is required and is set via cascading parameters.
[CascadingParameter]
public required TwCarousel Parent { get; set; }
Property Value
Methods
BuildRenderTree(RenderTreeBuilder)
Renders the component to the supplied RenderTreeBuilder.
protected override void BuildRenderTree(RenderTreeBuilder __builder)
Parameters
__builderRenderTreeBuilder
OnInitialized()
Method invoked when the component is ready to start, having received its initial parameters from its parent in the render tree.
protected override void OnInitialized()