diff --git a/README.md b/README.md
index 8891c39..ea36a61 100644
--- a/README.md
+++ b/README.md
@@ -100,6 +100,12 @@ Versions
--------
+ - 0.5.7
+ -
+
+ - add option for user input (#27)
+
+
- 0.5.6
-
diff --git a/bower.json b/bower.json
index 562c967..ad887b8 100644
--- a/bower.json
+++ b/bower.json
@@ -1,6 +1,6 @@
{
"name": "strengthify",
- "version": "0.5.6",
+ "version": "0.5.7",
"homepage": "https://github.com/MorrisJobke/strengthify",
"authors": [
"Eve Ragins
+ * Copyright (c) 2013-2019 Morris Jobke
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
diff --git a/jquery.strengthify.min.js b/jquery.strengthify.min.js
index 0026164..843c733 100644
--- a/jquery.strengthify.min.js
+++ b/jquery.strengthify.min.js
@@ -1 +1 @@
-(function($){$.fn.strengthify=function(paramOptions){"use strict";var defaults={zxcvbn:'zxcvbn/zxcvbn.js',titles:['Weakest','Weak','So-so','Good','Perfect'],tilesOptions:{tooltip:true,element:false},drawTitles:false,drawMessage:false,drawBars:true,$addAfter:null,nonce:null};return this.each(function(){var options=$.extend(defaults,paramOptions);if(!options.drawTitles&&!options.drawMessage&&!options.drawBars){console.warn("expect at least one of 'drawTitles', 'drawMessage', or 'drawBars' to be true")}function getWrapperFor(id){return $('div[data-strengthifyFor="'+id+'"]')};function drawStrengthify(){var password=$(this).val(),elemId=$(this).attr('id'),opacity=(password==='')?0:1,result=zxcvbn(password),css='',bsLevel='',message='',$wrapper=getWrapperFor(elemId),$container=$wrapper.find('.strengthify-container'),$message=$wrapper.find('[data-strengthifyMessage]');$wrapper.children().css('opacity',opacity).css('-ms-filter','"progid:DXImageTransform.Microsoft.Alpha(Opacity='+opacity*100+')"');if(options.onResult){options.onResult(result)}switch(result.score){case 0:case 1:css='password-bad';bsLevel='danger';message=result.feedback?result.feedback.suggestions.join('
'):"";break;case 2:bsLevel='warning';message=result.feedback?result.feedback.suggestions.join('
'):"";css='password-medium';break;case 3:css='password-good';bsLevel='info';message="Getting better.";break;case 4:css='password-good';bsLevel='success';message="Looks good.";break}if($message){$message.removeAttr('class');$message.addClass('bg-'+bsLevel);if(password===''){message=''}$message.html(message)}if($container){$container.attr('class',css+' strengthify-container').css('width',((result.score===0?1:result.score)*25)+'%');if(password===''){$container.css('width',0)}}if(options.drawTitles){if(options.tilesOptions.tooltip){$wrapper.attr('title',options.titles[result.score]).tooltip({placement:'bottom',trigger:'manual'}).tooltip('fixTitle').tooltip('show');if(opacity===0){$wrapper.tooltip('hide')}}if(options.tilesOptions.element){$wrapper.find(".strengthify-tiles").text(options.titles[result.score])}}};function init(){var $elem=$(this),elemId=$elem.attr('id');var drawSelf=drawStrengthify.bind(this);var $addAfter=options.$addAfter;if(!$addAfter){$addAfter=$elem}$addAfter.after('');if(options.drawBars){getWrapperFor(elemId).append('').append('').append('').append('').append('')}if(options.drawMessage){getWrapperFor(elemId).append('')}if(options.drawTitles&&options.tilesOptions){getWrapperFor(elemId).append('')}$elem.parent().on('scroll',drawSelf);var script=document.createElement("script");script.src=options.zxcvbn;if(options.nonce!==null){script.setAttribute('nonce',options.nonce)}document.head.appendChild(script);$elem.bind('keyup input change',drawSelf)};init.call(this);})}}(jQuery));
\ No newline at end of file
+!function(t){t.fn.strengthify=function(e){"use strict";var s={zxcvbn:"zxcvbn/zxcvbn.js",userInputs:[],titles:["Weakest","Weak","So-so","Good","Perfect"],tilesOptions:{tooltip:!0,element:!1},drawTitles:!1,drawMessage:!1,drawBars:!0,$addAfter:null,nonce:null};return this.each(function(){var a=t.extend(s,e);function r(e){return t('div[data-strengthifyFor="'+e+'"]')}a.drawTitles||a.drawMessage||a.drawBars||console.warn("expect at least one of 'drawTitles', 'drawMessage', or 'drawBars' to be true"),function(){var e=t(this),s=e.attr("id"),i=function(){var e=t(this).val(),s=t(this).attr("id"),i=""===e?0:1,n=zxcvbn(e,a.userInputs),o="",d="",c="",l=r(s),p=l.find(".strengthify-container"),f=l.find("[data-strengthifyMessage]");switch(l.children().css("opacity",i).css("-ms-filter",'"progid:DXImageTransform.Microsoft.Alpha(Opacity='+100*i+')"'),a.onResult&&a.onResult(n),n.score){case 0:case 1:o="password-bad",d="danger",c=n.feedback?n.feedback.suggestions.join("
"):"";break;case 2:d="warning",c=n.feedback?n.feedback.suggestions.join("
"):"",o="password-medium";break;case 3:o="password-good",d="info",c="Getting better.";break;case 4:o="password-good",d="success",c="Looks good."}f&&(f.removeAttr("class"),f.addClass("bg-"+d),""===e&&(c=""),f.html(c)),p&&(p.attr("class",o+" strengthify-container").css("width",25*(0===n.score?1:n.score)+"%"),""===e&&p.css("width",0)),a.drawTitles&&(a.tilesOptions.tooltip&&(l.attr("title",a.titles[n.score]).tooltip({placement:"bottom",trigger:"manual"}).tooltip("fixTitle").tooltip("show"),0===i&&l.tooltip("hide")),a.tilesOptions.element&&l.find(".strengthify-tiles").text(a.titles[n.score]))}.bind(this),n=a.$addAfter;n||(n=e),n.after(''),a.drawBars&&r(s).append('').append('').append('').append('').append(''),a.drawMessage&&r(s).append(""),a.drawTitles&&a.tilesOptions&&r(s).append(''),e.parent().on("scroll",i);var o=document.createElement("script");o.src=a.zxcvbn,null!==a.nonce&&o.setAttribute("nonce",a.nonce),document.head.appendChild(o),e.bind("keyup input change",i)}.call(this)})}}(jQuery);
\ No newline at end of file
diff --git a/package.json b/package.json
index 1238ed3..f097474 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "strengthify",
- "version": "0.5.6",
+ "version": "0.5.7",
"description": "Combine jQuery and zxcvbn to create a password strength meter",
"main": "jquery.strengthify.js",
"scripts": {
diff --git a/strengthify.css b/strengthify.css
index 539f908..6dee455 100644
--- a/strengthify.css
+++ b/strengthify.css
@@ -1,9 +1,9 @@
/**
* Strengthify - show the weakness of a password (uses zxcvbn for this)
* https://github.com/MorrisJobke/strengthify
- * Version: 0.5.6
+ * Version: 0.5.7
* License: The MIT License (MIT)
- * Copyright (c) 2013-2016 Morris Jobke
+ * Copyright (c) 2013-2019 Morris Jobke
*/
.strengthify-wrapper {