{{#let (arg-or-default @display "visible") as |display|}}
  <legend
    class={{class-names
      (if (eq display "hiddden") "euiFormLengend--isHidden")
      (if @compressed "euiFormLegend--compresed")
      "euiFormLegend"
    }}
    ...attributes
  >
    {{#if (eq display "hidden")}}
      <span {{screen-reader-only}}>
        {{yield}}
      </span>
    {{else}}
      {{yield}}
    {{/if}}
  </legend>
{{/let}}