Problem
On a phone, the edit toolbar above the keyboard can show while the pad is read-only.
ToolbarMobile.tsx:46 returns early on !editor || !isKeyboardOpen || !padOwnsKeyboard. It has no isEditable check. The toolbar handlers call editor.chain().focus()… and can still dispatch edits into a view that is not editable.
Pad Find (#250) raises the keyboard in read mode. A CSS rule in _caret-find.scss hides the toolbar while the find bar has focus. Any other input that raises the keyboard in read mode still shows the toolbar.
Fix
Change the early return to add !isEditable.
First, check on a real iPhone that settings.editor.isEditable is already true when the keyboard rises on the EditFAB tap and on the double-tap edit path. If it is not, this gate would hide the toolbar during normal editing.
Check
- iPhone, read mode: open Find. No edit toolbar shows.
- iPhone, edit mode: tap EditFAB, then double-tap text. The toolbar shows both times.
Part of #249.
Problem
On a phone, the edit toolbar above the keyboard can show while the pad is read-only.
ToolbarMobile.tsx:46returns early on!editor || !isKeyboardOpen || !padOwnsKeyboard. It has noisEditablecheck. The toolbar handlers calleditor.chain().focus()…and can still dispatch edits into a view that is not editable.Pad Find (#250) raises the keyboard in read mode. A CSS rule in
_caret-find.scsshides the toolbar while the find bar has focus. Any other input that raises the keyboard in read mode still shows the toolbar.Fix
Change the early return to add
!isEditable.First, check on a real iPhone that
settings.editor.isEditableis already true when the keyboard rises on the EditFAB tap and on the double-tap edit path. If it is not, this gate would hide the toolbar during normal editing.Check
Part of #249.