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

PNotify.defaultStack not work #327

Open
mahdisky opened this issue Feb 13, 2018 · 7 comments
Open

PNotify.defaultStack not work #327

mahdisky opened this issue Feb 13, 2018 · 7 comments
Assignees
Labels

Comments

@mahdisky
Copy link

how to set default PNotify.defaultStack?
i did this but didnt get any result

@hperrin
Copy link
Member

hperrin commented Feb 14, 2018

What version are you using?

@hperrin hperrin self-assigned this Feb 14, 2018
@mahdisky
Copy link
Author

v4

@hperrin
Copy link
Member

hperrin commented Feb 20, 2018

Can you show me your code? I'm not sure what you're trying to do.

@mahdisky
Copy link
Author

PNotify.defaultStack = { "dir1": "down", "dir2": "left", "firstpos1": 25, "firstpos2": 25, "spacing1": 36, "spacing2": 36, "push": "top", // "context": document.body };

@hperrin
Copy link
Member

hperrin commented Feb 22, 2018

As long as it's not on one line like that (so the comment doesn't comment out the closing }, that should work. Are you running it after loading PNotify?

@mahdisky
Copy link
Author

yes,can you send sample of this ?that's the position in top left and a little bit down

@hperrin
Copy link
Member

hperrin commented Mar 10, 2018

Try it like this:

document.addEventListener('DOMContentLoaded', function() {
  PNotify.defaultStack = { "dir1": "down", "dir2": "left", "firstpos1": 25, "firstpos2": 25, "spacing1": 36, "spacing2": 36, "push": "top", "context": document.body };
});

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

No branches or pull requests

2 participants