Skip to content

Commit

Permalink
fix(android): clipped notification text and expand arrow
Browse files Browse the repository at this point in the history
  • Loading branch information
erisu committed Aug 31, 2024
1 parent 74f3c7e commit 6b4b0eb
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions src/android/com/adobe/phonegap/push/FCMService.kt
Original file line number Diff line number Diff line change
Expand Up @@ -906,17 +906,16 @@ class FCMService : FirebaseMessagingService() {
setNotification(notId, "")

message?.let { messageStr ->
val bigText = NotificationCompat.BigTextStyle().run {
bigText(fromHtml(messageStr))
setBigContentTitle(fromHtml(it.getString(PushConstants.TITLE)))
val bigText = NotificationCompat.BigTextStyle()
.bigText(fromHtml(messageStr))
.setBigContentTitle(fromHtml(it.getString(PushConstants.TITLE)))

it.getString(PushConstants.SUMMARY_TEXT)?.let { summaryText ->
setSummaryText(fromHtml(summaryText))
}
it.getString(PushConstants.SUMMARY_TEXT)?.let { summaryText ->
bigText.setSummaryText(fromHtml(summaryText))
}

mBuilder.setContentText(fromHtml(messageStr))
mBuilder.setStyle(NotificationCompat.BigTextStyle().bigText(messageStr))
mBuilder.setStyle(bigText)
}
}
}
Expand Down

0 comments on commit 6b4b0eb

Please sign in to comment.