mirror of
https://github.com/niklasvh/html2canvas.git
synced 2023-08-10 21:13:10 +03:00

committed by
GitHub

parent
4555940d0b
commit
084017a673
@ -91,6 +91,10 @@ export const calculateBackgroundSize = (
|
||||
): [number, number] => {
|
||||
const [first, second] = size;
|
||||
|
||||
if (!first) {
|
||||
return [0, 0];
|
||||
}
|
||||
|
||||
if (isLengthPercentage(first) && second && isLengthPercentage(second)) {
|
||||
return [getAbsoluteValue(first, bounds.width), getAbsoluteValue(second, bounds.height)];
|
||||
}
|
||||
|
Reference in New Issue
Block a user