flutter_intro 3.0.0-dev.2 copy "flutter_intro: ^3.0.0-dev.2" to clipboard
flutter_intro: ^3.0.0-dev.2 copied to clipboard

outdated

A better way for new feature introduction and step-by-step users guide for your Flutter project.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:flutter_intro/flutter_intro.dart';
import 'package:intro/advanced_guide_page.dart';
import 'package:intro/simple_use.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      theme: ThemeData(
        primarySwatch: Colors.blue,
        visualDensity: VisualDensity.adaptivePlatformDensity,
      ),
      home: const StartPage(),
    );
  }
}

class StartPage extends StatelessWidget {
  const StartPage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('Flutter Intro'),
      ),
      body: Center(
        child: Column(
          mainAxisSize: MainAxisSize.min,
          children: [
            ElevatedButton(
              onPressed: () {
                Navigator.push(
                  context,
                  MaterialPageRoute(
                    builder: (BuildContext context) => Intro(
                      buttonTextBuilder: (order) =>
                          order == 3 ? 'Custom Button Text' : 'Next',
                      child: const SimpleUse(),
                    ),
                  ),
                );
              },
              child: const Text('Simple Use'),
            ),
            ElevatedButton(
              child: const Text('Advanced Use'),
              onPressed: () {
                Navigator.push(
                  context,
                  MaterialPageRoute(
                    builder: (BuildContext context) => Intro(
                      child: const AdvancedGuidePage(),
                    ),
                  ),
                );
              },
            ),
          ],
        ),
      ),
    );
  }
}
539
likes
0
pub points
94%
popularity

Publisher

verified publisher30x.link

A better way for new feature introduction and step-by-step users guide for your Flutter project.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on flutter_intro