Dear Sir,
Yes, right this would be done using JS & PHP for sure.
Dominate color lazy loader script would be installed into the website so that should be automated to generate small GIF/SVG file and attached there.
With 11 years of experience I am ready to do this work as I have deployed & customized a number of such kind themes & scripts into different website.
Waiting to hear you.
Thanks,
Deepak