headerWithHelp.tsx 844 B

1234567891011121314151617181920212223242526272829303132333435
  1. import styled from '@emotion/styled';
  2. import Button from 'sentry/components/actions/button';
  3. import LogoSentry from 'sentry/components/logoSentry';
  4. import {t} from 'sentry/locale';
  5. import {space} from 'sentry/styles/space';
  6. export default function HeaderWithHelp({docsUrl}: {docsUrl: string}) {
  7. return (
  8. <Header>
  9. <StyledLogoSentry />
  10. <Button external href={docsUrl} size="xs">
  11. {t('Need Help?')}
  12. </Button>
  13. </Header>
  14. );
  15. }
  16. const Header = styled('div')`
  17. width: 100%;
  18. position: fixed;
  19. display: flex;
  20. justify-content: space-between;
  21. top: 0;
  22. z-index: 100;
  23. padding: ${space(2)};
  24. background: ${p => p.theme.background};
  25. border-bottom: 1px solid ${p => p.theme.innerBorder};
  26. `;
  27. const StyledLogoSentry = styled(LogoSentry)`
  28. width: 130px;
  29. height: 30px;
  30. color: ${p => p.theme.textColor};
  31. `;