Resolved small mistake of giving display none while class not added