-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Generalized DialogViewComponent wrapper to display forms in popup #2069
Comments
If you are talking about forms, isn't |
Yes and no. It does, but any Component you pass in as a parameter still needs to handle a lot of common stuff. e.g. both RowDetailsComponent and NoteDetailsComponent need to inject MAT_DIALOG_DATA (and therefore can't be used as a "routed view"). And both need to add standard stuff like the app-dialog-close ("x" icon), although we have encapsulated that nicely in a component that just needs to be added to the template. In the long run, I would love to have components like NoteDetailsComponent (so that would probably include also the generic EntityDetailsComponent) that can be used both in dialogs and in main (routed) views. The biggest challenge there is probably how/where we handle the save buttons+actions. |
…d views (#2304) * migrated special config appConfig:note-details to a standard view:note/:id * adapted building blocks to be more flexible (app-view-title, app-dialog-buttons) * extracted basics from EntityDetailsComponent into a new AbstractEntityDetailsComponent to be reused * implemented DialogViewComponent similar to RoutedViewComponent * generalized NoteDetailsComponent (and to some extend EntityDetailsComponent) to be usable in both dialogs and routed views * ChildrenList & NotesManager take actual inputs instead of the full config object * add an app-view-actions wrapper to align DialogButtons and Actions placed on top in routed views closes #2069
🎉 This issue has been resolved in version 3.35.0-master.4 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
🎉 This issue has been resolved in version 3.35.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
We repeatedly need similar logic when displaying forms in a dialog/popup. To ensure the UX is consistent and make implementations simpler, a generic wrapper component that helps to display any component as a dialog would be useful.
Similar to the
RoutedViewComponent
, this newDialogViewComponent
could allow us to implement the actual functionalities in components that only use@Input()
and@Output()
properties - which can then be used in both routed and dialog wrapped views.Common functionality for all dialog forms should be:
[source]
concrete use cases / samples:
The text was updated successfully, but these errors were encountered: