1
0
mirror of https://gitlab.com/timvisee/send.git synced 2024-09-23 17:41:33 +02:00
send/app/templates/downloadButton/index.js
2018-02-15 15:54:59 -08:00

16 lines
334 B
JavaScript

const html = require('choo/html');
module.exports = function(state, emit) {
function download(event) {
event.preventDefault();
emit('download', state.fileInfo);
}
return html`
<div>
<button class="btn btn--download"
onclick=${download}>${state.translate('downloadButtonLabel')}
</button>
</div>`;
};