Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fixed bar
  • Loading branch information
met18001 committed May 8, 2020
1 parent a7c70a8 commit e0681cd
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 21 deletions.
7 changes: 6 additions & 1 deletion final_project/css/style.css
Expand Up @@ -112,7 +112,8 @@ h1{
border-radius: 2.75px;
background-color: white;
box-shadow: 0 4px 8px 0 hsla(162, 93%, 72%, 0.87), 0 6px 20px 0 hsla(162, 93%, 72%, 0.87);
width: 50vw;
width: 400px;

}

.bar .progress {
Expand All @@ -134,4 +135,8 @@ h1{
max-width: 25px;
min-width: 25px;
}
.bar{
width: 350px;
}

}
24 changes: 4 additions & 20 deletions final_project/js/this.js
Expand Up @@ -10,12 +10,7 @@ if (curHr < 12) {
document.getElementById('morning').innerText ='morning'
for(let i=0;i<numItemsToGenerate;i++){
rendermoringItem();
var img = new Image();
var div = document.getElementById('logo');
img.onload = function() {
div.innerHTML += '<img src="'+img.src+'" />';
};
img.src = ('../final_project/img/nature.png');




Expand All @@ -24,24 +19,13 @@ if (curHr < 12) {
document.getElementById('morning').innerText ='afternoon'
for(let i=0;i<numItemsToGenerate;i++){
renderafternoonItem();
var img = new Image();
var div = document.getElementById('logo');
img.onload = function() {
div.innerHTML += '<img src="'+img.src+'" />';
};
img.src = ('../final_project/img/weather.png');

}
} else {
document.getElementById('morning').innerText ='night'
for(let i=0;i<numItemsToGenerate;i++){
rendernightItem();

var img = new Image();
var div = document.getElementById('logo');
img.onload = function() {
div.innerHTML += '<img src="'+img.src+'" />';
};
img.src = ('../final_project/img/night.png');

}
}
Expand Down Expand Up @@ -127,6 +111,6 @@ retrieveSavedText();
//setting width of bar based on day
setInterval(function () {
var now = new Date();
document.getElementById('hours').style.width = ((now.getHours() / 24) * 750) + 'px';
}, 1000);
document.getElementById('hours').style.width = ((now.getHours() / 24) * 300) + 'px';
}, 250);

0 comments on commit e0681cd

Please sign in to comment.