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(combobox): fix error that occurs when a click is emitted when the component is appended to the DOM #9373

Conversation

jcfranco
Copy link
Member

Related Issue: #9321

Summary

This fixes an issue where references to internal elements were undefined in the window-level click handler. This would happen because the window click handler was added when the component was connected, but before its internals were rendered.

@jcfranco jcfranco requested a review from a team as a code owner May 20, 2024 21:49
@jcfranco jcfranco added the skip visual snapshots Pull requests that do not need visual regression testing. label May 20, 2024
@github-actions github-actions bot added the bug Bug reports for broken functionality. Issues should include a reproduction of the bug. label May 20, 2024
Copy link
Member

@driskull driskull left a comment

Choose a reason for hiding this comment

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

👍

@jcfranco jcfranco merged commit 34a2bbe into hotfix May 21, 2024
8 checks passed
@jcfranco jcfranco deleted the jcfranco/9321-fix-error-when-click-is-emitted-on-combobox-connect branch May 21, 2024 00:39
benelan pushed a commit that referenced this pull request May 21, 2024
… component is appended to the DOM (#9373)

**Related Issue:** #9321

## Summary

This fixes an issue where references to internal elements were undefined
in the window-level click handler. This would happen because the window
click handler was added when the component was connected, but before its
internals were rendered.
benelan added a commit that referenced this pull request May 21, 2024
🤖 I have created a release *beep* *boop*
---


<details><summary>@esri/calcite-components: 2.8.3</summary>

##
[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)


### Bug Fixes

* **combobox:** Fix error that occurs when a click is emitted when the
component is appended to the DOM
([#9373](#9373))
([34a2bbe](34a2bbe))
</details>

<details><summary>@esri/calcite-components-angular: 2.8.3</summary>

##
[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)


### Miscellaneous Chores

* **@esri/calcite-components-angular:** Synchronize components versions


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @esri/calcite-components bumped from ^2.8.2 to ^2.8.3
</details>

<details><summary>@esri/calcite-components-react: 2.8.3</summary>

##
[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)


### Miscellaneous Chores

* **@esri/calcite-components-react:** Synchronize components versions


### Dependencies

* The following workspace dependencies were updated
  * dependencies
    * @esri/calcite-components bumped from ^2.8.2 to ^2.8.3
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: Ben Elan <[email protected]>
benelan added a commit that referenced this pull request May 21, 2024
🤖 I have created a release *beep* *boop*
---

<details><summary>@esri/calcite-components: 2.8.3</summary>

[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)

* **combobox:** Fix error that occurs when a click is emitted when the
component is appended to the DOM
([#9373](#9373))
([34a2bbe](34a2bbe))
</details>

<details><summary>@esri/calcite-components-angular: 2.8.3</summary>

[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)

* **@esri/calcite-components-angular:** Synchronize components versions

* The following workspace dependencies were updated
  * dependencies
    * @esri/calcite-components bumped from ^2.8.2 to ^2.8.3
</details>

<details><summary>@esri/calcite-components-react: 2.8.3</summary>

[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)

* **@esri/calcite-components-react:** Synchronize components versions

* The following workspace dependencies were updated
  * dependencies
    * @esri/calcite-components bumped from ^2.8.2 to ^2.8.3
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: Ben Elan <[email protected]>
@benelan benelan mentioned this pull request May 21, 2024
jcfranco pushed a commit that referenced this pull request May 21, 2024
🤖 I have created a release *beep* *boop*
---

<details><summary>@esri/calcite-components: 2.8.3</summary>


[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)

* **combobox:** Fix error that occurs when a click is emitted when the
component is appended to the DOM
([#9373](#9373))

([34a2bbe](34a2bbe))
</details>

<details><summary>@esri/calcite-components-angular: 2.8.3</summary>


[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)

* **@esri/calcite-components-angular:** Synchronize components versions

* The following workspace dependencies were updated
  * dependencies
    * @esri/calcite-components bumped from ^2.8.2 to ^2.8.3
</details>

<details><summary>@esri/calcite-components-react: 2.8.3</summary>


[2.8.3](https://github.com/Esri/calcite-design-system/compare/@esri/[email protected]...@esri/[email protected])
(2024-05-21)

* **@esri/calcite-components-react:** Synchronize components versions

* The following workspace dependencies were updated
  * dependencies
    * @esri/calcite-components bumped from ^2.8.2 to ^2.8.3
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See

[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: Calcite Admin <[email protected]>
jcfranco added a commit that referenced this pull request Jun 4, 2024
…via a click (#9501)

**Related Issue:** #9504

## Summary

This fixes an issue where any clicks when the popover is connected to
the DOM would cause it to be immediately closed.

This would happen because `PopoverManager`'s window `click` handler was
being added and invoked during `connectedCallback` and not after the
component was initialized (somewhat similar to
#9373).

**Note**: there are no accompanying tests as this is not reproducible in
the test environment, which uses the lazy-loaded output.
benelan pushed a commit that referenced this pull request Jun 25, 2024
…via a click (#9501)

**Related Issue:** #9504

## Summary

This fixes an issue where any clicks when the popover is connected to
the DOM would cause it to be immediately closed.

This would happen because `PopoverManager`'s window `click` handler was
being added and invoked during `connectedCallback` and not after the
component was initialized (somewhat similar to
#9373).

**Note**: there are no accompanying tests as this is not reproducible in
the test environment, which uses the lazy-loaded output.
benelan pushed a commit that referenced this pull request Jun 25, 2024
…via a click (#9501)

**Related Issue:** #9504

## Summary

This fixes an issue where any clicks when the popover is connected to
the DOM would cause it to be immediately closed.

This would happen because `PopoverManager`'s window `click` handler was
being added and invoked during `connectedCallback` and not after the
component was initialized (somewhat similar to
#9373).

**Note**: there are no accompanying tests as this is not reproducible in
the test environment, which uses the lazy-loaded output.
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. skip visual snapshots Pull requests that do not need visual regression testing.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants