<commit_before><div
  class="offering-form"
  data-test-offering-form
  {{did-insert (perform this.load) @offering @cohorts @scrollToBottom}}
  {{did-update (perform this.load) @offering @cohorts @scrollToBottom}}
>
  {{#unless this.loadData.isRunning}}
    <div class="toggle-offering-calendar">
      <ToggleButtons
        @firstLabel={{t "general.hideCalendar"}}
        @firstOptionSelected={{not this.showOfferingCalendar}}
        @secondLabel={{t "general.showCalendar"}}
        @toggle={{toggle "showOfferingCalendar" this}}
      />
    </div>
    {{#if this.showOfferingCalendar}}
      <OfferingCalendar
        @endDate={{this.endDate}}
        @learnerGroups={{this.learnerGroups}}
        @startDate={{this.startDate}}
        @session={{@session}}
      />
    {{/if}}
    <div class="form">
      <div class="item start-date">
        <label>
          {{t "general.startDate"}}:
        </label>
        <PikadayInput
          @format="M/D/YYYY"
          @value={{this.startDate}}
          @onSelection={{fn this.updateStartDate}}
        />
      </div>
      <div class="item start-time">
        <label>
          {{t "general.startTime"}}:
        </label>
        {{#unless this.isEditingTimezone}}
          <div
            data-test-current-timezone
            class="editable clickable current-timezone"
            role="button"
            {{on "click" (set this.isEditingTimezone true)}}
          >
            {{this.formattedCurrentTimezone}}
          </div>
        {{/unless}}
        <TimePicker @date={{this.startDate}} @action={{fn this.updateStartTime}} />
      </div>
      <div class="item timezone" data-test-timezone-picker>
        {{#if this.isEditingTimezone}}
          <label>
            {{t "general.timezone"}}:
          </label>
          <span class="picker">
            <select {{on "change" (fn this.changeTimezone)}}>
              {{#each this.timezones as |timezone|}}
                <option value={{timezone.value}} selected={{is-equal timezone.value this.currentTimezone}}>
                  {{timezone.label}}
                </option>
              {{/each}}
            </select>
            <span class="actions">
              <button
                class="cancel"
                title={{t "general.cancel"}}
                type="button"
                {{on "click" (set this.isEditingTimezone false)}}
              >
                <FaIcon @icon="times" />
              </button>
            </span>
          </span>
        {{/if}}
      </div>
      <div class="item offering-duration">
        <label>
          {{t "general.duration"}}:
        </label>
        <div class="duration-inputs">
          <div class="hours">
            <div class="hours-container">
              <input
                min="0"
                type="number"
                value={{this.durationHours}}
                {{on "input" (perform this.updateDurationHours value="target.value")}}
              >
              {{#each (await (compute (fn this.getErrorsFor) "durationHours")) as |message|}}
                <span class="validation-error-message">
                  {{message}}
                </span>
              {{/each}}
              <label>
                {{t "general.hours"}}
              </label>
            </div>
          </div>
          <div class="minutes">
            <div class="minutes-container">
              <input
                max="59"
                min="0"
                type="number"
                value={{this.durationMinutes}}
                {{on "input" (perform this.updateDurationMinutes value="target.value")}}
              >
              {{#each (await (compute (fn this.getErrorsFor) "durationMinutes")) as |message|}}
                <span class="validation-error-message">
                  {{message}}
                </span>
              {{/each}}
              <label>
                {{t "general.minutes"}}
              </label>
            </div>
          </div>
        </div>
      </div>
      <div class="item end-date-time">
        <label>
          {{t "general.end"}}:
        </label>
        {{#if this.endDate}}
          <div class="text">
            {{moment-format this.endDate "M/D/YYYY h:mm a"}}
          </div>
        {{/if}}
      </div>
      {{#if @showMakeRecurring}}
        <div class="item make-recurring">
          <label>
            {{t "general.makeRecurring"}}
          </label>
          <ToggleYesno
            @yes={{this.makeRecurring}}
            @toggle={{set this.makeRecurring (not this.makeRecurring)}}
          />
          {{#if this.makeRecurring}}
            <div class="make-recurring-options">
              <div class="make-recurring-days">
                {{#each this.recurringDayOptions as |obj i|}}
                  <div>
                    <input id="make-recurring-day-input-{{i}}"
                      type="checkbox"
                      checked={{or
                        (contains obj.day this.recurringDays)
                        (eq (moment-format this.startDate "d") obj.day)
                      }}
                      disabled={{eq (moment-format this.startDate "d") obj.day}}
                      data-test-recurring-day-input={{i}}
                      {{on "click" (fn this.toggleRecurringDay obj.day)}}
                    >
                    <label
                      class="day-of-week clickable"
                      for="make-recurring-day-input-{{i}}"
                      data-test-recurring-day-label={{i}}
                    >
                      {{t obj.t}}
                    </label>
                  </div>
                {{/each}}
              </div>
              <div class="make-recurring-input-container">
                <input type="text"
                  value={{this.numberOfWeeks}}
                  class="make-recurring-input"
                  {{on "input" (fn this.changeNumberOfWeeks)}}
                  {{on "keyup" (fn this.addErrorDisplayFor "numberOfWeeks")}}<commit_msg>slaps another data-test attribute onto form element<commit_after><div
  class="offering-form"
  data-test-offering-form
  {{did-insert (perform this.load) @offering @cohorts @scrollToBottom}}
  {{did-update (perform this.load) @offering @cohorts @scrollToBottom}}
>
  {{#unless this.loadData.isRunning}}
    <div class="toggle-offering-calendar">
      <ToggleButtons
        @firstLabel={{t "general.hideCalendar"}}
        @firstOptionSelected={{not this.showOfferingCalendar}}
        @secondLabel={{t "general.showCalendar"}}
        @toggle={{toggle "showOfferingCalendar" this}}
      />
    </div>
    {{#if this.showOfferingCalendar}}
      <OfferingCalendar
        @endDate={{this.endDate}}
        @learnerGroups={{this.learnerGroups}}
        @startDate={{this.startDate}}
        @session={{@session}}
      />
    {{/if}}
    <div class="form">
      <div class="item start-date">
        <label>
          {{t "general.startDate"}}:
        </label>
        <PikadayInput
          @format="M/D/YYYY"
          @value={{this.startDate}}
          @onSelection={{fn this.updateStartDate}}
        />
      </div>
      <div class="item start-time">
        <label>
          {{t "general.startTime"}}:
        </label>
        {{#unless this.isEditingTimezone}}
          <div
            data-test-current-timezone
            class="editable clickable current-timezone"
            role="button"
            {{on "click" (set this.isEditingTimezone true)}}
          >
            {{this.formattedCurrentTimezone}}
          </div>
        {{/unless}}
        <TimePicker @date={{this.startDate}} @action={{fn this.updateStartTime}} />
      </div>
      <div class="item timezone" data-test-timezone-picker>
        {{#if this.isEditingTimezone}}
          <label>
            {{t "general.timezone"}}:
          </label>
          <span class="picker">
            <select {{on "change" (fn this.changeTimezone)}}>
              {{#each this.timezones as |timezone|}}
                <option value={{timezone.value}} selected={{is-equal timezone.value this.currentTimezone}}>
                  {{timezone.label}}
                </option>
              {{/each}}
            </select>
            <span class="actions">
              <button
                class="cancel"
                title={{t "general.cancel"}}
                type="button"
                {{on "click" (set this.isEditingTimezone false)}}
              >
                <FaIcon @icon="times" />
              </button>
            </span>
          </span>
        {{/if}}
      </div>
      <div class="item offering-duration">
        <label>
          {{t "general.duration"}}:
        </label>
        <div class="duration-inputs">
          <div class="hours">
            <div class="hours-container">
              <input
                min="0"
                type="number"
                value={{this.durationHours}}
                {{on "input" (perform this.updateDurationHours value="target.value")}}
              >
              {{#each (await (compute (fn this.getErrorsFor) "durationHours")) as |message|}}
                <span class="validation-error-message">
                  {{message}}
                </span>
              {{/each}}
              <label>
                {{t "general.hours"}}
              </label>
            </div>
          </div>
          <div class="minutes">
            <div class="minutes-container">
              <input
                max="59"
                min="0"
                type="number"
                value={{this.durationMinutes}}
                {{on "input" (perform this.updateDurationMinutes value="target.value")}}
              >
              {{#each (await (compute (fn this.getErrorsFor) "durationMinutes")) as |message|}}
                <span class="validation-error-message">
                  {{message}}
                </span>
              {{/each}}
              <label>
                {{t "general.minutes"}}
              </label>
            </div>
          </div>
        </div>
      </div>
      <div class="item end-date-time">
        <label>
          {{t "general.end"}}:
        </label>
        {{#if this.endDate}}
          <div class="text">
            {{moment-format this.endDate "M/D/YYYY h:mm a"}}
          </div>
        {{/if}}
      </div>
      {{#if @showMakeRecurring}}
        <div class="item make-recurring">
          <label>
            {{t "general.makeRecurring"}}
          </label>
          <ToggleYesno
            @yes={{this.makeRecurring}}
            @toggle={{set this.makeRecurring (not this.makeRecurring)}}
          />
          {{#if this.makeRecurring}}
            <div class="make-recurring-options">
              <div class="make-recurring-days">
                {{#each this.recurringDayOptions as |obj i|}}
                  <div data-test-make-recurring-day>
                    <input id="make-recurring-day-input-{{i}}"
                      type="checkbox"
                      checked={{or
                        (contains obj.day this.recurringDays)
                        (eq (moment-format this.startDate "d") obj.day)
                      }}
                      disabled={{eq (moment-format this.startDate "d") obj.day}}
                      data-test-recurring-day-input={{i}}
                      {{on "click" (fn this.toggleRecurringDay obj.day)}}
                    >
                    <label
                      class="day-of-week clickable"
                      for="make-recurring-day-input-{{i}}"
                      data-test-recurring-day-label={{i}}
                    >
                      {{t obj.t}}
                    </label>
                  </div>
                {{/each}}
              </div>
              <div class="make-recurring-input-container">
                <input type="text"
                  value={{this.numberOfWeeks}}
                  class="make-recurring-input"
                  {{on "input" (fn this.changeNumberOfWeeks)}}
                  {{on "keyup" (fn this.addErrorDisplayFor "numberOfWeeks")}}
{'fraction_non_alphanumeric': 0.14723068060241956, 'fraction_numerical': 0.0006583820261706855, 'mean_word_length': 1.4087215064420218, 'pattern_counts': {'":': 0, '<': 157, '<?xml version=': 0, '>': 155, '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': '6026647', 'n_tokens_mistral': 3411, 'n_tokens_neox': 3332, 'n_words': 608}