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

Combobox floating-ui does not update its position when overlayPosition is fixed #8708

Closed
2 of 6 tasks
nCastle1 opened this issue Feb 8, 2024 · 9 comments
Closed
2 of 6 tasks
Assignees
Labels
4 - verified Issues that have been released and confirmed resolved. ArcGIS Maps SDK for JavaScript Issues logged by ArcGIS SDK for JavaScript team members. ArcGIS Web Analysis Issues logged by ArcGIS Web Analysis team members bug Bug reports for broken functionality. Issues should include a reproduction of the bug. calcite-components Issues specific to the @esri/calcite-components package. has workaround Issues have a workaround available in the meantime. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive p - medium Issue is non core or affecting less that 60% of people using the library

Comments

@nCastle1
Copy link

nCastle1 commented Feb 8, 2024

Check existing issues

Actual Behavior

When the combobox scrolls/moves while the dropdown is open, the dropdown floats away from the input.

Screen.Recording.2024-02-08.at.1.24.52.PM.mov

Expected Behavior

I expect the combobox dropdown to stick to the input, like it did in a previous release. This matches the behavior of input-date-picker with the same overlayPositioning setting.

Screen.Recording.2024-02-08.at.1.32.15.PM.mov

Reproduction Sample

https://gist.github.com/nCastle1/a290f6ef4cb47cebcc37840d0c3ff122

Reproduction Steps

Place combobox in scrollable container, open combobox, scroll.

Reproduction Version

2.4.0

Relevant Info

Tested with Edge on macOS.

I noticed that the main difference between how input-date-picker does it and how combobox does it is on this line: https://github.com/Esri/calcite-components/blob/9eb680a5045e142d6db4c1d971c69961a73a44ee/packages/calcite-components/src/components/combobox/combobox.tsx#L960

input-date-picker wraps this in requestAnimationFrame():

requestAnimationFrame(() => connectFloatingUI(this, this.referenceEl, this.floatingEl));

I tested locally and that fixed the issue.

Regression?

Yes

Priority impact

p4 - not time sensitive

Impact

Can be worked around using the reposition method and monitoring for scroll on containers, but the workaround is clunky.

Calcite package

  • @esri/calcite-components
  • @esri/calcite-components-angular
  • @esri/calcite-components-react
  • @esri/calcite-design-tokens
  • @esri/eslint-plugin-calcite-components

Esri team

ArcGIS Maps SDK for JavaScript

@nCastle1 nCastle1 added 0 - new New issues that need assignment. bug Bug reports for broken functionality. Issues should include a reproduction of the bug. needs triage Planning workflow - pending design/dev review. labels Feb 8, 2024
@github-actions github-actions bot added ArcGIS Maps SDK for JavaScript Issues logged by ArcGIS SDK for JavaScript team members. calcite-components Issues specific to the @esri/calcite-components package. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive labels Feb 8, 2024
@eriklharper eriklharper self-assigned this Feb 9, 2024
@jcfranco
Copy link
Member

Used the provided repro case and dug a bit. This started happening in @esri/calcite-components@2.2.0-next.1. The only thing that looks suspicious from the diff between v2.2.0-next.0 and v2.2.0-next.1 is b15c052.

@jcfranco jcfranco added spike Issues that need quick investigations for time estimations, prioritization, or a quick assessment. needs milestone Planning workflow - pending milestone assignment, has priority and/or estimate. p - low Issue is non core or affecting less that 10% of people using the library has workaround Issues have a workaround available in the meantime. and removed needs triage Planning workflow - pending design/dev review. labels Feb 29, 2024
@dFranz2
Copy link

dFranz2 commented Mar 14, 2024

I ran into the same issue with overlayPositioning="fixed" when using the Dropdown component in development.

When trying to reproduce the issue in a codepen I noticed overlayPositioning="fixed" worked as expected but overlay-positioning="fixed" did not work as expected (list items 1 and 3 in the codepen)

Codepen: https://codepen.io/dmap/pen/vYMXjam

@ethanbdev ethanbdev added the ArcGIS Web Analysis Issues logged by ArcGIS Web Analysis team members label Mar 14, 2024
@amring1
Copy link

amring1 commented Mar 15, 2024

Any chance we can escalate getting a fix for this? It affects a lot of different places within analysis workflows, including the new ModelBuilder web experience

@jcfranco
Copy link
Member

@geospatialem Bumping priority on this one. I'll pick up this spike next week and will provide a more accurate estimate/timeline for this.

@jcfranco jcfranco added p - medium Issue is non core or affecting less that 60% of people using the library and removed p - low Issue is non core or affecting less that 10% of people using the library needs milestone Planning workflow - pending milestone assignment, has priority and/or estimate. labels Mar 15, 2024
@jcfranco jcfranco self-assigned this Mar 15, 2024
@jcfranco jcfranco added 1 - assigned Issues that are assigned to a sprint and a team member. and removed 0 - new New issues that need assignment. labels Mar 15, 2024
@jcfranco jcfranco added this to the 2024-03-26 - Mar Release milestone Mar 15, 2024
@driskull
Copy link
Member

@jcfranco I think #8973 may fix this one as well.

@Horiatu
Copy link

Horiatu commented Mar 22, 2024

This also happens in one of our project with:
"dependencies": {
"@arcgis/core": "^4.29.10",
"@esri/calcite-components-react": "^2.6.0",

image

(The Municipality CalciteCombobox has been expanded and the host panel is scrolled using the mouse wheel.)

@jcfranco
Copy link
Member

@nCastle1, @amring1, @Horiatu Would you mind testing with @next? As Matt suggested, #8973 seems to have fixed this. At least @dFranz2's repro case.

@nCastle1
Copy link
Author

I tested and confirmed this fixes the issue for Maps SDK for JS's FeatureForm and Editor widgets.

@jcfranco
Copy link
Member

@nCastle1 Thanks for testing! Closing as verified based on ☝️.

@jcfranco jcfranco added 4 - verified Issues that have been released and confirmed resolved. and removed 1 - assigned Issues that are assigned to a sprint and a team member. spike Issues that need quick investigations for time estimations, prioritization, or a quick assessment. labels Mar 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4 - verified Issues that have been released and confirmed resolved. ArcGIS Maps SDK for JavaScript Issues logged by ArcGIS SDK for JavaScript team members. ArcGIS Web Analysis Issues logged by ArcGIS Web Analysis team members bug Bug reports for broken functionality. Issues should include a reproduction of the bug. calcite-components Issues specific to the @esri/calcite-components package. has workaround Issues have a workaround available in the meantime. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive p - medium Issue is non core or affecting less that 60% of people using the library
Projects
None yet
Development

No branches or pull requests

8 participants