-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
201 lines (200 loc) · 7.1 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
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sno - Your Way</title>
<link rel="icon" type="image/x-icon" href="https://avatars.githubusercontent.com/u/149719209?s=200&v=4"/>
<link rel="stylesheet" href="https://guyotjs.github.io/bcss/bc.css">
<link rel="stylesheet" href="https://guyotjs.github.io/bcss/bc-colors.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.10.0/styles/default.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.10.0/highlight.min.js"></script>
<script>hljs.highlightAll();</script>
<style>
@import url('https://fonts.googleapis.com/css2?family=Karla:ital,wght@0,200..800;1,200..800&display=swap');
body{
margin:0;
padding:0;
overflow-x: hidden;
color:white;
}
.ehh{
color:lightgreen;
}
.f-xxl{
font-size: 80px;
}
b{
font-weight:600;
}
.blur{
backdrop-filter:blur(10px);
}
.f-respond{
font-size: 17px;
white-space: nowrap;
}
.fw-strong{
font-weight: 900;
}
.border-light{
border: 1px solid gray;
}
.border-right-light{
border-right: 1px solid gray;
}
.border-bottom-light{
border-bottom: 1px solid gray;
}
.plr-l{
padding-left: 32px;
padding-right: 32px;
}
.karla{
font-family: "Karla";
}
.dark-sky{
color:rgb(63, 144, 176);
}
.grad{
background-image: linear-gradient(to right, lightblue,rgb(230, 124, 230));
-webkit-background-clip: text;
background-clip: text;
-webkit-text-fill-color: transparent;
white-space: nowrap;
background-size: 200%;
}
.bg-grad{
background-image: linear-gradient(to right, blue,rgb(230, 124, 230));
background-color: rgba(255,255,255,0.7);
color:black;
background-blend-mode: lighten;
}
.w-full{
position: absolute;
left:0;
width: 93.5%;
}
#myCanvas{
position:fixed;
z-index:-1000;
top:0;
left:0;
width:100%;
height:100%;
}
</style>
</head>
<body data='{
count:0
}'>
<div class=" p-m">
<a href="https://snojs.github.io/tutorial" class="m-m sky">Docs</a>
<a href="https://github.com/snojs/">
<i class="fa-lg white fa m-m fa-github"></i>
</a>
</div>
<div class="text-center m-m">
<p class="f-xxl karla fw-strong bold"><span class="grad fw-strong karla">Sno.js</span></p><br/>
<p>Building the web <span class="grad karla fw-strong">{ your way }.</span></p>
</div><br/><br/>
<div class="text-center m-m" computer>
<div class="grid-2 left-center border-light r blur">
<div class="border-right-light">
<div class="plr-l f-respond p-m text-left karla">
<span class="gray">1|</span> <<b>body</b> data=<span class="ehh">'{count:0}'</span>><br/>
<span class="gray">2|</span>  <<b>p</b> react><span class="pumpkin">{{count}}</span></<b>p</b>><br/>
<span class="gray">3|</span>  <<b>button</b> onclick=<span class="ehh">'$("count++")'</span>>+</<b>button</b>><br/>
<span class="gray">4|</span>  <<b>script</b> src=<span class="calm">"./sno.js"</span>></<b>script</b>><br/>
<span class="gray">5|</span> </<b>body</b>><br/>
</div>
</div>
<div class="plr-l p-m" style="margin-top:15px;">
<p react>{{count}}</p>
<button class="p border-light gray bg-night r m" onclick='$("count++;")'>+</button>
</div>
</div>
</div>
<div class="text-center m-m" mobile>
<div class="left-center border-light r blur">
<div class="border-bottom-light">
<div class="plr-l f-respond p-m text-left karla">
<span class="gray">1|</span> <<b>body</b> data=<span class="ehh">'{count:0}'</span>><br/>
<span class="gray">2|</span>  <<b>p</b> react><span class="pumpkin">{{count}}</span></<b>p</b>><br/>
<span class="gray">3|</span>  <<b>button</b> onclick=<span class="ehh">'$("count++")'</span>>+</<b>button</b>><br/>
<span class="gray">4|</span>  <<b>script</b> src=<span class="calm">"./sno.js"</span>></<b>script</b>><br/>
<span class="gray">5|</span> </<b>body</b>><br/>
</div>
</div>
<div class="p">
<p react>{{count}}</p>
<button class="p border-light gray bg-night r m" onclick='$("count++;")'>+</button>
</div>
</div>
</div><span mobile><br/><br/><br/></span><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/>
<div class="text-center karla">
<p class="karla f-l">Add <span class="grad fw-strong">Sno</span> to Your Project...</p><br/>
All you need is <strong>One</strong> script tag <br/>
Download Locally <a href="https://snojs.github.io/snojs-beta/snoflake.js" download class="dark-sky">Here</a><br/>
Run from the link with a script tag<br/>
When supporting older versions use <br/><em><script src="https://snojs.github.io/sno/sno.js"></script></em><br/>
↓ Click to Copy ↓<br/>
<div class="p-m blur border-light r m-m" style="display:inline-block;" onclick="copy('<script src=\'https://snojs.github.io/sno/crystal.js\'></script>')">
<script src="https://snojs.github.io/sno/crystal.js"></script>
</div>
</div><br/><br/><br/>
<script>
function copy(id){
navigator.clipboard.writeText(id);
}
</script>
<script src="https://snojs.github.io/sno/crystal.js"></script>
<canvas id="myCanvas"></canvas>
<script src="https://classicmc-studios.github.io/js/moss.js"></script>
<script>
createCanvas(screen.width,screen.height);
bg("#242424");
//Snow_Particles
var angle = 0;
var W = screen.width+300;
var H = screen.height;
var mp = 50;//max particles
var particles = [];
for(var i = 0; i < mp; i++){
particles.push({
x: Math.random()*W,
y: Math.random()*H,
r: Math.random()*4+1,
d: Math.random()*mp
});
}
function update(){
angle += 0.01;
for(var i = 0; i < mp; i++){
var p = particles[i];
p.y += Math.cos(angle+p.d) + 1 + p.r/2;
p.x += -2;
if(p.x > W+5 || p.x < -5 || p.y > H){
if(i%3 > 0){particles[i] = {x: Math.random()*W, y: -10, r: p.r, d: p.d};}
else{
if(Math.sin(angle) > 0){particles[i] = {x: -5, y: Math.random()*H, r: p.r, d: p.d};}
else{particles[i] = {x: W+5, y: Math.random()*H, r: p.r, d: p.d};}
}
}
}
}
function draw(){
for(var i = 0; i < mp; i++){
noStroke();selectColor("#ffffff");var p = particles[i];ellipse(p.x,p.y,p.r);
}
update();
}
window.main = function(){
requestAnimationFrame( main )
bg("#242424");
draw();
};main();
</script>
</body>
</html>