forked from itscodenation/flw1-u1l8-23-24-student-exercises
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jsLab.js
65 lines (40 loc) · 2.29 KB
/
jsLab.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// html elements
let tile1 = document.querySelector('.tile-1')
let tile2 = document.querySelector('.tile-2')
let tile3 = document.querySelector('.tile-3')
let tile4 = document.querySelector('.tile-4')
let tile5 = document.querySelector('.tile-5')
let tile6 = document.querySelector('.tile-6')
let tile7 = document.querySelector('.tile-7')
let tile8 = document.querySelector('.tile-8')
let tile9 = document.querySelector('.tile-9')
/********* NOTE: unsure which tile is which? Be sure to reference the HTML when you need to double-check! ************/
// 1. Tile 1 feels a little sad.
// - Update the inner HTML to show an encouraging message!
// - Something like "YOU GOT THIS!" or even a "You're a beautiful person!"
// 2. Tile 2 has a button.
// - Create a click event and have the background color of tile 2 change to a shade of green.
// - BE SURE TO SAVE THE BUTTON FIRST AS A VARIABLE.
// - Can you see if there's a way to toggle it???
// 3. What's this? A totoro? Where's his friends?
// - Using createElement, create a friend (an image element).
// - Once created, set the src of it to the image address.
// - Append the element to tile 3.
// - Need some inspiration? Go to giphy.com, search a character and choose the "stickers".
// 4. Oh no! A broken image! We need to fix this.
// - Set the src for tile 4 to have an image of your favorite TV show.
// These following tasks may require a little bit of digging.
// Unsure how to complete the task? Use your resources! Code Nation reference table might help.
// Can't find it there? Google search the keywords of what you're trying to do and use web dev documentation!
// W3schools, MDN Web Docs, and Stack Overflow all super reliable 😊
// 5. Hmm. Looks like the font is too small.
// - Update the font-size of tile 5 to 35 pixels.
// 6. Another sad box!
// - Let make this tile 6 feel special and add a gradient background!
// - What kind of gradient? What color? YOU CHOOSE!
// 7. Too many squares.
// - Let's change tile 7 to have rounded edges - be sure to search for which CSS property does this :)
// 8. Replace the image with your favorite emoji.
// - Try going to this site to search: https://emojipedia.org/
// 9. Display a random number in the tile when the button is clicked.
// - BE SURE TO SAVE THE BUTTON FIRST AS A VARIABLE.