1

I have a scenario where a user can select a name from a dropdown list which will then prefill their details. They may need to add details for multiple people. So, if there are 2 people. I select a name for drop down 1, the idea would be for drop down 2 that the name selected for drop down 1 would not be available or would show as disabled in drop down 2?

I've not seen disabled options within a drop down list? Is this an established pattern?

Thanks for your help

2
  • FWIW: There exists the multiple attribute in HTML <select> elements, which technically allows you to select 2 items from a single "dropdown". See MDN for more. That said: While that is a standard which some people will know about, I have some doubts it's the intuitive solution to your problem that's appropriate to the current day and age. Commented Jan 5 at 14:57
  • Disabled is a valid attribute for option elements (source), but personally I would remove the unavailable item from the list.
    – jazZRo
    Commented Jan 5 at 16:09

2 Answers 2

0

Selecting an option in a drop-down can affect the options in the second drop-down. Or you can say, options in the drop-down 2 will be populated based on the input selected in the drop-down 1. This is a common scenario and you do not need to show any disabled options.

I will not recommend disabling the options, as it will confuse the user as he might think why this option is disabled and when will it become enabled.

0

As @LeoWattenberg said, a dropdown that lets you select multiple would be a good solution except it isn't always clear that you can select multiple. So lets make it clear:

See this SO answer for a dropdown with checkboxes: Dropdown Checklist

Checkboxes are very well associated with multi-select so the clarity shouldn't be an issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.