Skip to content

Commit 902a84f

Browse files
committed
feat(chip): add download attribute to assist chip
1 parent 8aefe19 commit 902a84f

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

chips/internal/assist-chip.ts

+7
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ import {Chip} from './chip.js';
1919
export class AssistChip extends Chip {
2020
@property({type: Boolean}) elevated = false;
2121
@property() href = '';
22+
/**
23+
* The filename to use when downloading the linked resource.
24+
* If not specified, the browser will determine a filename.
25+
* This is only applicable when the chip is used as a link (`href` is set).
26+
*/
27+
@property() download = '';
2228
@property() target: '_blank' | '_parent' | '_self' | '_top' | '' = '';
2329

2430
protected get primaryId() {
@@ -49,6 +55,7 @@ export class AssistChip extends Chip {
4955
id="link"
5056
aria-label=${ariaLabel || nothing}
5157
href=${this.href}
58+
download=${this.download || nothing}
5259
target=${this.target || nothing}
5360
>${content}</a
5461
>

0 commit comments

Comments
 (0)