Skip to content

Commit

Permalink
Fixes a speaker notes bug that did not allow going to the right in th…
Browse files Browse the repository at this point in the history
…e speaker notes.

The reason for that is that the "rel" attribute contained "prev" respective "next prefetch".
Change this selector to use the ~= selector
See: https://developer.mozilla.org/en-US/docs/Web/CSS/Attribute_selectors#attrvalue_2
  • Loading branch information
michael-kerscher committed Feb 7, 2025
1 parent c05f0b6 commit 0f81ea8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion theme/speaker-notes.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@

// Update prev/next buttons to keep speaker note state.
document
.querySelectorAll('a[rel="prev"], a[rel="next"]')
.querySelectorAll('a[rel~="prev"], a[rel~="next"]')
.forEach((elem) => {
elem.href += "#speaker-notes-open";
});
Expand Down

0 comments on commit 0f81ea8

Please sign in to comment.