Hi All,
I'm new to IOS development/Xcode and would appreciate any/all advice/guidance on this unexplainable issue. Please excuse my potential usage of wrong terms.
I have a project that was handed to me in a near completed state and there is a UI bug in the program that I am trying to fix. It is opening multiple instances of a View Controller Scene in the wrong dimensions, causing instanced layers that act independently of each other rather than a simple "page re-routing" like regular front end development.
Upon investigating the codebase I have noticed the following potential source: The storyboard was originally modeled after an IPhone 16 Pro Max, however the main device we will be creating the app for is an iPad 11 mini. Upon changing the simulated device, the view models for most of my XXXViewControllerScenes are not rendering the correct size.
Here are some examples:
Image1 ) When selecting the RootNavController (scene 1) > all storyboard scenes render the correct size (at least thats what it visually looks like). When clicking on the "Type Select View Controller" or the View within the "Type Select View Controller Scene" (scene 2) the view models remain the correct size.
Image2) However when clicking into the View for "Order Start View Controller Scene" - this causes the View and SafeArea renders for all scenes(except the RootNav)to shrink and not be the correct size equal to the simulated device:
This also persists, where previosly my Scene 2 which was the correct size, is now the incorrect size no matter what I do. The only way I have found to work around this is to re-select my RootNavController to render all scenes the proper size, then individually click the components I'm trying to edit in the Document Outline panel and tweak them manually on the Attribute Editor. Not to mention this makes setting constraints extremely hard as the elements render "off screen"
What I have checked so far:
- Ensure all my ViewControllerScene's Attribute Editor > Simulated Metric > Size = Inferred
- Unchecked "Use Preferred Explicit Size" for all ViewControllerScene's Attribute Editor > Simulated Metric > Content Size - 1 thing to note here is some of them have a set size of 744x1133 (when they render the full size) but it changes to 580x640 (when it shrinks) even though the option is UNCHECKED?
Circling back to the UI Bug in my app, when I segue to the next Scene, the pages end up loading in the shrinked dimension.
Please help me identify what is causing this issue and how to fix it or refer me to some guides that can assist.