ionic-team / ionic-team/ionic-framework

feat(datetime/picker): public API to programmatically enter numeric input mode

Abierto
#30,634 0 comentarios 0 reacciones 0 asignados Ver en GitHub
triage
Lenguaje dominante
TypeScript
Estrellas
52.7k
Forks
13.3k
Merge medio
1 d 15 h
PR fusionados (30 d)
51

Descripción

### Prerequisites

- [x] I have read the [Contributing Guidelines](https://github.com/ionic-team/ionic-framework/blob/main/docs/CONTRIBUTING.md#creating-an-issue).
- [x] I agree to follow the [Code of Conduct](https://ionicframework.com/code-of-conduct).
- [x] I have searched for [existing issues](https://github.com/ionic-team/ionic-framework/issues) that already include this feature request, without success.

### Describe the Feature Request

ion-datetime (wheel) + ion-picker supports a “numeric input mode” when the user taps a numeric column: the picker focuses an internal , shows the OS keypad, and lets users type to update both hour and minute columns.

There’s currently no public API to trigger the same behavior programmatically (e.g., from a button or accessibility shortcut).

### Describe the Use Case

- Accessibility: provide a keyboard/assistive-tech control to enter numeric mode.

- UX: offer an “Edit time” button that behaves exactly like a tap.

- Automated testing & consistency across platforms.

### Describe Preferred Solution

Expose a safe, documented method:

// on ion-picker (and used by ion-datetime internally)
enterInputMode(column?: HTMLIonPickerColumnElement | 'hour' | 'minute', options?: { focus?: boolean }): void;
exitInputMode(): void;

// or on ion-datetime (delegates to internal picker)
enterInputMode(scope?: 'all' | 'hour' | 'minute', options?: { focus?: boolean }): void;

Behavior should mirror a real tap:

- Set internal input-mode state (multi-column when scope === 'all').

- Emit the same event columns currently listen for.

- focus the hidden input to open the keypad.

### Describe Alternatives

_No response_

### Related Code

Any datetime/picker

### Additional Information

Without a public API, it’s impossible to trigger numeric input mode via assistive technology (e.g., VoiceOver/ TalkBack actions, hardware keyboard shortcuts, or custom accessibility buttons). This can prevent certain users from easily adjusting time values, especially those with motor impairments who find wheel scrolling difficult.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.