Skip to content
On this page

Onboarding

A sequence of introductory screens with navigation.

Onboarding in FluttyUIOnboarding in FluttyUI dark theme

Import

import 'package:flutter/widgets.dart';
import 'package:fluttyui/fluttyui.dart' as ui;

API Reference

The declarations below match the current FluttyUI source. Types are shown without the optional ui. import prefix.

Onboarding

const Onboarding({
  super.key,
  required this.pages,
  required this.onCompleted,
  this.onSkip,
  this.onPageChanged,
  this.initialPage = 0,
  this.nextLabel = 'Continue',
  this.completeLabel = 'Get started',
  this.backLabel = 'Back',
  this.skipLabel = 'Skip',
  this.showBack = true,
  this.showProgress = true,
  this.backgroundColor,
  this.activeIndicatorColor,
  this.inactiveIndicatorColor,
  this.contentPadding = const EdgeInsets.symmetric(horizontal: 24, vertical: 16),
  this.footerPadding = const EdgeInsets.symmetric(horizontal: 24),
  this.useSafeArea = true,
  this.animationDuration,
});
ParameterTypeRequiredDefault
keyKey?Nonull
pagesList<OnboardingPage>Yes—
onCompletedVoidCallbackYes—
onSkipVoidCallback?Nonull
onPageChangedValueChanged<int>?Nonull
initialPageintNo0
nextLabelStringNo'Continue'
completeLabelStringNo'Get started'
backLabelStringNo'Back'
skipLabelStringNo'Skip'
showBackboolNotrue
showProgressboolNotrue
backgroundColorColor?Nonull
activeIndicatorColorColor?Nonull
inactiveIndicatorColorColor?Nonull
contentPaddingEdgeInsetsGeometryNoconst EdgeInsets.symmetric(horizontal: 24, vertical: 16)
footerPaddingEdgeInsetsGeometryNoconst EdgeInsets.symmetric(horizontal: 24)
useSafeAreaboolNotrue
animationDurationDuration?Nonull

Application Setup

Place components under FluttyApp to provide theme, navigation, localization, and overlay defaults. Use theme tokens for shared appearance settings.

Source

lib/src/widgets/navigation/onboarding/onboarding.dart

This reference is generated from the Onboarding declaration in the FluttyUI core checkout. The component catalog lists the other available building blocks.

DartFlutter

Get started with FluttyUI