Skip to content

Commit

Permalink
Simplify hide/show logic
Browse files Browse the repository at this point in the history
Signed-off-by: Matt Sicker <boards@gmail.com>
  • Loading branch information
jvz committed Jul 31, 2019
1 parent 223098c commit 786e135
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/main/resources/lib/credentials/select/select.js
Original file line number Diff line number Diff line change
Expand Up @@ -262,13 +262,12 @@ Behaviour.specify("INPUT.credentials-select", 'credentials-select', -100, functi
});
Behaviour.specify("DIV.include-user-credentials", 'include-user-credentials', 0, function (e) {
e.querySelector("input[name='includeUser']").addEventListener('click', function (evt) {
var caution = e.querySelector("span.user-credentials-caution");
var caution = $(e.querySelector("span.user-credentials-caution"));
if (this.checked) {
caution.setAttribute('style', 'display:inline');
caution.show();
} else {
caution.setAttribute('style', 'display:none');
caution.hide();
}
layoutUpdateCallback.call();
});
})
window.setTimeout(function() {
Expand Down

0 comments on commit 786e135

Please sign in to comment.