import templateOnly from '@ember/component/template-only';
import { setComponentTemplate } from '@ember/component';
import { precompileTemplate } from '@ember/template-compilation';
import { on } from '@ember/modifier';
import EuiIcon from './eui-icon.js';

const EuiFormControlLayoutCustomIcon = setComponentTemplate(precompileTemplate(`
    {{#if @onClick}}
      <button
        type="button"
        class="euiFormControlLayoutCustomIcon euiFormControlLayoutCustomIcon--clickable"
        ...attributes
        {{on "click" @onClick}}
      >
        <EuiIcon
          @iconClasses="euiFormControlLayoutCustomIcon__icon"
          @type={{@type}}
          @size={{@size}}
          aria-hidden="true"
        />
      </button>
    {{else}}
      <span class="euiFormControlLayoutCustomIcon" ...attributes>
        <EuiIcon
          @iconClasses="euiFormControlLayoutCustomIcon__icon"
          @type={{@type}}
          @size={{@size}}
          aria-hidden="true"
        />
      </span>
    {{/if}}
  `, {
  strictMode: true,
  scope: () => ({
    on,
    EuiIcon
  })
}), templateOnly("eui-form-control-layout-custom-icon", "EuiFormControlLayoutCustomIcon"));

export { EuiFormControlLayoutCustomIcon as default };
//# sourceMappingURL=eui-form-control-layout-custom-icon.js.map
