{{!-- BEGIN-SNIPPET nypr-m-block-meta.hbs --}}
{{#if @authors}}
  <span class="c-block-meta__author u-font--secondary-style u-font--xxs">
    {{#each @authors as |author|}}
      {{~#if (and (not (has-next author @authors)) (gt @authors.length 1))~}}
        {{! the linter doesn't count the encoded space as a character when it comes to indentation }}
       &nbsp;and&nbsp;
      {{~else if (and (has-next author @authors) (has-previous author @authors))~}}
        ,&nbsp;
      {{~/if~}}

      {{author.name}}
    {{/each}}
  </span>
{{/if}}
{{#if @timestamp}}
  <span class="c-block-meta__timestamp u-font--secondary-style u-font--xxs" data-test-timestamp>
    {{#if @updatedTimestamp}}Updated:&nbsp;{{@updatedTimestamp}}{{else}}{{@timestamp}}{{/if}}
  </span>
{{/if}}
{{#if @commentCount}}
  {{#if @commentRoute}}
    {{#link-to params=@commentRoute class="c-block-meta__comments u-font--secondary-style u-font--xs"}}
      <span class="o-icon o-icon--comment u-icon--xxs">
        <Icon @icon="comment" @title="comment"/>
      </span>
      {{@commentCount}}
    {{/link-to}}
  {{else if @commentURL}}
    <a
      href={{@commentURL}}
      class="c-block-meta__comments u-font--secondary-style u-font--xs"
      name="comments"
      target="_blank"
      rel="noopener"
    >
      <span class="o-icon o-icon--comment u-icon--xs">
        <Icon @icon="comment" @title="comment"/>
      </span>
      {{@commentCount}}
    </a>
  {{/if}}
{{/if}}
{{!-- END-SNIPPET --}}
