Closed sam3365 closed 4 years ago
Hi @steve1mercury This is really basic Angular functionality, so I will not get into details. Some hints:
<mat-search-bar (onBlur)="yourOnBlurFunction($event)"></mat-search-bar>
@ViewChild
-decorator:
@ViewChild(MatSearchBar) matSearchBar;
...
yourFunction() { if (this.matSearchBar.searchVisible) doSomething(); else this.matSearchBar.open(); }
Hope this helps!
Can you provide coding examples how to:
1) Subscribe to the different events (onBlur, onClose, onEnter, onFocus, onOpen) 2) Access the open() and close() public methods from within component typescript code 3) Accessing the searchVisible property.
Thank you.