web: implement typo

This commit is contained in:
John Bowdre 2024-06-14 13:59:16 -05:00
parent 1b8fe443a2
commit 59578496ad
2 changed files with 13 additions and 4 deletions

6
web.md
View file

@ -10,7 +10,7 @@
<span class="kudos">Hi!<button class="tinylytics_kudos"></button></span> <span class="kudos">Hi!<button class="tinylytics_kudos"></button></span>
I write code to make imaginary computers run code written by less imaginary developers <div id="typo" data-typo-chance="2" data-typing-delay="40" data-typing-jitter="20">I write code to make imaginary computers run code written by less imaginary developers</div>
--- ---
@ -60,5 +60,5 @@ I write code to make imaginary computers run code written by less imaginary deve

View file

@ -2,6 +2,7 @@
<!-- add pride bar for june --> <!-- add pride bar for june -->
<link rel="stylesheet" href="https://cdn.pride.codes/css/bar_body.css"> <link rel="stylesheet" href="https://cdn.pride.codes/css/bar_body.css">
<script src="https://tinylytics.app/embed/QUH6xcnWKYeUUYaMkDKd.js?kudos=👋" defer></script> <script src="https://tinylytics.app/embed/QUH6xcnWKYeUUYaMkDKd.js?kudos=👋" defer></script>
<script src="https://paste.lol/jbowdre/typo.js/raw"></script>
<script> <script>
// get weather data from pastebin // get weather data from pastebin
document.addEventListener("DOMContentLoaded", function() { document.addEventListener("DOMContentLoaded", function() {
@ -144,5 +145,13 @@ document.addEventListener("DOMContentLoaded", function() {
} }
}); });
</script> </script>
<script>
// implement typo
document.addEventListener('DOMContentLoaded', function() {
var element = document.getElementById('typo');
var text = element.innerHTML;
typo(element, text);
});
</script>