Compare commits

...

8 commits

Author SHA1 Message Date
cfe916ec72 bump to version 0.1.11 2025-10-06 11:08:52 -05:00
01b9644243 fix: update source code info for about page 2025-10-06 11:06:53 -05:00
Lance Edgar
52b83d05bb build: explicitly use npm lts/iron when building package 2024-07-02 19:49:25 -05:00
Lance Edgar
a09d50af2c Update changelog 2024-06-09 19:32:46 -05:00
Lance Edgar
c92d9aae0d Fix URL bug when refreshing weather radar 2024-06-09 19:32:17 -05:00
Lance Edgar
d4cf4e1c3e Update changelog 2024-06-09 19:28:02 -05:00
Lance Edgar
fa1e702173 Add timestamp param to bust cache when refreshing radar images 2024-06-09 19:26:42 -05:00
Lance Edgar
cd615cb020 Warning notification should not butt up against forecast panel 2024-06-09 16:41:27 -05:00
8 changed files with 46 additions and 14 deletions

1
.gitignore vendored
View file

@ -28,3 +28,4 @@ coverage
*.sw? *.sw?
*.tsbuildinfo *.tsbuildinfo
*~

View file

@ -7,6 +7,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## Unreleased ## Unreleased
## 0.1.11 - 2025-10-06
### Changed
- update source code info for about page
## 0.1.10 - 2024-06-09
### Changed
- Fix URL bug when refreshing weather radar.
## 0.1.9 - 2024-06-09
### Changed
- Warning notification should not butt up against forecast panel.
- Add timestamp param to bust cache when refreshing radar images.
## 0.1.8 - 2024-06-09 ## 0.1.8 - 2024-06-09
### Added ### Added
- Add link to national radar map (live image). - Add link to national radar map (live image).

4
package-lock.json generated
View file

@ -1,12 +1,12 @@
{ {
"name": "myweather", "name": "myweather",
"version": "0.1.8", "version": "0.1.11",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "myweather", "name": "myweather",
"version": "0.1.8", "version": "0.1.11",
"dependencies": { "dependencies": {
"@fortawesome/fontawesome-svg-core": "^6.5.2", "@fortawesome/fontawesome-svg-core": "^6.5.2",
"@fortawesome/free-solid-svg-icons": "^6.5.2", "@fortawesome/free-solid-svg-icons": "^6.5.2",

View file

@ -1,6 +1,6 @@
{ {
"name": "myweather", "name": "myweather",
"version": "0.1.8", "version": "0.1.11",
"private": true, "private": true,
"type": "module", "type": "module",
"scripts": { "scripts": {

View file

@ -131,7 +131,7 @@ export const useWeatherStore = defineStore('weather', {
if (!this.forecast) { if (!this.forecast) {
const weather = await this.getWeather(this.coordinates) const weather = await this.getWeather()
const url = weather.properties.forecast const url = weather.properties.forecast
const response = await fetch(url) const response = await fetch(url)

View file

@ -28,12 +28,13 @@ import appsettings from '../appsettings'
</p> </p>
<p class="block"> <p class="block">
Source code is not currently browseable online but you can get it with: Source code is available at
</p> <a href="https://forgejo.wuttaproject.org/lance/myweather" target="_blank">
<span class="icon-text">
<p class="block is-family-monospace" <o-icon icon="external-link" />
style="padding-left: 4rem;"> <span>https://forgejo.wuttaproject.org/lance/myweather</span>
git clone https://git.edbob.org/readonly/myweather.git </span>
</a>
</p> </p>
<p class="block"> <p class="block">

View file

@ -11,6 +11,7 @@ const weatherStore = useWeatherStore()
const coordinates = ref(null) const coordinates = ref(null)
const refreshing = ref(false) const refreshing = ref(false)
const timestamp = ref(new Date().getTime())
const panelHeadingTitle = computed(() => { const panelHeadingTitle = computed(() => {
@ -24,6 +25,20 @@ const panelHeadingTitle = computed(() => {
}) })
const radarLatestURL = computed(() => {
if (weatherStore.weather) {
return `${weatherStore.radarLatestURL}?t=${timestamp.value}`
}
})
const radarLoopURL = computed(() => {
if (weatherStore.weather) {
return `${weatherStore.radarLoopURL}?t=${timestamp.value}`
}
})
onActivated(() => { onActivated(() => {
if (!weatherStore.coordinates) { if (!weatherStore.coordinates) {
@ -56,6 +71,7 @@ async function fetchWeather() {
async function refreshWeather() { async function refreshWeather() {
refreshing.value = true refreshing.value = true
weatherStore.clearWeather(true) weatherStore.clearWeather(true)
timestamp.value = new Date().getTime()
await fetchWeather() await fetchWeather()
refreshing.value = false refreshing.value = false
} }
@ -95,7 +111,8 @@ function showHourly(period) {
</o-button> </o-button>
</div> </div>
<div v-if="weatherStore.alerts?.features?.length"> <div v-if="weatherStore.alerts?.features?.length"
class="block">
<o-notification variant="warning" <o-notification variant="warning"
icon="warning" icon="warning"
@click="$router.push('/alerts')" @click="$router.push('/alerts')"
@ -162,10 +179,10 @@ function showHourly(period) {
<div class="panel-block"> <div class="panel-block">
<div class="columns"> <div class="columns">
<div class="column"> <div class="column">
<img :src="weatherStore.radarLatestURL" /> <img :src="radarLatestURL" />
</div> </div>
<div class="column"> <div class="column">
<img :src="weatherStore.radarLoopURL" /> <img :src="radarLoopURL" />
</div> </div>
</div> </div>
</div> </div>

View file

@ -24,7 +24,7 @@ def release(c):
version = js['version'] version = js['version']
# build the app, create zip archive # build the app, create zip archive
c.run('npm run build') c.run("bash -lc 'nvm use lts/iron; npm run build'")
os.chdir('dist') os.chdir('dist')
filename = f'myweather-{version}.zip' filename = f'myweather-{version}.zip'
c.run(f'zip --recurse-paths {filename} *') c.run(f'zip --recurse-paths {filename} *')