Radio group

Single select by voice: “size large” picks Large.

Say the command followed by an option. The group claims the phrase only when something follows the command, then matches the remainder against options as whole words — longest matching phrase wins, so “Very Satisfied” beats “Satisfied” when both fit. aliases map spoken words to option values, which is how “standard” selects STD.

Basic single select

Loading the Angular kit…

Hold anywhere and say:“size large”“size small”

Props

  • default command
  • default false
Angular
Updates as you tick props
import { Component } from "@angular/core";import { FormsModule } from "@angular/forms";import { ListensRadioGroupComponent } from "@listenssoft/speechui-angular";
@Component({  selector: "demo-radio-group",  imports: [ListensRadioGroupComponent, FormsModule],  template: `    <listens-radio-group      label="Size"      command="size"      [options]="['Small', 'Medium', 'Large']"      [(ngModel)]="size"    />  `,})export class DemoRadioGroup {  size = "Medium";}

Aliases for spoken names

Option values are often codes or abbreviations nobody would say aloud. aliases maps each value to the phrases people actually speak.

Loading the Angular kit…

Hold anywhere and say:“shipping express”“shipping overnight”

Angular
import { Component } from "@angular/core";import { FormsModule } from "@angular/forms";import { ListensRadioGroupComponent } from "@listenssoft/speechui-angular";
@Component({  selector: "demo-radio-aliases",  imports: [ListensRadioGroupComponent, FormsModule],  template: `    <listens-radio-group      label="Shipping"      command="shipping"      [options]="['STD', 'EXP', 'PRI']"      [aliases]="{        STD: ['standard', 'regular'],        EXP: ['express', 'fast'],        PRI: ['priority', 'overnight']      }"      [(ngModel)]="shipping"    />  `,})export class DemoRadioAliases {  shipping = "STD";}

What you can say

SayEffect
“size large”Selects “Large”. The command must lead the phrase, with the option after it.
“size extra large”Selects the longest option whose words all appear — “Extra Large” beats “Large” when both are options.
“shipping overnight”Aliases resolve to their option value (“overnight” → PRI).
“large (alone)”No effect — without the leading command the group never claims the phrase.

Matching is whole-word: “size l” matches nothing, and stray words around the option are fine (“size large please”).

API reference

Angular inputs & outputs for @listenssoft/speechui-angular.

Inputs

InputTypeDefaultDescription
listeningContentstringcommandLabel text while the mic is open.
disabledbooleanfalseDisables the radios; forms setDisabledState too.

Extra inputs

InputTypeDefaultDescription
valuestring""Two-way bindable — [(value)]; also ngModel / formControlName (ControlValueAccessor, string).
optionsstring[][]The selectable values.
commandstringlabelThe spoken prefix; “<command> <option>” selects.
labelstring""Group label; the command fallback.
aliasesRecord<string, string[]>{}Spoken aliases per option value.

Outputs

OutputTypeDefaultDescription
valueChangestring—The [(value)] channel.
matchedstring—Emits when speech selects an option.

Styling hooks

CSS hooks

HookTypeDefaultDescription
.listens-radio-group (root)class—Same part classes as React.
--listens-interactivetoken—The radio accent color.

Behavior notes

  • All frameworks: The radio group uses the two-pass claim flow: it claims only when the command leads with a non-empty remainder, so “size” alone leaves the transcript for others.

Was this page helpful?