In the process of migrating MediaSearch to Codex (see T336821) (, I've found a couple of behaviors that the existing sd-components possess which their Codex equivalents lack.
One example is having a dedicated clear event that is emitted by the text input component when a user clicks the optional clear button to remove all text at once.
In MediaSearch, this event is treated differently from a simple text change – the clear event is used as a signal to discard all previous search results (otherwise, search results from the previous query persist while the user makes single-letter changes in the input, and a new search is only performed when they select a lookup result or click on the search button).
It's not unreasonable to think that other features may need to assign special behavior to the use of the clear button as well.
Proposal
Let's add a clear event to the CdxTextInput component which is fired when the clear button is clicked. This event probably doesn't need a payload, and users can safely ignore it if they don't care about this behavior.