recharts
Version:
React charts
19 lines (18 loc) • 453 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.cartesianViewBoxToTrapezoid = cartesianViewBoxToTrapezoid;
function cartesianViewBoxToTrapezoid(box) {
if (!box) {
return undefined;
}
return {
x: box.x,
y: box.y,
upperWidth: 'upperWidth' in box ? box.upperWidth : box.width,
lowerWidth: 'lowerWidth' in box ? box.lowerWidth : box.width,
width: box.width,
height: box.height
};
}