I have created a custom widget that consists of a textarea, with a button that has an icon inside.
I use this widget on 3 fields on an order line, 2 custom and the third is the name field.
This works fine for the two custom fields but not 100% for the name field because I conditionally want to show / hide the button for this field.
I have another custom property that checks a custom property of product_id on the sale order line, and if it is a specific type, the button should show in the 'name' field.
It technically works, but the button doesn't hide or show immediately for the 'name', I first have to click away from the order line.
I have tried a multitude of things, such as trying to detect the onchange of the product_id field and re-render, or reload the custom widget or the sale order widget. I've also tried programmatically saving, or focusing somewhere else. Nothing seems to work.