@gechiui/dom
Version:
DOM utilities module for GeChiUI.
16 lines (15 loc) • 596 B
JavaScript
/**
* Internal dependencies
*/
import placeCaretAtEdge from './place-caret-at-edge';
/**
* Places the caret at the top or bottom of a given element.
*
* @param {HTMLElement} container Focusable element.
* @param {boolean} isReverse True for bottom, false for top.
* @param {DOMRect} [rect] The rectangle to position the caret with.
*/
export default function placeCaretAtVerticalEdge(container, isReverse, rect) {
return placeCaretAtEdge(container, isReverse, rect === null || rect === void 0 ? void 0 : rect.left);
}
//# sourceMappingURL=place-caret-at-vertical-edge.js.map