mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-19 04:19:25 +00:00
feat: enhance activity completion handling and tooltip functionality
This commit is contained in:
parent
bbe6f9e2c5
commit
ca12e799df
4 changed files with 121 additions and 20 deletions
|
|
@ -9,6 +9,7 @@ type TooltipProps = {
|
|||
children: React.ReactNode
|
||||
side?: 'top' | 'right' | 'bottom' | 'left' // default is bottom
|
||||
slateBlack?: boolean
|
||||
unstyled?: boolean // new prop to remove default styling
|
||||
}
|
||||
|
||||
const ToolTip = (props: TooltipProps) => {
|
||||
|
|
@ -19,6 +20,7 @@ const ToolTip = (props: TooltipProps) => {
|
|||
<Tooltip.Portal>
|
||||
<TooltipContent
|
||||
slateBlack={props.slateBlack}
|
||||
unstyled={props.unstyled}
|
||||
side={props.side ? props.side : 'bottom'}
|
||||
sideOffset={props.sideOffset}
|
||||
>
|
||||
|
|
@ -63,6 +65,17 @@ const TooltipContent = styled(Tooltip.Content, {
|
|||
color: 'white',
|
||||
},
|
||||
},
|
||||
unstyled: {
|
||||
true: {
|
||||
padding: 0,
|
||||
backgroundColor: 'transparent',
|
||||
boxShadow: 'none',
|
||||
borderRadius: 0,
|
||||
fontSize: 'inherit',
|
||||
lineHeight: 'inherit',
|
||||
color: 'inherit',
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
borderRadius: 4,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue