title: How to detect while caps lock is on/off using angular.js
body: <p>I need one help.I have one password filed validation which only takes the special character.At the time of typing password if user is typing any upper case letter the caps lock on notification will display and when it will off the message should display also.Please check my existing code below.</p>
  
  <pre><code>&lt;span class="input-group-addon ndrftextwidth text-right" style="width:180px"&gt;Password :&lt;/span&gt;
  &lt;div ng-class="{ 'has-error': billdata.pass.$touched &amp;&amp; billdata.pass.$invalid }"&gt;
  &lt;input type="{{inputType}}" name="pass" id="contactno" class="form-control" placeholder="password" ng-model="password" ng-minlength="8" ng-pattern="/^(?=.*[A-Z])(?=.*\d)(?=.*[a-z]).*_.*/" &gt;
  &lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="help-block" ng-messages="billdata.pass.$error" ng-if="billdata.pass.$touched"&gt;
  &lt;p ng-message="minlength" style="color:#F00;"&gt;This field is too short.The min length of your password should be 8.&lt;/p&gt;
  &lt;p ng-message="pattern" style="color:#F00;"&gt;This field needs the special character like at least one number,upper case,lower case letter and underscore.&lt;/p&gt;
  
  &lt;/div&gt;
  </code></pre>
  
  <p>Please help me to resolve this problem.</p>