# All files / src/Link Link.tsx

100% Statements 7/7
100% Branches 0/0
100% Functions 1/1
100% Lines 6/6

Press n or j to go to the next uncovered block, b, p or k for the previous block.

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    319x
    9x

    9x
    46x
    46x

    9x
     import React from 'react'
    import { StyledLink } from './Link.styles'
    import { LinkProps } from './Link.types'

    /**

     Links provide users with quick references to relevant Procore or affiliate
     websites that will provide more contextual information to a page or feature.

     Links should not be used to reference a page or modal in Procore’s product.
     In that case, use a button.

     @since 10.19.0

     @see [Storybook](https://procore.github.io/core/core-react/latest/?path=/story/demos-link--demo)

     @see [Design Guidelines](https://design.procore.com/link)

     */
    export const Link = React.forwardRef<HTMLAnchorElement, LinkProps>(
      ({ children, ...props }, ref) => {
        return (
          <StyledLink {...props} ref={ref}>
            {children}
          </StyledLink>
        )
      }
    )

    Link.displayName = 'Link'