I created two types of colour layers.This is the second layer with pink colour.I created the little rectangles using rectangle tool, selected them with command key + T and rotated them randomly. In this one, I change some of the rectangles to pink and group all the rectangles shapes named it shapes 1.
These are 4 different movements of the rectangles to make the GIF.
This is a screen shot of 6 different movements of the shapes appearing together.I made 6 layers in timeline.