Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes issue primefaces#7014: inserting mentions results in duplicated text #7017

Merged
merged 2 commits into from
Aug 11, 2024

Conversation

chaowss
Copy link
Contributor

@chaowss chaowss commented Aug 10, 2024

Fixes: #7014

The issue was that event.target is not the form element but actually a list item element, which doesn't have the selectionStart attribute.

I've also added a change where inserting the mention in front of a space does not result in a double space.

Note: this is my first time contributing to an open source project, let me know if there's anything I can do better!

… text

The issue was that event.target is not the prompt form but actually a list item element,
which doesn't have the selectionStart attribute.

I've also added a change where inserting the mention in front of a space does not result in a double space.
Copy link

vercel bot commented Aug 10, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
primereact ⬜️ Ignored (Inspect) Visit Preview Aug 11, 2024 4:12am
primereact-v9 ⬜️ Ignored (Inspect) Visit Preview Aug 11, 2024 4:12am

Copy link

Thanks a lot for your contribution! But, PR does not seem to be linked to any issues. Please manually link to an issue or mention it in the description using #<issue_id>.

components/lib/mention/Mention.js Outdated Show resolved Hide resolved
@chaowss chaowss requested a review from melloware August 11, 2024 02:04
@melloware melloware merged commit 69873b2 into primefaces:master Aug 11, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inserting a mention in between text results in text to be duplicated
2 participants