Skip to content
RockENZOPublic

About

MyWeather is a SwiftUI-based weather app that provides real-time weather information based on the user’s location. It features smooth launching animations, advanced loading effects, and displays key weather details like temperature, wind speed, and humidity. Built with iOS 16+ and Swift 5.5+.

Topics

Resources

Stars

2 stars

Watchers

1 watching

Forks

Repository files navigation

MyWeather

MyWeather is a SwiftUI-based weather application that provides current weather information based on the user's location. The app features a launching animation, a loading view with advanced animations, and an iOS 26-inspired Liquid Glass redesign.

Demo

MyWeather App Demo

Actual iOS Simulator recording using an Adelaide weather/forecast capture from OpenWeather, collected on 22 October 2026 at 12:42:48 UTC. The recording replays that capture; it is not a continuous live weather connection. It shows the current UI and card interactions, with source/capture time visible in-frame. See capture metadata and recording instructions.

Features

  • Current weather data (temperature, feels like, min/max, humidity, wind, pressure, visibility, cloudiness)
  • 3-hour forecast observations displayed as a smooth line graph
  • Location-based weather using CoreLocation
  • Launch animation with smooth transitions
  • Loading view with animated color cycling
  • iOS 26 Liquid Glass redesign: translucent, adaptive materials with dynamic opacity on interaction
  • Dark mode support with adaptive text colors
  • Smooth drag‑up card to reveal map details
  • Recoverable states: a failed weather request shows a retry action instead of a permanent spinner, and denied location permission explains the problem with a Settings shortcut

Requirements

  • iOS 16.0+ (designed for iOS 26 Liquid Glass effects)
  • Xcode 15.0+
  • Swift 5.5+

Installation

  1. Clone the repository
  2. Open the project in Xcode
  3. Build and run the project on your simulator or device.

Usage

  1. On launch, the app displays a launching animation.
  2. After the animation, the app requests location permissions.
  3. Once the location is obtained, the app fetches the current weather data.
  4. The main screen displays the temperature, wind speed, and humidity.
  5. Drag the “Weather now” card upward to reveal the map and more details; the card’s glass opacity increases as you drag.
  6. View the forecast line graph to see the temperature trend.

Code Overview

  • LaunchView – Displays the launching animation and transitions to ContentView.
  • ContentView – Manages the display of LaunchView and the main weather content.
  • WeatherRow – Displays individual weather information (temperature, wind speed, humidity).
  • LocationManager – Handles location services and provides the user's current location.
  • WeatherManager – Fetches weather data from the OpenWeatherMap API based on the user's location.
  • LineGraph – Displays the hourly forecast using a smoothed line graph with Liquid Glass background.
  • Extensions.swift – Contains glassBackground, glassCard, elevatedGlass view modifiers and adaptive color helpers.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Acknowledgements

Reliability checks

Hourly forecast geometry handles empty input, a single observation, constant values and nonfinite temperatures. A single observation and a flat series are centered vertically; invalid temperatures are omitted and an empty valid series shows an unavailable state. The loading screen's colour loop is scoped to its SwiftUI task and cancelled when the view leaves the hierarchy.

Run the geometry checks without an API key or network access:

swiftc MyWeather/ForecastGeometry.swift scripts/test-forecast.swift -o /tmp/test-forecast
/tmp/test-forecast

CI also builds the iOS Simulator app without signing. These checks do not verify live weather responses, device permissions or rendered UI appearance.

About

MyWeather is a SwiftUI-based weather app that provides real-time weather information based on the user’s location. It features smooth launching animations, advanced loading effects, and displays key weather details like temperature, wind speed, and humidity. Built with iOS 16+ and Swift 5.5+.

Topics

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages