smart_firebase_fcm 1.0.10
smart_firebase_fcm: ^1.0.10 copied to clipboard
A plug-and-play modular Firebase FCM package with local notifications, redirection, and manual feature toggles (analytics, crashlytics, etc.).
Changelog #
All notable changes to this project will be documented in this file.
1.0.9 - 2025-09-29 #
π¨ Custom Notification Icon Support #
- β Custom Android Notification Icons: Added support for custom notification icons using drawable/mipmap resources
- β Dynamic Icon Updates: Change notification icons at runtime without reinitializing
- β
Multiple Icon Sources: Support for both
@drawable/
and@mipmap/
resources - β
Backward Compatibility: Existing code continues to work with default
@mipmap/ic_launcher
- β
Enhanced API: Added
androidNotificationIcon
parameter toFCMInitializer.initialize()
- β
Utility Methods: Added
setAndroidNotificationIcon()
andgetAndroidNotificationIcon()
methods - β
Per-Notification Icons: Support for custom icons in
showCustomNotification()
- β Updated Documentation: Comprehensive guide for Android icon requirements and usage
- β Example App Enhancement: Interactive notification icon customization demo
π§ API Changes #
New Parameters:
androidNotificationIcon
inFCMInitializer.initialize()
androidIcon
inLocalNotificationService.showCustomNotification()
New Methods:
FCMInitializer.setAndroidNotificationIcon(String iconPath)
FCMInitializer.getAndroidNotificationIcon()
LocalNotificationService.setAndroidNotificationIcon(String iconPath)
LocalNotificationService.getAndroidNotificationIcon()
π± Usage Examples: #
// Initialize with custom icon
await FCMInitializer.initialize(
onTap: handleNotificationTap,
androidNotificationIcon: '@drawable/ic_notification',
);
// Change icon dynamically
FCMInitializer.setAndroidNotificationIcon('@mipmap/ic_custom');
// Custom notification with specific icon
await LocalNotificationService.showCustomNotification(
id: 1,
title: 'Test',
body: 'Test notification',
androidIcon: '@drawable/ic_message',
);
1.0.3 - 2025-07-01 #
π Initial Release #
- β Firebase FCM integration
- β Foreground, background, and terminated state redirection
- β Local notification support using flutter_local_notifications
- β Android channel setup
- β Toggle flags for Firebase Analytics and Crashlytics
- β Single-line initialization with optional message handler