import React from 'react';
import { InfoIcon } from '../info-icon';
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
/** View Title. Most often uses for titling page sections. For example leaderboard tabs, etc
 * [CAPITALIZATION] Use title case
 */
export const ViewTitle = ({
  children,
  customHtmlTag: CustomHtmlTag = 'h2',
  infoText,
  infoIconTestId,
  docsLink,
  description
}) => /*#__PURE__*/_jsxs("header", {
  "test-id": "view-title",
  className: "view-title-wrapper",
  children: [/*#__PURE__*/_jsx(CustomHtmlTag, {
    className: "view-title-custom-tag",
    children: children
  }), infoText && /*#__PURE__*/_jsx(InfoIcon, {
    docsLink: docsLink,
    testId: infoIconTestId,
    children: infoText
  }), description && /*#__PURE__*/_jsx("div", {
    className: "description-text",
    "test-id": "view-title-description",
    children: description
  })]
});