From d453adde074fe9a465e0ed83f11f70c9b80bfde5 Mon Sep 17 00:00:00 2001 From: alistair3149 Date: Wed, 3 Jul 2024 13:09:11 -0400 Subject: [PATCH] fix: URL hash should be escaped when used as selector --- modules/ext.tabberNeue/ext.tabberNeue.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ext.tabberNeue/ext.tabberNeue.js b/modules/ext.tabberNeue/ext.tabberNeue.js index 4ddbf79..2bf35dc 100644 --- a/modules/ext.tabberNeue/ext.tabberNeue.js +++ b/modules/ext.tabberNeue/ext.tabberNeue.js @@ -645,7 +645,7 @@ class TabberBuilder { await this.createHeader(); await this.createIndicator(); - const activeTab = this.tablist.querySelector( `#tab-${ urlHash }` ) || this.tablist.firstElementChild; + const activeTab = this.tablist.querySelector( `#tab-${ CSS.escape( urlHash ) }` ) || this.tablist.firstElementChild; TabberAction.setActiveTab( activeTab ); TabberAction.updateHeaderOverflow( this.tablist );