podio / jquery-mentions-input

MIT License
985 stars 333 forks source link

Issue when same text which is to be mentioned already in the content #104

Open ShriVishnu opened 9 years ago

ShriVishnu commented 9 years ago

Hey, When use the below example comes an issue

Hello john, Pls check this @john.

The mentioning should be done only to the second name(since @ should trigger)

But actually the regex get replaced to the first match,,, This should not be in such way ?

djhvscf commented 9 years ago

Do you have an example of your code? JsFiddle?? @ShriVishnu

ShriVishnu commented 9 years ago

Hi, Thanks for your reply. No need of sample code. Just try it in your own demo page http://podio.github.io/jquery-mentions-input/

Try this, the second time is what i have mentioned but the same text in first is highlighted hello Kenneth Auchenberg how r u ? Kenneth Auchenberg

djhvscf commented 9 years ago

Do you want mention the same person many times?? So this thing can be a enhancement!!

ShriVishnu commented 9 years ago

@djhvscf I didn't mention the name twice !!!! I mention only once but the plain text itself contains the same name which i mention.

For example,, consider a person named 'a'.

When I opt for an input like

I need a toy @a

Here the 'a' which comes after need is taken as mentioned name and highlighted which is a wrong context. Kindly try the example in the previous post. The name which comes first is entered as plain text and not an mention triggered with '@' symbol.

ShriVishnu commented 9 years ago

@djhvscf : Hey ! any update on this ? And don't consider this as an enhancement! I am not asking for mentioning a person twice. Please do understand the issue and remove the label!

djhvscf commented 9 years ago

Yes, I'm working on it! But, yes you're right I'm going to remove the label.

ShriVishnu commented 9 years ago

@djhvscf Hi, the issue is not about allowing repeat mentions. I am trying to add a plain text name. For example, consider a name as just 'a'.

Now when an input text added as, "Yesterday, a comment has been added by @a"

Here, note that the first 'a' is plain text and the second 'a' is a mention of username!

Now, the first plain text is taken as the mentioned text and not the actual user name.

This is the issue which I pointed out and not an option for repeat mention!

Thanks for your kind, Regards.

djhvscf commented 9 years ago

Yes, your right.. I already test it with allowRepeat option and it is happening.. I will reopen this issue.. Thanks

sharjeelrajput commented 6 years ago

No update on this .. Strange .. Without solving that issue that library is not useful