2026-06-30 13:53:13 -05:00
|
|
|
import 'package:immich_mobile/domain/models/feature_message.model.dart';
|
|
|
|
|
import 'package:immich_mobile/domain/models/settings_key.dart';
|
|
|
|
|
import 'package:immich_mobile/infrastructure/repositories/settings.repository.dart';
|
|
|
|
|
|
|
|
|
|
class FeatureMessageService {
|
|
|
|
|
final SettingsRepository _settingsRepository;
|
|
|
|
|
|
|
|
|
|
const FeatureMessageService(this._settingsRepository);
|
|
|
|
|
|
|
|
|
|
bool shouldShow() {
|
|
|
|
|
final seen = _settingsRepository.appConfig.featureMessage.seenRelease;
|
2026-08-11 14:41:13 +05:30
|
|
|
return visibleFeatureMessageHighlights.isNotEmpty && featureMessageRelease > seen;
|
2026-06-30 13:53:13 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Future<void> markSeen() => _settingsRepository.write(SettingsKey.featureMessageSeenRelease, featureMessageRelease);
|
|
|
|
|
}
|