you can do it, but it will take some work. First you need to create intelligent and dumb component relationships, a dumb component containing html, and an intelligent component (parent) containing logic.
you can read about this template here
you need to use Angular @Input and @Ouput to get and send values ββfrom the silent component.
then you can use Angular EventEmitter to send form values ββback to the smart component
you can read more here
this can be done using form-driven forms. It looks like your current code is a combination of patterns and reactive ... I would look at this with reactive forms, it will be easier.
you can learn about reactive forms here
source share