How to build Stencil component library (Angular) with ionic components

We have a Stencil project for building an angular component library using ionic components.
We are importing import ‘@ionic/core’; globally. The web component build passes. But the angular build fails with the following error.

2461 export declare interface IonRow extends Components.IonRow {}
projects/component-library/src/lib/stencil-generated/components.ts:2486:15 - error TS2305: Module ‘“ii-web-components-stencil/components”’ has no exported member ‘SearchbarChangeEventDetail’.