Skip to content

Commit

Permalink
fix: search in JSX doc.description
Browse files Browse the repository at this point in the history
  • Loading branch information
atanasster committed Nov 16, 2020
1 parent bd2dca6 commit e142ad3
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions ui/blocks/src/Search/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ interface SearchObject {
id: string;
title: string;
type: string;
description?: string | JSX.Element;
description?: string;
body?: string;
author?: string;
stories?: string[];
Expand All @@ -42,7 +42,10 @@ export const Search: FC<Omit<
id: page.title,
title: page.title.replace('/', ' '),
type: page.type || defDocType,
description: page.description,
description:
typeof page.description === 'string'
? page.description
: undefined,
body: page.source,
author: page.author,
stories: page.stories?.map(story => story.split('-').join(' ')),
Expand Down

0 comments on commit e142ad3

Please sign in to comment.