Closed senwang86 closed 1 year ago
Thanks! Esc
works in Code cells but seems not in Rich cells.
Thanks!
Esc
works in Code cells but seems not in Rich cells.
Just checked, it seems that onBlur()
is correctly fired after pressing Esc
, while the editor box is failed to to be selected as the code editor.
Still one bug. In the edit mode of a Rich pod, Hitting Esc should select the Rich pod. But now it drops me to its parent scope.
Still one bug. In the edit mode of a Rich pod, Hitting Esc should select the Rich pod. But now it drops me to its parent scope.
To be more specific, this bug happens when the Rich pod is inside a scope.
The cause is:
I tried a few methods, but none of them worked yet.
Thanks!
Thanks @senwang86 but sorry I probably come across some corner cases:
You can test in this repo: https://app.codepod.io/repo/eyusr62dyglelzg7m4jz
Thanks @senwang86 but sorry I probably come across some corner cases:
- When I press "Esc" on a pod, I do not always enter the command mode of its parent. If I first select and enter the parent scope, then I can. But the Escape should work without me doing that first. https://github.com/codepod-io/codepod/assets/438579/3bc802ab-b3c6-4b0b-aa1f-d2d8ea31b9a4
- When I hit "Enter" on a scope, I sometimes got focused on the child of another scope instead of the scope. https://github.com/codepod-io/codepod/assets/438579/6b8c4f70-1893-4726-8b1d-20f815f0e061
- When I hit "Enter" on a pod, I do not always go into the Edit mode. https://github.com/codepod-io/codepod/assets/438579/582eb194-041f-49f2-85b1-0fa0e395f080
You can test in this repo: https://app.codepod.io/repo/eyusr62dyglelzg7m4jz
Really appreciate the test, I can reproduce the bug, the states are not updated in response to the "drag handle click" event. Let me send a patch later.
BTW, I think Esc is not a good key for jump-to-parent. We have many context menus and pop-up menus, and we need to use <Esc>
to close those menus. How about <shift>+<up>
and <shift>+<down>
for up and down jumps?
How about
<shift>+<up>
and<shift>+<down>
for up and down jumps?
Moving the shortcut discussion to #418
Summary
Adding edit and command mode into Codepod regarding issue #88
Test