Free
Pro

Gallery Carousel

Ply slider is the gallery carousel: full-bleed slides, captions, autoplay, and crossfade. Selectors ply-carousel and ply-gallery-slider. Install slider. For a row of cards install carousel. For a numeric thumb install range-slider. CLI gallery, image-slider, and slideshow still map to this gallery.

When to use

  • Hero or product image decks that show one slide at a time.
  • When you need captions, indicators, or interval autoplay.

When not to use

  • A horizontal card scroller — use carousel (ply-horizontal-carousel).
  • A form range input — use range-slider.

Install with npx ply-ui-cli add slider.

free

View source

Slides Only

The simplest way to use the carousel is by passing an array of slide URLs.

Modular Structure

Use ply-carousel-item for more control over slide content.

Captions

Add rich captions to slides using ply-carousel-caption.

Crossfade & Dark Variant

Enable transition="crossfade" and [dark]="true" for light backgrounds.

Horizontal scroller

This page is the image/content deck (npx ply-ui-cli add slider, selectors ply-carousel / ply-gallery-slider). A row of cards is a different registry item: carousel (ply-horizontal-carousel). npx ply-ui-cli add carousel installs that scroller, not this gallery.

Installation

Run the following command to add this component to your project:

bash
npx ply-ui-cli add slider

API Reference

For AI agents

Copy a prompt with the registry name, CLI install, and import — or add the Ply MCP server.

bash
npx -y ply-ui-mcp

Ply provides standalone components. Import the exact elements you want to use into your component.

typescript (Example)
// Install: npx ply-ui-cli add slider
// Paths are relative to aliases.components (default: src/app/components)
import { CarouselCaptionComponent } from './slider/carousel-caption/carousel-caption.component';
import { CarouselItemComponent } from './slider/carousel-item/carousel-item.component';
import { GallerySliderComponent } from './slider/gallery-slider.component';
import { SliderDirective } from './slider/slider.directive';

@Component({
  selector: 'app-your-component',
  imports: [
    CarouselCaptionComponent,
    CarouselItemComponent,
    GallerySliderComponent,
    SliderDirective
  ],
  template: `...`
})
export class YourComponent {}

API for slider — generated from JSDoc in the library source.

API reference for slider
APIMemberTypeDefaultDescription
ply-carousel-caption—— — A caption overlay for a gallery slider or carousel item, typically positioned over the image.
ply-carousel-itemclassstring''Additional CSS classes to merge into the host element.
ply-carousel-itemintervalnumber-1Optional override for the auto-play interval when this specific slide is active.
ply-gallery-slider, ply-carouselclassstring''Additional CSS classes to merge into the host element.
ply-gallery-slider, ply-carouselactiveIndexnumber0The zero-based index of the currently active slide.
ply-gallery-slider, ply-carouselanimatebooleantrueWhether transitions are animated.
ply-gallery-slider, ply-carouseldarkbooleanfalseApplies a dark-themed visual overlay/buttons.
ply-gallery-slider, ply-carouseldirection'next' | 'prev''next'Defines the transition direction explicitly.
ply-gallery-slider, ply-carouselintervalnumber5000Milliseconds before auto-advancing to the next slide. Set to 0 to disable.
ply-gallery-slider, ply-carouselpause'hover' | false'hover'Whether to pause autoplay on hover.
ply-gallery-slider, ply-carouseltouchbooleantrueWhether touch swipe navigation is enabled.
ply-gallery-slider, ply-carouseltransition'slide' | 'crossfade''slide'The animation transition style.
ply-gallery-slider, ply-carouselwrapbooleantrueWhether the carousel loops back to the start when reaching the end.
ply-gallery-slider, ply-carouselslidesstring[][]Optional array of image source URLs for a quick image-only slider.
ply-gallery-slider, ply-carousel(itemChange)number — Emitted whenever the active slide index changes.
[plySlider](slideAction)boolean — The slideAction output property.