-
Notifications
You must be signed in to change notification settings - Fork 380
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
Rich text crashes when clicked multiple times in a row #1103
Comments
Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible. |
After investigating this a bit, there is an infinite loop (seems to be caused by fixing #666) This commit: |
@nbelyh many thanks for investigating it and providing more details. Would you be available to fix it and send a PR? |
@joelfmrodrigues unfortunately I am not sure how to fix this properly... 😢 The issue looks a bit complicated for me. There were already several attempts to fix the core thing as far as I understand (linked issue), i.e. the
This comment is a sad truth. Unfortunately, if you replace value with defaultValue, you'll get the "evil" issue 666 come back again. I've decided just to live with that one for now... waiting for a hero 😄 I would say the author of that comment may be a decent candidate 😄 I could revert the fix for 666, I think having 666 is better than infinite loop and app crash anyway? I would probably ask @AJIXuMuK to look at this when he has time, since he already dealt with this thing? |
I will look at it for sure. |
Category
[ ] Enhancement
[x] Bug
[ ] Question
Version
Please specify what version of the library you are using: [3.5.0]
Expected / Desired Behavior / Question
Nothing happens.
Observed Behavior
The application crashes (react crashes), with message:
Crashes here, at the row 867,
this.setState
:sp-dev-fx-controls-react/src/controls/richText/RichText.tsx
Lines 854 to 873 in 2f28397
Steps to Reproduce
Quickly (milliseconds) click in the RichText text control several times, like five or so (using left mouse button).
The rich text should not be empty (should contain some formatted text, such as a hyperlink)
It looks like the handler just enters the infinite loop, maybe a safeguard around it could solve it.
The text was updated successfully, but these errors were encountered: