Skip to content

Commit

Permalink
Merge pull request #491 from rsandell/prototype_removal
Browse files Browse the repository at this point in the history
Prepare for prototype removal
  • Loading branch information
raul-arabaolaza authored Oct 26, 2023
2 parents b83506d + cabf86d commit 5ec13ee
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<f:form action="createDomain" method="POST" name="newDomain">
<f:entry title="${%Domain Name}" help="/plugin/credentials/help/domain/name.html">
<f:textbox id="name" field="name" onchange="updateOk(this.form)" onkeyup="updateOk(this.form)"/>
<script>$('name').focus();</script>
<script>document.getElementById('name').focus();</script>
</f:entry>
<f:entry title="${%Description}" help="/plugin/credentials/help/domain/description.html">
<f:textarea name="description"/>
Expand All @@ -47,11 +47,11 @@
</f:bottomButtonBar>
</f:form>
<script><![CDATA[
var okButton = makeButton($('ok'), null);
var okButton = makeButton(document.getElementById('ok'), null);
function updateOk(form) {
function state() {
return ($('name').value.length === 0);
return (document.getElementById('name').value.length === 0);
}
okButton.set('disabled', state(), false);
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/lib/credentials/dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ Behaviour.specify("#credentials-add-submit", 'credentials-dialog-add', 0, functi
});

Behaviour.specify("#credentials-add-abort", 'credentials-dialog-abort', 0, function (e) {
e.onclick = (_) => window.credentials.dialog.hide();
e.onclick = (_) => window.credentials.dialog.style.display = "none";
});

0 comments on commit 5ec13ee

Please sign in to comment.