notificationsService documentation specifies an "actions" option but value isn't used
See original GitHub issuehttps://our.umbraco.com/apidocs/v8/ui/#/api/umbraco.services.notificationsService#methods_add
The documentation mentions a actions
option you can use to add one or more buttons to a notification. But neither the service, directive or view have any references to the actions
option. At least when checking the latest code for both V7 and V8. So not sure if it was ever been supported 😮
So the million dollar questions now: should the option be removed from the documentation, or should support for these actions buttons be implemented?
When reading up on the documentation for the notificationsService
for a package, my idea was that an error notification could feature a “read more” action/button leading to the package documentation or an overlay within Umbraco so that users can read more about what the error actually means.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:6 (4 by maintainers)
Got it! And your samples are great. Would be cool to be able to link to a specific error message in the log as well, related to this error… but I guess that would be a difficult one! 🤔
I still like the the idea of adding these actions - for instance the example with linking to the documentation on an overlay as I wrote about. So I’ve played a bit around with this.
So if I had something that resulted in an error, I could show a notification like this:
The first action illustrates how to open a new editor via the
editorService
, as well as removing the notification when the action is triggered.The second action opens
url
in a new tab, and also removes the notification once the action is clicked.Using either
<button />
or<umb-botton />
would take up more vertical space compared to a single line of text, which then looks a bit off. So for the screenshot below, I’ve gone with a regular linkWould this be worth pursuing as a PR? And if so, anything else an action ought to support?