<commit_before>div class=wrap_class_name
  - if model[:merge]
    == cell('folio/console/merges/index/header')

  - if model && model[:records].present?
    - if collection_actions
      .f-c-catalogue__collection-actions-bar hidden=true
        .f-c-catalogue__collection-actions-bar-count-wrap
          .f-c-catalogue__collection-actions-bar-count 0
          span.f-c-catalogue__collection-actions-bar-count-ico.mi content_copy

        - collection_actions.each do |action|
          = collection_action_for(action)

        span.f-c-catalogue__collection-actions-bar-close
          span.mi close

    .f-c-catalogue__table
      .f-c-catalogue__header
        - if model[:merge]
          .f-c-catalogue__header-cell[
            class="f-c-catalogue__header-cell--merge"
          ]

        - if collection_actions
          .f-c-catalogue__header-cell[
            class="f-c-catalogue__header-cell--collection-actions"
          ]
            label[
              class="f-c-catalogue__collection-actions-label"
            ]
              input[
                class="form-check-input"
                class="f-c-catalogue__collection-actions-checkbox-all"
                type="checkbox"
              ]

        = header_html

      - if model[:ancestry]
        - model[:records].each do |rec, children|
          .f-c-catalogue__row.f-c-catalogue__row--ancestry-root data-depth="0"
            = record_html(rec)

          = render_ancestry_children(children)

      - else
        - model[:records].each_with_index do |rec, i|
          = before_lambda.call(rec, model[:records], i) if before_lambda

          .f-c-catalogue__row
            - if model[:merge]
              .f-c-catalogue__cell.f-c-catalogue__cell--merge
                == cell('folio/console/merges/index/radios', rec)

            - if collection_actions
              .f-c-catalogue__cell.f-c-catalogue__cell--collection-actions
                label[
                  class="f-c-catalogue__collection-actions-label"
                ]
                  input[
                    class="form-check-input"
                    class="f-c-catalogue__collection-actions-checkbox"
                    type="checkbox"
                    name="ids[]"
                    value=rec.id
                  ]

            = record_html(rec)

          = after_lambda.call(rec, model[:records], i) if after_lambda

  - else
    == cell('folio/console/index/no_records', klass)

  span.folio-loader.f-c-catalogue__loader

- if model[:merge]
  == cell('folio/console/merges/index/footer', klass)<commit_msg>skip empty rows in console catalogue<commit_after>div class=wrap_class_name
  - if model[:merge]
    == cell('folio/console/merges/index/header')

  - if model && model[:records].present?
    - if collection_actions
      .f-c-catalogue__collection-actions-bar hidden=true
        .f-c-catalogue__collection-actions-bar-count-wrap
          .f-c-catalogue__collection-actions-bar-count 0
          span.f-c-catalogue__collection-actions-bar-count-ico.mi content_copy

        - collection_actions.each do |action|
          = collection_action_for(action)

        span.f-c-catalogue__collection-actions-bar-close
          span.mi close

    .f-c-catalogue__table
      .f-c-catalogue__header
        - if model[:merge]
          .f-c-catalogue__header-cell[
            class="f-c-catalogue__header-cell--merge"
          ]

        - if collection_actions
          .f-c-catalogue__header-cell[
            class="f-c-catalogue__header-cell--collection-actions"
          ]
            label[
              class="f-c-catalogue__collection-actions-label"
            ]
              input[
                class="form-check-input"
                class="f-c-catalogue__collection-actions-checkbox-all"
                type="checkbox"
              ]

        = header_html

      - if model[:ancestry]
        - model[:records].each do |rec, children|
          .f-c-catalogue__row.f-c-catalogue__row--ancestry-root data-depth="0"
            = record_html(rec)

          = render_ancestry_children(children)

      - else
        - model[:records].each_with_index do |rec, i|
          = before_lambda.call(rec, model[:records], i) if before_lambda

          - html = record_html(rec)

          - if html.present?
            .f-c-catalogue__row
              - if model[:merge]
                .f-c-catalogue__cell.f-c-catalogue__cell--merge
                  == cell('folio/console/merges/index/radios', rec)

              - if collection_actions
                .f-c-catalogue__cell.f-c-catalogue__cell--collection-actions
                  label[
                    class="f-c-catalogue__collection-actions-label"
                  ]
                    input[
                      class="form-check-input"
                      class="f-c-catalogue__collection-actions-checkbox"
                      type="checkbox"
                      name="ids[]"
                      value=rec.id
                    ]

              = html

          = after_lambda.call(rec, model[:records], i) if after_lambda

  - else
    == cell('folio/console/index/no_records', klass)

  span.folio-loader.f-c-catalogue__loader

- if model[:merge]
  == cell('folio/console/merges/index/footer', klass)
{'fraction_non_alphanumeric': 0.11338254779481355, 'fraction_numerical': 0.0007571455612341472, 'mean_word_length': 1.6835957338750636, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1550028', 'n_tokens_mistral': 1580, 'n_tokens_neox': 1512, 'n_words': 192}