Skip to content
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

IgxToast show should take a message param #7156

Closed
grosch opened this issue Apr 16, 2020 · 5 comments · Fixed by #7716
Closed

IgxToast show should take a message param #7156

grosch opened this issue Apr 16, 2020 · 5 comments · Fixed by #7716
Assignees
Labels
snackbar toast 🧰 feature-request version: 10.0.x version: 10.1.x ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged.

Comments

@grosch
Copy link

grosch commented Apr 16, 2020

It's pretty common to use one IgxToast but want to support multiple messages. Instead of having to do this:

this.toast.message = "xyz"
this.toast.show()

it would be nicer to just do

this.toast.show("xyz")
@radomirchev
Copy link
Contributor

@grosch , the feature request is in the list for the current milestone. You could follow the milestone progress on the Roadmap board or in the Roadmap file

@zdrawku
Copy link
Contributor

zdrawku commented Jun 22, 2020

Hello @grosch, with 9.1.0 we've added a functionality for displaying various content into the toast component through content projection. You can now place your message or any html element in the toast content which gives you more powerful and diverse way of toast content handling. Given that, I wanted to let you know that we are not planning to add a message param to the show method. Let me know if you have any questions or concerns.

We are going to update the official topic as well in order to address that change.

@zdrawku zdrawku closed this as completed Jun 22, 2020
@grosch
Copy link
Author

grosch commented Jun 22, 2020

That's doesn't really accomplish anything different though. So now I'll put a variable in the toast part of the HTML, but I still have to then take two steps to display it. I set the value, and then I call show.

If I only have one message the toaster would display what you're doing help. However, when it's a reusable item, which can display multiple messages depending on state, I'm still at a two step process.

@zdrawku
Copy link
Contributor

zdrawku commented Jun 23, 2020

I understand your point, we always strive to have simple and clear API, trying to limit having a couple of ways to achieve equivalent functionalities. After further discussion with @radomirchev we've decided to add this capability.

Adding this FR to the next sprint.

@zdrawku
Copy link
Contributor

zdrawku commented Jul 2, 2020

Hey @grosch, the new functionality will be available with the next product release 10.0.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
snackbar toast 🧰 feature-request version: 10.0.x version: 10.1.x ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants