vue自帶的 transition name="slide-fade" 設置動畫


html:

<transition name="slide-fade"> 
      <div ref="treeWrap" class="orgBox" v-show="isShow" @mouseout="hideOrg" @mouseover="ShowOrgs">
          <elTree :lazy="propLazy"  :request="propTreeRequest" :node.sync="syncNode" @hideTree="hideTree"></elTree>
      </div>
    </transition>

 

css: 

vue自帶的 transition name="slide-fade"  設置動畫
.slide-fade-enter-active {
  transition: all .25s linear;
}
.slide-fade-leave-active {
  transition: all .25s linear;
}
.slide-fade-enter, .slide-fade-leave-to
/* .slide-fade-leave-active for below version 2.1.8 */ {
  transform: translateY(100px);
  opacity: 0;
}

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM