Skip to content

Commit

Permalink
better sliders #13
Browse files Browse the repository at this point in the history
  • Loading branch information
apoorvagnihotri committed Apr 16, 2020
1 parent 174e3e5 commit 61eb725
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
9 changes: 7 additions & 2 deletions public/css/styles.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
.controls{
display: inline-flex;
width: -webkit-fill-available;
text-align: center;
}

.column {
width: 45%;
}
Expand Down Expand Up @@ -316,8 +322,7 @@ img {vertical-align: middle;}

/*Taken from https://www.w3schools.com/howto/howto_js_rangeslider.asp*/
.slidecontainer {
width: 80%;
float: left;
width: -webkit-fill-available;
}

.slider {
Expand Down
6 changes: 1 addition & 5 deletions public/js/gif-slider.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,15 @@ function appendInputButtons() {
button2.appendChild(document.createTextNode(">"))
button2.setAttribute("onclick",
"changePng(this.parentNode.parentNode.parentNode, true)")
button2.setAttribute("padding-top", "5px")

div.setAttribute("align", "center")
div.setAttribute("class", "controls")

var div1 = document.createElement("div")
div1.appendChild(button1)
div1.setAttribute("float", "left")
var div2 = document.createElement("div")
div2.setAttribute("class", "slidecontainer")
div2.setAttribute("float", "left")
div2.appendChild(input)
var div3 = document.createElement("div")
div3.setAttribute("float", "right")
div3.appendChild(button2)

div.appendChild(div1)
Expand Down

0 comments on commit 61eb725

Please sign in to comment.