tengo que arreglar el tema de los streams
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
|
||||
let file:File | null = $state(null);
|
||||
let confirmaGarantes: boolean = $state(false);
|
||||
|
||||
let clickeado: boolean = $state(false);
|
||||
|
||||
function handleFile(e:Event):void {
|
||||
const input = e.target as HTMLInputElement;
|
||||
@@ -22,7 +22,9 @@
|
||||
|
||||
function submit() {
|
||||
if (file == null) return;
|
||||
clickeado = true;
|
||||
onConfirm(file, men.mensaje.split(" ").reverse()[0]);
|
||||
onClose();
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -89,8 +91,14 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer d-flex justify-content-between">
|
||||
<button class="btn btn-primary" disabled={!(confirmaGarantes && file != null)} onclick={submit} >
|
||||
<button class="btn btn-primary" disabled={!(confirmaGarantes && file != null && clickeado == false)} onclick={submit} >
|
||||
{#if clickeado == false}
|
||||
Subir
|
||||
{:else}
|
||||
<div class="spinner-border" role="status">
|
||||
<span class="visually-hidden">Loading...</span>
|
||||
</div>
|
||||
{/if}
|
||||
</button>
|
||||
<button type="button" class="btn btn-danger" onclick={onCancel}>Cancelar Contrato</button>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user