[Feature Request] Offer a way to disable selections on a Selection instance
Use case: I have a DetailList which is inside a component tree the user can "disable":
<ActivatableSection>
<DataProvider>
<DetailList />
</DataProvider>
</ActivatableSection>
The DataProvider component manages the Selection instance which is passed to DetailList.
If the section is disabled, I don't want to be able to change the selection of the List's items. Right now I check in the DataProvider during the onSelectionChange handler if the disabled prop is set and run a forceUpdate on the Provider to reassign the selected keys to their old value, but this isn't really clean.
Is it possible to add a function setDisabled or something like that to provide a clean way to disable selections?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions to Fabric React!
@Nimelrian - there is a selectionMode prop on the DetailsList and you can set it to SelectionMode.None. Using this may be a cleaner way to disable selection on the list conditionally.
Hopefully that answers your question. Closing due to no recent activity.