Forms: Add support for form hotkeys

Adds JavaScript support to monitor keypresses or mouse events
of forms with the classes .form-hotkey-enter or form-hotkey-double-click,
and trigger the click event of the button with the CSS class
.btn-hotkey-default.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2018-11-25 01:32:22 -04:00
parent 8e896a54f9
commit e72b4e82a3
4 changed files with 25 additions and 9 deletions
+1 -1
View File
@@ -356,7 +356,7 @@ class UploadInteractiveView(UploadBaseView):
kwargs=self.request.resolver_match.kwargs
), self.request.META['QUERY_STRING']
),
'form_class': 'dropzone',
'form_css_classes': 'dropzone',
'form_disable_submit': True,
'form_id': 'html5upload',
}