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

fix(input, input-number, input-text): Fix infinite loop crashing browser. #5882 #5961

Merged
merged 2 commits into from
Dec 9, 2022

Conversation

driskull
Copy link
Member

@driskull driskull commented Dec 9, 2022

Related Issue: #5882

Summary

  • Adds click handler to focus on internal inputs
  • Focus handler only emits event

@github-actions github-actions bot added the bug Bug reports for broken functionality. Issues should include a reproduction of the bug. label Dec 9, 2022
@eriklharper
Copy link
Contributor

@driskull these changes look good, about the same as what I have (so far) come up with for resolving the infinite loop bug, but I still don't know how to get the setFocus call to work right after the programmatic insertion of the input element. Let's sync up on this maybe tomorrow. Focusing with the keyboard works fine, but for some reason clicks into the input don't focus the element and the setFocus calls don't work either. Very strange.

@driskull
Copy link
Member Author

driskull commented Dec 9, 2022

I still don't know how to get the setFocus call to work right after the programmatic insertion of the input element.

Yeah, I think something with focus-trap isn't allowing this. Maybe we can do this via a follow-up.

I will add a way to disable the focus trap for Modal.

@driskull driskull marked this pull request as ready for review December 9, 2022 16:50
@driskull driskull requested a review from a team as a code owner December 9, 2022 16:50
@driskull
Copy link
Member Author

driskull commented Dec 9, 2022

@eriklharper can we get this one installed today?

Copy link
Contributor

@eriklharper eriklharper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@eriklharper can we get this one installed today?

Yes, let's do it. Approved :)

@eriklharper eriklharper added the pr ready for visual snapshots Adding this label will run visual snapshot testing. label Dec 9, 2022
@driskull driskull merged commit 190cfac into master Dec 9, 2022
@driskull driskull deleted the dris0000/infinite-loop-fix branch December 9, 2022 18:20
@github-actions github-actions bot added this to the 2023 January Priorities milestone Dec 9, 2022
@geospatialem
Copy link
Member

I will add a way to disable the focus trap for Modal.

@driskull Do you have an open PR for the modal focus trap disable? Also noticed the behavior when trying to verify the related issue.

@driskull
Copy link
Member Author

driskull commented Dec 9, 2022

Yeah here's the PR: #5965

benelan added a commit that referenced this pull request Dec 12, 2022
* master: (55 commits)
  build: update browserslist db (#5986)
  docs: update component READMEs (#5980)
  1.0.0-next.670
  refactor(input-date-picker,date-picker)!: Removing deprecated locale properties (#5977)
  1.0.0-next.669
  refactor(input-date-picker)!: Remove deprecated active property (#5974)
  1.0.0-next.668
  fix(modal, popover): Add `disableFocusTrap` property to toggle focus trapping. (#5965)
  1.0.0-next.667
  refactor(input-time-picker)!: Remove deprecated active property (#5970)
  docs(changelog): fix breaking change indent levels (#5973)
  1.0.0-next.666
  refactor(time-picker)!: Remove deprecated locale property (#5962)
  1.0.0-next.665
  fix(input, input-number, input-text): Fix infinite loop crashing browser. #5882 (#5961)
  test(floating-ui): fix type errors (#5966)
  docs: update component READMEs (#5964)
  1.0.0-next.664
  fix(alert): auto-dismissible retains close button and dismisses timer while a user is hovering over (#5872)
  chore(color-picker): add opacity string (#5959)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug reports for broken functionality. Issues should include a reproduction of the bug. pr ready for visual snapshots Adding this label will run visual snapshot testing.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants