This site uses third-party cookies, learn more or accept
dark light

HTML Text Animation Editor

Written by Max Pelic on

TL;DR: I made a Text Animation Editor

I wanted to make my 404 page more exciting than just a static message, so I decided to add an animation to it. I came up with the idea of making some sort of text animation rather than a video or gif (which seem to be quite common around the web).

So I started to Google. I looked up "text animation creator", "ASCII animation maker", and other stuff like that, but I was having a hard time finding one that would let me make an animation from scratch (there's probably one out there, just not that I could find). So I decided to make my own.

I started by making a UI and adding all the features I wanted - different text alignments, cycling through frames, adding and deleting frames, and playing the animation. I also added some buttons to export the animation in a few different formats, and a way to import animations I'd created.

Once I got the basic structure down, I decided to add a few more features - cloning frames of the animation, copying the exported text to the clipboard, and dots to show where spaces are.

You can view the finished page here. I'd love to hear your feedback on ways I can improve it - shoot me an email at web@maxpelic.com

Here's an example of the end result:



The JSON for that animation looks like this:

1{

2 "align": "left",
3 "frames": [
4 ".\n",
5 "W.\n^",
6 "OW.\n^",
7 "WOW.\n^ ^",
8 ".WOW.\n ^",
9 " .WOW.\n ^ ^",
10 " ..WOW.\n ^",
11 " . .WOW.\n ^ ^",
12 ". .WOW.\n ^",
13 " ..WOW.\n ^ ^",
14 " . .WOW\n ^",
15 " . .WO\n ^",
16 " . .W\n",
17 " .\n",
18 "\n"
19 ]
20}

On my 404 page I have a spinning ?:



The JSON for the question mark looks like this:

1{

2 "align": "center",
3 "frames": [
4 "_____\n/ __ \\\n| / | |\n / /\n / /\n\n[ ]",
5 "___\n/ _ \\\n|/ | |\n / /\n//\n\n[]",
6 "__\n/ \\\n| |\n /\n/\n\nH",
7 "_\n/\\\n||\n /\n/\n\nI",
8 "\n|\n|\n|\n|\n\n|",
9 "_\n/\\\n||\n\\ \n\\\n\nI",
10 "__\n/ \\\n| |\n\\ \n\\\n\nH",
11 "___\n/ _ \\\n| / \\|\n\\ \\ \n\\\\\n\n[]",
12 "_____\n/ __ \\\n| | \\_|\n\\ \\ \n\\_\\ \n\n[ ]",
13 "___\n/ _ \\\n| / \\|\n\\ \\ \n\\\\\n\n[]",
14 "__\n/ \\\n| |\n\\ \n\\\n\nH",
15 "_\n/\\\n||\n\\ \n\\\n\nI",
16 "\n|\n|\n|\n|\n\n|",
17 "_\n/\\\n||\n /\n/\n\nI",
18 "__\n/ \\\n| |\n /\n/\n\nH",
19 "___\n/ _ \\\n|/ | |\n / /\n//\n\n[]"
20 ]
21}

Share this article:

Previous Article: Create 3D text with HTML, CSS, and JavaScript