I have tried this way to join all styles in string:
pointElement.style = `
display: 'block',
left: ${(rotated_x + w / 2) / scale}px,
top: ${(h / 2 - rotated_y) / scale}px`;
It is not applied.
I have tried this way to join all styles in string:
pointElement.style = `
display: 'block',
left: ${(rotated_x + w / 2) / scale}px,
top: ${(h / 2 - rotated_y) / scale}px`;
It is not applied.
You can use this,
pointElement.style.display = 'block';
pointElement.style.left = `${(rotated_x + w / 2) / scale}px`;
pointElement.style.top = `${(h / 2 - rotated_y) / scale}px`;
But don't forget to use position: absolute;
CSS property to apply your left and top properties. You will also need to have a container element which has position: relative;
CSS property for absolute positioning of your inner pointElement.