Skip to content

Commit

Permalink
fixed unusual behaviour of dropdown
Browse files Browse the repository at this point in the history
  • Loading branch information
UdaySagar-Git committed Apr 6, 2024
1 parent 04247d4 commit e0f5758
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Components/Form/MultiSelectMenuV2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,8 @@ const MultiSelectMenuV2 = <T, V>(props: Props<T, V>) => {
<MultiSelectOptionChip
key={index}
label={option.selectedLabel}
onRemove={() => {
onRemove={(e) => {
e.stopPropagation();
const updatedOptions = selectedOptions.filter(
(selectedOption) =>
selectedOption.value !== option.value
Expand Down Expand Up @@ -177,7 +178,7 @@ export default MultiSelectMenuV2;

interface MultiSelectOptionChipProps {
label: ReactNode;
onRemove?: () => void;
onRemove?: (e: any) => void;
}

export const MultiSelectOptionChip = (props: MultiSelectOptionChipProps) => {
Expand Down

0 comments on commit e0f5758

Please sign in to comment.