change state of link while scroll

kinda inefficient, but works. will work on more efficient version later.