xd-to-flutter-plugin icon indicating copy to clipboard operation
xd-to-flutter-plugin copied to clipboard

Items larger than the Artboard can cause issues

Open hemish11 opened this issue 4 years ago • 2 comments

I had created an oval a the app bar in my app. Its width is larger than that of the screens width. When exporting, it does not get transformed in dart code. The screenshot of the code generated is: Screenshot 2020-05-15 at 3 38 30 PM And I was able to correct it by changing transform values of x-axis to 0 And its screenshot is as follows: Screenshot 2020-05-15 at 3 41 07 PM Here is the screenshot of the app and of its design in Adobe Xd respectively: Screenshot 2020-05-15 at 3 30 56 PM Screenshot 2020-05-15 at 3 42 50 PM The Artboard in Adobe XD is for iPhone XR/XS Max/11 and the simulator is also iPhone 11. Please fix this as it makes much harder to change many values when there are multiple such ovals in application.

hemish11 avatar May 15 '20 10:05 hemish11

At a quick glance, I think this is related to issues with items that are larger than the screen size. This is related to some challenges in how Flutter handles these scenarios. We're still working to resolve this, and may wait for the layout changes related to #13 so we can take a more wholistic approach. Have you seen any issues with ovals that are not larger than the screen?

This is documented in our README "Known Issues", but we should put together a proper issue for it.

gskinner avatar May 15 '20 17:05 gskinner

There is a little idea to solve this problem by me. For this you may add if condition in which it checks that if it is larger than that of screen size if it is then it would set that specific axis value to 0 and if not then it would add the specific value.

hemish11 avatar May 15 '20 17:05 hemish11