Atibroo commited on
Commit
31a2229
·
verified ·
1 Parent(s): 7e1eddd

Add 3 files

Browse files
Files changed (3) hide show
  1. README.md +7 -5
  2. index.html +92 -19
  3. prompts.txt +1 -0
README.md CHANGED
@@ -1,10 +1,12 @@
1
  ---
2
- title: Ala
3
- emoji: 📉
4
- colorFrom: yellow
5
- colorTo: purple
6
  sdk: static
7
  pinned: false
 
 
8
  ---
9
 
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
1
  ---
2
+ title: ala
3
+ emoji: ⚛️
4
+ colorFrom: green
5
+ colorTo: green
6
  sdk: static
7
  pinned: false
8
+ tags:
9
+ - QwenSite
10
  ---
11
 
12
+ Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
index.html CHANGED
@@ -1,19 +1,92 @@
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="ar" 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
+ <script src="https://cdn.tailwindcss.com"></script>
8
+ <script src="https://kit.fontawesome.com/a076d05399.js" crossorigin="anonymous"></script>
9
+ <style>
10
+ body {
11
+ background: linear-gradient(to bottom right, #1e3c72, #2a5298);
12
+ font-family: 'Tajawal', sans-serif;
13
+ }
14
+ .calc-container {
15
+ max-width: 400px;
16
+ margin: 50px auto;
17
+ border-radius: 20px;
18
+ overflow: hidden;
19
+ box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
20
+ }
21
+ .btn:active {
22
+ transform: scale(0.95);
23
+ }
24
+ </style>
25
+ <link href="https://fonts.googleapis.com/css2?family=Tajawal:wght@500&display=swap" rel="stylesheet">
26
+ </head>
27
+ <body class="text-white min-h-screen flex items-center justify-center">
28
+
29
+ <div class="calc-container bg-gray-900 text-white">
30
+ <div class="p-5 bg-gray-800">
31
+ <input type="text" id="display" class="w-full text-right text-3xl p-3 bg-gray-900 border-none outline-none text-white" readonly>
32
+ </div>
33
+
34
+ <div class="grid grid-cols-4 gap-2 p-3 bg-gray-900">
35
+ <!-- Row 1 -->
36
+ <button onclick="clearDisplay()" class="btn bg-red-500 hover:bg-red-600 text-white p-4 rounded-xl text-xl transition"><i class="fas fa-trash"></i></button>
37
+ <button onclick="appendOperator('%')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">%</button>
38
+ <button onclick="appendOperator('÷')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">÷</button>
39
+ <button onclick="appendOperator('×')" class="btn bg-yellow-500 hover:bg-yellow-600 text-white p-4 rounded-xl text-xl transition">×</button>
40
+
41
+ <!-- Row 2 -->
42
+ <button onclick="appendNumber('7')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">7</button>
43
+ <button onclick="appendNumber('8')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">8</button>
44
+ <button onclick="appendNumber('9')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">9</button>
45
+ <button onclick="appendOperator('-')" class="btn bg-yellow-500 hover:bg-yellow-600 text-white p-4 rounded-xl text-xl transition">-</button>
46
+
47
+ <!-- Row 3 -->
48
+ <button onclick="appendNumber('4')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">4</button>
49
+ <button onclick="appendNumber('5')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">5</button>
50
+ <button onclick="appendNumber('6')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">6</button>
51
+ <button onclick="appendOperator('+')" class="btn bg-yellow-500 hover:bg-yellow-600 text-white p-4 rounded-xl text-xl transition">+</button>
52
+
53
+ <!-- Row 4 -->
54
+ <button onclick="appendNumber('1')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">1</button>
55
+ <button onclick="appendNumber('2')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">2</button>
56
+ <button onclick="appendNumber('3')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">3</button>
57
+ <button onclick="calculate()" class="btn bg-green-500 hover:bg-green-600 text-white p-4 rounded-xl text-xl transition row-span-2 flex items-center justify-center">=</button>
58
+
59
+ <!-- Row 5 -->
60
+ <button onclick="appendNumber('0')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition col-span-2 w-full">0</button>
61
+ <button onclick="appendNumber('.')" class="btn bg-gray-700 hover:bg-gray-600 text-white p-4 rounded-xl text-xl transition">.</button>
62
+ </div>
63
+ </div>
64
+
65
+ <script>
66
+ let display = document.getElementById('display');
67
+
68
+ function appendNumber(num) {
69
+ display.value += num;
70
+ }
71
+
72
+ function appendOperator(op) {
73
+ if (op === '÷') op = '/';
74
+ else if (op === '×') op = '*';
75
+ display.value += op;
76
+ }
77
+
78
+ function clearDisplay() {
79
+ display.value = '';
80
+ }
81
+
82
+ function calculate() {
83
+ try {
84
+ display.value = eval(display.value.replace(/[^-()\d/*+.%]/g, ''));
85
+ } catch (e) {
86
+ display.value = '��طأ';
87
+ }
88
+ }
89
+ </script>
90
+
91
+ <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-qwensite.hf.space/logo.svg" alt="qwensite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-qwensite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >QwenSite</a> - 🧬 <a href="https://enzostvs-qwensite.hf.space?remix=Atibroo/ala" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
92
+ </html>
prompts.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ كود الة حاسبة للاندرويد تكون بمنظر جميل جدا ورائع جداً