anu-verzum 2.2.6 → 2.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/reconciler.js +23 -26
- package/package.json +1 -1
package/dist/core/reconciler.js
CHANGED
|
@@ -416,35 +416,32 @@ const commitDeletion = (fiber, domParent) => {
|
|
|
416
416
|
}
|
|
417
417
|
node.stateNode.__fiber = null;
|
|
418
418
|
});
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
commitDeletion(node.child, node.stateNode);
|
|
428
|
-
}
|
|
429
|
-
while (node !== fiber && !node.sibling) {
|
|
430
|
-
node = node.parent;
|
|
431
|
-
}
|
|
432
|
-
if (node === fiber) {
|
|
433
|
-
return;
|
|
434
|
-
}
|
|
435
|
-
node = node.sibling;
|
|
436
|
-
continue;
|
|
437
|
-
}
|
|
438
|
-
if (domParent.contains(node.stateNode)) {
|
|
439
|
-
domParent.removeChild(node.stateNode);
|
|
419
|
+
removeFiberDom(fiber, domParent);
|
|
420
|
+
};
|
|
421
|
+
const removeFiberDom = (fiber, domParent) => {
|
|
422
|
+
if (fiber.tag === PORTAL) {
|
|
423
|
+
let child = fiber.child;
|
|
424
|
+
while (child) {
|
|
425
|
+
removeFiberDom(child, fiber.stateNode);
|
|
426
|
+
child = child.sibling;
|
|
440
427
|
}
|
|
441
|
-
|
|
442
|
-
|
|
428
|
+
return;
|
|
429
|
+
}
|
|
430
|
+
if (fiber.tag === HOST_COMPONENT) {
|
|
431
|
+
let child = fiber.child;
|
|
432
|
+
while (child) {
|
|
433
|
+
removeFiberDom(child, fiber.stateNode);
|
|
434
|
+
child = child.sibling;
|
|
443
435
|
}
|
|
444
|
-
if (
|
|
445
|
-
|
|
436
|
+
if (domParent.contains(fiber.stateNode)) {
|
|
437
|
+
domParent.removeChild(fiber.stateNode);
|
|
446
438
|
}
|
|
447
|
-
|
|
439
|
+
return;
|
|
440
|
+
}
|
|
441
|
+
let child = fiber.child;
|
|
442
|
+
while (child) {
|
|
443
|
+
removeFiberDom(child, domParent);
|
|
444
|
+
child = child.sibling;
|
|
448
445
|
}
|
|
449
446
|
};
|
|
450
447
|
const createRef = () => ({
|
package/package.json
CHANGED