Flexbox component / layout

Hello all,

I have been fiddling with the NGClient a bit lately. Because I have found it relatively hard to implement a responsive layout that caters to my needs, I wanted to make my life easier and create a flexbox component. (flexbox vs float layout: Flexbox - MDN Web Docs Glossary: Definitions of Web-related terms | MDN )

The flexbox component I had in mind would be regular component that you can drag and drop from the palette and you would be able to set flexbox-css properties like flex-direction, justify-content, align-items, etc from the properties tab. It should also be possible to drop other components into the flexbox.

I thought I’d add the component to my Component Package, but in my understanding Web Components cannot contain other components, am I right?

I also looked into creating my own Layout Package and a flexbox Layout Component in there, but I found out that a Layout Component is not a full Angular directive, but actually just a div with a class. Am I right that this will also not work, because there’s no way to pass down properties to the div?

Does anyone else have other ideas about this?

Best,

Jesse

At the moment I’m managing to achieve what I want, by using the customDiv component and adding a style attribute… Not the prettiest solution, but it definitely makes my life a lot easier :P