_checkVisibility(rect, parent, direction) {
		const elementOffset = this._getElementOffset(rect, direction)
		const viewportOffset = this._getViewportOffset(parent, direction)

		let visible = true

		if ((rect.left - viewportOffset.x) < -(rect.width - elementOffset.x)) {
			visible = false
		}

		if ((rect.left + viewportOffset.x) > (parent.w - elementOffset.x)) {
			visible = false
		}

		if ((rect.top - viewportOffset.y) < -(rect.height - elementOffset.y)) {
			visible = false
		}

		if ((rect.top + viewportOffset.y) > (parent.h - elementOffset.y)) {
			visible = false
		}

		return visible
	}
Check the visibility of the trigger in the viewport, with offsets applied
@param {ClientRect} rect
@param {{w: number, h: number}} parent
@param {string} direction top, bottom, left, right
@returns {boolean}
@private