Just hoping for a little advice on container selection as I’m still getting my head around how they all work…
I’ve got a popup that shows status information and parameter data on the left, and a small graph/chart on the right. I’m viewing this popup on an iPad, and it works well when the iPad is in landscape orientation, but not so much when it’s in portrait orientation. When in portrait orientation, I’d prefer to place the graph/chart below the status/parameter section, which would then also display quite nicely. I’d thought I could just use a breakpoint container - which I can - but then I have to make the root container wide enough for landscape, and tall enough for portrait, which will leave blank space on my popup in either configuration.
I’d though perhaps I could experiment with binding the default width/height to the position of the components on the screen (not sure if this would be a viable option or not), but at that point I began to wonder if perhaps I’m going about this the wrong way, and there’s a simpler way to use the available container types to do what I’m trying to do.
Anyone got a suggestion?
From the sound of it, you’d want to use either a Flex or Column Container within your Popup, but their “flexiness” is dependent on their dimensions, which would be set in the Popup configuration (width would be the driving property).
The problem here is that you would want the popup to open no wider than the display, but still open wider for landscape and narrower for portrait… Right now there’s no way to determine whether the device is displaying one way or the other, and when we pen a Popup, we open at the default size of the View being displayed in the Popup if the width parameter is not set.
Providing visibility into the Viewport’s current dimensions is something we’re planning to provide, but it won’t be ready for release.
I think I’m following you. If I understand rightly: if I was opening the view full screen, my approach would work, because the view would size itself to the available screen width, which would vary depending on what orientation the device was in. But a popup window just opens at default dimensions (or whatever dimensions I specify), and has no way of knowing whether it’s fully on screen or not. Am I correct? If so, I could perhaps change this view from a pop up to a full screen view - on an iPad I’d only ever be looking at one instance at a time. Though on a desktop machine I could want to compare 3 or 4 instances at the same time, which I lose the ability for if I take that approach. I guess I have to make the trade off until we have the ability to see the viewport’s dimensions.
That’s the issue, yes; the popup doesn’t open to the edge of the screen, it opens to the View’s defaultSize or the dimensions you specify.
You could maybe look into using a Docked View, but I would only recommend one instance per Docked View.
Thanks. I guess I’ll just have to keep things simple for now - perhaps I’ll revisit later when the ability to see the viewport’s current dimensions is added.