Spaces:
Running
Running
да уже лучше, но давай добавим на карточку пользовательские инпуты
Browse filesorderdat
Shares
Amount
Account
и вывод нужно убирать не за 5 сек а по нажатию на закрыть чтобы прользователь мог прочитать ответ
+ сделай карточку более прямоугольной вниз а не квадратной
- index.html +31 -7
- script.js +5 -7
- style.css +3 -1
index.html
CHANGED
|
@@ -17,8 +17,11 @@
|
|
| 17 |
<!-- Paper Product Card -->
|
| 18 |
<div class="paper-card bg-white rounded-xl shadow-lg overflow-hidden transition-all duration-300 hover:shadow-xl relative">
|
| 19 |
<div class="absolute inset-0 flex items-center justify-center z-10 notification hidden">
|
| 20 |
-
<div class="bg-white rounded-lg shadow-2xl p-6 max-w-sm w-full text-center">
|
| 21 |
-
<
|
|
|
|
|
|
|
|
|
|
| 22 |
<i data-feather="check-circle" class="text-green-500 w-12 h-12 mx-auto hidden success-icon"></i>
|
| 23 |
<i data-feather="x-circle" class="text-red-500 w-12 h-12 mx-auto hidden error-icon"></i>
|
| 24 |
</div>
|
|
@@ -26,11 +29,9 @@
|
|
| 26 |
<p class="text-gray-600 notification-message">Your transaction was completed successfully.</p>
|
| 27 |
</div>
|
| 28 |
</div>
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
<i data-feather="file-text" class="text-white w-20 h-20"></i>
|
| 32 |
</div>
|
| 33 |
-
|
| 34 |
<div class="p-6">
|
| 35 |
<div class="flex justify-between items-start mb-2">
|
| 36 |
<h2 class="text-xl font-bold text-gray-800">Premium A4 Paper</h2>
|
|
@@ -38,6 +39,29 @@
|
|
| 38 |
</div>
|
| 39 |
|
| 40 |
<p class="text-gray-600 mb-4">High quality 80gsm paper with smooth texture for professional printing.</p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 41 |
|
| 42 |
<div class="flex items-center justify-between mb-4">
|
| 43 |
<div>
|
|
@@ -63,7 +87,7 @@
|
|
| 63 |
Sell
|
| 64 |
</button>
|
| 65 |
</div>
|
| 66 |
-
|
| 67 |
</div>
|
| 68 |
</div>
|
| 69 |
</div>
|
|
|
|
| 17 |
<!-- Paper Product Card -->
|
| 18 |
<div class="paper-card bg-white rounded-xl shadow-lg overflow-hidden transition-all duration-300 hover:shadow-xl relative">
|
| 19 |
<div class="absolute inset-0 flex items-center justify-center z-10 notification hidden">
|
| 20 |
+
<div class="bg-white rounded-lg shadow-2xl p-6 max-w-sm w-full text-center relative">
|
| 21 |
+
<button class="close-notification absolute top-2 right-2 text-gray-400 hover:text-gray-600">
|
| 22 |
+
<i data-feather="x" class="w-5 h-5"></i>
|
| 23 |
+
</button>
|
| 24 |
+
<div class="icon-container mb-4">
|
| 25 |
<i data-feather="check-circle" class="text-green-500 w-12 h-12 mx-auto hidden success-icon"></i>
|
| 26 |
<i data-feather="x-circle" class="text-red-500 w-12 h-12 mx-auto hidden error-icon"></i>
|
| 27 |
</div>
|
|
|
|
| 29 |
<p class="text-gray-600 notification-message">Your transaction was completed successfully.</p>
|
| 30 |
</div>
|
| 31 |
</div>
|
| 32 |
+
<div class="h-32 bg-gradient-to-r from-blue-400 to-purple-500 flex items-center justify-center">
|
| 33 |
+
<i data-feather="file-text" class="text-white w-20 h-20"></i>
|
|
|
|
| 34 |
</div>
|
|
|
|
| 35 |
<div class="p-6">
|
| 36 |
<div class="flex justify-between items-start mb-2">
|
| 37 |
<h2 class="text-xl font-bold text-gray-800">Premium A4 Paper</h2>
|
|
|
|
| 39 |
</div>
|
| 40 |
|
| 41 |
<p class="text-gray-600 mb-4">High quality 80gsm paper with smooth texture for professional printing.</p>
|
| 42 |
+
|
| 43 |
+
<div class="space-y-3 mb-4">
|
| 44 |
+
<div>
|
| 45 |
+
<label class="block text-sm font-medium text-gray-700 mb-1">Order Date</label>
|
| 46 |
+
<input type="date" class="order-date w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
|
| 47 |
+
</div>
|
| 48 |
+
<div>
|
| 49 |
+
<label class="block text-sm font-medium text-gray-700 mb-1">Shares</label>
|
| 50 |
+
<input type="number" class="shares w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="Enter quantity">
|
| 51 |
+
</div>
|
| 52 |
+
<div>
|
| 53 |
+
<label class="block text-sm font-medium text-gray-700 mb-1">Amount</label>
|
| 54 |
+
<input type="number" class="amount w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="Enter amount">
|
| 55 |
+
</div>
|
| 56 |
+
<div>
|
| 57 |
+
<label class="block text-sm font-medium text-gray-700 mb-1">Account</label>
|
| 58 |
+
<select class="account w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
|
| 59 |
+
<option value="">Select account</option>
|
| 60 |
+
<option value="personal">Personal</option>
|
| 61 |
+
<option value="business">Business</option>
|
| 62 |
+
</select>
|
| 63 |
+
</div>
|
| 64 |
+
</div>
|
| 65 |
|
| 66 |
<div class="flex items-center justify-between mb-4">
|
| 67 |
<div>
|
|
|
|
| 87 |
Sell
|
| 88 |
</button>
|
| 89 |
</div>
|
| 90 |
+
</div>
|
| 91 |
</div>
|
| 92 |
</div>
|
| 93 |
</div>
|
script.js
CHANGED
|
@@ -38,16 +38,14 @@ document.addEventListener('DOMContentLoaded', function() {
|
|
| 38 |
|
| 39 |
// Show notification
|
| 40 |
notification.classList.remove('hidden');
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
notification.classList.add('hide');
|
| 45 |
-
|
| 46 |
-
// Reset after animation completes
|
| 47 |
setTimeout(() => {
|
| 48 |
notification.classList.add('hidden');
|
| 49 |
notification.classList.remove('hide');
|
| 50 |
}, 300);
|
| 51 |
-
}
|
| 52 |
-
|
| 53 |
});
|
|
|
|
| 38 |
|
| 39 |
// Show notification
|
| 40 |
notification.classList.remove('hidden');
|
| 41 |
+
// Add close button event
|
| 42 |
+
const closeBtn = card.querySelector('.close-notification');
|
| 43 |
+
closeBtn.addEventListener('click', () => {
|
| 44 |
notification.classList.add('hide');
|
|
|
|
|
|
|
| 45 |
setTimeout(() => {
|
| 46 |
notification.classList.add('hidden');
|
| 47 |
notification.classList.remove('hide');
|
| 48 |
}, 300);
|
| 49 |
+
});
|
| 50 |
+
}
|
| 51 |
});
|
style.css
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
|
|
| 1 |
.paper-card {
|
| 2 |
position: relative;
|
| 3 |
transition: transform 0.3s ease;
|
|
|
|
|
|
|
| 4 |
}
|
| 5 |
-
|
| 6 |
.paper-card:hover {
|
| 7 |
transform: translateY(-5px);
|
| 8 |
}
|
|
|
|
| 1 |
+
|
| 2 |
.paper-card {
|
| 3 |
position: relative;
|
| 4 |
transition: transform 0.3s ease;
|
| 5 |
+
height: auto;
|
| 6 |
+
min-height: 650px;
|
| 7 |
}
|
|
|
|
| 8 |
.paper-card:hover {
|
| 9 |
transform: translateY(-5px);
|
| 10 |
}
|