Spaces:
Sleeping
Sleeping
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Personnalisation</title> | |
| </head> | |
| <body class="bg-bg text-textDark font-sans"> | |
| <div id="dashboard-layout" class="flex flex-col h-screen"> | |
| <div id="content" class="flex flex-col flex-1 p-6"> | |
| <!-- Error Message --> | |
| <div id="error" class="hidden text-red-600"></div> | |
| <!-- Viewspace Container --> | |
| <div id="viewspacecontainer" class="bg-white p-6 rounded-lg shadow-md"> | |
| <div class="view aspect-w-16 aspect-h-9 rounded-xl border border-yellow-300 bg-gray-100 flex items-center justify-center"> | |
| <!-- Loading Animation --> | |
| <div id="Loading" class="absolute"> | |
| <h4 class="text-lg font-bold text-gray-700"> | |
| <span id="image-progress">Loading images: 0/?</span> | |
| </h4> | |
| </div> | |
| <!-- Benchmark Stats --> | |
| <textarea readonly id="benchmark-stats" rows="10" cols="40" | |
| class="absolute top-4 left-4 border rounded p-2 text-gray-600 bg-white shadow"> | |
| Click me to start benchmarking when the frame-rate is behaving reasonably. | |
| </textarea> | |
| <!-- Loading Indicators --> | |
| <div id="loading-container" class="absolute flex space-x-4"> | |
| <div id="topleft" class="loading-bgbox w-8 h-8 bg-gray-300 rounded-full"></div> | |
| <div id="bottomleft" class="loading-bgbox w-8 h-8 bg-gray-300 rounded-full"></div> | |
| <div id="topright" class="loading-bgbox w-8 h-8 bg-gray-300 rounded-full"></div> | |
| <div id="bottomright" class="loading-bgbox w-8 h-8 bg-gray-300 rounded-full"></div> | |
| <div id="loading-indicator" class="w-8 h-8 bg-gray-500 rounded-full animate-spin"></div> | |
| </div> | |
| <!-- Viewer Canvas --> | |
| <canvas id="viewerCanvas" class="w-full h-full rounded-xl"></canvas> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <script> | |
| const scriptsToLoad = [ | |
| 'https://unpkg.com/three@0.113.1/build/three.js', | |
| 'https://unpkg.com/three@0.113.1/examples/js/controls/OrbitControls.js', | |
| 'https://unpkg.com/three@0.113.1/examples/js/controls/PointerLockControls.js', | |
| 'https://unpkg.com/three@0.113.1/examples/js/controls/TransformControls.js', | |
| 'https://unpkg.com/stats-js@1.0.1/build/stats.min.js', | |
| 'https://cdn.jsdelivr.net/npm/ccapture.js@1.0.9/build/CCapture.all.min.js', | |
| 'https://unpkg.com/file-saver@2.0.0-rc.2/dist/FileSaver.min.js', | |
| '' | |
| ]; | |
| async function loadScriptsInOrder(scripts) { | |
| for (const script of scripts) { | |
| await new Promise((resolve, reject) => { | |
| const scriptEl = document.createElement('script'); | |
| scriptEl.src = script; | |
| scriptEl.onload = resolve; | |
| scriptEl.onerror = reject; | |
| document.body.appendChild(scriptEl); | |
| }); | |
| } | |
| } | |
| loadScriptsInOrder(scriptsToLoad); | |
| </script> | |
| </body> | |
| </html> | |