diff --git a/res/style.css b/res/style.css index 32616d45d35..5be3550884b 100644 --- a/res/style.css +++ b/res/style.css @@ -31,8 +31,6 @@ body { } #root { - /* Create a stacking context so that tooltips can be placed over the root element. */ - position: relative; z-index: 0; } diff --git a/src/content/components/TimelineCanvas.js b/src/content/components/TimelineCanvas.js index e9090a66474..3186f3f1524 100644 --- a/src/content/components/TimelineCanvas.js +++ b/src/content/components/TimelineCanvas.js @@ -13,7 +13,7 @@ type Props = { isDragging: boolean, getHoveredItemInfo: HoveredItem => React$Element<*>, drawCanvas: (CanvasRenderingContext2D, HoveredItem | null) => void, - onDoubleClickItem: HoveredItem => void, + onDoubleClickItem: (HoveredItem | null) => void, hitTest: (x: CssPixels, y: CssPixels) => HoveredItem | null, }; diff --git a/src/content/components/Tooltip.css b/src/content/components/Tooltip.css index 5dd1ecc8d14..f817c57490e 100644 --- a/src/content/components/Tooltip.css +++ b/src/content/components/Tooltip.css @@ -1,17 +1,11 @@ .tooltipMount { - /* Create a stacking context above the root container element. */ - position: absolute; - z-index: 1; - top: 0; - left: 0; - width: 100%; - height: 100%; - overflow: hidden; pointer-events: none; + /* Stack the tooltip mounting point above the root element. */ + z-index: 1; } .tooltip { - position: relative; + position: fixed; max-width: 100%; box-sizing: border-box; display: inline-block;