update position on reference click