<DModalBody @class="explain-reviewable">
  <ConditionalLoadingSpinner @condition={{this.loading}}>
    <table>
      <tbody>
        <tr>
          <th>{{i18n "review.explain.formula"}}</th>
          <th>{{i18n "review.explain.subtotal"}}</th>
        </tr>
        {{#each this.reviewableExplanation.scores as |s|}}
          <tr>
            <td>
              <ScoreValue @value="1.0" @tagName="" />
              <ScoreValue
                @value={{s.type_bonus}}
                @label="type_bonus"
                @tagName=""
              />
              <ScoreValue
                @value={{s.take_action_bonus}}
                @label="take_action_bonus"
                @tagName=""
              />
              <ScoreValue
                @value={{s.trust_level_bonus}}
                @label="trust_level_bonus"
                @tagName=""
              />
              <ScoreValue
                @value={{s.user_accuracy_bonus}}
                @label="user_accuracy_bonus"
                @tagName=""
              />
            </td>
            <td class="sum">{{float s.score}}</td>
          </tr>
        {{/each}}
        <tr class="total">
          <td>{{i18n "review.explain.total"}}</td>
          <td class="sum">{{float this.reviewableExplanation.total_score}}</td>
        </tr>
      </tbody>
    </table>

    <table class="thresholds">
      <tbody>
        <tr>
          <td>{{i18n "review.explain.min_score_visibility"}}</td>
          <td class="sum">
            {{float this.reviewableExplanation.min_score_visibility}}
          </td>
        </tr>
        <tr>
          <td>{{i18n "review.explain.score_to_hide"}}</td>
          <td class="sum">
            {{float this.reviewableExplanation.hide_post_score}}
          </td>
        </tr>
      </tbody>
    </table>

  </ConditionalLoadingSpinner>

</DModalBody>

<div class="modal-footer">
  <DButton @action={{route-action "closeModal"}} @label="close" />
</div>