Open
Description
NOTE: We do not look at .zip attachments for issue investigation.
Describe the bug
Error while send a Toast from a different thread
To Reproduce
Steps to reproduce the behavior:
- Create a toast
<Toasts class="p-3" Messages="messages" AutoHide="true" Delay="5000" ShowCloseButton=true Placement="ToastsPlacement.TopRight" />
- Create messages
private List<ToastMessage> messages = new List<ToastMessage>();
- In a new thread (from WS client) call to
{
var msg = new ToastMessage()
{
Type = ToastType.Danger,
Title = "Issue found!",
HelpText = $"{issueNewNotification.IssueSeverity} - {issueNewNotification.Date}",
Message = $"{issueNewNotification.IssueTitle}.",
};
lock (messages)
{
messages.Add(msg);
}
StateHasChanged();
});```
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
toast.js:89 Uncaught TypeError: Cannot read properties of null (reading 'classList')
at toast.js:89:21
at g (index.js:226:51)
at HTMLDivElement.a (index.js:247:5)
at s (index.js:71:11)
at index.js:253:7
**Versions (please complete the following information):**
- .NET Version: net9.0
- BlazorBootstrap: 3.3.1
- Blazor WebAssembly / Server: WebAssembly
- Blazor Interactive Render Mode: With all the same
- Blazor Interactivity Location: With all the same
Metadata
Metadata
Assignees
Labels
No labels