catalog-react: Rename useEntityListProvider hook to useEntityList
Signed-off-by: Johan Haals <johan.haals@gmail.com>
This commit is contained in:
@@ -18,12 +18,12 @@ import {
|
||||
Progress,
|
||||
WarningPanel,
|
||||
} from '@backstage/core-components';
|
||||
import { useEntityListProvider } from '@backstage/plugin-catalog-react';
|
||||
import { useEntityList } from '@backstage/plugin-catalog-react';
|
||||
import React from 'react';
|
||||
import { DocsCardGrid } from './DocsCardGrid';
|
||||
|
||||
export const EntityListDocsGrid = () => {
|
||||
const { loading, error, entities } = useEntityListProvider();
|
||||
const { loading, error, entities } = useEntityList();
|
||||
|
||||
if (error) {
|
||||
return (
|
||||
|
||||
@@ -24,7 +24,7 @@ import {
|
||||
WarningPanel,
|
||||
} from '@backstage/core-components';
|
||||
import {
|
||||
useEntityListProvider,
|
||||
useEntityList,
|
||||
useStarredEntities,
|
||||
} from '@backstage/plugin-catalog-react';
|
||||
import { DocsTable } from './DocsTable';
|
||||
@@ -39,7 +39,7 @@ export const EntityListDocsTable = ({
|
||||
columns?: TableColumn<DocsTableRow>[];
|
||||
actions?: TableProps<DocsTableRow>['actions'];
|
||||
}) => {
|
||||
const { loading, error, entities, filters } = useEntityListProvider();
|
||||
const { loading, error, entities, filters } = useEntityList();
|
||||
const { isStarredEntity, toggleStarredEntity } = useStarredEntities();
|
||||
const [, copyToClipboard] = useCopyToClipboard();
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ import {
|
||||
CATALOG_FILTER_EXISTS,
|
||||
DefaultEntityFilters,
|
||||
EntityFilter,
|
||||
useEntityListProvider,
|
||||
useEntityList,
|
||||
} from '@backstage/plugin-catalog-react';
|
||||
|
||||
class TechDocsFilter implements EntityFilter {
|
||||
@@ -35,7 +35,7 @@ type CustomFilters = DefaultEntityFilters & {
|
||||
};
|
||||
|
||||
export const TechDocsPicker = () => {
|
||||
const { updateFilters } = useEntityListProvider<CustomFilters>();
|
||||
const { updateFilters } = useEntityList<CustomFilters>();
|
||||
|
||||
useEffect(() => {
|
||||
updateFilters({
|
||||
|
||||
Reference in New Issue
Block a user