diff --git a/glance-system/glance-kisfenyo.yaml b/glance-system/glance-kisfenyo.yaml
index da0b57c..c22cc51 100644
--- a/glance-system/glance-kisfenyo.yaml
+++ b/glance-system/glance-kisfenyo.yaml
@@ -365,69 +365,90 @@ data:
- type: split-column
max-columns: 3
widgets:
- # Weather Widget
+ # Weather Widget - Időkép Scraper
- type: custom-api
- url: https://www.idokep.hu/idojaras/Budapest
- cache: 15m
- style:
- grid-column: span 4
- grid-row: span 3
- template: |
- {{/* Extract Current Weather Data */}}
- {{ $body := .Body }}
- {{ $temp := findSubmatch `(?s)current-temperature">([^˚<]+)` $body }}
- {{ $condition := findSubmatch `(?s)current-weather">([^<]+)` $body }}
- {{ $icon := findSubmatch `(?s)forecast-bigicon"[^>]+src="([^"]+)"` $body }}
- {{ $sunrise := findSubmatch `Napkelte ([0-9:]+)` $body }}
- {{ $sunset := findSubmatch `Napnyugta ([0-9:]+)` $body }}
-
-
- {{/* Header: Location and Current Time */}}
-
-
-
Budapest
-
{{ now | formatTime "Monday, Jan 02" }}
-
-
-
- ↑ {{ $sunrise }}
- ↓ {{ $sunset }}
-
-
-
+ url: https://www.idokep.hu/idojaras/Budapest
+ cache: 15m
+ style:
+ grid-column: span 4
+ grid-row: span 3
+ template: |
+ {{/* 1. Extract Current Data */}}
+ {{ $body := .Body }}
+ {{ $temp := findSubmatch `(?s)current-temperature">([^˚<]+)` $body | trimSpace }}
+ {{ $cond := findSubmatch `(?s)current-weather">([^<]+)
` $body | trimSpace }}
+ {{ $icon := findSubmatch `(?s)forecast-bigicon"[^>]+src="([^"]+)"` $body }}
+ {{ $sunrise := findSubmatch `Napkelte ([0-9:]+)` $body }}
+ {{ $sunset := findSubmatch `Napnyugta ([0-9:]+)` $body }}
- {{/* Main Current Weather Display */}}
-
- {{/* Helper to extract a specific day's data using regex index-based groups is limited in Go templates,
- so we extract the forecast block and manually grab the first few days. */}}
-
- {{ range $i := (list 1 2 3 4 5) }}
- {{/* This logic identifies the columns in the daily forecast grid */}}
- {{ $dayPattern := printf `(?s)dailyForecastCol.*?dfDayNum">([0-9]+).*?dfDay">([^<]+).*?src="([^"]+)".*?max[^>]+>([^<]+).*?min[^>]+>([^<]+)` }}
- {{/* Note: Standard Glance regex findSubmatch returns the first match. To get multiple days,
- we'd ideally need a loop. Since Glance regex is for single matches,
- we'll use the current logic to display the next primary data points. */}}
- {{ end }}
+ {{/* Day 2 (skipping 1 column) */}}
+ {{ $d2_pat := `(?s)dailyForecastCol.*?dailyForecastCol.*?dfDayNum">([0-9]+).*?dfDay">([^<]+).*?src="([^"]+)".*?max[^>]+>([^<]+).*?min[^>]+>([^<]+)` }}
+ {{ $d2_day := index (findSubmatch $d2_pat $body) 1 }}
+ {{ $d2_icon := index (findSubmatch $d2_pat $body) 2 }}
+ {{ $d2_max := index (findSubmatch $d2_pat $body) 3 }}
+ {{ $d2_min := index (findSubmatch $d2_pat $body) 4 }}
- {{/* Fallback to detailed view link if scraping multiple days is too complex for standard regex */}}
-
-
-
+
+
+