-
Notifications
You must be signed in to change notification settings - Fork 0
/
fullScript3.php
268 lines (210 loc) · 6.57 KB
/
fullScript3.php
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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
<script>
$(document).ready(function() {
i=0;
$('#fullpage2').fullpage({
lockAnchors: true,
anchors: ['part1', '', '', '', '', ''],
sectionsColor: ['', '', ''],
navigation: false,
navigationPosition: 'right',
afterLoad: function(anchorLink2, index2){//addClass
if(index2==1){
$(".topBtn").hide()
var iframe = document.querySelector('iframe');
var player = new Vimeo.Player(iframe);
player.on('play', function() {
setTimeout(function() {
$('.visualTxt').fadeIn(3000);
$('#header').fadeIn(3000);
}, 5000);
});
}
if(index2==2){
index2Effect();
}
if(index2==3){
i++;
if(i==1){
$(".number").text('1,000,000,000')
$('.number').counterUp({
delay: 10,
time: 1990
});
//그래프 이동
var countOne = 0
function counterUp(){
$("#path").css("stroke-dasharray",countOne+",1395");
$("#numTest").text(countOne);
$(".cirWrap").show();
countOne=countOne+1.5;
countOne2= 40+countOne*0.05
if(countOne2<40) countOne2=40
if(countOne2 <= 80){
$(".cirWrap circle").attr("r",countOne2);
}else{
$(".cirWrap circle").attr("r",80);
}
if(countOne >= 940){
clearInterval(stop)
$(".txtCir p").delay(300).fadeIn();
$(".cirWrap text").delay(300).fadeIn();
$('.sec03 .lastLine2').css("transition","all .5s").css("height","77%");
}
}
var stop = setInterval(function(){
counterUp()
},1)
//그래프 이동
//$(".cirWrap").addClass("motion");
$(".cirWrap").attr('class',"cirWrap motion<?=$moTxt?> opacity");
gsap.config({
nullTargetWarn: false
});
gsap.registerPlugin(MotionPathPlugin);
gsap.to(".cirWrap", {
duration: 3,
ease: "linear",
motionPath: {
path: "#path",
align: "#path",
autoRotate: false,
alignOrigin: [0.5, 0.9],
start: 0,
end: 0.677
},
});
$('.firstShow').delay(5000).fadeOut(500)
$('.englishTxt').delay(5500).fadeIn(500).delay(1500).fadeOut(500)
$('.koreanTxt').delay(8000).fadeIn(500)
var stop2 = setTimeout(function() {
//$(".cirWrap").addClass("motion2");
$(".cirWrap").attr('class',"cirWrap motion2<?=$moTxt?> opacity");
gsap.to(".cirWrap", {
duration: 3,
ease: "linear",
motionPath: {
path: "#path",
align: "#path",
autoRotate: false,
alignOrigin: [0.5, 0.9],
start: 0.677,
end: 1
},
});
//그래프 이동
var countOne2 = 940
function counterUp(){
$("#path").css("stroke-dasharray",countOne2+",1395");
$("#numTest").text(countOne2);
countOne2=countOne2+0.7;
if(countOne2 >= 1395){
clearInterval(stop)
$(".txtCir p").fadeOut();
$(".cirWrap text").fadeOut();
$(".finish").delay(300).fadeIn();
$('.sec03 .lastLine').css("transition","all .5s").css("height","100%");
$('body').off('scroll touchmove mousewheel');
$(".topBtn").fadeIn()
}
}
//.sec03 .lastLine
var stop = setInterval(function(){
counterUp()
},1)
}, 10000);
}
}
if(index2==4){
index4Effect();
}
if(index2==5){
index5Effect();
}
},
onLeave: function(anchorLink2, index2){//removeClass
if(index2!=1){
$(".topBtn").fadeIn()
}
if(index2!=2){
stop2Effect();
}
if(index2!=3){
//$("#sec03").stop().load('./graph2.php?jQueryLoad=1');
}
if(index2!=4){
}
if(index2!=5 && index2!=6){
stop5Effect();
}
},
});
var footerSection = $('#footer');
$('.footerSection').html(footerSection);
$(document).on('click', '.topBtn', function () {
$.fn.fullpage.moveTo('part1', 1);
return false;
});
});
//////실행함수
//두번째 페이지
function index2Effect (){
$('.bigTxt').css({'transform':'scale(1)', 'transition':'0.8s ease-in-out'});
$('.bigTxt').stop().animate({'top':0},500,function(){
$('.secondTxt').stop().animate({'opacity':1,'transform':'scale(1)'},800,function(){
$('.thirdTxt').stop().animate({'opacity':1,'transform':'scale(1)'},800,function(){
$('.lineBar').stop().animate({'height':'491px'},1500);
$('.smalltxtBox p').stop().animate({'opacity':1},800);
});
});
});
}
//네번째 페이지
function index4Effect (){
var iconImg01 = new Vivus('bestIcon', {type: 'delayed', duration: 150, start: 'autostart', dashGap: 20, forceRender: false})
var iconImg02 = new Vivus('growthIcon', {type: 'delayed', duration: 150, start: 'autostart', dashGap: 20, forceRender: false})
var iconImg03 = new Vivus('challIcon', {type: 'delayed', duration: 150, start: 'autostart', dashGap: 20, forceRender: false})
var iconImg04 = new Vivus('posiIcon', {type: 'delayed', duration: 150, start: 'autostart', dashGap: 20, forceRender: false})
var iconImg05 = new Vivus('loveIcon', {type: 'delayed', duration: 150, start: 'autostart', dashGap: 20, forceRender: false})
}
//다섯번째 페이지
function index5Effect (){
$('.sec05subT').addClass('active');
//$('.sec05subT').css({'transform':'scale(1)', 'transition':'1s ease-in-out'});
$('.sec05 .lineBar').delay(800).animate({'height':'204px'},800,function(){
$('.barTxtBox').stop().animate({'opacity':1},1000,function(){
$('.contactBtn').stop().animate({'opacity':1},1000,function(){
$('.sec05Bot').addClass('active');
});
});
});
}
//////리셋함수
//두번째 페이지
function stop2Effect(){
// $('.bigTxt').stop();
$('.secondTxt').stop();
$('.thirdTxt').stop();
$('.lineBar').stop();
$('.smalltxtBox p').stop();
$('.bigTxt').css({'transform':'scale(3)'});
//$('.bigTxt').css({'top':'15%','font-size':'12rem','position':'absolute'});
//$('.bigTxt').css({'top':'15%','position':'absolute'});
$('.secondTxt').css({'opacity':0,'transform':'scale(1.1)'});
$('.thirdTxt').css({'opacity':0,'transform':'scale(1.1)'});
$('.lineBar').css({'height':0});
$('.smalltxtBox p').css({'opacity':0});
}
//다섯번째 페이지
function stop5Effect (){
//$('.sec05subT').css({'transform':'scale(3)'});
$('.sec05subT').removeClass('active');
$('.sec05subT').stop();
$('.sec05 .lineBar').stop();
$('.barTxtBox').stop();
$('.contactBtn').stop();
$('.sec05 .lineBar').css({'height':'0px'});
$('.barTxtBox').css({'opacity':0});
$('.contactBtn').css({'opacity':0});
$('.sec05Bot').removeClass('active');
}
</script>