From 71de4463eabc59c5b3b73897c02c7a67d60f3cb8 Mon Sep 17 00:00:00 2001 From: 2betop <2betop.cn@gmail.com> Date: Tue, 31 Dec 2019 11:38:46 +0800 Subject: [PATCH] =?UTF-8?q?react-overlay=20=E8=BF=98=E4=BE=9D=E8=B5=96?= =?UTF-8?q?=E7=9A=84=E8=80=81=E7=89=88=E6=9C=AC=20dom-helpers=20=E6=89=80?= =?UTF-8?q?=E4=BB=A5=E4=B8=8D=E8=83=BD=E5=8D=87=E7=BA=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 3 ++- src/components/Collapse.tsx | 2 +- src/renderers/QuickEdit.tsx | 2 +- src/utils/dom.tsx | 10 +++++----- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/package.json b/package.json index c60efe4b..7c16fb6b 100644 --- a/package.json +++ b/package.json @@ -32,7 +32,7 @@ "autobind-decorator": "2.4.0", "blueimp-canvastoblob": "2.1.0", "classnames": "2.2.5", - "dom-helpers": "5.1.3", + "dom-helpers": "3.3.1", "downshift": "3.1.4", "echarts": "^4.1.0", "flv.js": "1.5.0", @@ -78,6 +78,7 @@ "devDependencies": { "@types/async": "^2.0.45", "@types/classnames": "^2.2.3", + "@types/dom-helpers": "^3.4.1", "@types/history": "^4.6.0", "@types/hoist-non-react-statics": "^3.0.1", "@types/jest": "^24.0.11", diff --git a/src/components/Collapse.tsx b/src/components/Collapse.tsx index a1694735..70fdaf53 100644 --- a/src/components/Collapse.tsx +++ b/src/components/Collapse.tsx @@ -5,7 +5,7 @@ */ import React from 'react'; -import css from 'dom-helpers/css'; +import css = require('dom-helpers/style/index'); import {ClassNamesFn, themeable} from '../theme'; import Transition, { EXITED, diff --git a/src/renderers/QuickEdit.tsx b/src/renderers/QuickEdit.tsx index da887f26..a2e98f5e 100644 --- a/src/renderers/QuickEdit.tsx +++ b/src/renderers/QuickEdit.tsx @@ -14,7 +14,7 @@ import hoistNonReactStatic = require('hoist-non-react-statics'); import onClickOutside from 'react-onclickoutside'; import {Action} from '../types'; import keycode from 'keycode'; -import matches from 'dom-helpers/matches'; +import matches = require('dom-helpers/query/matches'); import Overlay from '../components/Overlay'; import PopOver from '../components/PopOver'; diff --git a/src/utils/dom.tsx b/src/utils/dom.tsx index b8d58bec..7d8b9cc8 100644 --- a/src/utils/dom.tsx +++ b/src/utils/dom.tsx @@ -1,11 +1,11 @@ import React from 'react'; import ReactDOM from 'react-dom'; import hoistNonReactStatic = require('hoist-non-react-statics'); -import domOwnerDocument from 'dom-helpers/ownerDocument'; -import css from 'dom-helpers/css'; -import getOffset from 'dom-helpers/offset'; -import getPosition from 'dom-helpers/position'; -import getScrollTop from 'dom-helpers/scrollTop'; +import domOwnerDocument = require('dom-helpers/ownerDocument'); +import css = require('dom-helpers/style/index'); +import getOffset = require('dom-helpers/query/offset'); +import getPosition = require('dom-helpers/query/position'); +import getScrollTop = require('dom-helpers/query/scrollTop'); const bsMapping: { [propName: string]: string;