Skip to content

Commit aaf1edc

Browse files
authored
Update build-an-avatar-generator-with-html-css-js.mdx
1 parent 2557464 commit aaf1edc

File tree

1 file changed

+15
-13
lines changed

1 file changed

+15
-13
lines changed

projects/build-an-avatar-generator-with-html-css-js/build-an-avatar-generator-with-html-css-js.mdx

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,19 @@ tags:
3838
**Prerequisites:** HTML, CSS, JavaScript fundamentals
3939
**Read Time:** 45 minutes
4040

41-
# Introduction
41+
## Introduction
4242

4343
Have you ever used the randomize button in a video game's character creator? (…how many hours of Baldur's Gate 3 do you think we've played? ⚔️)
4444
<RoundedImage link="https://i.imgur.com/jkgf7of.gif" description="" />
4545

46-
Or, remember Cher's closet from [Clueless](https://en.wikipedia.org/wiki/Clueless), which helped her plan outfits by swiping through a catalogue of her entire wardrobe.?
46+
Or, remember Cher's closet from [Clueless](https://en.wikipedia.org/wiki/Clueless), which helped her plan outfits by swiping through a catalogue of her entire wardrobe?
4747
<RoundedImage link="https://i.imgur.com/TYmiJnX.gif" description="" />
4848

4949
These are both examples of randomizer generators!
5050

5151
There are other types of cool generators out there in games, movies, and TV shows. We can use the same logic to design monsters or even avatars.
5252

53-
Today, we'll be learning how to use HTML, CSS, and vanilla JavaScript to build our own Randomizer Generator.
53+
Today, we'll be learning how to use HTML, CSS, and vanilla JS to build our own Randomizer Generator.
5454

5555
## Getting Started
5656

@@ -62,26 +62,29 @@ If you've taken the HTML, CSS, and JavaScript courses, our web stack for this pr
6262

6363
```
6464
CluelessGenerator/
65-
├── index.html
66-
├── style.css
67-
└── script.js
65+
├── index.html
66+
├── style.css
67+
└── script.js
6868
```
6969

7070
## HTML
7171

72-
HTML buttons allow users to interact with the outfit generator. These buttons control the behavior of the app, such as randomizing outfits and cycling through different images of accessories, tops, and bottoms. Here’s what each part does:
72+
HTML buttons allow users to interact with the outfit generator. These buttons control the behavior of the app, such as randomizing outfits and cycling through different images of accessories, tops, and bottoms.
73+
74+
Here’s what each part does:
7375

7476
### Main Container
7577

76-
Below the header, add a div that wraps everything:
78+
Below the header, add a `<div>` that wraps everything:
7779

7880
```html
7981
<div class="main-container">
82+
8083
</div>
8184
```
8285
Everything else will go inside this container.
8386

84-
### Randomize Button:
87+
### Randomize Button
8588

8689
<RoundedImage link="https://i.imgur.com/PL9cXAX.gif" description="" />
8790

@@ -290,7 +293,7 @@ You'll also add `.shoes-image`.
290293
In JavaScript, you'll need to add a new category to the categories object. Each category includes an array of images, an index to track the current image, references to the HTML elements, and button IDs for navigation. Here's how you'll add the shoes category:
291294
```
292295
const categories = {
293-
296+
...
294297
shoes: {
295298
images: [
296299
// Your shoe images go here
@@ -316,16 +319,15 @@ Congrats! You've built your own generator! Now you're equipped with the skills t
316319
317320
P.S. Are you waiting for an Avatar Builder on Codédex? Keep an eye out!
318321
319-
## Additional Resources
322+
### Additional Resources
320323
321324
- [90's Fashion Nova Holiday Hackathon Project by Ciera](https://www.codedex.io/community/hackathon/OSlnGKjR7MWDaIRgvNdD)
322325
- [Archive App by Vita Newstetter](https://archive.clothing/)
323326
- [I Recreated Cher's Closet From Clueless](https://www.studiosophy.com/blog/2022/2/28/i-recreated-chers-closet-from-clueless)
324327
- [MoMa Exquisite Corpse Generator](https://ec.moma.org/intro)
325328
326-
327329
Share your projects with the team [@codedex_io](https://www.twitter.com/codedex_io)! Let us know what you come up with!
328-
<span style={{ fontSize: "16px", lineHeight: 1 }}>
330+
<span style={{ fontSize: "20px", lineHeight: 1 }}>
329331
<img
330332
src="https://i.imgur.com/FOR1yp5.gif"
331333
alt="emoji"

0 commit comments

Comments
 (0)