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

Width Landscape issue on i Pad #23

Open
alilibx opened this issue Jun 20, 2020 · 0 comments
Open

Width Landscape issue on i Pad #23

alilibx opened this issue Jun 20, 2020 · 0 comments

Comments

@alilibx
Copy link

alilibx commented Jun 20, 2020

I found your find_dropdown library very nice and good implementation, saved me alot of time, but there seems to be an issue when the design is landscape, particularly in iPad and landscape mode the width is not quite as the portrait mode, find screenshots, i did a pull request in your git repo hope you can approve it so i can post the change

[FIXED BY] Updating the select_dialog.dart

LINE 131

  bool get isMobile =>
      MediaQuery.of(context).orientation == Orientation.portrait? 
      MediaQuery.of(context).size.width > MediaQuery.of(context).size.height:
       MediaQuery.of(context).size.height > MediaQuery.of(context).size.width;

  BoxConstraints get webDefaultConstraints =>
      BoxConstraints(maxWidth: 250, maxHeight: 500);

  BoxConstraints get mobileDefaultConstraints => BoxConstraints(
        maxWidth: MediaQuery.of(context).orientation == Orientation.portrait
          ? MediaQuery.of(context).size.width * 0.9
          : MediaQuery.of(context).size.height * 0.7,
        maxHeight: MediaQuery.of(context).orientation == Orientation.portrait
          ? MediaQuery.of(context).size.height * 0.7
          : MediaQuery.of(context).size.width * 0.7,
      );
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

1 participant