How to fix the "jump" element to onMouseDown?

There is a simple task to drag svg group of elements with the correct initial cursor position. But faced with the following problem: at different radii of a circle on the onMouseDown on any element there is a jump. If the radii are everywhere equal, then everything works as it should. Can't understand what value I'm missing in the calculation of the displacement of the cursor, because the group size should increase along with the items inside.
Here is the code to understand what was going on: https://codepen.io/FLighter/pen/PowpjYB
Thanks in advance
April 3rd 20 at 18:55
1 answer
April 3rd 20 at 18:57
Solution
Thank you very much! You helped me a lot - Katelin commented on April 3rd 20 at 19:00

Find more questions by tags JavaScriptSVG