Skip to content

Commit

Permalink
bug fixes for chart
Browse files Browse the repository at this point in the history
  • Loading branch information
ronynn committed Jun 8, 2024
1 parent 76d3f23 commit 070a65b
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 49 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ Ronynn Weather is powered by the WTTR API for real-time weather data.
## Feedback
I'd love to hear your thoughts on Ronynn Weather! If you have any feedback, suggestions, or just want to say hi, don't hesitate to reach out.

Enjoy the weather in style with Ronynn Weather! 🌤️
Enjoy the weather in style with Ronynn Weather! 🌤️
1 change: 1 addition & 0 deletions chart.min.js

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions cookies.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

57 changes: 17 additions & 40 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -88,47 +88,39 @@

<body>
<nav>
<a href="https://ronynn.github.io"
><img src="https://github.com/ronynn.png"
/></a>
<a href="https://ronynn.github.io/weather"> ronynn weather </a>




<a href="https://github.com/ronynn/weather"
><img
src="https://img.shields.io/github/stars/ronynn/weather?style=social"
alt="stars - weather"
/></a>
</nav>

<br />
<br />


<form id="myForm" class="glassmorphism-form">
<input type="text" id="myInput" placeholder="Enter city name .." />
</form>

<h1 id="loc"></h1>
<h5 id="date" style="text-align: center"></h5>
<h2 id="desc" style="text-align:center"></h2>
<h2 id="desc" style="text-align: center"></h2>
<div class="panel">



<p id="desc"></p>

<p id="desc"></p>

<div class="left-panel">
<h1 id="temp"></h1>
</div>
<div class="right-panel" style="font-size: 1.5em">
<p id="minmax"></p>
</div>
<br/>
<div class="details">
<p id="detailsnow"></p>
</div>

<br />
<div class="details">
<p id="detailsnow"></p>
</div>
</div>


<div class="future">
<div class="div1">
<p id="tomorrow"></p>
Expand All @@ -141,11 +133,13 @@ <h1 id="temp"></h1>
<div id="today" class="tabcontent">
<canvas id="weatherCharttoday" width="400" height="200"></canvas
><br />
<div id="today1"></div>
</div>

<div id="nextday" class="tabcontent">
<canvas id="weatherChartnextday" width="400" height="200"></canvas
><br />
<div id="nextday1"></div>
</div>

<div id="nextnextday" class="tabcontent">
Expand All @@ -155,6 +149,7 @@ <h1 id="temp"></h1>
height="200"
></canvas
><br />
<div id="nextnextday1"></div>
</div>

<div id="buttons">
Expand All @@ -170,28 +165,10 @@ <h1 id="temp"></h1>
</button>
</div>

<footer>
<hr />
<a
href="https://github.com/ronynn/weather"
title="Go to GitHub repo"
><img
src="https://img.shields.io/static/v1?label=ronynn&message=weather&color=blue&logo=github"
alt="ronynn - weather"
/></a>
<a href="https://github.com/ronynn/weather"
><img
src="https://img.shields.io/github/stars/ronynn/weather?style=social"
alt="stars - weather"
/></a>
<hr />

<br />
</footer>
<script
type="text/javascript"
id="cookiebanner"
src="https://cdn.jsdelivr.net/gh/dobarkod/cookie-banner@1.2.2/dist/cookiebanner.min.js"
src="cookies.js"
data-height="25px"
data-position="bottom"
data-moreinfo="https://ronynn.github.io/blog/privacy"
Expand Down Expand Up @@ -220,7 +197,7 @@ <h1 id="temp"></h1>
tabcontent[i].style.display = "none";
}
document.getElementById(tabName).style.display = "block";
// document.getElementById(tabName).scrollIntoView({ behavior: "smooth", block: "center" });
// document.getElementById(tabName).scrollIntoView({ behavior: "smooth", block: "center" });
}
</script>
<script src="script.js"></script>
Expand Down
6 changes: 3 additions & 3 deletions script.js
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ function displayWeatherData(data) {
nextnextdaymin;

// For Today
document.getElementById("today").innerHTML += `
document.getElementById("today1").innerHTML = `
Today in ${loc}, ${region} <br/>(${todaydate}) <br/>
<table>
<tr>
Expand Down Expand Up @@ -379,7 +379,7 @@ Today in ${loc}, ${region} <br/>(${todaydate}) <br/>
<br/>
`;
// For Tomorrow
document.getElementById("nextday").innerHTML += `
document.getElementById("nextday1").innerHTML = `
Tommorow in ${loc}, ${region} <br/> (${nextdaydate}) <br/>
<table>
<tr>
Expand Down Expand Up @@ -451,7 +451,7 @@ Today in ${loc}, ${region} <br/>(${todaydate}) <br/>
`;
*/
// For Overmorrow
document.getElementById("nextnextday").innerHTML += `
document.getElementById("nextnextday1").innerHTML = `
Day after tommorow in ${loc}, ${region} <br/> (${nextnextdaydate})<br/>
<table>
<tr>
Expand Down
10 changes: 5 additions & 5 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -232,15 +232,15 @@ nav a {

nav a img {
padding: 0.2px;
width: 22px; /* Adjust image width as needed */
width: ; /* Adjust image width as needed */
margin: 0.2px; /* Add spacing between image and text */
}

nav a:hover {
background-color: rgba(255, 255, 255, 0.6);
}

nav a:nth-child(3) {
nav a:nth-child(2) {
margin-left: auto;
}

Expand All @@ -249,7 +249,7 @@ footer {
}

button {
background: transparent;
backdrop-filter: blur(5px);
border:0px;
background: transparent;
backdrop-filter: blur(5px);
border: 0px;
}

0 comments on commit 070a65b

Please sign in to comment.