Currently, when you go to close the sheetPortal, it will check to see if the gridPortal is open. If the gridPortal is not open, then the gridPortal will be set to whatever the sheetPortal was set to. This can be confusing for users who are using the mapPortal, because going into the sheetPortal and then back out will actually take them to the gridPortal, and not back to the mapPortal.
Ideally, it should check to see if either the mapPortal or the gridPortal is already open before opening the gridPortal on close.
Currently, when you go to close the sheetPortal, it will check to see if the gridPortal is open. If the gridPortal is not open, then the gridPortal will be set to whatever the sheetPortal was set to. This can be confusing for users who are using the mapPortal, because going into the sheetPortal and then back out will actually take them to the gridPortal, and not back to the mapPortal.
Ideally, it should check to see if either the mapPortal or the gridPortal is already open before opening the gridPortal on close.