catalog-react: Rename useEntityListProvider hook to useEntityList

Signed-off-by: Johan Haals <johan.haals@gmail.com>
This commit is contained in:
Johan Haals
2022-02-21 11:04:27 +01:00
parent 1482bb9349
commit b776ce5aab
21 changed files with 72 additions and 48 deletions
@@ -93,7 +93,7 @@ export type CustomFilters = DefaultEntityFilters & {
To control this filter, we can create a React component that shows checkboxes
for the security tiers. This component will make use of the
`useEntityListProvider` hook, which accepts this extended filter type as a
`useEntityList` hook, which accepts this extended filter type as a
[generic](https://www.typescriptlang.org/docs/handbook/2/generics.html)
parameter:
@@ -103,7 +103,7 @@ export const EntitySecurityTierPicker = () => {
const {
filters: { securityTiers },
updateFilters,
} = useEntityListProvider<CustomFilters>();
} = useEntityList<CustomFilters>();
// Toggles the value, depending on whether it's already selected
function onChange(value: string) {