Skip to content

Commit

Permalink
fix: add skinChange output onto picker component, fire on skin select
Browse files Browse the repository at this point in the history
  • Loading branch information
scttcper committed Sep 6, 2018
1 parent 0e8e873 commit b2b7d24
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/lib/picker/picker.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ export class PickerComponent implements OnInit {
@Input() searchIcons = icons.search;
@Output() emojiClick = new EventEmitter<any>();
@Output() emojiSelect = new EventEmitter<any>();
@Output() skinChange = new EventEmitter<Emoji['skin']>();
@ViewChild('scrollRef') private scrollRef!: ElementRef;
@ViewChild('previewRef') private previewRef!: PreviewComponent;
@ViewChild('searchRef') private searchRef!: SearchComponent;
Expand Down Expand Up @@ -375,5 +376,6 @@ export class PickerComponent implements OnInit {
handleSkinChange(skin: Emoji['skin']) {
this.skin = skin;
localStorage.setItem(`${this.NAMESPACE}.skin`, String(skin));
this.skinChange.emit(skin);
}
}

0 comments on commit b2b7d24

Please sign in to comment.