diff --git a/plugins/adr-backend/api-report.md b/plugins/adr-backend/api-report.md index 5a671e9c8f..24e54e8eb5 100644 --- a/plugins/adr-backend/api-report.md +++ b/plugins/adr-backend/api-report.md @@ -11,6 +11,7 @@ import { CatalogApi } from '@backstage/catalog-client'; import { Config } from '@backstage/config'; import { DocumentCollatorFactory } from '@backstage/plugin-search-common'; import { Entity } from '@backstage/catalog-model'; +import express from 'express'; import { Logger } from 'winston'; import { PluginCacheManager } from '@backstage/backend-common'; import { PluginEndpointDiscovery } from '@backstage/backend-common'; @@ -44,6 +45,9 @@ export type AdrParserContext = { // @public export const createMadrParser: (options?: MadrParserOptions) => AdrParser; +// @public (undocumented) +export function createRouter(reader: UrlReader): Promise; + // @public export class DefaultAdrCollatorFactory implements DocumentCollatorFactory { // (undocumented) diff --git a/plugins/adr/api-report.md b/plugins/adr/api-report.md index ecec0c0dd5..99d3e537a3 100644 --- a/plugins/adr/api-report.md +++ b/plugins/adr/api-report.md @@ -20,6 +20,14 @@ export type AdrContentDecorator = (adrInfo: { content: string; }; +// @public +export interface AdrFileFetcher { + // Warning: (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen + useGetAdrFilesAtUrl: (url: string) => any; + // Warning: (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen + useReadAdrFileAtUrl: (url: string) => any; +} + // @public export const adrPlugin: BackstagePlugin< { @@ -31,7 +39,11 @@ export const adrPlugin: BackstagePlugin< // @public export const AdrReader: { - (props: { adr: string; decorators?: AdrContentDecorator[] }): JSX.Element; + (props: { + adr: string; + decorators?: AdrContentDecorator[]; + adrFileFetcher?: AdrFileFetcher; + }): JSX.Element; decorators: Readonly<{ createRewriteRelativeLinksDecorator(): AdrContentDecorator; createRewriteRelativeEmbedsDecorator(): AdrContentDecorator; @@ -50,7 +62,14 @@ export function AdrSearchResultListItem(props: { export const EntityAdrContent: (props: { contentDecorators?: AdrContentDecorator[] | undefined; filePathFilterFn?: AdrFilePathFilterFn | undefined; + adrFileFetcher?: AdrFileFetcher | undefined; }) => JSX.Element; export { isAdrAvailable }; + +// @public +export const octokitAdrFileFetcher: AdrFileFetcher; + +// @public +export const urlReaderAdrFileFetcher: AdrFileFetcher; ```