#6022·slate

[Android] Soft keyboard dismisses and cursor jumps when typing after toggling a mark on a collapsed selection

Author: virgil1996Created Mar 20, 2026Updated Mar 23, 2026
Labelsbug⚑ cross platform

Description When using Slate on Android. If toggles a mark (e.g., Bold) while the selection is collapsed and then attempts to type, the cursor position breaks and the Android soft keyboard is immediately dismissed. However, if the user highlights an existing piece of text, applies the mark, and then continues typing, the issue does not occur.

I have attached a screen recording demonstrating the exact behavior.

Recording:

https://github.com/user-attachments/assets/295febaa-9b13-4e84-bd4f-d8d9c0a279b9

Steps to reproduce

  • Open a Slate editor on an Android
  • Focus the editor (Selection must be collapsed).
  • Toggle a mark (e.g., Bold).
  • Type any character.

Expected behavior: The soft keyboard should remain open.

Actual behavior: The soft keyboard is instantly dismissed.

Environment: OS: Android 16 (Pixel 9a Emulator)

Slate Version: latest?I used the official sample page for testing. https://www.slatejs.org/examples

Keyboard: Default Android Keyboard