Prevent click propagation to tooltip anchor

This commit is contained in:
IRBorisov 2024-01-16 01:28:20 +03:00
parent d54f67ae92
commit 46d8d93c4b
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ interface ConstituentaTooltipProps {
function ConstituentaTooltip({ data, anchor }: ConstituentaTooltipProps) {
return (
<Tooltip clickable anchorSelect={anchor} className='max-w-[30rem]'>
<InfoConstituenta data={data} />
<InfoConstituenta data={data} onClick={event => event.stopPropagation()} />
</Tooltip>
);
}

View File

@ -18,7 +18,7 @@ function HelpButton({ topic, ...restProps }: HelpButtonProps) {
<div id={`help-${topic}`} className='p-1'>
<BiInfoCircle size='1.25rem' className='clr-text-primary' />
<Tooltip clickable anchorSelect={`#help-${topic}`} layer='z-modal-tooltip' {...restProps}>
<div className='relative'>
<div className='relative' onClick={event => event.stopPropagation()}>
<div className='absolute right-0 text-sm top-[0.4rem]'>
<TextURL text='Справка...' href={`/manuals?topic=${topic}`} />
</div>