From 78049ede35016de725575c7c967544f2f40636ae Mon Sep 17 00:00:00 2001 From: sushuang Date: Tue, 22 Aug 2017 07:12:46 +0800 Subject: [PATCH] tweak ie8 --- src/component/tooltip/TooltipView.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/component/tooltip/TooltipView.js b/src/component/tooltip/TooltipView.js index b075b1fbf..9c8786f09 100644 --- a/src/component/tooltip/TooltipView.js +++ b/src/component/tooltip/TooltipView.js @@ -741,7 +741,7 @@ define(function (require) { // Consider browser compatibility. // IE8 does not support getComputedStyle. - if (document.defaultView.getComputedStyle) { + if (document.defaultView && document.defaultView.getComputedStyle) { var stl = document.defaultView.getComputedStyle(el); if (stl) { width += parseInt(stl.paddingLeft, 10) + parseInt(stl.paddingRight, 10) -- GitLab