-
Notifications
You must be signed in to change notification settings - Fork 102
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix imports form 'react-component-groups'
- Loading branch information
Showing
11 changed files
with
29 additions
and
32 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { Battery as BatteryPF } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
import BatteryPF, { BatteryProps } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated Battery import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const Battery: React.FunctionComponent<any> = BatteryPF; | ||
const Battery: React.FunctionComponent<BatteryProps> = BatteryPF; | ||
|
||
export default Battery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { CriticalBattery as CriticalBatteryPF } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
import Battery, { BatteryProps } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated CriticalBattery import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const CriticalBattery: React.FunctionComponent = CriticalBatteryPF; | ||
const CriticalBattery: React.FunctionComponent<BatteryProps> = (props) => <Battery {...props} severity="critical" />; | ||
|
||
export default CriticalBattery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { HighBattery as HighBatteryPF } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
import Battery, { BatteryProps } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated HighBattery import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const HighBattery: React.FunctionComponent = HighBatteryPF; | ||
const HighBattery: React.FunctionComponent<BatteryProps> = (props) => <Battery {...props} severity="high" />; | ||
|
||
export default HighBattery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { LowBattery as LowBatteryPF } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
import Battery, { BatteryProps } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated LowBattery import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const LowBattery: React.FunctionComponent = LowBatteryPF; | ||
const LowBattery: React.FunctionComponent<BatteryProps> = (props) => <Battery {...props} severity="low" />; | ||
|
||
export default LowBattery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { MediumBattery as MediumBatteryPF } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
import Battery, { BatteryProps } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated MediumBattery import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const MediumBattery: React.FunctionComponent = MediumBatteryPF; | ||
const MediumBattery: React.FunctionComponent<BatteryProps> = (props) => <Battery {...props} severity="medium" />; | ||
|
||
export default MediumBattery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { NullBattery as NullBatteryPF } from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
import Battery from '@patternfly/react-component-groups/dist/dynamic/Battery'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated NullBattery import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const NullBattery: React.FunctionComponent = NullBatteryPF; | ||
const NullBattery: React.FunctionComponent<any> = (props) => <Battery {...props} severity="null" />; | ||
|
||
export default NullBattery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,13 @@ | ||
import React from 'react'; | ||
import { ErrorBoundary as ErrorBoundaryPF } from '@patternfly/react-component-groups/dist/dynamic/ErrorBoundary'; | ||
import ErrorBoundaryPF, { ErrorPageProps } from '@patternfly/react-component-groups/dist/dynamic/ErrorBoundary'; | ||
import { DefaultErrorMessage } from '../ErrorState'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated ErrorBoundary import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const ErrorBoundary: React.FunctionComponent<any> = (props) => <ErrorBoundaryPF defaultErrorDescription={DefaultErrorMessage} {...props} />; | ||
const ErrorBoundary: React.FunctionComponent<ErrorPageProps> = (props) => ( | ||
<ErrorBoundaryPF defaultErrorDescription={<DefaultErrorMessage />} {...props} /> | ||
); | ||
|
||
export default ErrorBoundary; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
import React from 'react'; | ||
import { ErrorState as ErrorStatePF } from '@patternfly/react-component-groups/dist/dynamic/ErrorState'; | ||
import ErrorStatePF, { ErrorStateProps } from '@patternfly/react-component-groups/dist/dynamic/ErrorState'; | ||
import DefaultErrorMessage from './DefaultErrorMessage'; | ||
|
||
/** | ||
* @deprecated Do not use deprecated ErrorState import, the component has been moved to @patternfly/react-component-groups | ||
*/ | ||
const ErrorState: React.FunctionComponent = (props) => <ErrorStatePF defaultErrorDescription={<DefaultErrorMessage />} {...props} />; | ||
const ErrorState: React.FunctionComponent<ErrorStateProps> = (props) => <ErrorStatePF defaultErrorDescription={<DefaultErrorMessage />} {...props} />; | ||
|
||
export default ErrorState; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters