Skip to content

add Weather tab with minimal, scoped integration#1086

Open
MaydayV wants to merge 3 commits intoTheBoredTeam:devfrom
MaydayV:dev
Open

add Weather tab with minimal, scoped integration#1086
MaydayV wants to merge 3 commits intoTheBoredTeam:devfrom
MaydayV:dev

Conversation

@MaydayV
Copy link

@MaydayV MaydayV commented Mar 6, 2026

image

Title

feat(weather): add Weather tab with minimal, scoped integration

Summary

This PR adds a Weather feature to the notch UI with the smallest practical integration scope.

It includes:

  • A dedicated Weather tab in the notch UI.
  • A weather settings page (enable/disable, city, unit, refresh interval, content mode).
  • A WeatherManager to fetch and manage weather/geocoding data.
  • Minimal wiring into existing tab navigation and view routing.

It does not include localization key changes or unrelated refactors.

Changes

  • Added boringNotch/managers/WeatherManager.swift
    • Fetches weather data and city suggestions.
    • Handles refresh loop, retries, and state publishing.
  • Added boringNotch/components/Notch/WeatherTabView.swift
    • Displays current weather and forecast (based on settings).
  • Added boringNotch/components/Settings/Views/WeatherSettingsView.swift
    • Provides Weather settings UI.
  • Updated minimal integration points:
    • boringNotch/models/Constants.swift
    • boringNotch/enums/generic.swift
    • boringNotch/components/Tabs/TabSelectionView.swift
    • boringNotch/components/Notch/BoringHeader.swift
    • boringNotch/ContentView.swift
    • boringNotch/components/Settings/SettingsView.swift
    • boringNotch.xcodeproj/project.pbxproj

Cleanup Included

  • Removed unused weather payload fields/dead fields in WeatherManager to avoid no-op code.

Validation

  • Build check passed:
    • xcodebuild -project boringNotch.xcodeproj -scheme boringNotch -configuration Debug -destination 'platform=macOS' build

Notes

  • This PR is intentionally scoped to Weather only.
  • Localization updates (if needed) will be handled in a separate PR.

Copy link
Member

@Alexander5015 Alexander5015 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes seem very disorganized. In order for me to be able to review this properly please esure that:

  1. All changes for localization keys are in a separate PR. They are not related, and so they shouldn't be in the same PR.
  2. Code is correctly organized. Right now it seems like the code is isn't in the correct files. Ensure you organize all code into files in a clean way, where all files have proper separation of concerns.

@MaydayV MaydayV force-pushed the dev branch 2 times, most recently from 64b76d3 to 26ec366 Compare March 7, 2026 10:45
- 保留天气功能最小必要改动,移除与功能无关的链式顺序噪音改动。

- 删除 WeatherTabView 中未使用的 hourly UI 路径。

- 删除 WeatherManager 中未使用的小时预报/日出日落数据链路与冗余模型字段。

- 移除 ImageService.swift 中无用导入,并收敛 Tab 标签文本为最小实现。
- remove unused timeZone field from WeatherSnapshot\n- remove unused time fields from current weather decoding models\n- keep weather behavior unchanged while reducing dead code
@MaydayV MaydayV changed the title Add Weather tab (settings + notch experience) and fix localization key leakage for Crowdin-ready source strings add Weather tab with minimal, scoped integration Mar 7, 2026
@MaydayV
Copy link
Author

MaydayV commented Mar 9, 2026

@Alexander5015 Please check my changes to the features and code content again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants