responsive_widgets icon indicating copy to clipboard operation
responsive_widgets copied to clipboard

BoxConstraints NaN issue

Open Faiyyaz opened this issue 5 years ago • 2 comments

I am getting NaN error on app start if the device is locked while installing the build via adb.

══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
The following assertion was thrown building RawMaterialButton(dirty, state:
_RawMaterialButtonState#77fbf):
BoxConstraints has NaN values in maxWidth and maxHeight.
The offending constraints were:
  BoxConstraints(0.0<=w<=NaN, 0.0<=h<=NaN; NOT NORMALIZED)

The relevant error-causing widget was:
  RawMaterialButton
  file:///home/faiyyaz/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/responsive_widgets-2.0.1/lib/widgets/raised_button_responsive_widget.dart:165:12

and this is how i see the UI on mobile Screenshot_2020-09-17-10-07-19-46_bfec114022d4ec32295108acb110ca7d

Faiyyaz avatar Sep 17 '20 07:09 Faiyyaz

Hi @LucazzP Sorry got the issue it was the wrong usage of the plugin. I read the plugin doc and it is working fine now

Faiyyaz avatar Sep 17 '20 15:09 Faiyyaz

The NaN issue is still coming for raisedbuttonresponsive maxheight and maxwidth

Faiyyaz avatar Sep 18 '20 05:09 Faiyyaz