@bdt-component-library/link

0.5.9 • Public • Published

Link Component

About

This is a component published as its own package from our component library monorepo: https://github.com/BenefitsDataTrust/ui-components. Setup instructions, as well as higher-level goals and concerns can be found from the main project README.

Description

Handles display of links according to style guide conventions.

API

prop type required default explanation
className string no "" Adds an optional classname to the component
children React node yes n/a The inner content of the component
url string yes n/a The href for the link
role string no "" The role attr for the link
isExternal boolean no false Affects the rel, target, and visual distinctions for external links
isTruncated boolean no false Changes styles to use truncation
isActive boolean no true Changes styles to inactive
isUnderlined boolean no true Determines whether or not to use underline with link
display enum("default", "light", "white") no "default" Changes the foreground/background color mode
onClick function(e: event) no () => {} Function executed in place of default a tag behavoir for internal redirects

/@bdt-component-library/link/

    Package Sidebar

    Install

    npm i @bdt-component-library/link

    Weekly Downloads

    2

    Version

    0.5.9

    License

    MIT

    Unpacked Size

    3.31 MB

    Total Files

    12

    Last publish

    Collaborators

    • benefitsdatatrust
    • gabrielliwerant