Skip to content

Releases: thudugala/Plugin.LocalNotification

v14.1.0

29 Mar 04:30

Choose a tag to compare

✨ New Features

  • Inline Reply Actions on Android, iOS, and macOS (text input support).
  • Advanced Android Notification Styles: InboxStyle, MessagingStyle, MediaStyle.
  • Foreground service support with start/stop APIs.
  • Monthly repeat scheduling + improved alarm handling via AndroidScheduleMode.
  • Full DateTimeOffset migration for accurate cross‑timezone scheduling.

📱 Android Improvements

  • Added Person, Message, and extensible style models.
  • Added LED timing + audio attribute options (API < 26).
  • Added notification Tag support.
  • New IAndroidNotificationService for permissions, channels, and cancellation.

🍎 iOS/macOS Improvements

  • Text‑input notification actions.
  • New Apple options: CriticalSoundVolume, HideThumbnail, ThumbnailClippingRect.
  • Corrected AppleCategoryOptions flag names.

🧹 Refactoring & Cleanup

  • Removed old AndroidMediaStyle (replaced by new style system).
  • Refactored scheduling into ScheduleAlarm.
  • General API cleanup and formatting improvements.

📦 Package Updates

  • Plugin.LocalNotification14.1.0
  • Plugin.LocalNotification.Core1.1.0
  • Plugin.LocalNotification.Geofence1.1.0

Full Changelog: v14.0.0...v14.1.0

v14.0.0

23 Mar 09:43

Choose a tag to compare

Overview

Plugin.LocalNotification v14.0.0 is a major release featuring significant architectural improvements, platform expansion, and enhanced geofence support. This version modernises the codebase while maintaining backward compatibility for core functionality.

🎯 Major Changes

Architecture Restructuring

  • New Core Package: Introduced Plugin.LocalNotification.Core containing shared models, interfaces, and platform utilities

    • Separates core notification models from platform-specific implementations
    • Improves code reusability and maintainability
  • New Geofence Package: Plugin.LocalNotification.Geofence as an optional add-on

    • Enables geofence notifications on Android, iOS, and macOS
    • Reduces core dependencies by moving geofence logic to a separate package
    • Register with .UseLocalNotificationGeofence() in MauiAppBuilder

Platform Support Expansion

  • Added: macCatalyst platform support
  • Updated to .NET 10.0 (from .NET 9.0)

Naming Convention Updates

  • iOS → Apple: Renamed all iOS-specific types for clarity (e.g., iOSOptionsAppleOptions, iOSActionTypeAppleActionType)
  • All iOS namespace paths updated from iOSOption to AppleOption
  • Applied consistently across models and platform code

Logging Improvements

  • New: LocalNotificationLogger static class replaces scattered logging logic
    • Centralised logging with configurable LogLevel
    • Supports custom ILogger instances
    • Automatic caller name tracking via [CallerMemberName]

Package Restructuring

  • Solution format modernised from .sln to .slnx format
  • Three separate NuGet packages available:
    • Plugin.LocalNotification.Core - Core models and interfaces
    • Plugin.LocalNotification - Main notification service
    • Plugin.LocalNotification.Geofence - Geofence support (optional)

🔧 Breaking Changes

Namespace Changes

// Old
using Plugin.LocalNotification.iOSOption;
using Plugin.LocalNotification.AndroidOption;

// New
using Plugin.LocalNotification.Core.Models.AppleOption;
using Plugin.LocalNotification.Core.Models.AndroidOption;

Type Renames

  • iOSOptionsAppleOptions
  • iOSActionAppleAction
  • iOSActionTypeAppleActionType
  • iOSActionIconAppleActionIcon
  • iOSAuthorizationOptionsAppleAuthorizationOptions
  • iOSLocationAuthorizationAppleLocationAuthorization
  • NotificationChannelRequestAndroidNotificationChannelRequest
  • NotificationChannelGroupRequestAndroidNotificationChannelGroupRequest
  • iOSNotificationPermissionAppleNotificationPermission
  • iOSGeofenceOptionsAppleGeofenceOptions

API Changes

  • LocalNotificationCenter.LogLevelLocalNotificationLogger.LogLevel
  • LocalNotificationCenter.Log()LocalNotificationLogger.Log()
  • Request objects (iOS): Use .Apple property instead of .iOS
  • Android: Use AndroidNotificationChannelRequest instead of NotificationChannelRequest

Removed

  • Windows platform code removed (replaced with WinUI implementation)
  • MacCatalyst-specific files removed (now under iOS umbrella)
  • Generic notification service NotificationServiceImpl moved to core

✨ New Features

Geofence Support Enhancement

  • Dedicated geofence handler registry for modular architecture
  • Support for location-based notifications on iOS and Android
  • Android: Uses Google Play Services Location for geofencing
  • Geofence data serialisation with NotificationRequestGeofence

Windows Support

  • Full UWP/WinUI notification support via AppNotificationManager
  • File-based repository for pending/delivered notifications
  • Timer-based scheduling for delayed notifications
  • Image and action button support

macOS (macCatalyst) Support

  • Native UserNotifications framework integration
  • Calendar-based notification triggers
  • Geofence location-based triggers
  • Privacy info manifest support

Multi-Solution Support

  • Traditional .sln files for Visual Studio compatibility
  • Modern .slnx format for enhanced IDE support
  • Updated CI/CD workflows to support the new structure

📦 Dependencies

  • Updated to .NET 10 SDK
  • Microsoft.SourceLink.GitHub: 8.0.0 → 10.0.103
  • Microsoft.Extensions.Logging: Updated references
  • New: Xamarin.GooglePlayServices.Location (Android, when a geofence is used)
  • New: Microsoft.WindowsAppSDK 1.8.260209005 (Windows)

🔄 Sample Application Updates

  • Updated target frameworks to .NET 10
  • Migrated to new namespace structure
  • Added geofence usage examples (commented out)
  • Replaced legacy XAML layouts (StackLayout → Grid)
  • Added location permissions in Android manifest
  • Added XAML compilation optimisation settings

📋 CI/CD Updates

  • Xcode version updated to 26.2
  • Build pipeline now compiles three packages:
    • Plugin.LocalNotification.Core
    • Plugin.LocalNotification
    • Plugin.LocalNotification.Geofence
  • Separate artefact uploads for each package

🎓 Migration Guide

For Existing Users

  1. Update NuGet packages to v14.0.0
  2. Replace namespace imports with new structure
  3. Update property names: .iOS.Apple
  4. Update type names (see Breaking Changes section)
  5. For geofence features, add Plugin.LocalNotification.Geofence package and call .UseLocalNotificationGeofence()

Example

// Old way (v13)
using Plugin.LocalNotification.iOSOption;
var request = new NotificationRequest { iOS = new iOSOptions() };

// New way (v14)  
using Plugin.LocalNotification.Core.Models.AppleOption;
var request = new NotificationRequest { Apple = new AppleOptions() };

// Enable geofencing
MauiAppBuilder
    .UseLocalNotification()
    .UseLocalNotificationGeofence();

📊 Platform Support Matrix

Feature Android iOS macOS Windows
Local Notifications
Geofence
Actions/Buttons
Custom Images
Scheduling
Repeating

🐛 Quality Improvements

  • Enhanced test coverage with new unit tests
  • Comprehensive coverage tests for core models
  • Better separation of concerns between packages
  • Improved XML documentation across all types

🔐 Modernizations

  • C# 12+ features utilised where applicable
  • Target framework modernisation to .NET 10
  • Updated GitHub Actions workflows
  • Added GitHub Sponsors funding configuration

Full Changelog: v13.0.0...v14.0.0

v13.0.0

30 Nov 10:16

Choose a tag to compare

What's Changed

  • Bug Fix (#538): Resolved an issue where Geofence.Center.Latitude could be set to "NaN", causing deserialization errors when converting to NotificationRequest.
  • Platform Update:
    • Dropped support for .NET 8, as it has reached end of support. See the official .NET MAUI support policy for details.
    • Added support for .NET 10, ensuring compatibility with the latest runtime and tooling.

Full Changelog: V12.0.2...v13.0.0

V12.0.2

27 Jul 15:08

Choose a tag to compare

Full Changelog: v12.0.1...V12.0.2

Add missing XML comments.
Set IsAotCompatible to true, and make sure to use NotificationJsonContext inside NotificationSerializer.

When using net8.0-android
Add the package references below for Android

<ItemGroup Condition="$(TargetFramework.Contains('-android'))">
  <PackageReference Include="Xamarin.AndroidX.Fragment.Ktx" Version="1.8.6.2" />
</ItemGroup>

V12.0.1

10 May 00:49

Choose a tag to compare

Publishing PR #531 by @LeoJHarris

Fixing

Fatal Exception: android.runtime.JavaProxyThrowable
[System.NullReferenceException]: Object reference not set to an instance of an object
Plugin.LocalNotification.NotificationImage.get_HasValue

v12.0.0

30 Apr 23:01

Choose a tag to compare

Add support to .Net 9.0

Fixed Bugs

#530 reported by @TofuBug
#477 reported by @leonard

v11.1.4

08 Jul 07:54

Choose a tag to compare

#507 Updated GooglePlayServices nuget

Thank you @Kebechet

Make sure to Add these Package Reference for android

<ItemGroup Condition="$(TargetFramework.Contains('-android'))">
  <PackageReference Include="Xamarin.AndroidX.Fragment.Ktx" Version="1.8.1" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.Common" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.LiveData.Core" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.LiveData.Core.Ktx" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.Process" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.Runtime" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.Runtime.Ktx" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.ViewModel" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.ViewModel.Ktx" Version="2.8.3" />
  <PackageReference Include="Xamarin.AndroidX.Lifecycle.ViewModelSavedState" Version="2.8.3" />
</ItemGroup>

v11.1.3

05 Jun 12:03

Choose a tag to compare

Added ios notification action icon support

v11.1.2

14 Apr 02:47

Choose a tag to compare

  1. #490 Android: If the sound file is not stored as an Android resource correctly in the raw folder, an exception is triggered.
  2. Added support request Schedule Exact Alarm
var permissionRequest = new NotificationPermission
{
    Android =
        {
            RequestPermissionToScheduleExactAlarm = true
        }
};

if (await _notificationService.AreNotificationsEnabled(permissionRequest) == false)
{
    await _notificationService.RequestNotificationPermission(permissionRequest);
}

v11.1.1

26 Feb 06:50

Choose a tag to compare

Made LocalNotificationCenter Platform methods public so they can be used in native apps.