Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions resources/js/components/commit-search-results.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ export function SearchResults({
isWaiting = false,
heading = 'Most relevant commits',
empty = 'Try describing the idea in other words, or pick one of the searches below.',
isStandalone = false,
}: {
results: SearchResultSet | null;
isWaiting?: boolean;
heading?: string;
empty?: ReactNode;
isStandalone?: boolean;
}) {
if (results === null) {
return (
Expand Down Expand Up @@ -57,6 +59,16 @@ export function SearchResults({
) : (
<GraphCanvas>
{results.commits.map((commit, index) => {
if (isStandalone) {
return (
<CommitCard
key={commit.id}
commit={commit}
endsWithDot
/>
);
}

const previous = results.commits[index - 1];

return (
Expand Down
1 change: 1 addition & 0 deletions resources/js/pages/headline/show.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export default function Show({
results={results}
heading="What nullers have been saying"
empty="No matching commits from the past week."
isStandalone
/>
</>
);
Expand Down