Skip to content

Commit

Permalink
Revert back to button role=combobox
Browse files Browse the repository at this point in the history
  • Loading branch information
jandrade committed Nov 4, 2024
1 parent 45abd05 commit a0cbf60
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,7 @@ export default class MultiSelect extends React.Component<Props, State> {
disabled={isDisabled}
id={uniqueOpenerId}
aria-controls={dropdownId}
placeholder={noneSelected}
isPlaceholder={menuText === noneSelected}
light={light}
onOpenChanged={this.handleOpenChanged}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import caretDownIcon from "@phosphor-icons/core/bold/caret-down-bold.svg";
import {DROPDOWN_ITEM_HEIGHT} from "../util/constants";
import {OptionLabel} from "../util/types";

const StyledDiv = addStyle("div");
const StyledButton = addStyle("button");

type SelectOpenerProps = AriaProps & {
/**
Expand Down Expand Up @@ -161,7 +161,7 @@ export default class SelectOpener extends React.Component<
];

return (
<StyledDiv
<StyledButton
{...sharedProps}
aria-disabled={disabled}
aria-expanded={open ? "true" : "false"}
Expand All @@ -188,7 +188,7 @@ export default class SelectOpener extends React.Component<
style={styles.caret}
aria-hidden="true"
/>
</StyledDiv>
</StyledButton>
);
}
}
Expand Down

0 comments on commit a0cbf60

Please sign in to comment.