File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -67,6 +67,13 @@ export abstract class Button extends buttonBaseClass implements FormSubmitter {
67
67
*/
68
68
@property ( ) href = '' ;
69
69
70
+ /**
71
+ * The filename to use when downloading the linked resource.
72
+ * If not specified, the browser will determine a filename.
73
+ * This is only applicable when the button is used as a link (`href` is set).
74
+ */
75
+ @property ( ) downloadFilename = '' ;
76
+
70
77
/**
71
78
* Where to display the linked `href` URL for a link button. Common options
72
79
* include `_blank` to open in a new tab.
@@ -184,6 +191,7 @@ export abstract class Button extends buttonBaseClass implements FormSubmitter {
184
191
aria-haspopup ="${ ariaHasPopup || nothing } "
185
192
aria-expanded ="${ ariaExpanded || nothing } "
186
193
href =${ this . href }
194
+ download =${ this . downloadFilename || nothing }
187
195
target=${ this . target || nothing }
188
196
> ${ this . renderContent ( ) }
189
197
</ a > ` ;
You can’t perform that action at this time.
0 commit comments