diff --git a/plugins/catalog/api-report.md b/plugins/catalog/api-report.md index bef24b50d8..e2225f5ba6 100644 --- a/plugins/catalog/api-report.md +++ b/plugins/catalog/api-report.md @@ -245,6 +245,9 @@ export interface DefaultCatalogPageProps { tableOptions?: TableProps['options']; } +// @public (undocumented) +export const defaultColumnsFunc: CatalogTableColumnsFunc; + // @public export class DefaultEntityPresentationApi implements EntityPresentationApi { static create( diff --git a/plugins/catalog/src/components/CatalogTable/CatalogTable.tsx b/plugins/catalog/src/components/CatalogTable/CatalogTable.tsx index 006210bb1d..c68e1b06a6 100644 --- a/plugins/catalog/src/components/CatalogTable/CatalogTable.tsx +++ b/plugins/catalog/src/components/CatalogTable/CatalogTable.tsx @@ -77,7 +77,11 @@ const refCompare = (a: Entity, b: Entity) => { return toRef(a).localeCompare(toRef(b)); }; -const defaultColumnsFunc: CatalogTableColumnsFunc = ({ filters, entities }) => { +/** @public */ +export const defaultColumnsFunc: CatalogTableColumnsFunc = ({ + filters, + entities, +}) => { const showTypeColumn = filters.type === undefined; return [ diff --git a/plugins/catalog/src/components/CatalogTable/index.ts b/plugins/catalog/src/components/CatalogTable/index.ts index f5d1ca1bb7..e1d96a6f8f 100644 --- a/plugins/catalog/src/components/CatalogTable/index.ts +++ b/plugins/catalog/src/components/CatalogTable/index.ts @@ -14,6 +14,6 @@ * limitations under the License. */ -export { CatalogTable } from './CatalogTable'; +export { CatalogTable, defaultColumnsFunc } from './CatalogTable'; export type { CatalogTableProps } from './CatalogTable'; export type { CatalogTableRow, CatalogTableColumnsFunc } from './types';