node-red-dashboard icon indicating copy to clipboard operation
node-red-dashboard copied to clipboard

How to dynamically set Y-axis min and max in ui_chart with Node-RED Dashboard 2.0?

Open pepe12311 opened this issue 8 months ago • 1 comments

Hello,

I’m using @flowfuse/node-red-dashboard version 1.23.0 (Node-RED Dashboard 2.0) and I’m trying to dynamically set the Y-axis min and max values for a ui_chart node. I’ve tried sending the following message from a function node, but it doesn’t work:

msg = { chartOptions: { scales: { y: { type: "linear", min: 20, max: 30, ticks: { stepSize: 2 } } } } };

The Y-axis does not update to the range 20 to 30 as expected. I’ve also tried using options instead of chartOptions, but it still doesn’t work. Is there a way to dynamically configure the Y-axis min and max values in ui_chart? If so, could you provide an example of the correct message format?

Thanks for your help!

pepe12311 avatar Apr 13 '25 17:04 pepe12311

Annoyingly not yet supported, we have it recorded https://github.com/FlowFuse/node-red-dashboard/issues/1179 as a todo item, but haven't been able to make the progress we'd like with it just yet.

joepavitt avatar Apr 14 '25 17:04 joepavitt