A Metamask fork with Infura removed and default networks editable
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
ciphermask/ui/components/component-library/button-link/button-link.js

45 lines
1.1 KiB

import React from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import { ButtonBase } from '../button-base';
import { COLORS } from '../../../helpers/constants/design-system';
import { BUTTON_LINK_SIZES } from './button-link.constants';
export const ButtonLink = ({
className,
danger,
size = BUTTON_LINK_SIZES.MD,
...props
}) => {
return (
<ButtonBase
className={classnames(className, 'mm-button-link', {
'mm-button-link--type-danger': danger,
})}
size={size}
backgroundColor={COLORS.TRANSPARENT}
{...props}
/>
);
};
ButtonLink.propTypes = {
/**
* An additional className to apply to the ButtonLink.
*/
className: PropTypes.string,
/**
* Boolean to change button type to Danger when true
*/
danger: PropTypes.bool,
/**
* Possible size values: 'SIZES.AUTO', 'SIZES.SM'(32px), 'SIZES.MD'(40px), 'SIZES.LG'(48px).
* Default value is 'SIZES.MD'.
*/
size: PropTypes.oneOf(Object.values(BUTTON_LINK_SIZES)),
/**
* ButtonLink accepts all the props from ButtonBase
*/
...ButtonBase.propTypes,
};