Skip to content

Commit 74b6a95

Browse files
committed
chore: tweaks
1 parent 2011419 commit 74b6a95

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

packages/runtime-vapor/src/components/Teleport.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ export class TeleportFragment extends VaporFragment {
100100
})
101101

102102
const nodes = this.nodes
103-
// register updateCssVars to sub fragments's effects so that
104-
// updateCssVars will be called when subtree changed
103+
// register updateCssVars to root fragments's update hooks so that
104+
// it will be called when root fragment changed
105105
if (this.parentComponent && this.parentComponent.ut) {
106106
if (isFragment(nodes)) {
107107
;(nodes.updated || (nodes.updated = [])).push(() => updateCssVars(this))

packages/runtime-vapor/src/dom/prop.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -230,10 +230,9 @@ function setClassIncremental(el: any, value: any): void {
230230

231231
/**
232232
* dev only
233-
* if a component uses style v-bind, or an el's style contains style vars (potentially
234-
* fallthrough from parent components), then style matching checks must be deferred until
235-
* after hydration (when instance.block is set). At this point, it can be confirmed
236-
* whether the el is at the root level of the component.
233+
* defer style matching checks until hydration completes (instance.block is set) if
234+
* the component uses style v-bind or the element contains CSS variables, to correctly
235+
* verify if the element is the component root.
237236
*/
238237
function shouldDeferCheckStyleMismatch(el: TargetElement): boolean {
239238
return (

0 commit comments

Comments
 (0)