According to the KOBO epub guidelines:
QUOTE:
The navigator.epubReadingSystem Property
Note that the navigator.epubReadingSystem property is only supported on Kobo's Desktop and eInk platforms and is not presently supported on iOS, Android or Windows.
END OF QUOTE
— — —
Asking the KOBO app on iOS for navigator.epubReadingSystem correctly returns ‘UNDEFINED’.
The same kepub.epub file on the Clara BW 2024 completely rejects execution of all JS although it is supposed to support the property.
Without accessing the property navigator.epubReadingSystem JS gets executed
correctly (element myConsole text -> "Hello, Dolly!" -> "Hello, to you too!")
<script>
document.querySelector("#myConsole").innerHTML = "Hello, Dolly!";
const timer_A = setTimeout(function() {
document.querySelector("#myConsole").innerHTML = "Hello, to you too!";
}, 2000)
const timer_B = setTimeout(function() {
let feature = "dom-manipulation";
document.querySelector("#myConsole").innerHTML = feature + ": " + navigator.epubReadingSystem;
}, 4000)
/*
const timer_C = setTimeout(function() {
let feature = "dom-manipulation";
document.querySelector("#myConsole").innerHTML = feature + ": " + navigator.epubReadingSystem.hasFeature(feature);
}, 6000)
*/
</script>
According to the KOBO epub guidelines:
QUOTE:
The navigator.epubReadingSystem Property
Note that the navigator.epubReadingSystem property is only supported on Kobo's Desktop and eInk platforms and is not presently supported on iOS, Android or Windows.
END OF QUOTE
— — —
Asking the KOBO app on iOS for navigator.epubReadingSystem correctly returns ‘UNDEFINED’.
The same kepub.epub file on the Clara BW 2024 completely rejects execution of all JS although it is supposed to support the property.
Without accessing the property navigator.epubReadingSystem JS gets executed
correctly (element myConsole text -> "Hello, Dolly!" -> "Hello, to you too!")