divider.tsx 584 B

1234567891011121314151617181920212223242526272829
  1. import styled from '@emotion/styled';
  2. import {IconChevron} from 'sentry/icons';
  3. type Props = {
  4. isHover?: boolean;
  5. isLast?: boolean;
  6. };
  7. function Divider({isHover, isLast}: Props) {
  8. return isLast ? null : (
  9. <StyledDivider>
  10. <StyledIconChevron direction={isHover ? 'down' : 'right'} legacySize="14px" />
  11. </StyledDivider>
  12. );
  13. }
  14. const StyledIconChevron = styled(IconChevron)`
  15. display: block;
  16. `;
  17. const StyledDivider = styled('span')`
  18. display: inline-block;
  19. margin-left: 6px;
  20. color: ${p => p.theme.gray200};
  21. position: relative;
  22. `;
  23. export default Divider;