Moved javascript from template button.html to button.js