摘要:和和支持屬性。注釋以及更早版本的瀏覽器不支持屬性。定義和用法屬性規(guī)定過渡效果的速度曲線。在函數(shù)中定義自己的值。可能的值是至之間的數(shù)值。與上例相同,但通過來規(guī)定速度曲線
transition-timing-function: linear; -moz-transition-timing-function: linear; /* Firefox 4 */ -webkit-transition-timing-function: linear; /* Safari 和 Chrome */ -o-transition-timing-function: linear; /* Opera */ }Internet Explorer 10、Firefox、Opera 和 Chrome 支持 transition-timing-function 屬性。
Safari 支持替代的 -webkit-transition-timing-function 屬性。
注釋:Internet Explorer 9 以及更早版本的瀏覽器不支持 transition-timing-function 屬性。
定義和用法:transition-timing-function 屬性規(guī)定過渡效果的速度曲線。該屬性允許過渡效果隨著時間來改變其速度。?
transition-timing-function: linear|ease|ease-in|ease-out|ease-in-out|cubic- bezier(n,n,n,n);
#div1 {transition-timing-function: linear;} #div2 {transition-timing-function: ease;} #div3 {transition-timing-function: ease-in;} #div4 {transition-timing-function: ease-out;} #div5 {transition-timing-function: ease-in-out;} /* Firefox 4: */ #div1 {-moz-transition-timing-function: linear;} #div2 {-moz-transition-timing-function: ease;} #div3 {-moz-transition-timing-function: ease-in;} #div4 {-moz-transition-timing-function: ease-out;} #div5 {-moz-transition-timing-function: ease-in-out;} /* Safari and Chrome: */ #div1 {-webkit-transition-timing-function: linear;} #div2 {-webkit-transition-timing-function: ease;} #div3 {-webkit-transition-timing-function: ease-in;} #div4 {-webkit-transition-timing-function: ease-out;} #div5 {-webkit-transition-timing-function: ease-in-out;} /* Opera: */ #div1 {-o-transition-timing-function: linear;} #div2 {-o-transition-timing-function: ease;} #div3 {-o-transition-timing-function: ease-in;} #div4 {-o-transition-timing-function: ease-out;} #div5 {-o-transition-timing-function: ease-in-out;}
與上例相同,但通過 cubic-bezier 來規(guī)定速度曲線:
#div1 {transition-timing-function: cubic-bezier(0,0,1,1;} #div2 {transition-timing-function: cubic-bezier(0.25,0.1,0.25,1);} #div3 {transition-timing-function: cubic-bezier(0.42,0,1,1);} #div4 {transition-timing-function: cubic-bezier(0,0,0.58,1);} #div5 {transition-timing-function: cubic-bezier(0.42,0,0.58,1);} /* Firefox 4: */ #div1 {-moz-transition-timing-function: cubic-bezier(0,0,0.25,1);} #div2 {-moz-transition-timing-function: cubic-bezier(0.25,0.1,0.25,1);} #div3 {-moz-transition-timing-function: cubic-bezier(0.42,0,1,1);} #div4 {-moz-transition-timing-function: cubic-bezier(0,0,0.58,1);} #div5 {-moz-transition-timing-function: cubic-bezier(0.42,0,0.58,1);} /* Safari and Chrome: */ #div1 {-webkit-transition-timing-function: cubic-bezier(0,0,1,1;} #div2 {-webkit-transition-timing-function: cubic-bezier(0.25,0.1,0.25,1);} #div3 {-webkit-transition-timing-function: cubic-bezier(0.42,0,1,1);} #div4 {-webkit-transition-timing-function: cubic-bezier(0,0,0.58,1);} #div5 {-webkit-transition-timing-function: cubic-bezier(0.42,0,0.58,1);} /* Opera: */ #div1 {-o-transition-timing-function: cubic-bezier(0,0,1,1;} #div2 {-o-transition-timing-function: cubic-bezier(0.25,0.1,0.25,1);} #div3 {-o-transition-timing-function: cubic-bezier(0.42,0,1,1);} #div4 {-o-transition-timing-function: cubic-bezier(0,0,0.58,1);} #div5 {-o-transition-timing-function: cubic-bezier(0.42,0,0.58,1);}
文章版權(quán)歸作者所有,未經(jīng)允許請勿轉(zhuǎn)載,若此文章存在違規(guī)行為,您可以聯(lián)系管理員刪除。
轉(zhuǎn)載請注明本文地址:http://specialneedsforspecialkids.com/yun/799.html
摘要:支持替代的屬性。注釋以及更早版本的瀏覽器不支持屬性。定義和用法屬性規(guī)定過渡效果的速度曲線。默認(rèn)值繼承性版本語法語法值描述規(guī)定以相同速度開始至結(jié)束的過渡效果等于。可能的值是至之間的數(shù)值。以相同的速度從開始到結(jié)束的過渡效果: div { transition-timing-function: linear; -moz-transition-timing-function: linear; /*...
摘要:表示任何屬性都不應(yīng)用過渡,并且可以終止正在執(zhí)行的過渡。提供兩種計算曲線階梯函數(shù)三次貝茲曲線。在插入元素如或改變屬性后立即使用過渡元素將視為沒有開始狀態(tài),始終處于結(jié)束狀態(tài)。過渡取消不會觸發(fā)該事件。 一、概述 CSS屬性的值從一個值變成另一個值的過程叫做漸變,重點(diǎn)突出變化的過程。CSS3 transition系列屬性可控制這個變化過程,使得屬性值變化過程更加平滑。一個過渡應(yīng)包含這幾個屬性:...
摘要:一條正在繪制中的三次方貝塞爾曲線因為該曲線由四個點(diǎn)形成,我們將其稱為三次方貝塞爾曲線,而不是二次方曲線三個點(diǎn)或四次方曲線五個點(diǎn)。現(xiàn)在終于可以將貝塞爾曲線收入囊中了,也已經(jīng)對這 作者:Nicolas(滬江前端開發(fā)工程師)本文原創(chuàng)翻譯,轉(zhuǎn)載請注明作者及出處。 各位,趕緊綁住自己并緊緊抓牢了,因為當(dāng)你掌握了特別有趣但又復(fù)雜的CSS時序函數(shù)之后,你將會真正體驗到豎起頭發(fā)般的興奮感受。 好吧,本...
閱讀 2665·2021-11-11 16:54
閱讀 3657·2021-08-16 10:46
閱讀 3441·2019-08-30 14:18
閱讀 3034·2019-08-30 14:01
閱讀 2723·2019-08-29 14:15
閱讀 2007·2019-08-29 11:31
閱讀 3083·2019-08-29 11:05
閱讀 2583·2019-08-26 11:54