aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrégoire Aubert <gregoire.aubert@sonarsource.com>2017-10-10 14:43:30 +0200
committerGrégoire Aubert <gregoire.aubert@sonarsource.com>2017-10-10 14:43:30 +0200
commit8398b6393575a65960ebdbb90cd290ba8a1ef52e (patch)
tree9fb2b42a691c0f6a41c0e20ce911a3600f8f6f26
parent105142f1bb12bfa651edffce48bf9fcd3279e981 (diff)
downloadsonarqube-8398b6393575a65960ebdbb90cd290ba8a1ef52e.tar.gz
sonarqube-8398b6393575a65960ebdbb90cd290ba8a1ef52e.zip
Fix sidebar position helper in IE
-rw-r--r--server/sonar-web/src/main/js/components/common/ScreenPositionHelper.tsx5
1 files changed, 4 insertions, 1 deletions
diff --git a/server/sonar-web/src/main/js/components/common/ScreenPositionHelper.tsx b/server/sonar-web/src/main/js/components/common/ScreenPositionHelper.tsx
index a3e9d99d0e2..5f7b2476f5b 100644
--- a/server/sonar-web/src/main/js/components/common/ScreenPositionHelper.tsx
+++ b/server/sonar-web/src/main/js/components/common/ScreenPositionHelper.tsx
@@ -48,7 +48,10 @@ export default class ScreenPositionHelper extends React.PureComponent<Props> {
if (!containerPos) {
return { top: 0, left: 0 };
}
- return { top: window.scrollY + containerPos.top, left: window.scrollX + containerPos.left };
+ return {
+ top: window.pageYOffset + containerPos.top,
+ left: window.pageXOffset + containerPos.left
+ };
};
render() {