Cannot trigger empty on button on_click callback but can do so using straight forward code

I think my answer on your other post may be helpful/relevant here as well, but let me know if this is still a separate question.