input widget Issue with updating

I’m working with a Date Input widget in Palantir Workshop. When I select a date for the first time, the variable is set correctly. But when I clear or deselect the date, the variable still holds the last selected value until I pick a new date.

I would like the variable to automatically reset to undefined (or null) when the date is deselected. How can I configure this behavior in Workshop?

the data in the input is coming from a function.