Skip to content

Commit ac223f9

Browse files
committed
Fjerner EntryName komponent
1 parent 88e1c93 commit ac223f9

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

src/components/parts/_legacy/publishing-calendar/PublishingCalendarEntryLegacyPart.tsx

+5-9
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,6 @@ const processEntry = (item: PublishingCalendarEntryProps): PublishingCalendarEnt
5353
};
5454
};
5555

56-
const EntryName = ({ displayName, link }: PublishingCalendarEntryData) => {
57-
return link ? (
58-
<LenkeInline href={link}>{displayName}</LenkeInline>
59-
) : (
60-
<BodyLong>{displayName}</BodyLong>
61-
);
62-
};
63-
6456
export const PublishingCalendarEntryLegacyPart = (props: ContentProps) => {
6557
if (props.type !== ContentType.PublishingCalendarEntry) {
6658
return null;
@@ -78,7 +70,11 @@ export const PublishingCalendarEntryLegacyPart = (props: ContentProps) => {
7870
</Table.DataCell>
7971
<Table.DataCell>
8072
<BodyLong className={style.dateInfo}>{entry.period}</BodyLong>
81-
<EntryName {...entry} />
73+
{entry.link ? (
74+
<LenkeInline href={entry.link}>{entry.displayName}</LenkeInline>
75+
) : (
76+
<BodyLong>{entry.displayName}</BodyLong>
77+
)}
8278
</Table.DataCell>
8379
</Table.Row>
8480
);

0 commit comments

Comments
 (0)