@visactor/vrender-components
Version:
components library for dp visualization
12 lines • 535 B
JavaScript
export const isTextOverflow = (componentBoundsLike, textBounds, layout, isHorizontal) => {
if (!textBounds) return !1;
if (isHorizontal) {
if ("start" === layout) {
if (textBounds.x1 < componentBoundsLike.x1) return !0;
} else if (textBounds.x2 > componentBoundsLike.x2) return !0;
} else if ("start" === layout) {
if (textBounds.y1 < componentBoundsLike.y1) return !0;
} else if (textBounds.y2 > componentBoundsLike.y2) return !0;
return !1;
};
//# sourceMappingURL=utils.js.map