@@ -46,7 +46,7 @@ import type {
4646 DocFencedCode ,
4747 DocComment ,
4848} from '@microsoft/tsdoc' ;
49- import type { DeclarationReference } from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference.js' ;
49+ import type { DeclarationReference , ModuleSource } from '@microsoft/tsdoc/lib-commonjs/beta/DeclarationReference.js' ;
5050import { BuiltinDocumentationLinks } from './builtinDocumentationLinks.js' ;
5151import { PACKAGES , fetchVersionDocs , fetchVersions } from './shared.js' ;
5252
@@ -147,6 +147,9 @@ function resolveCanonicalReference(
147147 containerKey : `|${
148148 canonicalReference . symbol . meaning
149149 } |${ canonicalReference . symbol . componentPath . component . toString ( ) } `,
150+ getAssociatedEntryPoint ( ) {
151+ return canonicalReference . source as ModuleSource ;
152+ } ,
150153 } ,
151154 // eslint-disable-next-line unicorn/better-regex
152155 version : apiPackage ?. dependencies ?. [ canonicalReference . source . packageName ] ?. replace ( / [ ~ ^ ] / , '' ) ,
@@ -167,6 +170,9 @@ function resolveCanonicalReference(
167170 members : canonicalReference . memberReferences
168171 . slice ( 1 )
169172 . map ( ( member ) => ( { kind : member . kind , displayName : member . memberIdentifier ! . identifier ! } ) ) ,
173+ getAssociatedEntryPoint ( ) {
174+ return canonicalReference ;
175+ } ,
170176 } ,
171177 // eslint-disable-next-line unicorn/better-regex
172178 version : apiPackage ?. dependencies ?. [ canonicalReference . packageName ?? '' ] ?. replace ( / [ ~ ^ ] / , '' ) ,
@@ -204,10 +210,14 @@ export function hasEvents(item: ApiItemContainerMixin) {
204210 return resolveMembers ( item , memberPredicate ) . some ( ( { item : member } ) => member . kind === ApiItemKind . Event ) ;
205211}
206212
213+ interface ApiEntryPointLike {
214+ importPath : string | undefined ;
215+ }
216+
207217interface ApiItemLike {
208218 containerKey ?: string ;
209219 displayName : string ;
210- getAssociatedEntryPoint ?( ) : ApiEntryPoint | undefined ;
220+ getAssociatedEntryPoint ?( ) : ApiEntryPointLike | undefined ;
211221 kind : string ;
212222 members ?: readonly ApiItemLike [ ] ;
213223 parent ?: ApiItemLike | undefined ;
0 commit comments