FIX: Add unit to width and height CSS properties.
This commit is contained in:
parent
c0e8950fdb
commit
35d0fd038e
|
@ -53,8 +53,8 @@ function show(image) {
|
||||||
copyImg.style.position = "absolute";
|
copyImg.style.position = "absolute";
|
||||||
copyImg.style.top = `${image.offsetTop}px`;
|
copyImg.style.top = `${image.offsetTop}px`;
|
||||||
copyImg.style.left = `${image.offsetLeft}px`;
|
copyImg.style.left = `${image.offsetLeft}px`;
|
||||||
copyImg.style.width = imageData.width;
|
copyImg.style.width = `${imageData.width}px`;
|
||||||
copyImg.style.height = imageData.height;
|
copyImg.style.height = `${imageData.height}px`;
|
||||||
copyImg.className = imageData.className;
|
copyImg.className = imageData.className;
|
||||||
|
|
||||||
image.parentNode.insertBefore(copyImg, image);
|
image.parentNode.insertBefore(copyImg, image);
|
||||||
|
|
Loading…
Reference in New Issue