abeea commited on
Commit
0a507cd
·
verified ·
1 Parent(s): eff0a93

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +155 -37
index.html CHANGED
@@ -6,11 +6,18 @@
6
  <title>Spin & Load Wheel</title>
7
 
8
  <style>
 
 
 
 
 
 
 
9
  body {
10
  margin: 0;
11
  font-family: Arial, sans-serif;
12
- background: #111;
13
- color: #fff;
14
  height: 100vh;
15
  display: flex;
16
  justify-content: center;
@@ -21,6 +28,7 @@
21
  .container {
22
  width: 90%;
23
  max-width: 400px;
 
24
  }
25
 
26
  .info {
@@ -28,17 +36,20 @@
28
  font-size: 16px;
29
  line-height: 22px;
30
  opacity: 0.9;
 
31
  }
32
 
 
33
  .wheel {
34
  width: 300px;
35
  height: 300px;
36
  border-radius: 50%;
37
- border: 10px solid #fff;
38
  position: relative;
39
  overflow: hidden;
40
- transition: transform 2.2s cubic-bezier(.12,.66,.11,1.23); /* Faster spin */
41
  margin: auto;
 
42
  }
43
 
44
  .slice {
@@ -52,35 +63,90 @@
52
  display: flex;
53
  justify-content: center;
54
  align-items: center;
55
- font-size: 14px;
56
  font-weight: bold;
57
- border: 1px solid #222;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
58
  }
59
 
60
- .slice:nth-child(1) { background: #FF5722; transform: rotate(0deg) skewY(-54deg); }
61
- .slice:nth-child(2) { background: #FFC107; transform: rotate(72deg) skewY(-54deg); }
62
- .slice:nth-child(3) { background: #03A9F4; transform: rotate(144deg) skewY(-54deg); }
63
- .slice:nth-child(4) { background: #8BC34A; transform: rotate(216deg) skewY(-54deg); }
64
- .slice:nth-child(5) { background: #9C27B0; transform: rotate(288deg) skewY(-54deg); }
65
 
66
  .pointer {
67
  width: 0; height: 0;
68
- border-left: 20px solid transparent;
69
- border-right: 20px solid transparent;
70
- border-bottom: 35px solid yellow;
71
  margin: auto;
72
- margin-bottom: 10px;
 
73
  }
74
 
75
  button {
76
  margin-top: 25px;
77
  font-size: 20px;
78
  padding: 12px 25px;
79
- background: #4caf50;
80
  border: none;
81
  border-radius: 8px;
82
  color: white;
83
  cursor: pointer;
 
84
  }
85
  button:disabled {
86
  background: #333;
@@ -91,7 +157,27 @@
91
  margin-top: 20px;
92
  font-size: 18px;
93
  display: none;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
94
  }
 
95
  </style>
96
  </head>
97
 
@@ -101,30 +187,47 @@
101
 
102
  <p class="info">
103
  ⚡ For load balancing we add this to handle high traffic.<br>
104
- Just click on SPIN to unlock the main site!
105
  </p>
106
 
107
  <div class="pointer"></div>
108
  <div class="wheel" id="wheel">
109
- <div class="slice">love.com</div>
110
- <div class="slice">love1.com</div>
111
- <div class="slice">love2.com</div>
112
- <div class="slice">love3.com</div>
113
- <div class="slice">love4.com</div>
 
 
 
 
 
 
 
114
  </div>
 
 
 
 
115
 
116
- <button id="btn" onclick="spinWheel()">SPIN</button>
117
- <p id="message"></p>
118
 
119
  </div>
120
 
121
  <script>
 
 
122
  const sites = [
123
- "https://www.love.com",
124
- "https://www.love1.com",
125
- "https://www.love2.com",
126
- "https://www.love3.com",
127
- "https://www.love4.com"
 
 
 
 
 
128
  ];
129
 
130
  let spinning = false;
@@ -135,27 +238,42 @@ function spinWheel() {
135
 
136
  const wheel = document.getElementById("wheel");
137
  const message = document.getElementById("message");
138
- const btn = document.getElementById("btn");
139
 
140
- btn.disabled = true;
 
 
141
 
142
  const index = Math.floor(Math.random() * sites.length);
 
 
143
 
144
- /* More rotations but faster */
145
- const degrees = 360 * 10 + (360 - index * 72) - 36;
 
 
 
 
146
  wheel.style.transform = `rotate(${degrees}deg)`;
147
 
148
  message.style.display = "block";
149
  message.textContent = "🎡 Fast spinning…";
150
 
151
- /* Quicker redirect */
152
  setTimeout(() => {
153
  const selected = sites[index];
154
  message.textContent = "Redirecting to " + selected;
155
- window.location.href = selected;
156
- }, 2500); // Just 2.5s total
 
 
 
 
 
 
 
157
  }
158
  </script>
159
 
160
  </body>
161
- </html>
 
6
  <title>Spin & Load Wheel</title>
7
 
8
  <style>
9
+ :root {
10
+ --dark-blue: #002D62; /* Used for dark slices and center */
11
+ --light-blue: #B0E0E6; /* Used for light slices */
12
+ --red-pointer: #DC143C; /* Used for the pointer */
13
+ --border-color: #A9A9A9; /* Light border/outline color */
14
+ }
15
+
16
  body {
17
  margin: 0;
18
  font-family: Arial, sans-serif;
19
+ background: #E0FFFF; /* Very light blue background */
20
+ color: var(--dark-blue);
21
  height: 100vh;
22
  display: flex;
23
  justify-content: center;
 
28
  .container {
29
  width: 90%;
30
  max-width: 400px;
31
+ padding: 20px;
32
  }
33
 
34
  .info {
 
36
  font-size: 16px;
37
  line-height: 22px;
38
  opacity: 0.9;
39
+ color: var(--dark-blue);
40
  }
41
 
42
+ /* --- Wheel Styling to Match Image --- */
43
  .wheel {
44
  width: 300px;
45
  height: 300px;
46
  border-radius: 50%;
47
+ border: 5px solid var(--border-color); /* Outer ring */
48
  position: relative;
49
  overflow: hidden;
50
+ transition: transform 3s cubic-bezier(.12,.66,.11,1.23); /* Adjusted speed for a better visual spin */
51
  margin: auto;
52
+ box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
53
  }
54
 
55
  .slice {
 
63
  display: flex;
64
  justify-content: center;
65
  align-items: center;
66
+ font-size: 20px; /* Larger symbols */
67
  font-weight: bold;
68
+ /* Removed border for a cleaner look like the image */
69
+ }
70
+
71
+ /* 10 Slices with alternating colors */
72
+ .slice:nth-child(odd) {
73
+ background: var(--dark-blue);
74
+ color: white;
75
+ }
76
+ .slice:nth-child(even) {
77
+ background: var(--light-blue);
78
+ color: var(--dark-blue); /* Dark text on light slice */
79
+ }
80
+
81
+ /* Rotate slices for 10 segments (360/10 = 36 degrees per slice) */
82
+ /* Skew is used to make the triangular shape */
83
+ .slice:nth-child(1) { transform: rotate(0deg) skewY(-54deg) rotate(18deg); }
84
+ .slice:nth-child(2) { transform: rotate(36deg) skewY(-54deg) rotate(18deg); }
85
+ .slice:nth-child(3) { transform: rotate(72deg) skewY(-54deg) rotate(18deg); }
86
+ .slice:nth-child(4) { transform: rotate(108deg) skewY(-54deg) rotate(18deg); }
87
+ .slice:nth-child(5) { transform: rotate(144deg) skewY(-54deg) rotate(18deg); }
88
+ .slice:nth-child(6) { transform: rotate(180deg) skewY(-54deg) rotate(18deg); }
89
+ .slice:nth-child(7) { transform: rotate(216deg) skewY(-54deg) rotate(18deg); }
90
+ .slice:nth-child(8) { transform: rotate(252deg) skewY(-54deg) rotate(18deg); }
91
+ .slice:nth-child(9) { transform: rotate(288deg) skewY(-54deg) rotate(18deg); }
92
+ .slice:nth-child(10) { transform: rotate(324deg) skewY(-54deg) rotate(18deg); }
93
+
94
+ /* Centered "PLAY" button */
95
+ .center-circle {
96
+ position: absolute;
97
+ top: 50%;
98
+ left: 50%;
99
+ transform: translate(-50%, -50%);
100
+ width: 80px;
101
+ height: 80px;
102
+ background-color: white;
103
+ border-radius: 50%;
104
+ display: flex;
105
+ justify-content: center;
106
+ align-items: center;
107
+ z-index: 10;
108
+ border: 5px solid var(--dark-blue);
109
+ box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
110
+ cursor: pointer;
111
+ font-size: 18px;
112
+ font-weight: bold;
113
+ color: var(--dark-blue);
114
+ }
115
+
116
+ /* Outer dots/markers (simplified for CSS) */
117
+ .outer-ring-dots {
118
+ position: absolute;
119
+ top: 0;
120
+ left: 0;
121
+ right: 0;
122
+ bottom: 0;
123
+ border-radius: 50%;
124
+ pointer-events: none;
125
+ /* A simple dashed border can simulate the dots */
126
+ /* You could also use pseudoelements and more complex CSS for individual dots */
127
  }
128
 
 
 
 
 
 
129
 
130
  .pointer {
131
  width: 0; height: 0;
132
+ border-left: 10px solid transparent;
133
+ border-right: 10px solid transparent;
134
+ border-bottom: 20px solid var(--red-pointer); /* Red pointer like the image */
135
  margin: auto;
136
+ margin-bottom: 5px; /* Move closer to the wheel */
137
+ z-index: 20;
138
  }
139
 
140
  button {
141
  margin-top: 25px;
142
  font-size: 20px;
143
  padding: 12px 25px;
144
+ background: var(--dark-blue); /* Spin button color */
145
  border: none;
146
  border-radius: 8px;
147
  color: white;
148
  cursor: pointer;
149
+ display: none; /* Hide the SPIN button, use the center-circle for interaction */
150
  }
151
  button:disabled {
152
  background: #333;
 
157
  margin-top: 20px;
158
  font-size: 18px;
159
  display: none;
160
+ color: var(--dark-blue);
161
+ }
162
+
163
+ .try-your-luck {
164
+ margin-top: 20px;
165
+ font-size: 14px;
166
+ opacity: 0.7;
167
+ position: relative;
168
+ padding-top: 10px;
169
+ }
170
+ .try-your-luck:before {
171
+ content: '';
172
+ position: absolute;
173
+ top: 0;
174
+ left: 50%;
175
+ transform: translateX(-50%);
176
+ width: 60px;
177
+ height: 1px;
178
+ background: var(--dark-blue);
179
  }
180
+
181
  </style>
182
  </head>
183
 
 
187
 
188
  <p class="info">
189
  ⚡ For load balancing we add this to handle high traffic.<br>
190
+ Click **PLAY** to unlock the main site!
191
  </p>
192
 
193
  <div class="pointer"></div>
194
  <div class="wheel" id="wheel">
195
+ <div class="slice">$$</div>
196
+ <div class="slice">%</div>
197
+ <div class="slice">$$</div>
198
+ <div class="slice">%</div>
199
+ <div class="slice">$$</div>
200
+ <div class="slice">%</div>
201
+ <div class="slice">$$</div>
202
+ <div class="slice">%</div>
203
+ <div class="slice">$$</div>
204
+ <div class="slice">%</div>
205
+
206
+ <div class="center-circle" onclick="spinWheel()" id="centerBtn">PLAY</div>
207
  </div>
208
+
209
+ <p class="try-your-luck">
210
+ TRY YOUR LUCK
211
+ </p>
212
 
213
+ <button id="btn" style="display: none;">SPIN</button> <p id="message"></p>
 
214
 
215
  </div>
216
 
217
  <script>
218
+ // The array needs 10 items to match the 10 slices,
219
+ // even though only 5 unique sites are available.
220
  const sites = [
221
+ "https://www.love.com", // Index 0 ($$)
222
+ "https://www.love1.com", // Index 1 (%)
223
+ "https://www.love2.com", // Index 2 ($$)
224
+ "https://www.love3.com", // Index 3 (%)
225
+ "https://www.love4.com", // Index 4 ($$)
226
+ "https://www.love.com", // Index 5 (%)
227
+ "https://www.love1.com", // Index 6 ($$)
228
+ "https://www.love2.com", // Index 7 (%)
229
+ "https://www.love3.com", // Index 8 ($$)
230
+ "https://www.love4.com" // Index 9 (%)
231
  ];
232
 
233
  let spinning = false;
 
238
 
239
  const wheel = document.getElementById("wheel");
240
  const message = document.getElementById("message");
241
+ const centerBtn = document.getElementById("centerBtn");
242
 
243
+ // Disable the center button
244
+ centerBtn.style.pointerEvents = 'none';
245
+ centerBtn.textContent = '...';
246
 
247
  const index = Math.floor(Math.random() * sites.length);
248
+ const totalSlices = sites.length; // 10
249
+ const degreePerSlice = 360 / totalSlices; // 36 degrees
250
 
251
+ /* Calculate the degrees:
252
+ 1. 360 * 10: Ensures many rotations for visual effect.
253
+ 2. (360 - index * degreePerSlice): Positions the wheel to land the selected slice at the top (under the pointer).
254
+ 3. - (degreePerSlice / 2): Adjusts for the pointer pointing to the center of the slice, not the edge (36/2 = 18 degrees).
255
+ */
256
+ const degrees = 360 * 10 + (360 - index * degreePerSlice) - (degreePerSlice / 2);
257
  wheel.style.transform = `rotate(${degrees}deg)`;
258
 
259
  message.style.display = "block";
260
  message.textContent = "🎡 Fast spinning…";
261
 
262
+ /* Redirect after the transition completes */
263
  setTimeout(() => {
264
  const selected = sites[index];
265
  message.textContent = "Redirecting to " + selected;
266
+ // window.location.href = selected; // Uncomment this for live redirect
267
+ console.log("Redirecting to: " + selected); // Log for testing
268
+
269
+ // Reset state for re-spin (if not redirecting)
270
+ spinning = false;
271
+ centerBtn.style.pointerEvents = 'auto';
272
+ centerBtn.textContent = 'PLAY';
273
+
274
+ }, 3000); // 3 seconds to match the CSS transition duration
275
  }
276
  </script>
277
 
278
  </body>
279
+ </html>