diff --git a/DOM/bulb.html b/DOM/bulb.html new file mode 100644 index 0000000..9e714b2 --- /dev/null +++ b/DOM/bulb.html @@ -0,0 +1,35 @@ + + + + + + + + Image Carousel + + + + + + + + + +
+
+ +
+
+
+ +
+
+
+ + + + \ No newline at end of file diff --git a/DOM/strangerThings.html b/DOM/strangerThings.html new file mode 100644 index 0000000..f7055e8 --- /dev/null +++ b/DOM/strangerThings.html @@ -0,0 +1,260 @@ + + + + + + + + Document + + + + + + + +
+ +
+
+ A +
+
+ B +
+
+ C +
+
+ D +
+
+ E +
+
+ F +
+
+ G +
+
+ H +
+

+ +
+
+ I +
+
+ J +
+
+ K +
+
+ L +
+
+ M +
+
+ N +
+
+ O +
+
+ P +
+
+ Q +
+
+ +
+
+ R +
+
+ S +
+
+ T +
+
+ U +
+
+ V +
+
+ W +
+
+ X +
+
+ Y +
+
+ Z +
+
+
+ + +
+ + + + + \ No newline at end of file diff --git a/src/strangerThings.js b/src/strangerThings.js new file mode 100644 index 0000000..b55ab17 --- /dev/null +++ b/src/strangerThings.js @@ -0,0 +1,53 @@ + +let ele; +function sleep(ms) { + return new Promise(resolve => setTimeout(resolve, ms)); + } +async function illuminateLight(index) +{ + let message=document.getElementById("message").value; + message=message.toLocaleUpperCase(); + message=message.split(" ").join("") + //window.alert(message) +for(let i=0;i=0 && index<=7) + { + ele=document.getElementById("setOne").getElementsByTagName("li") + } + else if(index>=8&&index<=16) + { + ele=document.getElementById("setTwo").getElementsByTagName("li") + index=index-8; + } + else if(index>=17&&index<=25) + { + ele=document.getElementById("setThree").getElementsByTagName("li") + index=index-17; + } + //window.alert(ele[index]) + if(index%2!=0) + { //PINK + ele[index].style.backgroundColor='#ff99ff'; + colorValue='rgba(255,105,180,0.9)' + ele[index].style.boxShadow='0px 2px 20px 4px #ffff00'; + } + + else + { + //BLUE + ele[index].style.backgroundColor='aqua'; + colorValue='rgba(0,153,255,0.8)' + ele[index].style.boxShadow='0px 2px 20px 4px #ffff00'; + } + + await sleep(1000) + //window.alert(colorValue) + ele[index].style.backgroundColor=colorValue; + ele[index].style.boxShadow='0px 2px 20px 4px '+colorValue; + await sleep(500) + } + +}