|
@@ -308,12 +308,6 @@ export const TeleportImpl = {
|
|
|
target,
|
|
target,
|
|
|
props,
|
|
props,
|
|
|
} = vnode
|
|
} = vnode
|
|
|
-
|
|
|
|
|
- if (target) {
|
|
|
|
|
- hostRemove(targetStart!)
|
|
|
|
|
- hostRemove(targetAnchor!)
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
// an unmounted teleport should always unmount its children whether it's disabled or not
|
|
// an unmounted teleport should always unmount its children whether it's disabled or not
|
|
|
doRemove && hostRemove(anchor!)
|
|
doRemove && hostRemove(anchor!)
|
|
|
|
|
|
|
@@ -321,6 +315,11 @@ export const TeleportImpl = {
|
|
|
const disabled = isTeleportDisabled(props)
|
|
const disabled = isTeleportDisabled(props)
|
|
|
if (!disabled && !target) return
|
|
if (!disabled && !target) return
|
|
|
|
|
|
|
|
|
|
+ if (target) {
|
|
|
|
|
+ hostRemove(targetStart!)
|
|
|
|
|
+ hostRemove(targetAnchor!)
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
if (shapeFlag & ShapeFlags.ARRAY_CHILDREN) {
|
|
if (shapeFlag & ShapeFlags.ARRAY_CHILDREN) {
|
|
|
const shouldRemove = doRemove || !disabled
|
|
const shouldRemove = doRemove || !disabled
|
|
|
for (let i = 0; i < (children as VNode[]).length; i++) {
|
|
for (let i = 0; i < (children as VNode[]).length; i++) {
|