Infrastructure medium complexity mobile
0
Dependencies
0
Dependents
0
Entities
0
Integrations

Description

Manages microphone permission requests and tracks the current permission state on the device. It surfaces clear prompts when permission is denied and routes the user to device settings when needed. This component gates all speech recognition functionality to ensure compliant microphone access.

Feature: Speech-to-Text Input

speech-permission-handler

Sources & reasoning

Lines 86-88 provide the precise use-case constraint (post-interaction dictation, not live recording). Line 347 places it in Fase 2, which maps to v1.0 by ordinal. Two organizations (Blindeforbundet + HLF) endorsed it, making it a "should have" cross-org feature.

  • Begge organisasjoner ønsker mulighet for ĂĄ snakke inn rapporter fremfor ĂĄ skrive. Blindeforbundet understreker at opptak under selve samtalen er uønsket - tale-til-tekst er for etterpĂĄ, ved rapportskriving.
  • Tale-til-tekst

Responsibilities

  • Request microphone permission from the device OS on first use
  • Check and cache current microphone permission status
  • Emit permission state changes to dependent components
  • Direct users to device settings when permission is permanently denied
  • Block speech session start when permission is not granted

Interfaces

requestPermission(): Promise<PermissionStatus>
getPermissionStatus(): PermissionStatus
onPermissionChange(callback: (status: PermissionStatus) => void): void
openDeviceSettings(): void