Skip to content

Commit

Permalink
test(combobox): fix form-associated test (#8718)
Browse files Browse the repository at this point in the history
**Related Issue:** N/A

## Summary

Fixes a test failure caused by conditional rendering of nodes. 

**Note**: the `grid` key can be removed once we bump Stencil to v4.12.0
or greater as it introduced [automatic `key`
insertion](https://github.com/ionic-team/stencil/releases/tag/v4.12.0).
  • Loading branch information
jcfranco authored and Elijbet committed Feb 15, 2024
1 parent f911407 commit 6b8a439
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1632,7 +1632,7 @@ export class Combobox

return (
this.showingInlineIcon && (
<span class="icon-start">
<span class="icon-start" key="selected-placeholder-icon">
<calcite-icon
class="selected-icon"
flipRtl={this.open && selectedItem ? selectedItem.iconFlipRtl : placeholderIconFlipRtl}
Expand All @@ -1647,7 +1647,7 @@ export class Combobox
renderChevronIcon(): VNode {
const { open } = this;
return (
<span class="icon-end">
<span class="icon-end" key="chevron">
<calcite-icon
icon={open ? "chevron-up" : "chevron-down"}
scale={getIconScale(this.scale)}
Expand Down Expand Up @@ -1692,6 +1692,7 @@ export class Combobox
[CSS.selectionDisplayFit]: fitSelectionDisplay,
[CSS.selectionDisplaySingle]: singleSelectionDisplay,
}}
key="grid"
ref={this.setChipContainerEl}
>
{!singleSelectionMode && !singleSelectionDisplay && this.renderChips()}
Expand Down

0 comments on commit 6b8a439

Please sign in to comment.