Skip to content

Commit

Permalink
fix: fix logo gutter bg
Browse files Browse the repository at this point in the history
  • Loading branch information
RomanHotsiy committed May 13, 2019
1 parent 4c59628 commit 81896d3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
### Bug Fixes

* crash in node due to broken URL parsing ([8df2b97](https://github.com/Rebilly/ReDoc/commit/8df2b97))
* fix: fix logo gutter bg ([e43f7219](https://github.com/Rebilly/ReDoc/commit/e43f7219))



Expand Down
12 changes: 5 additions & 7 deletions src/components/ApiLogo/ApiLogo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,11 @@ export class ApiLogo extends React.Component<{ info: OpenAPIInfo }> {
// Use the english word logo if no alt text is provided
const altText = logoInfo.altText ? logoInfo.altText : 'logo';

const logo = (
<LogoImgEl
src={logoInfo.url}
style={{ backgroundColor: logoInfo.backgroundColor }}
alt={altText}
/>
const logo = <LogoImgEl src={logoInfo.url} alt={altText} />;
return (
<LogoWrap style={{ backgroundColor: logoInfo.backgroundColor }}>
{logoHref ? LinkWrap(logoHref)(logo) : logo}
</LogoWrap>
);
return <LogoWrap>{logoHref ? LinkWrap(logoHref)(logo) : logo}</LogoWrap>;
}
}

0 comments on commit 81896d3

Please sign in to comment.