Files
Alby96andClaude Opus 5 f434a68155 Replace the default Flutter icon with a stylised cloud
The app shipped the Flutter template's blue F, which said nothing about what it
does and did not match the interface. The launcher icon is now a white cloud on
the same seed blue the app themes itself with, so the two read as one product.

The icon is drawn rather than hand-edited: tool/generate_icon.py renders it from
signed distance fields — a union of three circles and a rounded box — using only
the standard library, so regenerating it needs no image toolchain. The shape's
framing is derived from its own bounding box, which is what keeps it centred;
maintaining the bounds separately from the shape had it drifting off-centre.

Adds the adaptive icon and the Android 13 monochrome layer, which were missing
entirely. The generator frames the cloud against the 72dp the launcher mask
always keeps and adaptive_icon_foreground_inset is 0, so the layer is not shrunk
twice and the icon reads at the same size as its neighbours on a home screen.

Verified on the emulator: the cloud appears in the app drawer and holds its shape
down to 48px. docs/architecture.md records how to regenerate it, including the
flutter_launcher_icons 0.14.4 bug that writes a string into a boolean Xcode
setting and needs reverting by hand afterwards.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-10 22:44:33 +02:00

83 lines
2.6 KiB
YAML

name: nuvolari
description: "Precipitation radar for Piedmont, Italy."
publish_to: 'none'
version: 0.1.0+1
environment:
sdk: ^3.13.3
dependencies:
dio: ^5.11.1
flutter:
sdk: flutter
flutter_localizations:
sdk: flutter
# State management. Riverpod is used without code generation on purpose —
# see docs/stack-decisions.md.
flutter_riverpod: ^3.4.3
# Date and number formatting for the Italian locale.
geolocator: ^14.0.3
intl: ^0.20.3
# Native GPU-composited map. Radar animation redraws a full-viewport image
# several times a second, which a Dart-side tile renderer cannot keep up with.
maplibre_gl: ^0.27.1
# Opens attribution and official-bulletin links in the browser.
shared_preferences: ^2.5.5
url_launcher: ^6.3.2
dev_dependencies:
flutter_test:
sdk: flutter
flutter_lints: ^6.0.0
# Fans the two generated sources out to every Android density, the adaptive
# icon and the iOS set. Build-time only: it writes files into android/ and
# ios/, which are committed, so nothing here ships in the app.
flutter_launcher_icons: ^0.14.4
flutter:
uses-material-design: true
# Generates AppLocalizations from lib/l10n/*.arb, configured in l10n.yaml.
generate: true
assets:
- assets/regions/
# Demo radar frames, generated by tool/generate_mock_frames.py. They make
# the app runnable offline with no credentials.
- assets/mock/
- assets/mock/frames/
# Launcher icon, generated from the sources that tool/generate_icon.py draws.
# Re-run after changing them:
#
# python ../tool/generate_icon.py
# dart run flutter_launcher_icons
flutter_launcher_icons:
android: true
ios: true
image_path: assets/icon/icon.png
# Adaptive icon: the launcher masks the foreground to its own shape, so the
# cloud is drawn inside the safe zone and the app blue fills whatever the mask
# leaves. Kept identical to ColorScheme.fromSeed in lib/main.dart.
adaptive_icon_background: "#1F6FB2"
adaptive_icon_foreground: assets/icon/icon_foreground.png
# The generator already frames the cloud inside the 72dp safe zone. Left at
# its default of 16, this would shrink the layer again and the icon would read
# noticeably smaller than every other one on the home screen.
adaptive_icon_foreground_inset: 0
# Android 13 themed icons tint the alpha of this layer with the user's
# wallpaper palette. The foreground is a flat white silhouette, so its alpha
# is already exactly the cloud.
adaptive_icon_monochrome: assets/icon/icon_foreground.png
# iOS rejects an alpha channel in app icons. The source is opaque anyway;
# this drops the channel itself.
remove_alpha_ios: true