An Input Form Element to enter OTP Number, PIN or split single characters.
MIT License
An Input Form Element to enter OTP Number, PIN or split single characters.
Add angular and otpInputDirective to your code
<script src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.5.3/angular.min.js"></script>
<script src="otpInputDirective.min.js"></script>
otpInputDirective
module in your application.angular.module('app', ['otpInputDirective']);
<div otp-input-directive options="otpInput"></div>
$scope.otpInput={
size:6,
type:"text",
onDone: function(value){
console.log(value);
},
onChange: function(value){
console.log(value);
}
};