function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
import React from 'react';
import { StyledH1, StyledH2, StyledH3, StyledLabel, StyledOL, StyledP, StyledUL } from './Semantic.styles';
export var H1 = /*#__PURE__*/React.forwardRef(function H1(props, ref) {
  return /*#__PURE__*/React.createElement(StyledH1, _extends({}, props, {
    ref: ref
  }));
});
export var H2 = /*#__PURE__*/React.forwardRef(function H2(props, ref) {
  return /*#__PURE__*/React.createElement(StyledH2, _extends({}, props, {
    ref: ref
  }));
});
export var H3 = /*#__PURE__*/React.forwardRef(function H3(props, ref) {
  return /*#__PURE__*/React.createElement(StyledH3, _extends({}, props, {
    ref: ref
  }));
});
export var H4 = /*#__PURE__*/React.forwardRef(function H4(props, ref) {
  return /*#__PURE__*/React.createElement(H3, _extends({
    as: "h4"
  }, props, {
    ref: ref
  }));
});
export var H5 = /*#__PURE__*/React.forwardRef(function H5(props, ref) {
  return /*#__PURE__*/React.createElement(H3, _extends({
    as: "h5",
    style: {
      fontSize: '90%'
    }
  }, props, {
    ref: ref
  }));
});
export var H6 = /*#__PURE__*/React.forwardRef(function H6(props, ref) {
  return /*#__PURE__*/React.createElement(H3, _extends({
    as: "h6",
    style: {
      fontSize: '85%'
    }
  }, props, {
    ref: ref
  }));
});
var UnknownHeading = /*#__PURE__*/React.forwardRef(function UnknownHeading(props, ref) {
  return /*#__PURE__*/React.createElement("strong", _extends({}, props, {
    ref: ref
  }));
});
var levelToComponent = {
  '1': H1,
  '2': H2,
  '3': H3,
  '4': H4,
  '5': H5,
  '6': H6
};

/**
 * @param level 1 - 6
 * @returns H1 - H6 component
 */
export function getHeadingComponent(level) {
  // @ts-ignore
  return levelToComponent[String(level)] || UnknownHeading;
}
export var P = /*#__PURE__*/React.forwardRef(function P(props, ref) {
  return /*#__PURE__*/React.createElement(StyledP, _extends({}, props, {
    ref: ref
  }));
});
export var UL = /*#__PURE__*/React.forwardRef(function UL(props, ref) {
  return /*#__PURE__*/React.createElement(StyledUL, _extends({}, props, {
    ref: ref
  }));
});
export var OL = /*#__PURE__*/React.forwardRef(function OL(props, ref) {
  return /*#__PURE__*/React.createElement(StyledOL, _extends({}, props, {
    ref: ref
  }));
});
export var Label = /*#__PURE__*/React.forwardRef(function Label(props, ref) {
  return /*#__PURE__*/React.createElement(StyledLabel, _extends({}, props, {
    ref: ref
  }));
});
H1.displayName = 'H1';
H2.displayName = 'H2';
H3.displayName = 'H3';
P.displayName = 'P';
UL.displayName = 'UL';
OL.displayName = 'OL';
Label.displayName = 'Label';
//# sourceMappingURL=Semantic.js.map