大家好,我想知道如何使用@mouseenter和@mouseleave来控制下拉内容,而不是让它消失
<div class="wrapper"> <div class="link" @mouseenter="show = true" @mouseleave="show = false">项目</div> <div class="content" v-if="show">这是一个内容</div> </div>
我尝试了这样的方式,但当我想要悬停在内容上或与其交互时,我不知道如何处理,希望你们能帮助我。提前谢谢。
Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号