mirror of
https://github.com/nprasad2077/nbaStats.git
synced 2026-11-12 12:54:14 +00:00
Configure static files for Heroku deployment
This commit is contained in:
1 parent
92f2e31e02
commit
6ddc41ea51
627 files changed
+72389
-9
No files matched your search
@@ -0,0 +1,16 @@
|
||||
'use strict';
|
||||
{
|
||||
const inputTags = ['BUTTON', 'INPUT', 'SELECT', 'TEXTAREA'];
|
||||
const modelName = document.getElementById('django-admin-form-add-constants').dataset.modelName;
|
||||
if (modelName) {
|
||||
const form = document.getElementById(modelName + '_form');
|
||||
for (const element of form.elements) {
|
||||
// HTMLElement.offsetParent returns null when the element is not
|
||||
// rendered.
|
||||
if (inputTags.includes(element.tagName) && !element.disabled && element.offsetParent) {
|
||||
element.focus();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user