import React from 'react';
import { css } from '@emotion/css';
import { AuthMethodSettings } from './auth-method/AuthMethodSettings.js';
import { TLSSettings } from './tls/TLSSettings.js';
import '@grafana/ui';
import { CustomHeaders } from './custom-headers/CustomHeaders.js';
import { ConfigSection } from '../ConfigSection/ConfigSection.js';
import '@grafana/data';

const Auth = ({
  selectedMethod,
  mostCommonMethod,
  visibleMethods,
  defaultOptionsOverrides,
  customMethods,
  onAuthMethodSelect,
  basicAuth,
  TLS,
  customHeaders,
  readOnly = false
}) => {
  const styles = {
    container: css({
      maxWidth: 578
    })
  };
  return /* @__PURE__ */ React.createElement("div", { className: styles.container }, /* @__PURE__ */ React.createElement(ConfigSection, { title: "Authentication" }, /* @__PURE__ */ React.createElement(
    AuthMethodSettings,
    {
      selectedMethod,
      mostCommonMethod,
      customMethods,
      visibleMethods,
      defaultOptionsOverrides,
      onAuthMethodSelect,
      basicAuth,
      readOnly
    }
  ), TLS && /* @__PURE__ */ React.createElement(TLSSettings, { ...TLS, readOnly }), customHeaders && /* @__PURE__ */ React.createElement(CustomHeaders, { ...customHeaders, readOnly })));
};

export { Auth };
//# sourceMappingURL=Auth.js.map
