Add click event tracking and project function