Our client would like to have a similiar behaviour to windows’s mosaic window placing. They want us to give them a route (page/layout) where they can drag other routes from the menu to there and size them and move around them and rearrange them or close them…
Is this even possible/makeable with Flow?..
Sounds like you want to use the upcoming Dashboard component. Dashboard layout component · Issue #6626 · vaadin/platform · GitHub
Thank you @knoobie :) If its decided that do not want to pay for it, are there existing ways to do something similiar?..
A couple of quick thoughts, without analyzing it too much:
- It sounds possible to implement that kind of UI
- “Route” is the wrong abstraction (or at least the wrong term) to use; a Route maps directly to one path in the browser. You can’t have multiple paths in the browser, so you can’t have multiple Routes visible at the same time.
Then you have to create it yourself using e.g. https://gridstackjs.com/ and connect that with your java side ;)
Not regarding layout itself but maybe the routing logic, I would recommend looking into Router Layouts. Create a Router Layout with your multi window component and you want to override the detach method. It is not intended to leave the view there and may break, but you would only have to think about layouting not routing.
Another way:
In our ERP we have one primary layout with @Route("/view/:viewName?")
for all our business views. Type and content of the view is definded by the viewName parameter and via query string. So no sub routes are registered within Vaadin.
The primary layout holds the navigation sidebar and a TabSheet, that displays the view and switches forth and back like browser tabs. When routing to a view via the navigation sidebar, either a new tab will be created or the exiting tab/layout will be opened.