A way to disable the deploy toast notification

Hi all,
I wonder if there is a way that I can disable the toast notification that shows up when deploying a flow, or reduce the delay. I build lots of flows and I find that notification eye straining and intrusive. I am of the habit to deploy the changes constantly, test, change, etc. I would like to disable the notification completely or reduce the delay. If also the actual height of the notifications gets slimmer like the new notifications for inject node, that would be great. It currently stays in screen for way too long and gets on the way. I even want to disable the Inject notification if possible too!
I am not sure if anyone else is sharing the same thoughts.
If however this is more unique preference and it is just me, can someone please point me on where on the code that part is and I will modify it on my installation only. I am sure the delay is hardcoded somewhere or so.
Thank you

The slimmer notification was in direct response to similar complaints about the deploy notification.

Any one-line notification will fit without obscuring the tab bar.

If you have unused config nodes, then the deploy notification will have the extra message in it, so will be a bit bigger.

Whilst it won't directly address all your complaints, you can also click on the notification to dismiss it instantly.

Thanks for prompt response @knolleary .
I am thinking we could possibly provide the user with a way to disable those notifications. I think the fact that the Deploy button gets disabled after every save denoting there is no change in flow is a well understood method of establishing that the flow was "successfully deployed". So I feel that the message "Successfully deployed" is unnecessary in this situation.
In regards to the warning message of unused config nodes, while I totally understand that warning message is very useful to a new user and would possibly help avoid some issues, I think it is still applicable to disable it by an option or so. With all the great new features we get with every release, I am hoping I could disable this. When building larger applications, those unused config is common, and I go clean them up at later stage.
Thanks for the tip of clicking the notification to dismiss, I didn't know that!
I hope this suggestion can get into a possible feature for later releases.
Cheers

Perhaps a configurable delay time for the notification to disappear in settings ?

I would find that very convenient. One could reduce to a short time if that fitted ones work pattern.

If you want to "hack it" yourself, being open source, you can apply some CSS to override its size. Example...

lNBWkQfRTX

#red-ui-notifications {
    z-index: 100;
    width: 500px;
    margin-left: -250px;
    right: 120px;
    position: absolute;
    top: 1px;
    transform: scale(0.6, 0.6);
    transform-origin: top;
}

You could even move it to the bottom...

vrBnht1QVy

#red-ui-notifications {
    z-index: 100;
    width: 500px;
    margin-left: -250px;
    left: 50%;
    position: absolute;
    bottom: 1px;
}

To use this, you can either create a theme, hack the CSS of your install or use a browser plugin that overrides CSS.


Here be dragons
Remember - these examples are just hacks that you will need to maintain over your updates/upgrades with no guarantees something under the hood wont change in next version :slight_smile:

2 Likes

you could always add these custom css in an external file loaded from your settings.js file to keep them persistent ? (untested)

For example

// Customising the editor
  editorTheme: {
    page: {
      css: "/Users/User/.node-red/myCustom.css",
    },
2 Likes

would rather either enable or disable notifications. I guess having config for delay of the toast is a bit uncommon practice, and I feel that having no notification at all will be best to focus on the task at hand. I dont find the notification add any use for me, giving there is already enough visual indication that the Deploy button has worked denoted by the loading icon and the Deploy button being disabled after deploy. A simple option to disable notifications after deploy would be very useful.

great I will give this a go! I would assume the actual delay is a transform / transition rule maybe? hopefully can be a css rule I will need to play around with that..

@Steve-Mcl @UnborN
thanks for ideas
achieved the result for what I want by simply adding the following rule to a custom.css

div.red-ui-notification.red-ui-notification-success {
  display: none !important;
}

then loaded in settings using editorTheme key as @UnborN suggested.

This will not show the success notification message, but still allow me to get any other notifications such as bad configuration dialogue, etc. This achieved exactly what I want. Note that the Inject node button generates a "Successfully injected" message which will also not going to be shown as the rule applies to that too. This is great for me :slight_smile: I cannot assert that it will not cause any issues missing important information that maybe generated from other stuff around like node-red debugger, but yet to see!

there is possible other solutions updating the .js file, reducing slideDown and slideUp delays for example but its little hacky ofcourse. This is the cleanest method I'd say.
I didnt realise editorTheme has quite a bit of options there.. for other time to try out!