Dynamic attributes for widgets

 My issue is that I would like bar widgets to have a max value that is not just a static number.  For example, on a monthly basis the max value would change depending on another parameter....in my case this other parameter would be obtained from another feed value.

So my first attempt was to change the max value attribute in the bar_render.js (line 51) to be a "feed" rather than "value" data type but this doesn't seem to work - I don't see any bar height.

My second idea was to do a getJSON call in the bar_draw() function of bar_render.js.  This would effectively do an API call to get the feed value.  This worked, however the system slowed down dramatically as the bar_draw() function is being called repeatedly and it must not have liked all the API calls.

Right now I'm at a loss if this is even possible.  Any help would be great.  I imagine this problem applies to all attributes for widgets.

I am using emonCMS v8.0.3.

Thanks,
Kevin