Skip to content

Commit

Permalink
guide title styles
Browse files Browse the repository at this point in the history
  • Loading branch information
Scott Byrne committed Aug 7, 2020
1 parent 077e52a commit ecdea51
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions components/search/hitComps.tsx
Expand Up @@ -23,11 +23,13 @@ const GuideHit = (clickHandler: any) => ({ hit }: { hit: Hit }) => (
<DynamicLink href={path.join('/guides', (hit as any).slug)}>
<div onClick={clickHandler}>
<h4>
{hit.guideTitle && (
<GuideTitle>
<Highlight attribute="guideTitle" hit={hit} tagName="mark" />
</GuideTitle>
)}
<Highlight attribute="title" hit={hit} tagName="mark" />
</h4>
<GuideTitle>
<Highlight attribute="guideTitle" hit={hit} tagName="mark" />
</GuideTitle>
{hit['_highlightResult'].excerpt.matchLevel !== 'none' && (
<Highlight attribute="excerpt" hit={hit} tagName="mark" />
)}
Expand All @@ -36,14 +38,11 @@ const GuideHit = (clickHandler: any) => ({ hit }: { hit: Hit }) => (
)

const GuideTitle = styled.div`
margin-top: -0.5rem;
+ * {
margin-top: 1rem;
display: block;
}
[class*='Highlight'] {
font-size: 0.8rem;
font-style: italic;
display: inline;
&:after {
content: ' - ';
display: inline-block;
margin: 0 0.25rem;
}
`

Expand Down

1 comment on commit ecdea51

@vercel
Copy link

@vercel vercel bot commented on ecdea51 Aug 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The deployment has failed to due an unexpected error within Vercel (your source code is not at fault).

Our team has been notified and will resolve the issue shortly.

Please sign in to comment.