notifications
notifications copied to clipboard
Make URLs in notification message clickable
You demanded to create new issue for it, thus doing so (it is exactly the same problem for me). Links are unclickable even in current version - no change.
Totally agree here, woud be cool to be able to click links to have them open in a new tab. :)
For example if I get a link via Nextcloud Talk, on the desktop I can actually click the link in the notification. In the web interface it’s not clickable:

Originally posted by @jancborchardt in https://github.com/nextcloud/notifications/issues/343#issuecomment-519916053
Lets track this in https://github.com/nextcloud/notifications/issues/1038
That's totally not related.
In the above case the problem is that links in Talk chat messages are currently always only rendered in the UI. In #1038 the problem is no or an invalid link is given as the link property.
Oh yes, sorry. Didn't read accurate enough
In #1038 the problem is no or an invalid link is given as the link property.
@nickvergessen Since @p-bo mentions that they can click the link in the desktop app, I'm rather sure that it's the same issue. If you look at https://github.com/nextcloud/notifications/issues/1038#issuecomment-873011403, you can see that the Nextcloud update notification does indeed have a valid link property.
It's not related, see the other issue for the fixing PR.
@p-bo If you're familiar with your browser's developer tools, would you be able to post the response (with sensitive data replaced by ***) of the XHR request GET /ocs/v2.php/apps/notifications/api/v2/notifications when there is an active talk notification?
{
"ocs": {
"meta": {
"status": "ok",
"statuscode": 200,
"message": "OK"
},
"data": [
{
"notification_id": 1017,
"app": "spreed",
"user": "admin",
"datetime": "2021-07-02T14:11:51+00:00",
"object_type": "chat",
"object_id": "rvjekc38",
"subject": "Bennet Bernetto mentioned you in a private conversation",
"message": "Hi @Adrian Ada https://nextcloud23.local/index.php/apps/spreed/",
"link": "https://nextcloud23.local/index.php/call/rvjekc38",
"subjectRich": "{user} mentioned you in a private conversation",
"subjectRichParameters": {
"user": {
"type": "user",
"id": "9110bb9c-0e61-48a8-9abf-0217e806d55a",
"name": "Bennet Bernetto"
},
"call": {
"type": "call",
"id": 24,
"name": "Bennet Bernetto",
"call-type": "one2one"
}
},
"messageRich": "Hi {mention-user1} see this link https://nextcloud23.local/index.php/apps/spreed/",
"messageRichParameters": {
"mention-user1": {
"type": "user",
"id": "admin",
"name": "Adrian Ada"
}
},
"icon": "https://nextcloud23.local/appsbabies/spreed/img/app-dark.svg",
"actions": [
{
"label": "View chat",
"link": "https://nextcloud23.local/index.php/call/rvjekc38",
"type": "WEB",
"primary": false
}
]
}
]
}
}
@nickvergessen So since that notification does have a link, shouldn't it be fixed by the backport?
edit: And if the link is invalid, wouldn't it be a https://github.com/nextcloud/spreed issue?
For this issue here, it's completely different request.
The notification has a link and that works, but the message also contains a link https://nextcloud23.local/index.php/apps/spreed/ which can not be used as a link of the notification, hence this enhancement request. I could post a message with 5 links, so which one should replace the notification link? => Doesn't work => individual links need to be clickable => as mentioned before this does not work atm because talk does not parse links on the backend
Oops, I'm sorry, I totally missed that link. 🤦
@caugner I would very like to help with more clarification of this, but unfortunately I'm not familiar with (any) browser's developer tools (I'm mere mortal/translator ;-) ) thus unfortunately cannot help with technical details.
But it would be easy to reproduce. Point is, that if user opens Nextcloud web interface, she/he get notifications with URLs (pointing to regular web URLs, not .local ones), which are suggesting to find more details on Github, etc. and they cannot be clicked, even cannot copied, so one must to read them from screen and write them on keyboard manually (which no one will do), so it is quite UX trouble on very visible place. Example - in last notification on depicted list (but please, don't fix on this one, which is originated from nextcloud vm - it is universally manifested behavior):
Thanks for you help :-)
Not sure from which app this comes from
https://github.com/nextcloud/vm/blob/66038488edbb440b2dda02e1d7e9a734417abdcc/lib.sh#L1690