topbar anpassungen
This commit is contained in:
@@ -57,6 +57,10 @@ export function showAsyncFlash(type, message, timeout) {
|
||||
const notice = document.createElement('div');
|
||||
notice.className = 'notice';
|
||||
notice.setAttribute('data-variant', type);
|
||||
const isAssertive = type === 'error' || type === 'warning';
|
||||
notice.setAttribute('role', isAssertive ? 'alert' : 'status');
|
||||
notice.setAttribute('aria-live', isAssertive ? 'assertive' : 'polite');
|
||||
notice.setAttribute('aria-atomic', 'true');
|
||||
|
||||
const messageSpan = document.createElement('span');
|
||||
messageSpan.textContent = message;
|
||||
|
||||
Reference in New Issue
Block a user