set PropsWithChildren as explicit type on components
Signed-off-by: Oleg S <97077423+RobotSail@users.noreply.github.com>
This commit is contained in:
@@ -23,7 +23,7 @@ import {
|
||||
} from '@backstage/plugin-catalog-react';
|
||||
import { TestApiProvider, wrapInTestApp } from '@backstage/test-utils';
|
||||
import { Grid } from '@material-ui/core';
|
||||
import React, { ComponentType } from 'react';
|
||||
import React, { ComponentType, PropsWithChildren } from 'react';
|
||||
import { GroupProfileCard } from './GroupProfileCard';
|
||||
|
||||
const dummyDepartment = {
|
||||
@@ -74,7 +74,7 @@ export default {
|
||||
title: 'Plugins/Org/Group Profile Card',
|
||||
component: GroupProfileCard,
|
||||
decorators: [
|
||||
(Story: ComponentType<{}>) =>
|
||||
(Story: ComponentType<PropsWithChildren<{}>>) =>
|
||||
wrapInTestApp(
|
||||
<TestApiProvider apis={[[catalogApiRef, catalogApi]]}>
|
||||
<Story />
|
||||
|
||||
@@ -21,7 +21,7 @@ import {
|
||||
} from '@backstage/plugin-catalog-react';
|
||||
import { wrapInTestApp } from '@backstage/test-utils';
|
||||
import { Grid } from '@material-ui/core';
|
||||
import React, { ComponentType } from 'react';
|
||||
import React, { ComponentType, PropsWithChildren } from 'react';
|
||||
import { UserProfileCard } from './UserProfileCard';
|
||||
|
||||
const dummyGroup = {
|
||||
@@ -94,7 +94,7 @@ export default {
|
||||
title: 'Plugins/Org/User Profile Card',
|
||||
component: UserProfileCard,
|
||||
decorators: [
|
||||
(Story: ComponentType<{}>) =>
|
||||
(Story: ComponentType<PropsWithChildren<{}>>) =>
|
||||
wrapInTestApp(<Story />, {
|
||||
mountedRoutes: {
|
||||
'/a': entityRouteRef,
|
||||
|
||||
Reference in New Issue
Block a user