We need to update the visibility logic to account for the clipped regions in the rect and shadow nodes