(event: KeyboardEvent)
| 494 | }; |
| 495 | const onCancel = () => finish(false); |
| 496 | const onKey = (event: KeyboardEvent) => { |
| 497 | if (event.key === 'Escape') { |
| 498 | event.stopPropagation(); |
| 499 | finish(false); |
| 500 | } |
| 501 | }; |
| 502 | |
| 503 | // Widgets allow sideways panning so the rail still swipes in edit mode; |
| 504 | // once a drag is live, the finger moves the widget, not the rail. |