import React from 'react';
import { Box, Button, Flexbox, Icon, Typography } from '../..';
var DrawerTitle = function DrawerTitle(_ref) {
  var _ref$title = _ref.title,
    title = _ref$title === void 0 ? 'Title' : _ref$title,
    helpTitle = _ref.helpTitle,
    showHelpTitle = _ref.showHelpTitle,
    _ref$onHelpClick = _ref.onHelpClick,
    onHelpClick = _ref$onHelpClick === void 0 ? function () {} : _ref$onHelpClick;
  return React.createElement(Flexbox, {
    container: true,
    gap: 2,
    alignItems: "center"
  }, showHelpTitle && React.createElement(Flexbox, {
    item: true
  }, React.createElement(Button.Icon, {
    onClick: onHelpClick
  }, React.createElement(Icon.ChevronLeft16, null))), React.createElement(Flexbox, {
    item: true,
    grow: 1
  }, React.createElement(Typography, {
    type: "title3",
    as: "h3"
  }, showHelpTitle ? helpTitle : title)), !showHelpTitle && React.createElement(Flexbox, {
    item: true
  }, React.createElement(Box, {
    pr: 8,
    pb: 3
  }, React.createElement(Button.Icon, {
    onClick: onHelpClick
  }, React.createElement(Icon.Settings16, null)))));
};
export default DrawerTitle;