I am building an animated grid with react-spring. Elements are animated from previous to next position. Positions are calculated to fit elements depending on width and their