intact-react
Advanced tools
Comparing version 3.0.27 to 3.0.28
@@ -6,2 +6,3 @@ declare type Fiber = any; | ||
export declare function preparePortalMount(dom: HTMLElement): void; | ||
export declare let connectFiber: boolean; | ||
export {}; |
@@ -124,2 +124,3 @@ 'use strict'; | ||
var IS_NON_DELEGATED = 2; | ||
var connectFiber = false; | ||
Function.prototype.bind = function () { | ||
@@ -162,2 +163,3 @@ var args = []; | ||
commentRoot.stateNode.containerInfo = targetContainer; | ||
connectFiber = true; | ||
} | ||
@@ -167,2 +169,3 @@ var ret = _fn_1(name, eventSystemFlags, targetContainer, nativeEvent); | ||
commentRoot.stateNode.containerInfo = containerInfo; | ||
connectFiber = false; | ||
} | ||
@@ -331,2 +334,14 @@ return ret; | ||
instance.$lastInput.dom = dom; | ||
/** | ||
* React find event props until the root fiber return null | ||
* If we have event props outeside the root container, it will be ignored. | ||
* So we must connect the fiber's return prop to outer element | ||
* @UnitTest: outer react element should receive event | ||
*/ | ||
var rootFiber = container._reactRootContainer._internalRoot.current; | ||
Object.defineProperty(rootFiber, 'return', { | ||
get: function () { | ||
return connectFiber && parentComponent ? parentComponent._reactInternals : null; | ||
} | ||
}); | ||
// console.log(rootContainer); | ||
@@ -333,0 +348,0 @@ // console.dir(container); |
@@ -117,2 +117,3 @@ 'use strict'; | ||
var IS_NON_DELEGATED = 2; | ||
var connectFiber = false; | ||
Function.prototype.bind = function () { | ||
@@ -155,2 +156,3 @@ var args = []; | ||
commentRoot.stateNode.containerInfo = targetContainer; | ||
connectFiber = true; | ||
} | ||
@@ -160,2 +162,3 @@ var ret = _fn_1(name, eventSystemFlags, targetContainer, nativeEvent); | ||
commentRoot.stateNode.containerInfo = containerInfo; | ||
connectFiber = false; | ||
} | ||
@@ -324,2 +327,14 @@ return ret; | ||
instance.$lastInput.dom = dom; | ||
/** | ||
* React find event props until the root fiber return null | ||
* If we have event props outeside the root container, it will be ignored. | ||
* So we must connect the fiber's return prop to outer element | ||
* @UnitTest: outer react element should receive event | ||
*/ | ||
var rootFiber = container._reactRootContainer._internalRoot.current; | ||
Object.defineProperty(rootFiber, 'return', { | ||
get: function () { | ||
return connectFiber && parentComponent ? parentComponent._reactInternals : null; | ||
} | ||
}); | ||
// console.log(rootContainer); | ||
@@ -326,0 +341,0 @@ // console.dir(container); |
@@ -121,2 +121,3 @@ import { __spreadArray, __assign, __extends } from 'tslib'; | ||
var IS_NON_DELEGATED = 2; | ||
var connectFiber = false; | ||
Function.prototype.bind = function () { | ||
@@ -159,2 +160,3 @@ var args = []; | ||
commentRoot.stateNode.containerInfo = targetContainer; | ||
connectFiber = true; | ||
} | ||
@@ -164,2 +166,3 @@ var ret = _fn_1(name, eventSystemFlags, targetContainer, nativeEvent); | ||
commentRoot.stateNode.containerInfo = containerInfo; | ||
connectFiber = false; | ||
} | ||
@@ -328,2 +331,14 @@ return ret; | ||
instance.$lastInput.dom = dom; | ||
/** | ||
* React find event props until the root fiber return null | ||
* If we have event props outeside the root container, it will be ignored. | ||
* So we must connect the fiber's return prop to outer element | ||
* @UnitTest: outer react element should receive event | ||
*/ | ||
var rootFiber = container._reactRootContainer._internalRoot.current; | ||
Object.defineProperty(rootFiber, 'return', { | ||
get: function () { | ||
return connectFiber && parentComponent ? parentComponent._reactInternals : null; | ||
} | ||
}); | ||
// console.log(rootContainer); | ||
@@ -330,0 +345,0 @@ // console.dir(container); |
@@ -6,2 +6,3 @@ declare type Fiber = any; | ||
export declare function preparePortalMount(dom: HTMLElement): void; | ||
export declare let connectFiber: boolean; | ||
export {}; |
{ | ||
"name": "intact-react", | ||
"version": "3.0.27", | ||
"version": "3.0.28", | ||
"description": "A compatibility layer for running intact component in React@17", | ||
@@ -32,6 +32,6 @@ "main": "index.js", | ||
"dependencies": { | ||
"intact": "^3.0.27", | ||
"intact-shared": "^3.0.27", | ||
"intact": "^3.0.28", | ||
"intact-shared": "^3.0.28", | ||
"tslib": "^2.3.1" | ||
} | ||
} |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
1050388
24766
Updatedintact@^3.0.28
Updatedintact-shared@^3.0.28