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

Allow custom actions for close button in MudSnackbar #7317

Open
2 tasks done
BieleckiLtd opened this issue Aug 8, 2023 · 2 comments · May be fixed by #8589
Open
2 tasks done

Allow custom actions for close button in MudSnackbar #7317

BieleckiLtd opened this issue Aug 8, 2023 · 2 comments · May be fixed by #8589
Assignees
Labels
enhancement New feature or request wants to do a PR

Comments

@BieleckiLtd
Copy link
Contributor

Feature request type

Enhance component

Component name

MudSnackbar

Is your feature request related to a problem?

No response

Describe the solution you'd like

I propose the ability to associate custom actions with the close button of MudSnackbar.

For example:

    private void ShowMessage()
    {
        message = Snackbar.Add("Message", configure: config =>
        {
            config.RequireInteraction = true;
            config.ShowCloseIcon = true;
            config.OnClose = OnClose;
        });
    }

    private void OnClose()
    {
        // Actions to perform when the user dismisses the message
    }

Have you seen this feature anywhere else?

No response

Describe alternatives you've considered

  1. Custom RenderFragment with custom close button
  2. config.ShowCloseIcon = false
  3. handling closing manually.

Pull Request

  • I would like to do a Pull Request

Code of Conduct

  • I agree to follow this project's Code of Conduct
@BieleckiLtd BieleckiLtd added enhancement New feature or request triage labels Aug 8, 2023
@github-actions
Copy link

github-actions bot commented Aug 8, 2023

👋 Thanks for wanting to do a PR @BieleckiLtd !
We suggest that you wait for an answer from @MudBlazor/contribution-team @MudBlazor/core-team . Otherwise we can not guarantee that your PR will be merged. As the library grows, we have to be very strict what PRs we can accept.

@danielchalmers
Copy link
Contributor

If you're still interested I expect this would be merged easily

@BieleckiLtd BieleckiLtd linked a pull request Apr 6, 2024 that will close this issue
6 tasks
@henon henon removed the triage label May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request wants to do a PR
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants