diff --git a/package.json b/package.json index 1fdbbfc..22c5614 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-range", - "version": "1.6.2", + "version": "1.6.3", "description": "Range input. Slides in all directions.", "main": "lib/index.js", "types": "lib/index.d.ts", diff --git a/src/utils.ts b/src/utils.ts index 9793959..b6f2e67 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -202,7 +202,7 @@ const getThumbWidth = ( elClone.style.visibility = 'hidden'; document.body.appendChild(elClone); elWidth = Math.ceil(elClone.getBoundingClientRect().width); - elClone.remove(); + document.body.removeChild(elClone); } return elWidth > width ? elWidth : width; },