ALink.tsx 515 B

12345678910111213141516171819202122232425262728
  1. import styled from "styled-components";
  2. import { Box, BoxProps } from "reflexbox/styled-components";
  3. interface Props extends BoxProps {
  4. href?: string;
  5. title?: string;
  6. target?: string;
  7. rel?: string;
  8. }
  9. const ALink = styled(Box).attrs({
  10. as: "a"
  11. })<Props>`
  12. cursor: pointer;
  13. color: #2196f3;
  14. border-bottom: 1px dotted transparent;
  15. text-decoration: none;
  16. transition: all 0.2s ease-out;
  17. :hover {
  18. border-bottom-color: #2196f3;
  19. }
  20. `;
  21. ALink.defaultProps = {
  22. pb: "1px"
  23. };
  24. export default ALink;