Skip to content

CSS v-bind doesn't work in all cases with Teleport #12176

@matej-svejda

Description

@matej-svejda

Vue version

3.5.12

Link to minimal reproduction

https://play.vuejs.org/#eNqdVMtu2zAQ/BWCF9tALEdJe3FlA22QQwr0gcZHAoUsrS0mFEmQlOLA8L93ST38qOsGuZE7o+XscKgt/ax1VFdApzSxmeHaEQuu0nMmeamVcWRLDKzIjqyMKskAqYNPPXanSt0C0cRvfKsDfEuU/KYq6SA/7cBkpqR1pGzhmT9muEqFhRGT/WfD4YjM5h0rqlNRAXKdqTwtmTSaUS1uHJRapA5wR0iS8zosmiXJRGrtjFEHAry2sUvNGtw4ZnSeTN5IvjklBwPqMV8hudXIKJk0ClpiMjkQRq+oszj5iq+jJ6sk+r71ZEYzbMUFmB/acXSG0SkJiMdSIdTL11Dzk1919ayA7PlM/clufI3RnwYsmBoY7bFmlAa+f/wOG1z3YKnySiD7AvgLrBKV19jQvlQyR9kHvKD2ISSAy/XC3m8cSNsN5YV65i7wGcU8eBf/Nfpe7m30IXzH5A5d7NL2/uDGR8mNu+g2sVym2fPa4I3md0oo08Zz8Ap+tsGl6PXBC+GIz8XKulcB+RhLmKdFwS2xhapETpZAmhP2IUsadc160eaROIVtonNZftNxD49nzumah8ieiS5uQyeC+dWQYyXad+4ubKlMDmZKYr0hmBOOMwm0En316AvPXYHg9bXetKUC+Lpwx7W9+ePMuz/FJ7bkMh+e3MoI+RgHvAqvY96mItzkX7G49Kv4j63+1be2WqFc/7yPDDt+479rMD7xKOM2+hjFN3T3B0Cn0sY=

Steps to reproduce

v-bind with styles works correctly with Teleport if the Teleport is directly in the component. If the Teleport is nested (i.e. a child component uses Teleport in combination with a slot), v-bind doesn't work anymore.

To reproduce that in the example simply open it.

What is expected?

Both squares should have a yellow background.

What is actually happening?

Only the square using Teleport directly has a yellow background.

System Info

No response

Any additional comments?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions