/**
 * @file Event vendor
 * @author liangxiaojun(liangxiaojun@derbysoft.com)
 */

function addEvent(el, type, cb) {

    if (!el || !type) {
        return;
    }

    if (typeof window.addEventListener === 'function') {
        el.addEventListener(type, cb, false);
    } else if (typeof document.attachEvent === 'function') {
        el.attachEvent(`on${type}`, cb);
    } else {
        el[`on${type}`] = cb;
    }

}

function removeEvent(el, type, cb) {

    if (!el || !type) {
        return;
    }

    if (typeof window.removeEventListener === 'function') {
        el.removeEventListener(type, cb, false);
    } else if (typeof document.detachEvent === 'function') {
        el.detachEvent(`on${type}`, cb);
    } else {
        el[`on${type}`] = null;
    }

}

function triggerPopupEventHandle(el, triggerEl, popupEl, currentVisible) {

    let flag = true;

    while (el) {
        if (el == popupEl) {
            return currentVisible;
        } else if (el == triggerEl) {
            return !currentVisible;
        }
        el = el.parentNode;
    }

    if (flag) {
        return false;
    }

}

function preventContainerScroll(e) {

    const {currentTarget, deltaX, deltaY} = e,
        {
            clientWidth, scrollWidth, scrollLeft,
            clientHeight, scrollHeight, scrollTop
        } = currentTarget;

    if (
        (
            scrollWidth > clientWidth
            &&
            (
                (deltaX < 0 && scrollLeft <= 0)
                ||
                (deltaX > 0 && scrollLeft >= scrollWidth - clientWidth)
            )
        )
        ||
        (
            scrollHeight > clientHeight
            &&
            (
                (deltaY < 0 && scrollTop <= 0)
                ||
                (deltaY > 0 && scrollTop >= scrollHeight - clientHeight)
            )
        )
    ) {
        e.preventDefault();
    }

}

export default {
    addEvent,
    removeEvent,
    triggerPopupEventHandle,
    preventContainerScroll
};
@@ -1884,16 +1884,200 @@
   %7D%0A%0A%7D%0A%0A
+function wheelHandler(e) %7B%0A    const %7BshouldPreventContainerScroll, onWheel%7D = this.props;%0A    shouldPreventContainerScroll && preventContainerScroll(e);%0A    onWheel && onWheel(e);%0A%7D%0A%0A
 export d
@@ -2171,11 +2171,29 @@
 erScroll
+,%0A    wheelHandler
 %0A%7D;

update Event