Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BigTextStyle for Android #62

Closed
nikolayczyk opened this issue Sep 12, 2017 · 5 comments
Closed

BigTextStyle for Android #62

nikolayczyk opened this issue Sep 12, 2017 · 5 comments
Milestone

Comments

@nikolayczyk
Copy link
Contributor

Hey @EddyVerbruggen,
I want to show multiline message in Notifications.
There is already an entry on stackoverflow on this topic.
Link:
https://stackoverflow.com/questions/45666384/firebase-push-notification-how-to-show-multiline-message-in-notification
I have extended your plugin therefore. I added the BigTextStyle as a style for Android.
Could you give me the permission to push my adjustments into the master?
I have already tested my adjustments. I've already pushed the adjustments in my fork.
I would like to share my adjustments.

Here are my changes:
local-notifications-common.js

LocalNotifications.defaults = {
id: 0,
title: '',
body: '',
badge: 0,
interval: 0,
ongoing: false,
groupSummary:null,
bigTextStyle: false
};

local-notifications.d.ts

export interface ScheduleOptions {
...
bigTextStyle?: boolean;

local-notifications.android.js

LocalNotifications.schedule = function (arg) {
...
if(options.bigTextStyle){
var bigTextStyle = new android.support.v4.app.NotificationCompat.BigTextStyle();
bigTextStyle.setBigContentTitle(options.title);
bigTextStyle.bigText(options.body);
builder.setStyle(bigTextStyle);
}

Best regards
Tim

@EddyVerbruggen
Copy link
Owner

Hi Tim, did you open a PR to this repo? I think it would make a great addition!

@nikolayczyk
Copy link
Contributor Author

I created a new branch (BigTextStyle).
But when I try to push I get a error message.

remote: Permission to EddyVerbruggen/nativescript-local-notifications.git denied to nikolayczyk.
fatal: unable to access 'https://github.com/EddyVerbruggen/nativescript-local-notifications.git/': The requested URL returned error: 403

@nikolayczyk
Copy link
Contributor Author

I have opened a PR. Sorry but I have not used Github often.

@EddyVerbruggen
Copy link
Owner

Thank you! First time for everything, right? :)

@EddyVerbruggen
Copy link
Owner

Great work, part of 2.0.0! 👌🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants