diff --git a/BackgroundGenerator/Shivam250702/README.md b/BackgroundGenerator/Shivam250702/README.md new file mode 100644 index 000000000..f9bb65815 --- /dev/null +++ b/BackgroundGenerator/Shivam250702/README.md @@ -0,0 +1,6 @@ +This is a simple Background Generator Made using HTML,CSS and JS which allow user to input the color of its choice and change color from left to right. + + +![Alt text](image.png) +![Alt text](image-1.png) +![Alt text](image-2.png) \ No newline at end of file diff --git a/BackgroundGenerator/Shivam250702/image-1.png b/BackgroundGenerator/Shivam250702/image-1.png new file mode 100644 index 000000000..74ac2aa52 Binary files /dev/null and b/BackgroundGenerator/Shivam250702/image-1.png differ diff --git a/BackgroundGenerator/Shivam250702/image-2.png b/BackgroundGenerator/Shivam250702/image-2.png new file mode 100644 index 000000000..cbad0e115 Binary files /dev/null and b/BackgroundGenerator/Shivam250702/image-2.png differ diff --git a/BackgroundGenerator/Shivam250702/image.png b/BackgroundGenerator/Shivam250702/image.png new file mode 100644 index 000000000..83094cde2 Binary files /dev/null and b/BackgroundGenerator/Shivam250702/image.png differ diff --git a/BackgroundGenerator/Shivam250702/index.html b/BackgroundGenerator/Shivam250702/index.html new file mode 100644 index 000000000..8a3130f6a --- /dev/null +++ b/BackgroundGenerator/Shivam250702/index.html @@ -0,0 +1,15 @@ + + + + Gradient Background + + + +

Background Generator

+ + +

Current CSS Background

+

+ + + \ No newline at end of file diff --git a/BackgroundGenerator/Shivam250702/script.js b/BackgroundGenerator/Shivam250702/script.js new file mode 100644 index 000000000..579f96e71 --- /dev/null +++ b/BackgroundGenerator/Shivam250702/script.js @@ -0,0 +1,21 @@ +var css = document.querySelector("h3"); +var color1 = document.querySelector(".color1"); +var color2 = document.querySelector(".color2"); +var body = document.getElementById("gradient"); +var n=prompt("1st value want"); + var m=prompt("2nd,value want"); + body.style.background="linear-gradient(to right, "+n+","+m+")"; +function setGradient() { + body.style.background = + "linear-gradient(to right, " + + color1.value + + ", " + + color2.value + + ")"; + + css.textContent = body.style.background + ";"; +} + +color1.addEventListener("input", setGradient); + +color2.addEventListener("input", setGradient); diff --git a/BackgroundGenerator/Shivam250702/style.css b/BackgroundGenerator/Shivam250702/style.css new file mode 100644 index 000000000..f99dbe95f --- /dev/null +++ b/BackgroundGenerator/Shivam250702/style.css @@ -0,0 +1,27 @@ +body { + font: 'Raleway', sans-serif; + color: rgba(0,0,0,.5); + text-align: center; + text-transform: uppercase; + letter-spacing: .5em; + top: 15%; + background: linear-gradient(to right, red , yellow); /* Standard syntax */ +} + +h1 { + font: 600 3.5em 'Raleway', sans-serif; + color: rgba(0,0,0,.5); + text-align: center; + text-transform: uppercase; + letter-spacing: .5em; + width: 100%; +} + +h3 { + font: 900 1em 'Raleway', sans-serif; + color: rgba(0,0,0,.5); + text-align: center; + text-transform: none; + letter-spacing: 0.01em; + +}