Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to null safety please? #37

Open
atebitftw opened this issue Mar 4, 2021 · 16 comments
Open

Migrate to null safety please? #37

atebitftw opened this issue Mar 4, 2021 · 16 comments

Comments

@atebitftw
Copy link

:)

@Mayb3Nots
Copy link

Mayb3Nots commented Mar 17, 2021

Alternative to this package is this loading_overlay.

@FelipeFernandesLeandro
Copy link

Alternative to this package is this loading_overlay.

right link > loading_overlay

@Mayb3Nots
Copy link

Alternative to this package is this loading_overlay.

right link > loading_overlay

Ahhh yes my bad, edited my link to the right one. Thanks!

@EgHubs
Copy link

EgHubs commented Mar 28, 2021

Any news?

@atebitftw
Copy link
Author

@EgHubs I found that someone published a null-safe version of the same package here: https://pub.dev/packages/modal_progress_hud_nsn

@luis901101
Copy link

luis901101 commented Apr 16, 2021

https://pub.dev/packages/modal_progress_hud_nsn is not a good alternative because it only supports iOS and Android. I just created a null-safety clone of this package which as it is a clone it has support for all flutter supported platforms not only for Android and iOS.
Here:
modal_progress_hud_alt

I also made a PR40

@bkoznov
Copy link

bkoznov commented Jun 21, 2021

@mmcc007 Any timeline on merging the null safety PR? Appreciate your work, and that of @luis901101 !

@Lakhankumawat
Copy link

In my case Loading_Overlay also didn't worked , please don't try that ....That too ( Loading Overlay) does not support Null Safety
Watch this

@luis901101
Copy link

The amount of code necessary for this plugin to work is just a few lines, I recommend for those who needs some specific behavior to checkout at the source code at https://github.com/luis901101/modal_progress_hud_alt which is alreeady null-safe and copy from there. It is literally a widget.

@Mayb3Nots
Copy link

@Lakhankumawat what version are you using it on? Because loading_overlay is on null safety and I'm using it right now. Please check your configuration.

@Lakhankumawat
Copy link

Thanks to @luis901101 for his modal_progress_hud_alt it worked in my case after using lots of loading progress indicator. Thanks again @luis901101 . You are awesome

@neelayak
Copy link

neelayak commented Sep 7, 2021

this is the null safety version

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

class ModalProgressHUD extends StatelessWidget {
  final bool inAsyncCall;
  final double opacity;
  final Color color;
  final Widget progressIndicator;
  Offset? offset;
  final bool dismissible;
  final Widget child;

  ModalProgressHUD({
    Key? key,
    required this.inAsyncCall,
    this.opacity = 0.3,
    this.color = Colors.grey,
    this.progressIndicator = const CircularProgressIndicator(),
    this.offset,
    this.dismissible = false,
    required this.child,
  })  : assert(child != null),
        assert(inAsyncCall != null),
        super(key: key);

  @override
  Widget build(BuildContext context) {
    if (!inAsyncCall) return child;

    Widget layOutProgressIndicator;
    if (offset == null)
      layOutProgressIndicator = Center(child: progressIndicator);
    else {
      layOutProgressIndicator = Positioned(
        child: progressIndicator,
        left: offset!.dx,
        top: offset!.dy,
      );
    }

    return new Stack(
      children: [
        child,
        new Opacity(
          child: new ModalBarrier(dismissible: dismissible, color: color),
          opacity: opacity,
        ),
        layOutProgressIndicator,
      ],
    );
  }
}
`

@joeyyy688
Copy link

@joseph-fox
Copy link

Is this repo abandoned by the original maintainers?

@joeyyy688
Copy link

joeyyy688 commented Nov 1, 2021

Is this repo abandoned by the original maintainers?

yes, Its been a while since it was updated.
Anyways feel free to check this out. It's an upgraded one

@dpedrinha
Copy link

@mmcc007 you ok? Can you please push this update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests