import _extends from "@babel/runtime/helpers/extends";
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";

/**
 * HTML Element
 *
 */
import React from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import E from './Element';

const H1 = (_ref) => {
  let {
    style_type,
    className
  } = _ref,
      p = _objectWithoutProperties(_ref, ["style_type", "className"]);

  if (style_type) {
    className = classnames("dnb-h1--".concat(style_type), className);
  }

  return React.createElement(E, _extends({
    is: "h1"
  }, p, {
    className: className
  }));
};

H1.tagName = 'dnb-h1';
H1.propTypes = process.env.NODE_ENV !== "production" ? {
  className: PropTypes.string,
  style_type: PropTypes.string
} : {};
H1.defaultProps = {
  className: null,
  style_type: null
};
export default H1;