diff options
author | Hsuan Lee <hsuan@cobinhood.com> | 2019-01-19 18:42:04 +0800 |
---|---|---|
committer | Hsuan Lee <hsuan@cobinhood.com> | 2019-01-19 18:42:04 +0800 |
commit | 7ae38906926dc09bc10670c361af0d2bf0050426 (patch) | |
tree | 5fb10ae366b987db09e4ddb4bc3ba0f75404ad08 /packages/website/ts/components/link.tsx | |
parent | b5fd3c72a08aaa6957917d74c333387a16edf66b (diff) | |
download | dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.tar dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.tar.gz dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.tar.bz2 dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.tar.lz dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.tar.xz dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.tar.zst dexon-sol-tools-7ae38906926dc09bc10670c361af0d2bf0050426.zip |
Update dependency packages
Diffstat (limited to 'packages/website/ts/components/link.tsx')
-rw-r--r-- | packages/website/ts/components/link.tsx | 61 |
1 files changed, 0 insertions, 61 deletions
diff --git a/packages/website/ts/components/link.tsx b/packages/website/ts/components/link.tsx deleted file mode 100644 index a66985acc..000000000 --- a/packages/website/ts/components/link.tsx +++ /dev/null @@ -1,61 +0,0 @@ -import { Link as SmartLink } from '@0x/react-shared'; -import * as React from 'react'; -import styled from 'styled-components'; - -interface LinkInterface { - color?: string; - children?: React.ReactNode | string; - isNoArrow?: boolean; - hasIcon?: boolean | string; - isBlock?: boolean; - isCentered?: boolean; - href?: string; - theme?: { - textColor: string; - }; - shouldOpenInNewTab?: boolean; - target?: string; -} - -export const Link = (props: LinkInterface) => { - const { children, isNoArrow, href } = props; - - return ( - <StyledLink to={href} {...props}> - {children} - {!isNoArrow && ( - <svg width="25" height="25" fill="none" xmlns="http://www.w3.org/2000/svg"> - <path - d="M8.484 5.246l.023 1.411 8.147.053L4.817 18.547l.996.996L17.65 7.706l.052 8.146 1.411.024-.068-10.561-10.561-.069z" - fill="currentColor" - /> - </svg> - )} - </StyledLink> - ); -}; - -// Added this, & + & doesnt really work since we switch with element types... -export const LinkWrap = styled.div` - a + a, - a + button, - button + a { - margin-left: 20px; - } -`; - -const StyledLink = styled(SmartLink)<LinkInterface>` - display: ${props => !props.isBlock && 'inline-flex'}; - color: ${props => props.color || props.theme.linkColor}; - text-align: center; - font-size: 18px; - text-decoration: none; - align-items: center; - - @media (max-width: 768px) { - } - - svg { - margin-left: 3px; - } -`; |