set PropsWithChildren as explicit type on components
Signed-off-by: Oleg S <97077423+RobotSail@users.noreply.github.com>
This commit is contained in:
@@ -30,7 +30,7 @@ describe('<ApiDefinitionCard />', () => {
|
||||
const apiDocsConfig: jest.Mocked<ApiDocsConfig> = {
|
||||
getApiDefinitionWidget: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
@@ -24,7 +24,7 @@ describe('<ApiTypeTitle />', () => {
|
||||
const apiDocsConfig: jest.Mocked<ApiDocsConfig> = {
|
||||
getApiDefinitionWidget: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
@@ -39,7 +39,7 @@ describe('<ConsumedApisCard />', () => {
|
||||
getLocationByRef: jest.fn(),
|
||||
removeEntityByUid: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
@@ -39,7 +39,7 @@ describe('<HasApisCard />', () => {
|
||||
getLocationByRef: jest.fn(),
|
||||
removeEntityByUid: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
@@ -39,7 +39,7 @@ describe('<ProvidedApisCard />', () => {
|
||||
getLocationByRef: jest.fn(),
|
||||
removeEntityByUid: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
@@ -35,7 +35,7 @@ describe('<ConsumingComponentsCard />', () => {
|
||||
getLocationByRef: jest.fn(),
|
||||
removeEntityByUid: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
@@ -35,7 +35,7 @@ describe('<ProvidingComponentsCard />', () => {
|
||||
getLocationByRef: jest.fn(),
|
||||
removeEntityByUid: jest.fn(),
|
||||
} as any;
|
||||
let Wrapper: React.ComponentType;
|
||||
let Wrapper: React.ComponentType<React.PropsWithChildren<{}>>;
|
||||
|
||||
beforeEach(() => {
|
||||
Wrapper = ({ children }: { children?: React.ReactNode }) => (
|
||||
|
||||
Reference in New Issue
Block a user