Wizard: Disable "Add all" button when there's an exact match
This disables the "Add all" button in the `DualListSelectorControl` on the Packages step when there's too many results to display, even if there's an exact match.
This commit is contained in:
parent
05b411c241
commit
c581903745
1 changed files with 6 additions and 1 deletions
|
|
@ -399,7 +399,12 @@ const Packages = ({ getAllPackages, isSuccess }) => {
|
|||
<AngleRightIcon />
|
||||
</DualListSelectorControl>
|
||||
<DualListSelectorControl
|
||||
isDisabled={availablePackagesDisplayList.length === 0}
|
||||
isDisabled={
|
||||
availablePackagesDisplayList.length === 0 ||
|
||||
// also disable the "Add all" button if there are too many matches
|
||||
// (even if there's an exact match)
|
||||
availablePackagesDisplayList.length >= 100
|
||||
}
|
||||
onClick={() => moveAllToChosen()}
|
||||
aria-label="Add all"
|
||||
tooltipContent="Add all"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue