1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

Fix type error

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton 2022-11-16 15:14:42 -05:00
parent c131766361
commit 2d87114f9e

View File

@ -164,7 +164,7 @@ interface Dependencies {
logger: Logger; logger: Logger;
} }
const RawIcon = withTooltip((props: IconProps & Dependencies) => { const RawIcon = (props: IconProps & Dependencies) => {
const ref = createRef<HTMLAnchorElement>(); const ref = createRef<HTMLAnchorElement>();
const { const {
@ -271,7 +271,7 @@ const RawIcon = withTooltip((props: IconProps & Dependencies) => {
} }
return <i {...iconProps} ref={ref} />; return <i {...iconProps} ref={ref} />;
}); };
const InjectedIcon = withInjectables<Dependencies, IconProps>(RawIcon, { const InjectedIcon = withInjectables<Dependencies, IconProps>(RawIcon, {
getProps: (di, props) => ({ getProps: (di, props) => ({
@ -280,4 +280,4 @@ const InjectedIcon = withInjectables<Dependencies, IconProps>(RawIcon, {
}), }),
}); });
export const Icon = Object.assign(InjectedIcon, { isSvg }); export const Icon = Object.assign(withTooltip(InjectedIcon), { isSvg });