Skip to content

Commit 1ba07e0

Browse files
authored
Merge pull request #43 from bprusinowski/feat/append-tooltip-to-body
feat: Append Tooltip to body
2 parents 77bc893 + c4f721e commit 1ba07e0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/components/Tooltip.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@ import { select } from "d3-selection";
33
export type Tooltip = ReturnType<typeof makeTooltip>;
44

55
export const makeTooltip = (div: HTMLDivElement) => {
6-
const root = select(div)
7-
.selectAll(".tooltip")
6+
const root = select(document.body)
7+
.selectAll(".plotteus-tooltip")
88
.data([null])
99
.join("div")
10-
.attr("class", "tooltip")
10+
.attr("class", "plotteus-tooltip")
11+
.style("z-index", "999999")
1112
.style("position", "fixed")
1213
.style("top", 0)
1314
.style("left", 0)

0 commit comments

Comments
 (0)