From b12d4fe069a2e193cd530f3234e38541adef9ab8 Mon Sep 17 00:00:00 2001 From: Ned Zimmerman Date: Sat, 28 Mar 2020 10:25:09 -0600 Subject: [PATCH] fix: don't make aria-live containers inert (#293) * fix: don't make aria-live containers inert --- src/assets/scripts/Pinecone/Dialog/index.js | 2 +- src/assets/scripts/Pinecone/FilterList/index.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/assets/scripts/Pinecone/Dialog/index.js b/src/assets/scripts/Pinecone/Dialog/index.js index 82053210..90c0a59f 100644 --- a/src/assets/scripts/Pinecone/Dialog/index.js +++ b/src/assets/scripts/Pinecone/Dialog/index.js @@ -57,7 +57,7 @@ class Dialog { * @param {Function} callback */ invokeDialog( callback ) { - const elems = document.querySelectorAll( 'body > *' ); + const elems = document.querySelectorAll( 'body > *:not([aria-live])' ); Array.prototype.forEach.call( elems, ( elem ) => { elem.setAttribute( 'inert', 'inert' ); } ); diff --git a/src/assets/scripts/Pinecone/FilterList/index.js b/src/assets/scripts/Pinecone/FilterList/index.js index 45cf7a09..2dc521cc 100644 --- a/src/assets/scripts/Pinecone/FilterList/index.js +++ b/src/assets/scripts/Pinecone/FilterList/index.js @@ -31,7 +31,7 @@ class FilterList { handleOverlay( event ) { if ( ! event.target.closest( this.config.showCtrlSelector ) && ! event.target.closest( this.config.hideCtrlSelector ) ) return false; - const elems = document.querySelectorAll( 'body > *' ); + const elems = document.querySelectorAll( 'body > *:not([aria-live])' ); if ( event.target.closest( this.config.showCtrlSelector ) ) { document.body.classList.add( 'has-modal' );