I'm submitting a ...
[x ] bug report
[ ] feature request
[ ] question about the decisions made in the repository
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Giving a component in the .component() function of angular2-modal alert() throws error . I am following this syntax
this.modal.alert()
.component(ChartComponent)
.size('lg')
.showClose(true)
.open();
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via
https://plnkr.co or similar (you can use one of the templates above as a starting point).
What is the expected behavior?
component should be reflected on the modal
What is the motivation / use case for changing the behavior?
Please tell us about your environment:
Angular version: 4.0.0
Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)
@ansuman273
Currently this is the way to render a custom component.
However, I also noticed:
The existence of the component default property as part of the FluentAssign. Although it exists, it does throw an error because of type mismatch, as you mentioned. Implementation seems off.
it does work (partially), even though it's types do not match. It renders the custom component, but lacks the context (which, of course, is necessary).
@shlomiassaf
What is the intention with / roadmap regarding the .component() ? Will this be an easier way to implement a custom component?
If the .component() is not being developed in the near future; how can I use the fluent assign method (for convenience) of, for instance, size/isblocking/ etc. ?
IMPORTANT: Please provide a sample using:
I'm submitting a ... [x ] bug report [ ] feature request [ ] question about the decisions made in the repository
Do you want to request a feature or report a bug? Bug
What is the current behavior? Giving a component in the .component() function of angular2-modal alert() throws error . I am following this syntax this.modal.alert() .component(ChartComponent) .size('lg') .showClose(true) .open();
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://plnkr.co or similar (you can use one of the templates above as a starting point).
What is the expected behavior? component should be reflected on the modal
What is the motivation / use case for changing the behavior?
Please tell us about your environment:
Angular version: 4.0.0
Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)