<commit_before><k-area-blocker [showLoader]="_transcodingProfileLoading" [message]="_transcodingProfileError">


  <div class="kUploadSettings">
    <div class="kHeader">
      <h1>{{ 'applications.upload.uploadSettings.title' | translate }}</h1>
    </div>
    <div class="kContent">
      <form [formGroup]="_profileForm" class="kProfile">
        <span>{{ 'applications.upload.uploadSettings.profile' | translate }}</span>
        <p-dropdown class="kTranscodingProfile"
                    [options]="_transcodingProfiles"
                    [autoWidth]="false"
                    [placeholder]="'applications.upload.uploadSettings.profilePlaceholder' | translate"
                    [formControl]="_transcodingProfileField">
        </p-dropdown>
      </form>

      <div class="kAddFile">
        <button type="button"
                class="kButtonDefault kAddFileButton"
                pButton
                [label]="'applications.upload.uploadSettings.addFileBtn' | translate"
                (click)="fileDialog.open()"></button>
      </div>
      <div class="kTable" [class.empty]="_files.length === 0">
        <p-dataTable [value]="_files"
                     [immutable]="false"
                     [emptyMessage]="'applications.upload.uploadSettings.table.emptyMessage.title' | translate"
                     scrollable="true">
          <p-column [style]="{'width': '28px'}"></p-column>
          <p-column field="name"
                    class="kFileNameCol"
                    [sortable]="false"
                    [header]="'applications.upload.uploadSettings.table.header.fileName' | translate">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <div *ngIf="!file.isEditing" class="kFileNameCell">
                <span class="kFileName">{{ file.name }}</span>
                <i class="kIconpen kIconEditFileName"
                   [kTooltip]="'applications.upload.uploadSettings.table.edit' | translate"
                   placement="top"
                   (click)="_editName(file)"></i>
              </div>
              <div *ngIf="file.isEditing">
                <input pInputText
                       class="kFileNameInput"
                       kAutofocus
                       [(ngModel)]="file.name"
                       (blur)="_cancelEdit(file)"
                       (keyup.enter)="_cancelEdit(file)">
              </div>
            </ng-template>
          </p-column>
          <p-column field="type"
                    [sortable]="false"
                    [style]="{ 'width': '150px', 'overflow':'visible' }"
                    [header]="'applications.upload.uploadSettings.table.header.mediaType' | translate">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <p-dropdown [options]="_fileTypes"
                          [autoWidth]="false"
                          [(ngModel)]="file.mediaType"
                          placeholder="{{'applications.content.entryDetails.related.select' | translate}}"></p-dropdown>
            </ng-template>
          </p-column>
          <p-column field="size"
                    [sortable]="false"
                    [style]="{ 'width': '100px' }"
                    [header]="'applications.upload.uploadSettings.table.header.size' | translate">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <span id="uploadSettingFileSize">{{ file.size | kFileSize }}</span>
            </ng-template>
          </p-column>
          <p-column [style]="{ 'width': '40px', 'text-align': 'center'}">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <i *ngIf="file.hasError"
                 class="kIconinfo kIconError"
                 [kTooltip]="file.errorToken | translate"
                 placement="top"
                 (click)="_removeFile(file)"></i>
            </ng-template>
          </p-column>
          <p-column [style]="{ 'width': '45px', 'text-align': 'center'}">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <i class="kIcontrash kIconRemoveFile"
                 [kTooltip]="'applications.upload.uploadSettings.table.remove' | translate"
                 placement="top"
                 (click)="_removeFile(file)"></i>
            </ng-template>
          </p-column>
          <p-column [style]="{'width': '28px'}"></p-column>
        </p-dataTable>
        <div *ngIf="_files.length === 0" class="kEmptyMessage">
          <h1>{{ 'applications.upload.uploadSettings.table.emptyMessage.title' | translate }}</h1>
          <p>
            {{ 'applications.upload.uploadSettings.table.emptyMessage.getStarted' | translate }}
            <a (click)="fileDialog.open()">
              {{ 'applications.upload.uploadSettings.table.emptyMessage.browse' | translate }}
            </a>
          </p>

        </div>
      </div>
    </div>
    <div class="kFooter">
      <button class="kButtonDefault kUploadButton"
              pButton
              [disabled]="_files.length === 0"
              [label]="'applications.upload.uploadSettings.uploadBtn' | translate"
              (click)="_upload()"></button>
    </div>
  </div>
</k-area-blocker>
<kFileDialog #fileDialog
             [filter]="_allowedExtensions"
             [allowMultiple]="true"
             (onFileSelected)="_handleSelectedFiles($event)"></kFileDialog>
<commit_msg>fix: show notification asking user to select media type when while uploading unrecognized file (#315)<commit_after><k-area-blocker [showLoader]="_transcodingProfileLoading" [message]="_transcodingProfileError">


  <div class="kUploadSettings">
    <div class="kHeader">
      <h1>{{ 'applications.upload.uploadSettings.title' | translate }}</h1>
    </div>
    <div class="kContent">
      <form [formGroup]="_profileForm" class="kProfile">
        <span>{{ 'applications.upload.uploadSettings.profile' | translate }}</span>
        <p-dropdown class="kTranscodingProfile"
                    [options]="_transcodingProfiles"
                    [autoWidth]="false"
                    [placeholder]="'applications.upload.uploadSettings.profilePlaceholder' | translate"
                    [formControl]="_transcodingProfileField">
        </p-dropdown>
      </form>

      <div class="kAddFile">
        <button type="button"
                class="kButtonDefault kAddFileButton"
                pButton
                [label]="'applications.upload.uploadSettings.addFileBtn' | translate"
                (click)="fileDialog.open()"></button>
      </div>
      <div class="kTable" [class.empty]="_files.length === 0">
        <p-dataTable [value]="_files"
                     [immutable]="false"
                     [emptyMessage]="'applications.upload.uploadSettings.table.emptyMessage.title' | translate"
                     scrollable="true">
          <p-column [style]="{'width': '28px'}"></p-column>
          <p-column field="name"
                    class="kFileNameCol"
                    [sortable]="false"
                    [header]="'applications.upload.uploadSettings.table.header.fileName' | translate">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <div *ngIf="!file.isEditing" class="kFileNameCell">
                <span class="kFileName">{{ file.name }}</span>
                <i class="kIconpen kIconEditFileName"
                   [kTooltip]="'applications.upload.uploadSettings.table.edit' | translate"
                   placement="top"
                   (click)="_editName(file)"></i>
              </div>
              <div *ngIf="file.isEditing">
                <input pInputText
                       class="kFileNameInput"
                       kAutofocus
                       [(ngModel)]="file.name"
                       (blur)="_cancelEdit(file)"
                       (keyup.enter)="_cancelEdit(file)">
              </div>
            </ng-template>
          </p-column>
          <p-column field="type"
                    [sortable]="false"
                    [style]="{ 'width': '150px', 'overflow':'visible' }"
                    [header]="'applications.upload.uploadSettings.table.header.mediaType' | translate">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <p-dropdown [options]="_fileTypes"
                          [autoWidth]="false"
                          [(ngModel)]="file.mediaType"
                          placeholder="{{'applications.content.entryDetails.related.select' | translate}}"></p-dropdown>
            </ng-template>
          </p-column>
          <p-column field="size"
                    [sortable]="false"
                    [style]="{ 'width': '100px' }"
                    [header]="'applications.upload.uploadSettings.table.header.size' | translate">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <span id="uploadSettingFileSize">{{ file.size | kFileSize }}</span>
            </ng-template>
          </p-column>
          <p-column [style]="{ 'width': '40px', 'text-align': 'center'}">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <i *ngIf="file.hasError"
                 class="kIconerror kIconError"
                 [kTooltip]="file.errorToken | translate"
                 placement="top"
                 (click)="_removeFile(file)"></i>
            </ng-template>
          </p-column>
          <p-column [style]="{ 'width': '45px', 'text-align': 'center'}">
            <ng-template let-col let-file="rowData" pTemplate="body">
              <i class="kIcontrash kIconRemoveFile"
                 [kTooltip]="'applications.upload.uploadSettings.table.remove' | translate"
                 placement="top"
                 (click)="_removeFile(file)"></i>
            </ng-template>
          </p-column>
          <p-column [style]="{'width': '28px'}"></p-column>
        </p-dataTable>
        <div *ngIf="_files.length === 0" class="kEmptyMessage">
          <h1>{{ 'applications.upload.uploadSettings.table.emptyMessage.title' | translate }}</h1>
          <p>
            {{ 'applications.upload.uploadSettings.table.emptyMessage.getStarted' | translate }}
            <a (click)="fileDialog.open()">
              {{ 'applications.upload.uploadSettings.table.emptyMessage.browse' | translate }}
            </a>
          </p>

        </div>
      </div>
    </div>
    <div class="kFooter">
      <button class="kButtonDefault kUploadButton"
              pButton
              [disabled]="_files.length === 0"
              [label]="'applications.upload.uploadSettings.uploadBtn' | translate"
              (click)="_upload()"></button>
    </div>
  </div>
</k-area-blocker>
<kFileDialog #fileDialog
             [filter]="_allowedExtensions"
             [allowMultiple]="true"
             (onFileSelected)="_handleSelectedFiles($event)"></kFileDialog>

{'fraction_non_alphanumeric': 0.1547586458618487, 'fraction_numerical': 0.004106214070626882, 'mean_word_length': 1.9094770374303158, 'pattern_counts': {'":': 0, '<': 161, '<?xml version=': 0, '>': 161, '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': '3023626', 'n_tokens_mistral': 3080, 'n_tokens_neox': 2935, 'n_words': 440}