@@ -282,7 +282,7 @@ <h3 class="font-bold text-primary-100 dark:text-primary-50 text-left ml-4">
282282 'break-all': hasLongWord(sel.name, 20),
283283 'break-words': !hasLongWord(sel.name, 20)
284284 } " class ="px-6 py-4 text-wrap break-words ">
285- {{sel.name}}
285+ {{normalizeName( sel.name) }}
286286 </ td >
287287 < td class ="px-6 py-4 text-wrap break-all ">
288288 {{sel.url}}
@@ -347,7 +347,116 @@ <h3 class="font-bold text-primary-100 dark:text-primary-50 text-left ml-4">
347347 </button>-->
348348 </ div >
349349 </ div >
350-
350+ @if(additionalISOS.length> 0){
351+ < h3 class ="font-bold text-primary-100 dark:text-primary-50 text-left ml-4 ">
352+ You added the following additional certifications:
353+ </ h3 >
354+ < div class ="relative overflow-x-auto shadow-md sm:rounded-lg w-full bg-white dark:bg-secondary-300 m-4 ">
355+ < table class ="w-full text-sm text-left rtl:text-right text-gray-500 dark:text-gray-200 ">
356+ < thead class ="text-xs text-gray-700 uppercase bg-gray-100 dark:bg-secondary-200 dark:text-white ">
357+ < tr >
358+ < th scope ="col " class ="px-6 py-3 ">
359+ {{ 'UPDATE_PROD_SPEC._product_name' | translate }}
360+ </ th >
361+ < th scope ="col " class ="px-6 py-3 ">
362+ {{ 'UPDATE_PROD_SPEC._value' | translate }}
363+ </ th >
364+ < th scope ="col " class ="px-6 py-3 ">
365+ {{ 'UPDATE_PROD_SPEC._actions' | translate }}
366+ </ th >
367+ </ tr >
368+ </ thead >
369+ < tbody >
370+ @for (cert of additionalISOS; track cert.name; let idx = $index) {
371+ < tr class ="border-b hover:bg-gray-200 dark:bg-secondary-300 dark:border-gray-700 dark:hover:bg-secondary-200 ">
372+ < td [ngClass] ="{
373+ 'break-all': hasLongWord(cert.name, 20),
374+ 'break-words': !hasLongWord(cert.name, 20)
375+ } " class ="px-6 py-4 text-wrap break-words ">
376+ {{normalizeName(cert.name)}}
377+ </ td >
378+ < td class ="px-6 py-4 text-wrap break-all ">
379+ {{cert.url}}
380+ </ td >
381+ < td class ="px-6 py-4 inline-flex ">
382+ < button (click) ="removeCert(cert) " type ="button " class ="text-white bg-red-600 hover:bg-red-700 focus:ring-4 focus:outline-none focus:ring-red-300 font-medium rounded-full text-sm p-1 text-center inline-flex items-center ">
383+ < svg class ="w-4 h-4 text-white " aria-hidden ="true " xmlns ="http://www.w3.org/2000/svg " width ="24 " height ="24 " fill ="none " viewBox ="0 0 24 24 ">
384+ < path stroke ="currentColor " stroke-linecap ="round " stroke-linejoin ="round " stroke-width ="2 " d ="M6 18 17.94 6M18 18 6.06 6 "/>
385+ </ svg >
386+ </ button >
387+ </ td >
388+ </ tr >
389+ }
390+ </ tbody >
391+ </ table >
392+ </ div >
393+ }
394+ @if(showCert==false){
395+ < div class ="flex w-full justify-items-center justify-center ">
396+ < button type ="button " (click) ="showCert=!showCert " class ="flex text-white justify-center bg-primary-100 hover:bg-primary-50 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm px-5 py-2.5 text-center inline-flex items-center ">
397+ Add an additional certification
398+ < svg class ="rtl:rotate-180 w-3.5 h-3.5 ms-2 " aria-hidden ="true " xmlns ="http://www.w3.org/2000/svg " fill ="none " viewBox ="0 0 24 24 ">
399+ < path stroke ="currentColor " stroke-linecap ="round " stroke-linejoin ="round " stroke-width ="2 " d ="M5 12h14m-7 7V5 "/>
400+ </ svg >
401+ </ button >
402+ </ div >
403+ } @else {
404+ < div class ="m-4 w-full ">
405+ < h3 class ="font-bold text-primary-100 dark:text-primary-50 text-left ml-4 ">
406+ Add an additional certification:
407+ </ h3 >
408+ < div class ="lg:flex lg:grid lg:grid-cols-2 w-full gap-4 align-items-middle align-middle border border-gray-200 rounded-lg p-4 ">
409+ < div class ="h-fit ">
410+ < label for ="cert-name " class ="font-bold text-lg dark:text-white "> {{ 'PROFILE._name' | translate }}</ label >
411+ < input #certificationName type ="text " id ="cert-name " [formControl] ="certFileName "
412+ [ngClass] ="certFileName.invalid == true ? 'border-red-600' : 'border-gray-300' "
413+ class ="mb-2 bg-gray-50 border border-gray-300 text-gray-900 dark:bg-secondary-300 dark:border-secondary-200 dark:text-white text-sm rounded-lg focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5 " />
414+ </ div >
415+ @if(isoToCreate==''){
416+ < ngx-file-drop class ="p-4 w-full " dropZoneLabel ="Drop files here " (onFileDrop) ="dropped($event,'attach') " (onFileOver) ="fileOver($event) " (onFileLeave) ="fileLeave($event) ">
417+ < ng-template class ="w-full " ngx-file-drop-content-tmp let-openFileSelector ="openFileSelector ">
418+ < div class ="w-full flex flex-col justify-items-center justify-center ">
419+ < svg class ="w-12 h-12 text-primary-100 mx-auto " aria-hidden ="true " xmlns ="http://www.w3.org/2000/svg " width ="24 " height ="24 " fill ="none " viewBox ="0 0 24 24 ">
420+ < path stroke ="currentColor " stroke-linecap ="round " stroke-linejoin ="round " stroke-width ="2 " d ="M15 17h3a3 3 0 0 0 0-6h-.025a5.56 5.56 0 0 0 .025-.5A5.5 5.5 0 0 0 7.207 9.021C7.137 9.017 7.071 9 7 9a4 4 0 1 0 0 8h2.167M12 19v-9m0 0-2 2m2-2 2 2 "/>
421+ </ svg >
422+ < div class ="flex w-full justify-center ">
423+ < p class ="text-gray-500 mr-2 w-fit "> {{ 'UPDATE_PROD_SPEC._drop_files' | translate }}
424+ < button (click) ="openFileSelector() " class ="font-medium text-primary-100 dark:text-primary-50 hover:underline "> {{ 'UPDATE_PROD_SPEC._select_files' | translate }}</ button >
425+ </ p >
426+ </ div >
427+ </ div >
428+ </ ng-template >
429+ </ ngx-file-drop >
430+ } @else {
431+ < div class ="relative w-full items-center p-4 text-sm text-primary-100 rounded-lg bg-blue-50 dark:bg-secondary-200 dark:text-primary-50 " role ="alert ">
432+ < span class ="sr-only "> Info</ span >
433+ < label class ="text-wrap break-all ">
434+ {{isoToCreate}}
435+ </ label >
436+ < button (click) ="clearAdditionalCert(true) " class ="z-10 absolute top-2 right-2 p-1 font-bold text-white bg-red-500 rounded-3xl ">
437+ < svg class ="w-4 h-4 text-white " aria-hidden ="true " xmlns ="http://www.w3.org/2000/svg " fill ="none " viewBox ="0 0 24 24 ">
438+ < path stroke ="currentColor " stroke-linecap ="round " stroke-linejoin ="round " stroke-width ="2 " d ="M6 18 17.94 6M18 18 6.06 6 "/>
439+ </ svg >
440+ </ button >
441+ </ div >
442+ }
443+ </ div >
444+ < div class ="flex w-full justify-items-center justify-center mt-4 ">
445+ < button type ="button " (click) ="saveAdditionalCert() "
446+ [disabled] ="!certFileName.valid || isoToCreate == '' " [ngClass] ="!certFileName.valid || isoToCreate == '' ? 'opacity-50' : 'hover:bg-primary-50' "
447+ class ="flex text-white justify-center bg-primary-100 hover:bg-primary-50 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm px-5 py-2.5 text-center inline-flex items-center ">
448+ Save
449+ < svg class ="rtl:rotate-180 w-3.5 h-3.5 ms-2 " aria-hidden ="true " xmlns ="http://www.w3.org/2000/svg " fill ="none " viewBox ="0 0 24 24 ">
450+ < path stroke ="currentColor " stroke-linecap ="round " stroke-width ="2 " d ="M11 16h2m6.707-9.293-2.414-2.414A1 1 0 0 0 16.586 4H5a1 1 0 0 0-1 1v14a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1V7.414a1 1 0 0 0-.293-.707ZM16 20v-6a1 1 0 0 0-1-1H9a1 1 0 0 0-1 1v6h8ZM9 4h6v3a1 1 0 0 1-1 1h-4a1 1 0 0 1-1-1V4Z "/>
451+ </ svg >
452+ </ button >
453+ < button type ="button " (click) ="clearAdditionalCert(false);showCert=false; "
454+ class ="flex ml-4 text-gray-900 justify-end bg-gray-400 hover:bg-primary-50 focus:ring-4 focus:outline-none font-medium rounded-lg text-sm px-5 py-2.5 text-center inline-flex items-center ">
455+ Discard
456+ </ button >
457+ </ div >
458+ </ div >
459+ }
351460
352461 }
353462 @if ((currentStep === 2 && !BUNDLE_ENABLED) || (currentStep === 3 && BUNDLE_ENABLED)) {
@@ -384,6 +493,7 @@ <h3 class="font-bold text-primary-100 dark:text-primary-50 text-left ml-4">
384493 </ thead >
385494 < tbody >
386495 @for (prod of prodChars; track prod;) {
496+ @if(!prod.name?.startsWith('Compliance:')){
387497 < tr class ="border-b hover:bg-gray-200 dark:bg-secondary-300 dark:border-gray-700 dark:hover:bg-secondary-200 ">
388498 < td [ngClass] ="{
389499 'break-all': hasLongWord(prod.name, 20),
@@ -430,6 +540,7 @@ <h3 class="font-bold text-primary-100 dark:text-primary-50 text-left ml-4">
430540 </ button >
431541 </ td >
432542 </ tr >
543+ }
433544 }
434545 </ tbody >
435546 </ table >
0 commit comments