Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clearing fade-in animation eventListeners #87

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion web-crypto/derive-bits/ecdh.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
sharedSecretValue.classList.add("fade-in");
sharedSecretValue.addEventListener("animationend", () => {
sharedSecretValue.classList.remove("fade-in");
});
}, { once: true });
sharedSecretValue.textContent = `${buffer}...[${sharedSecret.byteLength} bytes total]`;
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/derive-bits/pbkdf2.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
derivedBitsValue.classList.add("fade-in");
derivedBitsValue.addEventListener("animationend", () => {
derivedBitsValue.classList.remove("fade-in");
});
}, { once: true });
derivedBitsValue.textContent = `${buffer}...[${derivedBits.byteLength} bytes total]`;
}

Expand Down
4 changes: 2 additions & 2 deletions web-crypto/derive-key/ecdh.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
ciphertextValue.classList.add("fade-in");
ciphertextValue.addEventListener("animationend", () => {
ciphertextValue.classList.remove("fade-in");
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand Down Expand Up @@ -70,7 +70,7 @@
decryptedValue.classList.add("fade-in");
decryptedValue.addEventListener("animationend", () => {
decryptedValue.classList.remove("fade-in");
});
}, { once: true });
decryptedValue.textContent = dec.decode(decrypted);
} catch (e) {
decryptedValue.classList.add("error");
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/derive-key/pbkdf2.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
ciphertextValue.classList.add("fade-in");
ciphertextValue.addEventListener("animationend", () => {
ciphertextValue.classList.remove("fade-in");
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand Down Expand Up @@ -114,7 +114,7 @@
decryptedValue.classList.add("fade-in");
decryptedValue.addEventListener("animationend", () => {
decryptedValue.classList.remove("fade-in");
});
}, { once: true });
decryptedValue.textContent = dec.decode(decrypted);
} catch (e) {
decryptedValue.classList.add("error");
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/encrypt-decrypt/aes-cbc.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -62,7 +62,7 @@
decryptedValue.classList.add('fade-in');
decryptedValue.addEventListener('animationend', () => {
decryptedValue.classList.remove('fade-in');
});
}, { once: true });
decryptedValue.textContent = dec.decode(decrypted);
}

Expand Down
4 changes: 2 additions & 2 deletions web-crypto/encrypt-decrypt/aes-ctr.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -64,7 +64,7 @@
decryptedValue.classList.add('fade-in');
decryptedValue.addEventListener('animationend', () => {
decryptedValue.classList.remove('fade-in');
});
}, { once: true });
decryptedValue.textContent = dec.decode(decrypted);
}

Expand Down
4 changes: 2 additions & 2 deletions web-crypto/encrypt-decrypt/aes-gcm.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -62,7 +62,7 @@
decryptedValue.classList.add('fade-in');
decryptedValue.addEventListener('animationend', () => {
decryptedValue.classList.remove('fade-in');
});
}, { once: true });
decryptedValue.textContent = dec.decode(decrypted);
}

Expand Down
4 changes: 2 additions & 2 deletions web-crypto/encrypt-decrypt/rsa-oaep.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -57,7 +57,7 @@
decryptedValue.classList.add('fade-in');
decryptedValue.addEventListener('animationend', () => {
decryptedValue.classList.remove('fade-in');
});
}, { once: true });
decryptedValue.textContent = dec.decode(decrypted);
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/export-key/jwk.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
exportKeyOutput.classList.add("fade-in");
exportKeyOutput.addEventListener("animationend", () => {
exportKeyOutput.classList.remove("fade-in");
});
}, { once: true });
exportKeyOutput.textContent = JSON.stringify(exported, null, " ");
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/export-key/pkcs8.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
exportKeyOutput.classList.add("fade-in");
exportKeyOutput.addEventListener("animationend", () => {
exportKeyOutput.classList.remove("fade-in");
});
}, { once: true });
exportKeyOutput.textContent = pemExported;
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/export-key/raw.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
exportKeyOutput.classList.add("fade-in");
exportKeyOutput.addEventListener("animationend", () => {
exportKeyOutput.classList.remove("fade-in");
});
}, { once: true });
exportKeyOutput.textContent = `[${exportedKeyBuffer}]`;
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/export-key/spki.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
exportKeyOutput.classList.add("fade-in");
exportKeyOutput.addEventListener("animationend", () => {
exportKeyOutput.classList.remove("fade-in");
});
}, { once: true });
exportKeyOutput.textContent = pemExported;
}

Expand Down
4 changes: 2 additions & 2 deletions web-crypto/import-key/jwk.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
const buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand All @@ -77,7 +77,7 @@
signButton.classList.add('fade-in');
signButton.addEventListener('animationend', () => {
signButton.classList.remove('fade-in');
});
}, { once: true });
signButton.removeAttribute("disabled");
signButton.classList.remove("hidden");
}
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/import-key/pkcs8.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQDD0tPV/du2vftjvXj1t/gXTK39sNBV
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
const buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand All @@ -96,7 +96,7 @@ MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQDD0tPV/du2vftjvXj1t/gXTK39sNBV
signButton.classList.add('fade-in');
signButton.addEventListener('animationend', () => {
signButton.classList.remove('fade-in');
});
}, { once: true });
signButton.removeAttribute("disabled");
signButton.classList.remove("hidden");
}
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/import-key/raw.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -68,7 +68,7 @@
encryptButton.classList.add('fade-in');
encryptButton.addEventListener('animationend', () => {
encryptButton.classList.remove('fade-in');
});
}, { once: true });
encryptButton.removeAttribute("disabled");
encryptButton.classList.remove("hidden");
}
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/import-key/spki.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAy3Xo3U13dc+xojwQYWoJLCbOQ5fOVY8Llnqc
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -92,7 +92,7 @@ MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAy3Xo3U13dc+xojwQYWoJLCbOQ5fOVY8Llnqc
encryptButton.classList.add('fade-in');
encryptButton.addEventListener('animationend', () => {
encryptButton.classList.remove('fade-in');
});
}, { once: true });
encryptButton.removeAttribute("disabled");
encryptButton.classList.remove("hidden");
}
Expand Down
2 changes: 1 addition & 1 deletion web-crypto/sign-verify/ecdsa.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
let buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand Down
2 changes: 1 addition & 1 deletion web-crypto/sign-verify/hmac.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
let buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand Down
2 changes: 1 addition & 1 deletion web-crypto/sign-verify/rsa-pss.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
let buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand Down
2 changes: 1 addition & 1 deletion web-crypto/sign-verify/rsassa-pkcs1.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
let buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/unwrap-key/pkcs8.js
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@
signatureValue.classList.add('fade-in');
signatureValue.addEventListener('animationend', () => {
signatureValue.classList.remove('fade-in');
});
}, { once: true });
const buffer = new Uint8Array(signature, 0, 5);
signatureValue.textContent = `${buffer}...[${signature.byteLength} bytes total]`;
}
Expand All @@ -218,7 +218,7 @@
signButton.classList.add('fade-in');
signButton.addEventListener('animationend', () => {
signButton.classList.remove('fade-in');
});
}, { once: true });
signButton.removeAttribute("disabled");
signButton.classList.remove("hidden");
}
Expand Down
4 changes: 2 additions & 2 deletions web-crypto/unwrap-key/raw.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
ciphertextValue.classList.add('fade-in');
ciphertextValue.addEventListener('animationend', () => {
ciphertextValue.classList.remove('fade-in');
});
}, { once: true });
ciphertextValue.textContent = `${buffer}...[${ciphertext.byteLength} bytes total]`;
}

Expand All @@ -147,7 +147,7 @@
encryptButton.classList.add('fade-in');
encryptButton.addEventListener('animationend', () => {
encryptButton.classList.remove('fade-in');
});
}, { once: true });
encryptButton.removeAttribute("disabled");
encryptButton.classList.remove("hidden");
}
Expand Down
2 changes: 1 addition & 1 deletion web-crypto/wrap-key/jwk.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
wrappedKeyOutput.classList.add("fade-in");
wrappedKeyOutput.addEventListener("animationend", () => {
wrappedKeyOutput.classList.remove("fade-in");
});
}, { once: true });
wrappedKeyOutput.textContent = `[${wrappedKeyBuffer}]`;
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/wrap-key/pkcs8.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
wrappedKeyOutput.classList.add("fade-in");
wrappedKeyOutput.addEventListener("animationend", () => {
wrappedKeyOutput.classList.remove("fade-in");
});
}, { once: true });
wrappedKeyOutput.textContent = `[${wrappedKeyBuffer}]`;
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/wrap-key/raw.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
wrappedKeyOutput.classList.add("fade-in");
wrappedKeyOutput.addEventListener("animationend", () => {
wrappedKeyOutput.classList.remove("fade-in");
});
}, { once: true });
wrappedKeyOutput.textContent = `[${wrappedKeyBuffer}]`;
}

Expand Down
2 changes: 1 addition & 1 deletion web-crypto/wrap-key/spki.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
wrappedKeyOutput.classList.add("fade-in");
wrappedKeyOutput.addEventListener("animationend", () => {
wrappedKeyOutput.classList.remove("fade-in");
});
}, { once: true });
wrappedKeyOutput.textContent = `[${wrappedKeyBuffer}]`;
}

Expand Down