File tree Expand file tree Collapse file tree 3 files changed +10
-3
lines changed
packages-private/vapor-e2e-test/interop Expand file tree Collapse file tree 3 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,8 @@ const slotProp = ref('slot prop')
27
27
change slot prop
28
28
</button >
29
29
<div class =" vdom-slot-in-vapor-default" >
30
- #default: <slot :foo =" slotProp" />
30
+ #default:
31
+ <slot :foo =" slotProp" />
31
32
</div >
32
33
<div class =" vdom-slot-in-vapor-test" >
33
34
#test: <slot name =" test" >fallback content</slot >
@@ -40,7 +41,7 @@ const slotProp = ref('slot prop')
40
41
>
41
42
Toggle default slot to vdom
42
43
</button >
43
- <VdomComp :msg =" msg" >
44
+ <VdomComp :msg =" msg" class = " foo " >
44
45
<template #default =" { foo } " v-if =" passSlot " >
45
46
<div >slot prop: {{ foo }}</div >
46
47
<div >component prop: {{ msg }}</div >
Original file line number Diff line number Diff line change @@ -666,7 +666,12 @@ export function guardReactiveProps(
666
666
props : ( Data & VNodeProps ) | null ,
667
667
) : ( Data & VNodeProps ) | null {
668
668
if ( ! props ) return null
669
- return isProxy ( props ) || isInternalObject ( props ) ? extend ( { } , props ) : props
669
+ return isProxy ( props ) ||
670
+ isInternalObject ( props ) ||
671
+ // handling for vapor props
672
+ props . __vapor
673
+ ? extend ( { } , props )
674
+ : props
670
675
}
671
676
672
677
export function cloneVNode < T , U > (
Original file line number Diff line number Diff line change @@ -172,6 +172,7 @@ export function getPropsProxyHandlers(
172
172
173
173
export function getAttrFromRawProps ( rawProps : RawProps , key : string ) : unknown {
174
174
if ( key === '$' ) return
175
+ if ( key === '__vapor' ) return true
175
176
// need special merging behavior for class & style
176
177
const merged = key === 'class' || key === 'style' ? ( [ ] as any [ ] ) : undefined
177
178
const dynamicSources = rawProps . $
You can’t perform that action at this time.
0 commit comments