File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 1- import { Component , HostBinding } from "@angular/core" ;
1+ import {
2+ Component ,
3+ Output ,
4+ EventEmitter ,
5+ HostBinding
6+ } from "@angular/core" ;
27import { Tag } from "./tag.component" ;
38
49@Component ( {
510 selector : "ibm-tag-filter" ,
611 template : `
712 <ng-content></ng-content>
813 <svg
14+ (click)="close.emit()"
915 focusable="false"
1016 preserveAspectRatio="xMidYMid meet"
1117 style="will-change: transform;"
@@ -20,6 +26,11 @@ import { Tag } from "./tag.component";
2026 `
2127} )
2228export class TagFilter extends Tag {
29+ /**
30+ * Function for close/delete the tag
31+ */
32+ @Output ( ) close = new EventEmitter < any > ( ) ;
33+
2334 @HostBinding ( "attr.class" ) get attrClass ( ) {
2435 return `bx--tag bx--tag--filter bx--tag--${ this . type } ${ this . class } ` ;
2536 }
You can’t perform that action at this time.
0 commit comments