1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-12-22 19:07:54 +01:00

refactor: description renamed to summary

This commit is contained in:
Nuno Góis 2024-09-20 14:54:53 +01:00
parent a413a38352
commit f07cc2e460
No known key found for this signature in database
GPG Key ID: 71ECC689F1091765
5 changed files with 8 additions and 9 deletions

View File

@ -13,7 +13,7 @@ import {
export type EnrichedEvent = EventSchema & {
label: string;
description: string;
summary: string;
};
const StyledRow = styled('div')({

View File

@ -44,7 +44,7 @@ export const EventTimelineEventTooltip = ({
<StyledTooltipTitle>{event.label}</StyledTooltipTitle>
<StyledDateTime>{eventDateTime}</StyledDateTime>
</StyledTooltipHeader>
<Markdown>{event.description}</Markdown>
<Markdown>{event.summary}</Markdown>
</>
);
};

View File

@ -112,13 +112,13 @@ export default class EventSearchController extends Controller {
enrichEvents(events: IEvent[]): IEvent[] | IEnrichedEvent[] {
if (this.flagResolver.isEnabled('eventTimeline')) {
return events.map((event) => {
const { label, text: description } =
const { label, text: summary } =
this.msgFormatter.format(event);
return {
...event,
label,
description,
summary,
};
});
}

View File

@ -95,13 +95,12 @@ export const eventSchema = {
label: {
type: 'string',
nullable: true,
description: 'A concise, human-readable name for the event.',
description: 'The concise, human-readable name of the event.',
},
description: {
summary: {
type: 'string',
nullable: true,
description:
'A detailed description of the event, formatted in markdown.',
description: 'A markdown-formatted summary of the event.',
},
},
components: {

View File

@ -376,7 +376,7 @@ export interface IEvent extends Omit<IBaseEvent, 'ip'> {
export interface IEnrichedEvent extends IEvent {
label: string;
description: string;
summary: string;
}
export interface IEventList {