The cursor moves from its editing position to the end of the line in a safari

When I try to edit text in a text box in any position, the cursor moves to its final position.