1
0
Fork 0
mirror of https://github.com/futurepress/epub.js.git synced 2025-10-04 15:09:16 +02:00

Update webkit detection, update embedded example

This commit is contained in:
Fred Chasen 2017-09-02 13:52:31 -04:00
parent 6313bb09d0
commit ac08fe0fba
2 changed files with 113 additions and 1 deletions

View file

@ -8,7 +8,8 @@ import { Pane, Highlight, Underline } from "marks-pane";
// Dom events to listen for
const EVENTS = ["keydown", "keyup", "keypressed", "mouseup", "mousedown", "click", "touchend", "touchstart"];
const isWebkit = /AppleWebKit/.test(navigator.userAgent);
const isChrome = /Chrome/.test(navigator.userAgent);
const isWebkit = !isChrome && /AppleWebKit/.test(navigator.userAgent);
const ELEMENT_NODE = 1;
const TEXT_NODE = 3;