Fix dropdowns and charts UI issues
Most notably, fixes issues where dropdowns can't be used and charts aren't displayed.
The issues were caused by some javascript files being added multiple times by Horizon's JS static list (HORIZON_CONFIG.js_files) builder. As a solution, the JS script builder algorithm was overwritten.