We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ea34621 commit d2c43f3Copy full SHA for d2c43f3
1 file changed
src/LiveDevelopment/BrowserScripts/RemoteFunctions.js
@@ -3043,7 +3043,12 @@ function RemoteFunctions(config = {}) {
3043
isEscapePressed = true;
3044
// Cancel editing
3045
event.preventDefault();
3046
- finishEditing(element, false); // false means that the edit operation was cancelled
+ const newContent = element.textContent;
3047
+ if (oldContent !== newContent) {
3048
+ finishEditing(element, false); // false means that the edit operation was cancelled
3049
+ } else { // no content change we can avoid sending details to the editor
3050
+ finishEditingCleanup(element);
3051
+ }
3052
} else if (event.key === "Enter" && !event.shiftKey) {
3053
isEscapePressed = false;
3054
// Finish editing on Enter (unless Shift is held)
0 commit comments