mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-19 09:50:15 +01:00
🔊 refactor: Optimize Aria-Live Announcements for macOS VoiceOver (#3851)
This commit is contained in:
parent
757b6d3275
commit
dc40e577af
5 changed files with 59 additions and 170 deletions
|
|
@ -3,17 +3,17 @@ import React from 'react';
|
|||
|
||||
interface AnnouncerProps {
|
||||
statusMessage: string;
|
||||
responseMessage: string;
|
||||
logMessage: string;
|
||||
}
|
||||
|
||||
const Announcer: React.FC<AnnouncerProps> = ({ statusMessage, responseMessage }) => {
|
||||
const Announcer: React.FC<AnnouncerProps> = ({ statusMessage, logMessage }) => {
|
||||
return (
|
||||
<div className="sr-only">
|
||||
<div aria-live="assertive" aria-atomic="true">
|
||||
<div aria-live="polite" aria-atomic="true">
|
||||
{statusMessage}
|
||||
</div>
|
||||
<div aria-live="polite" aria-atomic="true">
|
||||
{responseMessage}
|
||||
{logMessage}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue