Skip to content

Commit 05189ca

Browse files
committed
feat(typerenderer): downloadLink add filename option to decide downloaded filename
1 parent 95900c9 commit 05189ca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/src/util/typerenderer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ define([
356356
var title = options && options.title;
357357
title = title || 'Download resource';
358358

359-
$element.html(`<a download title="${title}" href="${value}">⤵</a>`);
359+
$element.html(`<a download${options.filename ? ('=' + options.filename): ''} title="${title}" href="${value}">⤵</a>`);
360360
};
361361

362362
functions.openlink = {};

0 commit comments

Comments
 (0)