HEX
Server: Apache
System: Linux webm020.cluster127.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64
User: bohousj (181416)
PHP: 8.4.22
Disabled: _dyuweyrj4,_dyuweyrj4r,dl
Upload Files
File: /home/bohousj/www/wp-content/plugins/envato-elements/src/js/react/components/Buttons/Button.jsx
import React from 'react'
import PropTypes from 'prop-types'
import ButtonIconAndLabel from './ButtonIconAndLabel'
import ButtonElement from './ButtonElement'

const Button = ({ type, label, icon, onClick, disabled, dataTestId }) => {
  return (
    <ButtonElement element='button' type={type} onClick={onClick} disabled={disabled} dataTestId={dataTestId}>
      <ButtonIconAndLabel label={label} icon={icon} />
    </ButtonElement>
  )
}

Button.propTypes = {
  type: PropTypes.string,
  label: PropTypes.string,
  icon: PropTypes.string,
  onClick: PropTypes.func,
  disabled: PropTypes.bool,
  dataTestId: PropTypes.string
}

Button.defaultProps = {
  type: 'ghost',
  label: null,
  icon: null,
  onClick: null,
  disabled: false,
  dataTestId: null
}

export default Button