1<!-- TODO: Replace table with resusable table component -->
2<div class="table__row-value row">
3  <div class="certificate__type-cell bold">
4    {{getCertificateName(cert.Description)}}
5  </div>
6  <div class="certificate__title-inline">
7    Issued by:
8  </div>
9  <div class="certificate__issue-cell">
10    {{cert.Issuer.CommonName}}
11  </div>
12  <div class="certificate__title-inline">
13    Issued to:
14  </div>
15  <div class="certificate__issue-cell">
16    {{cert.Subject.CommonName}}
17  </div>
18  <div class="certificate__title-inline">
19    Valid from:
20  </div>
21  <div class="certificate__date-cell">
22    {{cert.ValidNotBefore | date:medium}}
23  </div>
24  <div class="certificate__title-inline">
25    Valid until:
26  </div>
27  <div class="certificate__status-cell">
28    <icon file="icon-critical.svg"
29      aria-label="certificate has expired"
30      class="certificate__status-icon"
31      ng-if="cert.isExpired">
32    </icon>
33    <icon file="icon-warning.svg"
34      aria-label="certificate will expire soon"
35      class="certificate__status-icon"
36      ng-if="cert.isExpiring">
37    </icon>
38  </div>
39  <div class="certificate__date-cell">
40    {{cert.ValidNotAfter | date:medium}}
41  </div>
42  <div class="certificate__title-inline">
43    Actions:
44  </div>
45  <div class="certificate__buttons-cell row">
46    <button
47      type="button"
48      ng-click="cert.upload = true"
49      aria-label="Replace certificate"
50      class="btn  btn-tertiary certificate__button">
51      <icon file="icon-replace.svg" aria-hidden="true"></icon>
52    </button>
53    <button type="button"
54      ng-click="confirmDeleteCert(cert)"
55      aria-label="Delete certificate"
56      class="btn  btn-tertiary certificate__button"
57      ng-disabled="!isDeletable(cert)">
58      <icon file="icon-trashcan.svg" aria-hidden="true"></icon>
59    </button>
60  </div>
61  <div ng-show="cert.upload === true" class="upload__certificate">
62    <div class="close-btn">
63      <button
64        type="button"
65        ng-click="cert.upload=false"
66        aria-label="close replace certificate upload form">
67        <icon file="icon-close.svg" aria-hidden="true"></icon>
68      </button>
69    </div>
70    <div class="file-upload">
71      <label
72        for="upload_{{ cert.Description + cert.Id }}"
73        class="file-upload-btn btn btn-secondary"
74        tabindex="0">Choose file</label>
75      <input
76        name="upload_{{ cert.Description + cert.Id }}"
77        id="upload_{{ cert.Description + cert.Id }}"
78        type="file"
79        file="cert.file"
80        class="file-upload-input"/>
81    </div>
82    <div class="file-upload-container file-upload-field">
83      <span ng-if="!cert.file">No file selected</span>
84      <span>{{ cert.file.name }}</span>
85      <button
86        type="reset"
87        class="btn file-upload-reset"
88        ng-if="cert.file.name"
89        ng-click="cert.file = '';"
90        aria-label="remove selected file">
91        <icon file="icon-close.svg" aria-hidden="true"></icon>
92      </button>
93    </div>
94    <div class="replace-btn">
95      <button
96        type="submit"
97        ng-disabled="!cert.file"
98        class="btn btn-primary"
99        ng-click="replaceCertificate(cert)">
100        Replace
101      </button>
102    </div>
103  </div>
104</div>
105