Describe the bug
calling clear method of SohoToolbarFlexSearchFieldComponent or SohoToolbarSearchFieldComponent results in
for SohoToolbarFlexSearchFieldComponent
ERROR TypeError: Cannot read property 'clear' of undefined
at ids-enterprise-ng.js:19407
at ZoneDelegate.invoke (zone-evergreen.js:359)
at Zone.run (zone-evergreen.js:124)
at NgZone.runOutsideAngular (core.js:39572)
at SohoToolbarSearchFieldComponent.clear (ids-enterprise-ng.js:19407)
at ViewToolbarComponent.set searchTerm [as searchTerm] (view-toolbar.component.ts:41)
at updateProp (core.js:32189)
at checkAndUpdateDirectiveInline (core.js:31867)
at checkAndUpdateNodeInline (core.js:44367)
at checkAndUpdateNode (core.js:44306)
and for SohoToolbarSearchFieldComponent
OverviewComponent.html:1 ERROR TypeError: Cannot read property 'clear' of undefined
at ids-enterprise-ng.js:19407
at ZoneDelegate.invoke (zone-evergreen.js:359)
at Zone.run (zone-evergreen.js:124)
at NgZone.runOutsideAngular (core.js:39572)
at SohoToolbarSearchFieldComponent.clear (ids-enterprise-ng.js:19407)
at ViewToolbarComponent.set searchTerm [as searchTerm] (view-toolbar.component.ts:41)
at updateProp (core.js:32189)
at checkAndUpdateDirectiveInline (core.js:31867)
at checkAndUpdateNodeInline (core.js:44367)
at checkAndUpdateNode (core.js:44306)
To Reproduce
Steps to reproduce the behavior:
@ViewChild(SohoToolbarFlexSearchFieldComponent) component: SohoToolbarFlexSearchFieldComponent;
ngAfterViewInit() {
setTimeout(() => {
this.component.clear();
}, 5 * 1000);
}
Expected behavior
A clear and concise description of what you expected to happen.
Version
Screenshots
If applicable, add screenshots to help explain your problem.
Platform
Additional context
Add any other context about the problem here.
also when ngModel used and value set to an empty string, the clear icon stays

Interesting... We just added this to the EP component https://github.com/infor-design/enterprise/pull/4048
So this should now be there. But not sure why the type was there before.
Assigning @ericangeles to take a look this sprint sometime as this was recently completed
@tmcconechy @Fruko I've tried this and it's working when calling it on afterInit. I'll create a test page for this. I basically just clean the dependencies and install it again.
This issue is now resolved.