diff --git a/js/accessibility/voicing/voicingManager.js b/js/accessibility/voicing/voicingManager.js
index bd42b98..9b434e4 100644
--- a/js/accessibility/voicing/voicingManager.js
+++ b/js/accessibility/voicing/voicingManager.js
@@ -417,7 +417,7 @@ class VoicingManager extends Announcer {
}
// embedding marks (for i18n) impact the output, strip before speaking
- const stringToSpeak = stripEmbeddingMarks( utterance.getTextToAlert( this.respectResponseCollectorProperties ) );
+ const stringToSpeak = removeBrTags( stripEmbeddingMarks( utterance.getTextToAlert( this.respectResponseCollectorProperties ) ) );
const speechSynthUtterance = new SpeechSynthesisUtterance( stringToSpeak );
speechSynthUtterance.voice = this.voiceProperty.value;
speechSynthUtterance.pitch = this.voicePitchProperty.value;
@@ -617,6 +617,22 @@ class VoicingQueueElement {
}
+/**
+ * @param {Object} element - returned from himalaya parser, see documentation for details.
+ * @returns {boolean}
+ */
+const isNotBrTag = element => !( element.type.toLowerCase() === 'element' && element.tagName.toLowerCase() === 'br' );
+
+/**
+ * Remove
or
tags from a string
+ * @param {string} string - plain text or html string
+ * @returns {string}
+ */
+function removeBrTags( string ) {
+ const parsedAndFiltered = himalaya.parse( string ).filter( isNotBrTag );
+ return himalaya.stringify( parsedAndFiltered );
+}
+
const voicingManager = new VoicingManager();
// @public - Priority levels that can be used by Utterances providing the `announcerOptions.priority` option.