Spaces:
Running
Running
Download index.html from FLEED993/sketchmaster-pro: direct link, hf CLI and curl.
- Browser
- Download file 5.47 kB
-
https://huggingface.co/spaces/FLEED993/sketchmaster-pro/resolve/main/index.html
- Command line
-
hf download hf://spaces/FLEED993/sketchmaster-pro/index.html
-
curl -L -o index.html https://huggingface.co/spaces/FLEED993/sketchmaster-pro/resolve/main/index.html
5.47 kB
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>SketchMaster Pro | Digital Drawing Platform</title> | |
| <link rel="stylesheet" href="style.css"> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script> | |
| <script src="https://unpkg.com/feather-icons"></script> | |
| <script src="components/navbar.js"></script> | |
| <script src="components/toolbar.js"></script> | |
| <script src="components/footer.js"></script> | |
| <script> | |
| tailwind.config = { | |
| theme: { | |
| extend: { | |
| colors: { | |
| primary: '#6366f1', | |
| secondary: '#f59e0b' | |
| } | |
| } | |
| } | |
| } | |
| </script> | |
| </head> | |
| <body class="bg-gray-100"> | |
| <custom-navbar></custom-navbar> | |
| <main class="container mx-auto px-4 py-8"> | |
| <div class="flex flex-col lg:flex-row gap-8"> | |
| <!-- Tools Panel --> | |
| <custom-toolbar></custom-toolbar> | |
| <!-- Canvas Area --> | |
| <div class="flex-1"> | |
| <div class="bg-white rounded-xl shadow-lg overflow-hidden"> | |
| <div class="p-4 border-b border-gray-200 flex justify-between items-center"> | |
| <h2 class="text-xl font-bold text-gray-800">Drawing Canvas</h2> | |
| <div class="flex gap-2"> | |
| <button class="px-3 py-1 bg-primary-500 text-white rounded-md hover:bg-primary-600 transition"> | |
| <i data-feather="save" class="w-4 h-4"></i> Save | |
| </button> | |
| <button class="px-3 py-1 bg-gray-200 text-gray-700 rounded-md hover:bg-gray-300 transition"> | |
| <i data-feather="share-2" class="w-4 h-4"></i> Export | |
| </button> | |
| </div> | |
| </div> | |
| <div class="p-4"> | |
| <div id="drawingCanvas" class="w-full h-96 bg-white border-2 border-dashed border-gray-300 rounded-md flex items-center justify-center cursor-crosshair"> | |
| <p class="text-gray-400">Start drawing here...</p> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Color Palette --> | |
| <div class="mt-6 bg-white rounded-xl shadow-lg p-4"> | |
| <h3 class="text-lg font-semibold mb-3 text-gray-700">Color Palette</h3> | |
| <div class="flex flex-wrap gap-2"> | |
| <div class="w-8 h-8 rounded-full bg-red-500 cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-blue-500 cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-green-500 cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-yellow-500 cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-purple-500 cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-pink-500 cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-black cursor-pointer border-2 border-white shadow"></div> | |
| <div class="w-8 h-8 rounded-full bg-white cursor-pointer border-2 border-gray-300 shadow"></div> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| </main> | |
| <custom-footer></custom-footer> | |
| <script src="script.js"></script> | |
| <script> | |
| feather.replace(); | |
| // Initialize canvas drawing functionality | |
| document.addEventListener('DOMContentLoaded', function() { | |
| const canvas = document.getElementById('drawingCanvas'); | |
| const ctx = canvas.getContext('2d'); | |
| let isDrawing = false; | |
| canvas.width = canvas.offsetWidth; | |
| canvas.height = canvas.offsetHeight; | |
| canvas.addEventListener('mousedown', startDrawing); | |
| canvas.addEventListener('mousemove', draw); | |
| canvas.addEventListener('mouseup', stopDrawing); | |
| canvas.addEventListener('mouseout', stopDrawing); | |
| function startDrawing(e) { | |
| isDrawing = true; | |
| draw(e); | |
| } | |
| function draw(e) { | |
| if (!isDrawing) return; | |
| ctx.lineWidth = 5; | |
| ctx.lineCap = 'round'; | |
| ctx.strokeStyle = '#000000'; | |
| ctx.lineTo( | |
| e.clientX - canvas.offsetLeft, | |
| e.clientY - canvas.offsetTop | |
| ); | |
| ctx.stroke(); | |
| ctx.beginPath(); | |
| ctx.moveTo( | |
| e.clientX - canvas.offsetLeft, | |
| e.clientY - canvas.offsetTop | |
| ); | |
| } | |
| function stopDrawing() { | |
| isDrawing = false; | |
| ctx.beginPath(); | |
| } | |
| }); | |
| </script> | |
| <script src="https://huggingface.co/deepsite/deepsite-badge.js"></script> | |
| </body> | |
| </html> |