Skip to content

Commit

Permalink
Release v3.1.1
Browse files Browse the repository at this point in the history
- Fix wordTwoCharacterClasses rule error message not showing up.
  • Loading branch information
ablanco committed Oct 28, 2021
1 parent a456da8 commit 34f4c14
Show file tree
Hide file tree
Showing 10 changed files with 107 additions and 10 deletions.
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## 3.1.1

- Fix wordTwoCharacterClasses rule error message not showing up.

## 3.1.0

- Allow chaining after setter methods.
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pwstrength-bootstrap",
"version": "3.1.0",
"version": "3.1.1",
"homepage": "https://github.com/ablanco/jquery.pwstrength.bootstrap",
"authors": [
"Alejandro Blanco <alejandro.b.e@gmail.com>"
Expand Down
4 changes: 2 additions & 2 deletions dist/pwstrength-bootstrap.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* jQuery Password Strength plugin for Twitter Bootstrap
* Version: 3.1.0
* Version: 3.1.1
*
* Copyright (c) 2008-2013 Tane Piper
* Copyright (c) 2013 Alejandro Blanco
Expand Down Expand Up @@ -154,7 +154,7 @@ try {
) {
return score;
}
return 0;
return;
};

validation.wordRepetitions = function(options, word, score) {
Expand Down
4 changes: 2 additions & 2 deletions dist/pwstrength-bootstrap.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/pwstrength-bootstrap.min.map

Large diffs are not rendered by default.

92 changes: 92 additions & 0 deletions examples/bootstrap5/rule_options.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
<!DOCTYPE html>
<html>

<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">

<title>Bootstrap 5 Password Strength Meter Example - Rule Options</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-+0n0xVW2eSR5OomGNYDnhzAbDsOXxcvSN1TPprVMTNDbiYZCxYbOOl7+AMvyTG2x" crossorigin="anonymous">
</head>

<body>
<div class="container mt-2">
<h1>Bootstrap 5 Password Strength Meter Example - Rule Options</h1>
<form role="form" class="my-5">
<div class="row" id="pwd-container">
<div class="col-sm">
<label for="password" class="form-label">Password</label>
<input type="password" class="form-control" id="password" placeholder="Password">
</div>
<div class="col-sm pt-5">
<div class="pwstrength_viewport_progress"></div>
</div>
</div>
<div class="row">
<div id="messages" class="col small text-muted"></div>
</div>
</form>
<pre>jQuery(document).ready(function () {
"use strict";
var options = {};
options.rules = {
activated: {
wordTwoCharacterClasses: true
},
specialCharClass: "[!,@,#,$,%,^,&,*,?,_,~,+]"
};
options.ui = {
container: "#pwd-container",
viewports: {
progress: ".pwstrength_viewport_progress"
},
showVerdictsInsideProgressBar: true
};
options.common = {
debug: true,
onLoad: function () {
$('#messages').text('Start typing password');
}
};
$(':password').pwstrength(options);
});</pre>
<p><a href="..">Go back</a></p>
</div>

<script src="https://code.jquery.com/jquery-3.6.0.min.js"
integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/js/bootstrap.bundle.min.js"
integrity="sha384-gtEjrD/SeCtmISkJkNUaaKMoLD0//ElJ19smozuHV6z3Iehds+3Ulb9Bn9Plx0x4"
crossorigin="anonymous"></script>
<script type="text/javascript" src="../pwstrength.js"></script>
<script type="text/javascript">
jQuery(document).ready(function () {
"use strict";
var options = {};
options.rules = {
activated: {
wordTwoCharacterClasses: true
},
specialCharClass: "[!,@,#,$,%,^,&,*,?,_,~,+]"
};
options.ui = {
container: "#pwd-container",
viewports: {
progress: ".pwstrength_viewport_progress"
},
showVerdictsInsideProgressBar: true,
showErrors: true
};
options.common = {
debug: true,
onLoad: function () {
$('#messages').text('Start typing password');
}
};
$(':password').pwstrength(options);
});
</script>
</body>

</html>
1 change: 1 addition & 0 deletions examples/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ <h3>Bootstrap 5</h3>
<ol>
<li><a href="bootstrap5/index.html">Basic usage</a></li>
<li><a href="bootstrap5/popover.html">Show verdict and errors in a popover</a></li>
<li><a href="bootstrap5/rule_options.html">Personalize special chars rule options</a></li>
</ol>

<h3>Bootstrap 4</h3>
Expand Down
4 changes: 2 additions & 2 deletions examples/pwstrength.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* jQuery Password Strength plugin for Twitter Bootstrap
* Version: 3.1.0
* Version: 3.1.1
*
* Copyright (c) 2008-2013 Tane Piper
* Copyright (c) 2013 Alejandro Blanco
Expand Down Expand Up @@ -154,7 +154,7 @@ try {
) {
return score;
}
return 0;
return;
};

validation.wordRepetitions = function(options, word, score) {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pwstrength-bootstrap",
"version": "3.1.0",
"version": "3.1.1",
"description": "jQuery plugin for Twitter Bootstrap that provides rulesets for visualy displaying the quality of a users typed in password.",
"author": "Alejandro Blanco <alejandro.b.e@gmail.com>",
"homepage": "https://github.com/ablanco/jquery.pwstrength.bootstrap",
Expand Down
2 changes: 1 addition & 1 deletion src/rules.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ try {
) {
return score;
}
return 0;
return;
};

validation.wordRepetitions = function(options, word, score) {
Expand Down

0 comments on commit 34f4c14

Please sign in to comment.