Mmdv2 commited on
Commit
12adee2
·
verified ·
1 Parent(s): 9407574

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. index.html +419 -19
index.html CHANGED
@@ -1,19 +1,419 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
19
- </html>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="fa" dir="rtl">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>برنامه سلام و احوالپرسی</title>
7
+ <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
8
+ <style>
9
+ * {
10
+ margin: 0;
11
+ padding: 0;
12
+ box-sizing: border-box;
13
+ font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
14
+ }
15
+
16
+ :root {
17
+ --primary-color: #4f46e5;
18
+ --secondary-color: #7c73e6;
19
+ --accent-color: #f59e0b;
20
+ --text-color: #1f2937;
21
+ --bg-color: #f8fafc;
22
+ --card-bg: #ffffff;
23
+ --shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
24
+ --gradient: linear-gradient(135deg, #4f46e5, #7c73e6);
25
+ }
26
+
27
+ body {
28
+ background: var(--bg-color);
29
+ color: var(--text-color);
30
+ min-height: 100vh;
31
+ display: flex;
32
+ flex-direction: column;
33
+ align-items: center;
34
+ justify-content: center;
35
+ padding: 20px;
36
+ transition: all 0.3s ease;
37
+ }
38
+
39
+ .header {
40
+ position: absolute;
41
+ top: 20px;
42
+ left: 20px;
43
+ }
44
+
45
+ .anycoder-link {
46
+ color: var(--primary-color);
47
+ text-decoration: none;
48
+ font-size: 14px;
49
+ display: flex;
50
+ align-items: center;
51
+ gap: 5px;
52
+ transition: all 0.3s ease;
53
+ }
54
+
55
+ .anycoder-link:hover {
56
+ color: var(--secondary-color);
57
+ transform: translateY(-2px);
58
+ }
59
+
60
+ .container {
61
+ max-width: 800px;
62
+ width: 100%;
63
+ background: var(--card-bg);
64
+ border-radius: 20px;
65
+ box-shadow: var(--shadow);
66
+ overflow: hidden;
67
+ animation: fadeIn 1s ease;
68
+ }
69
+
70
+ @keyframes fadeIn {
71
+ from { opacity: 0; transform: translateY(20px); }
72
+ to { opacity: 1; transform: translateY(0); }
73
+ }
74
+
75
+ .hero {
76
+ background: var(--gradient);
77
+ color: white;
78
+ padding: 40px 30px;
79
+ text-align: center;
80
+ position: relative;
81
+ overflow: hidden;
82
+ }
83
+
84
+ .hero::before {
85
+ content: '';
86
+ position: absolute;
87
+ top: -50%;
88
+ left: -50%;
89
+ width: 200%;
90
+ height: 200%;
91
+ background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
92
+ animation: rotate 20s linear infinite;
93
+ }
94
+
95
+ @keyframes rotate {
96
+ from { transform: rotate(0deg); }
97
+ to { transform: rotate(360deg); }
98
+ }
99
+
100
+ .hero h1 {
101
+ font-size: 2.5rem;
102
+ margin-bottom: 10px;
103
+ position: relative;
104
+ z-index: 1;
105
+ }
106
+
107
+ .hero p {
108
+ font-size: 1.2rem;
109
+ opacity: 0.9;
110
+ position: relative;
111
+ z-index: 1;
112
+ }
113
+
114
+ .content {
115
+ padding: 40px 30px;
116
+ }
117
+
118
+ .greeting-section {
119
+ display: flex;
120
+ flex-direction: column;
121
+ align-items: center;
122
+ gap: 20px;
123
+ margin-bottom: 40px;
124
+ }
125
+
126
+ .greeting-box {
127
+ background: var(--gradient);
128
+ color: white;
129
+ padding: 20px 30px;
130
+ border-radius: 15px;
131
+ text-align: center;
132
+ font-size: 1.8rem;
133
+ box-shadow: var(--shadow);
134
+ transition: transform 0.3s ease;
135
+ }
136
+
137
+ .greeting-box:hover {
138
+ transform: scale(1.05);
139
+ }
140
+
141
+ .response-box {
142
+ background: var(--card-bg);
143
+ border: 2px dashed var(--secondary-color);
144
+ padding: 20px 30px;
145
+ border-radius: 15px;
146
+ text-align: center;
147
+ font-size: 1.8rem;
148
+ color: var(--primary-color);
149
+ min-height: 80px;
150
+ display: flex;
151
+ align-items: center;
152
+ justify-content: center;
153
+ transition: all 0.3s ease;
154
+ }
155
+
156
+ .response-box:hover {
157
+ border-style: solid;
158
+ background: rgba(79, 70, 229, 0.05);
159
+ }
160
+
161
+ .interaction-section {
162
+ display: grid;
163
+ grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
164
+ gap: 20px;
165
+ margin-top: 30px;
166
+ }
167
+
168
+ .interaction-card {
169
+ background: var(--card-bg);
170
+ border-radius: 15px;
171
+ padding: 25px;
172
+ box-shadow: var(--shadow);
173
+ display: flex;
174
+ flex-direction: column;
175
+ align-items: center;
176
+ text-align: center;
177
+ transition: all 0.3s ease;
178
+ cursor: pointer;
179
+ }
180
+
181
+ .interaction-card:hover {
182
+ transform: translateY(-10px);
183
+ box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
184
+ }
185
+
186
+ .interaction-card i {
187
+ font-size: 2.5rem;
188
+ color: var(--primary-color);
189
+ margin-bottom: 15px;
190
+ }
191
+
192
+ .interaction-card h3 {
193
+ margin-bottom: 10px;
194
+ color: var(--text-color);
195
+ }
196
+
197
+ .interaction-card p {
198
+ color: #6b7280;
199
+ font-size: 0.9rem;
200
+ }
201
+
202
+ .emoji-section {
203
+ display: flex;
204
+ justify-content: center;
205
+ gap: 15px;
206
+ margin-top: 30px;
207
+ flex-wrap: wrap;
208
+ }
209
+
210
+ .emoji-btn {
211
+ background: var(--card-bg);
212
+ border: none;
213
+ border-radius: 50%;
214
+ width: 60px;
215
+ height: 60px;
216
+ font-size: 1.8rem;
217
+ cursor: pointer;
218
+ box-shadow: var(--shadow);
219
+ transition: all 0.3s ease;
220
+ }
221
+
222
+ .emoji-btn:hover {
223
+ transform: scale(1.2) rotate(10deg);
224
+ background: var(--gradient);
225
+ color: white;
226
+ }
227
+
228
+ .theme-toggle {
229
+ position: absolute;
230
+ top: 20px;
231
+ right: 20px;
232
+ background: var(--card-bg);
233
+ border: none;
234
+ border-radius: 50%;
235
+ width: 50px;
236
+ height: 50px;
237
+ display: flex;
238
+ align-items: center;
239
+ justify-content: center;
240
+ cursor: pointer;
241
+ box-shadow: var(--shadow);
242
+ font-size: 1.2rem;
243
+ color: var(--primary-color);
244
+ transition: all 0.3s ease;
245
+ }
246
+
247
+ .theme-toggle:hover {
248
+ transform: rotate(180deg);
249
+ }
250
+
251
+ .footer {
252
+ margin-top: 40px;
253
+ text-align: center;
254
+ color: #6b7280;
255
+ font-size: 0.9rem;
256
+ }
257
+
258
+ /* Dark theme */
259
+ body.dark-theme {
260
+ --text-color: #f9fafb;
261
+ --bg-color: #111827;
262
+ --card-bg: #1f2937;
263
+ --shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
264
+ }
265
+
266
+ /* Responsive styles */
267
+ @media (max-width: 768px) {
268
+ .hero h1 {
269
+ font-size: 2rem;
270
+ }
271
+
272
+ .hero p {
273
+ font-size: 1rem;
274
+ }
275
+
276
+ .greeting-box, .response-box {
277
+ font-size: 1.5rem;
278
+ padding: 15px 20px;
279
+ }
280
+
281
+ .content {
282
+ padding: 30px 20px;
283
+ }
284
+ }
285
+
286
+ @media (max-width: 480px) {
287
+ .hero {
288
+ padding: 30px 20px;
289
+ }
290
+
291
+ .hero h1 {
292
+ font-size: 1.7rem;
293
+ }
294
+
295
+ .interaction-section {
296
+ grid-template-columns: 1fr;
297
+ }
298
+ }
299
+ </style>
300
+ </head>
301
+ <body>
302
+ <div class="header">
303
+ <a href="https://huggingface.co/spaces/akhaliq/anycoder" class="anycoder-link">
304
+ <i class="fas fa-code"></i>
305
+ Built with anycoder
306
+ </a>
307
+ </div>
308
+
309
+ <button class="theme-toggle" id="themeToggle">
310
+ <i class="fas fa-moon"></i>
311
+ </button>
312
+
313
+ <div class="container">
314
+ <div class="hero">
315
+ <h1>سلام! خوبی؟</h1>
316
+ <p>برنامه تعاملی سلام و احوالپرسی به زبان فارسی</p>
317
+ </div>
318
+
319
+ <div class="content">
320
+ <div class="greeting-section">
321
+ <div class="greeting-box" id="greeting">
322
+ سلام! خوبی؟
323
+ </div>
324
+ <div class="response-box" id="response">
325
+ من خوبم، ممنون! شما چطورید؟
326
+ </div>
327
+ </div>
328
+
329
+ <div class="interaction-section">
330
+ <div class="interaction-card" onclick="changeGreeting('سلام! چطوری؟')">
331
+ <i class="fas fa-handshake"></i>
332
+ <h3>سلام دوستانه</h3>
333
+ <p>یک سلام صمیمانه و گرم</p>
334
+ </div>
335
+
336
+ <div class="interaction-card" onclick="changeGreeting('درود! حالتون چطوره؟')">
337
+ <i class="fas fa-user-friends"></i>
338
+ <h3>د��ود رسمی</h3>
339
+ <p>سلام و احوالپرسی رسمی</p>
340
+ </div>
341
+
342
+ <div class="interaction-card" onclick="changeGreeting('سلام عزیزم! چطوری؟')">
343
+ <i class="fas fa-heart"></i>
344
+ <h3>سلام عاشقانه</h3>
345
+ <p>سلامی پر از محبت و عشق</p>
346
+ </div>
347
+ </div>
348
+
349
+ <div class="emoji-section">
350
+ <button class="emoji-btn" onclick="showResponse('😊 خیلی خوبم! ممنون')">😊</button>
351
+ <button class="emoji-btn" onclick="showResponse('😐 بدک نیستم')">😐</button>
352
+ <button class="emoji-btn" onclick="showResponse('😔 حالم خوب نیست')">😔</button>
353
+ <button class="emoji-btn" onclick="showResponse('🤩 عالیم!')">🤩</button>
354
+ <button class="emoji-btn" onclick="showResponse('👍 خوبم، مرسی')">👍</button>
355
+ </div>
356
+ </div>
357
+ </div>
358
+
359
+ <div class="footer">
360
+ طراحی شده با HTML, CSS و JavaScript
361
+ </div>
362
+
363
+ <script>
364
+ // Theme toggle functionality
365
+ const themeToggle = document.getElementById('themeToggle');
366
+ const body = document.body;
367
+
368
+ themeToggle.addEventListener('click', () => {
369
+ body.classList.toggle('dark-theme');
370
+
371
+ if (body.classList.contains('dark-theme')) {
372
+ themeToggle.innerHTML = '<i class="fas fa-sun"></i>';
373
+ } else {
374
+ themeToggle.innerHTML = '<i class="fas fa-moon"></i>';
375
+ }
376
+ });
377
+
378
+ // Greeting change functionality
379
+ function changeGreeting(newGreeting) {
380
+ const greetingElement = document.getElementById('greeting');
381
+ greetingElement.textContent = newGreeting;
382
+
383
+ // Add animation
384
+ greetingElement.style.transform = 'scale(1.1)';
385
+ setTimeout(() => {
386
+ greetingElement.style.transform = 'scale(1)';
387
+ }, 300);
388
+
389
+ // Reset response
390
+ document.getElementById('response').textContent = 'من خوبم، ممنون! شما چطورید؟';
391
+ }
392
+
393
+ // Response change functionality
394
+ function showResponse(newResponse) {
395
+ const responseElement = document.getElementById('response');
396
+ responseElement.textContent = newResponse;
397
+
398
+ // Add animation
399
+ responseElement.style.transform = 'scale(1.1)';
400
+ setTimeout(() => {
401
+ responseElement.style.transform = 'scale(1)';
402
+ }, 300);
403
+ }
404
+
405
+ // Add some random animations to emojis
406
+ const emojiButtons = document.querySelectorAll('.emoji-btn');
407
+ emojiButtons.forEach(btn => {
408
+ btn.addEventListener('mouseover', () => {
409
+ const randomRotation = Math.floor(Math.random() * 20) - 10;
410
+ btn.style.transform = `scale(1.2) rotate(${randomRotation}deg)`;
411
+ });
412
+
413
+ btn.addEventListener('mouseout', () => {
414
+ btn.style.transform = 'scale(1) rotate(0deg)';
415
+ });
416
+ });
417
+ </script>
418
+ </body>
419
+ </html>