feat(adrs): display associated entity in AdrSearchResultListItem

Signed-off-by: Phil Kuang <pkuang@factset.com>
This commit is contained in:
Phil Kuang
2022-08-08 15:30:25 -04:00
parent af1e11b744
commit bfc7c50a09
7 changed files with 33 additions and 0 deletions
@@ -142,6 +142,7 @@ export class DefaultAdrCollatorFactory implements DocumentCollatorFactory {
'metadata.annotations',
'metadata.name',
'metadata.namespace',
'metadata.title',
],
},
{ token },
@@ -16,6 +16,7 @@
import { DateTime } from 'luxon';
import { marked } from 'marked';
import { stringifyEntityRef } from '@backstage/catalog-model';
import { MADR_DATE_FORMAT } from '@backstage/plugin-adr-common';
import { AdrParser } from './types';
@@ -101,6 +102,8 @@ export const createMadrParser = (
text: content,
status: adrStatus,
date: adrDate,
entityRef: stringifyEntityRef(entity),
entityTitle: entity.metadata.title,
location: applyArgsToFormat(locationTemplate, {
namespace: entity.metadata.namespace || 'default',
kind: entity.kind,