async def on_select_changed(self, event: Select.Changed) -> None:
        """Handle changes in the host API dropdown."""
        if event.select.id == "host-api-select":
            self.current_host_api = int(event.value.id)
            self.filter_devices()
            if self.stage == "input":
                self.populate_list(self.input_devices)
                if self.default_input_device:
                    self._select_default_in_list(self.default_input_device)
            elif self.stage == "output":
                self.populate_list(self.output_devices)
                if self.default_output_device:
                    self._select_default_in_list(self.default_output_device)
Handle changes in the host API dropdown.
examples/local-input-select-stt/select_audio_device.py