flutter_loading_screen 0.0.3 copy "flutter_loading_screen: ^0.0.3" to clipboard
flutter_loading_screen: ^0.0.3 copied to clipboard

Flutter package for loading screen UI & enent after loading.

flutter_responsive_scale #

A flutter package for making beautiful data loading screen with next page route event

Demo #

screenshot

Features #

  • Beautiful loading screen UI
  • Event callback after task completion
  • Event navigate to next screen after task complete
  • Parameters for Compete UI control

Usage #

Add dependency #

Please check the latest version before installation. If there is any problem with the new version, please use the previous version

dependencies:
  flutter:
    sdk: flutter
  # add flutter_responsive_scale
  flutter_loading_screen: ^{latest version}

Add the following imports to your Dart code #

import 'package:flutter_loading_screen/flutter_loading_screen.dart';

Property #

Property Type Parameter Description
initializers Parameter double required initial task parameter
navigateToWidget Function dynamic required Parameter for navigate to Next page.
image Parameter assets image (optional) parameter for background assets image

Examples #


import 'dart:core';

import 'package:flutter/material.dart';
import 'package:flutter_loading_screen/flutter_loading_screen.dart';

void main() => runApp(const MyApp());

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Loading Screen Example',
      theme: ThemeData(
        brightness: Brightness.dark,
        primarySwatch: Colors.grey,
      ),
      home: const LoadingScreenExample(),
    );
  }
}

class LoadingScreenExample extends StatefulWidget {
  const LoadingScreenExample({super.key});

  @override
  LoadingScreenExampleState createState() => LoadingScreenExampleState();
}

class LoadingScreenExampleState extends State<LoadingScreenExample> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: FlutterLoadingScreen(
        initializers: const <dynamic>[TimeMessages.timer],
        navigateToWidget: Scaffold(
          appBar: AppBar(
            title: const Text('Done'),
          ),
        ),
        loaderColor: Colors.white,
        image: Image.asset(
          'assets/lake.jpg',
          fit: BoxFit.cover,
        ),
        title: 'Welcome in demo app',
        backgroundColor: Colors.black,
        styleTextUnderTheLoader: const TextStyle(
          fontSize: 14.0,
          fontWeight: FontWeight.bold,
          color: Colors.lightGreenAccent,
        ),
      ),
    );
  }
}

class TimeMessages {
  static Future timer(MessageState state) async {
    await Future.delayed(const Duration(seconds: 20), () {
      state.setMessage = DateTime.now().toIso8601String();
    });
  }
}

Authors #

🚀 About Me #

I'm a flutter developer...

portfolio linkedin medium

Logo

License #

MIT

6
likes
140
pub points
33%
popularity
screenshot

Publisher

unverified uploader

Flutter package for loading screen UI & enent after loading.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on flutter_loading_screen