Spaces:
Running
Running
File size: 9,349 Bytes
1dd531b e534b1a 1dd531b b83b42b b9dfa58 b83b42b 1dd531b 3fb8e1f 70ea623 238bb87 3fb8e1f e534b1a 1dd531b e4fea1b 1dd531b e4fea1b 1dd531b e4fea1b 1dd531b e4fea1b 8ecd4e0 e4fea1b 1dd531b e4fea1b 1dd531b | 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 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Load Allocator</title>
<link rel="stylesheet" href="style.css">
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/feather-icons"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/vanta@latest/dist/vanta.globe.min.js"></script>
</head>
<body class="bg-gray-900 text-white">
<custom-navbar></custom-navbar>
<main class="container mx-auto px-4 py-8">
<div id="vanta-bg" class="absolute inset-0 z-0"></div>
<div class="relative z-10 text-center mb-8">
</div>
<div class="relative z-10 max-w-6xl mx-auto">
<div class="glass-card p-8 rounded-2xl shadow-2xl">
<div class="flex items-center justify-center gap-3 mb-4">
<img src="https://huggingface.co/spaces/excopstig/space-grid-wizard/resolve/main/images/IMG_3979.PNG" width="360" height="120" alt="Load Allocator Logo">
<h1 class="text-4xl font-bold"></h1>
</div>
<p class="text-xl text-center mb-8 text-gray-300">Optimize your space and resource allocation with precision</p>
<div class="grid md:grid-cols-2 gap-8">
<!-- Input Section -->
<div class="bg-gray-800 p-6 rounded-xl shadow-lg">
<h2 class="text-2xl font-semibold mb-4 flex items-center">
<i data-feather="edit-2" class="mr-2"></i> Configure Your Space
</h2>
<div class="space-y-4">
<div>
<label class="block mb-1 text-gray-300">Container Dimensions</label>
<div class="grid grid-cols-2 gap-3">
<input type="number" id="container-width" placeholder="Width (cm)"
class="bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
<input type="number" id="container-height" placeholder="Height (cm)"
class="bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
</div>
<div class="mt-3">
<input type="number" id="container-weight" placeholder="Max Weight (kg)" value="7200"
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
</div>
</div>
<div>
<label class="block mb-1 text-gray-300">Add Item</label>
<input type="text" id="item-name" placeholder="Item name"
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 mb-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
<div class="grid grid-cols-2 gap-3">
<input type="number" id="item-length" placeholder="Length (cm)"
class="bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
<input type="number" id="item-width" placeholder="Width (cm)"
class="bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
</div>
<div class="mt-2">
<input type="number" id="item-weight" placeholder="Weight (kg)"
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
</div>
<div class="mt-2">
<input type="number" id="item-quantity" placeholder="Quantity" value="1" min="1"
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-2 focus:ring-2 focus:ring-blue-500 focus:border-blue-500">
</div>
</div>
<div class="grid grid-cols-2 gap-3">
<button id="add-item-btn" class="bg-blue-600 hover:bg-blue-700 text-white py-2 px-4 rounded-lg flex items-center justify-center transition">
<i data-feather="plus" class="mr-2"></i> Add Item
</button>
<button id="remove-item-btn" class="bg-red-600 hover:bg-red-700 text-white py-2 px-4 rounded-lg flex items-center justify-center transition">
<i data-feather="trash-2" class="mr-2"></i> Remove
</button>
</div>
<div class="grid grid-cols-2 gap-3">
<button id="update-container-btn" class="bg-yellow-600 hover:bg-yellow-700 text-white py-2 px-4 rounded-lg flex items-center justify-center transition">
<i data-feather="refresh-cw" class="mr-2"></i> Update Container
</button>
<button id="clear-all-btn" class="bg-gray-600 hover:bg-gray-700 text-white py-2 px-4 rounded-lg flex items-center justify-center transition">
<i data-feather="x" class="mr-2"></i> Clear All
</button>
</div>
</div>
</div>
<!-- Items List -->
<div class="bg-gray-800 p-6 rounded-xl shadow-lg">
<h2 class="text-2xl font-semibold mb-4 flex items-center">
<i data-feather="list" class="mr-2"></i> Items
</h2>
<div class="space-y-4">
<div id="space-stats" class="bg-gray-700 p-3 rounded-lg">
<p class="text-center">Add items to see statistics</p>
</div>
<div class="overflow-auto max-h-64">
<table class="w-full border-collapse">
<thead>
<tr class="border-b border-gray-600">
<th class="p-2 text-left">Name</th>
<th class="p-2 text-center">Length</th>
<th class="p-2 text-center">Width</th>
<th class="p-2 text-center">Area</th>
<th class="p-2 text-center">Weight</th>
</tr>
</thead>
<tbody id="items-table">
<!-- Items will be added here -->
</tbody>
</table>
</div>
</div>
</div>
</div>
<!-- Visualization Canvas -->
<div class="mt-8">
<div class="bg-gray-800 p-6 rounded-xl shadow-lg">
<h2 class="text-2xl font-semibold mb-4 flex items-center">
<i data-feather="layout" class="mr-2"></i> Visualization
</h2>
<div id="visualization-container" class="w-full h-96 bg-gray-900 rounded-lg relative overflow-hidden">
<canvas id="space-canvas" class="w-full h-full"></canvas>
</div>
</div>
</div>
</div>
</div>
</main>
<custom-footer></custom-footer>
<script src="components/navbar.js"></script>
<script src="components/footer.js"></script>
<script src="script.js"></script>
<script>
feather.replace();
VANTA.GLOBE({
el: "#vanta-bg",
mouseControls: true,
touchControls: true,
gyroControls: false,
minHeight: 200.00,
minWidth: 200.00,
scale: 1.00,
scaleMobile: 1.00,
color: 0x3b82f6,
backgroundColor: 0x0f1115
});
</script>
<script src="https://huggingface.co/deepsite/deepsite-badge.js"></script>
</body>
</html> |