-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
fix: ESC key does not cancel editing in data browser cell #3001
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
🚀 Thanks for opening this pull request! We appreciate your effort in improving the project. Please let us know once your pull request is ready for review. |
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
📝 WalkthroughWalkthroughAdds ESC/cancel handling and switches key listeners from keypress/click to keydown/touchend across editors. Introduces an optional onCancel prop for DateTimeEditor and propagates onCancel through Browser.Editor to all editor types. Updates mount/unmount listeners accordingly and adjusts Enter key paths to prevent default behavior. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
actor U as User
participant E as Editor (e.g., String/Number/DateTime/GeoPoint)
participant B as Browser.Editor (parent)
rect rgba(230,240,255,0.4)
note over U,E: Key handling on keydown
U->>E: keydown Enter
E->>E: validate/prepare value
E-->>B: onCommit(value)
E-->>U: preventDefault + stopPropagation
end
rect rgba(255,235,230,0.5)
note over U,E: Cancel flow on Escape
U->>E: keydown Escape
alt onCancel provided
E-->>B: onCancel()
else
E-->>B: onCommit(original/current value)
end
E-->>U: preventDefault + stopPropagation
end
rect rgba(235,255,235,0.5)
note over U,E: External interaction
U->>E: body touchend (outside)
E->>E: checkExternalClick()
alt commit or cancel per editor state
E-->>B: onCommit(...) or onCancel()
end
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (5)
🧰 Additional context used🧬 Code graph analysis (1)src/dashboard/Data/Browser/Editor.react.js (4)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🔇 Additional comments (17)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Uffizzi Ephemeral Environment
|
# [7.6.0-alpha.10](7.6.0-alpha.9...7.6.0-alpha.10) (2025-10-14) ### Bug Fixes * ESC key does not cancel editing in data browser cell ([#3001](#3001)) ([d1d7241](d1d7241))
|
🎉 This change has been released in version 7.6.0-alpha.10 |
# [8.0.0](7.5.0...8.0.0) (2025-11-01) ### Bug Fixes * Add missing major version increase of dashboard release ([#3005](#3005)) ([5debb4d](5debb4d)) * Cannot connect to server with error invalid header name ([#3006](#3006)) ([ea4ec07](ea4ec07)) * Currently displayed view reloads when editing and saving a different view ([#3002](#3002)) ([794a35a](794a35a)) * Dashboard config objects stored on server with public read / write access ([#2997](#2997)) ([31a4639](31a4639)) * ESC key does not cancel editing in data browser cell ([#3001](#3001)) ([d1d7241](d1d7241)) * Filter text field in data browser partly looses focus when hitting enter key to apply filter ([#2992](#2992)) ([e3085b9](e3085b9)) * Filter text field in data browser partly looses focus when selecting in drop-down element by hitting enter key to apply filter ([#2993](#2993)) ([f4c17c7](f4c17c7)) * Info panel briefly shows cached media content from previously selected cell when using pre-fetch ([#3008](#3008)) ([dd6a85e](dd6a85e)) * Missing alert when changing data browser browser data while rows are selected ([#2994](#2994)) ([6cabaa3](6cabaa3)) * Security upgrade parse from 3.5.1 to 7.0.1 ([#3003](#3003)) ([5123fbf](5123fbf)) * Security upgrade passport from 0.5.3 to 0.6.0 ([#3000](#3000)) ([fbb5e6d](fbb5e6d)) * Session management issue that causes malformed redirect URLs ([#3011](#3011)) ([1649dd3](1649dd3)) * Storing view on server creates view key with hashed view name instead of UUID ([#2995](#2995)) ([7cb65f3](7cb65f3)) * Switching between browser tabs can cause illegible text color for config parameter value field ([#3010](#3010)) ([77c5c67](77c5c67)) * View table data may be retained when switching between views ([#2996](#2996)) ([ddc91c9](ddc91c9)) ### Features * Add `matches regex` filter to data browser replacing limited `string contains string` filter ([#2991](#2991)) ([64a9f71](64a9f71)) * Add info panel options `prefetchImage`, `prefetchVideo`, `prefetchAudio` to pre-fetch media content in the info panel ([#3009](#3009)) ([6796c9e](6796c9e)) * Add Parse Server version compatibility detection ([#3004](#3004)) ([9a7a60f](9a7a60f)) ### Performance Improvements * Storing, deleting, modifying view in server storage now only affects the specific view instead of updating all views ([#2998](#2998)) ([48cea3c](48cea3c)) ### BREAKING CHANGES * This increases the required minimum version to Parse Server 7. ([5debb4d](5debb4d))
|
🎉 This change has been released in version 8.0.0 |
New Pull Request Checklist
Issue Description
When hitting the Esc key while editing a cell in the DataBrowser table, the editing does not abort.
Approach
According to MDN Web Docs, the keypress event is deprecated:
So this change also modernizes the code to follow current web standards.
The root cause chain was:
By changing to keydown:
Summary by CodeRabbit
New Features
Improvements
Bug Fixes