I’m not blaming the concepts. I’m just stating that as it stands, layout is really hard.
Part of the problem I was able to see was due to the fact that there were nested divs with alternating absolute and relative positioning. This killed all padding settings to the sub-objects. Basically the default layout was preventing natural browser positioning. (anti-PAYG) ;-) Maybe the solution is to write another layout, but I have a feeling that simplifying the layout might help even more. Yishay and I will try to put together some test cases to help show the problems and possibly help find the correct solution... On Nov 27, 2016, at 5:06 PM, Alex Harui <aha...@adobe.com> wrote: > > > On 11/27/16, 3:31 AM, "Harbs" <harbs.li...@gmail.com> wrote: > >> FlexJS makes it way too hard to solve simple layout challenges. > > I don't know if it is fair to blame the patterns and principles of FlexJS > for that, but it certainly is possible that the Layout you need hasn't > been written yet. > > Keep in mind that regular Flex VerticalLayout visited every child twice > and used %width in a non-CSS-compliant way. So under PAYG, the default > FlexJS VerticalLayout is going to leverage what the browser will do and > work differently. > > But that means these lighter weight layouts will leverage CSS and > StackOverflow is full of folks wrestling with CSS to get what they want. > If FlexJS has other, slower layouts that solve these common problems, that > will be an advantage for us. > > The way I suggest folks deal with layout right now (given that the layout > you want may not exist yet), is to just use an HTML editor to layout some > widgets in the way you want. All FlexJS is trying to do is identify and > encapsulate existing HTML and JS patterns and present them as components. > So figure out what the HTML needs to look like and that will determine if > an existing layout can do it, or if you need to write a new one. Don't > forget that in FlexJS, there is both CSS margin and padding: regular Flex > only supported padding and a non-CSS compliant "gap". > > Thanks, > -Alex >