From c38903097206ce13a33064e1bcab7a6873ef5d43 Mon Sep 17 00:00:00 2001 From: OMGiTzPomPom Date: Thu, 10 Nov 2022 13:46:32 +0100 Subject: [PATCH] js --- tp1/{ => tp1.0}/css/style.css | 0 tp1/{ => tp1.0}/img/DSC_0852 (1)_edited 1.png | Bin tp1/{ => tp1.0}/img/Group 1.png | Bin tp1/{ => tp1.0}/img/Instagram.png | Bin tp1/{ => tp1.0}/img/LOGOsimple noir 1.png | Bin tp1/{ => tp1.0}/img/Linkedin.png | Bin tp1/{ => tp1.0}/img/Logo.png | Bin tp1/{ => tp1.0}/img/Patient.png | Bin tp1/{ => tp1.0}/img/Pro.png | Bin .../img/akar-icons_facebook-fill.png | Bin ...€”kitchen supplies wooden shovel_4581308 1.png | Bin ...ee—many kinds of vegetables in_7257107 1.png | Bin ...ee—many kinds of vegetables in_7257107 2.png | Bin ...ee—many kinds of vegetables in_7257107 3.png | Bin tp1/{ => tp1.0}/index.html | 0 {tp1.1 => tp1/tp1.1}/index.html | 0 tp1/tp1.2/index.html | 41 ++++++++++++ tp1/tp1.2/style.css | 9 +++ tp1/tp1.3/index.html | 57 ++++++++++++++++ tp1/tp1.3/style.css | 9 +++ tp1/tp1.4/index.html | 41 ++++++++++++ tp1/tp1.4/style.css | 9 +++ tp2/tp2.0/1.html | 63 ++++++++++++++++++ tp2/tp2.0/2.html | 25 +++++++ tp2/tp2.0/data.json | 40 +++++++++++ tp2/tp2.0/script.js | 56 ++++++++++++++++ tp2/tp2.0/style.css | 8 +++ 27 files changed, 358 insertions(+) rename tp1/{ => tp1.0}/css/style.css (100%) rename tp1/{ => tp1.0}/img/DSC_0852 (1)_edited 1.png (100%) rename tp1/{ => tp1.0}/img/Group 1.png (100%) rename tp1/{ => tp1.0}/img/Instagram.png (100%) rename tp1/{ => tp1.0}/img/LOGOsimple noir 1.png (100%) rename tp1/{ => tp1.0}/img/Linkedin.png (100%) rename tp1/{ => tp1.0}/img/Logo.png (100%) rename tp1/{ => tp1.0}/img/Patient.png (100%) rename tp1/{ => tp1.0}/img/Pro.png (100%) rename tp1/{ => tp1.0}/img/akar-icons_facebook-fill.png (100%) rename tp1/{ => tp1.0}/img/—Pngtree—kitchen supplies wooden shovel_4581308 1.png (100%) rename tp1/{ => tp1.0}/img/—Pngtree—many kinds of vegetables in_7257107 1.png (100%) rename tp1/{ => tp1.0}/img/—Pngtree—many kinds of vegetables in_7257107 2.png (100%) rename tp1/{ => tp1.0}/img/—Pngtree—many kinds of vegetables in_7257107 3.png (100%) rename tp1/{ => tp1.0}/index.html (100%) rename {tp1.1 => tp1/tp1.1}/index.html (100%) create mode 100644 tp1/tp1.2/index.html create mode 100644 tp1/tp1.2/style.css create mode 100644 tp1/tp1.3/index.html create mode 100644 tp1/tp1.3/style.css create mode 100644 tp1/tp1.4/index.html create mode 100644 tp1/tp1.4/style.css create mode 100644 tp2/tp2.0/1.html create mode 100644 tp2/tp2.0/2.html create mode 100644 tp2/tp2.0/data.json create mode 100644 tp2/tp2.0/script.js create mode 100644 tp2/tp2.0/style.css diff --git a/tp1/css/style.css b/tp1/tp1.0/css/style.css similarity index 100% rename from tp1/css/style.css rename to tp1/tp1.0/css/style.css diff --git a/tp1/img/DSC_0852 (1)_edited 1.png b/tp1/tp1.0/img/DSC_0852 (1)_edited 1.png similarity index 100% rename from tp1/img/DSC_0852 (1)_edited 1.png rename to tp1/tp1.0/img/DSC_0852 (1)_edited 1.png diff --git a/tp1/img/Group 1.png b/tp1/tp1.0/img/Group 1.png similarity index 100% rename from tp1/img/Group 1.png rename to tp1/tp1.0/img/Group 1.png diff --git a/tp1/img/Instagram.png b/tp1/tp1.0/img/Instagram.png similarity index 100% rename from tp1/img/Instagram.png rename to tp1/tp1.0/img/Instagram.png diff --git a/tp1/img/LOGOsimple noir 1.png b/tp1/tp1.0/img/LOGOsimple noir 1.png similarity index 100% rename from tp1/img/LOGOsimple noir 1.png rename to tp1/tp1.0/img/LOGOsimple noir 1.png diff --git a/tp1/img/Linkedin.png b/tp1/tp1.0/img/Linkedin.png similarity index 100% rename from tp1/img/Linkedin.png rename to tp1/tp1.0/img/Linkedin.png diff --git a/tp1/img/Logo.png b/tp1/tp1.0/img/Logo.png similarity index 100% rename from tp1/img/Logo.png rename to tp1/tp1.0/img/Logo.png diff --git a/tp1/img/Patient.png b/tp1/tp1.0/img/Patient.png similarity index 100% rename from tp1/img/Patient.png rename to tp1/tp1.0/img/Patient.png diff --git a/tp1/img/Pro.png b/tp1/tp1.0/img/Pro.png similarity index 100% rename from tp1/img/Pro.png rename to tp1/tp1.0/img/Pro.png diff --git a/tp1/img/akar-icons_facebook-fill.png b/tp1/tp1.0/img/akar-icons_facebook-fill.png similarity index 100% rename from tp1/img/akar-icons_facebook-fill.png rename to tp1/tp1.0/img/akar-icons_facebook-fill.png diff --git a/tp1/img/—Pngtree—kitchen supplies wooden shovel_4581308 1.png b/tp1/tp1.0/img/—Pngtree—kitchen supplies wooden shovel_4581308 1.png similarity index 100% rename from tp1/img/—Pngtree—kitchen supplies wooden shovel_4581308 1.png rename to tp1/tp1.0/img/—Pngtree—kitchen supplies wooden shovel_4581308 1.png diff --git a/tp1/img/—Pngtree—many kinds of vegetables in_7257107 1.png b/tp1/tp1.0/img/—Pngtree—many kinds of vegetables in_7257107 1.png similarity index 100% rename from tp1/img/—Pngtree—many kinds of vegetables in_7257107 1.png rename to tp1/tp1.0/img/—Pngtree—many kinds of vegetables in_7257107 1.png diff --git a/tp1/img/—Pngtree—many kinds of vegetables in_7257107 2.png b/tp1/tp1.0/img/—Pngtree—many kinds of vegetables in_7257107 2.png similarity index 100% rename from tp1/img/—Pngtree—many kinds of vegetables in_7257107 2.png rename to tp1/tp1.0/img/—Pngtree—many kinds of vegetables in_7257107 2.png diff --git a/tp1/img/—Pngtree—many kinds of vegetables in_7257107 3.png b/tp1/tp1.0/img/—Pngtree—many kinds of vegetables in_7257107 3.png similarity index 100% rename from tp1/img/—Pngtree—many kinds of vegetables in_7257107 3.png rename to tp1/tp1.0/img/—Pngtree—many kinds of vegetables in_7257107 3.png diff --git a/tp1/index.html b/tp1/tp1.0/index.html similarity index 100% rename from tp1/index.html rename to tp1/tp1.0/index.html diff --git a/tp1.1/index.html b/tp1/tp1.1/index.html similarity index 100% rename from tp1.1/index.html rename to tp1/tp1.1/index.html diff --git a/tp1/tp1.2/index.html b/tp1/tp1.2/index.html new file mode 100644 index 0000000..8ec53b2 --- /dev/null +++ b/tp1/tp1.2/index.html @@ -0,0 +1,41 @@ + + + + + + + Document + + + + + + + +
+
+
Col 1/2
+
Col 2/2
+
+ +
+
Col 1/2
+
Col 2/2
+
+ +
+
Col 1/2
+
Col 2/2
+
+ +
+
Col 1/3
+
Col 2/3
+
Col 3/3
+
+
+ + + + + \ No newline at end of file diff --git a/tp1/tp1.2/style.css b/tp1/tp1.2/style.css new file mode 100644 index 0000000..ae93b7a --- /dev/null +++ b/tp1/tp1.2/style.css @@ -0,0 +1,9 @@ +.custom-line { + min-height: 5rem; + margin-bottom: 1rem; + background-color: rgba(60, 240, 160, 0.7); +} + +.custom-line > .col { + background-color: rgba(60, 120, 160, 0.7); +} \ No newline at end of file diff --git a/tp1/tp1.3/index.html b/tp1/tp1.3/index.html new file mode 100644 index 0000000..98d480d --- /dev/null +++ b/tp1/tp1.3/index.html @@ -0,0 +1,57 @@ + + + + + + + Document + + + + + + + +
+
+
Justify Content 1/2
+
Justify Content 2/2
+
+ +
+
Justify Content 1/2
+
Justify Content 2/2
+
+ +
+
Justify Content 1/2
+
Justify Content 2/2
+
+ +
+
Justify Content 1/2
+
Justify Content 2/2
+
+ +
+
Justify Content 1/2
+
Justify Content 2/3
+
Justify Content 3/3
+
+ +
+
Justify Content 1/2
+
Justify Content 2/2
+
+ +
+
Justify Content 1/2
+
Justify Content 2/3
+
Justify Content 3/3
+
+
+ + + + + \ No newline at end of file diff --git a/tp1/tp1.3/style.css b/tp1/tp1.3/style.css new file mode 100644 index 0000000..b81eeba --- /dev/null +++ b/tp1/tp1.3/style.css @@ -0,0 +1,9 @@ +.custom-line { + min-height: 5rem; + margin-bottom: 1rem; + background-color: rgba(0, 255, 140, 0.7); +} + +.custom-line > .col { + background-color: rgba(0, 152, 253, 0.7); +} \ No newline at end of file diff --git a/tp1/tp1.4/index.html b/tp1/tp1.4/index.html new file mode 100644 index 0000000..2910322 --- /dev/null +++ b/tp1/tp1.4/index.html @@ -0,0 +1,41 @@ + + + + + + + Document + + + + + + + +
+
+
Div
+
Div
+
Div
+
Div
+
+ +
+
Div
+
Div
+
Div
+
Div
+
+ +
+
Div
+
Div
+
Div
+
Div
+
+
+ + + + + \ No newline at end of file diff --git a/tp1/tp1.4/style.css b/tp1/tp1.4/style.css new file mode 100644 index 0000000..b81eeba --- /dev/null +++ b/tp1/tp1.4/style.css @@ -0,0 +1,9 @@ +.custom-line { + min-height: 5rem; + margin-bottom: 1rem; + background-color: rgba(0, 255, 140, 0.7); +} + +.custom-line > .col { + background-color: rgba(0, 152, 253, 0.7); +} \ No newline at end of file diff --git a/tp2/tp2.0/1.html b/tp2/tp2.0/1.html new file mode 100644 index 0000000..7bca728 --- /dev/null +++ b/tp2/tp2.0/1.html @@ -0,0 +1,63 @@ + + + + + + + + + Super Hero Squad + + +
+
+ +
+
+ +
+
+
+

Molecule Man

+

Secret Identity : Dan Jukes

+

Age : 29

+

Superpowers :

+
    +
  • Radiation Resistance
  • +
  • Turning Tiny
  • +
  • Radiation Blast
  • +
+
+ +
+

Madame Uppercut

+

Secret Identity : Jane Wilson

+

Age : 39

+

Superpowers :

+
    +
  • Million Tone punch
  • +
  • Damage resistance
  • +
  • Superhuman reflexes
  • +
+
+ +
+

Eternal Flame

+

Secret Identity : Unknown

+

Age : 100000

+

Superpowers :

+
    +
  • Immortality
  • +
  • Heat Immunity
  • +
  • Inferno
  • +
  • Teleportation
  • +
  • Interdimensional travel
  • +
+
+
+
+ + \ No newline at end of file diff --git a/tp2/tp2.0/2.html b/tp2/tp2.0/2.html new file mode 100644 index 0000000..772cbd6 --- /dev/null +++ b/tp2/tp2.0/2.html @@ -0,0 +1,25 @@ + + + + + + + + Super Hero Squad + + +
+
+ +
+
+ +
+
+ +
+
+ + + \ No newline at end of file diff --git a/tp2/tp2.0/data.json b/tp2/tp2.0/data.json new file mode 100644 index 0000000..8c3d67f --- /dev/null +++ b/tp2/tp2.0/data.json @@ -0,0 +1,40 @@ +{ + "SquadName" : "Super Hero Squad", + "HomeTown" : "Metro City", + "formed" : 2022, + "members" : [ + { + "name" : "Molecule Man", + "age" : "29", + "secretIdentity" : "Dan Jukes", + "powers" : [ + "Radiation Resistance", + "Turning Tiny", + "Radiation Blast" + ] + }, + { + "name" : "Madame Uppercut", + "age" : "39", + "secretIdentity" : "Jane Wilson", + "powers" : [ + "Million Tone punch", + "Damage resistance", + "Superhuman reflexes" + ] + + }, + { + "name" : "Eternal Flame", + "age" : "100000", + "secretIdentity" : "Unknown", + "powers" : [ + "Immortality", + "Heat Immunity", + "Inferno", + "Teleportation", + "Interdimensional travel" + ] + } + ] +} diff --git a/tp2/tp2.0/script.js b/tp2/tp2.0/script.js new file mode 100644 index 0000000..187e77f --- /dev/null +++ b/tp2/tp2.0/script.js @@ -0,0 +1,56 @@ +let requestURL = './data.json'; +let request = new XMLHttpRequest(); +request.open('GET', requestURL); +request.responseType = 'json'; +request.send(); + +request.onload = function() { + let superHeroes = request.response; + console.log(superHeroes); + + + const headerAnchor = document.getElementById('header'); + + var headerH1 = document.createElement('h1'); + var headerP = document.createElement('p'); + headerH1.textContent = superHeroes["SquadName"]; + headerP.textContent = "Hometown : " + superHeroes["HomeTown"]; + + headerAnchor.appendChild(headerH1); + headerAnchor.appendChild(headerP); + + const contentAnchor = document.getElementById('content'); + + for (let i = 0; i < 3; ++i) { + + let article = document.createElement('article'); + let h2 = document.createElement('h2'); + let p = document.createElement('p'); + let p2 = document.createElement('p'); + let p3 = document.createElement('p'); + let ul = document.createElement('ul'); + + article.classList.add('col-4'); + h2.textContent = superHeroes["members"][i]["name"]; + p.textContent = "Secret Identity : " + superHeroes["members"][i]["secretIdentity"]; + p2.textContent = "Age : " + superHeroes["members"][i]["age"]; + p3.textContent = "Powers :"; + + contentAnchor.appendChild(article); + article.appendChild(h2); + article.appendChild(p); + article.appendChild(p2); + article.appendChild(p3); + article.appendChild(ul); + + superHeroes["members"][i]["powers"].forEach(power => { + let li = document.createElement('li'); + li.textContent = power; + ul.appendChild(li); + }); + + + } + + +} diff --git a/tp2/tp2.0/style.css b/tp2/tp2.0/style.css new file mode 100644 index 0000000..b4cc12c --- /dev/null +++ b/tp2/tp2.0/style.css @@ -0,0 +1,8 @@ +body { + border: 1px solid #000000; + width: 75%; + margin: 20px auto; + position: absolute; + top: 50%; left: 50%; + transform: translate(-50%, -50%); +} \ No newline at end of file