पैकेज, रिपॉज़िटरी और ऐप श्रेणियाँ खोजें

पैकेज विवरणv1.2.1

another_flutter_splash_screen

एक फ्लटर पैकेज जो आपके ऐप में स्प्लैश स्क्रीन को आसानी से लागू करने का तरीका प्रदान करता है। साथ ही रिपो में संगठित डेमो भी प्रदान करता है।

AndroidiOSWebmacOSWindowsLinux
30-दिन डाउनलोड
3.1 हज़ार
लाइक
310
Pub अंक
150

पैकेज इंस्टॉल करें

flutter pub add another_flutter_splash_screen

पैकेज अवलोकन

सार्वजनिक जानकारी से बना चयन मार्गदर्शन। केवल संदर्भ हेतु।

एक अन्य Flutter स्प्लैश स्क्रीन एक हल्का पैकेज है जो Flutter एप्लिकेशन में स्प्लैश स्क्रीन के कार्यान्वयन को सरल बनाता है। यह एक आसान उपयोग के लिए API प्रदान करता है जो कस्टमाइज़ किए गए अवधि, पृष्ठभूमि रंग और लोगो के साथ एक स्प्लैश स्क्रीन प्रदर्शित करने के लिए उपयोग किया जा सकता है। पैकेज में डेमो उदाहरण शामिल हैं जो विकासकर्ताओं को तेजी से शुरुआत करने में मदद करते हैं। सभी प्रमुख प्लेटफॉर्म—Android, iOS, Web, macOS, Windows और Linux—के लिए सुविधाजनक है, जो लक्षित उपकरण के आधार पर एक समान स्प्लैश अनुभव सुनिश्चित करता है।

उपयोग

  • त्वरित ऐप लॉन्च स्क्रीन सेटअप
  • क्रॉस-प्लेटफॉर्म स्प्लैश स्क्रीन कार्यान्वयन
  • कस्टमाइज़ेबल स्प्लैश एनिमेशन
  • ऑनबोर्डिंग या ब्रांडिंग प्रदर्शन
  • एप्लिकेशन इनिशियलाइजेशन देरी का प्रबंधन

मुख्य विशेषताएँ

  • स्प्लैश स्क्रीन एकीकरण के लिए सरल API
  • कई प्लेटफॉर्म का समर्थन करता है
  • निर्मित डेमो उदाहरण
  • कॉन्फ़िगरेबल अवधि और दिखावट
  • हल्का और निर्भरता-मुक्त
  • रंग और संपत्तियों के सुगम अनुकूलन

इनके लिए उपयुक्त

  • शुरुआती Flutter विकासकर्ता
  • स्थिर ओनबोर्डिंग विजुअल्स की आवश्यकता वाले ऐप्स
  • त्वरित स्प्लैश स्क्रीन डेप्लॉयमेंट की आवश्यकता वाले प्रोजेक्ट
  • क्रॉस-प्लेटफॉर्म मोबाइल और डेस्कटॉप एप्लिकेशन
  • न्यूनतम सेटअप समय की तलाश में विकासकर्ता

विचार योग्य बातें

  • सीमित उन्नत एनीमेशन विकल्प
  • डायनामिक कंटेंट लोडिंग के लिए बिल्ट-इन सपोर्ट नहीं है
  • पोस्ट-स्प्लैश नेविगेशन के हैंडलिंग के लिए मैनुअल हैंडलिंग की आवश्यकता है
  • जटिल स्प्लैश तर्क के लिए आदर्श नहीं
  • स्थिर या सरल स्प्लैश प्रदर्शन के लिए सबसे उपयुक्त

मूल README

संबंधित सोर्स रिपॉज़िटरी के मूल README का स्नैपशॉट। नवीनतम सामग्री के लिए रिपॉज़िटरी देखें।

pub package

:star: Splash screens made simple :star:


Supports deciding next screen dynamically. Example here
Supports Immersive Mode (Hide Status Bar in Splash Screen). Example here

Buy Me A Coffee

Getting started

Add another_flutter_splash_screen to your pubspec.yaml file and start implementing splash screen easily.

Installation

Just add another_flutter_splash_screen as a dependency in your pubspec.yaml file.

dependencies:
  another_flutter_splash_screen: <Latest Version>

Usage

 import 'package:another_flutter_splash_screen/another_flutter_splash_screen.dart';

A splash screen with a gif splash.

FlutterSplashScreen.gif(
          gifPath: 'assets/example.gif',
          gifWidth: 269,
          gifHeight: 474,
          nextScreen: const MyHomePage(),
          duration: const Duration(milliseconds: 3515),
          onInit: () async {
            debugPrint("onInit");
          },
          onEnd: () async {
            debugPrint("onEnd 1");
          },
        );

A splash screen with fade in splash.

FlutterSplashScreen.fadeIn(
          backgroundColor: Colors.white,
          onInit: () {
            debugPrint("On Init");
          },
          onEnd: () {
            debugPrint("On End");
          },
          childWidget: SizedBox(
            height: 200,
            width: 200,
            child: Image.asset("assets/dart_bird.png"),
          ),
          onAnimationEnd: () => debugPrint("On Fade In End"),
          nextScreen: const MyHomePage(),
        );

A splash screen with scale splash.

FlutterSplashScreen.scale(
          gradient: const LinearGradient(
            begin: Alignment.topCenter,
            end: Alignment.bottomCenter,
            colors: [
              Colors.lightBlue,
              Colors.blue,
            ],
          ),
          childWidget: SizedBox(
            height: 50,
            child: Image.asset("assets/twitter_logo_white.png"),
          ),
          duration: const Duration(milliseconds: 1500),
          animationDuration: const Duration(milliseconds: 1000),
          onAnimationEnd: () => debugPrint("On Scale End"),
          nextScreen: const MyHomePage(),
        );

Dynamic routing

  • Following is the example of Navigate using different mechanisms
FlutterSplashScreen.gif(
     ...
     // go_router example
     asyncNavigationCallback: () async {
       var response = await userRepository.getUserData();
      if(response.status == 200 && response.data.isAuthenticated){
       GoRouter.of(context).goNamed("home");     
      }
      else{
          // GoRouter.of(context).goNamed("/");
      }
     },
                  OR
     // Named routing example
     asyncNavigationCallback: () async {
       await Future.delayed(const Duration(seconds: 3));
       if (context.mounted) {
         Navigator.pushReplacementNamed(context, "home");
       }
     },
    ...
   );

A splash screen using immersive mode (Hide status bar in splash screen).

Just use "useImmersiveMode : true" to hide status bar in splash screen.

Demo 1
FlutterSplashScreen.gif(
          useImmersiveMode: true,
          gifPath: 'assets/example.gif',
          gifWidth: 269,
          gifHeight: 474,
          nextScreen: const MyHomePage(),
          duration: const Duration(milliseconds: 3515),
        );

A splash screen using lottie animation.

FlutterSplashScreen(
          useImmersiveMode: true,
          duration: const Duration(milliseconds: 2000),
          nextScreen: const MyHomePage(),
          backgroundColor: Colors.white,
          splashScreenBody: Center(
            child: Lottie.asset(
              "assets/lottie_loading_2.json",
              repeat: false,
            ),
          ),
        );

A splash screen with custom splash.

FlutterSplashScreen(
          duration: const Duration(milliseconds: 2000),
          nextScreen: const MyHomePage(),
          backgroundColor: Colors.white,
          splashScreenBody: Center(
            child: Column(
              crossAxisAlignment: CrossAxisAlignment.center,
              children: [
                const SizedBox(
                  height: 100,
                ),
                const Text(
                  "Custom Splash",
                  style: TextStyle(color: Colors.black, fontSize: 24),
                ),
                const Spacer(),
                SizedBox(
                  width: 200,
                  child: Image.asset('assets/flutter.png'),
                ),
                const Spacer(),
                const Text(
                  "Flutter is Love",
                  style: TextStyle(color: Colors.pink, fontSize: 20),
                ),
                const SizedBox(
                  height: 100,
                ),
              ],
            ),
          ),
        );

Additional information

We will be more than happy for your contributions.
Please contribute to another_flutter_splash_screen this github repo.

श्रेणियाँ

सोर्स रिपॉज़िटरी

इस पैकेज का उपयोग करने वाले प्रोजेक्ट