conduit/lib/features/release_notes/models/release_note.dart
cogwheel 677a20e2ba
Redesign the Conduit 4.0 release announcement (#602)
* feat: bundled JSON release notes for 4.0, polished changelog sheet, remove IAP

- Move release-note content from ARB to assets/release_notes/<locale>.json
  with locale-fallback repository and schema-checked validator
- Polish the release notes sheet (staggered reveal, version badge,
  feature glyph bullets, action cards) and add the 4.0 note in 13 locales
- Prune pre-4.0 notes
- Remove in_app_purchase and the tip jar entirely; keep the Buy Me a
  Coffee donation link on all platforms

* Refresh release notes sheet and localized copy

* Add release notes banner and native review support

* Redesign release announcement sheet

* Target release announcement to 4.0.1

* Address release announcement review feedback

* Tighten release note locale handling
2026-07-31 21:54:47 +05:30

31 lines
931 B
Dart

import 'package:flutter/widgets.dart';
import 'release_version.dart';
class ReleaseNote {
ReleaseNote({
required this.version,
required this.title,
required this.intro,
required this.bullets,
this.bulletIcons = const <IconData?>[],
this.bulletIconAssets = const <String?>[],
}) : parsedVersion = ReleaseVersion.parse(version);
final String version;
final String title;
final String intro;
final List<String> bullets;
/// Optional leading glyph per bullet, aligned by index with [bullets].
/// Bullets without a matching icon fall back to a plain dot.
final List<IconData?> bulletIcons;
final List<String?> bulletIconAssets;
final ReleaseVersion parsedVersion;
IconData? iconForBullet(int index) =>
index < bulletIcons.length ? bulletIcons[index] : null;
String? iconAssetForBullet(int index) =>
index < bulletIconAssets.length ? bulletIconAssets[index] : null;
}