-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
162 lines (156 loc) · 7.27 KB
/
index.html
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
<!doctype html>
<html lang="en">
<head>
<!--
_ _____ _
\`,"" ,'7"r-..__/ \
,'\ `, ,',',' _/ \
/ \ 7 / / ( \ |
J \/ j L______\ / |
L __JF"""/""\"\_, /
L,-"| O| f O | L_ _/
F \_ / \__/ `- j|
.-' `""" ,' | _..====.._
\__/ r"_ A ,' _..---.._`,
`-.______,,-L// / \ ___,' ,'_..:::.. `,`,
j / / / 7" `-<""=:' '':. \ \
/ <,' / F . i , \ `, :T W I
| \,' / >X< | \ :| | L
| `._/ ' ! ` | I :| | G
\ \ / | :H T |
__>-.__ __,-\ | | S P |
/ /| | \ \ \_ | 'A R |
/ __/ | | L L \ K./ / L
/ | | 4 I I | E./ / ,'
J \ I L F I | // / _,'
_________| | F |J F | //_/-'
\ __ | / J |/ J | /="
\\ \_\ \__,' \ F | F |
\\\_____________\/ F__/ F
\\| HTML for |_____/ (______/
\/__Dummies___/
You can fork this page on github: https://github.com/pinkiepie-fun/pinkiepie.fun/
-->
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>Pinkie Pie Fun</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta property="og:site_name" content="Pinkie Pie Fun">
<meta property="og:url" content="https://pinkiepie.fun">
<meta property="og:title" content="Pinkie Pie Fun">
<meta property="og:image" content="http://pinkiepie.fun/img/pinkie_bounce_by_batmanbrony-d6rosgq.gif">
<meta property="og:image:secure_url" content="https://pinkiepie.fun/img/pinkie_bounce_by_batmanbrony-d6rosgq.gif">
<meta property="og:image:type" content="image/gif" />
<meta property="og:image" content="http://pinkiepie.fun/img/pinkie.png">
<meta property="og:image:secure_url" content="https://pinkiepie.fun/img/pinkie.png">
<meta property="og:image:type" content="image/png" />
<meta property="og:description" content="Sometimes you need a specific pink pony bouncing on your screen to cheer you up.">
<meta property="og:type" content="article">
<meta name="twitter:card" content="summary_large_image">
<link href="https://fonts.googleapis.com/css?family=Bangers&text=Loading." rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300" rel="stylesheet">
<link href="page.css" rel="stylesheet">
</head>
<body>
<div id="wrapper">
<!-- loader -->
<div class="batman-transition">
<div class="batman-transition-logo"></div>
<div class="batman-transition-text">Loading...</div>
</div>
<!-- JavaScript -->
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js" integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4=" crossorigin="anonymous"></script>
<script src="polyfill.js"></script>
<script src="pinkie.js"></script>
<script src="//cdn.ravenjs.com/3.18.1/raven.min.js" crossorigin="anonymous"></script>
<script>Raven.config('https://[email protected]/11').install()</script>
<script>
var pinkie = new Pinkie(); // And into her own reflection she stared, ...
pinkie.click_will_close = false; // people would be sad.
pinkie.append_to_selector = "#wrapper"; // so she jumps above our footer
pinkie.use_fixed_position = false; // use "position: absolute".
pinkie.beReady(false); // fun awaits.
</script>
<!-- background -->
<div id="bg">
<img src="img/simple_ponyville_background_by_dipi11-d5lyblg.svg" alt="Background image. If nobody ate it." data-id="0" style="z-index: 1">
</div>
<script>
$(function () {
$('.batman-transition').addClass("no-batman").remove();
});
function getImg$(i) {
return $("#bg").find("img[data-id='" + i + "']");
}
var backgrounds = [
'simple_ponyville_background_by_dipi11-d5lyblg.svg'
, 'mlp_fim_background2_by_scootaloooo-d4t0kzu.png'
, 'ponyville_background_1_by_scootaloooo-d4stsj3.png'
, 'background3_by_scootaloooo-d4t1xmp.png'
, 'bg1_by_mlp_vector_collabs-d50sedv.svg'
, 'bg10_1_by_mlp_vector_collabs-d5ortfn.svg'
, 'vector_ponyvilleoutskirts01_by_mlp_vector_collabs-d5t0fm1.svg'
, 'vector_background12_by_mlp_vector_collabs-d5u9iam.svg'
, 'mlp_fim___twilight__s_laboratory_by_sigmavirus1-d4w6r2w.png'
];
var loaded_backgrounds = [getImg$(0)];
var now = new Date();
if (now.getMonth() === 12) { // december
backgrounds.push('ponyville_dawn__snowy_by_stinkehund-d5ne9hb.png');
}
if (now.getHours() > 22 || now.getHours() < 4) { // night
backgrounds.push('orchard_sunset_by_mlp_vector_collabs-d5fp99h.svg');
backgrounds.push('lake_at_night_by_xpesifeindx-d5wwkwg.svg');
}
var current_to_load = 0, current_shown = 0;
function getImg(image) {
return "img/"+image;
}
function loadBackground() {
current_to_load++;
current_to_load %= backgrounds.length;
var current_img = getImg$(current_to_load);
if (!current_img.length) { // image doesn't exist
var new_img = $('<img alt="Background image. If nobody ate it." data-id="' + current_to_load + '">');
new_img.attr('src', getImg(backgrounds[current_to_load]));
new_img.on('load', function (e) {
self = $(this);
loaded_backgrounds.push(self);
console.log("img " + self.attr('data-id') + " loaded", loaded_backgrounds, self);
if (backgrounds.length > loaded_backgrounds.length) {
setTimeout(loadBackground, 1000);
}
});
new_img.css({"display": "none", "z-index": 1});
$('#bg').append(new_img);
console.log("img " + current_to_load + " added", new_img);
current_img = new_img;
}
}
function nextBackground() {
// determinate the images to display/hide
var loaded = loaded_backgrounds.length;
if (!loaded) {
// none are loaded yet, modulo would result in NaN :D
return;
}
var last_shown = current_shown;
current_shown = (current_shown + 1) % loaded;
// now display one of the loaded ones, and hide the previous.
// z-index: [pile, new, old]
loaded_backgrounds[last_shown].css('z-index', 3); // move on top, so when fading, the new one will be seen.
loaded_backgrounds[current_shown].css('z-index', 2).show(); // over the pile of images, below the old one.
loaded_backgrounds[last_shown].fadeOut(1000, function () {
$(this).css('z-index', 1); // move back into the pile
});
}
setInterval(Raven.wrap(nextBackground), 30000);
Raven.wrap(loadBackground)();
</script>
</div>
<div id="footer-push"></div>
<div id="footer">You can fork me on <a href="//github.com/pinkiepie-fun/pinkiepie.fun/">github</a>.</div>
<!-- Note: Littlepip is best pony. -->
</body>
</html>