forked from cerc-io/snowballtools-base
🔧 chore: use proper type
This commit is contained in:
parent
3493d735b9
commit
4a87c100d6
@ -1,9 +1,8 @@
|
|||||||
import React, { ReactNode } from 'react';
|
import React, { ComponentPropsWithoutRef, ReactNode } from 'react';
|
||||||
import { cn } from 'utils/classnames';
|
import { cn } from 'utils/classnames';
|
||||||
|
|
||||||
interface IconWithFrameProps {
|
interface IconWithFrameProps extends ComponentPropsWithoutRef<'div'> {
|
||||||
icon: ReactNode;
|
icon: ReactNode;
|
||||||
className?: string;
|
|
||||||
hasHighlight?: boolean;
|
hasHighlight?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -11,6 +10,7 @@ export const IconWithFrame = ({
|
|||||||
icon,
|
icon,
|
||||||
className,
|
className,
|
||||||
hasHighlight = true,
|
hasHighlight = true,
|
||||||
|
...props
|
||||||
}: IconWithFrameProps) => {
|
}: IconWithFrameProps) => {
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
@ -21,6 +21,7 @@ export const IconWithFrame = ({
|
|||||||
'bg-controls-secondary',
|
'bg-controls-secondary',
|
||||||
className,
|
className,
|
||||||
)}
|
)}
|
||||||
|
{...props}
|
||||||
>
|
>
|
||||||
{hasHighlight && (
|
{hasHighlight && (
|
||||||
<div className="bottom-0 absolute w-[37px] h-px bg-gradient-to-r from-gray-0/0 via-gray-0/50 to-gray-0/0" />
|
<div className="bottom-0 absolute w-[37px] h-px bg-gradient-to-r from-gray-0/0 via-gray-0/50 to-gray-0/0" />
|
||||||
|
Loading…
Reference in New Issue
Block a user