post_carousel 0.0.2 copy "post_carousel: ^0.0.2" to clipboard
post_carousel: ^0.0.2 copied to clipboard

A customizable Flutter package for displaying a carousel of featured posts with staggered animations.

Post Carousel #

A customizable Flutter package for displaying a carousel of featured posts with staggered animations.

Features #

  • Customizable Carousel: Display a carousel of images with titles.
  • Staggered Animations: Smooth entry animations for carousel items.
  • Active Indicator: Visual indicator for the currently active item.
  • Cached Images: Efficient image loading with caching support.
  • Html Support: Render HTML titles on top of images.

Getting started #

Add the dependency to your pubspec.yaml:

dependencies:
  post_carousel: ^0.0.2

Usage #

Import the package:

import 'package:post_carousel/post_carousel.dart';

Create a list of CarouselItem and pass it to PostCarousel:

PostCarousel(
  items: [
    CarouselItem(
      image: 'https://example.com/image1.jpg',
      title: 'Beautiful Landscape',
      onTap: () {
        print('Tapped on Item 1');
      },
    ),
    CarouselItem(
      image: 'https://example.com/image2.jpg',
      title: 'City Lights',
    ),
  ],
)

Additional parameters #

  • height: Height of the carousel container (default: 300).
  • isAutoPlay: Enable auto-play (default: false).
  • autoPlayDuration: Duration between auto-play slides (default: 3 seconds).

Contributing #

Contributions are welcome! Please feel free to submit a Pull Request.

2
likes
150
points
99
downloads

Publisher

verified publisherrupaksapkota.com.np

Weekly Downloads

A customizable Flutter package for displaying a carousel of featured posts with staggered animations.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

cached_network_image, flutter, flutter_html, flutter_staggered_animations

More

Packages that depend on post_carousel