@gechiui/dom
Version:
DOM utilities module for GeChiUI.
17 lines (15 loc) • 456 B
JavaScript
/**
* Internal dependencies
*/
import isEdge from './is-edge';
/**
* Check whether the selection is horizontally at the edge of the container.
*
* @param {Element} container Focusable element.
* @param {boolean} isReverse Set to true to check left, false for right.
*
* @return {boolean} True if at the horizontal edge, false if not.
*/
export default function isHorizontalEdge( container, isReverse ) {
return isEdge( container, isReverse );
}