Flutter 简单的动画介绍页

特点

将此添加到您的 Flutter 应用中,即可获得一个简单的动画介绍页。

example

入门

将此添加到您的包的pubspec.yaml文件中

dependencies:
  animated_introduction: ^1.0.3

用法

导入包

import 'package:animated_introduction/animated_introduction.dart';

创建 SingleIntroScreen 对象列表

final List<SingleIntroScreen> pages = [
  const SingleIntroScreen(
    title: 'Welcome to the Event Management App !',
    description: 'You plans your Events, We\'ll do the rest and will be the best! Guaranteed!  ',
    imageAsset: 'assets/onboard_one.png',
  ),
  const SingleIntroScreen(
    title: 'Book tickets to cricket matches and events',
    description: 'Tickets to the latest movies, crickets matches, concerts, comedy shows, plus lots more !',
    imageAsset: 'assets/onboard_two.png',
  ),
  const SingleIntroScreen(
    title: 'Grabs all events now only in your hands',
    description: 'All events are now in your hands, just a click away ! ',
    imageAsset: 'assets/onboard_three.png',
  ),
];

将列表传递给 AnimatedIntroduction 小部件

Scaffold(
  body: AnimatedIntroduction(
    slides: pages,
    indicatorType: IndicatorType.circle,
    onDone: () {
/// TODO: Go to desire page like login or home
      },
    ),
  );

GitHub

查看 Github