File tree Expand file tree Collapse file tree
sourcegraph/stream-search Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ This may be an issue with your configuration - try updating the Sourcegraph exte
7676 >
7777 { /* show suggestions IFF no results */ }
7878 { ! state . isLoading && state . results . length === 0 ? (
79- < List . Section title = "Suggestions" subtitle = { state . summary || '' } >
79+ < List . Section title = "Suggestions" subtitle = { state . summary || "" } >
8080 { state . suggestions . slice ( 0 , 3 ) . map ( ( suggestion ) => (
8181 < SuggestionItem key = { randomId ( ) } suggestion = { suggestion } />
8282 ) ) }
@@ -172,7 +172,7 @@ function SearchResultItem({
172172 icon . tintColor = Color . Yellow ;
173173 }
174174 title = match . repository ;
175- subtitle = match . description || '' ;
175+ subtitle = match . description || "" ;
176176 context = match . repoStars ? `${ match . repoStars } stars` : "" ;
177177 break ;
178178 case "commit" :
Original file line number Diff line number Diff line change @@ -81,15 +81,17 @@ export async function performSearch(
8181 } ;
8282
8383 handlers . onResults (
84- event . data . map ( ( match ) : SearchResult => {
85- const url = `${ src . instance } ${ getMatchUrl ( match ) } ` ;
86- if ( match . type === "commit" ) {
87- // Commit stuff comes already markdown-formatted?? so strip formatting
88- match . label = stripMarkdown . processSync ( match . label ) ?. value . toString ( ) . split ( `› ` ) . pop ( ) || "" ;
89- match . detail = stripMarkdown . processSync ( match . detail ) ?. value . toString ( ) ;
84+ event . data . map (
85+ ( match ) : SearchResult => {
86+ const url = `${ src . instance } ${ getMatchUrl ( match ) } ` ;
87+ if ( match . type === "commit" ) {
88+ // Commit stuff comes already markdown-formatted?? so strip formatting
89+ match . label = stripMarkdown . processSync ( match . label ) ?. value . toString ( ) . split ( `› ` ) . pop ( ) || "" ;
90+ match . detail = stripMarkdown . processSync ( match . detail ) ?. value . toString ( ) ;
91+ }
92+ return { url, match } ;
9093 }
91- return { url, match } ;
92- } )
94+ )
9395 ) ;
9496 } ) ;
9597
You can’t perform that action at this time.
0 commit comments