forked from uikit/uikit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
grid-parallax.html
129 lines (107 loc) · 5.05 KB
/
grid-parallax.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
<!DOCTYPE html>
<html lang="en-gb" dir="ltr">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Grid Parallax - UIkit tests</title>
<script src="js/test.js"></script>
<style type="text/css">
.uk-panel { height: 300px; }
:nth-child(5n-4) > .uk-panel { background: rgba(0,0,0,0.2); }
:nth-child(5n-3) > .uk-panel { background: rgba(0,0,0,0.3); }
:nth-child(5n-2) > .uk-panel { background: rgba(0,0,0,0.4); }
:nth-child(5n-1) > .uk-panel { background: rgba(0,0,0,0.5); }
:nth-child(5n) > .uk-panel { background: rgba(0,0,0,0.6); }
.test { background: rgba(0,0,0,0.05); }
</style>
</head>
<body>
<div class="uk-container">
<h1>Grid Parallax</h1>
<h2>3 Columns</h2>
<div class="test">
<div class="uk-child-width-1-3@m" uk-grid="parallax: 150">
<div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
</div>
<div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
</div>
<div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
<div class="uk-panel uk-grid-margin"></div>
</div>
</div>
</div>
<h2>Multi-row</h2>
<div class="test">
<div class="uk-child-width-1-2@ uk-child-width-1-3@m uk-child-width-1-3@l" uk-grid="parallax: 200">
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
<div><div class="uk-panel"></div></div>
</div>
</div>
<h2>JavaScript Options</h2>
<div class="uk-overflow-auto">
<table class="uk-table uk-table-striped">
<thead>
<tr>
<th>Option</th>
<th>Value</th>
<th>Default</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>margin</code></td>
<td>String</td>
<td>uk-grid-margin</td>
<td>This class is added to items that break into the next row, typically to create margin to the previous row.</td>
</tr>
<tr>
<td><code>first-column</code></td>
<td>String</td>
<td>uk-first-column</td>
<td>This class is added to the first element in each row.</td>
</tr>
<tr>
<td><code>masonry</code></td>
<td>Boolean</td>
<td>false</td>
<td>Enables masonry layout for this grid.</td>
</tr>
<tr>
<td><code>parallax</code></td>
<td>Number</td>
<td>0</td>
<td>Parallax translation value. The value must be a positive integer. Falsy disables the parallax effect (default).</td>
</tr>
</tbody>
</table>
</div>
</div>
</body>
</html>