The igc-carousel presents a set of igc-carousel-slides by sequentially displaying a subset of one or more slides.

Slots
Default — slot for the carousel. Any projected `igc-carousel-slide` components should be projected here.
previous-button — Renders content inside the previous button.
next-button — Renders content inside the next button.
CSS Parts
navigation — The wrapper container of each carousel navigation button.
previous — The wrapper container of the carousel previous navigation button.
next — The wrapper container of the carousel next navigation button.
dot — The carousel dot indicator container.
active — The carousel active dot indicator container.
label — The label container of the carousel indicators.
start — The wrapping container of all carousel indicators when indicators-orientation is set to start.

The animation type.

animationType: HorizontalTransitionAnimation

Whether the carousel should skip rotating to the first slide after it reaches the last.

disableLoop: boolean

Whether the carousel should ignore use interactions and not pause on them.

disablePauseOnInteraction: boolean

Whether the carousel should render the indicator controls (dots).

hideIndicators: boolean

Whether the carousel should skip rendering of the default navigation buttons.

hideNavigation: boolean

The format used to set the aria-label on the carousel indicators. Instances of '{0}' will be replaced with the index of the corresponding slide.

indicatorsLabelFormat: string

Sets the orientation of the indicator controls (dots).

indicatorsOrientation: CarouselIndicatorsOrientation

The duration in milliseconds between changing the active slide.

interval: number

Gets/Sets the locale used for getting language, affecting resource strings.

locale: string

Controls the maximum indicator controls (dots) that can be shown. Default value is 10.

maximumIndicatorsCount: number

The resource strings for localization. Currently only aria-label attributes are localized for the carousel.

resourceStrings: ICarouselResourceStrings

The format used to set the aria-label on the carousel slides and the text displayed when the number of indicators is greater than tha maximum indicator count. Instances of '{0}' will be replaced with the index of the corresponding slide. Instances of '{1}' will be replaced with the total amount of slides.

slidesLabelFormat: string

Whether the carousel has vertical alignment.

vertical: boolean

The index of the current active slide.

get current(): number

Returns number

Whether the carousel in in paused state.

get isPaused(): boolean

Returns boolean

Whether the carousel is in playing state.

get isPlaying(): boolean

Returns boolean

The slides of the carousel.

get slides(): IgrCarouselSlideComponent[]

Returns IgrCarouselSlideComponent[]

The total number of slides.

get total(): number

Returns number

Switches to the next slide, runs any animations, and returns if the operation was successful.

next(): Promise<boolean>

Returns Promise<boolean>

Pauses the carousel rotation of slides.

pause(): void

Returns void

Resumes playing of the carousel slides.

play(): void

Returns void

Switches to the previous slide, runs any animations, and returns if the operation was successful.

prev(): Promise<boolean>

Returns Promise<boolean>

Switches to the passed-in slide, runs any animations, and returns if the operation was successful.

select(slide: IgrCarouselSlideComponent, animationDirection: "next" | "prev"): Promise<boolean>

Parameters

  • slide: IgrCarouselSlideComponent
  • animationDirection: "next" | "prev"

Returns Promise<boolean>

Emitted when the carousel enters paused state by a user interaction.

onPaused(args: CustomEvent<void>): void

Parameters

Returns void

Emitted when the carousel enters playing state by a user interaction.

onPlaying(args: CustomEvent<void>): void

Parameters

Returns void

Emitted when the current active slide is changed either by user interaction or by the interval callback.

onSlideChanged(args: CustomEvent<number>): void

Parameters

Returns void