add table shading logic