Skip to content

Commit

Permalink
Move javascript inline with HTML - PR Feedback
Browse files Browse the repository at this point in the history
Signed-off-by: Philip Corliss <[email protected]>
  • Loading branch information
pcorliss committed Jun 6, 2024
1 parent 6f25e6f commit 8ca20f2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
4 changes: 0 additions & 4 deletions web/static/form.js

This file was deleted.

8 changes: 7 additions & 1 deletion web/templates/password.html
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,12 @@ <h2 class="theme-heading">Log in to Your Account</h2>
{{ end }}
</div>

<script type="text/javascript" src="{{ url .ReqPath "/static/form.js" }}"></script>

<script type="text/javascript">
document.querySelector('form').onsubmit = function(e) {
var el = document.querySelector('#submit-login');
el.setAttribute('disabled', 'disabled');
};
</script>

{{ template "footer.html" . }}

0 comments on commit 8ca20f2

Please sign in to comment.