I'm trying to author a "choose your own adventure"-style ebook in the epub3 format. In a general sense, epub seems well-suited for this... each choice at the bottom of the page is just a html link to another file internal to the epub. However, unlike with a paper book, it is easy to turn the page past these choices with an inadvertent tap. I sometimes do this with my thumb on my phone just wrapped around the edge as I hold it.
It would be nice if I could disable page-turning (to the next xhtml file) entirely.
I have tried the linear="no" attribute in the metadata.opf file. While the spec's description of this feature seems clear that it should be perfect for my use (maybe even the intended use for it), in practice I find that it does not work correctly at all. Some apps ignore it (Calibre's ebook viewer), others like iBooks or whatever it's called now act like it was only ever meant for endnotes.
I've found hints of using preventDefault(); in javascript in an epub, but can't find enough to even know where to start with it. epub.js results pollute any keywords I can think of to use, and Google results haven't been exactly improving the last couple of years.
Any javascript that prevented page-turning through the normal mechanism would need to be able to ignore following the links, but also allow for page turning within the xhtml file (since it might be large enough to require page-turning to read it all).