particle-iot / spark-setup-ios

(DEPRECATED) Spark device setup library - Soft AP Cocoapod/Carthage lib for iOS
Apache License 2.0
19 stars 25 forks source link

SparkSetup API - Improper Alignment for iOS iPad Form Factor #53

Closed P-DoxQuad closed 3 years ago

P-DoxQuad commented 7 years ago

There seems to be something wrong with the way SparkSetup works on an iPad when building your own app. I have a button to login to a particle account, but the login page is completely misaligned. I've tried testing on a physical iPad as well as different iOS iPad emulators, and it doesn't display properly. However everything works perfectly on an iPhone emulator.

I tried fixing the layout of the login page by adding my own constraints but that didn't solve anything either.

This app is being created from Xcode 8.2.1.

particle_account_misalign_ipad

rickkas7 commented 7 years ago

I was able to reproduce this, creating a new universal project with the current spark setup and opening it in the iPad Air emulator. The same project displays correctly on my phone.

idokleinman commented 7 years ago

Known issue, constraints for the setup lib were not created for generic window size, since project was created before XCode supported this (traits, etc). Good workaround: please use UIModalPresentationFormSheet style window popup to display the setup wizard, more info here: https://developer.apple.com/reference/uikit/uimodalpresentationstyle/uimodalpresentationformsheet

I'd love to get a PR from the community that fixes the setup lib UI constraints to support generic size. It's definitely on the radar.