@@ -100,6 +100,7 @@ public struct APNSLiveActivityNotification<ContentState: Encodable & Sendable>:
100100 /// - apnsID: A canonical UUID that identifies the notification.
101101 /// - contentState: Updated content-state of live activity
102102 /// - event: event type e.g. update
103+ /// - alert: Optional alert content for the notification.
103104 /// - timestamp: Timestamp when sending notification
104105 /// - dismissalDate: Timestamp when to dismiss live notification when sent with `end`, if in the past
105106 /// dismiss immediately
@@ -109,6 +110,7 @@ public struct APNSLiveActivityNotification<ContentState: Encodable & Sendable>:
109110 appID: String ,
110111 contentState: ContentState ,
111112 event: APNSLiveActivityNotificationEvent ,
113+ alert: APNSAlertNotificationContent ? = nil ,
112114 timestamp: Int ,
113115 dismissalDate: APNSLiveActivityDismissalDate = . none,
114116 apnsID: UUID ? = nil
@@ -119,6 +121,7 @@ public struct APNSLiveActivityNotification<ContentState: Encodable & Sendable>:
119121 topic: appID + " .push-type.liveactivity " ,
120122 contentState: contentState,
121123 event: event,
124+ alert: alert,
122125 timestamp: timestamp,
123126 dismissalDate: dismissalDate
124127 )
@@ -136,6 +139,7 @@ public struct APNSLiveActivityNotification<ContentState: Encodable & Sendable>:
136139 /// - apnsID: A canonical UUID that identifies the notification.
137140 /// - contentState: Updated content-state of live activity
138141 /// - event: event type e.g. update
142+ /// - alert: Optional alert content for the notification.
139143 /// - timestamp: Timestamp when sending notification
140144 /// - dismissalDate: Timestamp when to dismiss live notification when sent with `end`, if in the past
141145 /// dismiss immediately
@@ -146,14 +150,16 @@ public struct APNSLiveActivityNotification<ContentState: Encodable & Sendable>:
146150 apnsID: UUID ? = nil ,
147151 contentState: ContentState ,
148152 event: APNSLiveActivityNotificationEvent ,
153+ alert: APNSAlertNotificationContent ? = nil ,
149154 timestamp: Int ,
150155 dismissalDate: APNSLiveActivityDismissalDate = . none
151156 ) {
152157 self . aps = APNSLiveActivityNotificationAPSStorage (
153158 timestamp: timestamp,
154159 event: event. rawValue,
155160 contentState: contentState,
156- dismissalDate: dismissalDate. dismissal
161+ dismissalDate: dismissalDate. dismissal,
162+ alert: alert
157163 )
158164 self . apnsID = apnsID
159165 self . expiration = expiration
0 commit comments