Transition 所支持的css屬性

transition-property是用來指定當元素其中一個屬性改變時執行transition效果: 所支持的屬性類型以下:css

  1. color: 經過紅、綠、藍和透明度組件變換(每一個數值處理)如:background-color,border-color,color,outline-color等css屬性;
  2. length: 真實的數字 如:word-spacing,width,vertical-align,top,right,bottom,left,padding,outline-width,margin,min-width,min-height,max-width,max-height,line-height,height,border-width,border-spacing,background-position等屬性;
  3. percentage:真實的數字 如:word-spacing,width,vertical-align,top,right,bottom,left,padding,outline-width,margin,min-width,min-height,max-width,max-height,line-height,height,border-width,border-spacing,background-position等屬性;
  4. integer離散步驟(整個數字),在真實的數字空間,以及使用floor()轉換爲整數時發生 如:outline-offset,z-index等屬性;
  5. number真實的(浮點型)數值,如:zoom,opacity,font-weight,等屬性;
  6. transform list
  7. rectangle:經過x, y, width 和 height(轉爲數值)變換,如:crop
  8. visibility: 離散步驟,在0到1數字範圍以內,0表示「隱藏」,1表示徹底「顯示」,如:visibility
  9. shadow: 做用於color, x, y 和 blur(模糊)屬性,如:text-shadow
  10. gradient: 經過每次中止時的位置和顏色進行變化。它們必須有相同的類型(放射狀的或是線性的)和相同的中止數值以便執行動畫,如:background-image
  11. paint server (SVG): 只支持下面的狀況:從gradientgradient以及colorcolor,而後工做與上面相似
  12. space-separated list of above:若是列表有相同的項目數值,則列表每一項按照上面的規則進行變化,不然無變化
  13. a shorthand property: 若是縮寫的全部部分均可以實現動畫,則會像全部單個屬性變化同樣變化
相關文章
相關標籤/搜索