Skip to content

Commit

Permalink
Fix bug whereby selection of suggestion would overwrite input text
Browse files Browse the repository at this point in the history
  • Loading branch information
getdave committed Aug 3, 2021
1 parent 6ab3473 commit 02859ee
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/block-editor/src/components/link-control/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,10 @@ function LinkControl( {
);

const handleSelectSuggestion = ( updatedValue ) => {
onChange( updatedValue );
onChange( {
...updatedValue,
text: internalTextValue,
} );
stopEditing();
};

Expand Down

0 comments on commit 02859ee

Please sign in to comment.