Compare commits

...

3 Commits

Author SHA1 Message Date
Gleidson Daniel Silva c0935c1c0d
Update index.tsx 2022-02-24 22:26:01 -03:00
GleidsonDaniel e2b11e301e match any letter in the cursor space except @ 2022-02-24 18:33:04 -03:00
GleidsonDaniel e49f817272 add cyrillic alphabet to regex expression 2022-02-24 17:57:54 -03:00
1 changed files with 1 additions and 1 deletions

View File

@ -493,7 +493,7 @@ class MessageBox extends Component<IMessageBoxProps, IMessageBoxState> {
const msg = this.text; const msg = this.text;
const { start, end } = this.selection; const { start, end } = this.selection;
const cursor = Math.max(start, end); const cursor = Math.max(start, end);
const regexp = /([a-z0-9._-]+)$/im; const regexp = /(?!^)[^]/g;
let result = msg.substr(0, cursor).replace(regexp, ''); let result = msg.substr(0, cursor).replace(regexp, '');
// Remove the ! after select the canned response // Remove the ! after select the canned response
if (trackingType === MENTIONS_TRACKING_TYPE_CANNED) { if (trackingType === MENTIONS_TRACKING_TYPE_CANNED) {