mirror of
https://github.com/open-webui/open-webui
synced 2025-06-26 18:26:48 +00:00
made the chat response messages readable with a screen reader
This commit is contained in:
parent
186a89bcba
commit
53dcaa63d4
@ -580,6 +580,14 @@
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
let screenReaderDiv: HTMLDivElement;
|
||||||
|
|
||||||
|
$: if (message.done) {
|
||||||
|
if (screenReaderDiv) {
|
||||||
|
screenReaderDiv.textContent = message.content;
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<DeleteConfirmDialog
|
<DeleteConfirmDialog
|
||||||
@ -590,6 +598,14 @@
|
|||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<div
|
||||||
|
bind:this={screenReaderDiv}
|
||||||
|
aria-live="polite"
|
||||||
|
class="sr-only"
|
||||||
|
>
|
||||||
|
{message.done ? message.content : ''}
|
||||||
|
</div>
|
||||||
|
|
||||||
{#key message.id}
|
{#key message.id}
|
||||||
<div
|
<div
|
||||||
class=" flex w-full message-{message.id}"
|
class=" flex w-full message-{message.id}"
|
||||||
|
Loading…
Reference in New Issue
Block a user