Merge branch 'patch-1' of https://github.com/jhofker/reveal.js into dev
This commit is contained in:
commit
fc568b5524
1 changed files with 4 additions and 1 deletions
|
@ -4054,7 +4054,10 @@
|
||||||
// If, after clicking a link or similar and we're coming back,
|
// If, after clicking a link or similar and we're coming back,
|
||||||
// focus the document.body to ensure we can use keyboard shortcuts
|
// focus the document.body to ensure we can use keyboard shortcuts
|
||||||
if( isHidden === false && document.activeElement !== document.body ) {
|
if( isHidden === false && document.activeElement !== document.body ) {
|
||||||
|
// Not all elements support .blur() - SVGs among them.
|
||||||
|
if (typeof document.activeElement.blur === 'function') {
|
||||||
document.activeElement.blur();
|
document.activeElement.blur();
|
||||||
|
}
|
||||||
document.body.focus();
|
document.body.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue