import { makeStyles } from '@material-ui/core/styles';
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
var useStyles = makeStyles({
  image: {
    maxWidth: '20%',
    maxHeight: '100px',
    width: 'inherit',
    height: 'inherit',
    "float": 'right'
  }
});

function Image(logoUrl) {
  var classes = useStyles();
  return /*#__PURE__*/_jsx("img", {
    src: logoUrl,
    alt: 'Logo',
    className: classes.image
  });
}

export default (function (config) {
  return function (props) {
    var _props$schema, _props$schema$title;

    (_props$schema$title = (_props$schema = props.schema).title) !== null && _props$schema$title !== void 0 ? _props$schema$title : _props$schema.title = config.useLabel ? config.label : config.logo ? /*#__PURE__*/_jsxs("div", {
      style: {
        overflow: 'hidden'
      },
      children: [Image(config.logo), config.title]
    }) : config.title;
  };
});
//# sourceMappingURL=fieldTitleSupport.js.map