umbraco/Umbraco.UI

Change event not raised in uui-radio when using keyboard

nathanwoulfe opened this issue · 1 comments

Which exact UI Library version are you using? For example: 1.0.1 - don't just write v1.

1.1.0

Bug summary

When using uui-radio inside a uui-radio-group, changing the selected value via keyboard does not raise the change event.

Specifics

Take the below example (truncated for brevity) - using the keyboard to change the value in the uui components logs nothing, while changing the value in the bare-bones lit elements logs the event.

change(e: Event) {
  console.log(e);
}

<uui-radio-group>
  <uui-radio @change=${this.change} label=foo value=foo></uui-radio>
  <uui-radio @change=${this.change} label=bar value=bar></uui-radio>
</uui-radio-group>

<input type="radio" name=radio @change=${this.change} value=foo />
<input type="radio" name=radio @change=${this.change} value=bar />

Steps to reproduce

see above - drop example into an existing component

Expected result / actual result

Changing the input selection via keyboard should fire the change event.

I think this is expected - can get change event from the parent radio group.