- Jul 16 Thu 2015 14:57
-
這是測試文章
- Jul 13 Mon 2015 11:30
-
GSAP Timeline Lite scroll 抖動
原因在於scroll時動畫不斷重新play,在progress加上.pause()即可解決:
$(window).on("scroll", function(){
var top = $(window).scrollTop();
var percentofprogress=(top+$(window).height())/($(document).height()-$(window).height());
//console.log(top);
//console.log(top/($doc.height()-$win.height()));
tl.progress(percentofprogress).pause();
} )
$(window).on("scroll", function(){
var top = $(window).scrollTop();
var percentofprogress=(top+$(window).height())/($(document).height()-$(window).height());
//console.log(top);
//console.log(top/($doc.height()-$win.height()));
tl.progress(percentofprogress).pause();
} )
- Jul 02 Thu 2015 17:39
-
CSS3 3D
設定3D視角
scss:
transform:perspective(100px); // 針對單一物件
perspective:100px;//針對父容器,子物件的相對應位置會依照視角變換角度
scss:
transform:perspective(100px); // 針對單一物件
perspective:100px;//針對父容器,子物件的相對應位置會依照視角變換角度
- May 09 Thu 2013 19:26
-
js 動態換圖
筆記一下( 5月lovelybox html )
var add = document.getElementById("big1");
var image = new Image();
image.onload=function(){
add.appendChild(image);
$(add).animate({opacity:0.5},0).animate({opacity:1},250);
}
var imgurlary = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t"];
function dfun() {
for(var i = 0;i < 20;i++) {
(function(i) {
$("#small" + String(i + 1)).mouseover(function() {
image.src="stylesheets/images/products_"+imgurlary[i]+".png";
}).mouseout(function(){add.removeChild(image)})
}
)(i)
}
}
dfun();
var add = document.getElementById("big1");
var image = new Image();
image.onload=function(){
add.appendChild(image);
$(add).animate({opacity:0.5},0).animate({opacity:1},250);
}
var imgurlary = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t"];
function dfun() {
for(var i = 0;i < 20;i++) {
(function(i) {
$("#small" + String(i + 1)).mouseover(function() {
image.src="stylesheets/images/products_"+imgurlary[i]+".png";
}).mouseout(function(){add.removeChild(image)})
}
)(i)
}
}
dfun();
- Feb 04 Mon 2013 11:35
-
這功能真方便
[Interview] Don't Break Search: Q&A with Google Lead Designer Jon Wiley
The design of the search page on Google.com is one of the most iconic in the Web's history, but it's in the midst of major changes. Google has redefined itself with Google+. Its notion of Web search as an index of pages has grown to include people, places and things. In addition to the search box, the page now has a share box . It takes great design to introduce all these new features and interactions to Google's hundreds of millions of users.
At the same time, smartphones and tablets are changing the way users interact with the Web, and Google has to make that leap along with them. It has to strike a delicate balance between simplicity, consistency and usefulness. Fortunately, Google's hundreds of millions of users provide mountains of data its designers can use to guide their decisions. I sat down with Jon Wiley , lead designer of Google Search since 2010, to learn more about how Google pushes its user experience forward.
- Aug 09 Thu 2012 23:40
-
flash object style
<object ... style="display:block;">...</object>
讓符合視窗的flash在IE上面不會有瀏覽器捲軸產生
讓符合視窗的flash在IE上面不會有瀏覽器捲軸產生
- Oct 31 Mon 2011 12:57
-
共同攜手˙戰勝乳癌 ˙點亮台灣
- Oct 25 Tue 2011 19:42
-
jQuery 寫法補充
jQuery("span.bqstart").css({
'float': "left",
'height': "45px",
'margin-top': "-20px",
'padding-top': "45px",
'margin-bottom':" -50px",
'font-size': "700%",
'color': "#FF0000",
});
屬性需加上單引號
屬性結尾值須拿掉[,],以防IE bug
'float': "left",
'height': "45px",
'margin-top': "-20px",
'padding-top': "45px",
'margin-bottom':" -50px",
'font-size': "700%",
'color': "#FF0000",
});
屬性需加上單引號
屬性結尾值須拿掉[,],以防IE bug
- Oct 25 Tue 2011 18:51
-
在AS3中撰寫javascript
在AS3中撰寫javascript(當然也可以用ExternalInterface.call呼叫HTML中的Javascript)
var temp:String ='javascript:$("#container3").animate({"top":"+=620px"},"slow");$("#extradiv1").height(620);void(0)';//void(0)必加,以防回傳javascript執行的結果
function openfun(e:Event):void {
gotoAndPlay("open");
e.target.removeEventListener(MouseEvent.ROLL_OUT,outfun);
e.target.removeEventListener(MouseEvent.ROLL_OVER,overfun);
//ExternalInterface.call("clickopen");
navigateToURL(new URLRequest(temp),"_self")//*以字串撰寫
};
var temp:String ='javascript:$("#container3").animate({"top":"+=620px"},"slow");$("#extradiv1").height(620);void(0)';//void(0)必加,以防回傳javascript執行的結果
function openfun(e:Event):void {
gotoAndPlay("open");
e.target.removeEventListener(MouseEvent.ROLL_OUT,outfun);
e.target.removeEventListener(MouseEvent.ROLL_OVER,overfun);
//ExternalInterface.call("clickopen");
navigateToURL(new URLRequest(temp),"_self")//*以字串撰寫
};

