<commit_before><h3>Visibility</h3>
<% if f.object.embargo_release_date %>
  <%= render 'form_permission_under_embargo', f: f %>
<% elsif f.object.lease_expiration_date %>
  <%= render 'form_permission_under_lease', f: f %>
<% else %>
  <div class="form-group visibility">
    <label class="radio">
      <%= f.radio_button :visibility, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC, data: { 'target': '#collapsePublic' }  %>
      <%= t('libra.visibility.open.label_html') %>
      <section class="collapse" id="collapsePublic">
      </section>
    </label>

    <label class="radio">
      <%= f.radio_button :visibility, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_EMBARGO, data: { 'target': '#collapseEmbargo' } %>
      <%= t('libra.visibility.embargo.label_html') %>
      <div class="collapse" id="collapseEmbargo">
        <div class="form-inline">
          <%= f.input :visibility_during_embargo, label: 'Restricted to', wrapper: :inline, collection: post_embargo_visibility_options( ), include_blank: false %>
          <%= f.input :embargo_period, label: 'For', wrapper: :inline, collection: embargo_duration_options( ), include_blank: false %>
          <%= f.input :embargo_release_date, as: :hidden, input_html: { value: Date.tomorrow } %>
          <%= f.input :visibility_after_embargo, as: :hidden, input_html: { value: Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC } %>
          <br>
          <%= t('libra.visibility.after_embargo.label_html') %>
        </div>
      </div>
    </label>

  </div>
<% end %>
<commit_msg>LIBRA-105: embargo visibility is non-optional<commit_after><h3>Visibility</h3>
<% if f.object.embargo_release_date %>
  <%= render 'form_permission_under_embargo', f: f %>
<% elsif f.object.lease_expiration_date %>
  <%= render 'form_permission_under_lease', f: f %>
<% else %>
  <div class="form-group visibility">
    <label class="radio">
      <%= f.radio_button :visibility, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC, data: { 'target': '#collapsePublic' }  %>
      <%= t('libra.visibility.open.label_html') %>
      <section class="collapse" id="collapsePublic">
      </section>
    </label>

    <label class="radio">
      <%= f.radio_button :visibility, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_EMBARGO, data: { 'target': '#collapseEmbargo' } %>
      <%= t('libra.visibility.embargo.label_html') %>
      <div class="collapse" id="collapseEmbargo">
        <div class="form-inline">
          <%= f.input :embargo_period, label: 'For', wrapper: :inline, collection: embargo_duration_options( ), include_blank: false %>
          <%= f.input :visibility_during_embargo, as: :hidden, input_html: { value: Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_AUTHENTICATED } %>
          <%= f.input :embargo_release_date, as: :hidden, input_html: { value: Date.tomorrow } %>
          <%= f.input :visibility_after_embargo, as: :hidden, input_html: { value: Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC } %>
          <%= t('libra.visibility.after_embargo.label_html') %>
        </div>
      </div>
    </label>

  </div>
<% end %>

{'fraction_non_alphanumeric': 0.16625, 'fraction_numerical': 0.0021875, 'mean_word_length': 4.273476112026359, 'pattern_counts': {'":': 0, '<': 62, '<?xml version=': 0, '>': 62, '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': '2018700', 'n_tokens_mistral': 1114, 'n_tokens_neox': 1013, 'n_words': 173}