Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion dev/src/views/Expression.js
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ export default class Expression extends EventDispatcher {
// catches pasting full expressions in.
// TODO: will need to be updated to work with other delimeters
this._deferUpdate();
let str = evt.text[0];
let str = evt.text[0].trim();
if (str.length < 3 || !str.match(/^\/.+[^\\]\/[a-z]*$/ig) || evt.from.ch !== 1 || evt.to.ch != 1 + evt.removed[0].length) {
// not pasting a full expression.
return;
Expand Down