Skip to content

Commit a4da2fc

Browse files
authored
Merge pull request #3530 from AnnMarieW/v4-update-tooltip
Make targetable tooltips interactive in v4
2 parents 9e5d7c5 + feab86a commit a4da2fc

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

components/dash-core-components/src/components/Tooltip.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ const Tooltip = ({
3131
height: `${position?.y1 - position?.y0}px`,
3232
display: `${show_tooltip ? 'inline-block' : 'none'}`,
3333
pointerEvents: `${targetable ? 'auto' : 'none'}`,
34+
'--Dash-Tooltip-PointerEvents': targetable ? 'auto' : 'none',
3435
'--Dash-Tooltip-Border-Color': border_color,
3536
'--Dash-Tooltip-Background-Color': background_color,
3637
'--Dash-Tooltip-ZIndex': zindex,

components/dash-core-components/src/components/css/tooltip.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
background: var(--Dash-Tooltip-Background-Color);
3333
white-space: nowrap;
3434
z-index: var(--Dash-Tooltip-ZIndex);
35-
pointer-events: none;
35+
pointer-events: var(--Dash-Tooltip-PointerEvents);
3636
box-shadow: 0px 10px 38px -10px var(--Dash-Shading-Strong),
3737
0px 10px 20px -15px var(--Dash-Shading-Weak);
3838
}

0 commit comments

Comments
 (0)