Skip to content

v2.0.0

Latest

Choose a tag to compare

@arshaviras arshaviras released this 20 Nov 19:30

What's new

Each user can now set up the weather widget themselves, and a dashboard can show several weather cards.

Added

  • Settings window (gear button). Each user can change the location, units, refresh interval, icon set and variant, and width. Choices are saved per user. Turn this off with 'user_settings' => false.
  • Location search. Search any place by name, or use the browser's location (needs HTTPS). Turn this off with 'location_search' => false.
  • Daily forecast with an Hourly / Daily / Both switch, remembered per user.
  • Chance of precipitation in the forecast, and the day name on the first hourly slot after midnight.
  • "Updated HH:MM" in the viewer's own time, with a refresh button (limited to once a minute per widget).
  • Loading overlay while the widget updates.
  • Wind direction as compass text (N, NE, …).
  • WeatherWidgets: users can duplicate and remove their own weather cards (at least 1, at most max_widgets).
  • WeatherWidget::make([...]) to put several widgets with different options on one dashboard, and a columnSpan option. The layout adapts to the widget's width.
  • Test suite and CI (PHP 8.2–8.4, Laravel 12–13, Filament 4–5).

Fixed

  • Icons from different sets (fill / line / monochrome, static / animated) no longer break each other on the same page.
  • No more -0°.

Changed

  • Visibility, rain and pressure follow the units setting (km/mi, mm/in, hPa/inHg).
  • Unit labels and "N/A" moved to the translation files.

⚠️ Breaking changes

  • Laravel 11 is no longer supported. Stay on 1.x if you need it.
  • Built-in city list removed. The city dropdown and the cities translation key are gone; users search for places instead. A city picked from the old list resets to your configured city.
  • Published views: if you published widget.blade.php, re-publish it. The view now receives formatted values.
  • WeatherCurrentResource: $wind_speed and $wind_deg are now $windSpeed and $windDegrees.

Upgrading

  1. composer require arshaviras/weather-widget:^2.0
  2. php artisan filament:assets
  3. Compare your published config with the new one. New keys: forecast_view, user_settings, location_search, max_widgets.

See the README for details.