-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
440 lines (344 loc) · 11.7 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
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
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
<!doctype html>
<html lang="fr">
<head>
<title>Startpack</title>
<meta name="description" content="Description courte de la page" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Language" content="fr" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
<link href="./assets/css/style.css" rel="stylesheet" type="text/css" />
<link href="./assets/img/favicon.png" rel="shortcut icon" type="image/png" />
<script src="https://code.jquery.com/jquery-3.4.1.min.js" integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo=" crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.2.0/css/all.css" integrity="sha384-hWVjflwFxL6sNzntih27bfxkr27PmbbK/iSvJ+a4+0owXq79v+lsFkW54bOGbiDQ" crossorigin="anonymous">
<script type="text/javascript" src="./assets/js/prefunctions.js"></script>
</head>
<body>
<div id="wrapper">
<ul id="buttons_dl">
<li>
<a href="https://github.com/Zenike/startpack">
Download on <strong>GITHUB</strong>
</a>
</li>
</ul>
<h1 class="logo-header">
<img src="./assets/img/logo-startpack.svg" alt="">
</h1>
<!-- HEADER END ------------------------------------------------------------------------------->
<div class="sliker-example-title">
Fast scroll
</div>
<div class="sliker-example-text">
Jquery module that scroll the page vertically to a specifif target.
</div>
<section class="example-1">
<div id="example_fast_scroll">
<div data-stp-fastscroll-cmd="name_of_fast_scroll_action" class="btn">
Scroll to target "A" on click here
</div>
<div data-stp-fastscroll-target="name_of_fast_scroll_action" class="btn no_hover">
target "A" is here !
</div>
<div data-stp-fastscroll-cmd="name_of_fast_scroll_action2" class="btn">
Scroll to target "B" on click here
</div>
<div data-stp-fastscroll-exclusion="name_of_fast_scroll_action2" class="text">
Exclusion zone.<br>
Offset the scroll by the height of this !<br>
(Linked to "B" example)
</div>
<div data-stp-fastscroll-target="name_of_fast_scroll_action2" class="btn no_hover">
target "B" is here !
</div>
</div>
</section>
<blockquote>
- all the datas-... attributes of a same action must use the same unique name.<br />
- data-stp-fastscroll-exclusion allow you to offset the scroll by the height of a specific element.<br />
This element can be placed everywhere in the page, its height will offset the scroll even if the element isn't close to the target.
</blockquote>
<script>
createExampleBlockById(1);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Clear
</div>
<div class="sliker-example-text">
A simple "clear: both" class. Usefull to get a standard flow after some "float" elements
</div>
<section class="example-2">
<div id="example_clear">
<div class="block">float</div>
<div class="block">float</div>
<div class="block">float</div>
<span class="clear"></span>
<p class="text">
Classic text block after some float elements. The clear, juste before, repair the flow of the page.
</p>
</div>
</section>
<script>
createExampleBlockById(2);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Autoloader
</div>
<div class="sliker-example-text">
Jquery/Less module that display a waiting screen on top of the page when needed.
</div>
<section class="example-3">
<div id="example_autoloader">
<div class="btn start">
autoloader("start");
</div>
<div class="btn stop">
autoloader("stop");
</div>
</div>
<script>
$("#example_autoloader .start").click(function() {
autoloader("start");
});
$("#example_autoloader .stop").click(function() {
autoloader("stop");
});
</script>
</section>
<blockquote>
- No need to create an html structure, the module js will create it on click.<br>
- This require FontAwesome in the project (for the rotating)
</blockquote>
<script>
createExampleBlockById(3);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Autopopup
</div>
<div class="sliker-example-text">
Module that create popups dynamically. You write a single div tag with the good attributes and the html strucure will be created on initialization.
</div>
<section class="example-4">
<div id="example_autopopup">
<div class="autopopup r5 w600 m30" id="popup_example">
<p>
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
<br><br>
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
<br><br>
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</p>
</div>
<div class="btn" data-popup="popup_example">
Launch the popup
</div>
</div>
</section>
<blockquote>
All the numericals values represent pixels :<br>
- rounded edges : r5, r10, r15, ..., r45, r50<br>
- width : w100, w200, w300, ..., w900, w1000<br>
- internal margins : m5, m10, m15, ..., m45, m50
</blockquote>
<script>
createExampleBlockById(4);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Lift
</div>
<div class="sliker-example-text">
Jquery module that add a specific class to an element when the top of the window touch it.<br>
Mainly usefull to change an element from "static" to "fixed" when needed, but you can find other uses of it.
</div>
<section class="example-5">
<div id="example_lift">
<label class="btn" data-stp-lift-pusher>
<input type="checkbox"> Active a pusher element (data-stp-lift-pusher attribute).
This could be the height of a fixed navbar for example.
</label>
<div class="test-container" data-stp-lift-wrapper>
<div class="block-left" data-stp-lift>
.stp-lift-on
</div>
</div>
</div>
</section>
<blockquote>
- no css by defaut with this module. You have to specify our own css for the .stp-lift-on class.<br>
- you can use this in other ways that a simple fixed position : hide the block, show a popup when scroll pass a specific point, etc.
- the "pusher" (data-stp-lift-pusher) can use any type of tag (div, label, ...).
</blockquote>
<script>
createExampleBlockById(5);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Block Ratios
</div>
<div class="sliker-example-text">
Less module that allows you to create fixed ratio block (3/2, 16/9, 4/3, ...) to pu anything in it (pictures, iframes, ...)
</div>
<section class="example-6">
<div id="example_blocks_ratios">
<div class="block-3-2">
<div>
<div>
<em class="nbr">1</em>
<img src="./assets/img/examples/2.jpg">
</div>
</div>
</div>
<div class="block-3-2">
<div>
<em class="nbr">2</em>
<img src="./assets/img/examples/2.jpg">
</div>
</div>
<div class="block-square">
<div>
<div>
<em class="nbr">3</em>
<img src="./assets/img/examples/2.jpg">
</div>
</div>
</div>
<div class="block-square">
<div>
<div>
<em class="nbr">4</em>
<img src="./assets/img/examples/1.jpg">
</div>
</div>
</div>
<div class="my-custom-ratio">
<div>
<div>
<em class="nbr">5</em>
<img src="./assets/img/examples/1.jpg">
</div>
</div>
</div>
</div>
</section>
<blockquote>
1) Classical structure (block-x-x>div>div>img) : the picture size is defined by a max-width and max-height at 100%.<br />
2) Fast structure block-x-x>div>img : the picture will take 100% of the width.<br />
3) Other example with another ratio.<br />
4) Same example but with an horizontal picture, no vertical centering with this module<br />
5) custom ratio : you have to use a less mixin in your own css : .block-ratio(@width,@height), targeting .my-custom-ratio (you can use any class name);
</blockquote>
<script>
createExampleBlockById(6);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Navbar to mobile
</div>
<div class="sliker-example-text">
Classic navbar mobile that switch classes an dynamically manages a black background.
</div>
<section class="example-7">
<div class="mobi_lemenu_button" data-stp-menu-open="navbar">
<i class="fas fa-bars"></i>
</div>
<nav class="header_navbar_example" data-stp-menu="navbar">
<div class="cross" data-stp-menu-close>
<i class="fas fa-times"></i>
</div>
<ul>
<li cass="selected">
<a href="">
Accueil
</a>
</li>
<li>
<a href="">
Comment ça marche?
</a>
</li>
<li>
<a href="">
FAQ
</a>
</li>
<li>
<a href="">
Tombola
</a>
</li>
<li>
<a href="">
Contact
</a>
</li>
<li>
<a href="">
Inscription
</a>
</li>
<li>
<a href="">
Connexion
</a>
</li>
</ul>
</nav>
</section>
<blockquote>
1) Add a "data-stp-menu-open" attribute on a button and specify the name of the targeted menu<br />
2) Add a "data-stp-menu" attribute on the menu itself to name it<br />
3) Use the "stp-menu-open" class to show/animate the menu (no css by defaut)<br />
4) Set an element with a "data-stp-menu-close" attribute in the menu to close it on click<br />
</blockquote>
<script>
createExampleBlockById(7);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Placeholder mixins
</div>
<div class="sliker-example-text">
Less mixin that changes the color of placeholder
</div>
<section class="example-8" id="example-placeholder">
<input type="text" placeholder="I am a placeholder">
<style>
input {
.placeholder(red);
}
</style>
</section>
<blockquote>
- Only one argument available : a color (text or hex).
</blockquote>
<script>
createExampleBlockById(8);
</script>
<!--------------------------------------------------------------------------------->
<div class="sliker-example-title">
Parallax
</div>
<div class="sliker-example-text">
JS module that creates a parallax effect by manipulating the "background-position" property.
</div>
<section class="example-9" id="example-parallax">
<div class="big-banner" data-stp-parallax style="background-image: url(./assets/img/examples/1.jpg);">
<!-- banner content -->
</div>
</section>
<blockquote>
- Only "background-position" is manipulated, you have to use other background attributes, like "background-size", by your own.<br>
- "background-position" is fixed horizontaly to 50% by the JS.
</blockquote>
<script>
createExampleBlockById(9);
</script>
<!--------------------------------------------------------------------------------->
</div><!-- \wrapper -->
<script type="text/javascript" src="./startpack.js"></script>
<script type="text/javascript" src="./assets/js/postfunctions.js"></script>
</body>
</html>