-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Replace OC.Notification with toastify js #15124
Conversation
So the design team has to decide of course. But I'm not 100% convinced having it on the bottom is the best. All our notifications etc are on the top so that is where people look. Maybe adding it just blow the header makes more sense? |
Of course visually this looks a lot better than the 1990 style we had before. |
I think it is hard to distinguish from the other content. Maybe use a contrast color (white on dark background on normal, and dark on white background on dark theme)? |
See the last open checkbox ;) It should be moved to the top right. |
A full colored background is a bit to much I think, but I've increased the box shadow visibility a bit (see the updated screenshot in the first post)
Done 😉 |
8ca1804
to
348e589
Compare
Top right is indeed much better, that’s where all the "meta / organizational" stuff is. :) And it looks really really nice! Props @juliushaertl! The only thing I can find is that the x icon is not our |
No reason, I can adjust that as well. |
348e589
to
ca97368
Compare
@jancborchardt Thanks for the hint, pushed with the proper close icon |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having the mouse over the notification should prevent it from disappearing I think. If you're reading something long and it disappear, you're confused :)
I'll see, but we probably need to fix that upstream. |
I agree, I struggle from a bit of dyslexia and often find myself highlighting text to help me read it and sometimes reading takes a bit longer than "average". Having a notification disappear while reading it can be quite frustrating. Especially if there's not an easy way to get it back.
I have opened up apvarun/toastify-js#21 upstream so we'll see if this feature can get added. If not, perhaps I can recommend not setting the timeout at all. |
@BrookeDot Thanks a lot for that! 🚀 |
Opened PR: apvarun/toastify-js#22 |
I like it. Looks more modern |
I would also be happy with just ignoring the hide method and have a default timeout of 30s for notifications that were called without a timeout though the legacy API. |
Just to clarify: This issue does not happen when using this new notification API? Cause a defaut timeout for notifications has a big issue in that people don’t necessarily check the screen or tab all the time, and they might miss a notification. Also, do these notifications have a close button so you can close them before the 30s? |
66bbf67
to
f41e539
Compare
The new API has a default timeout as I would consider those notifications to be more temporary than permanent.
I have now also rebuild the old OC.Notifiation.hide() method, so the behavior on the old API should be complete. The only thing that has changed is the fallback if no notification to hide was provided. In that case we do nothing now, as there was a warning logged for quite some time and just removing the first notification doesn't seem to be a good fallback to me. Let's see if the tests are happy. |
🎉 Tests are happy again. @skjnldsv @ChristophWurst Mind to have another look? |
Looks all good to me :D |
94fdc6c
to
6d519df
Compare
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Signed-off-by: Julius Härtl <jus@bitgrid.net>
6d519df
to
d95ef2c
Compare
Done 🚢 |
@juliushaertl There is a mismatch in the options received by OC.Notification and OCP.Toast: OC.Notification uses isHTML, while OCP.Toast uses showHtml. Either |
If you scroll down the page, the message is not visible under the header |
Please open a new ticket. |
Should be fixed already #17110 |
This is a PoC pull request for #13423 to make error messages that are sent though OC.Notification more obvious and visually appealing.
Feedback is welcome @nextcloud/designers
Note that the current OC.Notification.show OC.Notification.showTemporary continue to work, but the toastify lib adds additional types (error,warning,success,info) to give a visual hint about the type of message.
ToDo as from #13423: