Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement/hashtype autocomplete #781

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
- Tasks can be set to top priority (to be first in the list) by the User API.
- Supertask runtime can be estimated on the supertask detail page by entering expected attack speeds for hashcat wordlist and bruteforce attacks
- Number of agents per task can be limited (pull request #764).
- Added hashtype dropdown autocompletion for creating new hashlists (pull request #781)

## Bugfixes

Expand Down
3 changes: 3 additions & 0 deletions src/static/select2-bootstrap-5.dark.min.css

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions src/static/select2-bootstrap-5.min.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/static/select2.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions src/static/select2.min.js

Large diffs are not rendered by default.

10 changes: 10 additions & 0 deletions src/templates/hashlists/new.template.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,16 @@ <h2>New hashlist</h2>
$("#hashlistFormat option[value='1']").prop('selected', false);
}
}

// Initialize select2
$(document).ready(function() {
$('#hashtype').select2({
width: '100%'
});
}) // Set focus to the select2 search field when opening the select2 element
.on('select2:open', () => {
setTimeout(() => document.querySelector('.select2-container--open .select2-search__field').focus(), 100);
});
</script>
<form class='form-inline' action="hashlists.php" method="POST" enctype="multipart/form-data">
<input type='hidden' name='action' value='[[$DHashlistAction::CREATE_HASHLIST]]'>
Expand Down
Loading