import templateOnly from '@ember/component/template-only';
import { setComponentTemplate } from '@ember/component';
import { precompileTemplate } from '@ember/template-compilation';
import { eq } from 'ember-truth-helpers';
import argOrDefault from '../helpers/arg-or-default.js';
import classNames from '../helpers/class-names.js';

const EuiFlexGroup = setComponentTemplate(precompileTemplate(`
  {{#if (eq @tagName "span")}}
    <span
      class={{classNames
        (unless (eq @responsive false) "euiFlexGroup--responsive")
        (if @wrap "euiFlexGroup--wrap")
        componentName="EuiFlexGroup"
        gutterSize=(argOrDefault @gutterSize "l")
        alignItems=(argOrDefault @alignItems "stretch")
        justifyContent=(argOrDefault @justifyContent "flexStart")
        direction=(argOrDefault @direction "row")
      }}
      ...attributes
    >
      {{yield}}
    </span>
  {{else}}
    <div
      class={{classNames
        (unless (eq @responsive false) "euiFlexGroup--responsive")
        (if @wrap "euiFlexGroup--wrap")
        componentName="EuiFlexGroup"
        gutterSize=(argOrDefault @gutterSize "l")
        alignItems=(argOrDefault @alignItems "stretch")
        justifyContent=(argOrDefault @justifyContent "flexStart")
        direction=(argOrDefault @direction "row")
      }}
      ...attributes
    >
      {{yield}}
    </div>
  {{/if}}
`, {
  strictMode: true,
  scope: () => ({
    eq,
    classNames,
    argOrDefault
  })
}), templateOnly("eui-flex-group", "EuiFlexGroup"));

export { EuiFlexGroup as default };
//# sourceMappingURL=eui-flex-group.js.map
