Karn / notify

Simplified notification construction and delivery for Android.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

BigText Notification with title and big text (without expanded text)

hukjordanjanaq opened this issue · comments

How can I make notification with just title and big text?

1*9DSdM91LB7K-w1n-sI5mtQ
]()

Hey @jordanjanaq! Yes, you should be able to do the following when using the latest develop release:

Notify
    .with(context)
    .asBigText { // this: Payload.Content.BigText
        // The title of the notification.
        title = "Chocolate brownie sundae"
        // The second line of the (collapsed) notification.
        text = "Try our newest dessert option!"
        // The second line of the expanded notification.
        // expandedText = "Try our newest dessert option!" // <- Skip setting this
        // Large string that is displayed under the line above.
        bigText = "Our own Fabulous Godiva Chocolate Brownie, Vanilla " +
                  "Ice Cream, Hot Fudge, Whipped Cream and Toasted " + 
                  "Almonds.\n\n" +
                  "Come try this delicious new dessert and get two for " +
                  "the price of one!"
    }
    .show()

going to mark this as closed but feel free to open if you'd like some additional clarification.

Breadcrumb: Patch bigText formatting 9bbe0b2