JS fix for cover resize