-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpaul.js
129 lines (106 loc) · 3.21 KB
/
paul.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
Cufon.replace('.dinot-font', {
hover: true,
fontFamily: 'DINOT-Regular'
});
Cufon.replace('.whitney-font', { fontFamily: 'Whitney Semibold' });
Cufon.replace('.whatup-quote', { fontFamily: 'Whitney Semibold' });
Cufon.replace('.home-link', { fontFamily: 'Whitney Semibold' });
Cufon.replace('h3', { fontFamily: 'Whitney Semibold' });
$(document).ready(function() {
$('.introtext').css('opacity','0.8');
$('.web-intro').css('opacity','0.8');
$('.px-intro').css('opacity','0.8');
$('.recentwork-item').hover(
function () {
$(this).find('.item-layover').css('background','transparent url(images/magni.png) no-repeat center center');
$(this).find('.item-image').css('opacity','0.8');
},
function () {
$(this).find('.item-layover').css('background','none');
$(this).find('.item-image').css('opacity','1');
}
);
$('.web-image').hover(
function () {
$(this).find('.web-item-layover').css('background','transparent url(images/magni.png) no-repeat center center');
$(this).find('.item-image').css('opacity','0.9');
},
function () {
$(this).find('.web-item-layover').css('background','none');
$(this).find('.item-image').css('opacity','1');
}
);
// Dropdown example for topbar nav
// ===============================
$("body").bind("click", function (e) {
$('a.menu').parent("li").removeClass("open");
});
$("a.menu").click(function (e) {
var $li = $(this).parent("li").toggleClass('open');
return false;
});
// colorbox
// ===============================
jQuery("a.lightbox").colorbox({
transition: 'fade',
rel: 'group1',
maxHeight: '92%'
});
$("a.flickrphoto").colorbox({maxHeight: '92%'});
$("a[rel='group1']").colorbox({rel:'group1'});
// photo filters + hover effect
$("#photographs .black").css('opacity','0.2');
$("#photographs a").hover(function () {
$(this).find('.black').css('display','block');
},
function() {
$(this).find('.black').css('display','none');
});
$("#photographs a").hoverIntent(function () {
$(this).append('<div class="caption">' + $(this).attr('alt') + '</div>');
},
function() {
$('.caption', this).remove();
});
$("#photographs .caption").hover(function () {
$('.caption', this).remove();
});
$("#filter a").click(function () {
$("#filter a").removeClass();
var cat = $(this).attr('ref');
if (cat == 'all') {
$("#photographs img").fadeTo('slow', '1');
} else {
$("#photographs a." + cat + "' img").fadeTo('slow', '1');
$("#photographs a:not('." + cat + "') img").fadeTo('slow', '0.1');
}
$(this).addClass('active');
});
if ($('body').hasClass('flickr-page')) {
$('html').addClass('flickr-page');
}
// Mail
// ===============================
$('a#email_me').click(function(){
document.location = 'mailto:[email protected]';
return false;
})
$('#main_carousel').cycle({
fx:'scrollHorz',
easing: 'easeInOutExpo',
speed: '800',
pause : true,
timeout : 6000,
next: '#next_s',
prev: '#prev_s',
pager: '#c_nav',
});
$('.recentwork-item .item-image').each(function(){
$(this).hover(function(){
// work work
})
})
});
function goToByScroll(id){
$('html,body').animate({scrollTop: $("#"+id).offset().top},'slow');
}