<commit_before><% if edition.locale_can_be_changed? %>
  <fieldset class="foreign-language">
    <div class="checkbox">
      <%= label_tag :create_foreign_language_only, nil, class: [:checkbox, "js-toggle-scheduled-publication-date-picker"] do %>
        <%= check_box_tag :create_foreign_language_only, "1", form.object.primary_locale != "en" %> Create a foreign language only news article
      <% end %>
    </div>
    <div class="form-group foreign-language-select js-hidden">
      <%= form.label :primary_locale, 'Document language' %>
      <div class="form-inline add-label-margin">
        <%= form.select :primary_locale, options_for_foreign_language_locale(edition), {}, {class: 'form-control input-md-6'} %>
      </div>
      <p class="warning">Warning: News stories without an English version cannot have other translations.</p>
    </div>
  </fieldset>
<% end %><commit_msg>Allow locale_fields partial to apply to multiple Edition types<commit_after><% if edition.locale_can_be_changed? %>
  <fieldset class="foreign-language">
    <div class="checkbox">
      <%= label_tag :create_foreign_language_only, nil, class: [:checkbox, "js-toggle-scheduled-publication-date-picker"] do %>
        <%= check_box_tag :create_foreign_language_only, "1", form.object.primary_locale != "en" %> <%="Create a foreign language only #{edition.model_name.human.downcase}"%>
      <% end %>
    </div>
    <div class="form-group foreign-language-select js-hidden">
      <%= form.label :primary_locale, 'Document language' %>
      <div class="form-inline add-label-margin">
        <%= form.select :primary_locale, options_for_foreign_language_locale(edition), {}, {class: 'form-control input-md-6'} %>
      </div>
      <% if edition.is_a?(NewsArticle) %>
        <p class="warning">Warning: News stories without an English version cannot have other translations.</p>
      <% end %>
    </div>
  </fieldset>
<% end %>
{'fraction_non_alphanumeric': 0.15364583333333334, 'fraction_numerical': 0.0020833333333333333, 'mean_word_length': 4.041994750656168, 'pattern_counts': {'":': 0, '<': 40, '<?xml version=': 0, '>': 40, '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': '6338135', 'n_tokens_mistral': 614, 'n_tokens_neox': 574, 'n_words': 134}