Skip to content

Session Status ​

The ui-session-status widget shows a panel with one text: Session On Text on a green background when the session is on, Session Off Text on a red background when it is off, and an empty white panel when there is no state. The text is white and bold, and larger on wider screens.

Session onSession off

Palette: category Monitor, label session status. 1 input, 1 output.

Configuration ​

PropertyDescriptionDefault
NameNode name shown in the editor.""
GroupDashboard group where the panel is displayed.(required)
SizeWidget width and height; 0 means automatic.0 x 0
Session On TextText shown when the session is on.SESSION ON
Session Off TextText shown when the session is off.SESSION OFF

Input ​

msg.payload must be an object. Its status property sets the panel:

msg.payload.statusPanel
true, or any other truthy valueSession On Text, green
false, or any other falsy value such as 0Session Off Text, red
nullEmpty, white

A payload without status leaves the panel as it is. The panel starts empty; a browser that opens the page shows the state of the last message received, when that message had a status.

Output ​

This node does not send messages. Input messages are not passed on.

Usage example ​

A function node placed after the node that starts and stops the inspection session (here a Button Switch, whose msg.payload is the new state):

js
msg.payload = { status: msg.payload === true };
return msg;

The panel turns green when the session starts and red when it stops. Sending { status: null } clears it.