Remove video element workaround
Note:
Video elements (or other elements that are a "component") that is partially visible will be ignored.
It's not a that big of an issue right now and a better solution needs to be found.
MODIFY
js/views/cfi_navigation_logic.js
js/views/cfi_navigation_logic.js
@@ -451,16 +451,9 @@ var CfiNavigationLogic = function (options) {
range.selectNode($el[0]);
//noinspection JSUnresolvedFunction
clientRectList = range.getClientRects();
- } else {
- if ($el.parent()[0].tagName === "video"){
- // create a rect using the video
- var videoRect = $el.parent()[0].getClientRects();
- clientRectList = videoRect;
} else {
//noinspection JSUnresolvedFunction
clientRectList = $el[0].getClientRects();
-
- }
}
// all the separate rectangles (for detecting position of the element
@@ -891,9 +884,6 @@ var CfiNavigationLogic = function (options) {
// we need to also check for medai elements as a cfi
} else {
//if not then generate a CFI for the element
- if ( element.parentElement.nodeName === "video") {
- element = element.parentElement;
- }
return self.getCfiForElement(element);
}
}

Remove video element workaround

Note:
Video elements (or other elements that are a "component") that is partially visible will be ignored.
It's not a that big of an issue right now and a better solution needs to be found.